Tudo que Sanieg postou
-
(Resolvido)Colocando cooldown na magia
Edite o tempo do cooldown... ps: em segundos no caso eu coloquei 60 segundos (1 minuto)
-
(Resolvido)Colocando cooldown na magia
Editado...
-
Tibia morreu tudo morreu
Eu não estava pegando como exemplo nada profissional e como eu disse "Se fizer aquilo que gosta", pois também posso fazer algo que não gosto e aprender a gostar disso também. Um exemplo seria um script: Eu faço um script (Bem provável que não, ando muito sem ideias) e se eu fizer direito eu vou gostar caso contrário não... Não excluindo a possibilidade de melhorar, mas não necessariamente eu devo gostar de algo logo como eu disse: "bem provável".
-
(Resolvido)Colocando cooldown na magia
local tempo = 30 local effect = {175} local health = 1000 local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0) local condition = createConditionObject(CONDITION_REGENERATION) setConditionParam(condition, CONDITION_PARAM_SUBID, 1) setConditionParam(condition, CONDITION_PARAM_BUFF, TRUE) setConditionParam(condition, CONDITION_PARAM_TICKS, tempo*1000) setConditionParam(condition, CONDITION_PARAM_HEALTHGAIN, health) setConditionParam(condition, CONDITION_PARAM_HEALTHTICKS, 1000) setCombatCondition(combat, condition) function magicEffect10(tempo2,tempo3,cid) if (isCreature(cid)) then if getPlayerStorageValue(cid, 102053) > 0 and getCreatureCondition(cid, CONDITION_REGENERATION, 1) then for i=1, #effect do local position = {x=getPlayerPosition(cid).x+1, y=getPlayerPosition(cid).y, z=getPlayerPosition(cid).z} doSendMagicEffect(position, effect[i]) end end end end function onCastSpell(cid, var) local cooldown = 60 --Tempo de cooldown if getPlayerStorageValue(cid, 102055) >= 1 then doPlayerSendCancel(cid, "You're exhausted.") return false end if getPlayerStorageValue(cid, 102053) ~= 1 or getCreatureCondition(cid, CONDITION_REGENERATION, 1) == false then doCombat(cid, combat, var) addEvent(function () setPlayerStorageValue(cid, 102055, 1) end, os.clock()+cooldown) tempo2 = 0 while (tempo2 ~= (tempo*1000)) do addEvent(magicEffect10, tempo2, tempo2, tempo*1000, cid) tempo2 = tempo2 + 300 end setPlayerStorageValue(cid, 102053,1) else doPlayerSendCancel(cid, "O magia está sendo usada!.") end end
-
(Resolvido)Spell Heala 50% de Mana
Nada, se precisar já sabe
-
Tibia morreu tudo morreu
Realmente, mas se você fizer oque gosta bem provável que goste daquilo que faz . A não ser que não faça direito...
-
DBwarrior 8.54 , bug
Ok.. E o erro no console ?? possui algum ??
-
(Resolvido){Pedido} Addon Bonus
Tem jeito não amigo desculpa ai ...
-
War Castle Radbr
Editado verifique agora...
-
Spell de buff na life matando personagem.
Caso o valor da redução seja igual a 0 ele vai ganhar 5% do life máximo dele para não morrer... E logo em seguida diminuir a porcentagem de life que ele ganhou... (Com a spell) Mude: local function finishJutsu(cid) if not isCreature(cid) then return true end local giant = getStorage(cid, 10721) if giant > 0 then setStorage(cid, 10721, 0) local jutsuLv = getJutsuLevel(cid, "chou_baika") local healthGainPercent = giantGain[jutsuLv]*0.01 local maxHealth = getPlayerHealthMax(cid) local healthChange = - math.ceil(maxHealth * healthGainPercent) doCreatureAddHealth(cid, healthChange) doRemoveCondition(cid, CONDITION_ATTRIBUTES) doSendMagicEffect(getCreaturePosition(cid), 10) normalizeOutfit(cid) end end por: local function finishJutsu(cid) if not isCreature(cid) then return true end local giant = getStorage(cid, 10721) if giant > 0 then setStorage(cid, 10721, 0) local jutsuLv = getJutsuLevel(cid, "chou_baika") local healthGainPercent = giantGain[jutsuLv]*0.01 local maxHealth = getPlayerHealthMax(cid) local healthChange = - math.ceil(maxHealth * healthGainPercent) if getCreatureHealth(cid) - math.ceil(maxHealth * healthGainPercent) == 0 then doCreatureAddHealth(cid, 5*getCreatureMaxHealth(cid)/100) end doCreatureAddHealth(cid, healthChange) doRemoveCondition(cid, CONDITION_ATTRIBUTES) doSendMagicEffect(getCreaturePosition(cid), 10) normalizeOutfit(cid) end end
-
War Castle Radbr
<globalevent name="castle" interval="30" event="script" value="castle.lua"/>
-
War Castle Radbr
Qual é esse erro exatamente ??
-
(Resolvido){Pedido} Addon Bonus
local water = {490, 491, 492, 493, 4608, 4609, 4610, 4611, 4612, 4613, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625} local combat = createCombatObject() local meteor = createCombatObject() setCombatParam(meteor, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatParam(meteor, COMBAT_PARAM_EFFECT, CONST_ME_FIREATTACK) setCombatFormula(meteor, COMBAT_FORMULA_LEVELMAGIC, -6.5, -500, -6.7, -400) local stun = createConditionObject(CONDITION_PARALYZE) setConditionParam(stun, CONDITION_PARAM_TICKS, 1000) setConditionFormula(stun, -0.9, 1, -0.9, 1) local meteor_water = createCombatObject() setCombatParam(meteor_water, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatParam(meteor_water, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatFormula(meteor_water, COMBAT_FORMULA_LEVELMAGIC, -7.70, -200, -7.80, -200) combat_arr = { {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 1, 3, 1, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} } local combat_area = createCombatArea(combat_arr) setCombatArea(combat, combat_area) local function meteorCast(p) doCombat(p.cid, p.combat, positionToVariant(p.pos)) end local function stunEffect(cid) doSendMagicEffect(getThingPos(cid), CONST_ME_STUN) end function onTargetTile(cid, pos) if (math.random(0, 0) == 0) then local ground = getThingfromPos({x = pos.x, y = pos.y, z = pos.z, stackpos = 1}) if (isInArray(water, ground.itemid) == TRUE) then local newpos = {x = pos.x - 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, CONST_ANI_FIRE) addEvent(meteorCast, 100, {cid = cid, pos = pos, combat = meteor_water}) else local newpos = {x = pos.x - 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, CONST_ANI_FIRE) addEvent(meteorCast, 100, {cid = cid,pos = pos, combat = meteor}) end end end setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) if getPlayerStorageValue(cid, 19235) >= 1 then setCombatCondition(combat, stun) setCombatCondition(meteor, stun) end return doCombat(cid, combat, var) end local water = {490, 491, 492, 493, 4608, 4609, 4610, 4611, 4612, 4613, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625} local combat = createCombatObject() local meteor = createCombatObject() setCombatParam(meteor, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE) setCombatParam(meteor, COMBAT_PARAM_EFFECT, CONST_ME_ICEATTACK) setCombatFormula(meteor, COMBAT_FORMULA_LEVELMAGIC, -6.5, -500, -6.7, -350) setCombatParam(meteor, COMBAT_PARAM_CREATEITEM, 0000) local stun = createConditionObject(CONDITION_PARALYZE) setConditionParam(stun, CONDITION_PARAM_TICKS, 1000) setConditionFormula(stun, -0.9, 1, -0.9, 1) local meteor_water = createCombatObject() setCombatParam(meteor_water, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(meteor_water, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatFormula(meteor_water, COMBAT_FORMULA_LEVELMAGIC, -7.70, -200, -7.80, -200) combat_arr = { {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 1, 3, 1, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} } local combat_area = createCombatArea(combat_arr) setCombatArea(combat, combat_area) local function meteorCast(p) doCombat(p.cid, p.combat, positionToVariant(p.pos)) end local function stunEffect(cid) doSendMagicEffect(getThingPos(cid), CONST_ME_STUN) end function onTargetTile(cid, pos) if (math.random(0, 0) == 0) then local ground = getThingfromPos({x = pos.x, y = pos.y, z = pos.z, stackpos = 1}) if (isInArray(water, ground.itemid) == TRUE) then local newpos = {x = pos.x + 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, 28) addEvent(meteorCast, 100, {cid = cid, pos = pos, combat = meteor_water}) else local newpos = {x = pos.x + 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, 28) addEvent(meteorCast, 100, {cid = cid,pos = pos, combat = meteor}) end end end setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) if getPlayerStorageValue(cid, 19235) >= 1 then setCombatCondition(combat, stun) setCombatCondition(meteor, stun) end return doCombat(cid, combat, var) end
-
Tibia morreu tudo morreu
Huehuehuehuehue é pra rir ou pra chorar ?!
-
(Resolvido)(Pedido) Item que dê acesso
Exatamente agora falta verificar se é funcional e se é aquilo que você quer...
-
{Pedido} Task System
task = {{"dragon", 10},{"dragon lord", 20},{"frost dragon", 30}}, -- nome do bixo e quantidade Na verdade ele está ganhando para cada task pois está utilizando somente uma storage para kill exemplo: 10 Dragon = 1 premio, 20 dragon lord = 1 premio a storage é sempre a mesma...
-
(Resolvido){Pedido} Addon Bonus
Entendi agora... deleta o setCombatCondition(meteor, stun) do primeiro script dessa spell que você enviou e em baixo de function onCastSpell(cid, var) você coloca: if getPlayerStorageValue(cid, 19235) >= 1 then setCombatCondition(combat, stun) setCombatCondition(meteor, stun) end
-
(Resolvido)(Pedido) Item que dê acesso
Acho que é isso function onStepIn(cid, fromPos, item, toPos) if not getPlayerStorageValue(cid, 19234, 1) then doPlayerSendCancel(cid, "Voce nao pode passar aqui.") doTeleportThing(cid, getTownTemplePosition(1)) end return true end function onUse(cid, fromPos, item, toPos, item2) local item = IDDOITEM if getPlayerStorageValue(cid, 19234) >= 1 then doPlayerSendCancel(cid, "Voce ja possui acesso liberado a X area.") end doPlayerRemoveItem(cid, item, 1) addEvent(function () setPlayerStorageValue(cid, 19234, 1) end, os.time()+(86400*7)) --Vai durar 1 semana doPlayerSendTextMessage(cid, 19, "Voce ganhou 7 dias liberados para X area.") return true end function onThink(cid, interval, lastexecution) local pos1 = {x=1050, y=1050, z=7} --Superior esquerdo dessa X area local pos2 = {x=1050, y=1050, z=7} --Inferior direito dessa X area if isPlayer(cid) and isInRange(getThingPosition(cid), pos1, pos2) and not getPlayerStorageValue(cid, 19234) >= 1 then doPlayerSendTextMessage(cid, 19, "Que pena acabou seu acesso a X area.") doTeleportThing(cid, getTownTemplePosition(1)) end return true end
-
(Resolvido){Pedido} Addon Bonus
Não entendi o porque desse erro eu apenas adicionei uma linha a mais e a checagem do addon (Que vejo que não é necessária). Agora estou em duvida sobre isso que você quer (Fora o paralise que eu acho que basta adicionar: setCombatCondition(combat, stun) em baixo do setCombatCondition(meteor, stun))
-
Spell de buff na life matando personagem.
Para o cooldown basta adicionar isso em baixo de doCreatureAddHealth(cid, healthChange): addEvent(function () setStorage(cid, 9000, 1) end, os.clock()+60) PS: modifiquei conforme seu script em um Tibia normal seria "setPlayerStorageValue"... Porém não entendi como ele morre uma hora e outra não ...
-
[Pokemon Kpdo] Pokemon kpdo exaioros By Cater
Eu hospedei no media-fire para quem não esta conseguindo baixar no mega, caso alguém com disponibilidade possa efetuar um scan para mim eu agradeço . http://www.mediafire.com/download/jg5jy2ghh4558y5/Projeto_Kpdo_OpenSource-www.exaioros.com.rar
-
(Resolvido)(Pedido) Item que dê acesso
Eu não entendi nada , o que você quer mesmo ??
-
(Resolvido){Pedido} Addon Bonus
Não entendi muito bem pois o "meteor" já possui paralise porém eu adicionei também no "combat" basta testar para ver se é isso e também o requisito de addon full... Druid: local water = {490, 491, 492, 493, 4608, 4609, 4610, 4611, 4612, 4613, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625} local combat = createCombatObject() local meteor = createCombatObject() setCombatParam(meteor, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE) setCombatParam(meteor, COMBAT_PARAM_EFFECT, CONST_ME_ICEATTACK) setCombatFormula(meteor, COMBAT_FORMULA_LEVELMAGIC, -6.5, -500, -6.7, -350) setCombatParam(meteor, COMBAT_PARAM_CREATEITEM, 0000) local stun = createConditionObject(CONDITION_PARALYZE) setConditionParam(stun, CONDITION_PARAM_TICKS, 1000) setConditionFormula(stun, -0.9, 1, -0.9, 1) setCombatCondition(meteor, stun) setCombatCondition(combat, stun) local meteor_water = createCombatObject() setCombatParam(meteor_water, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(meteor_water, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatFormula(meteor_water, COMBAT_FORMULA_LEVELMAGIC, -7.70, -200, -7.80, -200) combat_arr = { {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 1, 3, 1, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} } local combat_area = createCombatArea(combat_arr) setCombatArea(combat, combat_area) local function meteorCast(p) doCombat(p.cid, p.combat, positionToVariant(p.pos)) end local function stunEffect(cid) doSendMagicEffect(getThingPos(cid), CONST_ME_STUN) end function onTargetTile(cid, pos) if (math.random(0, 0) == 0) then local ground = getThingfromPos({x = pos.x, y = pos.y, z = pos.z, stackpos = 1}) if (isInArray(water, ground.itemid) == TRUE) then local newpos = {x = pos.x + 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, 28) addEvent(meteorCast, 100, {cid = cid, pos = pos, combat = meteor_water}) else local newpos = {x = pos.x + 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, 28) addEvent(meteorCast, 100, {cid = cid,pos = pos, combat = meteor}) end end end setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) if not getPlayerStorageValue(cid, 19235) >= 1 then doPlayerSendCancel(cid, "Voce nao pode usar essa spell pois nao possui addon full.") end return doCombat(cid, combat, var) end Sorcerer: local water = {490, 491, 492, 493, 4608, 4609, 4610, 4611, 4612, 4613, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625}local combat = createCombatObject() local meteor = createCombatObject() setCombatParam(meteor, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatParam(meteor, COMBAT_PARAM_EFFECT, CONST_ME_FIREATTACK) setCombatFormula(meteor, COMBAT_FORMULA_LEVELMAGIC, -6.5, -500, -6.7, -400) local stun = createConditionObject(CONDITION_PARALYZE) setConditionParam(stun, CONDITION_PARAM_TICKS, 1000) setConditionFormula(stun, -0.9, 1, -0.9, 1) setCombatCondition(meteor, stun) setCombatCondition(combat, stun) local meteor_water = createCombatObject() setCombatParam(meteor_water, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatParam(meteor_water, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatFormula(meteor_water, COMBAT_FORMULA_LEVELMAGIC, -7.70, -200, -7.80, -200) combat_arr = { {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 1, 3, 1, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} } local combat_area = createCombatArea(combat_arr) setCombatArea(combat, combat_area) local function meteorCast(p) doCombat(p.cid, p.combat, positionToVariant(p.pos)) end local function stunEffect(cid) doSendMagicEffect(getThingPos(cid), CONST_ME_STUN) end function onTargetTile(cid, pos) if (math.random(0, 0) == 0) then local ground = getThingfromPos({x = pos.x, y = pos.y, z = pos.z, stackpos = 1}) if (isInArray(water, ground.itemid) == TRUE) then local newpos = {x = pos.x - 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, CONST_ANI_FIRE) addEvent(meteorCast, 100, {cid = cid, pos = pos, combat = meteor_water}) else local newpos = {x = pos.x - 9, y = pos.y - 8, z = pos.z} doSendDistanceShoot(newpos, pos, CONST_ANI_FIRE) addEvent(meteorCast, 100, {cid = cid,pos = pos, combat = meteor}) end end end setCombatCallback(combat, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) if not getPlayerStorageValue(cid, 19235) >= 1 then doPlayerSendCancel(cid, "Voce nao pode usar essa spell pois nao possui addon full.") end return doCombat(cid, combat, var) end
-
{Pedido} Task System
Já modifiquei os scripts para você basta seguir o exemplo do vodkart: http://www.tibiaking.com/forum/topic/15642-pedido-npc-task-system/ Npc: domodlib('KillM_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({"task","mission","missao"}, msg) then if not tonumber(getPlayerStorageValue(cid, tsk.storages[1])) then npcHandler:say("Você já terminou a task!", cid) elseif getPlayerStorageValue(cid, tsk.storages[2]) >= 1 then npcHandler:say("Você já matou "..tsk.task[2].." "..tsk.task[1].."? {yes}", cid) talkState[talkUser] = 2 else npcHandler:say("Você deseja fazer uma missão de matar "..tsk.task[2].." "..tsk.task[1].." e receber "..tsk.exp.." de experience e "..tsk.item[getPlayerVocation(cid)].itens.." "..getItemNameById(tsk.item[getPlayerVocation(cid)].count).."? {yes}", cid) talkState[talkUser] = 1 end elseif isInArray({"yes","sim"}, msg) and talkState[talkUser] > 0 then if talkState[talkUser] == 1 then npcHandler:say("Parabéns! Agora você está participando da task, volte quanto tiver terminado!", cid) setPlayerStorageValue(cid, tsk.storages[2], 1) else if getPlayerStorageValue(cid, tsk.storages[1]) >= tsk.task[2] then npcHandler:say("Obrigado guerreiro, aqui está sua recompensa!", cid) setPlayerStorageValue(cid, tsk.storages[1], "Finished") doPlayerAddExp(cid, tsk.exp) doPlayerAddItem(cid, tsk.item[getPlayerVocation(cid)].itens, tsk.item[getPlayerVocation(cid)].count) else npcHandler:say("Você ainda não terminou a sua task!", cid) end end talkState[talkUser] = 0 elseif msg == "no" 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()) Mod: <?xml version="1.0" encoding="ISO-8859-1"?> <mod name="Task Kill" version="1.0" author="Vodkart" contact="tibiaking.com" enabled="yes"> <config name="KillM_func"><![CDATA[ tsk = { storages = {68754,68755}, task = {"dragon", 10}, -- nome do bixo e quantidade exp = 200, item = { [1] = {itens = {IDDOITEM}, count=10}, [2] = {itens = {IDDOITEM}, count=10}, [3] = {itens = {IDDOITEM}, count=10}, [4] = {itens = {IDDOITEM}, count=10}} } ]]></config> <event type="login" name="AreKill" event="script"><![CDATA[ function onLogin(cid) registerCreatureEvent(cid, "CountTask") return true end]]></event> <event type="kill" name="CountTask" event="script"><![CDATA[ domodlib('KillM_func') function onKill(cid, target) if isMonster(target) then local n = string.lower(getCreatureName(target)) if n == tsk.task[1] and getPlayerStorageValue(cid, tsk.storages[2]) >= 1 then local contagem = getPlayerStorageValue(cid, tsk.storages[1]) if (contagem == -1) then contagem = 1 end if not tonumber(contagem) then return true end if contagem > tsk.task[2] then return true end setPlayerStorageValue(cid, tsk.storages[1], contagem+1) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE,""..(contagem == tsk.task[2] and "Congratulations! You finished the task of "..n.."." or "defeated. Total [" .. contagem .. "/" .. tsk.task[2] .. "] " .. n .. ".").."") end end return true end]]></event> </mod>
-
(Resolvido)[Ajuda] Servidor não esta dropando loot
Nem aparecer mensagem de loot ... Já verificou o rate de drop do servidor ?