• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

action items

ConAn Edujawa

Member
Joined
Feb 23, 2015
Messages
457
Reaction score
17
i try to make items add mana 3 time in 3 differnt lvls but its work only in first lvl anyone can help me?
0.4
sorry for my bad english

Code:
function onUse(cid, item, frompos, item2, topos)
    if getPlayerLevel(cid) >= 8 and getPlayerStorageValue(cid, 81729) == 0 then 
    doSendMagicEffect(getCreaturePosition(cid), 33)
     setCreatureMaxHealth(cid, (getCreatureMaxHealth(cid)+500))
    doPlayerSendTextMessage(cid, 22, "You gained 500 extra Health point!")
    doCreatureSetStorage(cid, 81729, 1)
    doRemoveItem(item.uid, 1)
               else
                doPlayerSendTextMessage(cid,19,'You used it before')
    return true
    end
     if getPlayerLevel(cid) >= 400 and getPlayerStorageValue(cid, 81629) == 0 then
    doSendMagicEffect(getCreaturePosition(cid), 33)
     setCreatureMaxHealth(cid, (getCreatureMaxHealth(cid)+500))
      doPlayerSendTextMessage(cid, 22, "You gained 500 extra Health point!")
     doCreatureSetStorage(cid, 81629, 1)
            doRemoveItem(item.uid, 1)
            return true
     end
      if getPlayerLevel(cid) >= 600 and getPlayerStorageValue(cid, 81529) == 0 then
      doSendMagicEffect(getCreaturePosition(cid), 33)
     setCreatureMaxHealth(cid, (getCreatureMaxHealth(cid)+500))
       doPlayerSendTextMessage(cid, 22, "You gained 500 extra Health point!")
      doCreatureSetStorage(cid, 81529, 1)
              doRemoveItem(item.uid, 1)
            return true
      end
end
 
Last edited:
Back
Top