Skip to content
Snippets Groups Projects
Commit ebefcfb1 authored by dg's avatar dg
Browse files

Failing to wear an item will not consume a turn

git-svn-id: http://svn.net-core.org/repos/t-engine4@4990 51575b47-30f0-44d4-a5cc-537603b46e54
parent 94c170db
No related branches found
No related tags found
No related merge requests found
......@@ -849,12 +849,12 @@ function _M:doWear(inven, item, o)
self:removeObject(inven, item, true)
local ro = self:wearObject(o, true, true)
if ro then
self:useEnergy()
if type(ro) == "table" then self:addObject(inven, ro) end
elseif not ro then
self:addObject(inven, o)
end
self:sortInven()
self:useEnergy()
self:playerCheckSustains()
self.changed = true
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment