v50 Steam/Premium information for editors
- v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
- Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.
Difference between revisions of "40d:Memory hacking/v0.27.169.33a"
Jump to navigation
Jump to search
m (→Addresses: Whoops.) |
|||
Line 70: | Line 70: | ||
| <code>0x0000</code> || 4 || || Vptr || Virtual function table pointer | | <code>0x0000</code> || 4 || || Vptr || Virtual function table pointer | ||
|- | |- | ||
− | | <code>0x0004</code> || 24 || [[Memory hacking# | + | | <code>0x0004</code> || 24 || [[Memory hacking#String|string]] || First name || |
|- | |- | ||
− | | <code>0x0020</code> || 24 || [[Memory hacking# | + | | <code>0x0020</code> || 24 || [[Memory hacking#String|string]] || Nickname || |
|- | |- | ||
− | | <code>0x0070</code> || 24 || [[Memory hacking# | + | | <code>0x0070</code> || 24 || [[Memory hacking#String|string]] || Custom profession name || |
|- | |- | ||
| <code>0x0088</code> || 2 || || Type ID #1 || rowspan="2"| Dwarf types. 0x88 is the original dwarf type, 0x8a is the current dwarf type (I'm told Toady stores the original dwarf type for legends). The key is in the "Type ID" table, woefully incomplete. | | <code>0x0088</code> || 2 || || Type ID #1 || rowspan="2"| Dwarf types. 0x88 is the original dwarf type, 0x8a is the current dwarf type (I'm told Toady stores the original dwarf type for legends). The key is in the "Type ID" table, woefully incomplete. | ||
Line 94: | Line 94: | ||
|- | |- | ||
| <code>0x01F8</code> || 2 || || Strange mood || 0xFFFF means no mood | | <code>0x01F8</code> || 2 || || Strange mood || 0xFFFF means no mood | ||
+ | |- | ||
+ | | <code>0x0304</code> || || [[Memory hacking#Vector|vector]] || Bodypart Health || A list to body part health, the list of ushorts, values range 0 to 15 from what i've seen. 15 being white, 0 being red. | ||
|- | |- | ||
| <code>0x041C</code> || 4 || || Strength || | | <code>0x041C</code> || 4 || || Strength || |
Revision as of 14:45, 5 November 2007
Addresses
Name | Size | Type | Notes | Offset |
---|---|---|---|---|
Art defacement malus | 4 | long | normally -1000 (18 FC FF FF) | 0079DC2F
|
Current unit focus | 4 | long | Indexes into the full creature list. | 00C2F548
|
Current year | 00C34378
| |||
Map menu state | 4 | long | The current state of the menu when viewing the map normally in Dwarf Fortress. 0x16 when in 'View Units' mode, other values unknown.
|
123B65C
|
Dwarf race ID | As in the race identifier in the creature structure. | 01237AD0 (probably)
| ||
Creature vector | vector | There are actually multiple creature vectors, but this has all of them. | 01416A38
| |
Another creature vector | vector | This is the creature list that 'Current unit focus' indexes into, unlike previously stated. | 01416A48
|
Creature Structure
Offset | Size | Type | Name | Notes | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0x0000 |
4 | Vptr | Virtual function table pointer | |||||||||||||||
0x0004 |
24 | string | First name | |||||||||||||||
0x0020 |
24 | string | Nickname | |||||||||||||||
0x0070 |
24 | string | Custom profession name | |||||||||||||||
0x0088 |
2 | Type ID #1 | Dwarf types. 0x88 is the original dwarf type, 0x8a is the current dwarf type (I'm told Toady stores the original dwarf type for legends). The key is in the "Type ID" table, woefully incomplete. | |||||||||||||||
0x008A |
2 | Type ID #2 | ||||||||||||||||
0x008C |
4 | Creature Race | A6 is the dwarf default (this may be different if the user has a mod installed) | |||||||||||||||
0x00AC |
2 | X Coordinate | Cells east of the west side | |||||||||||||||
0x00AE |
2 | Y Coordinate | Cells south of the north side | |||||||||||||||
0x00B0 |
2 | Z Coordinate | Levels up from the bottom level | |||||||||||||||
0x00E4 |
4 | Flags | (1 << 1) Unclear. It is set on dead things. Also, when a merchant caravan arrives, merchants and guards are added to the entity list slightly before they are added to the "u" list - during this period, this bit is set. | |||||||||||||||
0x00E8 |
4 | Flags | (1 << 7) Appears to be whether or not the creature is dead.
(1 << 17) if creature is ready for slaughter | |||||||||||||||
0x01F8 |
2 | Strange mood | 0xFFFF means no mood | |||||||||||||||
0x0304 |
vector | Bodypart Health | A list to body part health, the list of ushorts, values range 0 to 15 from what i've seen. 15 being white, 0 being red. | |||||||||||||||
0x041C |
4 | Strength |
| |||||||||||||||
0x0420 |
4 | Agility |
| |||||||||||||||
0x0424 |
4 | Toughness |
| |||||||||||||||
0x042C |
4 | Skill Start Ptr | Start of skill list | |||||||||||||||
0x0430 |
4 | Skill End Ptr | End of skill list | |||||||||||||||
0x0458 |
102 | Labor preferences | 102 1 byte values, corresponding to the profession list. Mostly bools, with notable exceptions of shieldtype,armortype, and weaponnum. I have No idea what the last one means. | |||||||||||||||
0x0504 |
4 | Happiness level | 0 = miserable, >149 = ecstatic |