summaryrefslogtreecommitdiff
path: root/src/types.h
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2015-02-23 09:11:58 +0100
committerBardur Arantsson <bardur@scientician.net>2015-02-23 09:11:58 +0100
commit2714df02ad4a4b47745caa149561e3a8c821df45 (patch)
treeeed928a19283374ede241177e294663367e20340 /src/types.h
parent11056413f0457bca511ad6f875219e031a2c3503 (diff)
Remove f_head, f_name, f_text
Diffstat (limited to 'src/types.h')
-rw-r--r--src/types.h33
1 files changed, 9 insertions, 24 deletions
diff --git a/src/types.h b/src/types.h
index 326cebf6..16bd5b04 100644
--- a/src/types.h
+++ b/src/types.h
@@ -42,31 +42,15 @@
* clearing of many variables at once.
*
* Certain data is saved in multiple places for efficient access, currently,
- * this includes the tval/sval/weight fields in "object_type", various fields
- * in "header_type", and the "m_idx" and "o_idx" fields in "cave_type". All
- * of these could be removed, but this would, in general, slow down the game
- * and increase the complexity of the code.
+ * this includes the tval/sval/weight fields in "object_type" and the "m_idx"
+ * and "o_idx" fields in "cave_type". All of these could be removed, but
+ * this would, in general, slow down the game and increase the complexity of
+ * the code.
*/
/*
- * Template file header information (see "init.c"). 16 bytes.
- */
-
-typedef struct header header;
-
-struct header
-{
- u16b info_num; /* Number of "info" records */
-
- u32b name_size; /* Size of the "name" array in bytes */
-
- u32b text_size; /* Size of the "text" array in bytes */
-};
-
-
-/*
* "Themed" objects.
* Probability in percent for each class of objects to be dropped.
* This could perhaps be an array - but that wouldn't be as clear.
@@ -89,10 +73,11 @@ typedef struct feature_type feature_type;
struct feature_type
{
- u32b name; /* Name (offset) */
- u32b text; /* Text (offset) */
- u32b tunnel; /* Text for tunneling */
- u32b block; /* Text for blocking */
+ char *name; /* Name */
+
+ const char *text; /* Text. May point to shared read-only memory, DO NOT FREE! */
+ const char *tunnel; /* Text for tunneling. May point to shared read-only memory, DO NOT FREE! */
+ const char *block; /* Text for blocking. May point to shared read-only memory, DO NOT FREE! */
byte mimic; /* Feature to mimic */