-
Total de itens
3406 -
Registro em
-
Última visita
-
Dias Ganhos
113
Tudo que Vodkart postou
-
usa o código de actions assim: function onUse(cid, item, fromPosition, itemEx, toPosition) if getPlayerVocation(cid) ~= 7 then return doPlayerSendCancel(cid, "you need to be a blacksmith.") elseif isInArray({0, 65535}, toPosition.x) then return doPlayerSendCancel(cid, "Sorry, not possible.") elseif getTileItemById(toPosition, 2555).uid == 0 then return doPlayerSendCancel(cid, "You must put your ingredients in an anvil.") end local obj = RecipeFromPosition(toPosition) if obj then obj:forge(cid, toPosition) if _FORGESYSTEM.useSkill == true then addForgeTry(cid) end else doPlayerSendCancel(cid, _FORGESYSTEM.prompt.invalidRecipe) end return true end no caso eu coloquei a vocation 7 para ser a de ferreiro, pode trocar '-'
-
coloca a talk do seu !buyvip aqui para que possamos modificar
-
--[[ SCRIPT BY: MarcelloMkez ]] function onUse(cid, item, pos, item2, topos) config = { ptemp ="yes", --[[ Teleportar para ciade principal "yes ou no". ]] townp ="no", --[[ Teleportar para Cidade onde o player mora, "yes ou no". ]] rmvitem ="no", --[[ Remover item quando for usado? "yes ou no". ]] vip ="yes", --[[ Precisa ser Premium Account para usar o item? "yes ou no" ]] batlle ="yes", --[[ Precisa estar sem Batlle para usar o item? "yes ou no "]] possibilidade = 1 , --[[ Possibilidade do player ser teleportado em porcentagem. ]] princ = {x=418, y=1406, z=7}, --[[ Posição da Cidade Principal. ]] pz ="yes" --[[ Precisa estar em Protection Zone para Usar o Magic Teleport? "yes ou no"]] } local p = getPlayerTown(cid) local townpos = getTownTemplePosition(p) local cityname = getTownName(p) local chance = math.random(1, 100) --[[ de 1 a 100 % de chance, Não mude. ]] local msgp ="~ "..getPlayerName(cid).." Foi Teleportado para Cidade Principal. ~" local msgt ="~ "..getPlayerName(cid).." Foi Teleportado para "..cityname..". ~" local fail ="'O Teleport Falhou.'" if(config.vip =="yes") and getPlayerStorageValue(cid, 13540) - os.time() <= 0 then return doPlayerSendCancel(cid, "Você precisa ser Vip Para usar o Teleport Magico.") elseif (config.batlle == "yes") and (getCreatureCondition(cid, CONDITION_INFIGHT) == TRUE) then return doPlayerSendCancel(cid, "Você precisa estar sem o batlle para usar o Teleport Magico.") elseif (config.pz =="yes") and (getTilePzInfo(getCreaturePosition(cid)) == FALSE) then return doPlayerSendCancel(cid, "Você precisa estar em Protection Zone para usar o Teleport Magico.") elseif (config.ptemp =="yes" and config.townp =="yes") then return doPlayerPopupFYI(cid, "'ERROR': Não é Possivel teleportar para duas cidades ao mesmo tempo.") --[[ Menssagem quando o player marcar 'yes' para as duas opçoes de teleport. ]] elseif chance >= 1 and chance <= config.possibilidade then doCreatureSay(cid, fail, TALKTYPE_ORANGE_1) return doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF) elseif(config.ptemp == "yes") then doTeleportThing(cid, config.princ) doCreatureSay(cid, msgp, TALKTYPE_ORANGE_1) return doSendMagicEffect(getPlayerPosition(cid), CONST_ME_MAGIC_RED) elseif(config.townp == "yes") then doTeleportThing(cid, townpos) doCreatureSay(cid, msgt, TALKTYPE_ORANGE_1) return doSendMagicEffect(getPlayerPosition(cid), CONST_ME_MAGIC_RED) end if(config.rmvitem =="yes") then doRemoveItem(item.uid, 1) end return TRUE end reportado, área incorreta
-
ta pra sair a cada 3 segundos(3000) effectevent[getPlayerGUID(cid)] = addEvent(doEffectPlayer, 3000, cid, effect) só mudar o 3000 ali para por exemplo 2 segundos = 2000
-
em login.lua adc antes do return true: -- effect vip effectevent = {} function doEffectPlayer(cid, effect) if not isCreature(cid) then return LUA_ERROR end doSendMagicEffect(getThingPos(cid), effect) effectevent[getPlayerGUID(cid)] = addEvent(doEffectPlayer, 3000, cid, effect) end if getPlayerStorageValue(cid, 13540) - os.time() > 0 then doEffectPlayer(cid, 45) end -- end effect vip doEffectPlayer(cid, 45) -- 45 é o n° do efeito que vai sair no player
-
Eu testei aqui e ele volta para a outfit original por causa dessa função: doRemoveCondition(cid, CONDITION_OUTFIT) ... você diz ficar com o looktype 3 também?
-
events = {} config = { sit = {hp = 5, mana = 5}, outfit = {lookType = 3}, storage = 21211 } function onSay(cid, words, param, channel) setPlayerStorageValue(cid, config.storage, getPlayerStorageValue(cid, config.storage) == -1 and 1 or -1) doCreatureSetNoMove(cid, getPlayerStorageValue(cid, config.storage) == 1 and true or false) if getPlayerStorageValue(cid, config.storage) == 1 then doPlayerSay(cid, "Ufa, Relaxando") doSetCreatureOutfit(cid, config.outfit, -1) doSendMagicEffect(getCreaturePosition(cid), CONST_ME_HOLYAREA) doSitRelax(cid, config.sit) else doPlayerSay(cid, "você ficou em pé") doRemoveCondition(cid, CONDITION_OUTFIT) stopEvent(events[getPlayerGUID(cid)]) end return true end function doSitRelax(cid, formula) if not isCreature(cid) then return LUA_ERROR end doCreatureAddHealth(cid, formula.hp) doCreatureAddMana(cid, formula.mana) doSendMagicEffect(getCreaturePosition(cid), CONST_ME_HOLYAREA) events[getPlayerGUID(cid)] = addEvent(doSitRelax, 5000, cid, formula) end
-
@vilden function onDeath(cid, corpse, deathList) if isPlayer(cid) and getPlayerSkullType(cid) < SKULL_RED and getPlayerBlessing(cid, 5) then doCreatureSetDropLoot(cid, false) end return true end eu coloquei só para checar a bless 5 porque ela que tem a função de não deixar perder loot '-'
-
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 local talkUser = NPCHANDLER_CONVbehavior == CONVERSATION_DEFAULT and 0 or cid local item,pos = 2123,{x=129, y=53, z=6} if (msgcontains(msg, 'travel') or msgcontains(msg, 'viajar'))then npcHandler:say("Você precisa ter na bag 1 "..getItemNameById(item).." para teleportar, você quer teleportar? {yes}", cid) talkState[talkUser] = 1 elseif msgcontains(msg, 'yes') and talkState[talkUser] == 1 then if getPlayerItemCount(cid, item) >= 1 then doTeleportThing(cid, pos) else npcHandler:say("Você não tem o item!", cid) end elseif msg == "no" then selfSay("Then not", cid) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) end return TRUE end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new())
-
creaturescript/script nome do seu script.lua function onCombat(cid, target) if isPlayer(cid) and isPlayer(target) then if getPlayerVocation(cid) < 9 and getPlayerVocation(target) > 8 or getPlayerVocation(cid) > 8 and getPlayerVocation(target) < 9 then doPlayerSendCancel(cid, "You may not attack.") return false end end return true end login.lua adc : registerCreatureEvent(cid, "VocationAttack") tag: <event type="combat" name="VocationAttack" event="script" value="nome do seu script.lua"/>
-
só editando pelas source mesmo, eu acho.
-
Pronto Editado =D ainda tem erro, só tirar "doRemoveCreature(cid)"
-
da pra ver que é seu mesmo, tem erro... vai kikar o jogador e mandar a msg pra quem?
-
1° Abra o programa Sqlite 2° Selecione a database do seu server, o arquivo é esse ".s3db", por exemplo o "forgottenserver.s3db" 3° na parte superior do programa tem a aba "Tools",clica nela e seleciona "Open SQL query editor" ou (ALT + E) se preferir 4° Vai abrir uma janela branca,nela você coloca isso: ALTER TABLE `accounts` ADD `premium_points` INT NOT NULL DEFAULT 0; 5° Depois clica no ícone do raio ali na parte de cima ou aperta o botão F9 que vai fazer com que a query seja executada.
-
function onSay(cid, words, param) local on = getPlayersOnline() for i = 1, #on do if getPlayerAccess(on[i]) < 3 then doTeleportThing(on[i], getTownTemplePosition(getPlayerTown(on[i]))) end end return true end
-
ficou lotado de gifs gays
-
porque seu pinto é grande cara? me explica
-
~~Sonhado~~ REP- Alertado em 10% por desrespeitar seu superior.
-
Membro alertado em 30% e suspenso por 15 dias. Tópico fechado.
-
@UP aqui está o magic wall mostrando o tempo: magic wall rune.lua local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_ENERGY) setCombatParam(combat, COMBAT_PARAM_CREATEITEM, 1497) function onCastSpell(cid, var) function MagicWallTime(pos, delay) doSendAnimatedText(pos, delay, 145) if delay ~= 1 then addEvent(MagicWallTime, 1000, pos, delay -1) end end local pos,duration = variantToPosition(var),20 MagicWallTime(pos,duration) return doCombat(cid, combat, var) end local pos,duration = variantToPosition(var),20 o 20 significa quanto a magic wall dura, só ver em items.xml '-'
-
@UP logo abaixo dessa linha: function sendGemEffect(cid, storage, interval) coloque: if not isCreature(cid) then return LUA_ERROR end
-
fiz rapidinho, vê se é isso que vc quer: Mods Saffari.xml <?xml version="1.0" encoding="UTF-8"?> <mod name="Saffari" version="1.0" author="Vodkart" contact="none.com" enabled="yes"> <config name="saffari_func"><![CDATA[ config = { Price = 2000, Premium = false, Level = 50, Saffari_Pos = {Enter = {x=189,y=53,z=7}, Exit = {x=195,y=53,z=7}}, Time = 30, AddPokeballs = {11445,30}, Blocked_pokeballs = {2146, 2147, 11437, 11441}, Storages = {874547,874548}, levelandskills = false, loot = false } ]]></config> <event type="login" name="SaffariRegister" event="script"><![CDATA[ function onLogin(cid) registerCreatureEvent(cid, "SaffariDeath") return true end]]></event> <talkaction words="/saffari;!saffari" event="buffer"><![CDATA[ domodlib('saffari_func') param = string.lower(param) if (param == "") then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE,"invalid command, for more information enter !saffari info") elseif(param == "info") then doShowTextDialog(cid,2160,"Saffari Info:\n\nLevel Minimum: "..config.Level.."\nSaffari Cost: "..config.Price.."\nTime Limit: "..config.Time.." minutes\n\nThe safari is home to rare creatures, some are dangerous and others not\n[*Warning*]\nis only allowed to enter with saffari balls.\n\nTo leave enter command:\n!saffari leave") elseif(param == "leave") then if getPlayerStorageValue(cid, config.Storages[1]) >= 1 then doTeleportThing(cid, config.Saffari_Pos.Exit) setPlayerStorageValue(cid, config.Storages[1], -1) setPlayerStorageValue(cid, config.Storages[2], -1) doPlayerSendTextMessage(cid,22,'you left the saffari zone.') else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE,"you are not in Saffari") end end return true ]]></talkaction> <globalevent name="SaffariCheck" interval="60" event="script"><![CDATA[ domodlib('saffari_func') function onThink(interval, lastExecution) local on = getPlayersOnline() if #on > 0 then for i = 1, #on do if getPlayerStorageValue(on[i], config.Storages[2]) <= os.time() and getPlayerStorageValue(on[i], config.Storages[1]) >= 1 then doTeleportThing(on[i], config.Saffari_Pos.Exit) setPlayerStorageValue(on[i], config.Storages[1], -1) setPlayerStorageValue(on[i], config.Storages[2], -1) doPlayerSendTextMessage(on[i],22,'you left the saffari zone.') end end end return true end ]]></globalevent> <event type="death" name="SaffariDeath" event="script"><![CDATA[ domodlib('saffari_func') function onDeath(cid, corpse, deathList) if isPlayer(cid) and getPlayerStorageValue(cid, config.Storages[1]) >= 1 then setPlayerStorageValue(cid, config.Storages[1], -1) setPlayerStorageValue(cid, config.Storages[2], -1) if config.loot == false then doCreatureSetDropLoot(cid, false) end if config.levelandskills == false then doPlayerSetLossSkill(cid, 0) end end return true end ]]></event> </mod> Npc domodlib('saffari_func') 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 local talkUser = NPCHANDLER_CONVbehavior == CONVERSATION_DEFAULT and 0 or cid local msg = string.lower(msg) if isInArray({"saffari","enter","entrar"}, msg) then npcHandler:say('you can stay in the Saffari zone by '..config.Time..' minutes, the price is '..config.Price..' gp(s), You want enter? {yes}', cid) talkState[talkUser] = 1 elseif msgcontains(msg, 'yes') and talkState[talkUser] == 1 then for i = 1, #config.Blocked_pokeballs do if getPlayerItemCount(cid, config.Blocked_pokeballs[i]) >= 1 then npcHandler:say('Keep your PokeBalls!', cid) return true end end if config.Premium == true and not isPremium(cid) then npcHandler:say('Sorry, you need to be premium!', cid) return true elseif getPlayerLevel(cid) < config.Level then npcHandler:say('Sorry, you must be at least level '..config.Level..' to enter the Saffari zone!', cid) return true elseif not doPlayerRemoveMoney(cid, config.Price) then npcHandler:say('Sorry, you do not have enough money!', cid) return true end doPlayerAddItem(cid, config.AddPokeballs[1], config.AddPokeballs[2]) selfSay("Thanks, you've been teleported to the Saffari zone and has "..config.Time.." minutes, if you want to leave enter {!saffari leave}.", cid) doTeleportThing(cid, config.Saffari_Pos.Enter) setPlayerStorageValue(cid, config.Storages[1], 1) setPlayerStorageValue(cid, config.Storages[2], os.time()+config.Time*60) elseif msg == "no" and talkState[talkUser] >= 1 then selfSay("tudo bem então.", cid) talkState[talkUser] = 0 npcHandler:releaseFocus(cid) end return TRUE end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new()) configurações config = { Price = 2000, -- qnto vai custar Premium = false, -- se precisa ser premium Level = 50, -- level minimo para entrar Saffari_Pos = {Enter = {x=189,y=53,z=7}, Exit = {x=195,y=53,z=7}}, -- pos da safari, e pos pra onde ele vai dps que acaba o tempo Time = 30, -- tempo maximo q ele pode ficar no saffari in minutes AddPokeballs = {11445,30}, -- id da saffari ball e quantidade Blocked_pokeballs = {2146, 2147, 11437, 11441}, -- pokeballs q ele n pode estar na bag Storages = {874547,874548}, -- n mexa levelandskills = false, -- se vai perder skills e exp ao morrer loot = false -- se vai perder loot ao morrer } comandos extra: !saffari info -- mostra em uma janela sobre o preço, lvl e o tempo que pode ficar lá !saffari leave -- faz com que o player saia da saffari zone
-
Quem Está Navegando 0 membros estão online
- Nenhum usuário registrado visualizando esta página.