
bunda321
Membro
-
Registro em
-
Última visita
Histórico de Curtidas
-
bunda321 recebeu reputação de nicholas1q em [SHOPP] Systen bugado!RESOLVI MEU PROBLEMA USEI ESSE shop.lua apaguei o meu e coloquei esse
-- ### CONFIG ### -- time (in seconds) between connections to SQL database by shop script SQL_interval = 30 -- ### END OF CONFIG ### function onThink(interval, lastExecution) local result_plr = db.storeQuery("SELECT * FROM z_ots_comunication") if result_plr ~= false then repeat local id = tonumber(result.getDataInt(result_plr, "id")) local action = tostring(result.getDataString(result_plr, "action")) local delete = tonumber(result.getDataInt(result_plr, "delete_it")) local player = Player(tostring(result.getDataString(result_plr, "name"))) if player then local itemtogive_id = tonumber(result.getDataInt(result_plr, "param1")) local itemtogive_count = tonumber(result.getDataInt(result_plr, "param2")) local container_id = tonumber(result.getDataInt(result_plr, "param3")) local container_count = tonumber(result.getDataInt(result_plr, "param4")) local add_item_type = tostring(result.getDataString(result_plr, "param5")) local add_item_name = tostring(result.getDataString(result_plr, "param6")) local received_item = 0 local full_weight = 0 local itemType = ItemType(itemtogive_id) if add_item_type == 'container' then if itemType:isRune() then items_weight = container_count * itemType:getWeight() else items_weight = container_count * itemType:getWeight(itemtogive_count) end full_weight = items_weight + ItemType(container_id):getWeight() else if itemType:isRune() then full_weight = itemType:getWeight() else full_weight = itemType:getWeight(itemtogive_count) end end local free_cap = player:getFreeCapacity() if full_weight <= free_cap then if add_item_type == 'container' then local new_container = Game.createItem(container_id, 1) local iter = 0 while iter ~= container_count do new_container:addItem(itemtogive_id, itemtogive_count) iter = iter + 1 end received_item = player:addItemEx(new_container) else local new_item = Game.createItem(itemtogive_id, itemtogive_count) received_item = player:addItemEx(new_item) end if type(received_item) == 'number' and received_item == RETURNVALUE_NOERROR then player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, 'You received >> '.. add_item_name ..' << from OTS shop.') db.query("DELETE FROM `z_ots_comunication` WHERE `id` = " .. id .. ";") db.query("UPDATE `z_shop_history_item` SET `trans_state`='realized', `trans_real`=" .. os.time() .. " WHERE id = " ..id .. ";") else player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, '>> '.. add_item_name ..' << from OTS shop is waiting for you. Please make place for this item in your backpack/hands and wait about '.. SQL_interval ..' seconds to get it.') end else player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, '>> '.. add_item_name ..' << from OTS shop is waiting for you. It weight is '.. full_weight ..' oz., you have only '.. free_cap ..' oz. free capacity. Put some items in depot and wait about '.. SQL_interval..' seconds to get it.') end end until not result.next(result_plr) result.free(result_plr) end return true end
e agora esta tudo 100%, topico resolvido -
bunda321 deu reputação a luanluciano93 em [TFS 1.x] Mount DollOlá pessoal, para quem não sabe esse script funciona da seguinte maneira, você escolhe um X item, e se o player tiver esse X item, e falar !mount [nome da mount] ele ganha a mount que ele escolheu.
Crie um arquivo com o nome mountdoll.lua em talkactions/scripts e coloque isso dentro:
local mounts = { --["mount"] = {id = x}, ["widow queen"] = {id = 1} } function onSay(player, words, param) local word = mounts[string.lower(param)] local mountdoll_id = 9019 -- id do mount doll if player:getItemCount(mountdoll_id) > 0 then if param ~= "" and word then if not player:hasMount(word.id) and player:removeItem(mountdoll_id, 1) then player:sendTextMessage(MESSAGE_INFO_DESCR, "You got your mount!") player:getPosition():sendMagicEffect(CONST_ME_GIFT_WRAPS) player:addMount(word.id) else player:sendCancelMessage("You already have this mount.") end else player:sendCancelMessage("This mount does not exist.") end else player:sendCancelMessage("You must have a mount doll in your backpack!") end return true end
E em talkactions.xml adcione a tag:
<talkaction words="!mount" script="mountdoll.lua"/> Para editar é fácil, nesta parte:
local mountdoll_id = 9019 -- id do mount doll
Você escolhe o id do item que será o mount doll.
E caso queira adicionar alguma mount nova que não esteja configurado adicione ele na tabela em sequencia aos outros igual o exemplo:
-- ["mount"] = {id = x},
Eu deixei configurei apenas 1 mount, basta pegar os ids das mount e fazer igual o exemplo.
Para usar no servidor é só usar o comando !mount "mountname
Bem simples né pessoal ?! Espero ter ajudado, abraços!
-
bunda321 deu reputação a vankk em (Resolvido)Server Info do meu gesior tfs1.0ctrl+u nesse site, copia as tables, e seja feliz.
-
bunda321 deu reputação a runeraserver em Custom Cliente - Todas as versões - Qualquer IPFala galera,
Vejo muita gente com dúvida de como fazer custom clients. Neste tutorial vou ensinar para vocês criar custom clients de todas as versões e com qualquer ip.
1º Passo:
• Baixe o programa NotePad http://notepad-plus-plus.org/repository/6.x/6.7.5/npp.6.7.5.Installer.exe
2º Passo:
• Vá no diretório onde está instalado o client que deseja editar, clique com o direito em Tibia.exe e selecione "Edit with Notepad++"
3º Passo:
• Pressione ctrl + f e busque por login01.tibia.com e substitua pelo seu ip, (exemplo.com.br).
Perceba que login01.tibia.com + os 3 NUL que aparecem, somam 20 caracteres (NUL conta como 1).
O seu IP deverá conter 20 caracteres ou menos.
Exemplo:
exemplo.com.br possui 14 caracteres
Como o meu exemplo possui 14 caracteres e login01.tibia.comNULNULNUL possui 20, vou ter que preencher esses 6 caracteres que faltam com 6 NUL.
Para isso, você deverá deixar o cursos de texto na frente do seu ip (exemplo.com.br"AQUI") e ir para Plugins>Converter>Conversion.
Digite 0 em decimal e clique em (ASCII: Insert) 6 vezes, devendo ficar assim: exemplo.com.brNULNULNULNULNULNUL (Lembrando que acrescenta 6 NUL no caso do exemplo, o seu IP deverá completar os 20 caracteres podendo haver mais ou menos NULs).
Procure por esses ips e faça os passos acima em todos:
login01.tibia.com login02.tibia.com login03.tibia.com login04.tibia.com login05.tibia.com tibia01.cipsoft.com tibia02.cipsoft.com tibia03.cipsoft.com tibia04.cipsoft.com tibia05.cipsoft.com Feito isso, procure por:
132127743205872284062295099082293384952776326496165507967876361843343953435544496682053323833394351797728954155097012103928360786959821132214473291575712138800495033169914814069637740318278150290733684032524174782740134357629699062987023311132821016569775488792221429527047321331896351555606801473202394175817 Substitue por:
109120132967399429278860960508995541528237502902798129123468757937266291492576446330739696001110603907230888610072655818825358503429057592827629436413108566029093628212635953836686562675849720620786279431090218017681061521755056710823876476444260558147179707119674283982419152118103759076030616683978566631413 Créditos: Gesior
-
bunda321 deu reputação a patuloku em Bug Shop System GesiorSomente usar \/
http://pastebin.com/mjisMCpR
-
bunda321 deu reputação a Fir3element em [SHOPP] Systen bugado!-- ### CONFIG ### -- message send to player by script "type" (types you can check in "global.lua") SHOP_MSG_TYPE = 18 -- time (in seconds) between connections to SQL database by shop script SQL_interval = 30 -- ### END OF CONFIG ### function onThink(interval, lastExecution) local result_plr = db.storeQuery("SELECT * FROM z_ots_comunication") if(result_plr ~= false) then repeat local id = tonumber(result.getDataInt(result_plr, "id")) local action = tostring(result.getDataString(result_plr, "action")) local delete = tonumber(result.getDataInt(result_plr, "delete_it")) local cid = getPlayerByName(tostring(result.getDataString(result_plr, "name"))) if(cid) then local itemtogive_id = tonumber(result.getDataInt(result_plr, "param1")) local itemtogive_count = tonumber(result.getDataInt(result_plr, "param2")) local container_id = tonumber(result.getDataInt(result_plr, "param3")) local container_count = tonumber(result.getDataInt(result_plr, "param4")) local add_item_type = tostring(result.getDataString(result_plr, "param5")) local add_item_name = tostring(result.getDataString(result_plr, "param6")) local storage = tostring(result.getDataString(result_plr, "param7")) local received_item = 0 local full_weight = 0 if(add_item_type == 'container') then container_weight = getItemWeight(container_id, 1) if(isItemRune(itemtogive_id)) then items_weight = container_count * getItemWeight(itemtogive_id, 1) else items_weight = container_count * getItemWeight(itemtogive_id, itemtogive_count) end full_weight = items_weight + container_weight else full_weight = getItemWeight(itemtogive_id, itemtogive_count) if(isItemRune(itemtogive_id)) then full_weight = getItemWeight(itemtogive_id, 1) else full_weight = getItemWeight(itemtogive_id, itemtogive_count) end end local free_cap = getPlayerFreeCap(cid) if(full_weight <= free_cap) then if(add_item_type == 'container') then local new_container = doCreateItemEx(container_id, 1) local iter = 0 while(iter ~= container_count) do doAddContainerItem(new_container, itemtogive_id, itemtogive_count) iter = iter + 1 end received_item = doPlayerAddItemEx(cid, new_container) else local new_item = doCreateItemEx(itemtogive_id, itemtogive_count) received_item = doPlayerAddItemEx(cid, new_item) end if(type(received_item) == "number" and received_item == RETURNVALUE_NOERROR) then doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, 'You received '.. add_item_name ..' from ArenaTibia Shop.') setPlayerStorageValue(cid,storage+555884621212,1) db.query("DELETE FROM `z_ots_comunication` WHERE `id` = " .. id .. ";") db.query("UPDATE `z_shop_history_item` SET `trans_state`='realized', `trans_real`=" .. os.time() .. " WHERE id = " .. id .. ";") else doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, ' '.. add_item_name ..' from ArenaTibia Shop is waiting for you. Please make place for this item in your backpack/hands and wait about '.. SQL_interval ..' seconds to get it.') end else doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, ' '.. add_item_name ..' ArenaTibia Shop is waiting for you. It weight is '.. full_weight ..' oz., you have only '.. free_cap ..' oz. free capacity. Put some items in depot and wait about '.. SQL_interval ..' seconds to get it.') end end until not result.next(result_plr) result.free(result_plr) end return true end, itemtogive_id, itemtogive_count) iter = iter + 1 end received_item = doPlayerAddItemEx(cid, new_container) else local new_item = doCreateItemEx(itemtogive_id, itemtogive_count) received_item = doPlayerAddItemEx(cid, new_item) end if received_item == RETURNVALUE_NOERROR then doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, 'You received >> '.. add_item_name ..' << from OTS shop.') db.query("DELETE FROM `z_ots_comunication` WHERE `id` = " .. id .. ";") db.query("UPDATE `z_shop_history_item` SET `trans_state`='realized', `trans_real`=" .. os.time() .. " WHERE id = " .. id .. ";") doPlayerSave(cid) else doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, '>> The item '.. add_item_name ..' << that you just bought on the website couldnt be added. Han error has ocurred, please wait '.. SQL_interval ..' seconds.. Shop ID: '.. id ..'') end else doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, '>> The item '.. add_item_name ..' << that you just bought on the website couldnt be added. Han error has ocurred, please wait '.. SQL_interval ..' seconds.. Shop ID: '.. id ..'') end end if not(result_plr:next()) then break end end result_plr:free() end return TRUE end
-
bunda321 deu reputação a psychonaut em [SHOPP] Systen bugado!Faz backup do antigo e testa esse shop.lua, ou procura outro por ai, o seu ta bugado
-
bunda321 deu reputação a psychonaut em [SHOPP] Systen bugado!Vou dar uma olhada no script... Certifica que ele ta dentro da pasta /globalevents/scripts/, copia ele la
-
bunda321 deu reputação a Tricoder em [SHOPP] Systen bugado!Veja os posts http://www.tibiaking.com/forum/topic/52485-gesior-entrega-itens-sem-parar/