
Tudo que xWhiteWolf postou
- Error de versão não compatível com o código.
- Critical
- (Resolvido)Talkaction Correr "Mensagem Para Poketibia
-
[8.6] Heromassa Server 2.0
não tive tempo pra testar tudo ainda mas pelo que andei vendo está muito decente. Meus parabéns e fico feliz de ter visto meu nome como um dos contribuintes pro projeto. Parabéns e obrigado
-
Taunt
@Vinicius Caetano desculpa a demora, entrei de férias e esqueci de checar os fóruns.. esse erro tá querendo dizer q seu servidor não tem a função doMonsterSetTarget.... que versão vc testou isso? vc saberia me responder se a sua source tem essa função compilada com outro nome? pq se tiver é só trocar na linha 280 da minha lib pelo nome correto que já resolve.
- [AJUDA] Shield que almenta o ataque !?
- [AJUDA] Shield que almenta o ataque !?
- Critical Skill System
-
(Resolvido)[Ajuda] Talk Transform
xWhiteWolf respondeu ao post em um tópico de jeffersonpetrolina em Suporte Tibia OTServer (Resolvidos)eu percebi que esse era o intuito porém pra fazer isso vc teria que fazer uma das gambiarras abaixo. Primeira gambiarra: criar várias conditions com % de vida pré-definidas e selecionar dentro do script qual aplicar (o motivo disso é q vc tem que criar as conditions quando o server abre, por isso elas ficam fora do escopo do script (fora do callback)) Segunda gambiarra: Utilizar a função setCreatureMaxHealth e colocar um addEvent pra setar a vida de volta ao normal. O problema desse segundo caso é q se vc tiver qualquer magia/script/mount que aumente a vida máxima do player vai dar pra ele usar esses dois combinados pra aumentar o tamanho da vida dele permanentemente. Se um dia vc for fazer alguma delas, sugiro que faça a primeira. Fica muito feio no código mas é a que tem menos chance de cagar, além do mais, player não vê script.
-
(Resolvido)[Ajuda] Talk Transform
xWhiteWolf respondeu ao post em um tópico de jeffersonpetrolina em Suporte Tibia OTServer (Resolvidos)tenta assim local from,to = {x=1001, y=705, z=7},{x=1031, y=737, z=7} -- começo e final do mapa local from2,to2 = {x=1011, y=705, z=6},{x=1031, y=738, z=6} -- começo e final do mapa local from3,to3 = {x=1012, y=706, z=5},{x=1032, y=739, z=5} -- começo e final do mapa local from4,to4 = {x=985, y=598, z=7},{x=1044, y=652, z=7} -- começo e final do mapa local from5,to5 = {x=986, y=615, z=6},{x=1039, y=647, z=7} -- começo e final do mapa local from6,to6 = {x=990, y=616, z=5},{x=1040, y=647, z=5} -- começo e final do mapa local config = { --[vocation id] = { level, nova voc, looktype} [1] = { 1, 2, 398, 13, 30}, [2] = { 80, 3, 399, 13, 30} } local tempo = 60 * 1000 local condition = createConditionObject(CONDITION_ATTRIBUTES) setConditionParam(condition, CONDITION_PARAM_TICKS, tempo) setConditionParam(condition, CONDITION_PARAM_STAT_MAXHEALTHPERCENT, 110) -- 110% da vida setConditionParam(condition, CONDITION_PARAM_BUFF, true) function onSay(cid, words, param, channel) if isInRange(getCreaturePosition(cid), from, to) or isInRange(getCreaturePosition(cid), from2, to2) or isInRange(getCreaturePosition(cid), from3, to3) or isInRange(getCreaturePosition(cid), from4, to4) or isInRange(getCreaturePosition(cid), from5, to5) or isInRange(getCreaturePosition(cid), from6, to6) then doPlayerSendCancel(cid, "Você não pode se Transformar nesta área!") return true end doPlayerSay(cid, "transformar") local voc = config[getPlayerVocation(cid)] if voc then if getPlayerLevel(cid) >= voc[1] then registerCreatureEvent(cid, "stordeath") setPlayerStorageValue(cid, voc_stor, getPlayerVocation(cid)) doPlayerSetVocation(cid, voc[2]) addEvent(doPlayerSetVocation,tempo,cid,getPlayerStorageValue(cid, voc_stor)) addEvent(setPlayerStorageValue,tempo,cid,voc_stor,0) doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Você Transformou!") local outfit = {lookType = voc[3]} doSetCreatureOutfit(cid, outfit, tempo) doSendMagicEffect(getCreaturePosition(cid), voc[4]) local efeito = voc[5] local function meffect(cid,t) if isPlayer(cid) and t ~= 0 then doSendMagicEffect(getThingPos(cid), efeito) addEvent(meffect, 1000, cid, (t - 1)) end end meffect(cid,(tempo/1000)) doAddCondition(cid, condition) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Você precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Você não pode se Transformar!") end return true end
-
Ajuda com Item
<action itemid="2263" script="bombita.lua" allowfaruse="1"/> deixa a tag assim
-
Ajuda com Item
não to conseguindo comentar nesse tópico, fica indo pra baixo daquela primeira resposta minha... mas a resposta tá ali já.
-
Ajuda com Item
@pablobion local config = { itemid = 2180, -- id da bomba duration = 1, -- duration antes de ser removida effect1 = 3, -- efeito que sai ao colocar a bomba msg1 = "Bomba ativada!", -- mensagem que sai ao ser colocado a bomba effect2 = 5 -- efeito ao explodir } local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, config.effect2) setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) -- formula local arr = { {0, 1, 0}, {1, 3, 1}, -- area que vai acertar ao explodir a bomba {0, 1, 0}, } local area = createCombatArea(arr) setCombatArea(combat, area) local function removeBomba(cid, pos, id) local item = getTileItemById(pos, id) if item.uid > 0 then local player = getPlayerByNameWildcard(getItemAttribute(item.uid, 'ref')) if isCreature(player) then doCombat(player, combat, { pos = pos, type = 2 }) end doRemoveItem(item.uid) end return true end local fpos = {x = 160, y = 54, z = 7} -- pos da area < /\ local tpos = {x = 189, y = 20, z = 7} -- pos da area > \/ function onUse(cid, item, fromPosition, itemEx, toPosition) if not isInRange(fromPosition, fpos, tpos) then doPlayerSendCancel(cid, "You're out of the permitted area.") return true end local item = doCreateItem(config.itemid, 1, toPosition) doItemSetAttribute(item, 'ref', getCreatureName(cid)) doCreatureSay(cid, config.msg1, 20) doSendMagicEffect(toPosition, config.effect1) addEvent(removeBomba, config.duration * 1000, cid, toPosition, config.itemid) return true end não.. tenta inverter as areas. @pablobion troca essa linha if not isInRange(fromPosition, fpos, tpos) then doPlayerSendCancel(cid, "You're out of the permitted area.") return true end por if not isInRange(getCreaturePosition(cid), fpos, tpos) then doPlayerSendCancel(cid, "You're out of the permitted area.") return true end
-
Ajuda com Item
<action itemid="2263" script="bombita.lua"/> local config = { itemid = 2180, -- id da bomba duration = 1, -- duration antes de ser removida effect1 = 3, -- efeito que sai ao colocar a bomba msg1 = "Bomba ativada!", -- mensagem que sai ao ser colocado a bomba effect2 = 5 -- efeito ao explodir } local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, config.effect2) setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -20, 5, 5, 1.4, 2.1) -- formula local arr = { {0, 1, 0}, {1, 3, 1}, -- area que vai acertar ao explodir a bomba {0, 1, 0}, } local area = createCombatArea(arr) setCombatArea(combat, area) local function removeBomba(cid, pos, id) local item = getTileItemById(pos, id) if item.uid > 0 then local player = getPlayerByNameWildcard(getItemAttribute(item.uid, 'ref')) if isCreature(player) then doCombat(player, combat, { pos = pos, type = 2 }) end doRemoveItem(item.uid) end return true end function onUse(cid, item, fromPosition, itemEx, toPosition) local item = doCreateItem(config.itemid, 1, toPosition) doItemSetAttribute(item, 'ref', getCreatureName(cid)) doCreatureSay(cid, config.msg1, 20) doSendMagicEffect(toPosition, config.effect1) addEvent(removeBomba, config.duration * 1000, cid, toPosition, config.itemid) return true end o primeiro vai no actions.xml, o segundo em data/actions/scripts.
- Critical Skill System
-
Critical Skill System
@Hundra olá amigo, obrigado por reportar isso. Fico feliz que vc esteja usando meu sistema contudo não acredito que eu possa te ajudar no primeiro problema, esse sistema tem algumas limitações.. acompanhe comigo: a source do tibia funciona +- assim, toda vez que um player/monstro leva dano, esse dano é reduzido de acordo com as defesas dele e aí então que é aplicado o callback onStatsChange. Logo a vida que a gente captura ali no value é a vida que ele iria perder. Só que nosso sistema faz o seguinte: ele cancela essa vida que seria perdida e chama um outro ataque criado por script. Esse outro ataque será recebido pela source da mesma forma que o anterior, passará pelas defesas do player e será reduzido antes de ser aplicado. Se o player possui muito protect o sistema pode se tornar falho, sim, como você bem observou. Pra ficar perfeito seria necessário fazer alterações na source mas isso é uma coisa que eu evito fazer nos meus códigos pois nem todo mundo possui a source. O próprio tibia tem 1 sistema de critical que é perfeito já e que vem imbutido na maioria das sources > 0.3.6. Por conta disso, também não podemos colocar o critical sendo multiplicado pela % de critical que vc possui, aquilo é só a chance.. até daria pra fazer mas por conta dos problemas citados anteriormente o dano ficaria mais variável ainda.
- Magnus Challenger
- Magnus Challenger
- Magnus Challenger
-
Tanker Method
qual versão do seu sv?
- Magnus Challenger
- Dodge System 8.54+
-
Gran Castle Event (8.54+)
@di12345d haha fico lisonjeado, a idéia desse evento não é dominar o castle já que o prêmio ja é o próprio buff da gran aura.. PORÉM vc pode criar outro castelo e permitir que os players que tenham o storage entrem nele.. se n me engano ja comentei isso aqui nesse tópico, dá uma lida nos comentários. Não dá pra adaptar pra fazer assim, teria que editar praticamente tudo e cara, esse sistema é complexo pra crl hahaha só de pensar no trabalho que daria já começo a ter sono. Os erros são porque ele não tá conseguindo criar o monstro Gran tower, isso pode acontecer por 3 motivos: 1- Você não configurou a posição q ele tem q nascer e o script tá tentando criar o monstro numa área q nao dá. 2- você não colocou o monstro no server 3- ja tem alguma criatura ocupando aquele sqm do monstro. Verifica se tá tudo configurado certinho, esse é um tutorial bem extenso.. as vezes você tem que reler ele e refazer os passos do 0 pra garantir que vai funcionar.
-
Magnus Challenger
@di12345d faltou um end pra fechar o if do dodge: local config = { loginMessage = getConfigValue('loginMessage'), useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')) } function onLogin(cid) accountManager = "Account Manager" managerCounter = 0 for i, player in ipairs(getOnlinePlayers()) do if accountManager:lower() == player:lower() then managerCounter = managerCounter + 1 end end if managerCounter >= 3 then return false end local loss = getConfigValue('deathLostPercent') if(loss ~= nil) then doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10) end local accountManager = getPlayerAccountManager(cid) if(accountManager == MANAGER_NONE) then local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage if(lastLogin > 0) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str) str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "." else str = str .. " Please choose your outfit." doPlayerSendOutfitWindow(cid) end doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str) elseif(accountManager == MANAGER_NAMELOCK) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, it appears that your character has been namelocked, what would you like as your new name?") elseif(accountManager == MANAGER_ACCOUNT) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to manage your account and if you want to start over then type 'cancel'.") else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to create an account or type 'recover' to recover an account.") end if(not isPlayerGhost(cid)) then doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT) end registerCreatureEvent(cid, "Mail") registerCreatureEvent(cid, "GuildMotd") registerCreatureEvent(cid, "Idle") if(config.useFragHandler) then registerCreatureEvent(cid, "SkullCheck") end registerCreatureEvent(cid, "ReportBug") registerCreatureEvent(cid, "AdvanceSave") registerCreatureEvent(cid, "attackguild") registerCreatureEvent(cid, "advance") registerCreatureEvent(cid, "FimVip") registerCreatureEvent(cid, "SkullCheck") registerCreatureEvent(cid, "demonOakLogout") registerCreatureEvent(cid, "demonOakDeath") registerCreatureEvent(cid, "ReportBug") registerCreatureEvent(cid, "bluelegs") registerCreatureEvent(cid, "VipReceive") registerCreatureEvent(cid, "FirstItems") registerCreatureEvent(cid, "Promot") registerCreatureEvent(cid, "PlayerKill") registerCreatureEvent(cid, "KillingInTheNameOf") registerCreatureEvent(cid, "PythiusDead") registerCreatureEvent(cid, "ExpVip") registerCreatureEvent(cid, "levelplayer") registerCreatureEvent(cid, "PlayerAdvance") -----------GRAN CASTLE ----------- registerCreatureEvent(cid, "Gran Tower") registerCreatureEvent(cid, "Gran Aura") registerCreatureEvent(cid, "Gran Aura Stats") registerCreatureEvent(cid, "Gran Aura Logout") registerCreatureEvent(cid, "Gran Tower Target") registerCreatureEvent(cid,"tasksystem") registerCreatureEvent(cid, "dodge") if (InitArenaScript ~= 0) then InitArenaScript = 1 for i = 42300, 42309 do setGlobalStorageValue(i, 0) setGlobalStorageValue(i+100, 0) end end if getPlayerStorageValue(cid, 42309) < 1 then for i = 42300, 42309 do setPlayerStorageValue(cid, i, 0) end end if getPlayerStorageValue(cid, 42319) < 1 then for i = 42310, 42319 do setPlayerStorageValue(cid, i, 0) end end if getPlayerStorageValue(cid, 42329) < 1 then for i = 42320, 42329 do setPlayerStorageValue(cid, i, 0) end end if getPlayerStorageValue(cid, 42355) == -1 then setPlayerStorageValue(cid, 42355, 0) end setPlayerStorageValue(cid, 42350, 0) setPlayerStorageValue(cid, 42352, 0) -------------- TASK SYSTEM -------------- if getPlayerStorageValue(cid, 95673) < 0 then setPlayerStorageValue(cid, 95673, 0) end if getPlayerStorageValue(cid, 95674) < 0 then setPlayerStorageValue(cid, 95674, 0) end ----------------dodge------------------- if getPlayerStorageValue(cid, 48902) == -1 then setPlayerStorageValue(cid, 48902, 0) end return true end
- Sistema de Reset 100%