Ir para conteúdo

Sociopata

Membro
  • Registro em

  • Última visita

Tudo que Sociopata postou

  1. crie em "data/scripts" goldenbag.lua function onEquipItem(cid, item, slot) if item.itemid == 7739 and slot == CONST_SLOT_BACKPACK then doPlayerAddSkill(cid, SKILL_DISTANCE, 300) -- Adiciona 300 pontos na skill Distance doPlayerAddSkill(cid, SKILL_AXE, 300) -- Adiciona 300 pontos na skill Axe doPlayerAddSkill(cid, SKILL_SWORD, 300) -- Adiciona 300 pontos na skill Sword doPlayerAddSkill(cid, SKILL_CLUB, 300) -- Adiciona 300 pontos na skill Club doPlayerAddSkill(cid, SKILL_SHIELD, 300) -- Adiciona 300 pontos na skill Shield doPlayerAddSkill(cid, SKILL_FIST, 300) -- Adiciona 300 pontos na skill Fist doPlayerAddSpeed(cid, 300) -- Adiciona 300 pontos na velocidade do jogador doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você ganhou habilidades ao equipar a Golden Bag.") end return true end function onDeEquipItem(cid, item, slot) if item.itemid == 7739 and slot == CONST_SLOT_BACKPACK then doPlayerAddSkill(cid, SKILL_DISTANCE, -300) -- Remove 300 pontos na skill Distance doPlayerAddSkill(cid, SKILL_AXE, -300) -- Remove 300 pontos na skill Axe doPlayerAddSkill(cid, SKILL_SWORD, -300) -- Remove 300 pontos na skill Sword doPlayerAddSkill(cid, SKILL_CLUB, -300) -- Remove 300 pontos na skill Club doPlayerAddSkill(cid, SKILL_SHIELD, -300) -- Remove 300 pontos na skill Shield doPlayerAddSkill(cid, SKILL_FIST, -300) -- Remove 300 pontos na skill Fist doPlayerAddSpeed(cid, -300) -- Remove 300 pontos na velocidade do jogador doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você perdeu habilidades ao remover a Golden Bag.") end return true end teste ai e veja se é isso mesmo
  2. local function applyMagicLevelBonus(cid) local playerStorage = getPlayerStorageValue(cid, 848484) or 0 local mlBonus = 0 if playerStorage >= 15 then mlBonus = 2 elseif playerStorage >= 5 then mlBonus = 1 end if mlBonus > 0 then local condition = createConditionObject(CONDITION_ATTRIBUTES) setConditionParam(condition, CONDITION_PARAM_TICKS, -1) setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVEL, mlBonus) if getCreatureCondition(cid, CONDITION_ATTRIBUTES) then doRemoveCondition(cid, CONDITION_ATTRIBUTES) end doAddCondition(cid, condition) doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você ganhou " .. mlBonus .. " pontos de Magic Level.") end end function onLogin(cid) applyMagicLevelBonus(cid) return true end 1. applyMagicLevelBonus(cid): Esta função verifica o valor da storage (848484) do jogador. Se for 15 ou mais, ganha 2 pontos de Magic Level. Se for 5 ou mais, ganha 1 ponto de Magic Level. A função doPlayerSendTextMessage é usada para informar ao jogador quanto de Magic Level foi adicionado. 2. onLogin(cid): Quando um jogador loga, esta função é chamada. Ela simplesmente chama applyMagicLevelBonus(cid) para aplicar o bônus de Magic Level quando o jogador loga.
  3. local config = { ["Boss"] = { posiTeleporte = {x = 96, y = 1153, z = 7, stackpos = 254}, -- Posição em que o teleporte aparecerá. posiToTeleporte = {x = 96, y = 1142, z = 7}, -- Posição onde será teleportado. time = 60, -- Tempo em que o teleporte irá desaparecer 60 segundos. life = 185, -- Life ao rebornar mana = 40, -- Mana ao rebornar level = 8, -- Level ao rebornar exp = 4200, -- exp que fica voc = 18, -- Voc ao rebornar cap = 450, storage = 30023 } } function removeTeleporte(tp) local teleporte = getTileItemById(tp.posiTeleporte, 5023) if teleporte then doRemoveItem(teleporte.uid, 1) doSendMagicEffect(tp.posiTeleporte, CONST_ME_POFF) end end function onDeath(cid) local teleport = config[getCreatureName(cid)] if teleport then doTeleportThing(cid, teleport.posiToTeleporte) doPlayerSetVocation(cid, teleport.voc) doPlayerSetOutfit(cid, teleport.outfit) doRemoveCreature(cid) addEvent(removeTeleporte, teleport.time*1000, teleport) end return true end As alterações que fiz foram as seguintes: Adicionei uma função removeTeleporte() que remove o teleporte após o tempo especificado. Na função onDeath(), agora eu teleporto o jogador para a posição especificada no config, altero a classe e a roupa do jogador e removo o jogador do jogo. Este script funciona da seguinte forma: Quando um monstro é morto, a função onDeath() é chamada. A função onDeath() verifica se o monstro está no config. Se o monstro estiver no config, a função onDeath() executa as seguintes ações: Cria um teleporte na posição especificada no config. Adiciona um evento para remover o teleporte após o tempo especificado. Teleporta o jogador para a posição especificada no config. Altera a classe do jogador para a classe especificada no config. Altera a roupa do jogador para a roupa especificada no config. Remove o jogador do jogo. Este script é apenas um ponto de partida. Você pode personalizá-lo para atender às suas necessidades específicas. Por exemplo, você pode adicionar uma verificação para garantir que o jogador não esteja em combate antes de teleportá-lo. Você também pode adicionar uma mensagem de confirmação para o jogador antes de teleportá-lo. Aqui estão algumas sugestões para personalizar o script: if isPlayerInCombat(cid) then return true end Adicione uma mensagem de confirmação para o jogador antes de teleportá-lo. local answer = doPlayerAskYesNo(cid, "Deseja ser teleportado?") if not answer then return true end Adicione uma condição para que o teleporte só funcione se o jogador tiver uma determinada quantidade de experiência. if getPlayerExperience(cid) < 10000 then return true end Adicione um efeito mágico quando o jogador é teleportado doSendMagicEffect(getPlayerPosition(cid), CONST_ME_TELEPORT) Espero que isso ajude
  4. Sociopata postou uma resposta no tópico em Suporte Tibia OTServer
    é infelizmente nao tem, vou ve se me viro com as sources aqui, pelo jeito a noite vai ser longa, mas vlw ae pessoal
  5. Sociopata postou uma resposta no tópico em Suporte Tibia OTServer
    fala Turma, estou querendo monstra um server aqui do "old times", porem nao acho onde fica a opção de desabilitar aquela mensagem que aparece mostrando loot da criatura, alguem pode me dizer onde habilita e desabilita essa opção?
  6. Crieo o server e o site td certo, mas qunado crio um char no site vou logar da o seguinte problema this account does not contain any character yet Resolvi passando para slite e voltando para mysql para resolver o problema de "comunicação"
  7. Sociopata postou uma resposta no tópico em Suporte Tibia OTServer
    http://www.tibiaking.com/forum/forum/186-servidores-derivados/
  8. vou ser sincero nao sei q arquivo faz isso, penso q seja ali em player.php por ai, ams achei um topico q talvez te ajude http://www.tibiaking.com/forum/topic/29294-d%C3%BAvidaesconder-samples-gesior/
  9. vai em htdocs>config e abra o config.php e altere essa linha $config['site']['support_group_id'] = 2; mude o dois para 11 de salve e atualize a lista , caso de algum erro retorne o numero q estava antes
  10. veja se é em TEAM.PHP
  11. @Digo tente fazer o seguinte, execute essas tabelas que estou passando a vc e me fale se deu algum resultado CREATE TABLE IF NOT EXISTS `accounts` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(32) NOT NULL DEFAULT '', `password` varchar(255) NOT NULL, `salt` varchar(40) NOT NULL DEFAULT '', `premdays` int(11) NOT NULL DEFAULT '0', `lastday` int(10) unsigned NOT NULL DEFAULT '0', `email` varchar(255) NOT NULL DEFAULT '', `key` varchar(20) NOT NULL DEFAULT '0', `blocked` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'internal usage', `warnings` int(11) NOT NULL DEFAULT '0', `group_id` int(11) NOT NULL DEFAULT '1', `viptime` int(15) NOT NULL DEFAULT '0', `page_lastday` int(11) NOT NULL, `email_new` varchar(255) NOT NULL, `email_new_time` int(15) NOT NULL, `created` int(11) NOT NULL DEFAULT '0', `rlname` varchar(255) NOT NULL DEFAULT '', `location` varchar(255) NOT NULL DEFAULT '', `page_access` int(11) NOT NULL DEFAULT '0', `email_code` varchar(255) NOT NULL DEFAULT '0', `next_email` int(11) NOT NULL DEFAULT '0', `premium_points` int(11) NOT NULL DEFAULT '0', `vote` int(11) NOT NULL, `last_post` int(11) NOT NULL DEFAULT '0', `flag` varchar(255) NOT NULL, `vip_time` int(11) NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=6741028 ; CREATE TABLE IF NOT EXISTS `players` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(255) NOT NULL, `world_id` tinyint(2) unsigned NOT NULL DEFAULT '0', `group_id` int(11) NOT NULL DEFAULT '1', `account_id` int(11) NOT NULL DEFAULT '0', `level` int(11) NOT NULL DEFAULT '1', `vocation` int(11) NOT NULL DEFAULT '0', `health` int(11) NOT NULL DEFAULT '150', `healthmax` int(11) NOT NULL DEFAULT '150', `experience` bigint(20) NOT NULL DEFAULT '0', `lookbody` int(11) NOT NULL DEFAULT '0', `lookfeet` int(11) NOT NULL DEFAULT '0', `lookhead` int(11) NOT NULL DEFAULT '0', `looklegs` int(11) NOT NULL DEFAULT '0', `looktype` int(11) NOT NULL DEFAULT '136', `lookaddons` int(11) NOT NULL DEFAULT '0', `maglevel` int(11) NOT NULL DEFAULT '0', `mana` int(11) NOT NULL DEFAULT '0', `manamax` int(11) NOT NULL DEFAULT '0', `manaspent` int(11) NOT NULL DEFAULT '0', `soul` int(10) unsigned NOT NULL DEFAULT '0', `town_id` int(11) NOT NULL DEFAULT '0', `posx` int(11) NOT NULL DEFAULT '0', `posy` int(11) NOT NULL DEFAULT '0', `posz` int(11) NOT NULL DEFAULT '0', `conditions` blob NOT NULL, `cap` int(11) NOT NULL DEFAULT '0', `sex` int(11) NOT NULL DEFAULT '0', `lastlogin` bigint(20) unsigned NOT NULL DEFAULT '0', `lastip` int(10) unsigned NOT NULL DEFAULT '0', `save` tinyint(1) NOT NULL DEFAULT '1', `skull` tinyint(1) unsigned NOT NULL DEFAULT '0', `skulltime` int(11) NOT NULL DEFAULT '0', `rank_id` int(11) NOT NULL DEFAULT '0', `guildnick` varchar(255) NOT NULL DEFAULT '', `lastlogout` bigint(20) unsigned NOT NULL DEFAULT '0', `blessings` tinyint(2) NOT NULL DEFAULT '0', `balance` bigint(20) NOT NULL DEFAULT '0', `stamina` bigint(20) NOT NULL DEFAULT '151200000' COMMENT 'stored in miliseconds', `direction` int(11) NOT NULL DEFAULT '2', `loss_experience` int(11) NOT NULL DEFAULT '100', `loss_mana` int(11) NOT NULL DEFAULT '100', `loss_skills` int(11) NOT NULL DEFAULT '100', `loss_containers` int(11) NOT NULL DEFAULT '100', `loss_items` int(11) NOT NULL DEFAULT '100', `premend` int(11) NOT NULL DEFAULT '0' COMMENT 'NOT IN USE BY THE SERVER', `online` tinyint(1) NOT NULL DEFAULT '0', `marriage` int(10) unsigned NOT NULL DEFAULT '0', `marrystatus` int(10) unsigned NOT NULL DEFAULT '0', `promotion` int(11) NOT NULL DEFAULT '0', `deleted` tinyint(1) NOT NULL DEFAULT '0', `description` varchar(255) NOT NULL DEFAULT '', `created` int(11) NOT NULL DEFAULT '0', `nick_verify` int(11) NOT NULL DEFAULT '0', `old_name` varchar(255) NOT NULL DEFAULT '', `hide_char` int(11) NOT NULL DEFAULT '0', `worldtransfer` int(11) NOT NULL DEFAULT '0', `comment` text NOT NULL, `show_outfit` tinyint(4) NOT NULL DEFAULT '1', `show_eq` tinyint(4) NOT NULL DEFAULT '1', `show_bars` tinyint(4) NOT NULL DEFAULT '1', `show_skills` tinyint(4) NOT NULL DEFAULT '1', `show_quests` tinyint(4) NOT NULL DEFAULT '1', `goals` int(11) NOT NULL DEFAULT '0', `wins` int(11) NOT NULL DEFAULT '0', `total` int(11) NOT NULL DEFAULT '0', `exphist_lastexp` bigint(255) NOT NULL DEFAULT '0', `exphist1` bigint(255) NOT NULL DEFAULT '0', `exphist2` bigint(255) NOT NULL DEFAULT '0', `exphist3` bigint(255) NOT NULL DEFAULT '0', `exphist4` bigint(255) NOT NULL DEFAULT '0', `exphist5` bigint(255) NOT NULL DEFAULT '0', `exphist6` bigint(255) NOT NULL DEFAULT '0', `exphist7` bigint(255) NOT NULL DEFAULT '0', `onlinetimetoday` bigint(255) NOT NULL DEFAULT '0', `onlinetime1` bigint(255) NOT NULL DEFAULT '0', `onlinetime2` bigint(255) NOT NULL DEFAULT '0', `onlinetime3` bigint(255) NOT NULL DEFAULT '0', `onlinetime4` bigint(255) NOT NULL DEFAULT '0', `onlinetime5` bigint(255) NOT NULL DEFAULT '0', `onlinetime6` bigint(255) NOT NULL DEFAULT '0', `onlinetime7` bigint(255) NOT NULL DEFAULT '0', `onlinetimeall` bigint(255) NOT NULL DEFAULT '0', `frags` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`,`deleted`), KEY `account_id` (`account_id`), KEY `group_id` (`group_id`), KEY `online` (`online`), KEY `deleted` (`deleted`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=9 ; CREATE TABLE IF NOT EXISTS `player_skills` ( `player_id` int(11) NOT NULL DEFAULT '0', `skillid` tinyint(2) NOT NULL DEFAULT '0', `value` int(10) unsigned NOT NULL DEFAULT '0', `count` int(10) unsigned NOT NULL DEFAULT '0', UNIQUE KEY `player_id_2` (`player_id`,`skillid`), KEY `player_id` (`player_id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  12. mas amigo a database vc cria apos instalar o xammp, e antes de colocar o htdocs na pasta do xammp, sugiro q refaça o processo novamente se vc fez isso q eu falei
  13. vc foi tentar ter acesso aeo phpmyadmin e deu isso?ou ao instalar o site?
  14. alter table bans add column reason int(10) NOT NULL so executar
  15. o erro esta na falta de algumas tabelas a maioria possui no forum, mas vc quer q eu lhe passe ?so no maximo umas 20
  16. http://www.tibiaking.com/forum/topic/43281-entendendo-o-phpmyadmin/
  17. Sociopata postou uma resposta no tópico em Suporte Tibia OTServer
    vá na pasta xampp/php e abra o arquivo php.ini procure por: error_reporting = substitua tudo por: error_reporting = E_ALL & ~E_NOTICE | E_STRICT Feche, salve, e reinicie o Apache !
  18. Sociopata postou uma resposta no tópico em Suporte Tibia OTServer
    vc apagou algum char com o nome sample?ou o account manager?
  19. no vertrigo a pasta é WWW se nao me engano
  20. seu config.lua nao era para ser assim sqlType = "mysql" sqlHost = "localhost" sqlPort = 3306 sqlUser = "root" sqlPass = "SUA SENHA" sqlDatabase = "SUA DATABASE DO PHPMYADMIN" sqlFile = "forgottenserver.s3db" sqlKeepAlive = 0 mysqlReadTimeout = 10 mysqlWriteTimeout = 10 encryptionType = "sha1" isso dependendo da versão do seu servidor eu acho
  21. mude para mysql e certifique-se q o apache e o mysql esteja rodando, e veja se os dados criados no phpmyadmin e no config.lua estão certos
  22. vai em htdocs>config>config.ini vai estar assim install = "no" server_path = "DIRETÓRIO DOSERVER" signatures = "1" feito isso reinsta-le o gesior colocando YES na primeira linha no lugar do NO
  23. diretorio do seu config.lua esta errado
  24. qual seria esse erro na database quando vc muda para mysql?

Informação Importante

Confirmação de Termo