Ir para conteúdo

FlavioHulk

Membro
  • Registro em

  • Última visita

Tudo que FlavioHulk postou

  1. Virus Total Scan Monsters.rar
  2. Poderia explicar isso melhor? Você quer que apareça a chance que o player conseguiu para obter a recompensa? E por que a tabela tá com a mesma variável pra todos os actionIds? items[1] é a chance que o player poderá obter ou não?
  3. FlavioHulk postou uma resposta no tópico em Outros Clients
    ????????????
  4. FlavioHulk postou uma resposta no tópico em Outros Clients
    Bom trabalho, Gui! Sempre admirei seu trabalho, cara! ?????
  5. function onUse(cid, item) if getPlayerVocation(cid) == 12 then doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You already was promoted!") return true end if getPlayerVocation(cid) ~= 8 then doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You need to be VIP Elite Knight!") return true end doPlayerSetVocation(cid, (getPlayerVocation(cid) + 4)) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have been promoted!") doRemoveItem(item.uid, 1) return true end
  6. Quando seu suporte for resolvido, por favor marque a melhor resposta para que a tag "Resolvido" seja adicionada. Esta é uma mensagem automática! Pedimos que leia as regras do fórum!
  7. local skillids = { ["shielding"] = 5, ["sword"] = 2, ["axe"] = 3, ["club"] = 1, ["distance"] = 4, ["fishing"] = 6, ["fist"] = 0, } function onSay(cid, words, param) if not (L_LvlPoints.vocPoints[getPlayerVocation(cid)]) then return false end local param = param:lower() local p2 = string.explode(param, ",") if (getPlayerStorageValue(cid, 14574) < 0) then setPlayerStorageValue(cid, 14574, 0) end if (param == "check") then doPlayerPopupFYI(cid, "~*~*~ Level Points System by MaXwEllDeN ~*~*~\n\nPontos disponíveis: ".. getPlayerStorageValue(cid, 14574) .."\nPontos por level: ".. L_LvlPoints.vocPoints[getPlayerVocation(cid)]) elseif (p2[1] and p2[1] == "add") and (L_LvlPoints.attributes[p2[2]]) and (tonumber(p2[3])) then if getCreatureCondition(cid, CONDITION_ATTRIBUTES) then doPlayerSendCancel(cid, "Você não pode usar esse comando enquanto está com buff.") return doSendMagicEffect(getThingPos(cid), 2) end if (getPlayerStorageValue(cid, 14574) < tonumber(p2[3]) * L_LvlPoints.attributes[p2[2]].np) then doPlayerSendCancel(cid, "Você não tem pontos suficientes para distribuir!") return doSendMagicEffect(getThingPos(cid), 2) end if (p2[2] == "hp") then setCreatureMaxHealth(cid, getCreatureMaxHealth(cid) + L_LvlPoints.attributes[p2[2]].vl * tonumber(p2[3])) doCreatureAddHealth(cid, L_LvlPoints.attributes[p2[2]].vl * tonumber(p2[3])) elseif (p2[2] == "mp") then setCreatureMaxMana(cid, getCreatureMaxMana(cid) + L_LvlPoints.attributes[p2[2]].vl * tonumber(p2[3])) doCreatureAddMana(cid, L_LvlPoints.attributes[p2[2]].vl * tonumber(p2[3])) elseif (p2[2] == "magic") then doPlayerAddMagLevel(cid, 1) elseif(skillids[p2[2]]) then for a = 1, tonumber(p2[3]) do doPlayerAddSkillTry(cid, skillids[p2[2]], getPlayerRequiredSkillTries(cid, skillids[p2[2]], getPlayerSkillLevel(cid, skillids[p2[2]]) + 1) - getPlayerSkillTries(cid, skillids[p2[2]]), false) end end doSendMagicEffect(getThingPos(cid), 29) doSendMagicEffect(getThingPos(cid), 30) doSendAnimatedText(getThingPos(cid), "-" .. tonumber(p2[3]) * L_LvlPoints.attributes[p2[2]].np, 180) setPlayerStorageValue(cid, 14574, getPlayerStorageValue(cid, 14574) - tonumber(p2[3]) * L_LvlPoints.attributes[p2[2]].np) else local msgx = "" for i, v in pairs(L_LvlPoints.attributes) do local add = (v.np > 1) and "s" or "" msgx = msgx .. string.upper(i:sub(1,1)) .. i:sub(2, #i) .. " - ".. v.np .. " ponto".. add .. " ~ " .. v.vl .. " ".. v.nm .. "\n" end doPlayerPopupFYI(cid, "~*~*~ Level Points System by MaXwEllDeN ~*~*~\n\nPontos necessários para aumentar os stats:\n\n".. msgx .. "\nExemplo de uso: ".. words .." add, vitalidade, 5\n\nPontos disponíveis: ".. getPlayerStorageValue(cid, 14574)) end return true end
  8. FlavioHulk postou uma resposta no tópico em Suporte Bots
    Aqui no TibiaKing mensagens como UP e BUMP são proibidas, utilize o botão subir este tópico. Esta é uma mensagem automática! Pedimos que leia as regras do fórum!
  9. posta seu script do utito tempo ou utito tempo san, por favor
  10. <?php /** * Created by Notepad++. * User: Malucooo - Erick Nunes * Remaked of login.php by JLCVP and parts of login.php by Monteiro. Thanks for both! * Date: 18/09/17 * Time: 03:01 */ require 'config/config.php'; // comment to show E_NOTICE [undefinied variable etc.], comment if you want make script and see all errors error_reporting(E_ALL ^ E_STRICT ^ E_NOTICE); // true = show sent queries and SQL queries status/status code/error message define('DEBUG_DATABASE', false); define('INITIALIZED', true); if (!defined('ONLY_PAGE')) define('ONLY_PAGE', true); // check if site is disabled/requires installation include_once('./system/load.loadCheck.php'); // fix user data, load config, enable class auto loader include_once('./system/load.init.php'); // DATABASE include_once('./system/load.database.php'); if (DEBUG_DATABASE) Website::getDBHandle()->setPrintQueries(true); // DATABASE END /*error example: { "errorCode":3, "errorMessage":"Account name or password is not correct." }*/ # Declare variables with array structure $characters = array(); $playerData = array(); $data = array(); $isCasting = false; # error function function sendError($msg){ $ret = array(); $ret["errorCode"] = 3; $ret["errorMessage"] = $msg; die(json_encode($ret)); } # getting infos $request = file_get_contents('php://input'); $result = json_decode($request, true); # account infos $accountName = $result["accountname"]; $password = $result["password"]; # game port $port = 7172; # check if player wanna see cast list if (strtolower($accountName) == "cast") $isCasting = true; if ($isCasting) { $casts = $SQL->query("SELECT `player_id` FROM `live_casts`")->fetchAll(); if (count($casts[0]) == 0) sendError("There is no live casts right now!"); foreach($casts as $cast) { $character = new Player(); $character->load($cast['player_id']); if ($character->isLoaded()) { $char = array("worldid" => 0, "name" => $character->getName(), "ismale" => (($character->getSex() == 1) ? true : false), "tutorial" => false); $characters[] = $char; } } $port = 7173; $lastLogin = 0; $premiumAccount = true; $timePremium = 0; } else { $account = new Account(); $account->find($accountName); if (!$account->isLoaded()) sendError("Failed to get account. Try again!"); if ($account->getPassword() != Website::encryptPassword($password)) sendError("The password for this account is wrong. Try again!"); foreach($account->getPlayersList() as $character) { $char = array("worldid" => 0, "name" => $character->getName(), "ismale" => (($character->getSex() == 1) ? true : false), "tutorial" => false); $characters[] = $char; } $lastLogin = $account->getLastLogin(); $premiumAccount = ($account->isPremium()) ? true : false; $timePremium = time() + ($account->getPremDays() * 86400); } $session = array( "fpstracking" => false, "isreturner" => true, "returnernotification" => false, "showrewardnews" => false, "sessionkey" => $accountName . "\n" . $password, "lastlogintime" => $lastLogin, "ispremium" => $premiumAccount, "premiumuntil" => $timePremium, "status" => "active" ); $world = array( "id" => 0, "name" => $config['server']['serverName'], "externaladdress" => $config['server']['ip'], "externalport" => $port, "previewstate" => 0, "location" => "BRA", "anticheatprotection" => false ); //Survey by: Cjaker $survey = array( "id" => rand(0, 999999), "invitationtext" => "Seja bem vindo ao EternalRPG.", "invitationtoken" => "1751f1beddf001e1d36dee78ace974", "endtimestamp" => 1510614000 ); // https://limesurvey.cipsoft.com/index.php/survey/index/sid/527875/lang-en?token=1751f1beddf001e1d36dee78ace974 // token=invitationtoken // o endtimestamp acima é o tempo convertido em unix timestamp, onde o mesmo é o prazo que irá acabar o survey! $worlds = array($world); $data["session"] = $session; $playerData["worlds"] = $worlds; $playerData["characters"] = $characters; $data["playdata"] = $playerData; //$data["survey"] = $survey; echo json_encode($data);
  11. FlavioHulk postou uma resposta no tópico em Suporte Tibia OTServer
    Movements, só olhar a função inicial "onStepOut"...
  12. 1 - Procure uma aba escrito SQL 2 - Cole o comando na área 3 - Execute o comando, e enjoy !
  13. FlavioHulk postou uma resposta no tópico em Suporte Tibia OTServer
    local config = { [12500] = { -- Aqui você coloca sua actionId, a mesma que você colocará no item respectivo... newPosition = Position(125, 125, 7) -- Posição para onde o player irá } } function onStepOut(creature, item, position, fromPosition) local player = creature:getPlayer() if not player then return true end local tmpConfig = config[item.actionid] if not tmpConfig then return true end player:teleportTo(config.newPosition) player:getPosition():sendMagicEffect(CONST_ME_TELEPORT) return true end
  14. <?php /** * Created by Notepad++. * User: Malucooo - Erick Nunes * Remaked of login.php by JLCVP and parts of login.php by Monteiro. Thanks for both! * Date: 18/09/17 * Time: 03:01 */ require 'config/config.php'; // comment to show E_NOTICE [undefinied variable etc.], comment if you want make script and see all errors error_reporting(E_ALL ^ E_STRICT ^ E_NOTICE); // true = show sent queries and SQL queries status/status code/error message define('DEBUG_DATABASE', false); define('INITIALIZED', true); if (!defined('ONLY_PAGE')) define('ONLY_PAGE', true); // check if site is disabled/requires installation include_once('./system/load.loadCheck.php'); // fix user data, load config, enable class auto loader include_once('./system/load.init.php'); // DATABASE include_once('./system/load.database.php'); if (DEBUG_DATABASE) Website::getDBHandle()->setPrintQueries(true); // DATABASE END /*error example: { "errorCode":3, "errorMessage":"Account name or password is not correct." }*/ # Declare variables with array structure $characters = array(); $playerData = array(); $data = array(); $isCasting = false; # error function function sendError($msg){ $ret = array(); $ret["errorCode"] = 3; $ret["errorMessage"] = $msg; die(json_encode($ret)); } # getting infos $request = file_get_contents('php://input'); $result = json_decode($request, true); # account infos $accountName = $result["accountname"]; $password = $result["password"]; # game port $port = 7172; # check if player wanna see cast list if (strtolower($accountName) == "cast") $isCasting = true; if ($isCasting) { $casts = $SQL->query("SELECT `player_id` FROM `live_casts`")->fetchAll(); if (count($casts[0]) == 0) sendError("There is no live casts right now!"); foreach($casts as $cast) { $character = new Player(); $character->load($cast['player_id']); if ($character->isLoaded()) { $char = array("worldid" => 0, "name" => $character->getName(), "ismale" => (($character->getSex() == 1) ? true : false), "tutorial" => false); $characters[] = $char; } } $port = 7173; $lastLogin = 0; $premiumAccount = true; $timePremium = 0; } else { $account = new Account(); $account->find($accountName); if (!$account->isLoaded()) sendError("Failed to get account. Try again!"); if ($account->getPassword() != Website::encryptPassword($password)) sendError("The password for this account is wrong. Try again!"); foreach($account->getPlayersList() as $character) { $char = array("worldid" => 0, "name" => $character->getName(), "ismale" => (($character->getSex() == 1) ? true : false), "tutorial" => false); $characters[] = $char; } $lastLogin = $account->getLastLogin(); $premiumAccount = ($account->isPremium()) ? true : false; $timePremium = time() + ($account->getPremDays() * 86400); } $session = array( "fpstracking" => false, "isreturner" => true, "returnernotification" => false, "showrewardnews" => false, "sessionkey" => $accountName . "\n" . $password, "lastlogintime" => $lastLogin, "ispremium" => $premiumAccount, "premiumuntil" => $timePremium, "status" => "active" ); $world = array( "id" => 0, "name" => $config['server']['serverName'], "externaladdress" => $config['server']['ip'], "externalport" => $port, "previewstate" => 0, "location" => "BRA", "anticheatprotection" => false ); //Survey by: Cjaker $survey = array( "id" => rand(0, 999999), "invitationtext" => "Querido tibiano, obrigado por usar OTX, a base mais atualizada do Tibia Global.\n'Mensagem dita por Cjaker'.", "invitationtoken" => "1751f1beddf001e1d36dee78ace974", "endtimestamp" => 1510614000 ); // https://limesurvey.cipsoft.com/index.php/survey/index/sid/527875/lang-en?token=1751f1beddf001e1d36dee78ace974 // token=invitationtoken // o endtimestamp acima é o tempo convertido em unix timestamp, onde o mesmo é o prazo que irá acabar o survey! $worlds = array($world); $data["session"] = $session; $playerData["worlds"] = $worlds; $playerData["characters"] = $characters; $data["playdata"] = $playerData; $data["survey"] = $survey; echo json_encode($data); Outra dúvida, qual a versão do cliente que você está utilizando?
  15. <?php /** * Created by PhpStorm. * User: jlcvp - leu * Date: 07/06/17 * Time: 21:22 */ require 'config/config.php'; // comment to show E_NOTICE [undefinied variable etc.], comment if you want make script and see all errors error_reporting(E_ALL ^ E_STRICT ^ E_NOTICE); // true = show sent queries and SQL queries status/status code/error message define('DEBUG_DATABASE', false); define('INITIALIZED', true); if (!defined('ONLY_PAGE')) define('ONLY_PAGE', true); // check if site is disabled/requires installation include_once('./system/load.loadCheck.php'); // fix user data, load config, enable class auto loader include_once('./system/load.init.php'); // DATABASE include_once('./system/load.database.php'); if (DEBUG_DATABASE) Website::getDBHandle()->setPrintQueries(true); // DATABASE END /*error example: { "errorCode":3, "errorMessage":"Account name or password is not correct." }*/ //error function function sendError($error_msg,$code=3){ $retError = array(); $retError["errorCode"] = $code; $retError["errorMessage"] = $error_msg; die(json_encode($retError)); } $request_body = file_get_contents('php://input'); $result = json_decode($request_body, true); $acc = $result["accountname"]; $password = $result["password"]; $query = $SQL->prepare("SELECT `id`,`premdays` FROM `accounts` WHERE `name` = :acc AND `password` = SHA1(:pass) LIMIT 1"); $query->bindValue(":acc", $acc); $query->bindValue(":pass", $password); $dbResource = $query->execute(); if (!$dbResource) { sendError("failed to get account."); } $dbRet = $query->fetch(); if (!dbRet) { sendError("failed to fetch account data"); } $accId = $dbRet["id"]; $premdays = $dbRet["premdays"]; if (!$accId) { sendError("Account name or password is not correct."); } $dbResource = $SQL->query("SELECT `name`,`sex`,`lastlogin` FROM `players` WHERE `account_id` = $accId LIMIT 1"); if (!$dbResource) { sendError("failed to get characters."); } $accArray = array(); $lastlogin=0; while ($dbRet = $dbResource->fetch()) { $dict = array( "worldid" => 0, "name" => $dbRet["name"], "ismale" => (($dbRet["sex"]==1)?true:false), "tutorial" => false ); $accArray[] = $dict; if($lastlogin<$dbRet["lastlogin"]){ $lastlogin = $dbRet["lastlogin"]; } } $data = array(); //TODO: Melhorar estrutura de dado aqui e preencher com os dados reais da account $session = array( "sessionkey" => $acc . "\n" . $password, "lastlogintime" => $lastlogin, "ispremium" => ($premdays > 0 || $config["server"]["freePremium"]) ? true : false, "premiumuntil" => ($freePremium) ? (time() + 365 * 86400) : (time() + $premdays * 86400), "status" => "active" ); $data["session"] = $session; $playerData = array(); //TODO: melhorar estrutura de dado aqui para permitir multiple worlds $world = array( "id" => 0, "name" => $config["server"]["serverName"], "externaladdress" => $config["server"]["ip"], "externalport" => $config["server"]["gameProtocolPort"], "previewstate" => 0, "location" => "BRA", "externaladdressunprotected" => $config["server"]["ip"], "externaladdressprotected" => $config["server"]["ip"] ); $worlds = array($world); $playerData["worlds"] = $worlds; $playerData["characters"] = $accArray; $data["playdata"] = $playerData; echo json_encode($data);
  16. Posta seu login.php, por favor
  17. <attribute key="criticalHitChance" value="5" /> No value é onde você indica a porcentagem de chance que o player terá pra dar um critical, e sobre a source... Se sua source for 0.4, funcionará sim, pelo que vi não há algum erro nos scripts
  18. Engraçado como funciona a hipocrisia... Fulano é mercenário pois cobra por serviço, entendam só... Fulano passou horas e horas estudando, falhando, desanimando pra aprender aquilo e se aperfeiçoar... Fulano tem total direito de cobrar pelo seu serviço sim, há uma diferença entre serviço pronto e ajuda, geralmente só vejo pedidos de scripts prontos, nem o favor de testar antes, ou tentar corrigir por si só, já que isso aumenta seu aprendizado... Outra, por que vocês colocam donate, items vip pra vender no OTSERV? Querem retorno, querem ganhar dinheiro, entendeu onde está a hipocrisia? Se não quer ser cobrado por tempo e aprendizado, aprendam, tentem que eu digo a vocês, será bem mais satisfatório! Boa sorte a todos com seus otservers, e digo mais uma vez, isso é um dos motivos mais fortes de o Open Tibia estar se extinguindo...
  19. Opa cara, perdão, somente vi agora, então cara, você tem que setar pra pasta onde está seu dat e spr personalizado
  20. Algum erro no console? Vejo que existe algumas coisas obsoletas no script acima..
  21. Manda PM pra mim com uma forma pra eu entrar em contato contigo
  22. local conditions = { CONDITION_ATTRIBUTES, CONDITION_FREEZING, CONDITION_DAZZLED, CONDITION_CURSED, CONDITION_REGENERATION, CONDITION_DRUNK, CONDITION_OUTFIT, CONDITION_INVISIBLE, CONDITION_LIGHT, CONDITION_MANASHIELD, CONDITION_POISON, CONDITION_FIRE, CONDITION_ENERGY, CONDITION_PHYSICAL, CONDITION_HASTE, CONDITION_PARALYZE } local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_HEALING) setCombatParam(combat, COMBAT_PARAM_EFFECT, 49) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, false) setHealingFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 29.5, 36.5) function onCastSpell(cid, var) for i = 1, #conditions do local types = conditions[i] doRemoveCondition(cid, types) end return doCombat(cid, combat, var) end
  23. local conditions = { CONDITION_ATTRIBUTES, CONDITION_FREEZING, CONDITION_DAZZLED, CONDITION_CURSED, CONDITION_REGENERATION, CONDITION_DRUNK, CONDITION_OUTFIT, CONDITION_INVISIBLE, CONDITION_LIGHT, CONDITION_MANASHIELD, CONDITION_POISON, CONDITION_FIRE, CONDITION_ENERGY, CONDITION_PHYSICAL, CONDITION_HASTE, CONDITION_PARALYZE } local combat = createCombatObject() setHealingFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 5, 5, 29.5, 36.5) function onCastSpell(cid, var) for i = 1, #conditions do local types = conditions[i] doRemoveCondition(cid, types) end return doCombat(cid, combat, var) end
  24. Aah, você precisa utilizar o cliente correto, isso é o cliente que está desatualizado, você precisa setar o seu client editado pelo RME
  25. Isso irá remover todas as conditions, é mesmo que curar

Informação Importante

Confirmação de Termo