Commit Graph

105 Commits (a7085ea36bdc45b087d7c3d2c8e54ec30d603877)

Author SHA1 Message Date
myk002 fc860478e4
move fastdwarf's teleport code to Units module
and expose in Lua API
2021-06-06 08:48:32 -07:00
myk002 9e17bc938c
only set labor validity for the player civ 2021-02-17 09:16:49 -08:00
myk002 6819ee9928
make alchemist flag valid for controllable civs 2021-02-05 16:45:39 -08:00
lethosor 8c5b21b7ee
Fix a couple warnings in the Units module (#1615) 2020-08-08 14:35:12 -04:00
Ryan Bennitt 23c22b3b9d Merge branch 'develop' of https://github.com/DFHack/dfhack into feature/manipulator_goal 2020-08-07 22:17:32 +01:00
Ryan Bennitt a85b77e6f1 Retrieve goal string values from enum attributes and add new Units methods to Lua API and docs 2020-08-07 22:07:48 +01:00
Ryan Bennitt 9510dd52e1 Add Goal to Manipulator Detail Modes 2020-08-04 23:01:28 +01:00
PatrikLundell 5570a5743b Merge branch 'develop' of https://github.com/DFHack/dfhack into Units 2020-06-26 09:53:41 +02:00
PatrikLundell d5b5b81450 changes 2020-06-02 15:03:59 +02:00
Ben Lubar 5d05cfc7cc
Fix several functions in the Units module ignoring unit caste.
Fixes #1583.
2020-06-02 01:18:57 -05:00
PatrikLundell ec7f97bb7a adapted to enum value name change 2020-05-02 17:37:10 +02:00
PatrikLundell 21be5cf061 adapted to structures 2020-04-22 15:32:49 +02:00
PatrikLundell f371ae6da8 adapted to histfig_nemesis_id->union 2020-04-22 12:38:37 +02:00
PatrikLundell f4f2aa0d5e removed underscores, adapted to structure (re)naming 2020-04-15 10:18:37 +02:00
PatrikLundell 55988e3fc4 adapted to updated structures, remote Using units for age 2020-04-08 08:45:40 +02:00
PatrikLundell a0e2abe20a Units update need coordination with structure identity 2020-04-04 14:00:26 +02:00
Ben Lubar 66ded03bc1
update structures 2020-03-02 20:41:13 -06:00
lethosor 5eca50476e Merge remote-tracking branch 'nornagon/unit-description' into develop 2020-01-13 23:31:23 -05:00
Ben Lubar be5dc2d4a4
Make Units::isGay act consistently when called on an asexual unit.
The function appears to be used to determine whether heterosexual relationships are possible, so asexual units will always return true for isGay.

Old behavior was to treat asexual units as male.
2020-01-09 14:48:30 -06:00
Jeremy Apthorp 5de368a1ed unit_{=> get_}physical_description 2020-01-04 22:17:03 +11:00
Jeremy Apthorp 7644dde9e4
default to empty description if symbol unavailable 2019-12-14 12:01:13 -08:00
Jeremy Apthorp 50e696acf6 getDescription => getPhysicalDescription 2019-12-14 09:36:47 -08:00
Jeremy Apthorp 7fce6fe0b0 move THISCALL define to header, clean up code a little 2019-12-13 23:54:27 -08:00
Jeremy Apthorp dfab521a71
specify __thiscall
According to https://docs.microsoft.com/en-us/cpp/cpp/thiscall?view=vs-2019, "on ARM and x64 machines, __thiscall is accepted and ignored by the compiler.". So it should be OK to specify this for all win32
2019-12-12 17:51:41 -08:00
Jeremy Apthorp 9a37849603 use symbols.xml 2019-12-07 22:41:55 -08:00
Jeremy Apthorp 910f965838 wip 2019-12-07 22:17:59 -08:00
lethosor 2dac3c53c7 Add stress cutoffs to Units module, fix dwarfmonitor/manipulator
Fixes #1292
2018-07-09 15:59:12 -04:00
lethosor 54cf8b7dc3 Fix getVisibleName for units with identities
As of 0.44.11 (possibly 0.44.01), identity names take precedence over the
associated histfig names. Tested with:

https://drive.google.com/file/d/1bX5CQMqNsb_mjJOEOS4wBm4mGDLLs_cZ/view (#1279)
http://dffd.bay12games.com/file.php?id=13428 (from http://www.bay12games.com/dwarves/mantisbt/view.php?id=10530)

Fixes #1279
2018-07-06 11:06:04 -04:00
Pauli c39a882b57 Add missing Unit::isDiplomat
Fixes #1324
2018-06-29 16:19:18 +03:00
lethosor 7a5e7c7c86 Rename unit_flags1.dead to killed, update submodules/changelog
Follow-up for dfhack/df-structures#247
2018-06-21 11:17:09 -04:00
PatrikLundell 51584c2d9e Corrected isGhost 2018-06-13 15:37:45 -04:00
PatrikLundell f329774059 dead & killed flag separation
squashed 4 commits from #1297
2018-06-13 15:37:45 -04:00
lethosor 27343e3253 Add unit and tile visibility functions 2017-06-10 21:54:08 -04:00
lethosor 778ffb0971 More Units module cleanup, modernize getUnitsInBox 2017-06-10 21:02:30 -04:00
lethosor 1321a64613 Remove lots of old/unused functions from the Units module 2017-06-10 17:21:34 -04:00
lethosor 71b553b305 Add a few functions to retrieve unit social activities 2017-04-28 17:25:58 -04:00
lethosor 215afa34f3 Update for 64-bit unit changes
Includes xml, stonesense, scripts

Ref DFHack/df-structures@25cb373
2016-08-10 23:50:00 -04:00
lethosor 402a96b0e6 Expose new unit functions to lua and add some basic safety checks 2016-04-23 21:52:50 -04:00
lethosor 52728babd4 Merge branch 'develop' into zone-unassign 2016-04-22 18:41:15 -04:00
sv-esk 9da79544de fix Units::isCitizen
fixes a lot of issues where plugins ignore non-dwarf citizens and work
with dwarf mercenaries and bards, where it shouldnot
2016-03-04 22:48:33 +02:00
lethosor 5bb19a230f getKillCount: also search kills->events 2016-02-25 15:34:56 -05:00
lethosor 25507a10f9 Add Units::getKillCount() and expose it to Lua 2016-02-25 15:21:14 -05:00
lethosor 3e44aabf12 Expose Units::getSquadName to lua 2016-02-25 15:19:35 -05:00
sv-esk 83c70ccb0f forbid manipulator editing non-citizens 2016-02-11 13:31:52 +02:00
James Gilles 0a670bb0db Implement #804, move some functions to Units, colorize zone output, a
little cleanup
2016-02-01 11:12:06 -05:00
lethosor 5a1e5e1464 Expose Units::casteFlagSet() 2015-12-19 11:07:35 -05:00
lethosor ac71fa8070 Add isValidLabor() to Units module
Closes #711 and could avoid potential issues when editing units from
other civs with manipulator.
2015-10-30 18:41:09 -04:00
lethosor 10cfef0553 Fix whitespace issues 2015-02-14 22:53:06 -05:00
Chris Dombroski f608235b1e Fix some Lua things 2015-01-29 19:56:50 -05:00
Chris Dombroski 1514233aaa Add missing null checks to Units.cpp 2015-01-29 13:57:50 -05:00