Ir para conteúdo

Posts Recomendados

Como funciona?

 

Ele previne que um player puxe outro player enquanto ele está treinando ou atacando um monstro.

 

COLOQUE TUDO EM CREATURESCRIPTS

 

creaturescripts.xml

 

 

 

XML Code:

 

<event type="push" name="Anti-Push" event="script" value="anti-push.lua"/>

 

 

 

login.lua

 

 

 

Lua Code:

 

registerCreatureEvent(cid, "Anti-Push")

 

 

 

anti-push.lua

 

 

 

Lua Code:

 

local targetList, GAMEMASTER = {"Target Dummy"}, 5

function onPush(cid, target)

if(getPlayerAccess(cid) < GAMEMASTER) then

if((target ~= cid and isPlayer(target)) and (getCreatureTarget(target) > 0 and isInArray(targetList, getCreatureName(getCreatureTarget(target)):lower()))) then

doPlayerSendCancel(cid, "You cannot move this object.")

return false

end

end

 

return true

end

Link para o comentário
https://xtibia.com/forum/topic/191465-anti-push/
Compartilhar em outros sites

Tópico mal formulado, alem do mais esse script foi feito por J.Dre, ou seja poste os devidos créditos.

 

Segue o link do tópico verdadeiro: http://otland.net/f82/anti-push-159029/

Link para o comentário
https://xtibia.com/forum/topic/191465-anti-push/#findComment-1311102
Compartilhar em outros sites

×
×
  • Criar Novo...