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

provide mana pots to mages at birth

bind mana & heal pots to keybinds 9 and 10 at birth


git-svn-id: http://svn.net-core.org/repos/t-engine4@281 51575b47-30f0-44d4-a5cc-537603b46e54
parent 298ed5ae
No related branches found
No related tags found
No related merge requests found
......@@ -151,6 +151,12 @@ function _M:apply()
self.actor:initBody()
end
if d.copy then
-- Append array part
while #d.copy > 0 do
local f = table.remove(d.copy)
table.insert(self.actor, f)
end
-- Copy normal data
table.merge(self.actor, d.copy, true)
end
end
......
......@@ -112,10 +112,17 @@ newBirthDescriptor{
copy = {
max_life = 80,
life_rating = 7,
equipment = resolvers.equip{ id=true,
resolvers.equip{ id=true,
{type="weapon", subtype="staff", name="elm staff"},
{type="armor", subtype="cloth", name="robe"}
},
resolvers.inventory{ id=true,
{type="potion", subtype="potion", name="potion of lesser mana"},
{type="potion", subtype="potion", name="potion of lesser mana"},
},
resolvers.generic(function(e)
e.hotkey[10] = {"inventory", "potion of lesser mana"}
end),
},
}
......
......@@ -16,6 +16,9 @@ newBirthDescriptor{
{type="potion", subtype="potion", name="potion of lesser healing"},
{type="potion", subtype="potion", name="potion of lesser healing"},
},
resolvers.generic(function(e)
e.hotkey[9] = {"inventory", "potion of lesser healing"}
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