Ir para conteúdo
  • Cadastre-se

Posts Recomendados

ASSIM EU TAVA EDITANDO NO MEU SERVE COLOKEI UNS SISTEMA AI TALS AI QUANDO EU FUI TESTA O SERVE TAVA PERFEITO MAIS QUANDO EU FUI TESTA SE OS PLAYER SE ATAKAVA AI ELE NÃO SE ATAKA ALGEM PODE AJUDA PRA EU COLOKA PRA ATAKA?

Link para o post
Compartilhar em outros sites

ele 8.6 ai quando eu tento ataka  aparesse isso 

 

                                        sorry.not possible

 

la em baixo do meio 

Link para o post
Compartilhar em outros sites

mano eu axo que encontrei o erro eu axo que é aki eu vo marca de vermelho

 

esse script é do sistema  Battlefield Event! 

 

e tem isso la creaturescripts.xml

 

<event type="combat" name="BattleTeam" event="script" value="BattleCreatureScript.lua"/>

 

BattleCreatureScript.lua
function onLogin(cid)
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
registerCreatureEvent(cid, "BattleTeam")
registerCreatureEvent(cid, "BattleDeath")
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 then
doPlayerSendCancel(cid, "You may not attack your team mates.") return false
end
if getPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage) == 1 and getPlayerStorageValue(target, _Lib_Battle_Info.TeamTwo.storage) == 1 then
doPlayerSendCancel(cid, "You may not attack your team mates.") return false
end

return true
end
return true
end
function onPrepareDeath(cid, deathList, lastHitKiller, mostDamageKiller)
if getPlayerStorageValue(cid, _Lib_Battle_Info.TeamOne.storage) >= 1 then
setPlayerStorageValue(cid, _Lib_Battle_Info.TeamOne.storage, -1)
setGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage, getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage)-1)
doRemoveCondition(cid, CONDITION_OUTFIT)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "[battle Field] You Are Dead!")
if getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage) == 0 then
getWinnersBattle(_Lib_Battle_Info.TeamTwo.storage)
else
doBroadCastBattle(23,"[battleField Information] ".._Lib_Battle_Info.TeamOne.name.." "..getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage).." VS "..getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage).." " .._Lib_Battle_Info.TeamTwo.name)
end
elseif getPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage) >= 1 then
setPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage, -1)
setGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage, getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage)-1)
doRemoveCondition(cid, CONDITION_OUTFIT)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "[battle Field] You Are Dead!")
if getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage) == 0 then
getWinnersBattle(_Lib_Battle_Info.TeamOne.storage)
else
doBroadCastBattle(23,"[battleField Information] ".._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

Editado por macalo (veja o histórico de edições)

Link para o post
Compartilhar em outros sites

a  e tem outro evento [CTF] Capture The Flag 2.0(Automático)

 

ai tem esse event 

 

<event type="combat" name="CTFCombat" event="script" value="CTFMax.lua"/>      <!-- CTF by MaXwELlDeN -->

 

 

--[[

Capture The Flag System
Author: Maxwell Denisson(MaXwEllDeN)
Version: 2.0
]]
 
 
local CTF = CTF_LIB
 
function onStatsChange(cid, attacker, type, combat, value)
if getPlayerStorageValue(cid, 16700) ~= -1 and type == 1 and getCreatureHealth(cid) - value <= 0 then
if getPlayerStorageValue(cid, 16702) ~= -1 then
CTF.returnFlag(cid, 1)
end
 
doCreatureAddHealth(cid, getCreatureMaxHealth(cid))
doCreatureAddMana(cid, getCreatureMaxMana(cid))
doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid)))
return false
end
 
return true
end
 
function onLogout(cid)
if getPlayerStorageValue(cid, 16700) ~= -1 then
CTF.removePlayer(cid)
end
 
   return true
end
 
function onCombat(cid, target)
if getPlayerStorageValue(cid, 16700) ~= -1 then
if getPlayerStorageValue(cid, 16700) == getPlayerStorageValue(target, 16700) then
return false
end
end
 
return true
end
 
function onAttack(cid, target)
if getPlayerStorageValue(cid, 16700) ~= -1 then
if getPlayerStorageValue(cid, 16700) == getPlayerStorageValue(target, 16700) then
return false
end
end
 
return true
end

Link para o post
Compartilhar em outros sites

Olá, bom dia.

 

Colega, penso que a questão é outra.

 

Funciona da Seguinte Maneira:
 

PvP:

 worldType = "pvp"

No-PvP

worldType = "Optional"

PvP-Enforced

worldType = "Hardcore"

Confira se funciona e volte aqui.

Ah, confira se os "players" não estão em uma área no-pvp também.

 

Abraço.

Editado por Xagah (veja o histórico de edições)

5YkRF3w.gif

 

 

 

 

 

 

CzysZUR.gifytaam6k.png

 

 

Link para o post
Compartilhar em outros sites
  • 6 months later...

OLHE A SETA QUE E FIZ .... TROQUE PARA TRUE  PARA PODER ATACAR !!!

 

 

function onLogin(cid)
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
registerCreatureEvent(cid, "BattleTeam")
registerCreatureEvent(cid, "BattleDeath")
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 then
doPlayerSendCancel(cid, "You may not attack your team mates.") return false     <-------------------------------------------------------------------- troque para true
end
if getPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage) == 1 and getPlayerStorageValue(target, _Lib_Battle_Info.TeamTwo.storage) == 1 then
doPlayerSendCancel(cid, "You may not attack your team mates.") return false     <--------------------------------------------------------------------- troque para true
end
return true
end
return true
end
function onPrepareDeath(cid, deathList, lastHitKiller, mostDamageKiller)
if getPlayerStorageValue(cid, _Lib_Battle_Info.TeamOne.storage) >= 1 then
setPlayerStorageValue(cid, _Lib_Battle_Info.TeamOne.storage, -1)
setGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage, getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage)-1)
doRemoveCondition(cid, CONDITION_OUTFIT)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "[battle Field] You Are Dead!")
if getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage) == 0 then
getWinnersBattle(_Lib_Battle_Info.TeamTwo.storage)
else
doBroadCastBattle(23,"[battleField Information] ".._Lib_Battle_Info.TeamOne.name.." "..getGlobalStorageValue(_Lib_Battle_Info.TeamOne.storage).." VS "..getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage).." " .._Lib_Battle_Info.TeamTwo.name)
end
elseif getPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage) >= 1 then
setPlayerStorageValue(cid, _Lib_Battle_Info.TeamTwo.storage, -1)
setGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage, getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage)-1)
doRemoveCondition(cid, CONDITION_OUTFIT)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "[battle Field] You Are Dead!")
if getGlobalStorageValue(_Lib_Battle_Info.TeamTwo.storage) == 0 then
getWinnersBattle(_Lib_Battle_Info.TeamOne.storage)
else
doBroadCastBattle(23,"[battleField Information] ".._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

 

 

 

SE AJUDEI REP+  :)

Link para o post
Compartilhar em outros sites
  • 6 years later...

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.

Visitante
Responder

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo