Critico
Sexy
- Joined
- Mar 25, 2010
- Messages
- 370
- Reaction score
- 176
be added to this script every time you reset, you will add hp and mana?
example:
190 hp + 1 reset = 205 hp
35 mana + 1 reset = 95 mana
try this
Code:
for _, k in ipairs(stage) do
if getReborns(cid) <= k.reborn then
if getPlayerLevel(cid) >= k.level then
setPlayerStorageValue(cid, 1020, getReborns(cid)+1)
doPlayerPopupFYI(cid, "You now was reborn, you have "..getReborns(cid)+(1).." reborn\'s.")
doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)))
local hp,mana = (getCreatureMaxHealth(cid)+10),(getCreatureMaxMana(cid)+15)
doRemoveCreature(cid)
db.executeQuery("UPDATE `players` SET `level` = "..config.RemainingLvl..", `experience` = "..config.exp..",`manamax` = "..mana..",`healthmax` = "..hp..",`health` = "..hp..",`mana` = "..mana.." WHERE `id` = "..config.pid)
else
doPlayerSendCancel(cid, "You need to have level "..k.level.." or more you may be reborn.")
doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
end
end
end
local hp,mana = (getCreatureMaxHealth(cid)+10),(getCreatureMaxMana(cid)+15)
+10 hp points
+15 mana points