Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Give position.rst the "dfhack" tag; changes relating to active units #1308

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion deep-embark.lua
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ function moveEmbarkStuff(selectedBlock, embarkTiles)
local unitsAtSpawn = dfhack.units.getUnitsInBox(x1, y1, z1, x2, y2, z2)
local movedUnit = false
for i, unit in ipairs(unitsAtSpawn) do
if unit.civ_id == df.global.plotinfo.civ_id and not unit.flags1.inactive and not unit.flags2.killed then
if unit.civ_id == df.global.plotinfo.civ_id and not unit.flags2.killed then
local pos = embarkTiles[math.random(1, #embarkTiles)]
dfhack.units.teleport(unit, pos)
reveal(pos)
Expand Down
2 changes: 1 addition & 1 deletion docs/exterminate.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Options
``-m``, ``--method <method>``
Specifies the "method" of killing units. See below for details.
``-o``, ``--only-visible``
Specifies the tool should only kill units visible to the player.
Specifies the tool should only kill units visible to the player
on the map.
``-f``, ``--include-friendly``
Specifies the tool should also kill units friendly to the player.
Expand Down
2 changes: 1 addition & 1 deletion docs/position.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ position

.. dfhack-tool::
:summary: Report cursor and mouse position, along with other info.
:tags: adventure fort inspection map
:tags: adventure dfhack fort inspection map
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


This tool reports the current date, clock time, month, season, and historical
era. It also reports the keyboard cursor position (or just the z-level if no
Expand Down
2 changes: 1 addition & 1 deletion fix/stuckdoors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ end

-- Util function: find out if there are any units on the tile with coordinates x,y,z
function unitOnTile(x, y, z)
local units = dfhack.units.getUnitsInBox(x,y,z,x,y,z,dfhack.units.isActive)
local units = dfhack.units.getUnitsInBox(x,y,z,x,y,z)
return #(units) > 0
end

Expand Down
2 changes: 1 addition & 1 deletion modtools/reaction-trigger.lua
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ local validArgs = utils.invert({
'allowMultipleTargets',
'range',
'ignoreWorker',
'dontSkipInactive',
'dontSkipInactive', --TODO: positions for inactive units are meaningless!
'resetPolicy'
})

Expand Down