summaryrefslogtreecommitdiff
path: root/src/types.h
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2012-04-07 20:47:47 +0200
committerBardur Arantsson <bardur@scientician.net>2012-04-07 20:47:47 +0200
commit5ea970c82ba3119ca3a5ee68037aee7cdda6dfa3 (patch)
tree0ea4395ab8fe0cf0f6ff480228a3fb0964926fd7 /src/types.h
parent23ead090b5c135702eb8b178d8c74cb347815c29 (diff)
Lua: Moved mimicry to C
Diffstat (limited to 'src/types.h')
-rw-r--r--src/types.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/types.h b/src/types.h
index df2c4f40..040a0149 100644
--- a/src/types.h
+++ b/src/types.h
@@ -2602,3 +2602,29 @@ struct corruption_type
void (*gain_callback)(); /* callback to invoke when gained */
s16b power; /* index of granted power if >= 0, ignored otherwise */
};
+
+/**
+ * Mimicry forms
+ */
+typedef struct mimic_duration_type mimic_duration_type;
+struct mimic_duration_type
+{
+ s16b min;
+ s16b max;
+};
+
+typedef struct mimic_form_type mimic_form_type;
+struct mimic_form_type
+{
+ int modules[3]; /* Modules where this mimicry form is available; terminated with a -1 entry */
+ cptr name; /* Name of mimicry form */
+ cptr obj_name; /* Object mimicry form name */
+ cptr desc; /* Description */
+ cptr realm; /* Realm of mimicry */
+ bool_ limit; /* If true, the form is not available except through special means */
+ byte level;
+ byte rarity;
+ mimic_duration_type duration;
+ s32b (*calc)(); /* Callback to calculate bonuses; return number of blows to add */
+ void (*power)(); /* Callback to calculate powers */
+};