Skip to content

Instantly share code, notes, and snippets.

@warmist
Forked from thistleknot/gist:6146077
Last active December 20, 2015 14:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save warmist/6146095 to your computer and use it in GitHub Desktop.
Save warmist/6146095 to your computer and use it in GitHub Desktop.
unit = dfhack.gui.getSelectedUnit()
Physical = {STRENGTH=450, TOUGHNESS=950}
P_Attributes = unit.body.physical_attrs
M_Attributes = unit.status.current_sould.mental_attrs
for attrName, attrValue in pairs(Physical) do
P_Attributes[attrName].value = attrValue
P_Attributes[attrName].max_value = attrValue*2
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment