Commit Graph

48 Commits (c1273982cf03ca726430aa9199bce0655ce4b227)

Author SHA1 Message Date
Petr Mrázek bd9643c8cc Merge branch 'dfapi'
Conflicts:
	CMakeLists.txt
	library/DFProcess-linux.cpp
	library/include/dfhack-c/modules/Creatures_C.h
	library/include/dfhack/modules/Maps.h
	library/modules/Creatures_C.cpp
2011-07-23 17:29:05 +02:00
Matthew Cline 5c1526d6d9 creatures: read and write pregnancy counter
Also change creaturemanger to print out the ticks-until-birth for
pregnant creatures.
2011-07-11 02:48:10 -07:00
Matthew Cline cb9c9aae7c Deal with third flag group in creatures
Added support for reading and writing the third creature flag group,
t_creaturflags3 (the offest already exists in Memory.xml).  So far I've
only figured out three of the flags (out of an apparent 13):

1) announce_titan, which causes the creature to be announced as if
   it was a titan or FB which had just arrived.

2) scuttle, which causes the creature to be die like it had been
   killed in the game.  That is, it leaves behind a corpse, and
   will generate unhappy thoughts in dwarves if approriate.

3) ghostly, for creatures which are the ghosts of dead dwarves.

I updated creaturemanager to use scuttle for --kill, and added the
action --erase to kill in the old way which doesn't leave a corpse or
creatre unhappy thoughts.
2011-07-10 04:00:52 -07:00
Petr Mrázek e0fb8f7c81 Crud removal: Context is gone. Added missing FakeSDL.h 2011-06-17 15:02:43 +02:00
Petr Mrázek 93be1eb1fb Yay, kittens! Also some license cleanup, IO thread usage, more SDL wrapping and ability to run reveal from DFHack console. 2011-06-16 23:53:39 +02:00
Petr Mrázek 511f459182 Stripped nonsense from the DFHack vector wrapper. Next step: removal. 2011-06-13 01:14:10 +02:00
Petr Mrázek 81d648dfa7 First 'working' DFHack inside DF, for 'some' values of 'working'. 2011-06-12 23:17:40 +02:00
Petr Mrázek da2fb1cb1a Fix creature owned items vector offset on Windows, added support for owned items to more versions. 2011-05-28 10:18:50 +02:00
Alexander Gavrilov a7be2aee33 Support actually removing owner links between items and creatures. 2011-05-12 21:10:29 +04:00
Alexander Gavrilov ed1477b53d Support listing items owned by a creature. 2011-05-09 14:49:44 +04:00
Petr Mrázek 96bfec5402 The mood offset on linux was OK. General fixage of things. 2011-05-08 03:21:34 +02:00
Petr Mrázek f481ee7b5d Add missing stddef.h include in Creatures module. 2011-04-24 02:49:49 +02:00
Alexander Gavrilov ebc4d21e66 Improve name structure handling, and support duplicating them (on linux).
The name structure actually contains additional linguistical data,
ignoring which produces wrong renderings for non-dwarfish names.
This data also obviously has to be copied with the structure.

Copying STL strings works by replicating the shared copy logic
(i.e. incrementing the reference counter), but leaks memory owned
by the string being overwritten.
2011-04-13 20:36:10 +04:00
Alexander Gavrilov 2e0ec2db72 Support retrieving the item owner reference.
Reference is done by item id, and stored in some kind
of generic reference vector in the item structure.
2011-04-11 14:32:53 +04:00
Petr Mrázek bb04aa1a32 Linux header cleanups. Windows side will follow. 2011-04-10 10:19:15 +02:00
Petr Mrázek 7b1f3ce72b Job ID is a Word, not DWord. 2011-04-03 21:43:16 +02:00
Petr Mrázek 8b8c70b5ff Big creature jobs read/write fix (it was cmpletely broken) 2011-04-03 21:27:47 +02:00
Petr Mrázek a7f3258018 Get rid of SHM in modules. 2011-03-18 17:58:48 +01:00
Petr Mrázek b94ddf50d0 Eliminated silly dependency cascade within the library. Some documentation tweaks. 2011-03-18 08:53:59 +01:00
Petr Mrázek 9f5ee8a790 Many fixes, still many to go. 2011-02-18 02:51:17 +01:00
Petr Mrázek ac91f46b6c Merged patches from Rainer Keller 2010-11-17 20:50:50 +01:00
Petr Mrázek 5a5745590a More Creatures rework, this time with more memset 2010-09-03 03:01:37 +02:00
Petr Mrázek dc6aa19083 Creature rework 2010-09-03 02:15:09 +02:00
Petr Mrázek 86aa19daa4 Fix for Creature module 2010-08-31 17:21:47 +02:00
Petr Mrázek b9bee108e1 Sync, fixes. 2010-08-31 06:52:03 +02:00
Petr Mrázek 95abf6e605 All the modules *should* now use the new offset storage properly. Maybe, needs testing :) 2010-08-30 00:08:17 +02:00
Petr Mrázek e762f1caea Merge branch 'master' of git://bigbox.banquise.net/dfhack
Conflicts:
	tools/examples/creaturedump.cpp
	tools/supported/dumpoffsets.cpp
2010-08-28 04:39:03 +02:00
Petr Mrázek 1bceac2343 Rename memory_info and its factory class. 2010-08-20 14:10:05 +02:00
simon 9cf2e0f26d Support for reading inventory 2010-08-17 15:21:54 +02:00
sizeak 7d684d12b4 Job writing for mood material editing 2010-08-09 19:28:35 +01:00
Simon Jackson 1e7a705129 getType needs lots of work but its ok(ish). Mostly working .10 creature offsets 2010-07-15 12:57:45 +01:00
Simon Jackson 4f009a5c5c Civilisation writing 2010-06-23 03:32:33 +01:00
Simon Jackson e1e1850d8e Position writing 2010-06-22 18:27:27 +01:00
Simon Jackson 3f0ab50b5d mood skill writing 2010-06-22 17:21:09 +01:00
Simon Jackson 95b52d099f flag writing type fix 2010-06-19 20:09:16 +01:00
Petr Mrázek 41f3432d1c whitespace 2010-06-18 01:17:46 +02:00
Simon Jackson 96c774629a Added mood writing. Mood only, not skill or anything. Seems to work ok 2010-06-17 23:18:01 +01:00
Simon Jackson 061108c685 weird skill reading byte alignment fix (reverted to how it was original minus the offsetof change) 2010-06-17 19:24:18 +01:00
Simon Jackson 9a15f00c8d bug fix, sex writing (seems to work ok), trait writing(untested) 2010-06-16 20:47:05 +01:00
Petr Mrázek 5e105c9571 fix typo 2010-06-16 02:03:37 +02:00
Simon Jackson ba9d2d14c2 Magic number cleaning 2010-06-16 08:01:17 +08:00
Simon Jackson 77d2343742 Attribute writing added 2010-06-16 07:22:39 +08:00
Simon Jackson 8fb05f24db Skill writing added 2010-06-16 07:22:38 +08:00
Simon Jackson 2254f3dfe5 Flag writing function added 2010-06-16 07:22:38 +08:00
Simon Jackson b95efc22fe Happiness writing function added and tested. Seems ok so far 2010-06-16 07:22:38 +08:00
Petr Mrázek 04b71f154c Fun and games. Also turning old DFWindow class into a module tracked by Context. 2010-05-26 12:24:45 +02:00
Petr Mrázek 966a145b3e Moving stuff around, part 3 2010-05-26 08:42:09 +02:00
Petr Mrázek b710ed687a Moving stuff around, part 2 2010-05-26 06:48:23 +02:00