Postado Fevereiro 4, 2016 9 anos olá galera do tibia king, estou aqui denovo com uma duvida adicionei um sistema no meu otserver, e ele usa uma certa 'STORAGE' gostaria de saber, como eu faço para colocar essa STORAGE '11548' em todos os players já estão criados no meu server, incluindo o ACCOUNT MANAGER, OS SAMPLES, no caso tenho site, e uso gesior e no caso, de alguem criar também o 'CHARACTER' nascer já com essa STORAGE alguem poderia me ajudar, ? reputarei quem puder me dar uma força para resolver o problema grato deis de já a todos que ajudarem @Xagah Editado Fevereiro 4, 2016 9 anos por Micheel15 (veja o histórico de edições)
Postado Fevereiro 4, 2016 9 anos Penso ser possível realizar o que deseja por meio do 'script' 'first items'. Você o utiliza? The Last Man Standing - 100% funcional
Postado Fevereiro 4, 2016 9 anos Autor @Xagah meu first item é assim : local firstItems = {} firstItems[0] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } firstItems[1] = { 2173, 2525, 2190, 2124, 2460, 2478, 2643 } firstItems[2] = { 2173, 2525, 2182, 2124, 2460, 2478, 2643 } firstItems[3] = { 2173, 2525, 2389, 2124, 2460, 2478, 2643 } firstItems[4] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } function onLogin(cid) if getPlayerStorageValue(cid, 30001) == -1 then for i = 1, table.maxn(firstItems[getPlayerVocation(cid)]) do doPlayerAddItem(cid, firstItems[getPlayerVocation(cid)], 1) end if getPlayerSex(cid) == 0 then doPlayerAddItem(cid, 2465, 1) else doPlayerAddItem(cid, 2465, 1) end local bag = doPlayerAddItem(cid, 10518, 1) doAddContainerItem(bag, 2554, 1) doAddContainerItem(bag, 2120, 1) doAddContainerItem(bag, 7618, 1) doAddContainerItem(bag, 2383, 1) setPlayerStorageValue(cid, 30001, 1) end return TRUE end
Postado Fevereiro 4, 2016 9 anos Em 04/02/2016 em 17:50, Micheel15 disse: @Xagah meu first item é assim : local firstItems = {} firstItems[0] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } firstItems[1] = { 2173, 2525, 2190, 2124, 2460, 2478, 2643 } firstItems[2] = { 2173, 2525, 2182, 2124, 2460, 2478, 2643 } firstItems[3] = { 2173, 2525, 2389, 2124, 2460, 2478, 2643 } firstItems[4] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } function onLogin(cid) if getPlayerStorageValue(cid, 30001) == -1 then for i = 1, table.maxn(firstItems[getPlayerVocation(cid)]) do doPlayerAddItem(cid, firstItems[getPlayerVocation(cid)], 1)endif getPlayerSex(cid) == 0 thendoPlayerAddItem(cid, 2465, 1)elsedoPlayerAddItem(cid, 2465, 1)endlocal bag = doPlayerAddItem(cid, 10518, 1)doAddContainerItem(bag, 2554, 1)doAddContainerItem(bag, 2120, 1)doAddContainerItem(bag, 7618, 1)doAddContainerItem(bag, 2383, 1)setPlayerStorageValue(cid, 30001, 1)endreturn TRUEend tente com este aqui amigo local firstItems = {} firstItems[0] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } firstItems[1] = { 2173, 2525, 2190, 2124, 2460, 2478, 2643 } firstItems[2] = { 2173, 2525, 2182, 2124, 2460, 2478, 2643 } firstItems[3] = { 2173, 2525, 2389, 2124, 2460, 2478, 2643 } firstItems[4] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } function onLogin(cid) if getPlayerStorageValue(cid, 30001) == -1 then for i = 1, table.maxn(firstItems[getPlayerVocation(cid)]) do doPlayerAddItem(cid, firstItems[getPlayerVocation(cid)], 1) end if getPlayerSex(cid) == 0 then doPlayerAddItem(cid, 2465, 1) else doPlayerAddItem(cid, 2465, 1) end local bag = doPlayerAddItem(cid, 10518, 1) doAddContainerItem(bag, 2554, 1) doAddContainerItem(bag, 2120, 1) doAddContainerItem(bag, 7618, 1) doAddContainerItem(bag, 2383, 1) setPlayerStorageValue(cid, 30001, 1) setPlayerStorageValue(cid, 11548, 1) end return TRUE end
Postado Fevereiro 4, 2016 9 anos Não testado. local firstItems = {} firstItems[0] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } firstItems[1] = { 2173, 2525, 2190, 2124, 2460, 2478, 2643 } firstItems[2] = { 2173, 2525, 2182, 2124, 2460, 2478, 2643 } firstItems[3] = { 2173, 2525, 2389, 2124, 2460, 2478, 2643 } firstItems[4] = { 2173, 2525, 2428, 2124, 2460, 2478, 2643 } function onLogin(cid) if getPlayerStorageValue(cid, 11548) == -1 then setPlayerStorageValue(cid, 11548, 1) end if getPlayerStorageValue(cid, 30001) == -1 then for i = 1, table.maxn(firstItems[getPlayerVocation(cid)]) do doPlayerAddItem(cid, firstItems[getPlayerVocation(cid)], 1) end if getPlayerSex(cid) == 0 then doPlayerAddItem(cid, 2465, 1) else doPlayerAddItem(cid, 2465, 1) end local bag = doPlayerAddItem(cid, 10518, 1) doAddContainerItem(bag, 2554, 1) doAddContainerItem(bag, 2120, 1) doAddContainerItem(bag, 7618, 1) doAddContainerItem(bag, 2383, 1) setPlayerStorageValue(cid, 30001, 1) end return TRUE end Nós somos aquilo que fazemos repetidamente. Excelência, não é um modo de agir, mas um hábito. Aristóteles
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.