Ir para conteúdo

Featured Replies

  • Respostas 25
  • Visualizações 1.9k
  • Created
  • Última resposta

Top Posters In This Topic

Postado
  • Autor

Como funciona pra decidir se é vermelho ou verde o time ?

Não sei amigo eu peguei o script e coloquei sei que ele balancei  exemplo tem 1 red ai loga mais 1 entra como green !

 

joadson char nem loga

 

[Error - CreatureScript Interface] 
[27/04/2013 16:50:30] data/creaturescripts/scripts/loginTeam.lua:onLogin
[27/04/2013 16:50:30] Description: 
[27/04/2013 16:50:30] attempt to index a nil value
[27/04/2013 16:50:30] stack traceback:
[27/04/2013 16:50:30] [C]: in function 'doTeleportThing'
[27/04/2013 16:50:30] data/creaturescripts/scripts/loginTeam.lua:35: in function <data/creaturescripts/scripts/loginTeam.lua:17>
[27/04/2013 16:50:30] Mickfern has logged out.

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

Mais vale a lagrima da derrota doque a Covardia de não ter lutado , Prefiro morrer de Pé do que sempre viver ajoelhado.

Kaio santos "soldier killed"

Postado

Troca o arquivo do script por esse e REINICIA O SERVER

 

local config = {
    storageTeamOne = 68473,
    storageTeamTwo = 68474,
    teamOne = { outfitMale =  {lookType = 128, lookHead = 94, lookBody = 94, lookLegs = 94, lookFeet = 94}, -- 94 representa a cor vermelha.
                outfitFemale =  {lookType = 136, lookHead = 94, lookBody = 94, lookLegs = 94, lookFeet = 94},
                templeId = 1
              },
    teamTwo = { outfitMale =  {lookType = 128, lookHead = 82, lookBody = 82, lookLegs = 82, lookFeet = 82}, -- 82 representa a cor verde.
                outfitFemale =  {lookType = 136, lookHead = 82, lookBody = 82, lookLegs = 82, lookFeet = 82},
                templeId = 2
              }
}
 
function onLogin(cid)
local vermelho = getGlobalStorageValue(config.teamOne)
local verde = getGlobalStorageValue(config.storageTeamTwo)
if vermelho > verde then
    if getPlayerSex(cid) == 0 then
        doCreatureChangeOutfit(cid, config.teamTwo.outfitFemale)
    else
        doCreatureChangeOutfit(cid, config.teamTwo.outfitMale)
    end  
    doTeleportThing(cid, {x = 965, y = 1012, y = z})
    setGlobalStorageValue(config.storageTeamTwo, verde+1)
    setPlayerStorageValue(cid, config.storageTeamTwo, 1)
else
    if getPlayerSex(cid) == 0 then
        doCreatureChangeOutfit(cid, config.teamOne.outfitFemale)
    else
        doCreatureChangeOutfit(cid, config.teamOne.outfitMale)
    end  
    doTeleportThing(cid, {x = 1030, y = 1012, z = 7})
    setGlobalStorageValue(config.teamOne, vermelho+1)
    setPlayerStorageValue(cid, config.teamOne, 1)
end
registerCreatureEvent(cid, "LogoutTeam")
registerCreatureEvent(cid, "DeathTeam")
return true
end
 
function onDeath(cid, corpse, deathList)
if getPlayerStorageValue(cid, config.storageTeamTwo) == 1 then
    setPlayerStorageValue(cid, config.storageTeamTwo, 0)
    setGlobalStorageValue(config.storageTeamTwo, getGlobalStorageValue(config.storageTeamTwo)-1)
else
    setPlayerStorageValue(cid, config.teamOne, 0)
    setGlobalStorageValue(config.teamOne, getGlobalStorageValue(config.teamOne)-1)
end
return true
end
 
function onLogout(cid)
if getPlayerStorageValue(cid, config.storageTeamTwo) == 1 then
    setPlayerStorageValue(cid, config.storageTeamTwo, 0)
    setGlobalStorageValue(config.storageTeamTwo, getGlobalStorageValue(config.storageTeamTwo)-1)
else
    setPlayerStorageValue(cid, config.teamOne, 0)
    setGlobalStorageValue(config.teamOne, getGlobalStorageValue(config.teamOne)-1)
end
return true
end

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

Dp9Y7vq.png

Postado
  • Autor

Troca o arquivo do script por esse e REINICIA O SERVER

 

local config = {
    storageTeamOne = 68473,
    storageTeamTwo = 68474,
    teamOne = { outfitMale =  {lookType = 128, lookHead = 94, lookBody = 94, lookLegs = 94, lookFeet = 94}, -- 94 representa a cor vermelha.
                outfitFemale =  {lookType = 136, lookHead = 94, lookBody = 94, lookLegs = 94, lookFeet = 94},
                templeId = 1
              },
    teamTwo = { outfitMale =  {lookType = 128, lookHead = 82, lookBody = 82, lookLegs = 82, lookFeet = 82}, -- 82 representa a cor verde.
                outfitFemale =  {lookType = 136, lookHead = 82, lookBody = 82, lookLegs = 82, lookFeet = 82},
                templeId = 2
              }
}
 
