Ir para conteúdo
  • Cadastre-se

[TUTORIAL] Como Adicionar Novos Tipos De Pokemons. "Fairy"


Posts Recomendados

  • Respostas 14
  • Created
  • Última resposta

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

Hidden Content Give reaction to this post to see the hidden content. Hidden Content Give reaction to this post to see the hidden content. Hidden Content Give reaction to this post to see the hidden content. Hidden Content

ta e pro clan psycraft dar buff nele? @edited ja consegui...   Como fazer por pro clan da buff encima do fairy:   Vá a "Pasta Do Servidor > Data > Lib  e abra  "clan system"   e substitui o seu por esse:  

Posted Images

ta e pro clan psycraft dar buff nele?
@edited ja consegui...
 
Como fazer por pro clan da buff encima do fairy:
 
Vá a "Pasta Do Servidor > Data > Lib  e abra  "clan system"

 

e substitui o seu por esse:

 

  Mostrar conteúdo oculto

local clansAtk = {


[1] =     {
            [FIREDAMAGE] =     {
                                [1] = {atk = 1.17},
                                [2] = {atk = 1.22},
                                [3] = {atk = 1.27},
                                [4] = {atk = 1.32},
                                [5] = {atk = 1.37},
                            },
            ["null"] =          {
                            },
        },
[2] =     {
            [WATERDAMAGE] = {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
            [iCEDAMAGE] =   {
                                [1] = {atk = 1.10},
                                [2] = {atk = 1.15},
                                [3] = {atk = 1.20},
                                [4] = {atk = 1.25},
                                [5] = {atk = 1.30},
                            },
        },
[3] =     {
            [ROCKDAMAGE] =  {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
           [GROUNDDAMAGE] = {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
        },
[4] =     {
            [FLYDAMAGE] =      {
                                [1] = {atk = 1.15},
                                [2] = {atk = 1.20},
                                [3] = {atk = 1.25},
                                [4] = {atk = 1.30},
                                [5] = {atk = 1.38},
                            },
           [DRAGONDAMAGE] = {
                                [1] = {atk = 1.10},
                                [2] = {atk = 1.15},
                                [3] = {atk = 1.20},
                                [4] = {atk = 1.25},
                                [5] = {atk = 1.38},
                            },
        },
[5] =     {
           [GHOSTDAMAGE] =  {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
           [POISONDAMAGE] = {
                                [1] = {atk = 1.08},
                                [2] = {atk = 1.13},
                                [3] = {atk = 1.18},
                                [4] = {atk = 1.23},
                                [5] = {atk = 1.28},
                            },
        },
[6] =     {
            [FIGHTDAMAGE] = {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
           [NORMALDAMAGE] = {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
        },
[7] =     {
         [PSYCHICDAMAGE] =  {
                                [1] = {atk = 1.10},
                                [2] = {atk = 1.15},
                                [3] = {atk = 1.20},
                                [4] = {atk = 1.25},
                                [5] = {atk = 1.30},
                            },
           [FAIRYDAMAGE] =     {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
        },
[8] =     {
           [GRASSDAMAGE] =  {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
           [bUGDAMAGE] =     {
                                [1] = {atk = 1.05},
                                [2] = {atk = 1.10},
                                [3] = {atk = 1.15},
                                [4] = {atk = 1.20},
                                [5] = {atk = 1.25},
                            },
        },
[9] =     {
         [ELECTRICDAMAGE] = {
                                [1] = {atk = 1.12},
                                [2] = {atk = 1.17},
                                [3] = {atk = 1.22},
                                [4] = {atk = 1.27},
                                [5] = {atk = 1.32},
                            },
            ["null"] =         {
                            },
        }
}

local clansDef = {
[1] =     {
            ["fire"] =     {
                            [1] = {def = 0.17},
                            [2] = {def = 0.22},
                            [3] = {def = 0.27},
                            [4] = {def = 0.32},
                            [5] = {def = 0.37},
                        },
            ["null"] =  {
                        },
        },
[2] =   {
            ["water"] = {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
            ["ice"] =     {
                            [1] = {def = 0.10},
                            [2] = {def = 0.15},
                            [3] = {def = 0.20},
                            [4] = {def = 0.25},
                            [5] = {def = 0.30},
                        },
        },
[3] =    {
            ["rock"] =     {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
           ["ground"] = {
                            [1] = {def = 0.10},
                            [2] = {def = 0.15},
                            [3] = {def = 0.20},
                            [4] = {def = 0.25},
                            [5] = {def = 0.30},
                        },
        },
[4] =   {
          ["flying"] =  {
                            [1] = {def = 0.15},
                            [2] = {def = 0.20},
                            [3] = {def = 0.25},
                            [4] = {def = 0.30},
                            [5] = {def = 0.35},
                        },
           ["dragon"] = {
                            [1] = {def = 0.10},
                            [2] = {def = 0.15},
                            [3] = {def = 0.20},
                            [4] = {def = 0.25},
                            [5] = {def = 0.30},
                        },
        },
[5] =     {
            ["ghost"] = {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
           ["poison"] = {
                            [1] = {def = 0.08},
                            [2] = {def = 0.13},
                            [3] = {def = 0.18},
                            [4] = {def = 0.23},
                            [5] = {def = 0.28},
                        },
        },
[6] =   {
         ["fighting"] = {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
           ["normal"] = {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
        },
[7] =   {
          ["psychic"] = {
                            [1] = {def = 0.10},
                            [2] = {def = 0.15},
                            [3] = {def = 0.20},
                            [4] = {def = 0.25},
                            [5] = {def = 0.30},
                        },
            ["fairy"] =   {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
        },
[8] =   {
            ["grass"] = {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
            ["bug"] =   {
                            [1] = {def = 0.05},
                            [2] = {def = 0.10},
                            [3] = {def = 0.15},
                            [4] = {def = 0.20},
                            [5] = {def = 0.25},
                        },
        },
[9] =   {
        ["electric"] = {
                            [1] = {def = 0.12},
                            [2] = {def = 0.17},
                            [3] = {def = 0.22},
                            [4] = {def = 0.27},
                            [5] = {def = 0.32},
                        },
        }
}                        

local clansName = {
--[num do clan] = {nome do clan, storage outfit normal, storage outfit rank5},
[1] = {'Volcanic', 181613, 181625},
[2] = {'Seavell', 181619, 181622},
[3] = {'Orebound', 181620, 181627},
[4] = {'Wingeon', 181616, 181626},
[5] = {'Malefic', 181615, 181624},
[6] = {'Gardestrike', 181614, 181628},
[7] = {'Psycraft', 181618, 181629},
[8] = {'Naturia', 181612, 181623},
[9] = {'Raibolt', 181617, 181621},
}


function getClanPorcent(master, combat, option, type, type2)         --alterado v1.9 \/
if getPlayerClanNum(master) >= 1 then        
   local clanAtk = clansAtk[getPlayerClanNum(master)]
   local clanDef = clansDef[getPlayerClanNum(master)]

   if option == "atk" and clanAtk[combat] then
      return clanAtk[combat][getPlayerClanRank(master)].atk
   else
      if option == "def" and clanDef[type] then                                
         return clanDef[type][getPlayerClanRank(master)].def
      elseif option == "def" and clanDef[type2] then
         return clanDef[type2][getPlayerClanRank(master)].def
      end
   end
end
return option == "atk" and 1 or 0
end

function getPlayerClanName(cid)
if not isCreature(cid) then return 'No Clan!' end
return clansName[getPlayerClanNum(cid)] and clansName[getPlayerClanNum(cid)][1] or 'No Clan!'
end

function getPlayerClanNum(cid)
if not isCreature(cid) then return -1 end
return getPlayerStorageValue(cid, 86228)
end

function getPlayerClanRank(cid)
if not isCreature(cid) then return -1 end
return getPlayerStorageValue(cid, 862281)
end

function setPlayerClan(cid, clan)
if not isCreature(cid) or not clan then return false end
if removePlayerClan(cid) then  --para evitar possiveis problemas!
   if type(clan) == "number" and (clan >= 1 and clan <= 9) then
      setPlayerStorageValue(cid, 86228, clan)    --sto clan
      setPlayerClanRank(cid, 1)                  --set rank 1
      setPlayerStorageValue(cid, clansName[clan][2], 1)   --sto roupa
      return true
   elseif type(clan) == "string" then
      clan = string.lower(clan)
      for e, f in pairs(clansName) do
          local clan2 = string.lower(f[1])
          if clan == clan2 then
             setPlayerStorageValue(cid, 86228, e)  --sto clan
             setPlayerClanRank(cid, 1)             --set rank 1
             setPlayerStorageValue(cid, clansName[e][2], 1)   --sto roupa
             return true
          end
      end
   end
end
return false
end

function setPlayerClanRank(cid, rank)
if not isCreature(cid) or not rank then return false end
if type(rank) == "number" and (rank >= 1 and rank <= 5) then
   setPlayerStorageValue(cid, 862281, rank)
   if rank == 5 then
      setPlayerStorageValue(cid, clansName[getPlayerClanNum(cid)][3], 1)
   end
   return true
end
return false
end

function removePlayerClan(cid)
if not isCreature(cid) then return false end
if getPlayerStorageValue(cid, 854789) >= 1 then return false end --nao pode remover o clan se o player tiver fazendo missoes de rank!
   setPlayerStorageValue(cid, 86228, -1) --sto do clan
   setPlayerStorageValue(cid, 862281, -1) --sto do rank
   setPlayerStorageValue(cid, 854789, -1) --sto da quest de rank
   setPlayerStorageValue(cid, 854788, -1) --sto catch, quest de rank
   setPlayerStorageValue(cid, 854787, -1) --sto task, quest de rank
   for i = 181612, 181638 do
       setPlayerStorageValue(cid, i, -1)  --sto das roupas de clan
   end
return true
end    

function checkItensForTask(cid, itens)
local check = 0
local array = {}
local missing = {}
table.insert(missing, "Are missing: ")
local c = 0
    for i = 1, #itens do
        if getPlayerItemCount(cid, itens[1]) >= itens[2] then
           check = check + 1
        else
           table.insert(array, {itens[1], (itens[2]-getPlayerItemCount(cid, itens[1]))})
        end       
    end
if check == #itens then
   for b = 1, #itens do
       doPlayerRemoveItem(cid, itens[1], itens[2])
   end
   return 0
else
   for a = 1, #array do
       table.insert(missing, ((a == #array and c ~= 0) and " and " or a ~= 1 and ", " or "{")..(array[a][2]).." "..(getItemNameById(array[a][1])))
       c = c+1
   end
   table.insert(missing, "} yet.")
   return table.concat(missing)
end
end

function checkPokemonForTask(cid, poke)
local pbs = getPokeballsInContainer(getPlayerSlotItem(cid, 3).uid)
local slot = getPlayerSlotItem(cid, 8)
if slot.itemid > 0 and isPokeball(slot.itemid) then
   if getItemAttribute(slot.uid, "poke") == poke and getItemAttribute(slot.uid, "task") and getItemAttribute(slot.uid, "task") >= 1 then
      doRemoveItem(slot.uid, 1)
      doTransformItem(getPlayerSlotItem(cid, CONST_SLOT_LEGS).uid, 2395)
      return true
   end
end
for i = 1, #pbs do
    if getItemAttribute(pbs, "poke") == poke and getItemAttribute(pbs, "task") and getItemAttribute(pbs, "task") >= 1 then
      doRemoveItem(pbs, 1)
      return true
   end
end
return false
end     

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

Continue meu filho desobediente

Haverá paz quando você estiver terminado

Coloque sua cabeça cansada para descansar

Não chore mais

Link para o post
Compartilhar em outros sites
  Em 12/05/2015 em 14:49, xandeloko disse:

ta e pro clan psycraft dar buff nele?

@edited ja consegui...

 

Como fazer por pro clan da buff encima do fairy:

 

Vá a "Pasta Do Servidor > Data > Lib  e abra  "clan system"

 

e substitui o seu por esse:

 

  Mostrar conteúdo oculto

local clansAtk = {

[1] =     {

            [FIREDAMAGE] =     {

                                [1] = {atk = 1.17},

                                [2] = {atk = 1.22},

                                [3] = {atk = 1.27},

                                [4] = {atk = 1.32},

                                [5] = {atk = 1.37},

                            },

            ["null"] =          {

                            },

        },

[2] =     {

            [WATERDAMAGE] = {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

            [iCEDAMAGE] =   {

                                [1] = {atk = 1.10},

                                [2] = {atk = 1.15},

                                [3] = {atk = 1.20},

                                [4] = {atk = 1.25},

                                [5] = {atk = 1.30},

                            },

        },

[3] =     {

            [ROCKDAMAGE] =  {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

           [GROUNDDAMAGE] = {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

        },

[4] =     {

            [FLYDAMAGE] =      {

                                [1] = {atk = 1.15},

                                [2] = {atk = 1.20},

                                [3] = {atk = 1.25},

                                [4] = {atk = 1.30},

                                [5] = {atk = 1.38},

                            },

           [DRAGONDAMAGE] = {

                                [1] = {atk = 1.10},

                                [2] = {atk = 1.15},

                                [3] = {atk = 1.20},

                                [4] = {atk = 1.25},

                                [5] = {atk = 1.38},

                            },

        },

[5] =     {

           [GHOSTDAMAGE] =  {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

           [POISONDAMAGE] = {

                                [1] = {atk = 1.08},

                                [2] = {atk = 1.13},

                                [3] = {atk = 1.18},

                                [4] = {atk = 1.23},

                                [5] = {atk = 1.28},

                            },

        },

[6] =     {

            [FIGHTDAMAGE] = {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

           [NORMALDAMAGE] = {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

        },

[7] =     {

         [PSYCHICDAMAGE] =  {

                                [1] = {atk = 1.10},

                                [2] = {atk = 1.15},

                                [3] = {atk = 1.20},

                                [4] = {atk = 1.25},

                                [5] = {atk = 1.30},

                            },

           [FAIRYDAMAGE] =     {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

        },

[8] =     {

           [GRASSDAMAGE] =  {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

           [bUGDAMAGE] =     {

                                [1] = {atk = 1.05},

                                [2] = {atk = 1.10},

                                [3] = {atk = 1.15},

                                [4] = {atk = 1.20},

                                [5] = {atk = 1.25},

                            },

        },

[9] =     {

         [ELECTRICDAMAGE] = {

                                [1] = {atk = 1.12},

                                [2] = {atk = 1.17},

                                [3] = {atk = 1.22},

                                [4] = {atk = 1.27},

                                [5] = {atk = 1.32},

                            },

            ["null"] =         {

                            },

        }

}

local clansDef = {

[1] =     {

            ["fire"] =     {

                            [1] = {def = 0.17},

                            [2] = {def = 0.22},

                            [3] = {def = 0.27},

                            [4] = {def = 0.32},

                            [5] = {def = 0.37},

                        },

            ["null"] =  {

                        },

        },

[2] =   {

            ["water"] = {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

            ["ice"] =     {

                            [1] = {def = 0.10},

                            [2] = {def = 0.15},

                            [3] = {def = 0.20},

                            [4] = {def = 0.25},

                            [5] = {def = 0.30},

                        },

        },

[3] =    {

            ["rock"] =     {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

           ["ground"] = {

                            [1] = {def = 0.10},

                            [2] = {def = 0.15},

                            [3] = {def = 0.20},

                            [4] = {def = 0.25},

                            [5] = {def = 0.30},

                        },

        },

[4] =   {

          ["flying"] =  {

                            [1] = {def = 0.15},

                            [2] = {def = 0.20},

                            [3] = {def = 0.25},

                            [4] = {def = 0.30},

                            [5] = {def = 0.35},

                        },

           ["dragon"] = {

                            [1] = {def = 0.10},

                            [2] = {def = 0.15},

                            [3] = {def = 0.20},

                            [4] = {def = 0.25},

                            [5] = {def = 0.30},

                        },

        },

[5] =     {

            ["ghost"] = {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

           ["poison"] = {

                            [1] = {def = 0.08},

                            [2] = {def = 0.13},

                            [3] = {def = 0.18},

                            [4] = {def = 0.23},

                            [5] = {def = 0.28},

                        },

        },

[6] =   {

         ["fighting"] = {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

           ["normal"] = {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

        },

[7] =   {

          ["psychic"] = {

                            [1] = {def = 0.10},

                            [2] = {def = 0.15},

                            [3] = {def = 0.20},

                            [4] = {def = 0.25},

                            [5] = {def = 0.30},

                        },

            ["fairy"] =   {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

        },

[8] =   {

            ["grass"] = {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

            ["bug"] =   {

                            [1] = {def = 0.05},

                            [2] = {def = 0.10},

                            [3] = {def = 0.15},

                            [4] = {def = 0.20},

                            [5] = {def = 0.25},

                        },

        },

[9] =   {

        ["electric"] = {

                            [1] = {def = 0.12},

                            [2] = {def = 0.17},

                            [3] = {def = 0.22},

                            [4] = {def = 0.27},

                            [5] = {def = 0.32},

                        },

        }

}                        

local clansName = {

--[num do clan] = {nome do clan, storage outfit normal, storage outfit rank5},

[1] = {'Volcanic', 181613, 181625},

[2] = {'Seavell', 181619, 181622},

[3] = {'Orebound', 181620, 181627},

[4] = {'Wingeon', 181616, 181626},

[5] = {'Malefic', 181615, 181624},

[6] = {'Gardestrike', 181614, 181628},

[7] = {'Psycraft', 181618, 181629},

[8] = {'Naturia', 181612, 181623},

[9] = {'Raibolt', 181617, 181621},

}

function getClanPorcent(master, combat, option, type, type2)         --alterado v1.9 \/

if getPlayerClanNum(master) >= 1 then        

   local clanAtk = clansAtk[getPlayerClanNum(master)]

   local clanDef = clansDef[getPlayerClanNum(master)]

   if option == "atk" and clanAtk[combat] then

      return clanAtk[combat][getPlayerClanRank(master)].atk

   else

      if option == "def" and clanDef[type] then                                

         return clanDef[type][getPlayerClanRank(master)].def

      elseif option == "def" and clanDef[type2] then

         return clanDef[type2][getPlayerClanRank(master)].def

      end

   end

end

return option == "atk" and 1 or 0

end

function getPlayerClanName(cid)

if not isCreature(cid) then return 'No Clan!' end

return clansName[getPlayerClanNum(cid)] and clansName[getPlayerClanNum(cid)][1] or 'No Clan!'

end

function getPlayerClanNum(cid)

if not isCreature(cid) then return -1 end

return getPlayerStorageValue(cid, 86228)

end

function getPlayerClanRank(cid)

if not isCreature(cid) then return -1 end

return getPlayerStorageValue(cid, 862281)

end

function setPlayerClan(cid, clan)

if not isCreature(cid) or not clan then return false end

if removePlayerClan(cid) then  --para evitar possiveis problemas!

   if type(clan) == "number" and (clan >= 1 and clan <= 9) then

      setPlayerStorageValue(cid, 86228, clan)    --sto clan

      setPlayerClanRank(cid, 1)                  --set rank 1

      setPlayerStorageValue(cid, clansName[clan][2], 1)   --sto roupa

      return true

   elseif type(clan) == "string" then

      clan = string.lower(clan)

      for e, f in pairs(clansName) do

          local clan2 = string.lower(f[1])

          if clan == clan2 then

             setPlayerStorageValue(cid, 86228, e)  --sto clan

             setPlayerClanRank(cid, 1)             --set rank 1

             setPlayerStorageValue(cid, clansName[e][2], 1)   --sto roupa

             return true

          end

      end

   end

end

return false

end

function setPlayerClanRank(cid, rank)

if not isCreature(cid) or not rank then return false end

if type(rank) == "number" and (rank >= 1 and rank <= 5) then

   setPlayerStorageValue(cid, 862281, rank)

   if rank == 5 then

      setPlayerStorageValue(cid, clansName[getPlayerClanNum(cid)][3], 1)

   end

   return true

end

return false

end

function removePlayerClan(cid)

if not isCreature(cid) then return false end

if getPlayerStorageValue(cid, 854789) >= 1 then return false end --nao pode remover o clan se o player tiver fazendo missoes de rank!

   setPlayerStorageValue(cid, 86228, -1) --sto do clan

   setPlayerStorageValue(cid, 862281, -1) --sto do rank

   setPlayerStorageValue(cid, 854789, -1) --sto da quest de rank

   setPlayerStorageValue(cid, 854788, -1) --sto catch, quest de rank

   setPlayerStorageValue(cid, 854787, -1) --sto task, quest de rank

   for i = 181612, 181638 do

       setPlayerStorageValue(cid, i, -1)  --sto das roupas de clan

   end

return true

end    

function checkItensForTask(cid, itens)

local check = 0

local array = {}

local missing = {}

table.insert(missing, "Are missing: ")

local c = 0

    for i = 1, #itens do

        if getPlayerItemCount(cid, itens[1]) >= itens[2] then

           check = check + 1

        else

           table.insert(array, {itens[1], (itens[2]-getPlayerItemCount(cid, itens[1]))})

        end       

    end

if check == #itens then

   for b = 1, #itens do

       doPlayerRemoveItem(cid, itens[1], itens[2])

   end

   return 0

else

   for a = 1, #array do

       table.insert(missing, ((a == #array and c ~= 0) and " and " or a ~= 1 and ", " or "{")..(array[a][2]).." "..(getItemNameById(array[a][1])))

       c = c+1

   end

   table.insert(missing, "} yet.")

   return table.concat(missing)

end

end

function checkPokemonForTask(cid, poke)

local pbs = getPokeballsInContainer(getPlayerSlotItem(cid, 3).uid)

local slot = getPlayerSlotItem(cid, 8)

if slot.itemid > 0 and isPokeball(slot.itemid) then

   if getItemAttribute(slot.uid, "poke") == poke and getItemAttribute(slot.uid, "task") and getItemAttribute(slot.uid, "task") >= 1 then

      doRemoveItem(slot.uid, 1)

      doTransformItem(getPlayerSlotItem(cid, CONST_SLOT_LEGS).uid, 2395)

      return true

   end

end

for i = 1, #pbs do

    if getItemAttribute(pbs, "poke") == poke and getItemAttribute(pbs, "task") and getItemAttribute(pbs, "task") >= 1 then

      doRemoveItem(pbs, 1)

      return true

   end

end

return false

end     

Expand   Mostrar mais  

eu não utilizo esse clan system ai, por isso não tinha lembrado de colocar sobre ele, se importa se eu adicionar no meu post essa sua explicação?

darkrai.gif

A Vingança nunca é plena, mata a alma e envenena.
                                                      "Seu Madruga"
 
 
Não acredite na mentira, ela não é verdade.                                  
                         "Uma Pessoa do Facebook"
 
 
Se a força não esta funcionando, é porque você esta batendo fraco demais.
                                                                                    "Natsu Dragnell"
 
 
Pokemon Revolution 2015
 Facebook: https://www.facebook.com/PokemonRev?ref=ts&fref=ts
 
Sword Tibiart Online
Facebook: https://www.facebook.com/swordtibiartonline
 

tTAL2Wl.gif2z8t5ef.jpg

Link para o post
Compartilhar em outros sites

sem problemas

Continue meu filho desobediente

Haverá paz quando você estiver terminado

Coloque sua cabeça cansada para descansar

Não chore mais

Link para o post
Compartilhar em outros sites

O tópico foi movido para a área correta, preste mais atenção da próxima vez!

Leia as regras do fórum:

Hidden Content

    Give reaction to this post to see the hidden content.

Este tópico foi movido:

De: "OTServSuporte OTServSuporte de Servidores Derivados"

Para: "OTServScriptingTutoriais de Scripting"

Link para o post
Compartilhar em outros sites

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.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.

  • Conteúdo Similar

    • Por Johncore
      Open Source MMORPG emulador de Tibia escrito em C++.
      Servidor Oficial do Tibiaking!

       
       
        
       Novidades!
       
      - Protocolo 12.51
       
      - Bestiary
      - Charms
      - Boosted Creature
      - Quick Loot
      - Supply Stash
      - Event Schedule
      - GLOBAL MAP FULL
      - Quests com Quest Log 100%
      - Anti Rollback 100%
      - Source Optimizada
      - Sistema Anti WPE 100%
      - SUMMER UPDATE 2020 AND WINTER UPDATE 2020
      - Bounac
      - Wherehyenas
      - Mirrored Nightmare
      - Exercise Training 100%
      - Monstros 100%
      - Trainer Offline 100%
      - Trainer Online 100%
      - War System 100%
       
       

       
      Imagens :
       
      THAIS TEMPLE
       

       
       
      



      Downloads 

       
       Servidor + Database: 
       Download 
      »» PROJETO OFFICIAL:  GITHUB
       
      »» Distro + Dlls 64x
       otg-king_Distro_e_Dlls_Tibiaking.com.zip

       
      OTG Gesior
      GESIOR OFFICIAL CLIQUE AQUI

       

      MAP EDITOR 12.51
       
      - Remere's Map Editor 3.7.1 - Paletas atualizadas!
       
       
       
      - Remere's Map Editor 3.7.0: MediaFire (scan)
      - Items (.otb e .xml) do OTG King Otserv 12.51 https://github.com/Johncorex/otg-king/tree/master/data/items
       

       
      Créditos :
      The Forgotten Server
      OTG contribuidores
      OTX contribuidores
      Otbr contribuidores
      Johncore
      Erick Nunes
      Cjaker
      Leu
      Tibiaking
      Marson Schneider
      Erimyth
      Nolis
      Toninho
      Renan Ulian
      jzdj

       
       
      Grupo Whatsapp Official OTG (duvidas, chat):
      LINK
       
    • Por Johncore
      OTG-Premium-Version - 10x e 12.40 

      Agradecemos primeiramente ao Tibiaking pela oportunidade nos concedida,
      somos parceiros oficiais do Tibiaking.com melhor Forum Brasileiro!

       
        
      Especificações :
       
      - Maioria das Quests com Quest Log 100%
      - Anti Rollback 100% com tutorial
      - Source Optimizada (baixo consumo de CPU e memoria)
      - Sem Bug de Clonar dinheiro (Npcs Refeitos)
      - Sistema Anti WPE 100%
      - SUMMER UPDATE 2020 AND WINTER UPDATE 2020
      - New Falcons Bastion
      - New Asuras
      - Warzone 4,5,6 100%
      - Exercise Training 100%
      - Raids 100%
      - Monstros 100%
      - Trainer Offline 100%
      - Trainer Online 100%
      - Database Completa COMPATIVEL COM GESIOR MARCOMOA E OTG-GESIOR
      - War System 100%
      - Global Map FULL RL
       
       
      OBS: GESIOR OFFICIAL CLIQUE AQUI
       
       

      Imagens :
       
      THAIS TEMPLE
       

       
      FALCONS
       

       
      NEW ASURAS
       

       
      WZ 4,5,6

       

       

      
      Downloads : 
       
       GESIOR OFFICIAL:
      CLIQUE AQUI
       
       SERVIDOR + DATABASE:
       Download 
       
      PROJETO OFFICIAL:  GITHUB
       
      Grupo Whatsapp Official OTG (duvidas, chat):
      LINK
       
       
       

       Créditos :
      The Forgotten Server
      OTG contribuidores
      OTX contribuidores
      Otbr contribuidores
      Johncore
      Erick Nunes
      Leu
      Marcomoa
      Marson Schneider
      Leandro Baldissera
       
    • Por Under
      Após anos sem contribuir com um servidor fico feliz em lançar essa versão com muitas correções!

      Está versão é a versão OPEN_BETA.

      Que pode ser testada aqui. (Online até dia 25/05/2023)

      Foram corrigos muitos bugs e existem diversas melhorias em muitos dos sistemas existentes.

      Vocês podem encontrar as Libs que devem estar com uns 30% desses novos sistemas que foram adicionados e podem testar ou usar os códigos.

      O servidor esta online a 120+ dias, foi construído com XP 1 e bateu 66 Players Online.

      O ideal é usar este servidor em low rate.

      Atualizações

      Verifique a pagina do facebook para saber todas as atualizações!
      Se você curtiu acompanhe a pagina para acompanha o lançamento do jogo oficial!
       
      Importante
       

      A cada onda do nosso sistema de incursões, você terá a chance de encontrar um Pokémon Shiny raro e, após a terceira onda, um chefe shiny ainda mais raro aparecerá, oferecendo recompensas valiosas para os treinadores ousados o suficiente para enfrentá-lo.
      Utilize seus tokens de incursão para reiniciar o sistema e tentar novamente.

      Para saber sobre todas as novidades Por favor considere olhar nossa pagina,

      https://www.facebook.com/pokexadventure/photos
       
      Imagens
       
       
      Downloads

      Para configurar basta substituir a pasta data que você pode encontrar fazendo download da source, cole a pasta data baixa do Pokexadventure e divirta-se!

      Sources

      pokexadventure_open_beta_datapack.rar

      DLLS + Executaveis (Windows)

      OTC
       
      (mediafire.com)
       
      Website
       
      https://github.com/otsoft/myaac

      Ferramentas : 
      auto_restarter_windows.bat

      RME 3.5 ou superior.

      Object builder 10.98 Support ou superior.

      Item editor 10.98 Support ou superior.

      Tutoriais para Compilações
       

      Créditos : @Underewar @pota
    • Por pota
      Desenvolvi por muito tempo uma base Pokémon do 0 (parti do TFS 1.2 e fui implementando tudo até chegar nessa versão que estou disponibilizando). O resultado é um servidor extremamente leve e estável (já testado com 100+ players e por mais de 1 mês sem cair). Basicamente, ele suporta tranquilamente 1k+ players e não tem nenhum bug conhecido que faça com que ele caia.
       
      Esse servidor ficou no ar por muito tempo (mais de 2 anos) e era conhecido como PokeDash. Acabei ficando sem tempo para administrar o servidor, o que fez com que a maioria dos players parassem de jogar e com que eu fechasse de vez.
       
      Pensei por muito tempo sobre o que fazer com ele, e decidi disponibilizar para a comunidade. Trata-se de algo único (eu ao menos nunca vi um servidor de Pokémon construído a partir do TFS 1.2)!
       
      Como desenvolvi todos os sistemas do 0, tomei cuidado para fazer tudo da melhor maneira possível e para que possa ser facilmente modificado e atualizado. Basicamente, os Pokémons podem ser criados a partir de um único arquivo XML (como monstros do Tibia), e nesse arquivo você pode especificar tudo, desde level máximo e mínimo de spawn, loots, tipos (fogo, agua, etc), se ele pode usar habilidades (surf, fly, etc), moves (quando alguém captura), ataques (quando selvagem), evoluções, chance de catch, etc.
      Exemplo de Pokemon
      Resumo de alguns sistemas (tem muita coisa, então coloquei os principais)
      ✅ Pokemons com level, status e boost. O level do player/boost também influencia no status dos pokes.
      ✅ Sistema de Love (seu poke fica mais forte que os demais quando upa de level matando pokemons mais fortes que ele).
      ✅ Base propria com Shinys e Ancients.
      ✅ Cada player pode conseguir ancient stone para evoluir 1 shiny para ancient através de quest.
      ✅ Moves bar e pokemon bar (troca de pokemon com 1 click).
      ✅ Autoloot agrupando em bags.
      ✅ Ganho de exp ao capturar/dar dex em pokes com um bonus adicional para o primeiro catch de cada poke.
      ✅ Mapa original com mais de 40 quests, incluindo outland com Ancients.
      ✅ Eventos diários automáticos: Futebol todo dia 19:30, arena PVP todo dia 20:00, golden arena aos sabados 17:00, bag premiada aos domingos/feriados 17:00.
      ✅ Profissões (facilmente customizáveis):
      Catcher: 3.5% mais chance de capturar um Pokemon. Hunter: 10% mais status de dano para o seu Pokemon (tanto magico quanto fisico). Blocker: 25% mais vida para seus Pokemons. Healer: 100% mais cura que aplica tanto em potions quando moves dos seus Pokemons. Explorer: 15% mais experiencia para seu personagem durante a caça. ✅ Task diária de catch/loot dando Tokens. Os tokens podem ser trocados por itens raros (dentre eles premier ball e bags personalizadas) além de pagar seu curso com o NPC Job Manager para aprender uma das profissões acima. Uma das maneiras de conseguir tokens é fazendo tasks diárias.
      ✅ Muito mais!
      Screenshots

       

      Download
      Baixe o pack contendo o servidor, cliente, site, editor de mapa e editor de itens clique aqui!. Caso considere minha contribuição interessante para a comunidade, considere realizar uma doação para a chave pix: server.pokedash@gmail.com
      GM account: gm/gmgmgm
      O projeto será atualizado em sua homepage: https://pokedashpota.vercel.app/
       
      SCAN
       
      ---EDIT---
      Download sources
      SCAN
       
       Problemas e soluções
      GroupID não existe ao tentar logar no server.
       
      Erros ao importar o schema.sql.
       
      Comando /cb não funcionando:
       
    • Por Valakinhas
      • Menu:
      ├ Informações; ├ Lista dos sistemas; ├ Erros; ├ Erros Solved; ├ Prints; ├ Download; └ Creditos.   • Informações; Sem level system Base Dash v6  Source      • Lista dos sistemas    
       
       
      • Erros
       
       
       
       
      • Erros Fixed
       
       
        • Prints  
       
       
       
      Detalhes adicionais
       
       
       
       
       
      Conta do GOD
       
       
       
       
      Download e Scanner
       
       
       
       
       
      Creditos
       
      Bruno123
      aberos
      snix 
  • Estatísticas dos Fóruns

    96841
    Tópicos
    519578
    Posts



×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo