pele112
Member
Hello!
I have problem with this script. Player death but don't teleport to temple.
Someone can help me ? ;pp
I have problem with this script. Player death but don't teleport to temple.
Code:
local temple_pos ={x = 2828, y = 2663, z = 7}
function onPrepareDeath(cid, lastHitKiller, mostDamageKiller)
if type == 1 and getCreatureHealth(cid) <= value
and isPlayer(cid) then
doTeleportThing(cid, temple_pos, true)
doRemoveCondition(cid, CONDITION_INFIGHT)
doCreatureAddHealth(cid, getCreatureMaxHealth(cid), true)
doCreatureAddMana(cid, getCreatureMaxMana(cid), true)
return false
end
return true
end
Someone can help me ? ;pp