Ir para conteúdo

Líderes

Conteúdo Popular

Exibindo conteúdo com a maior reputação em 03/20/11 em todas áreas

  1. Kimoszin

    [Tutorial] Criando Magias

    Introdução Ao Motivo de fechar a minha "fabrica de spells" resolvi criar esse tutorial. Para os iniciantes aprederem sozinhos. Organizei em Spoiler os Tipos de Magia. Spell De Attack: Spell De Cura: Spell de Suport: Bom é isso Pessoal. Espero que tenham Gostado! Obs: Quando eu tiver tempo, mostrarei todos os effects Abraços
    3 pontos
  2. Hello Como prometido irei disponibilizar agora o download do mapa pokemon que estive trabalhando. Coloquei as houses mais não o respaw. Apresentações ? Vamos lá para uma prévia das cidades. As hunt's vocês terão que baixar para conferir CITY 1 CITY 2 CITY 3 CITY 4 Me ajudem a atingir 200 REP +, Que farei este mapa ficar muito melhor do que está. Antes era 150 REP+, Mas por conta de alguns moderadores me tirarem REP + dizendo que eu tinha feito outra conta para me dar REP + agora será 200. Segue o download do mapa e o que precisa para que você abra-o MAPA BETINHOWZ666 SPR POR PIRADECO Créditos: PeeWee - por fazer parte do mapa Piradeco - pelas .spr e .dat betinhowz666 - por estar editando. (EU)
    2 pontos
  3. Que isso cara, precisa se desculpar não, acontece. Ja aconteceu comigo. O report que eu fiz, foi para mover, não foi contra você, fica tranquilo. Foi para ir a seção correta, e você se ajudado. Abraços.
    2 pontos
  4. Kydrai

    Vip System By Account V1.0

    Vip System by Account 1.0 By Kydrai Este é um vip system por account, ou seja, um sistema de vip válido para todos os characters de uma determinada conta. O script foi testado no TFS 0.3.6 - 8.54. E no site Gesior 0.3.4 beta4. Em caso de erros ou dúvidas é só postar. Funções do Script Função necessária para começar a usar o script: installVip() -> Cria a coluna no banco de dados para usar o sistema de vip (testei somente em sqlite, mas acredito que funcione em mysql) Funções que utilizam o account id: doTeleportPlayersByAccount(acc, topos) -> Teleporta todos os players da account getVipTimeByAccount(acc) -> Pega o tempo de vip setVipTimeByAccount(acc, time) -> Edita o tempo de vip getVipDaysByAccount(acc) -> Pega o tempo de vip em dias isVipAccount(acc) -> Verifica se é vip addVipDaysByAccount(acc, days) -> Adiciona dias de vip doRemoveVipDaysByAccount(acc, days) -> Remove dias de vip getVipDateByAccount(acc) -> Pega a data e hora que irá terminar a vip Funções que utilizam o creature id (cid): doTeleportPlayers(cid, topos) -> Teleporta todos os players da account getVipTime(cid) -> Pega o tempo de vip setVipTime(cid, time) -> Edita o tempo de vip getVipDays(cid) -> Pega o tempo de vip em dias isVip(cid) -> Verifica se é vip addVipDays(cid, days) -> Adiciona dias de vip doRemoveVipDays(cid, days) -> Remove dias de vip getVipDate(cid) -> Pega a data e hora que irá terminar a vip Inserindo as funções Abra a pasta data/lib, crie um arquivo lua e coloque: vipAccount.lua --[[ Name: Vip System by Account Version: 1.0 Author: Kydrai Forum: http://www.xtibia.com/forum/topic/136543-vip-system-by-account-v10/ [Functions] -- Install installVip() -- By Account doTeleportPlayersByAccount(acc, topos) getVipTimeByAccount(acc) setVipTimeByAccount(acc, time) getVipDaysByAccount(acc) isVipAccount(acc) addVipDaysByAccount(acc, days) doRemoveVipDaysByAccount(acc, days) getVipDateByAccount(acc) -- By Player doTeleportPlayers(cid, topos) getVipTime(cid) setVipTime(cid, time) getVipDays(cid) isVip(cid) addVipDays(cid, days) doRemoveVipDays(cid, days) getVipDate(cid) ]]-- -- Install function installVip() if db.executeQuery("ALTER TABLE `accounts` ADD viptime INT(15) NOT NULL DEFAULT 0;") then print("[Vip System] Vip System instalado com sucesso!") return TRUE end print("[Vip System] Não foi possível instalar o Vip System!") return FALSE end -- By Account function doTeleportPlayersByAccount(acc, topos) if db.executeQuery("UPDATE `players` SET `posx` = "..topos.x..", `posy` = "..topos.y..", `posz` = "..topos.z.." WHERE `account_id` = "..acc..";") then return TRUE end return FALSE end function getVipTimeByAccount(acc) local vip = db.getResult("SELECT `viptime` FROM `accounts` WHERE `id` = "..acc..";") if vip:getID() == -1 then print("[Vip System] Account not found!") return FALSE end return vip:getDataInt("viptime") end function setVipTimeByAccount(acc, time) if db.executeQuery("UPDATE `accounts` SET `viptime` = "..time.." WHERE `id` = "..acc..";") then return TRUE end return FALSE end function getVipDaysByAccount(acc) local vipTime = getVipTimeByAccount(acc) local timeNow = os.time() local days = math.ceil((vipTime - timeNow)/(24 * 60 * 60)) return days <= 0 and 0 or days end function isVipAccount(acc) return getVipDaysByAccount(acc) > 0 and TRUE or FALSE end function addVipDaysByAccount(acc, days) if days > 0 then local daysValue = days * 24 * 60 * 60 local vipTime = getVipTimeByAccount(acc) local timeNow = os.time() local time = getVipDaysByAccount(acc) == 0 and (timeNow + daysValue) or (vipTime + daysValue) setVipTimeByAccount(acc, time) return TRUE end return FALSE end function doRemoveVipDaysByAccount(acc, days) if days > 0 then local daysValue = days * 24 * 60 * 60 local vipTime = getVipTimeByAccount(acc) local time = vipTime - daysValue setVipTimeByAccount(acc, (time <= 0 and 1 or time)) return TRUE end return FALSE end function getVipDateByAccount(acc) if isVipAccount(acc) then local vipTime = getVipTimeByAccount(acc) return os.date("%d/%m/%y %X", vipTime) end return FALSE end -- By Player function doTeleportPlayers(cid, topos) doTeleportPlayersByAccount(getPlayerAccountId(cid), topos) end function getVipTime(cid) return getVipTimeByAccount(getPlayerAccountId(cid)) end function setVipTime(cid, time) return setVipTimeByAccount(getPlayerAccountId(cid), time) end function getVipDays(cid) return getVipDaysByAccount(getPlayerAccountId(cid)) end function isVip(cid) return isVipAccount(getPlayerAccountId(cid)) end function addVipDays(cid, days) return addVipDaysByAccount(getPlayerAccountId(cid), days) end function doRemoveVipDays(cid, days) return doRemoveVipDaysByAccount(getPlayerAccountId(cid), days) end function getVipDate(cid) return getVipDateByAccount(getPlayerAccountId(cid)) end Exemplos de uso Talkaction GOD: /installvip /addvip name, days /removevip name, days /checkvip name Player: /buyvip /vipdays talkactions.xml: <talkaction log="yes" access="5" words="/installvip;/addvip;/removevip;/checkvip" event="script" value="vipaccgod.lua"/> <talkaction words="/buyvip;/vipdays" event="script" value="vipaccplayer.lua"/> vipaccgod.lua: function onSay(cid, words, param, channel) local t = param:explode(",") local name, days = t[1], tonumber(t[2]) if words == "/installvip" then if installVip() then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Vip System instalado com sucesso!") else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Não foi possível instalar o Vip System!") end elseif words == "/addvip" then if name then if days then local acc = getAccountIdByName(name) if acc ~= 0 then addVipDaysByAccount(acc, days) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você adicionou "..days.." dia(s) de vip ao "..name..", agora ele possui "..getVipDaysByAccount(acc).." dia(s) de vip.") else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Este player não existe.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você não pode adicionar essa quantidade de dia(s) de vip.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você não pode adicionar dia(s) de vip a este player.") end elseif words == "/removevip" then if name then if days then local acc = getAccountIdByName(name) if acc ~= 0 then doRemoveVipDaysByAccount(acc, days) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você retirou "..days.." dia(s) de vip do "..name..", agora ele possui "..getVipDaysByAccount(acc).." dia(s) de vip.") else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Este player não existe.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você não pode retirar essa quantidade de dia(s) de vip.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você não pode retirar dia(s) de vip a este player.") end elseif words == "/checkvip" then if name then local acc = getAccountIdByName(name) if acc ~= 0 then local duration = getVipDateByAccount(acc) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "O "..name.." possui "..getVipDaysByAccount(acc).." dias de vip."..(duration and (" Ela irá durar até "..duration..".") or "")) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Este player não existe.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você não pode visualizar os dias de vip a este player.") end end return TRUE end vipaccplayer.lua: function onSay(cid, words, param, channel) if words == "/buyvip" then local price = 1000000 local days = 30 if doPlayerRemoveMoney(cid, price) then addVipDays(cid, days) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você adicionou "..days.." dia(s) de vip, agora você possui "..getVipDays(cid).." dia(s) de vip.") else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você precisa de "..price.." para adicionar "..days.." dia(s) de vip.") end elseif words == "/vipdays" then local duration = getVipDate(cid) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você possui "..getVipDays(cid).." dia(s) de vip."..(duration and (" Ela irá durar até "..duration..".") or "")) end return TRUE end Movement (Tile) Coloque actionid 15000 em um tile onde somente os vips poderão passar. movements.xml: <movevent type="StepIn" actionid="15000" event="script" value="viptile.lua"/> viptile.lua: function onStepIn(cid, item, position, fromPosition) if isVip(cid) == FALSE then doTeleportThing(cid, fromPosition, false) doSendMagicEffect(position, CONST_ME_MAGIC_BLUE) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Somente players vip podem passar.") end return TRUE end Creaturescript (Login) Quando player logar irá verificar se a vip do player acabou, se sim então irá teleportar todos os players da account para o templo, se não irá mostrar o tempo da vip. creaturescripts.xml: <event type="login" name="viplogin" script="viplogin.lua"/> viplogin.lua: function onLogin(cid) local vip = isVip(cid) if getVipTime(cid) > 0 and vip == FALSE then local townid = 1 doPlayerSetTown(cid, townid) local templePos = getTownTemplePosition(getPlayerTown(cid)) doTeleportThing(cid, templePos, false) setVipTime(cid, 0) doTeleportPlayers(cid, templePos) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Sua Vip acabou!") elseif vip == TRUE then local duration = getVipDate(cid) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você possui "..getVipDays(cid).." dia(s) de vip."..(duration and (" Ela irá durar até "..duration..".") or "")) end return TRUE end Action (Door) Coloque actionid 15001 na door onde somente os vips poderão passar. Use a porta gate of expertise (id: 1227) actions.xml: <action actionid="15001" script="vipdoor.lua"/> vipdoor.lua: function onUse(cid, item, fromPosition, itemEx, toPosition) if isVip(cid) == FALSE then doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Somente players vip podem passar.") elseif item.itemid == 1227 then doTransformItem(item.uid, item.itemid + 1) doTeleportThing(cid, toPosition) end return TRUE end NPC (Vendedor de VIP) vipnpc.xml: <?xml version="1.0" encoding="UTF-8"?> <npc name="Vendedor de VIP" script="vipnpc.lua" walkinterval="2000" floorchange="0"> <health now="100" max="100"/> <look type="128" head="17" body="54" legs="114" feet="0" addons="2"/> <parameters> <parameter key="message_greet" value="Hello |PLAYERNAME|, I sell {vip} days."/> </parameters> </npc> vipnpc.lua: local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end function buyVip(cid, message, keywords, parameters, node) if(not npcHandler:isFocused(cid)) then return false end if doPlayerRemoveMoney(cid, parameters.price) then addVipDays(cid, parameters.days) npcHandler:say('Thanks, you buy '..parameters.days..' vip days. You have '..getVipDays(cid)..' vip days.', cid) else npcHandler:say('Sorry, you don\'t have enough money.', cid) end npcHandler:resetNpc() return true end local node1 = keywordHandler:addKeyword({'vip'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Do you want buy 30 vip days for 1000000 gp\'s?'}) node1:addChildKeyword({'yes'}, buyVip, {price = 1000000, days = 30}) node1:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Ok, then.', reset = true}) npcHandler:addModule(FocusModule:new()) Erros e Soluções Configurando o Gesior Com essa configuração irá aparecer o vip status do player no site e será possível vender vip pelo site. Se eu esqueci de alguma coisa é só avisar. accountmanagement.php Depois de: if(!$account_logged->isPremium()) $account_status = '<b><font color="red">Free Account</font></b>'; else $account_status = '<b><font color="green">Premium Account, '.$account_logged->getPremDays().' days left</font></b>'; Adicione: if(!$account_logged->isVip()) $account_vip_status = '<b><font color="red">Not Vip Account</font></b>'; else $account_vip_status = '<b><font color="green">Vip Account, '.$account_logged->getVipDays().' days left</font></b>'; Depois de: <td class="LabelV" >Account Status:</td><td>'.$account_status.'</td></tr><tr style="background-color:'.$config['site']['darkborder'].';" > Adicione: <td class="LabelV" >Account Vip Status:</td><td>'.$account_vip_status.'</td></tr><tr style="background-color:'.$config['site']['darkborder'].';" > pot/OTS_Account.php Substitua: private $data = array('email' => '', 'blocked' => false, 'rlname' => '','location' => '','page_access' => 0,'lastday' => 0,'premdays' => 0, 'created' => 0); Por: private $data = array('email' => '', 'blocked' => false, 'rlname' => '','location' => '','page_access' => 0,'lastday' => 0,'premdays' => 0, 'created' => 0, 'viptime' => 0); Substitua: $this->data = $this->db->query('SELECT ' . $this->db->fieldName('id') . ', ' . $this->db->fieldName('name') . ', ' . $this->db->fieldName('password') . ', ' . $this->db->fieldName('email') . ', ' . $this->db->fieldName('blocked') . ', ' . $this->db->fieldName('rlname') . ', ' . $this->db->fieldName('location') . ', ' . $this->db->fieldName('page_access') . ', ' . $this->db->fieldName('premdays') . ', ' . $this->db->fieldName('lastday') . ', ' . $this->db->fieldName('created') . ' FROM ' . $this->db->tableName('accounts') . ' WHERE ' . $this->db->fieldName('id') . ' = ' . (int) $id)->fetch(); Por: $this->data = $this->db->query('SELECT ' . $this->db->fieldName('id') . ', ' . $this->db->fieldName('name') . ', ' . $this->db->fieldName('password') . ', ' . $this->db->fieldName('email') . ', ' . $this->db->fieldName('blocked') . ', ' . $this->db->fieldName('rlname') . ', ' . $this->db->fieldName('location') . ', ' . $this->db->fieldName('page_access') . ', ' . $this->db->fieldName('premdays') . ', ' . $this->db->fieldName('viptime') . ', ' . $this->db->fieldName('lastday') . ', ' . $this->db->fieldName('created') . ' FROM ' . $this->db->tableName('accounts') . ' WHERE ' . $this->db->fieldName('id') . ' = ' . (int) $id)->fetch(); Substitua: $this->db->query('UPDATE ' . $this->db->tableName('accounts') . ' SET ' . $this->db->fieldName('password') . ' = ' . $this->db->quote($this->data['password']) . ', ' . $this->db->fieldName('email') . ' = ' . $this->db->quote($this->data['email']) . ', ' . $this->db->fieldName('blocked') . ' = ' . (int) $this->data['blocked'] . ', ' . $this->db->fieldName('rlname') . ' = ' . $this->db->quote($this->data['rlname']) . ', ' . $this->db->fieldName('location') . ' = ' . $this->db->quote($this->data['location']) . ', ' . $this->db->fieldName('page_access') . ' = ' . (int) $this->data['page_access'] . ', ' . $this->db->fieldName('premdays') . ' = ' . (int) $this->data['premdays'] . ', ' . $this->db->fieldName('lastday') . ' = ' . (int) $this->data['lastday'] . ' WHERE ' . $this->db->fieldName('id') . ' = ' . $this->data['id']); Por: $this->db->query('UPDATE ' . $this->db->tableName('accounts') . ' SET ' . $this->db->fieldName('password') . ' = ' . $this->db->quote($this->data['password']) . ', ' . $this->db->fieldName('email') . ' = ' . $this->db->quote($this->data['email']) . ', ' . $this->db->fieldName('blocked') . ' = ' . (int) $this->data['blocked'] . ', ' . $this->db->fieldName('rlname') . ' = ' . $this->db->quote($this->data['rlname']) . ', ' . $this->db->fieldName('location') . ' = ' . $this->db->quote($this->data['location']) . ', ' . $this->db->fieldName('page_access') . ' = ' . (int) $this->data['page_access'] . ', ' . $this->db->fieldName('premdays') . ' = ' . (int) $this->data['premdays'] . ', ' . $this->db->fieldName('viptime') . ' = ' . (int) $this->data['viptime'] . ', ' . $this->db->fieldName('lastday') . ' = ' . (int) $this->data['lastday'] . ' WHERE ' . $this->db->fieldName('id') . ' = ' . $this->data['id']); Depois de: public function getPremDays() { if( !isset($this->data['premdays']) || !isset($this->data['lastday']) ) { throw new E_OTS_NotLoaded(); } return $this->data['premdays'] - (date("z", time()) + (365 * (date("Y", time()) - date("Y", $this->data['lastday']))) - date("z", $this->data['lastday'])); } Adicione: public function getVipDays() { if( !isset($this->data['viptime']) || !isset($this->data['lastday']) ) { throw new E_OTS_NotLoaded(); } return ceil(($this->data['viptime'] - time()) / (24*60*60)); } Depois de: public function isPremium() { return ($this->data['premdays'] - (date("z", time()) + (365 * (date("Y", time()) - date("Y", $this->data['lastday']))) - date("z", $this->data['lastday'])) > 0); } Adicione: public function isVip() { return ceil(($this->data['viptime'] - time()) / (24*60*60)) > 0; } characters.php Substitua: if($config['site']['show_vip_status']) { $id = $player->getCustomField("id"); if(is_int($number_of_rows / 2)) { $bgcolor = $config['site']['darkborder']; } else { $bgcolor = $config['site']['lightborder']; } $number_of_rows++; $main_content .= '<TR BGCOLOR="'.$bgcolor.'"><TD WIDTH=10%>Vip Status:</TD>'; $vip = $SQL->query('SELECT * FROM player_storage WHERE player_id = '.$id.' AND `key` = '.$config['site']['show_vip_storage'].';')->fetch(); if($vip == false) { $main_content .= '<TD><span class="red"><B>NOT VIP</B></TD></TR>'; } else { $main_content .= '<TD><span class="green"><B>VIP</B></TD></TR>'; } $comment = $player->getComment(); $newlines = array("\r\n", "\n", "\r"); $comment_with_lines = str_replace($newlines, '<br />', $comment, $count); if($count < 50) $comment = $comment_with_lines; if(!empty($comment)) { if(is_int($number_of_rows / 2)) { $bgcolor = $config['site']['darkborder']; } else { $bgcolor = $config['site']['lightborder']; } $number_of_rows++; $main_content .= '<TR BGCOLOR="'.$bgcolor.'"><TD VALIGN=top>Comment:</TD><TD>'.$comment.'</TD></TR>'; } } Por: if($config['site']['show_vip_status']) { $id = $player->getCustomField("id"); if(is_int($number_of_rows / 2)) { $bgcolor = $config['site']['darkborder']; } else { $bgcolor = $config['site']['lightborder']; } $number_of_rows++; $main_content .= '<TR BGCOLOR="'.$bgcolor.'"><TD WIDTH=10%>Account Vip Status:</TD>'; if(!$account->isVip()) { $main_content .= '<TD><span class="red"><B>NOT VIP</B></TD></TR>'; } else { $main_content .= '<TD><span class="green"><B>VIP</B></TD></TR>'; } $comment = $player->getComment(); $newlines = array("\r\n", "\n", "\r"); $comment_with_lines = str_replace($newlines, '<br />', $comment, $count); if($count < 50) $comment = $comment_with_lines; if(!empty($comment)) { if(is_int($number_of_rows / 2)) { $bgcolor = $config['site']['darkborder']; } else { $bgcolor = $config['site']['lightborder']; } $number_of_rows++; $main_content .= '<TR BGCOLOR="'.$bgcolor.'"><TD VALIGN=top>Comment:</TD><TD>'.$comment.'</TD></TR>'; } } shopsystem.php (+Créditos ao GM Bekman) Substitua: if($buy_offer['type'] == 'pacc') { $player_premdays = $buy_player_account->getCustomField('premdays'); $player_lastlogin = $buy_player_account->getCustomField('lastday'); $save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_pacc').' (id, to_name, to_account, from_nick, from_account, price, pacc_days, trans_state, trans_start, trans_real) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['days']).', \'realized\', '.$SQL->quote(time()).', '.$SQL->quote(time()).');'; $SQL->query($save_transaction); $buy_player_account->setCustomField('premdays', $player_premdays+$buy_offer['days']); $account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']); $user_premium_points = $user_premium_points - $buy_offer['points']; if($player_premdays == 0) { $buy_player_account->setCustomField('lastday', time()); } $main_content .= '<h2>PACC added!</h2><b>'.$buy_offer['days'].' days</b> of Premium Account added to account of player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br />Now you have <b>'.$user_premium_points.' premium points</b>.<br /><a href="index.php?subtopic=shopsystem">GO TO MAIN SHOP SITE</a>'; } Por: if($buy_offer['type'] == 'pacc') { $player_viptime = $buy_player_account->getCustomField('viptime'); $player_lastlogin = $buy_player_account->getCustomField('lastday'); $save_transaction = 'INSERT INTO '.$SQL->tableName('z_shop_history_pacc').' (id, to_name, to_account, from_nick, from_account, price, pacc_days, trans_state, trans_start, trans_real) VALUES (NULL, '.$SQL->quote($buy_player->getName()).', '.$SQL->quote($buy_player_account->getId()).', '.$SQL->quote($buy_from).', '.$SQL->quote($account_logged->getId()).', '.$SQL->quote($buy_offer['points']).', '.$SQL->quote($buy_offer['days']).', \'realized\', '.$SQL->quote(time()).', '.$SQL->quote(time()).');'; $SQL->query($save_transaction); if($player_viptime > 0) $buy_player_account->setCustomField('viptime', $player_viptime + ($buy_offer['days'] * 24 * 60 * 60)); else $buy_player_account->setCustomField('viptime', time() + ($buy_offer['days'] * 24 * 60 * 60)); $account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']); $user_premium_points = $user_premium_points - $buy_offer['points']; if($player_viptime == 0) { $buy_player_account->setCustomField('lastday', time()); } $main_content .= '<h2>VIP Days added!</h2><b>'.$buy_offer['days'].' days</b> of Vip Account added to account of player <b>'.$buy_player->getName().'</b> for <b>'.$buy_offer['points'].' premium points</b> from your account.<br />Now you have <b>'.$user_premium_points.' premium points</b>.<br /><a href="index.php?subtopic=shopsystem">GO TO MAIN SHOP SITE</a>'; } Links Úteis 01- [Gesior Acc] Vendedo Vip Pelo Pacc Créditos: GM Bekman 02- Double Exp Para Vip Créditos: Vodkart 03- Outfits Só Para Jogadores Vips Créditos: Vodkart
    1 ponto
  5. Demonbholder

    [Talkaction] Cadeia

    Faaala galera!!! Bom, vamos lá a mais um script que eu fiz agora a tarde. Antes de vocês falarem que já existe, eu quero dizer que eu fiz esse script agora a tarde sem nem olhar para os scripts de cadeia já existentes e que só fiz este script, porque um cara da seção de pedidos me pediu ajuda. O script que eu fiz é diferente dos já existentes, porque é possível especificar o tempo e o motivo pelo próprio comando. Primeira Versão: Segunda Versão: Fase de Testes O que mudou: Na primeira versão a cadeia é por tempo, e você configura o tempo no próprio comando da talkaction. Na segunda versão a cadeia é por fiança, você estipula um valor de fiança e o jogador não pode sair de lá até ter sua fiança paga, ou ele mesmo pagar sua própria fiança. Mais algumas informações de rotina: Servidor Testado: New Styller Yourots 0.7.5 Acho que é isso, se tiver algum erro se manifestem, até mais.
    1 ponto
  6. Natanael Beckman

    Servfull 8.0 Mapa Global...

    <span style='color:blue'>Servfull Versão 8.0 (Protocolo 7.81) -- ServFull Mapa Global 8.0 -- -- Treiner -- -- 517 Houses Configuradas -- -- 40 + Quest -- -- Demon Helmet-- -- Anihilator-- -- Ancient Helmet-- -- DSM-- -- Demona Quest-- -- RH-- -- Behe Quest-- -- Ring of the skies-- -- Bright Sowrd-- -- Banshee Quest-- -- Crown Legs-- -- Blue <> BOH <> SS-- -- Warlock Quest Lv 70-- -- Knight Armor-- -- Teddy Bear-- -- Mms and Giant Sword-- -- Uma de Lv 200 4 Itens Raros-- -- Crystal Arrow-- -- Gold Ring-- -- Dragon Scale Legs-- -- Great Shield-- -- + Uma de Lv 210 4 Itens Raros-- -- Magic Plate Armor-- -- Great Axe-- -- Horned Helmet-- -- Golden Boots-- -- e Muito + -- -- Novas Citys -- -- Venore-- -- Thais-- -- Ab'Dendriel-- -- Carlin-- -- Ankrhmun-- -- Edron-- -- Senja-- --Port Hope-- -- New Island-- -- Kazoedoon-- -- Mais Muito +...-- -- Tem Umas Invasões -- -- /raid mino-- -- /raid orsha-- -- /raid abin-- -- /raid undead-- -- /raid drag-- -- /raid port...-- -- Boas Areas De Hunt -- -- Hydras em Port Hope-- -- Drag em Ankrahmun uma area muito extensa e muitas quest-- -- Uma de Demon muito grande e muitas quest-- -- Mais essa são novas areas tem muito mais-- -- Tem um Npc Death -- -- Tem 3 resposta -- -- Demodras-- -- Ferrumbas-- -- Morgaroth...-- -- Acrescentei um NPC de treiner -- -- Mais um q leva ao dp e a treinar -- -- Novos Bichos -- -- Ferumbras-- -- Morgaroth-- -- Serpent Spawn-- A melhor versão 7.8 Global sem clona bugs 70% removidos... Tem uns bugs q ainda não resolvi galera, mais não é pq eu não saiba, mais e pq eu n tenho tempo msm, mais ainda tera mais versões Servfull, e prometo sempre esta melhorando... OBS: Os Bugs Q Forem Vistos Postem... Servfull 8.0 By â‚ªÄÆ’â€ ÄÆ’₪™... Reconheçam o trabalho e esforço de uma pessoa eu agradeço a quem posta....</span> Link Aki <<<<<<<<<<<<<<<< Divirta-se Link lix: http://lix.in/420589 Preciso de um progammer Ot Serv Global Servfull Ip: Xthenordeste.servegame.com</span> http://Xthenordeste.servegame.com:8080</span>
    1 ponto
  7. MarcelloMendes

    Advanced Reset System'

    ~~ Advanced Reset System 1.0 ~~ By: MarcelloMkez Bom, vi alguns Sistemas de Reset como o do Marcryzius, Yunie, e etc. E sempre vi Muitos pedidos como por exemplo: OBS: NÂO FUNCIONA EM 8.60 Reset no Look; Mudar Vocação ao Resetar; Limite em Resets; e etc... Então, resolvi Criar o Meu 'Reset System' com todas essas funções acima, e com a opção de Abilitar ou Desabilitar as Funções. Testado em TFS 0.3.6 - 8.50 e 8.60, o Script Funcionou Perfeitamente. Funções do Sistema: - Reset No Look; - Mudar Vocação ao Resetar; - Limite de Resets; - Premium Account; Ja vi sistemas de Reset, cada um com alguma dessas Funções, então resolvi junta-las em Apenas um 'Advanced Reset System'... Espero Por Críticas e Elogios. Abra a pasta data/Talkactions, crie um arquivo .lua e coloque: advancedReset.lua e Adicione Isso: --[[ SCRIPTING> MarcelloMkez <scriptING ]] --[[ [Advanced Reset System] Autor: MarcelloMkez Versão: 1.0 TFS: 0.3.6 Testado em: 8.50 Fórum: www.xtibia.com/forum/topic/138026-talk-action-advanced-reset-system/ [Características] ~ Versão 1.0 ~ - Resets no Look; - Premium Account ou não; - Mudar Vocação; - Limite de Resets; - Opções para Abilitar e Desabilitar Condições; [Em Construção] - Stages Free e Premium; - 'Talvez' um novo sistema de mudar Vocação; sem data para postagem. ]] function onSay(cid, words, param) --[Configurações de Condição]__ config = { --[[verdadeiro / Falso]] needPa = false, -- Precisa de Premium Account? [true / false] needPz = true, -- Precisa estar em Protection Zone? [true / false] battle = false, -- Precisa estar sem Batlle para Resetar? [true / false] withe = false, -- Players PK Withe pode Resetar? [true / false] red = false, -- Players PK Red pode Resetar? [true / false] tp = true, -- Teleportar para o Templo após o reset? [true / false] look = true, -- Mostrar Resets no Look do Player? [true / false] addLimite = false, -- Abilitar Limite de Resets? [true / false] setClasse = true, -- Mudar Vocação do player quando resetar? [true / false] storage = 2310, -- Storage [valor] --[Configurações do Reset]__ resetStatus = { player = getPlayerGUID(cid), -- Não Mude. lvl = 350 , -- Level Necessário para Resetar. [valor] lvlreset = 8, -- Level que retornará após o Reset. [valor] limite = 114, -- Máximo de resets que um player pode chegar. [valor] newClasse = 1, -- Id da Nova Vocação após o Reset. [valor] tempo= 5 -- Tempo para o Player deslogar para Resetar. Em segundos. [valor] }, } --[Funções]__ function Reseting(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) doPlayerSetVocation(cid, config.resetStatus.newClasse) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `description` = ' [Reset "..resets.."]' WHERE `players`.`id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) return TRUE end function noAll(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `description` = '' WHERE `players`.`id` = "..config.resetStatus.player) return TRUE end function noTeleporting(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doPlayerSetVocation(cid, config.resetStatus.newClasse) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `description` = ' [Reset "..resets.."]' WHERE `players`.`id` = "..config.resetStatus.player) return TRUE end function noLook(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doPlayerSetVocation(cid, config.resetStatus.newClasse) doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `description` = '' WHERE `players`.`id` = "..config.resetStatus.player) return TRUE end function noClasse(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `description` = ' [Reset "..resets.."]' WHERE `players`.`id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) return TRUE end function setClasse(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doPlayerSetVocation(cid, config.resetStatus.newClasse) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `description` = '' WHERE `players`.`id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) return TRUE end function look(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `description` = ' [Reset "..resets.."]' WHERE `players`.`id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) return TRUE end function teleporting(cid) resets = getResets(cid) setPlayerStorageValue(cid,config.storage,resets+1) doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) doRemoveCreature(cid) db.executeQuery("UPDATE `players` SET `description` = '' WHERE `players`.`id` = "..config.resetStatus.player) db.executeQuery("UPDATE `players` SET `level` = "..config.resetStatus.lvlreset..", `experience` = 0 WHERE `id` = "..config.resetStatus.player) return TRUE end function getResets(cid) resets = getPlayerStorageValue(cid,config.storage) if resets < 0 then resets = 0 end return resets end local resets = getResets(cid) local needLvl ="Você precisa de "..config.resetStatus.lvl-getPlayerLevel(cid).." level's para resetar." local msg ="~~[Reset: "..getResets(cid).."]~~ 'Sucesso ao Resetar! Você será deslogado em "..config.resetStatus.tempo.." Segundos." --[Condiçoes]__ if(config.needPz == true) and (getTilePzInfo(getCreaturePosition(cid)) == FALSE) then doPlayerSendTextMessage(cid,22,"Você Precisa estar em Protection Zone Para Resetar.") return TRUE elseif(config.addLimite == true) and (getResets(cid) == config.resetStatus.limite) then doPlayerSendTextMessage(cid, 22, "Você ja atingiu o Limite de Resets.") return TRUE elseif(config.withe == false) and (getCreatureSkullType(cid) == 3) then doPlayerSendTextMessage(cid,22,"Você ta PK White, por isso não pode resetar.") return TRUE elseif(config.red == false) and (getCreatureSkullType(cid) == 4) then doPlayerSendTextMessage(cid,22,"Você ta PK Red, por isso não pode resetar.") return TRUE elseif(config.needPa == true) and not isPremium(cid) then doPlayerSendTextMessage(cid,22,"Você Precisa ser Premium Account para Resetar.") return TRUE elseif(config.battle == true) and (getCreatureCondition(cid, CONDITION_INFIGHT) == TRUE) then doPlayerSendTextMessage(cid,22,"Você Precisa estar sem Battle para Resetar.") return TRUE elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == true) and (config.look == true) and (config.setClasse == true) then addEvent(Reseting, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == false) and (config.look == false) and (config.setClasse == false) then addEvent(noAll, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == false) and (config.look == true) and (config.setClasse == true) then addEvent(noTeleporting, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == true) and (config.look == false) and (config.setClasse == true) then addEvent(noLook, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == true) and (config.look == true) and (config.setClasse == false) then addEvent(noClasse, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == false) and (config.look == false) and (config.setClasse == true) then addEvent(setClasse, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == false) and (config.look == true) and (config.setClasse == false) then addEvent(look, config.resetStatus.tempo* 1000, cid) elseif getPlayerLevel(cid) >= config.resetStatus.lvl and (config.tp == true) and (config.look == false) and (config.setClasse == false) then addEvent(teleporting, config.resetStatus.tempo* 1000, cid) elseif doPlayerSendCancel(cid, needLvl) then doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) return TRUE end if doPlayerPopupFYI(cid, msg) then end return TRUE end --[by: MarcelloMkez]__ E em Talkactions.xml adicione isso: <talkaction words="!resetar" event="script" value="advancedReset.lua"/> Configurações: em --[Configurações de Condição]__ Para você Abilitar ou Desabilitar uma Função, você usa " true " para Verdadeiro," false " para falso, como ta Explicando no script. Em --[Configurações do Reset]__ Você colocará os Valores desejados, como: Level necessário para Resetar; Level que o Player Retornara após o Reset; Vocação para qual o player irá mudar caso esteja Abilitado a Função; Limite de Resets, caso esteja Abilitada a Função; E tempo em 'Segundos', para o Player Deslogar ao Resetar; Agora, para resetar, basta usar o comando "!resetar". Espero que Gostem e Entendam, Obrigado. by: MarcelloMkez'
    1 ponto
  8. Olá pessoal do XTibia Apesar de não ter muita experiencia com formatação de tópicos, estou aqui para informar-vos, criadores de Website que estão com problemas na instalação do Gesior, uma solução fácil e rápida desse erro: É o seguinte. Eu descobri que o php.ini ( arquivo que determina extensões , index e etc ) do xampp atualizado ( 1.7x), não está compatível com a linguagem .php dos arquivos do Gesior. Qual a solução ? Simples. Passo 1 Desinstale seu xampp e todos os seus serviços ( mysql, apache e os outros ). Passo 2 Baixe e instale esse xampp v 1.6.5 : Download Passo 3 Siga os passos do video-tutorial: Clique Aqui ! Pronto. Agora é so alegria . Se não deu certo, pode postar suas dúvidas aqui . Dá Rep + aí pessoal . Até mais pessoal, espero que dê certo, pois pra mim deu ! Créditos: Kamykasy ( EU ) Os comentários são o fogo do tópico !
    1 ponto
  9. Vmspk

    Azeroth Server Updated

    Azeroth Server Updated 14/07/2011: v1.0 Outras Versões: v1.1 [8.60]: http://www.xtibia.co...oth-rpg-reborn/ v2.0 [9.60]: http://www.xtibia.com/forum/topic/205054-960-azeroth-rpg/ Versão: 8.70 Distro: Crystal Server Mapa Base: Yourots Edited e Mix Yourots Features: > 7 Cidades: Azeroth Avalon Zatur Liberty Bay Gloria Sand Trap Tiquanda > Montarias por quest(NPC Mount Master, cavernas ao norte de Azeroth). > NPCs de Travel/Boat diferentes para cada cidade. > Corrigidos Vários Bugs do mapa. > Templo Reformado > Retirados Vários Itens custom e suas quests do antigo Riot Server. > Adicionada Dragon Dungeon. > Adicionado Vulcão de Goroma. > Adicionada Quest Especial em Gloria (NPC Gloria Scientist). > Adicionada Ferumbras Tower. > Várias Hunts adicionadas. > Adicionada Formorgar Mines. > Sistema de Refinamento e Slot. > 6 Novas Mounts. > Principais Quests: Annihilator Pits of Inferno The Inquisition FireWalker Boots Demon Helmet Draken Hell Conquer > 23 Raids Automáticas e configuradas: > Sistema de Guerras pelo Castelo [Honor Castle, a oeste de Azeroth] Evento automático. Quando a guerra é anunciada as guilds podem batalhar pelo controle do castelo, dando use no monumento do último andar e permanecendo assim até a guerra acabar. O último jogador a ter o controle do castelo antes do tempo acabar será o vencedor, e sua guild se tornará dona do castelo. Todos os membros da Guild ganharão uma recompensa e poderão acessar o mapa do subsolo. Os membros de outras Guilds serão teleportados para o templo e não poderão acessar o castelo. O sistema envia mensagens a todos antes de o evento começar, quando começar, quando o dono do castelo muda, antes de se finalizar e ao finalizar, relatando o conquistador do castelo e a guild vencedora. Imagens: Raids Castle Upgrade & Slot System Não há teleports diretos para hunts ou quests. Não há items ou monstros editados(além dos trainers). Não há sistema VIP(premium account valorizada). Não há raids com monstros excessivamente fortes nas cidades iniciais. Acc God: 2/password Créditos:Unknow YourOts Edited, Mix Yourots Team, Crystal Server Team, Tryller, Mock, TFS Team e um pouquinho (bem pouquinho) pra mim xD. Source - IP Changer 8.70 - Utilitários(opcional) - Map Editor *Utilitários inclui: Lista com códigos de todos os looktypes, SQLite Studio 1.1.1, códigos das cores dos outfits e o OTRestarter. Download Azeroth Server V 1.0 - Completo [MEDIAFIRE] Comandos: !war para executar a guerra pelo castelo manualmente, !reset para interromper o funcionamento da war e !castle para limpar todos os dados, ou seja, o castelo volta a ser terra de ninguém. V 0.2 V 0.3 V 0.4 V 1.0 Último pedido meu: encham o saco dos adms pra colocarem o tópico do tryller como fixo. É o melhor distro 8.70 que nós temos aqui, talvez ele salve os ots 8.70 daqui pra frente Contato: vmspk@hotmail.com Edit - Coloquei os Scans Edit2 - Adicionado comando Edit3 - Atualização Edit4 - Atualização http://img208.images...claymorepsf.jpg
    1 ponto
  10. Skywar

    Fazendo Uma Loja De Arqueiro

    Criando uma loja de arcos e munições para arqueiro. Olá galera do Xtibia, bom? Então vamos para o tutorial, sem enrolação. Aqui vou mostrar para vocês um estilo de fazer uma loja de arqueiro(paladin), começando com a base da loja. Parte 1: Aqui vou fazer uma simples mais bem agradável, siga a foto: Nesta imagem eu fiz o seguinte, como tudo você tem que pensar primeiramente na estrutura da loja, pensando onde o NPC vá ficar e onde ele trabalhará para o equipamento. ID'S Usados: 1815, 1620 e 1621, 7143 e 7144, 5321, 1536 Parte 2: Agora vamo pra parte de aperfeiçoamento da loja. Agora já nesta parte você já deve detalhar a loja ao seu gosto, como eu tenho o meu gosto eu coloquei algumas tábuas onde o NPC deve pegar para o arco, flecha, tapetes para não ficar no chão puro, alguns baús, caixas para a armazenagem de equipamento. ID'S Usados: 6474 e 6475, 5860, 1738, 1739, 1774, 1775 e 5300 a 5302. Parte 3: Vamos para alguns detalhes que ajuda a aparência da loja. Aqui ti mostro uma maneira de se detalhar a loja, posso ter exagerado ;/. Eu coloquei alguns musgos de grama e “graminhas” as rachaduras do piso. ID'S Usados: 1906 a 1908, 6285 a 6299, 4580 a 4594, 3611 a 3623 e 4514 a 4521. Parte 4: Vamos fazer o andar superior, siga: Bom, aqui eu fiz já o aposento do NPC e um lugar onde ele possa trabalha tranquilo. Você pode colocar os seus detalhes, só não acho bom colocar pedras e tufos de grama. ID'S Usados: 2556 a 2568, 2064, 1974, 1950 e 1777. Parte 5: Finalizando, fazendo um telhado bem legal e colocando alguns mais detalhes para aparência. ---------------- Bom esse e o meu primeiro tutorial aqui no XTibia, tentando ajudar vocês, espero que tenha mesmo. Download do mapa: http://www.speedyshare.com/files/23402426/tutorialxt1.otbm Scan: http://www.virustotal.com/pt/analisis/ec4ecba38d14f3326638d670c3fe736cbcb15bea66eb242662cbea9969a2bde4-1279297880 Créditos a min.
    1 ponto
  11. MatheusGlad

    [Systems] Pokemon Systems

    Scripts para TFS 0.3.6pl1 NAO FOI TESTADO EM OUTRA! Preview: Antes de tudo, va na pasta data/lib e adicione um script.lua com o nome de pokeLib e adicione isso: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- pokein, pokeout = 2222,2223 function doRemoveTile(pos)-- Script by mock pos.stackpos = 0 local sqm = getTileThingByPos(pos) doRemoveItem(sqm.uid,1) end function doCreateTile(id,pos) -- By mock doAreaCombatHealth(0,0,pos,0,0,0,CONST_ME_NONE) doCreateItem(id,1,pos) end function getPosDirs(p, dir) -- By MatheusMkalo return dir == 1 and {x=p.x-1, y=p.y, z=p.z} or dir == 2 and {x=p.x-1, y=p.y+1, z=p.z} or dir == 3 and {x=p.x, y=p.y+1, z=p.z} or dir == 4 and {x=p.x+1, y=p.y+1, z=p.z} or dir == 5 and {x=p.x+1, y=p.y, z=p.z} or dir == 6 and {x=p.x+1, y=p.y-1, z=p.z} or dir == 7 and {x=p.x, y=p.y-1, z=p.z} or dir == 8 and {x=p.x-1, y=p.y-1, z=p.z} end function doItem(pos,a,d)-- Script by mock doCreateTile(460,pos) pos.stackpos = 0 local c = getTileThingByPos(pos) doItemSetAttribute(c.uid, "aid", a) end function getDescription(uid) for i,x in pairs(getItemDescriptions(uid)) do if i == "special" then return x end end end function findLetter(string, letter) for i = 1, #string do if string:sub(i, i) == letter then return i end end end function isWalkable(pos, creature, proj, pz)-- by Nord if getTileThingByPos({x = pos.x, y = pos.y, z = pos.z, stackpos = 0}).itemid == 0 then return false end if getTopCreature(pos).uid > 0 and creature then return false end if getTileInfo(pos).protection and pz then return false, true end local n = not proj and 3 or 2 for i = 0, 255 do pos.stackpos = i local tile = getTileThingByPos(pos) if tile.itemid ~= 0 and not isCreature(tile.uid) then if hasProperty(tile.uid, n) or hasProperty(tile.uid, 7) then return false end end end return true end function getPosDirs(p, dir) return dir == 1 and {x=p.x-1, y=p.y, z=p.z} or dir == 2 and {x=p.x-1, y=p.y+1, z=p.z} or dir == 3 and {x=p.x, y=p.y+1, z=p.z} or dir == 4 and {x=p.x+1, y=p.y+1, z=p.z} or dir == 5 and {x=p.x+1, y=p.y, z=p.z} or dir == 6 and {x=p.x+1, y=p.y-1, z=p.z} or dir == 7 and {x=p.x, y=p.y-1, z=p.z} or dir == 8 and {x=p.x-1, y=p.y-1, z=p.z} end function canSummon(cid) local pos = getCreaturePosition(cid) local state = false for i = 1, 8 do if isWalkable(getPosDirs(getCreaturePosition(cid), i)) then state = true end end return state end function isPlayerSummon(cid, uid) if getCreatureMaster(uid) == cid then return TRUE end return FALSE end function getSummonLifes(cid) for _,x in pairs(getCreatureSummons(cid)) do return getCreatureHealth(x), getCreatureMaxHealth(x) end end function getItemsInContainerById(container, itemid) -- Function By Kydrai local items = {} if isContainer(container) and getContainerSize(container) > 0 then for slot=0, (getContainerSize(container)-1) do local item = getContainerItem(container, slot) if isContainer(item.uid) then local itemsbag = getItemsInContainerById(item.uid, itemid) for i=0, #itemsbag do table.insert(items, itemsbag[i]) end else if itemid == item.itemid then table.insert(items, item.uid) end end end end return items end function addPokeball(cid, pokename, maxh) local s = doPlayerAddItem(cid, pokein) doItemSetAttribute(s, "poke", "This is "..pokename.."'s pokeball. HP = ["..maxh.."/"..maxh.."]") doItemSetAttribute(s, "description", "Contains a " .. pokename) end function getPokeOutLive(cid) dat = {} for slot = CONST_SLOT_FIRST, CONST_SLOT_LAST do local item = getPlayerSlotItem(cid, slot) if isContainer(item.uid) then local items = getItemsInContainerById(item.uid, pokeout) for _, ui in pairs(items) do if getItemAttribute(ui, "poke"):sub(#getItemAttribute(ui, "poke")) == "." then table.insert(dat, ui) end end end if item.itemid == pokeout then if getItemAttribute(item.uid, "poke"):sub(#getItemAttribute(item.uid, "poke")) == "." then table.insert(dat, item.uid) end end end return dat end Go/Back Pokeball System By: MatheusMkalo Vá em data/actions/scripts e adicione um arquivo.lua com o nome de goback.lua Depois de ter feito isso, adicione o seguinte script no arquivo goback.lua: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- local pokes = { ["Dragon"] = {level = 1, go = "Vai Dragon", back = "Volte Dragon."}, ["Demon"] = {level = 8, go = "Vai Demon", back = "Volte Demon."}, ["Dragon Lord"] = {level = 8, go = "Vai Dragon Lord", back = "Volte Dragon Lord."}, ["Rat"] = {level = 8, go = "Vai Rat", back = "Volte Rat."}, } local msgunica = false function onUse(cid, item, frompos, item2, topos) local maxh = tonumber(getItemAttribute(item.uid, "poke"):match("/(.+)]")) local health = tonumber(getItemAttribute(item.uid, "poke"):match("%[(.-)/")) if item.itemid == pokeout then if health ~= nil and health <= 0 then return doPlayerSendCancel(cid, "This pokemon is dead.") end if #getCreatureSummons(cid) >= 1 then for _,z in pairs(getCreatureSummons(cid)) do if getItemAttribute(item.uid, "poke"):find(getCreatureName(z)) then doTransformItem(item.uid, pokein) if msgunica then doCreatureSay(cid, "Back, " .. getCreatureName(z), TALKTYPE_SAY) else doCreatureSay(cid, pokes[getCreatureName(z)].back, TALKTYPE_SAY) end doItemSetAttribute(item.uid, "poke", getItemAttribute(item.uid, "poke"):sub(1, findLetter(getItemAttribute(item.uid, "poke"), ".")) .. " HP = ["..getCreatureHealth(z).."/"..getCreatureMaxHealth(z).."]") setPlayerStorageValue(cid, 61204, 0) doSendMagicEffect(getCreaturePosition(z), 10) return doRemoveCreature(z) end end end elseif item.itemid == pokein then if getTilePzInfo(getCreaturePosition(cid)) then return doPlayerSendCancel(cid, "You can't use pokeball in Protection Zones.") end if not canSummon(cid) then return doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTENOUGHROOM) end if getPlayerStorageValue(cid, 63215) >= 1 then return doPlayerSendCancel(cid, "You can't use pokeball while surfing.") end if getPlayerStorageValue(cid, 62314) >= 1 then return doPlayerSendCancel(cid, "You can't use pokeball while flying.") end if getPlayerStorageValue(cid, 59987) >= 1 then return doPlayerSendCancel(cid, "You can't use pokeball while riding.") end for i,x in pairs(pokes) do if #getCreatureSummons(cid) >= 1 then return doPlayerSendCancel(cid, "You already summoned a pokemon.") end if i == getItemAttribute(item.uid, "poke"):sub(9, findLetter(getItemAttribute(item.uid, "poke"), "'")-1) then if getPlayerLevel(cid) >= x.level then pk = doSummonCreature(i, getThingPosition(cid)) doConvinceCreature(cid, pk) setCreatureMaxHealth(pk, tonumber(getItemAttribute(item.uid, "poke"):match("/(.+)]"))) doCreatureAddHealth(pk, maxh) doCreatureAddHealth(pk, health-maxh) doTransformItem(item.uid, pokeout) if msgunica then doCreatureSay(cid, "Go, " .. i, TALKTYPE_SAY) else doCreatureSay(cid, x.go, TALKTYPE_SAY) end doItemSetAttribute(item.uid, "poke", getItemAttribute(item.uid, "poke"):sub(1, findLetter(getItemAttribute(item.uid, "poke"), "."))) doSendMagicEffect(getCreaturePosition(pk), 10) setPlayerStorageValue(cid, 61204, 1) registerCreatureEvent(pk, "DiePoke") registerCreatureEvent(cid, "PlayerPokeDeath") registerCreatureEvent(cid, "LogoutPoke") break else doPlayerSendCancel(cid, "Only players level "..x.level.." or higher can use this pokemon.") end end end end return TRUE end Depois, va em actions.xml e adicione a seguinte tag: <action itemid="2222;2223" event="script" value="goback.lua"/> Sendo que 2222 e 2223 são, respectivamente, o id da pokeball que ira "chamar" o pokemon, e o outro o id da pokeball que ira retirar o pokemon. (Seriam as pokebolas acesas e apagadas do PO) Agora, para evitar alguns bugs, va em data/creaturescripts/scripts e crie um arquivo.lua com o nome goback.lua e bote o seguinte script dentro: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- function onLogout(cid) local health,maxhealth = getSummonLifes(cid) if getPlayerStorageValue(cid, 61204) >= 1 and getPlayerStorageValue(cid, 63215) <= 0 and getPlayerStorageValue(cid, 62314) <= 0 and getPlayerStorageValue(cid, 59987) <= 0 then setPlayerStorageValue(cid, 61205, health) setPlayerStorageValue(cid, 61206, maxhealth) setPlayerStorageValue(cid, 61204, 0) setPlayerStorageValue(cid, 61207, 1) end if getPlayerStorageValue(cid, 62314) >= 1 then pos = getCreaturePosition(cid) for i = 1,8 do doRemoveTile(getPosDirs(getCreaturePosition(cid), i)) end doRemoveTile(getCreaturePosition(cid)) setPlayerStorageValue(cid, 61941, pos.x) setPlayerStorageValue(cid, 61942, pos.y) setPlayerStorageValue(cid, 61943, pos.z) end return TRUE end function onLogin(cid) local pokes = { ["Dragon"] = {lookType=267, speed = 1500}, ["Rat"] = {lookType=267, speed = 500}, } local pokesfly = { ["Dragon"] = {lookType = 216, speed = 500}, } local pokesride = { ["Dragon Lord"] = {lookType=4, speed = 3000}, ["Dragon"] = {lookType=4, speed = 500}, } if getPlayerStorageValue(cid, 62314) >= 1 then doCreateTile(460, {x=getPlayerStorageValue(cid, 61941), y=getPlayerStorageValue(cid, 61942), z=getPlayerStorageValue(cid, 61943)}) doTeleportThing(cid, {x=getPlayerStorageValue(cid, 61941), y=getPlayerStorageValue(cid, 61942), z=getPlayerStorageValue(cid, 61943)}) for i = 1,8 do doItem(getPosDirs(getCreaturePosition(cid), i), 65119+i) end local item = getPokeOutLive(cid)[1] local a = getItemAttribute(item, "poke"):match("This is (.-)'s pokeball.") doSetCreatureOutfit(cid, pokesfly[tostring(a)], -1) doChangeSpeed(cid, pokesfly[tostring(a)].speed) registerCreatureEvent(cid, "PlayerPokeDeath") end if getPlayerStorageValue(cid, 63215) >= 1 then local item = getPokeOutLive(cid)[1] local a = getItemAttribute(item, "poke"):match("This is (.-)'s pokeball.") doSetCreatureOutfit(cid, pokes[tostring(a)], -1) doChangeSpeed(cid, pokes[tostring(a)].speed) registerCreatureEvent(cid, "PlayerPokeDeath") end if getPlayerStorageValue(cid, 59987) >= 1 then local item = getPokeOutLive(cid)[1] local a = getItemAttribute(item, "poke"):match("This is (.-)'s pokeball.") doSetCreatureOutfit(cid, pokesride[tostring(a)], -1) doChangeSpeed(cid, pokesride[tostring(a)].speed) registerCreatureEvent(cid, "PlayerPokeDeath") end if getPlayerStorageValue(cid, 61207) >= 1 then local item = getPokeOutLive(cid)[1] doTransformItem(item, pokein) doRemoveCondition(cid, CONDITION_OUTFIT) doItemSetAttribute(item, "poke", getItemAttribute(item, "poke"):sub(#getItemAttribute(item, "poke")) ~= "]" and getItemAttribute(item, "poke") .. " HP = ["..getPlayerStorageValue(cid, 61205).."/"..getPlayerStorageValue(cid, 61206).."]" or getItemAttribute(item, "poke")) setPlayerStorageValue(cid, 61207, 0) end return TRUE end function onDeath(cid, deathList) local owner = getCreatureMaster(cid) doPlayerSendTextMessage(owner, 22, "Your pokemon died.") for slot = CONST_SLOT_FIRST, CONST_SLOT_LAST do local item = getPlayerSlotItem(owner, slot) if isContainer(item.uid) then local items = getItemsInContainerById(item.uid, pokeout) for _, ui in pairs(items) do if getItemAttribute(ui, "poke"):sub(#getItemAttribute(ui, "poke")) == "." then local maxh = tonumber(getItemAttribute(ui, "poke"):match("/(.+)]")) doItemSetAttribute(ui, "poke", getItemAttribute(ui, "poke"):sub(1, findLetter(getItemAttribute(ui, "poke"), ".")) .. " HP = [0/"..getCreatureMaxHealth(cid).."]") end end end if item.itemid == pokeout then if getItemAttribute(item.uid, "poke"):sub(#getItemAttribute(item.uid, "poke")) == "." then local maxh = tonumber(getItemAttribute(item.uid, "poke"):match("/(.+)]")) doItemSetAttribute(item.uid, "poke", getItemAttribute(item.uid, "poke"):sub(1, findLetter(getItemAttribute(item.uid, "poke"), ".")) .. " HP = [0/"..getCreatureMaxHealth(cid).."]") end end end doRemoveCreature(cid) setPlayerStorageValue(owner, 61207, 0) setPlayerStorageValue(owner, 61204, 0) return FALSE end Agora adicione outro arquivo.lua na pasta data/creaturescripts/scripts com o nome de playerpdeath e bote esse script: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- function onDeath(cid) local health,maxhealth = getSummonLifes(cid) if #getCreatureSummons(cid) >= 1 then setPlayerStorageValue(cid, 61205, health) setPlayerStorageValue(cid, 61206, maxhealth) setPlayerStorageValue(cid, 61204, 0) setPlayerStorageValue(cid, 61207, 1) end if getPlayerStorageValue(cid, 63215) >= 1 then setPlayerStorageValue(cid, 61205, getPlayerStorageValue(cid, 61210)) setPlayerStorageValue(cid, 61206, getPlayerStorageValue(cid, 61209)) setPlayerStorageValue(cid, 61204, 0) setPlayerStorageValue(cid, 63215, 0) setPlayerStorageValue(cid, 61207, 1) end if getPlayerStorageValue(cid, 62314) >= 1 then setPlayerStorageValue(cid, 61205, getPlayerStorageValue(cid, 61262)) setPlayerStorageValue(cid, 61206, getPlayerStorageValue(cid, 61263)) setPlayerStorageValue(cid, 61204, 0) setPlayerStorageValue(cid, 62314, 0) setPlayerStorageValue(cid, 61207, 1) end if getPlayerStorageValue(cid, 59987) >=1 then setPlayerStorageValue(cid, 61205, getPlayerStorageValue(cid, 59988)) setPlayerStorageValue(cid, 61206, getPlayerStorageValue(cid, 59989)) setPlayerStorageValue(cid, 61204, 0) setPlayerStorageValue(cid, 59987, 0) setPlayerStorageValue(cid, 61207, 1) end return TRUE end Depois va em creaturescripts.xml e adicione as seguintes TAGS: <event type="death" name="PlayerPokeDeath" event="script" value="playerpdeath.lua"/> <event type="death" name="DiePoke" event="script" value="goback.lua"/> <event type="logout" name="LogoutPoke" event="script" value="goback.lua"/> <event type="login" name="LoginPoke" event="script" value="goback.lua"/> Catch Pokemon System By: MatheusMkalo Vá em data/actions/scripts e adicione um arquivo.lua com o nome de catch.lua Depois adicione o seguinte script dentro dele: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- local pokes = { ["Dragon"] = {corpseid = 5973, chance = 100, health = 12200, maxhealth = 12200}, ["Dragon Lord"] = {corpseid = 5984, chance = 100, health = 12200, maxhealth = 12200}, ["Demon"] = {corpseid = 5995, chance = 100, health = 12200, maxhealth = 12200}, } local time = 4 -- Tempo para mandar as mensagens e adiciona item function onUse(cid, item, frompos, item2, topos) for i,x in pairs(pokes) do if item2.itemid == x.corpseid then doRemoveItem(item.uid, 1) doRemoveItem(item2.uid, 1) if math.random(1,100) <= x.chance then function add() local s = doPlayerAddItem(cid, pokein) doItemSetAttribute(s, "poke", "This is "..i.."'s pokeball. HP = ["..x.health.."/"..x.maxhealth.."]") doItemSetAttribute(s, "description", "Contains a " .. i) end doSendMagicEffect(topos, 24) addEvent(add, time*1000) return addEvent(doPlayerSendTextMessage, time*1000, cid, 27, "You catch a " .. i .. ".") else addEvent(doPlayerSendTextMessage, time*1000, cid, 27, "Your pokeball broke.") return doSendMagicEffect(topos, 23) end end end return TRUE end Depois adicione a seguinte TAG no actions.xml: <action itemid="2147" event="script" value="catch.lua"/> Sendo 2147, o id da sua pokebola para capturar pokemons (NAO A DE CHAMAR O POKEMON) Npc Healler By: MatheusMkalo Vá em data/npc/scripts e adicione um arquivo.lua com o seguinte script: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- local keywordHandler = KeywordHandler:new() local npcHandler = NpcHandler:new(keywordHandler) NpcSystem.parseParameters(npcHandler) local talkState = {} function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end function onThink() npcHandler:onThink() end function creatureSayCallback(cid, type, msg) if(not npcHandler:isFocused(cid)) then return false end if msgcontains(msg, 'heal') then if #getCreatureSummons(cid) >= 1 then return selfSay('Voce precisa botar seus pokemons dentro da pokebola.', cid) end for slo = CONST_SLOT_FIRST, CONST_SLOT_LAST do local item = getPlayerSlotItem(cid, slo) if isContainer(item.uid) then local items = getItemsInContainerById(item.uid, pokeout) for i,x in pairs(items) do local maxh = tonumber(getItemAttribute(x, "poke"):match("/(.+)]")) doItemSetAttribute(x, "poke", getItemAttribute(x, "poke"):sub(1, findLetter(getItemAttribute(x, "poke"), ".")) .. " HP = ["..maxh.."/"..maxh.."]") doTransformItem(x, pokein) end local items2 = getItemsInContainerById(item.uid, pokein) for i,x in pairs(items2) do local maxh = tonumber(getItemAttribute(x, "poke"):match("/(.+)]")) doItemSetAttribute(x, "poke", getItemAttribute(x, "poke"):sub(1, findLetter(getItemAttribute(x, "poke"), ".")) .. " HP = ["..maxh.."/"..maxh.."]") end elseif item.itemid == pokeout or item.itemid == pokein then local maxh = tonumber(getItemAttribute(item.uid, "poke"):match("/(.+)]")) doItemSetAttribute(item.uid, "poke", getItemAttribute(item.uid, "poke"):sub(1, findLetter(getItemAttribute(item.uid, "poke"), ".")) .. " HP = ["..maxh.."/"..maxh.."]") doTransformItem(item.uid, pokein) end end selfSay('Pronto, voce e seus pokemons estao com a life maxima.', cid) end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new()) Depois va ate a pasta data/npc e adicione um arquivo.xml e bote isso dentro: <?xml version="1.0" encoding="UTF-8"?> <npc name="Pokemon Healer" script="pokehealer.lua" walkinterval="2000" floorchange="0"> <health now="100" max="100"/> <look type="128" head="17" body="54" legs="114" feet="0" addons="2"/> <parameters> <parameter key="message_greet" value="Ola, diga {heal} para recuperar sua vida e a vida dos seus pokemons."/> </parameters> </npc> Surf System By: MatheusMkalo Vá em data/actions/scripts e crie um arquivo.lua com o nome de surf e bote esse script dentro: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- function onUse(cid, item, frompos, item2, topos) local configs = { [4647] = {x = -2, y = 0}, -- 4647 é o id da borda oeste (lado esquerdo do player) [4645] = {x = 2, y = 0}, -- 4645 é o id da borda leste (lado direito do player) [4646] = {x = 0, y = 2}, -- 4646 é o id da borda sul (abaixo do player) [4644] = {x = 0, y = -2}, -- 4644 é o id da borda norte (acima do player) } local playerpos = getCreaturePosition(cid) local pokes = { ["Dragon"] = {lookType=267, speed = 1500}, ["Rat"] = {lookType=267, speed = 500}, } if #getCreatureSummons(cid) <= 0 and getPlayerStorageValue(cid, 63215) <= 0 then return doPlayerSendCancel(cid, "You need a pokemon to surf.") end l = false for i,x in pairs(pokes) do if getPlayerStorageValue(cid, 63215) <= 0 and i:lower() == getCreatureName(getCreatureSummons(cid)[1]):lower() then l = true end end if not l and getPlayerStorageValue(cid, 63215) <= 0 then return doPlayerSendCancel(cid, "This pokemon can't surf.") end if getPlayerStorageValue(cid, 63215) <= 0 then doTeleportThing(cid, {x=playerpos.x+configs[item2.itemid].x, y=playerpos.y+configs[item2.itemid].y, z=playerpos.z}) setPlayerStorageValue(cid, 63215, 1) doSetCreatureOutfit(cid, pokes[getCreatureName(getCreatureSummons(cid)[1])], -1) doCreatureSay(cid, "Let's surf, "..getCreatureName(getCreatureSummons(cid)[1]), 1) setPlayerStorageValue(cid, 61209, getCreatureMaxHealth(getCreatureSummons(cid)[1])) setPlayerStorageValue(cid, 61210, getCreatureHealth(getCreatureSummons(cid)[1])) doChangeSpeed(cid, pokes[getCreatureName(getCreatureSummons(cid)[1])].speed) doRemoveCreature(getCreatureSummons(cid)[1]) else doTeleportThing(cid, {x=playerpos.x-configs[item2.itemid].x, y=playerpos.y-configs[item2.itemid].y, z=playerpos.z}) setPlayerStorageValue(cid, 63215, 0) doRemoveCondition(cid, CONDITION_OUTFIT) local item = getPokeOutLive(cid)[1] doCreatureSay(cid, "Im tired of surf, " .. getItemAttribute(item, "poke"):match("This is (.-)'s pokeball."), 1) pk = doSummonCreature(getItemAttribute(item, "poke"):match("This is (.-)'s pokeball."), getThingPosition(cid)) doConvinceCreature(cid, pk) registerCreatureEvent(pk, "DiePoke") registerCreatureEvent(cid, "PlayerPokeDeath") registerCreatureEvent(cid, "LogoutPoke") setCreatureMaxHealth(pk, getPlayerStorageValue(cid, 61209)) doCreatureAddHealth(pk, getPlayerStorageValue(cid, 61209)) doCreatureAddHealth(pk, getPlayerStorageValue(cid, 61210)-getPlayerStorageValue(cid, 61209)) doChangeSpeed(cid, getCreatureBaseSpeed(cid)-getCreatureSpeed(cid)) end return TRUE end Depois va em actions.xml e adicione essa tag: <action itemid="4647;4645;4646;4644" event="script" value="surf.lua"/> Ensinarei nos tutorias como adicionar novas bordas e botar cada pokemon com seu proprio outfit na agua. OBS:Todos os scripts mudaram para implementar o surf, atualize-os OBS2: Para funcionar o id da agua tem que ser 4820. Para usar basta clicar na borda da agua. Evolution System By: MatheusMkalo Vá em data/actions/scripts e adicione um script.lua com o nome de evolution.lua e bote esse script: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon System By Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon System By Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- local pokes = { ["Dragon"] = {level = 1, evolution = "Dragon Lord", maxh = 2000}, } local types = { ["Water"] = {itemid = 2277, "Horsea", "Goldeen", "Magikarp"}, ["Venom"] = {itemid = 2278, "Zubat", "Ekans"}, ["Thunder"] = {itemid = 2279, "Magnemite", "Pikachu"}, ["Rock"] = {itemid = 2280, "Geodude", "Graveler"}, ["Punch"] = {itemid = 2281, "Machop", "Machoke"}, ["Leaf"] = {itemid = 2276, "Ivysaur"}, ["Fire"] = {itemid = 2283, "Charmander", "Charmeleon", "Dragon"}, ["Coccon"] = {itemid = 2284, "Caterpie", "Metapod"}, ["Crystal"] = {itemid = 2285, "Dratini", "Dragonair"}, ["Darkness"] = {itemid = 2286, "Gastly", "Haunter"}, ["Earth"] = {itemid = 2287, "Cubone"}, ["Enigma"] = {itemid = 2288, "Abra", "Kadabra"}, ["Heart"] = {itemid = 2289, "Rattata", "Pidgey"}, ["Ice"] = {itemid = 2290, "Seel"}, } function onUse(cid, item, frompos, item2, topos) for i,x in pairs(types) do if item.itemid == x.itemid then if isCreature(item2.uid) then if isPlayerSummon(cid, item2.uid) then if table.find(x, getCreatureName(item2.uid)) then if getPlayerLevel(cid) >= pokes[getCreatureName(item2.uid)].level then local pokeball = getPokeOutLive(cid)[1] local slo = pokes[getCreatureName(item2.uid)].maxh local sle = pokes[getCreatureName(item2.uid)].evolution doItemSetAttribute(pokeball, "description", "Contains a " .. pokes[getCreatureName(item2.uid)].evolution) doPlayerSendTextMessage(cid, 27, "Your "..getCreatureName(item2.uid).." evolued to a "..pokes[getCreatureName(item2.uid)].evolution) doSendMagicEffect(topos, 18) doItemSetAttribute(pokeball, "poke", "") doItemSetAttribute(pokeball, "poke", "This is "..pokes[getCreatureName(item2.uid)].evolution.."'s pokeball. HP = ["..pokes[getCreatureName(item2.uid)].maxh.."/"..pokes[getCreatureName(item2.uid)].maxh.."]") doRemoveCreature(item2.uid) local pk = doSummonCreature(sle, topos) registerCreatureEvent(pk, "DiePoke") registerCreatureEvent(cid, "PlayerPokeDeath") registerCreatureEvent(cid, "LogoutPoke") doConvinceCreature(cid, pk) setCreatureMaxHealth(pk, slo) setPlayerStorageValue(cid, 61204, 1) doCreatureAddHealth(pk, slo) doRemoveItem(item.uid, 1) break else return doPlayerSendCancel(cid, "You need to be level "..pokes[getCreatureName(item2.uid)].level.." or higher to use this stone in this pokemon.") end end end end end end return TRUE end Depois vá em actions.xml e adicione esta tag: <action itemid="2276;2277;2278;2279;2280;2281;2283;2284;2285;2286;2287;2288;2289;2290" event="script" value="evolution.lua" allowfaruse="1"/> Fly System By: MatheusMkalo, Credits: Mock Vá em data/talkactions/scripts e adicione um arquivo.lua com o nome de fly e bote esse script: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon Systems by Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon Systems by Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- function onSay(cid, words, param) local pokes = { ["Dragon"] = {lookType = 216, speed = 500}, } if #getCreatureSummons(cid) <= 0 and getPlayerStorageValue(cid, 62314) <= 0 then doPlayerSendCancel(cid, "You need a pokemon to fly.") end if getPlayerStorageValue(cid, 62314) <= 0 and not pokes[getCreatureName(getCreatureSummons(cid)[1])] then return doPlayerSendCancel(cid, "This pokemon can't fly.") end if getPlayerStorageValue(cid, 62314) <= 0 then doSetCreatureOutfit(cid, pokes[getCreatureName(getCreatureSummons(cid)[1])], -1) doChangeSpeed(cid, pokes[getCreatureName(getCreatureSummons(cid)[1])].speed) setPlayerStorageValue(cid, 61263, getCreatureMaxHealth(getCreatureSummons(cid)[1])) setPlayerStorageValue(cid, 61262, getCreatureHealth(getCreatureSummons(cid)[1])) setPlayerStorageValue(cid, 62314, 1) registerCreatureEvent(cid, "LogoutPoke") doCreatureSay(cid, "Let's fly, "..getCreatureName(getCreatureSummons(cid)[1]), 1) doRemoveCreature(getCreatureSummons(cid)[1]) local ppos = getCreaturePos(cid) local newpos = {x=ppos.x, y=ppos.y, z = 0} doCreateTile(460, newpos) doTeleportThing(cid, newpos) for i = 1,8 do doItem(getPosDirs(getCreaturePosition(cid), i), 65119+i) end elseif getPlayerStorageValue(cid, 62314) >= 1 then local ppos = getCreaturePosition(cid) p = true for i = 1,17 do if getTileThingByPos({x=ppos.x, y=ppos.y, z=ppos.z+i}).itemid ~= 0 and not isWalkable({x=ppos.x, y=ppos.y, z=ppos.z+i}) then p = false break end if isWalkable({x=ppos.x, y=ppos.y, z=ppos.z+i}) then l = ppos.z + i break end end if not p or getTileThingByPos({x=ppos.x, y=ppos.y, z=l}).itemid == 4820 then return doPlayerSendCancel(cid, "You can't down in there.") end for i = 1,8 do doRemoveTile(getPosDirs(getCreaturePosition(cid), i)) end setPlayerStorageValue(cid, 62314, 0) doTeleportThing(cid, {x=ppos.x, y=ppos.y, z=l}) doRemoveTile(ppos) local item = getPokeOutLive(cid)[1] pk = doSummonCreature(getItemAttribute(item, "poke"):match("This is (.-)'s pokeball."), getThingPosition(cid)) doConvinceCreature(cid, pk) doCreatureSay(cid, "I'm tired of fly, "..getItemAttribute(item, "poke"):match("This is (.-)'s pokeball."), 1) registerCreatureEvent(pk, "DiePoke") registerCreatureEvent(cid, "PlayerPokeDeath") setCreatureMaxHealth(pk, getPlayerStorageValue(cid, 61263)) doCreatureAddHealth(pk, getPlayerStorageValue(cid, 61263)) doCreatureAddHealth(pk, getPlayerStorageValue(cid, 61262)-getPlayerStorageValue(cid, 61263)) doChangeSpeed(cid, getCreatureBaseSpeed(cid)-getCreatureSpeed(cid)) doRemoveCondition(cid, CONDITION_OUTFIT) end return TRUE end Depois bote essa tag no talkaction.xml: <talkaction words="!fly" event="script" value="fly.lua"/> Va em data/movements/scripts e crie um arquivo.lua com o nome de fly.lua e bote: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon Systems by Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon Systems by Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- function onStepIn(cid, item, position, fromPosition) local actions = { [65120] = {del = {4,5,6}, add = {1,2,8}}, [65121] = {del = {8,7,6,5,4}, add = {8,1,2,3,4}}, [65122] = {del = {8,7,6}, add = {2,3,4}}, [65123] = {del = {2,1,8,7,6}, add = {6,5,4,3,2}}, [65124] = {del = {2,1,8}, add = {4,5,6}}, [65125] = {del = {8,1,2,3,4}, add = {8,7,6,5,4}}, [65126] = {del = {2,3,4}, add = {8,7,6}}, [65127] = {del = {6,5,4,3,2}, add = {6,7,8,1,2}}, } local configs = actions[item.actionid] for i = 1,8 do if table.find(configs.del, i) then doRemoveTile(getPosDirs(fromPosition, i)) end doItem(getPosDirs(getCreaturePosition(cid), i), 65119+i) end return TRUE end Depois va em movements.xml e adicione essa tag: <movevent type="StepIn" actionid="65120;65121;65122;65123;65124;65125;65126;65127" event="script" value="fly.lua"/> Para usar o fly diga !fly para descer e subir Ride System By: MatheusMkalo Vá em talkactions/scripts e crie um arquivo.lua com o nome de ride e bote esse script: --[[ This file is part of Pokemon Systems by Mkalo. Pokemon Systems by Mkalo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Pokemon Systems by Mkalo is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Pokemon Systems by Mkalo. If not, see <http://www.gnu.org/licenses/>. ]]-- function onSay(cid, words) local pokesride = { ["Dragon Lord"] = {lookType=4, speed = 3000}, ["Dragon"] = {lookType=4, speed = 500}, } if #getCreatureSummons(cid) <= 0 and getPlayerStorageValue(cid, 59987) <= 0 then return doPlayerSendCancel(cid, "You need a pokemon to ride.") end if not canSummon(cid) and getPlayerStorageValue(cid, 59987) >= 1 then return doPlayerSendDefaultCancel(cid, RETURNVALUE_NOTENOUGHROOM) end local sname = #getCreatureSummons(cid) >= 1 and getCreatureName(getCreatureSummons(cid)[1]) or nil if sname ~= nil and pokesride[sname] and getPlayerStorageValue(cid, 59987) <= 0 then doSetCreatureOutfit(cid, pokesride[sname], -1) doChangeSpeed(cid, pokesride[sname].speed) doCreatureSay(cid, "Let's ride, " .. sname, 1) setPlayerStorageValue(cid, 59987, 1) setPlayerStorageValue(cid, 59988, getCreatureHealth(getCreatureSummons(cid)[1])) setPlayerStorageValue(cid, 59989, getCreatureMaxHealth(getCreatureSummons(cid)[1])) doRemoveCreature(getCreatureSummons(cid)[1]) elseif getPlayerStorageValue(cid, 59987) >= 1 then setPlayerStorageValue(cid, 59987, 0) doRemoveCondition(cid, CONDITION_OUTFIT) local item = getPokeOutLive(cid)[1] doCreatureSay(cid, "Im tired of ride, " .. getItemAttribute(item, "poke"):match("This is (.-)'s pokeball."), 1) pk = doSummonCreature(getItemAttribute(item, "poke"):match("This is (.-)'s pokeball."), getThingPosition(cid)) doConvinceCreature(cid, pk) registerCreatureEvent(pk, "DiePoke") registerCreatureEvent(cid, "PlayerPokeDeath") registerCreatureEvent(cid, "LogoutPoke") setCreatureMaxHealth(pk, getPlayerStorageValue(cid, 59989)) doCreatureAddHealth(pk, getPlayerStorageValue(cid, 59989)) doCreatureAddHealth(pk, getPlayerStorageValue(cid, 59988)-getPlayerStorageValue(cid, 59989)) doChangeSpeed(cid, getCreatureBaseSpeed(cid)-getCreatureSpeed(cid)) end return TRUE end Agora bote essa tag em talkactions.xml: <talkaction words="!ride" event="script" value="ride.lua"/> Pra usar o ride é so falar !ride. Para configurar os pokemons é praticamente igual ao surf. Configurando os scripts Como adicionar mais pokemons no go/back: No inicio do script, tem essa tabela com as informaçoes: Copie a ultima linha (vermelha) e cole logo abaixo, editando os nomes e as mensagens ficando assim: Voce pode configurar o level para usar o poke mudando o valor de level. Configurando pokemons para o catch:[/b] Olhe a tabela no inicio do script: Faça o mesmo processo do acima de copiar e colar embaixo e editar: Aonde as informaçoes corpseid, chance, health, maxhealth serao, respectivamente: Id do corpo do monstro, Chance de capturar em %, health que o pokemon iria ir pro player, e health maxima que o poke iria ir para o player. Como trocar os ids das pokebolas, acesas e apagadas. Para trocar o id da pokebola "acesa" e "apagada" basta mudar os ids 2222,2223 na lib sendo que 2222 eh o da acesa e o 2223 eh o id da apagada Mude tambem na tag do action.xml que seu script ira funcionar perfeitamente. Como adicionar mais bordas ao surf. Primeiramente va em actions.xml e adicione os ids das bordas na tag do surf: (Eu fiz com a borda de areia) Depois va no script surf.lua em actions e repare nessa parte: Copie todas as 4 bordas e cole abaixo ficando: Depois mude os ids das bordas do lado << conforme as informaçoes do lado >>, ficando: Como adicionar mais pokes ao surf: Va no script surf.lua em actions e repare nessa parte: Ai voce pode adicionar o pokemon pra surf e o outfit que ele vai te dar na agua copiando o de cima e colando logo abaixo e editando algumas coisas: Lembre-se de depois que acabar de editar toda a tabela no surf.lua, va no goback.lua em creaturescripts e substitua a tabela pokes, pela que esta na actions surf.lua: Como adicionar mais pokes no evolution: Repare nessa parte do script evolution.lua em actions: Bem voce deve copiar o primeiro monstro da tabela "pokes", e adicionar no final e mudar as configuraçoes: Sendo level,evolution,maxh respectivamente, o level pra evoluir o poke, o nome da evoluçao, e a health maxima do pokemon evoluido. Depois eh so adicionar o Nome do monstro que foi adicionado a tabela "pokes" na tabela "types", no lugar do type dele: Como adicionar mais pokes no fly: Repare nas partes iguais no fly.lua (talkaction) e no goback.lua(creaturescripts): fly.lua: goback.lua: A unica coisa que mudou foi o nome da tabela, "pokes" e "pokesfly", para adicionar mais pokes no fly basta adicionar no fly.lua e botar igual no goback.lua. Informaçoes Importantes!!! Para testar o script de catch que esta no topico, voce deve deletar as tags de encantamento de armas. Para poder summonar os pokemons com o go/back, voce precisa ir no arquivo.xml do monstro e editar essa linha: Se estiver convinceable="0", mude para convinceable="1" ficando: Creditos Especiais: Kydrai pela funçao "getItemsInContainerById" MarcelloMkez Mock por algumas funçoes do fly system dele. Agradecimentos: D3rs00n (Me ajudou a fazer sumir o corpo do pokemon) Julio Cezar (Ajudou reportando bugs e testando scripts) Miih (Ajudou reportando bugs e testando scripts) Arth3miS (Ajudou reportando bugs e testando scripts) E para todos que reportaram bugs. Bugs, erros, duvidas, elogios no topico[/b]
    1 ponto
  12. Versão: 8.5x and 8.6x 1- Vá "Pasta Servidor > Data > Actions > Liquids" e Procure pelo arquivo "potion.lua" e abra ele. 2- Depois de aberto procure por: [8704] = {empty = 7636, splash = 2, health = {50, 100}}, -- small health potion 3- Copie o primeiro ID da linha (no caso 8704) e coloque-o no lugar do ID que se encontra depois de "empty = " (no caso 7636) Ficará assim: [8704] = {empty = 8704, splash = 2, health = {50, 100}}, -- small health potion Depois faça isso com todas as outras linhas de potions. Espero Ter Ajudado. Topico Alterado: 30/09/12
    1 ponto
  13. Vodkart

    [Mod] Map Change 2.0

    é um script que muda de mapa a cada X horas(ou minutos) Creditos: Vodkart e Demonbholder que me ajudo *-* na pasta mods crie um arquivo.xml e renomeie para ChangeMap.xml <?xml version="1.0" encoding="ISO-8859-1"?> <mod name="ChangeMap" version="2.0" author="Vodkart" contact="none.com" enabled="yes"> <config name="map_func"><![CDATA[ info = { [0] = 1, [1] = 3, [2] = 4 } storage = 789520 ]]></config> <event type="login" name="Check Map" event="script"><![CDATA[ domodlib('map_func') function onLogin(cid) if getGlobalStorageValue(storage) == -1 then setGlobalStorageValue(storage, 0) end doTeleportThing(cid, getTownTemplePosition(info[getGlobalStorageValue(storage)])) return true end ]]></event> <globalevent name="ChangeMap" interval="3600" event="script"><![CDATA[ domodlib('map_func') function onThink(interval, lastExecution) doBroadcastMessage('The map will be changed again in 1 hour.') setGlobalStorageValue(storage, getGlobalStorageValue(storage) < #info and getGlobalStorageValue(storage)+1 or 0) for _, pid in ipairs(getPlayersOnline()) do doPlayerSetTown(pid, info[getGlobalStorageValue(storage)]) doRemoveConditions(pid, true) doCreatureAddHealth(pid, getCreatureMaxHealth(pid)) doCreatureAddMana(pid, getCreatureMaxMana(pid)) doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid))) end return true end]]></globalevent> </mod> Explicação: No info é o id das town para adicionar mais mapas é só colocar uma virgula no último e adicionar o novo town_id [3] = 5, [4] = ?? e o tempo você muda nessa parte interval="3600" no caso está para 1 hora
    1 ponto
  14. Vodkart

    Npc Pokemoncollector Funcionando

    Explicação: é dada uma lista na ordem alfabética com os pokemons que esse NPC compra,depois disso há 2 versões V 1.0 --[[ PokeServer ]] -- : basta dizer o nome do pokemon que você quer vender e colocar o mesmo no slot da pokebola... V 2.0 --[[ Pokemon Dash --]] : a pokebola tem que estar dentro da backpack,com a função "sellPokemon(cid, name, price)" que não é minha NPC/SCRIPT buy_pokemons.lua V 1.0 V 2.0 NPC Comprador.xml <?xml version="1.0"?> <npc name="Comprador" script="data/npc/scripts/buy_pokemons.lua" walkinterval="5000" floorchange="0"> <health now="100" max="100"/> <look type="134" head="78" body="88" legs="0" feet="88" addons="3"/> <parameters> <parameter key="message_greet" value="Ola |PLAYERNAME|. quer me vender alguns {pokemon}? " /> </parameters> </npc>
    1 ponto
  15. Eae Galera :tongue2: Agora Venho Mostrar A Versão 2 Desse Script Disseram Qe Ficaria Mais Legal Assim Podendo Cortar Varias Arvores E Ganhando Variios Items Esta Ai O Script Espero qe Gostem Adicionei Qase Todas As Arvores. Testado Em: Snowz Thyranic 3.1 (8.6) Data/Actions/Script Crie Um Arquivo Lua Renomeie Para Corte E Adicione Depois Em Data/Actions/Actions.xml Adicione Espero Qe Gostem Se Gostou Rep+ Vlw Abrass :positive: Agradesso A Um Parceiro Qe Sempre Me Ajudou A Aprender Lua Não Vou Citar Nome! Vlw ^^
    1 ponto
  16. Rep+ é só clicar no verde embaixo do meu post ;* No caso, você deve estar usando a versão 8.7 do RME, ela está bugada ainda, ela deveria vir com o creatures.xml Aconselho pegar a versão antiga, ou baixar o SimoneMapEditor. Obs: Mais de 5 pessoas no meu msn estão com o mesmo problema. Novamente, aconselho o SimoneMapEditor ele vem com o creatures.xml e é bem mais fácil Qualquer coisa: kamui_lg@hotmail.com
    1 ponto
  17. Demonbholder

    [Mod] Map Change 2.0

    Ficou ótimo cara, não posso mais dar rep+ hoje, mas com certeza tem o meu garantido.
    1 ponto
  18. É, mas se ele pedir algo de novo, e alguém pedir pra ele substituir o login.lua por um outro, o script não irá mais funcionar, por isso não é aconselhável colocar no login.lua mesmo. @Topic Vou reportar para moverem.
    1 ponto
  19. Olaa Galera Estava Sem Nada Para Fazer Resolvi Fazer Um Script Facil Mas Legalzinho Ate Funciona Assim O Player Pega O Item 2558 E Corta A Arvore Não Pode Corta Todas As Arvores Apenas Uma Qe Eh Ah 2768 Qando Ele Corta Ele Tem Chance De Receber Um Item Eu Coloquei O 2148 Que Eh O Gold Coins Isso Se Você Quiser Mudar Você Mude A Arvore Nasce Sozinha Qando O Player Corta. Testado Em: Snowz Thyranic 3.1 (8.6) Então Vamos Lah :positive: Data/Actions/Scrips Copie Um Arquivo Lua Renomeie Para Corte E Adiciona Depois Em Data/Actions/Actions.xml Adicione Espero Qe Gostem Se Gostou Rep+ Vlw Abrass
    1 ponto
  20. KamuiRunt

    Duvida Remeres Map Editor 2.1

    Vá na pasta do editor, abra o creatures.xml O meu está assim: <creatures> --Npcs-- <creature looktype="131" name="Aldo" head="25" body="103" legs="52" feet="99" type="npc"/> <creature looktype="128" name="Athan" head="20" body="100" legs="50" feet="99" type="npc"/> <creature looktype="141" name="Bianca" head="78" body="79" legs="0" feet="72" addons="1" type="npc"/> <creature looktype="253" name="Bill the Messager" head="38" body="79" legs="107" feet="114" type="npc"/> <creature looktype="128" name="Dark Rodo" head="78" body="71" legs="82" feet="114" type="npc"/> <creature looktype="128" name="Dufi" head="130" body="112" legs="112" feet="76" type="npc"/> <creature looktype="206" name="Fargo" head="123" body="123" legs="123" feet="21" addons="3" type="npc"/> <creature looktype="57" name="Guild Master" head="114" body="113" legs="113" feet="113" type="npc"/> <creature looktype="133" name="Johnny" head="114" body="119" legs="132" feet="114" type="npc"/> <creature looktype="128" name="Joseph" head="57" body="32" legs="49" feet="114" type="npc"/> <creature looktype="134" name="Killer Guard" head="0" body="20" legs="5" feet="115" addons="3" type="npc"/> <creature looktype="128" name="Lector" head="20" body="100" legs="50" feet="99" type="npc"/> <creature looktype="129" name="Mad" head="76" body="114" legs="124" feet="86" type="npc"/> <creature looktype="128" name="Obi" head="78" body="71" legs="82" feet="114" type="npc"/> <creature looktype="128" name="Padre" head="79" body="79" legs="79" feet="79" type="npc"/> <creature looktype="12" name="Papai Noel" head="20" body="30" legs="40" feet="50" type="npc"/> <creature looktype="128" name="Perac" head="66" body="46" legs="2" feet="89" type="npc"/> <creature looktype="266" name="Rex" head="0" body="30" legs="40" feet="115" addons="0" type="npc"/> <creature looktype="266" name="Rex2" head="0" body="30" legs="40" feet="115" addons="0" type="npc"/> <creature looktype="128" name="Seller" head="20" body="30" legs="40" feet="50" type="npc"/> <creature looktype="134" name="Varkhal" head="0" body="95" legs="95" feet="95" type="npc"/> <creature looktype="134" name="Vip" head="0" body="95" legs="95" feet="95" type="npc"/> </creatures> Basta apenas você remover todos os que tiverem com type="npc" Feito isso, ele "limpará" Dúvidas? Mande um e-mail Te ajudei? Rep+ Abraços.
    1 ponto
  21. Demonbholder

    Como Criar Quest

    Põe uma actionid no baú pelo mapeditor. Depois adiciona isso em actions.xml <action actionid="AID" event="script" value="NomeDoArquivo.lua"/> É isso, até.
    1 ponto
  22. Arg, bom saber que copiam até a cor da minha cueca Q__Q Cara, muito obrigado, mas o OT não é meu, eu estou resolvendo aqui com ele, como eu vejo se tem algum player bugado? Abraço, obrigado, ja dei um +REP O rep + deveria ser dirigido a mim rs. O que você colocou foi: Tanbem pode ser algum char bugado tipo tem muitas pessoas que bugam ai vai atacar algum bicho o serv buga eh cai meu ot tanbem tava tendo esse problema..Erram dois players bugado ^^ OBS:Peguei essa resposta do KamuiRunt eh dei uma pequena implementada O que não tem nexo, sem contar os erros ortográficos. Seu post, foi sem sentido, e foi reportado. Obs: Obg pelo toque CMGabriel, t+
    1 ponto
  23. Cara Você Não Pode Dar ctrl+c No Post Do KamuiRunt E Colar Em Um Tópico! Você Foi Simplesmente Inutil! ~REPORTADO~ Abraços.
    1 ponto
  24. tem mais e se o jogador matar o monstro? é só fazer um tile ali debaixo ou uma alanvaca pra checa se o monstro esta naquela area,caso ele esteja e removido e a quest segue normal.
    1 ponto
  25. KamuiRunt

    Mudança De Mapa

    Tem sim. Só pegar o itens.otbm da pasta do seu editor, e colar na pasta do seu ot em: data/itens itens.otbm. Obs: Por preocaução, faça um backup antes ok? Lembrando que: Se os itens no ot for 1, e no editor for outro, faça o mesmo procedimento com o itens.xml Dúvidas? Mande um e-mail. Te ajudei? Rep+ Abraços.
    1 ponto
  26. Vodkart

    Remover Frags.

    fiz uma talk de exemplo. function onSay(cid, words, param) if db.executeQuery("UPDATE killers SET unjustified = 0 WHERE id NOT IN (SELECT kill_id FROM player_killers WHERE player_id NOT IN (SELECT id FROM players));") then return doPlayerSendTextMessage(cid,MESSAGE_STATUS_CONSOLE_BLUE,'Todos os frags do serve foram removidos!.') end return doPlayerSendCancel(cid, '[Error] não foi possivel deletar as frags do servidor') end
    1 ponto
  27. betinhowz666

    [Pedido] System M1 Ate O M11

    Aqui está. Ta com 147/151 m1 á m12 Não está configurado, Cd, Atkmin, Atkmax e Damage. Talkactions.xml <talkaction words="m1;m2;m3;m4;m5;m6;m7;m8;m9;m10;m11;m12" hide="yes" event="script" value="moves.lua"/> Faça um arquivo chamado moves.lua na pasta script
    1 ponto
  28. Fez alguma atualização? Colocou algum monster? Npc? Algo do tipo? Tem um npc, um tal de Rowenna, que é bugado e desliga o ot a cada "x" minutos. Obs: Há alguns npcs de "Auto-Mensagem" que estão bugados, e quando vão mandar a mensagem, derrubam o otserver na hora. Faça o seguinte, me diga o que foi feito de la para ca, e eu lhe direi o que fazer. Obs: Não há como isso ter ocorrido sem mais nem menos. Tanbem pode ser algum char bugado tipo tem muitas pessoas que bugam ai vai atacar algum bicho o serv buga eh cai meu ot tanbem tava tendo esse problema..Erram dois players bugado ^^ OBS:Peguei essa resposta do KamuiRunt eh dei uma pequena implementada
    1 ponto
  29. meromeromei

    Hunt Tanagar Morrendo.

    Olá galera do Xtibia,to aki trazendo mais uma hunt pra voces. vamos lá. Descrição. "Tanagar Guard say : Cuidado caro amigo,essa floresta nao é mais a mesma,sua riquieza em fauna e flora tornou-se um perigo para viajantes desalertados. Desde que certas criaturas tomaram a montanha sul e passaram a morar la tudo mudou,a vegetação não é mais a mesma,as criaturas estão sofrendo mutações,está tudo um caos !!O detalhe é que eles chegaram a apenas duas semanas,imagine daqui a um mes caro amigo,ajude-nos por favor." Link das imagens removido, Vilden. Hunt.rar é isso ae. minha net ta uma merda entao nao postarei scan,se alguem kizer faça por si mesmo que posto aki. abraços.
    1 ponto
  30. 306295

    [8.54] Mapa Pokemon Betinhowz666

    tipow, se tem os arquivos dos monstros certo?só nao ta no mapa editor né?se for esse o caso vai no mapa editor e vai em file/import e escolhe import monster/npc... ai se vai na pasta do ot que estao os pokemons.xml e pega td os pokes em falta(seleciona td de uma vez ai nao vai faltar nenhum :X)
    1 ponto
  31. Demonbholder

    Colocando Rainho Na Vocation

    Acho que assim funciona: function onLogin(cid) if getPlayerStorageValue(cid, 30023) == 4 then doEffect(cid) return TRUE end return TRUE end function doEffect(cid) local efeito = 3 local delay = 5 if isCreature(cid) == TRUE then doSendMagicEffect(getCreaturePosition(cid), efeito) addEvent(doEffect, delay*1000, cid) end return TRUE end Até mais.
    1 ponto
  32. - Preste mais atenção aonde você faz seus tópicos Area incorreta Reportado.
    1 ponto
  33. Kimoszin

    [Talkaction] Falar God...

    Cara tem esse Script --[[ @by Shynzo ]]-- local colors = { TEXTCOLOR_BLUE, TEXTCOLOR_LIGHTBLUE, TEXTCOLOR_LIGHTGREEN, TEXTCOLOR_TEAL, TEXTCOLOR_PURPLE, TEXTCOLOR_PLATINUMBLUE, TEXTCOLOR_LIGHTGREY, TEXTCOLOR_DARKRED, TEXTCOLOR_RED, TEXTCOLOR_ORANGE, TEXTCOLOR_YELLOW, TEXTCOLOR_WHITE_EXP } function onSay(cid, words, param) local playerpos = getPlayerPosition(cid) local random = math.random(1, #colors) if math.max(math.abs(playerpos.x-23), math.abs(playerpos.y-30)) < 9999 then doSendAnimatedText(playerpos, "GOD!", colors[random]) return 0 end return 1 end E assim no talkaction.xml <talkaction words="GOD" hide="yes" event="script" value="god.lua"/> Mais nao sei se funciona em TFS 8.70 Abraços.
    1 ponto
  34. refi

    [Moveevent] Tile Para Templo

    Legal Usado e Aprovado :positive:
    1 ponto
  35. SoulFamily, Acho que o modo mais simples mesmo, seria bloquear o uso de itens VIP para vocações não-VIP. Isso é feito dentro de dois arquivos XML: weapons e movements. O primeiro para armamentos em geral, o segundo para equipamentos. Ao abrir o primeiro arquivo, você irá deverá localizar estes tipos de tags nele, <melee id="ID DO ITEM" level="LEVEL REQUERIDO" unproperly="1" event="function" value="default"/> Para fazer com que apenas certas vocações usem o item, você deverá usar o tipo de tag abaixo, <melee id="ID DO ITEM" level="LEVEL REQUERIDO" unproperly="1" event="function" value="default"> <vocation id="ID DA VOCATION"/> </melee>] ID DO ITEM - ID do armamento VIP LEVEL REQUERIDO - Se houver, Level necessário para usar o item, ID DA VOCATION - Vocação que pode usar o item, você pode criar 'n' linhas para 'n' vocações. Agora vejamos o segundo arquivo, onde você encontrará tags que nem essas abaixo, <movevent type="Equip" itemid="ID DO ITEM" slot="SLOT" level="LEVEL" event="function" value="onEquipItem"/> Para restringir o uso a certas vocações, basta fazer tags parecidas com essas, <movevent type="Equip" itemid="ID DO ITEM" slot="SLOT" level="LEVEL" event="function" value="onEquipItem"> <vocation id="ID DA VOCATION"/> </moveevent> ID DO ITEM - ID do equipamento VIP. SLOT - O slot onde o item é equipado, se é uma armadura, o slot é 'armor' e assim por diante. Veja abaixo os slots: LEVEL - Level requerido para equipar o item, 0 se não for necessário. ID DA VOCATION - Vocação que pode usar o item, você pode criar 'n' linhas para 'n' vocações. Acho que é só isso, Abraços.
    1 ponto
  36. Kra por que vc nao vai se ferra sabe ler nao imbecil da proxima ve se leh direito seu noob..... :angry_smile:
    -1 pontos
Líderes está configurado para São Paulo/GMT-03:00
×
×
  • Criar Novo...