Tente assim:
function onCombat(cid, target)
if (isPlayer(cid) and isPlayer(target)) then
if (getPlayerVocation(cid) == getPlayerVocation(target)) then
doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUMAYNOTATTACKTHISPLAYER)
return false
else
return true
end
else
return true
end
return true
end
O script n tinha erros aparentes... Tenta o q eu mandei.
flw





info
Grupo: Campones
Registrado: 27/08/08
Posts: 57
Reputação: +6
eu e eu amigo bolamos esse script com o proposito q os players n possão atakar outros players da mesma vocação mas qando apliquei ao servidor ningem consigia atkar ningem
PF me ajudem Obrigado
function onCombat(cid, target) if (isPlayer(cid) and isPlayer(target)) then if (getPlayerVocation(cid) == getPlayerVocation(target)) then doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUMAYNOTATTACKTHISPLAYER) return false end end return true endcreaturescript.xml
login.lua