Postado Junho 18, 2014 11 anos bom gostaria de um script para um book que da as 5 blessing ao clikar nele e nao some mas so pode ser usado por players premium. OldTaboos24hpor48h.com Inauguração DOMONIGO as 18:00 | 18/03/2018 | Stages | Custom Map |VENHA SER TOP TABOOS!
Postado Junho 18, 2014 11 anos -- <action itemid="9999" script="teste.lua"/> function onUse(cid, item, fromPosition, itemEx, toPosition) local PLAYER = Player(cid) local COST = getBlessingsCost(getPlayerLevel(cid)) local BOOK_ID = 9999 if item.itemid == BOOK_ID then if(not(isPlayerPzLocked(cid))) then if(PLAYER:hasBlessing(1) and PLAYER:hasBlessing(2) and PLAYER:hasBlessing(3) and PLAYER:hasBlessing(4) and PLAYER:hasBlessing(5)) then PLAYER:sendCancelMessage("You have already been blessed by the gods.") return false end if(PLAYER:removeMoney(COST)) then for b = 1,5 do PLAYER:addBlessing(b) end PLAYER:getPosition():sendMagicEffect(CONST_ME_HOLYAREA) PLAYER:sendTextMessage(MESSAGE_INFO_DESCR, "You have been blessed by the 5 gods!") Item(item.uid):remove(1) else PLAYER:sendCancelMessage("You need "..COST.." gold coins to buy all 5 bless.") end else PLAYER:sendCancelMessage("You can't buy bless, when you are in a battle.") end else return false end return true end STYLLER OT 2022
Postado Junho 19, 2014 11 anos Autor amigo seria so para premium usar ? eo bless e de graça neh ? Editado Junho 19, 2014 11 anos por kinglekke (veja o histórico de edições) OldTaboos24hpor48h.com Inauguração DOMONIGO as 18:00 | 18/03/2018 | Stages | Custom Map |VENHA SER TOP TABOOS!
Postado Junho 19, 2014 11 anos function onUse(cid, item, fromPosition, itemEx, toPosition) local PLAYER = Player(cid) local COST = 10000 -- valor da bless local BOOK_ID = 9999 -- id do item (book) if item.itemid == BOOK_ID then if PLAYER:getPremiumDays() >= 1 then if(not(isPlayerPzLocked(cid))) then if(PLAYER:hasBlessing(1) and PLAYER:hasBlessing(2) and PLAYER:hasBlessing(3) and PLAYER:hasBlessing(4) and PLAYER:hasBlessing(5)) then PLAYER:sendCancelMessage("You have already been blessed by the gods.") return false end if(PLAYER:removeMoney(COST)) then for b = 1,5 do PLAYER:addBlessing(b) end PLAYER:getPosition():sendMagicEffect(CONST_ME_HOLYAREA) PLAYER:sendTextMessage(MESSAGE_INFO_DESCR, "You have been blessed by the 5 gods!") Item(item.uid):remove(1) else PLAYER:sendCancelMessage("You need "..COST.." gold coins to buy all 5 bless.") end else PLAYER:sendCancelMessage("You can't buy bless, when you are in a battle.") end else PLAYER:sendCancelMessage("You no have premium account.") end else return false end return true end STYLLER OT 2022
Postado Junho 19, 2014 11 anos Autor cara ta quase perfeito agora gostaria que quando o cara clika-se no item aparece-se vc nao possui premium[ se ele nao tiver premium] ou Voce ja possui os 5 blessing [ se vc ja tiver clikado no livro] OldTaboos24hpor48h.com Inauguração DOMONIGO as 18:00 | 18/03/2018 | Stages | Custom Map |VENHA SER TOP TABOOS!
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.