Postado Agosto 30, 2020 4 anos Autor 15 horas atrás, Naze disse: Posta tudo que está usando onDeath, onPrepareDeath <event type="PrepareDeath" name="BattleDeath" event="script" value="BattleCreatureScript.lua"/> function onLogin(cid) registerCreatureEvent(cid, "BattleTeam") registerCreatureEvent(cid, "BattleDeath") if getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage) == -1 then setGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage, 0) setGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage, 0) setGlobalStorageValue(_Lib_Battle_Info.storage_count, 0) end if getPlayerStorageValue(cid,_Lib_Battle_Info.TeamOne.storage) >= 1 or getPlayerStorageValue(cid,_Lib_Battle_Info.TeamTwo.storage) >= 1 then setPlayerStorageValue(cid, _Lib_Battle_Info.TeamOne.storage, -1) setPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage, -1) doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) end return true end function onCombat(cid, target) if isPlayer(cid) and isPlayer(target) then if getPlayerStorageValue(cid,_Lib_Battle_Info.TeamOne.storage) >= 1 and getPlayerStorageValue(target,_Lib_Battle_Info.TeamOne.storage) >= 1 or getPlayerStorageValue(cid,_Lib_Battle_Info.TeamTwo.storage) >= 1 and getPlayerStorageValue(target,_Lib_Battle_Info.TeamTwo.storage) >= 1 then return false end return true end return true end function onPrepareDeath(cid, deathList, lastHitKiller, mostDamageKiller) if isPlayer(cid) and getPlayerStorageValue(cid,_Lib_Battle_Info.TeamOne.storage) >= 1 or getPlayerStorageValue(cid,_Lib_Battle_Info.TeamTwo.storage) >= 1 then local MyTeam = getPlayerStorageValue(cid,_Lib_Battle_Info.TeamOne.storage) >= 1 and _Lib_Battle_Info.TeamOne.storage or _Lib_Battle_Info.TeamTwo.storage local EnemyTeam = getPlayerStorageValue(cid,_Lib_Battle_Info.TeamOne.storage) >= 1 and _Lib_Battle_Info.TeamTwo.storage or _Lib_Battle_Info.TeamOne.storage setGlobalStorageValue(MyTeam, (getGlobalStorageValue(MyTeam)-1)) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "[Akat Vs Anbu] Voce esta Morto !") setPlayerStorageValue(cid, MyTeam, -1) doRemoveCondition(cid, CONDITION_OUTFIT) if getGlobalStorageValue(MyTeam) == 0 then getWinnersBattle(EnemyTeam) else doBroadCastBattle(23,"[Akat Vs Anbu Informacao] ".._Lib_Battle_Info.TeamOne.name.." "..getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage).." VS "..getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage).." " .._Lib_Battle_Info.TeamTwo.name) end end return true end <event type="death" name="DeathPlayer" event="script" value="youdead.lua"/> function onDeath(cid, corpse, deathList) if not isPlayer(cid) then return true end local killer = deathList[1] if isMonster(killer) then doBroadcastMessage(getCreatureName(cid).." [Level: "..getPlayerLevel(cid).."] foi morto pelo monstro "..getCreatureName(killer).."." , MESSAGE_STATUS_CONSOLE_ORANGE) elseif isPlayer(killer) then doBroadcastMessage(getCreatureName(cid).." [Level: "..getPlayerLevel(cid).."] foi morto pelo jogador "..getCreatureName(killer).." [Level: "..getPlayerLevel(killer).."].", MESSAGE_STATUS_CONSOLE_ORANGE) end return true end <event type="death" name="redSkullAmulet" event="script" value="redamulet.lua"/> function onDeath(cid, corpse, deathList) local ID_ITEM = 2170 if (getPlayerSlotItem(cid, CONST_SLOT_NECKLACE).itemid == ID_ITEM) and (getCreatureSkullType(cid) == SKULL_RED or getCreatureSkullType(cid) == SKULL_BLACK) then doPlayerRemoveItem(cid, 2170, 1) doCreatureSetDropLoot(cid, false) else if (getPlayerSlotItem(cid, CONST_SLOT_NECKLACE).itemid == ID_ITEM) and getPlayerSkullType(cid) <= 3 then doCreatureSetDropLoot(cid, false) end end return true end <event type="death" name="stordeath" event="script" value="stordeath.lua"/> function onDeath(cid, corpse, deathList) local i = getPlayerStorageValue(cid, voc_stor) if i > 0 then doPlayerSetVocation(cid, i) setPlayerStorageValue(cid, voc_stor, 0) end return true end
Postado Agosto 30, 2020 4 anos apesar de ta mal formatado nao me parece ter nenhum problema o redSkullAmulet, tenta desativa ele e testa, e fazendo o mesmo com outros. Discord: Naze#3578 Ter Linux Dentro de Windows com Acesso 'localhost' para testes e + AutoLoot Otimizado Direto na Source (tfs 0.4/otx) // Pirataria é crime, original é roubo, compartilhar é legal.
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.