
Tudo que Bruno Carvalho postou
-
Sistema de vip 2 no meu OT, preciso de ajuda com algum script para remover item ao invés de gold
Try: function onSay(cid, words, param, channel) if(words == "!buyvip") then local item = 12569 local count = 1 if doPlayerRemoveItem(cid, item, count) then local days = 30 local daysvalue = days * 24 * 60 * 60 local storageplayer = getPlayerStorageValue(cid, 13500) local storage = 13500 local timenow = os.time() if storageplayer - os.time() <= 0 then time = timenow + daysvalue else time = storageplayer + daysvalue end if string.find(tostring(getCreatureName(cid)),"[[Vip]]") then doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Foram adicionados ".. days .." dias de VIP no seu character.") setPlayerStorageValue(cid, storage, time) local quantity = math.floor((getPlayerStorageValue(cid, storage) - timenow)/(24 * 60 * 60)) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você tem ".. quantity .." dias de VIP restantes.") else doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Foram adicionados ".. days .." dias de VIP no seu character.") setPlayerStorageValue(cid, storage, time) local name = getCreatureName(cid) db.executeQuery("UPDATE `players` SET `name` = '[Vip] "..name.."' WHERE `id` = "..getPlayerGUID(cid)..";") doRemoveCreature(cid) end else doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você precisa de "..id.." gp's para colocar vip.") end elseif(words == "!vipdays") then local timenow = os.time() local quantity = math.floor((getPlayerStorageValue(cid, storage) - timenow)/(24 * 60 * 60)) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você tem ".. (quantity < 0 and 0 or quantity) .." dias de VIP no seu character.") elseif(words == "/checkvip") then if getPlayerAccess(cid) == 5 then if not param then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Invalid param specified.") end local player = getPlayerByName(param) if not isPlayer(player) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Player "..player.." not found.") end local timenow = os.time() local quantity = math.floor((getPlayerStorageValue(player, storage) - timenow)/(24 * 60 * 60)) doPlayerPopupFYI(cid, "O jogador tem ".. (quantity < 0 and 0 or quantity) .." dias de VIP no character.") return TRUE end elseif(words == "/addvip") then if getPlayerAccess(cid) == 5 then local t = string.explode(param, ",") if not t[2] then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Invalid param specified.") end local player = getPlayerByName(t[1]) local name = getCreatureName(player) local days = t[2] local pid = getPlayerByNameWildcard(t[1]) if(not pid or (isPlayerGhost(pid) and getPlayerGhostAccess(pid) > getPlayerGhostAccess(cid))) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Player with this name doesn\'t exist or is offline.") return TRUE end local daysvalue = days*3600*24 local storageplayer = getPlayerStorageValue(player, storage) local timenow = os.time() local time = storageplayer <= 0 and (timenow + daysvalue) or (storageplayer + daysvalue) if string.find(tostring(getCreatureName(pid)),"[[Vip]]") then doPlayerSendTextMessage(player, MESSAGE_INFO_DESCR, "Foram adicionados "..days.." dias de VIP no seu character.") setPlayerStorageValue(player, storage, time) local quantity = math.floor((getPlayerStorageValue(player, storage) - timenow)/(3600*24)) doPlayerSendTextMessage(player, MESSAGE_INFO_DESCR, "Você tem "..quantity.." dias de VIP restantes.") else setPlayerStorageValue(player, storage, time) db.executeQuery("UPDATE `players` SET `name` = '[Vip] "..name.."' WHERE `id` = "..getPlayerGUID(player)..";") doRemoveCreature(player) end end elseif(words == "/delvip") then if getPlayerAccess(cid) == 5 then local dec = MESSAGE_INFO_DESCR if(param == "") then return TRUE,doPlayerSendTextMessage(cid,18,"Command param required.")end local C,t = {},string.explode(param, ",") C.pos = getPlayerPosition(cid) C.uid = getCreatureByName(t[1]) C.time = ((tonumber(t[2]) == nil) and 1 or tonumber(t[2]))*3600*24 --Tempo da vip por dia. C.days = (tonumber(t[2]) == nil) and 1 or tonumber(t[2]) --Dias de vip. if(getPlayerStorageValue(C.uid,storage) < C.time)then doPlayerSendTextMessage(cid,dec,'O jogador '..t[1]..' não possui '..C.days..' dias de vip.') else doPlayerSendTextMessage(cid,dec,'Você removeu '..C.days..' dias de vip do player '..t[1]..'.') setPlayerStorageValue(C.uid,storage,getPlayerStorageValue(C.uid,storage)-C.time) end doSendMagicEffect(C.pos, math.random(28,30)) end end return TRUE end
-
[Resolvido] [Duvida] Como tirar vip...
Avisado e negativado por moderação secundária !
-
[PEDIDO] Script 8.60
Acho que ficaria assim mais ou menos: function onSay(cid, words, param, channel) local _ip = nil if(param ~= '') then _ip = tonumber(param) if(not _ip or _ip == 0) then local revertIp = doRevertIp(param) if(not revertIp) then local tid = getPlayerByNameWildcard(param) if(not tid) then _ip = nil else _ip = getPlayerIp(tid) if(_ip == 0) then _ip = nil end end else _ip = doConvertIpToInteger(revertIp) end end end local list, ips, players = {}, {}, getPlayersOnline() for i, pid in ipairs(players) do local ip = getPlayerIp(pid) if(ip ~= 0) then local tmp = table.find(ips, ip) if(tmp ~= nil and) then if(table.countElements(list, ip) == 0) then list[players[tmp]] = ip end list[pid] = ip end table.insert(ips, ip) end end local total = table.maxn(list) if(total > 0) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Currently online players with same IP address(es):") for pid, ip in pairs(list) do doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, getCreatureName(pid) .. " (" .. doConvertIntegerToIp(ip) .. ")") end doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Total: " .. total .. " clients with more than one connection.") else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Currently there aren't any players with same IP address(es).") end return true end Testa ai, to com sono e só tirei a função de ip = ip...
-
Alissow Ots 5.0 [17/03/2013]
Alguns npcs ao falar addon para eles podem te vender o addon que usam =D
-
Alissow Ots 5.0 [17/03/2013]
Agora o npc alissow vende o premmy scroll ._. Isso são pedidos para um servidor ganhar direito, caso queira edite e seu e não fique pedindo =D
-
Alissow Ots 5.0 [17/03/2013]
Galera, como não teve muitos bugs reports da 5.1 eu fiz uma lista aqui e ja to arrumando algumas coisas que acho que deveriam ser mudadas, ta ficando assim... Falta mais alguma coisa?
-
Alissow Ots 5.0 [17/03/2013]
O npc vende somente algumas addons, outros vendem se você falar addon para eles... Dica: Tente dizer addon para os npcs com 3 addons... O outfit de casamento da para conseguir casando no npc da igreja... Ok, eu achei que funcionada, então vou antecipar a possivel 5.1 e trazer compilado para 64 bits.
-
Alissow Ots 5.0 [17/03/2013]
Galera, eu tava dando uma olhada e vi que para funcionar em 64x precisa trocar as dlls, aqui estão os downloads que contém na otx: + Dll 32x + Dll 64x
-
#13 - Evento de Páscoa 2013 - Resultado
Eu tirei a foto em liberty bay, la quase nunca tem ninguém em harmonia... Esse bug é exclusivo do meu pc u.U quando eu ando a tela do lado fica piscando, é linda *.*
-
#13 - Evento de Páscoa 2013 - Resultado
Tibia no notebook não roda aqui, fica esses bug ehehuehuehu' Só entrei pra pega o dinhero
-
#13 - Evento de Páscoa 2013 - Resultado
É, não foi primeiro de abril =D O premmy scroll esta guardado pq to pensando em fazer um concurso u.U
-
OTX Server - 2.52 Version (Necron)
Changelog Suporte Essa versão está baseada no tibia 9.83 e anteriores, existem sistemas que foram para certas versões: + CoolDown System - 8.54/57 - 8.60 Não compativel + OrangeSkull System - 8.54/57 - 8.60 Não compativel + PvpBlessing - 8.54/57 - 8.60 Não compativel + Mount System - 8.54/57 - 8.60 Não compativel + OffLineTraining - 8.54/57 - 8.60 - 8.70/71 Não compativel + DialogModals - 8.54/57 - 8.60 - 8.70/71 - 9.60/61 Não compativel + Market System - 8.54/57 - 8.60 - 8.70/71 Não compativel Requisitos Microsoft Visual C++ 2010 - 32Bits: Redistributable Package Microsoft Visual C++ 2010 - 64Bits: Redistributable Package Download Servidor - Contém executáveis 32x e 64x + Dll 32x + Dll 64x Bugs Qualquer bug pedimos que reporte imediatamente. Créditos https://code.google....ata/people/list
-
Alissow Ots 5.0 [17/03/2013]
Para voltar a começar a nascer em dorion fala com o npc alissow...
-
#13 - Evento de Páscoa 2013 - Resultado
Na vdd ele fico bravo com noiz pq n participo u.U
-
#13 - Evento de Páscoa 2013 - Resultado
Caracaa =O e eu nem ia participa Só participei pq vc pediu la no chat kkkk u.U
-
Anti Divulgação
Estou pensando em lançar um patch do alissow 5.1 com ele e outras funções...
-
#13 - Evento de Páscoa 2013
Aqui estão =D Anti Divulgação Anonymous Channel
-
Anonymous Channel
Nome: Anonymous Channel Versão: 2.0 Suportada: Tfs 0.3 e 0.4 Descrição: Quer atender o servidor mais sem ser descoberto? Mas quer configurar isso pelo config.lua? Eis a solução Em configmanager.cpp procure: m_confNumber[PACKETS_PER_SECOND] = getGlobalNumber("packetsPerSecond", 50); Abaixo adicione: m_confNumber[ANONYMOUS_CHANNEL] = getGlobalNumber("gmAnonymousInChannel", 0); Em configmanager.h procure: PACKETS_PER_SECOND, Abaixo adicione: ANONYMOUS_CHANNEL, Em game.cpp procure: case MSG_CHANNEL: { if(channelId == CHANNEL_HELP) { if(player->hasFlag(PlayerFlag_TalkOrangeHelpChannel)) type = MSG_CHANNEL_HIGHLIGHT; if(player->hasFlag(PlayerFlag_CanTalkRedChannel)) type = MSG_GAMEMASTER_CHANNEL; } break; } Substitua por: case MSG_CHANNEL: { if(channelId == CHANNEL_HELP) { if(player->hasFlag(PlayerFlag_TalkOrangeHelpChannel)) type = MSG_CHANNEL_HIGHLIGHT; if(player->hasFlag(PlayerFlag_CanTalkRedChannel)) type = MSG_GAMEMASTER_CHANNEL; if(g_config.getNumber(ConfigManager::ANONYMOUS_CHANNEL) == 1) { if(player->hasFlag(PlayerFlag_CanTalkRedChannelAnonymous)) { if(text.length() < 251) return g_chat.talk(player, type, text, channelId, statementId, true); } } } if(g_config.getNumber(ConfigManager::ANONYMOUS_CHANNEL) == 2) { if(player->hasFlag(PlayerFlag_CanTalkRedChannelAnonymous)) { if(text.length() < 251) return g_chat.talk(player, type, text, channelId, statementId, true); } } break; } Em config.lua adicione: gmAnonymousInChanel = 0 Configurando: gmAnonymousInChannel modifique para = 0 - Normal; 1 - Help Channel; 2 - All channels Créditos: Comedinha Outros fóruns (Versão antiga)
-
Anti Divulgação
Nome: advertisingBlock Versão: 2.0 Suportada: Tfs 0.3 e 0.4 Descrição: Bloqueie propagandas de outros servidor eu seu sem ficar recompilando toda hora. Em configmanager.cpp procure: m_confNumber[PACKETS_PER_SECOND] = getGlobalNumber("packetsPerSecond", 50); Abaixo adicione: m_confString[ADVERTISING_BLOCK] = getGlobalString("advertisingBlock", ""); Em configmanager.h procure: GAME_PORT, Abaixo adicione: ADVERTISING_BLOCK, Em game.cpp procure: int32_t muted = 0; bool mute = player->isMuted(channelId, type, muted); if(muted && mute) { if(muted > 0) { char buffer[75]; sprintf(buffer, "You are still muted for %d seconds.", muted); player->sendTextMessage(MSG_STATUS_SMALL, buffer); } else player->sendTextMessage(MSG_STATUS_SMALL, "You are muted permanently."); return false; } Abaixo adicione: std::string _text = asLowerCaseString(text); for(uint8_t i = 0; i < _text.length(); i++) { char t = _text[i]; if(t != '-' && t != '.' && !(t >= 'a' && t <= 'z')) { _text.erase(i, 1); i--; } } StringVec strVector; strVector = explodeString(g_config.getString(ConfigManager::ADVERTISING_BLOCK), ";"); for(StringVec::iterator it = strVector.begin(); it != strVector.end(); ++it) { std::string words []= {(*it)}; int ii, length; length = sizeof(words)/sizeof(words[0]); for(ii=0; ii < int(length); ii++) { if (int(_text.find(words[ii])) > 0 || _text == words[ii]) { player->sendTextMessage(MSG_STATUS_SMALL, "You can't send this message, forbidden characters."); return false; break; } } } Em config.lua adicione: advertisingBlock = "" Configurando: No config.lua onde tem advertisingBlock = "" substitua para o que deseja bloquear adicionando ; para separar. Exemplo: advertisingBlock = ".net;servegame;no-ip,.net;.com;.com.br;.org;.pl;.net;.biz" Créditos: Comedinha OTLand (Versão antiga)
-
Alissow Ots 5.0 [17/03/2013]
Hoje eu sinto que levantei inspirado... Como ainda não tem erros nesse servidor já comecei a pensar nas novidades de uma possível 5.1... Que tal as configs novas: Conseguem decifrar algumas? u.U
-
Alissow Ots 5.0 [17/03/2013]
http://tibiaking.com/forum/topic/22469-remeres-map-editor/ Acabei de atualizar
- [10.91] Remere's Map Editor
-
Alissow Ots 5.0 [17/03/2013]
Estou gostando de ver o resultado u.U há 2 dias atrás eu vi as estatisticas e estávamos em 30º (tinha aparecido pelomenos)... e acabei de ver hoje e amei o resultado... Fomos de 30º para 18º =D Obrigado a todos e espero que suba ainda mais =D
-
Alissow Ots 5.0 [17/03/2013]
Vlw =D Obrigado, qualquer bug reporte Não =D
-
Alissow Ots 5.0 [17/03/2013]
Algumas coisas que eu esqueci de fala: