Postado Janeiro 29, 2023 2 anos Action: Remover skull Citar local removeSkull = Action() function removeSkull.onUse(player, item, fromPos, target, toPos, isHotkey) local Info = { [3] = {msg = "Você perdeu seu white skull e frags por 100k.", item = 37337, caveira = "White Skull"}, [4] = {msg = "Você perdeu seu red skull e frags por 500k.", item = 37338, caveira = "Red Skull"}, [5] = {msg = "Você perdeu seu black skull e frags por 1kk.", item = 37335, caveira = "Black Skull"}, } local skull = Info[player:getSkull(creature)] local playerPos = player:getPosition() local tile = Tile(playerPos) if player:getCondition(CONDITION_INFIGHT, CONDITIONID_DEFAULT) and not Tile(player:getPosition()):hasFlag(TILESTATE_PROTECTIONZONE) then player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Você pode usar apenas em pz ou sem battle.") return true end if (not skull) then player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Você não está com nenhum tipo de skull.") return false end if skull then Game.broadcastMessage('Jogador: '.. player:getName() ..' acabou de remover sua ' .. skull.caveira .. '.', MESSAGE_GAME_HIGHLIGHT) player:setSkull(0) player:say("Removeu " .. skull.caveira .. "!") player:sendCancelMessage(skull.msg) player:getPosition():sendMagicEffect(50) player:getPosition():sendMagicEffect(29) Item(item.uid):remove(1) else player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Você não tem " .. ItemType(skull.item):getName() .. " para remover sua skull.") player:getPosition():sendMagicEffect(3) end end removeSkull:id(37337, 37338, 37335) removeSkull:register()
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.