-
Notifications
You must be signed in to change notification settings - Fork 191
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
Script to commute the prison sentence of a convicted criminal #1200
base: master
Are you sure you want to change the base?
Conversation
e16f1cb
to
f43f816
Compare
with just the one command ( |
c6ff149
to
d1081ea
Compare
d1081ea
to
7b85a77
Compare
======= | ||
|
||
.. dfhack-tool:: | ||
:summary: Commands related to the justice system |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:summary: Commands related to the justice system | |
:summary: Commands related to the justice system. |
This tool allows control over aspects of the justice system, such as the | ||
ability to pardon criminals. | ||
|
||
usage |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
usage | |
Usage |
:: | ||
justice pardon [--unit <id>] | ||
|
||
Pardon the selected unit or the one specified by unit id if provided. Currently |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pardon the selected unit or the one specified by unit id if provided. Currently | |
Pardon the selected unit or the one specified by unit id (if provided). Currently |
only applies to prison time and doesn't cancel beatings or hammerings. | ||
|
||
|
||
options |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
options | |
Options |
unit = df.unit.find(unit_id) | ||
if not unit then qerror(("No unit with id %i"):format(unit_id)) end | ||
end | ||
if unit then pardon_unit(unit) end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if unit then pardon_unit(unit) end | |
pardon_unit(unit) |
end | ||
|
||
qerror(("Unrecognised command: %s"):format(command)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
end | |
qerror(("Unrecognised command: %s"):format(command)) | |
elseif not command then | |
qerror('missing command') | |
else | |
qerror(("Unrecognised command: %s"):format(command)) | |
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please also add a line to the changelog under New tools
Fixes DFHack/dfhack#4738