Merge remote-tracking branch 'Putnam3145/patch-10' into develop

Conflicts:
	NEWS
develop
lethosor 2015-02-06 17:08:00 -05:00
commit 7823a14a8f
2 changed files with 8 additions and 2 deletions

@ -3,6 +3,7 @@ DFHack Future
Lua scripts will only be reloaded if necessary and will delete their old globals if the file was changed. Lua scripts will only be reloaded if necessary and will delete their old globals if the file was changed.
Fixes Fixes
Gave add-thought a proper subthought arg. Gave add-thought a proper subthought arg.
Made hack-wish stack properly.
New Plugins New Plugins
New Scripts New Scripts
modtools/reaction-product-trigger: triggers callbacks when products are produced (contrast with when reactions complete) modtools/reaction-product-trigger: triggers callbacks when products are produced (contrast with when reactions complete)

@ -190,8 +190,13 @@ function hackWish(unit)
if args.multi then if args.multi then
repeat amountok,amount=script.showInputPrompt('Wish','How many do you want? (numbers only!)',COLOR_LIGHTGREEN) until tonumber(amount) repeat amountok,amount=script.showInputPrompt('Wish','How many do you want? (numbers only!)',COLOR_LIGHTGREEN) until tonumber(amount)
if mattype and itemtype then if mattype and itemtype then
for i=1,tonumber(amount) do if df.item_type.attrs[itemtype].is_stackable then
createItem({mattype,matindex},{itemtype,itemsubtype},quality,unit,description) local proper_item=df.item.find(dfhack.items.createItem(itemtype, itemsubtype, mattype, matindex, unit))
proper_item:setStackSize(amount)
else
for i=1,amount do
dfhack.items.createItem(itemtype, itemsubtype, mattype, matindex, unit)
end
end end
end end
else else