function onLogin(cid)
local vermelho = getGlobalStorageValue(config.teamOne)
local verde = getGlobalStorageValue(config.storageTeamTwo)
if vermelho > verde then
    if getPlayerSex(cid) == 0 then
        doCreatureChangeOutfit(cid, config.teamTwo.outfitFemale)
    else
        doCreatureChangeOutfit(cid, config.teamTwo.outfitMale)
    end  
    doTeleportThing(cid, {x = 965, y = 1012, y = z})
    setGlobalStorageValue(config.storageTeamTwo, verde+1)
    setPlayerStorageValue(cid, config.storageTeamTwo, 1)
else
    if getPlayerSex(cid) == 0 then
        doCreatureChangeOutfit(cid, config.teamOne.outfitFemale)
    else
        doCreatureChangeOutfit(cid, config.teamOne.outfitMale)
    end  
    doTeleportThing(cid, {x = 1030, y = 1012, z = 7})
    setGlobalStorageValue(config.teamOne, vermelho+1)
    setPlayerStorageValue(cid, config.teamOne, 1)
end
registerCreatureEvent(cid, "LogoutTeam")
registerCreatureEvent(cid, "DeathTeam")
return true
end
 
function onDeath(cid, corpse, deathList)
if getPlayerStorageValue(cid, config.storageTeamTwo) == 1 then
    setPlayerStorageValue(cid, config.storageTeamTwo, 0)
    setGlobalStorageValue(config.storageTeamTwo, getGlobalStorageValue(config.storageTeamTwo)-1)
else
    setPlayerStorageValue(cid, config.teamOne, 0)
    setGlobalStorageValue(config.teamOne, getGlobalStorageValue(config.teamOne)-1)
end
return true
end
 
function onLogout(cid)
if getPlayerStorageValue(cid, config.storageTeamTwo) == 1 then
    setPlayerStorageValue(cid, config.storageTeamTwo, 0)
    setGlobalStorageValue(config.storageTeamTwo, getGlobalStorageValue(config.storageTeamTwo)-1)
else
    setPlayerStorageValue(cid, config.teamOne, 0)
    setGlobalStorageValue(config.teamOne, getGlobalStorageValue(config.teamOne)-1)
end
return true
end

Nossa não deu ta foda !

Mais vale a lagrima da derrota doque a Covardia de não ter lutado , Prefiro morrer de Pé do que sempre viver ajoelhado.

Kaio santos "soldier killed"

  • 8 months later...
Postado

O Meu Script Funfa é pra ot war que troca acada 20 minutos o mapa

 

Mais eu queria saber aonde troca a roupa da team?!?

 

Queria Verde vs preto xD

 

Não SEI SE VAI PEGAR ENTAO NAO FALA MERDA

 

 

local config = {

loginMessage = getConfigValue('loginMessage'),
useFragHandler = getBooleanFromString(getConfigValue('useFragHandler'))
}
 
function onLogin(cid)
    setTeam(cid)
 
local loss = getConfigValue('deathLostPercent')
if(loss ~= nil) then
doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10)
doPlayerAddBlessing(cid, 1)
doPlayerAddBlessing(cid, 2)
doPlayerAddBlessing(cid, 3)
doPlayerAddBlessing(cid, 4)
doPlayerAddBlessing(cid, 5)
 
end
 
local accountManager = getPlayerAccountManager(cid)
if(accountManager == MANAGER_NONE) then
local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage
if(lastLogin > 0) then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "."
else
str = str .. " Please choose your outfit."
doPlayerSendOutfitWindow(cid)
end
 
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
elseif(accountManager == MANAGER_NAMELOCK) then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, it appears that your character has been namelocked, what would you like as your new name?")
elseif(accountManager == MANAGER_ACCOUNT) then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to manage your account and if you want to start over then type 'cancel'.")
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to create an account or type 'recover' to recover an account.")
end
 
if(not isPlayerGhost(cid)) then
doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)
end
 
registerCreatureEvent(cid, "Mail")
registerCreatureEvent(cid, "GuildMotd")
registerCreatureEvent(cid, "fragReward")
registerCreatureEvent(cid, "FragReward")
     registerCreatureEvent(cid, "deathBroadcast")
     registerCreatureEvent(cid, "DeathBroadcast")
 
registerCreatureEvent(cid, "Idle")
if(config.useFragHandler) then
registerCreatureEvent(cid, "SkullCheck")
end
 
return true
end
 

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

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

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.7k

Informação Importante

Confirmação de Termo