Ir para conteúdo

Kemix

Campones
  • Total de itens

    15
  • Registro em

  • Última visita

  • Dias Ganhos

    2

Kemix venceu a última vez em Dezembro 13 2021

Kemix had the most liked content!

1 Seguidor

Sobre Kemix

Perfil

  • Gênero
    Masculino

Informações

  • Forma que conheci o xTibia
    Sites de Busca
  • Sou
    OT-Admin

Últimos Visitantes

O bloco dos últimos visitantes está desativado e não está sendo visualizado por outros usuários.

Kemix's Achievements

  1. Kemix

    Sou scripter

    Opa, desculpe então, pode deletar o topico.
  2. Kemix

    Sou scripter

    Nome: Tiago Idade: 26 Experiencia: 7 anos Trabalho com pedidos de scripts.O valor depende da complexidade. Contato: tiago.oliveira1409 obs: NÃO TRABALHO EM PROJETOS, APENAS POR PEDIDOS.
  3. Kemix

    Magia por x Reset's

    -- Areas/Combat for 0ms function getPlayerReset(cid) local qr = db.getResult("SELECT `reset` FROM `players` WHERE `id`= ".. getPlayerGUID(cid).. ";") <-- rss = qr:getDataInt("reset", cid) if rss < 0 then rss = 0 end return rss end local combat0_Brush = createCombatObject() setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatParam(combat0_Brush, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_ICE) setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE) setCombatArea(combat0_Brush,createCombatArea({{2}})) function getDmg_Brush(cid, level, maglevel) return (80)*-1,(180)*-10 end setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush") local dfcombat0_Brush = {CONST_ANI_SMALLICE}local combat0_Brush_2 = createCombatObject() setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_GREEN) setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_2,createCombatArea({{2}})) function getDmg_Brush_2(cid, level, maglevel) return (80)*-1,(180)*-12 end setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2")local combat0_Brush_3 = createCombatObject() setCombatParam(combat0_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat0_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_3,createCombatArea({{1, 0, 0, 0, 1}, {0, 1, 2, 1, 0}, {1, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-10 end setCombatCallback(combat0_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3")local combat0_Brush_2 = createCombatObject() setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_GROUNDSHAKER) setCombatParam(combat0_Brush_2, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_WHIRLWINDCLUB) setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_2,createCombatArea({{2}})) function getDmg_Brush_2(cid, level, maglevel) return (80)*-1,(200)*-10 end setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2") local dfcombat0_Brush_2 = {CONST_ANI_WHIRLWINDCLUB}local combat0_Brush = createCombatObject() setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_SMALLCLOUDS) setCombatParam(combat0_Brush, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_THROWINGKNIFE) setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush,createCombatArea({{2}})) function getDmg_Brush(cid, level, maglevel) return (95)*-1,(210)*-10 end setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush") local dfcombat0_Brush = {CONST_ANI_SMALLEARTH}local combat0_Brush_6 = createCombatObject() setCombatParam(combat0_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat0_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_6,createCombatArea({{0, 1, 1, 1, 0}, {1, 0, 2, 0, 1}, {0, 1, 1, 1, 0}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-10 end setCombatCallback(combat0_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6") -- Areas/Combat for 900ms local combat9_Brush_6 = createCombatObject() setCombatParam(combat9_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat9_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat9_Brush_6,createCombatArea({{1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 2, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-11 end setCombatCallback(combat9_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6")local combat9_Brush_3 = createCombatObject() setCombatParam(combat9_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat9_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat9_Brush_3,createCombatArea({{1, 0, 0, 0, 0, 0, 0, 0, 1}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 1, 2, 1, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-10 end setCombatCallback(combat9_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3") -- Areas/Combat for 400ms local combat4_Brush_6 = createCombatObject() setCombatParam(combat4_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat4_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat4_Brush_6,createCombatArea({{0, 1, 1, 1, 1, 1, 0}, {1, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 2, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 1}, {0, 1, 1, 1, 1, 1, 0}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-10 end setCombatCallback(combat4_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6")local combat4_Brush_3 = createCombatObject() setCombatParam(combat4_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat4_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat4_Brush_3,createCombatArea({{1, 0, 0, 0, 0, 0, 1}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 2, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-7 end setCombatCallback(combat4_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3") -- =============== CORE FUNCTIONS =============== local function RunPart(c,cid,var,dirList,dirEmitPos) -- Part if (isCreature(cid)) then doCombat(cid, c, var) if (dirList ~= nil) then -- Emit distance effects local i = 2; while (i < #dirList) do doSendDistanceShoot(dirEmitPos,{x=dirEmitPos.x-dirList,y=dirEmitPos.y-dirList[i+1],z=dirEmitPos.z},dirList[1]) i = i + 2 end end end end function onCastSpell(cid, var) if getPlayerReset(cid) < 1 then doPlayerSendCancel(cid, "You can't cast this spell.") return true end local startPos = getCreaturePosition(cid) RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos) RunPart(combat0_Brush_2,cid,var) RunPart(combat0_Brush_3,cid,var) RunPart(combat0_Brush_2,cid,var,dfcombat0_Brush_2,startPos) RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos) RunPart(combat0_Brush_6,cid,var) addEvent(RunPart,900,combat9_Brush_6,cid,var) addEvent(RunPart,900,combat9_Brush_3,cid,var) addEvent(RunPart,400,combat4_Brush_6,cid,var) addEvent(RunPart,400,combat4_Brush_3,cid,var) return true end
  4. Kemix

    Magia por x Reset's

    -- Areas/Combat for 0ms function getPlayerReset(cid) local qr = db.getResult("SELECT `reset` FROM `players` WHERE `id`= `cid`;") -- mudei isso rss = qr:getDataInt("reset", cid) if rss < 0 then rss = 0 end return rss end local combat0_Brush = createCombatObject() setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatParam(combat0_Brush, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_ICE) setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE) setCombatArea(combat0_Brush,createCombatArea({{2}})) function getDmg_Brush(cid, level, maglevel) return (80)*-1,(180)*-10 end setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush") local dfcombat0_Brush = {CONST_ANI_SMALLICE}local combat0_Brush_2 = createCombatObject() setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_GREEN) setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_2,createCombatArea({{2}})) function getDmg_Brush_2(cid, level, maglevel) return (80)*-1,(180)*-12 end setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2")local combat0_Brush_3 = createCombatObject() setCombatParam(combat0_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat0_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_3,createCombatArea({{1, 0, 0, 0, 1}, {0, 1, 2, 1, 0}, {1, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-10 end setCombatCallback(combat0_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3")local combat0_Brush_2 = createCombatObject() setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_GROUNDSHAKER) setCombatParam(combat0_Brush_2, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_WHIRLWINDCLUB) setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_2,createCombatArea({{2}})) function getDmg_Brush_2(cid, level, maglevel) return (80)*-1,(200)*-10 end setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2") local dfcombat0_Brush_2 = {CONST_ANI_WHIRLWINDCLUB}local combat0_Brush = createCombatObject() setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_SMALLCLOUDS) setCombatParam(combat0_Brush, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_THROWINGKNIFE) setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush,createCombatArea({{2}})) function getDmg_Brush(cid, level, maglevel) return (95)*-1,(210)*-10 end setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush") local dfcombat0_Brush = {CONST_ANI_SMALLEARTH}local combat0_Brush_6 = createCombatObject() setCombatParam(combat0_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat0_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_6,createCombatArea({{0, 1, 1, 1, 0}, {1, 0, 2, 0, 1}, {0, 1, 1, 1, 0}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-10 end setCombatCallback(combat0_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6") -- Areas/Combat for 900ms local combat9_Brush_6 = createCombatObject() setCombatParam(combat9_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat9_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat9_Brush_6,createCombatArea({{1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 2, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-11 end setCombatCallback(combat9_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6")local combat9_Brush_3 = createCombatObject() setCombatParam(combat9_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat9_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat9_Brush_3,createCombatArea({{1, 0, 0, 0, 0, 0, 0, 0, 1}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 1, 2, 1, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-10 end setCombatCallback(combat9_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3") -- Areas/Combat for 400ms local combat4_Brush_6 = createCombatObject() setCombatParam(combat4_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat4_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat4_Brush_6,createCombatArea({{0, 1, 1, 1, 1, 1, 0}, {1, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 2, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 1}, {0, 1, 1, 1, 1, 1, 0}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-10 end setCombatCallback(combat4_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6")local combat4_Brush_3 = createCombatObject() setCombatParam(combat4_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat4_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat4_Brush_3,createCombatArea({{1, 0, 0, 0, 0, 0, 1}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 2, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-7 end setCombatCallback(combat4_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3") -- =============== CORE FUNCTIONS =============== local function RunPart(c,cid,var,dirList,dirEmitPos) -- Part if (isCreature(cid)) then doCombat(cid, c, var) if (dirList ~= nil) then -- Emit distance effects local i = 2; while (i < #dirList) do doSendDistanceShoot(dirEmitPos,{x=dirEmitPos.x-dirList,y=dirEmitPos.y-dirList[i+1],z=dirEmitPos.z},dirList[1]) i = i + 2 end end end end function onCastSpell(cid, var) if getPlayerReset(cid) < 1 then doPlayerSendCancel(cid, "You can't cast this spell.") return true end local startPos = getCreaturePosition(cid) RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos) RunPart(combat0_Brush_2,cid,var) RunPart(combat0_Brush_3,cid,var) RunPart(combat0_Brush_2,cid,var,dfcombat0_Brush_2,startPos) RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos) RunPart(combat0_Brush_6,cid,var) addEvent(RunPart,900,combat9_Brush_6,cid,var) addEvent(RunPart,900,combat9_Brush_3,cid,var) addEvent(RunPart,400,combat4_Brush_6,cid,var) addEvent(RunPart,400,combat4_Brush_3,cid,var) return true end
  5. Esta bugado ou vc quer modificar para o jeito que vc falou?
  6. Kemix

    Magia por x Reset's

    -- Areas/Combat for 0ms function getPlayerReset(cid) local qr = db.getResult("SELECT `reset` FROM `players` WHERE `id`= cid;") rss = qr:getDataInt("reset", cid) if rss < 0 then rss = 0 end return rss end local combat0_Brush = createCombatObject() setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_LOSEENERGY) setCombatParam(combat0_Brush, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_ICE) setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_ICEDAMAGE) setCombatArea(combat0_Brush,createCombatArea({{2}})) function getDmg_Brush(cid, level, maglevel) return (80)*-1,(180)*-10 end setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush") local dfcombat0_Brush = {CONST_ANI_SMALLICE}local combat0_Brush_2 = createCombatObject() setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_GREEN) setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_2,createCombatArea({{2}})) function getDmg_Brush_2(cid, level, maglevel) return (80)*-1,(180)*-12 end setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2")local combat0_Brush_3 = createCombatObject() setCombatParam(combat0_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat0_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_3,createCombatArea({{1, 0, 0, 0, 1}, {0, 1, 2, 1, 0}, {1, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-10 end setCombatCallback(combat0_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3")local combat0_Brush_2 = createCombatObject() setCombatParam(combat0_Brush_2, COMBAT_PARAM_EFFECT, CONST_ME_GROUNDSHAKER) setCombatParam(combat0_Brush_2, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_WHIRLWINDCLUB) setCombatParam(combat0_Brush_2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_2,createCombatArea({{2}})) function getDmg_Brush_2(cid, level, maglevel) return (80)*-1,(200)*-10 end setCombatCallback(combat0_Brush_2, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_2") local dfcombat0_Brush_2 = {CONST_ANI_WHIRLWINDCLUB}local combat0_Brush = createCombatObject() setCombatParam(combat0_Brush, COMBAT_PARAM_EFFECT, CONST_ME_SMALLCLOUDS) setCombatParam(combat0_Brush, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_THROWINGKNIFE) setCombatParam(combat0_Brush, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush,createCombatArea({{2}})) function getDmg_Brush(cid, level, maglevel) return (95)*-1,(210)*-10 end setCombatCallback(combat0_Brush, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush") local dfcombat0_Brush = {CONST_ANI_SMALLEARTH}local combat0_Brush_6 = createCombatObject() setCombatParam(combat0_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat0_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat0_Brush_6,createCombatArea({{0, 1, 1, 1, 0}, {1, 0, 2, 0, 1}, {0, 1, 1, 1, 0}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-10 end setCombatCallback(combat0_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6") -- Areas/Combat for 900ms local combat9_Brush_6 = createCombatObject() setCombatParam(combat9_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat9_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat9_Brush_6,createCombatArea({{1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 2, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-11 end setCombatCallback(combat9_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6")local combat9_Brush_3 = createCombatObject() setCombatParam(combat9_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat9_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat9_Brush_3,createCombatArea({{1, 0, 0, 0, 0, 0, 0, 0, 1}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 1, 2, 1, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-10 end setCombatCallback(combat9_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3") -- Areas/Combat for 400ms local combat4_Brush_6 = createCombatObject() setCombatParam(combat4_Brush_6, COMBAT_PARAM_EFFECT, CONST_ME_SMALLPLANTS) setCombatParam(combat4_Brush_6, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat4_Brush_6,createCombatArea({{0, 1, 1, 1, 1, 1, 0}, {1, 0, 0, 0, 0, 0, 1}, {1, 0, 0, 2, 0, 0, 1}, {1, 0, 0, 0, 0, 0, 1}, {0, 1, 1, 1, 1, 1, 0}})) function getDmg_Brush_6(cid, level, maglevel) return (100)*-1,(290)*-10 end setCombatCallback(combat4_Brush_6, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_6")local combat4_Brush_3 = createCombatObject() setCombatParam(combat4_Brush_3, COMBAT_PARAM_EFFECT, CONST_ME_STUN) setCombatParam(combat4_Brush_3, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatArea(combat4_Brush_3,createCombatArea({{1, 0, 0, 0, 0, 0, 1}, {0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 2, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, {1, 0, 0, 0, 0, 0, 1}})) function getDmg_Brush_3(cid, level, maglevel) return (86)*-1,(200)*-7 end setCombatCallback(combat4_Brush_3, CALLBACK_PARAM_LEVELMAGICVALUE, "getDmg_Brush_3") -- =============== CORE FUNCTIONS =============== local function RunPart(c,cid,var,dirList,dirEmitPos) -- Part if (isCreature(cid)) then doCombat(cid, c, var) if (dirList ~= nil) then -- Emit distance effects local i = 2; while (i < #dirList) do doSendDistanceShoot(dirEmitPos,{x=dirEmitPos.x-dirList,y=dirEmitPos.y-dirList[i+1],z=dirEmitPos.z},dirList[1]) i = i + 2 end end end end function onCastSpell(cid, var) if getPlayerReset(cid) < 1 then doPlayerSendCancel(cid, "You can't cast this spell.") return true end local startPos = getCreaturePosition(cid) RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos) RunPart(combat0_Brush_2,cid,var) RunPart(combat0_Brush_3,cid,var) RunPart(combat0_Brush_2,cid,var,dfcombat0_Brush_2,startPos) RunPart(combat0_Brush,cid,var,dfcombat0_Brush,startPos) RunPart(combat0_Brush_6,cid,var) addEvent(RunPart,900,combat9_Brush_6,cid,var) addEvent(RunPart,900,combat9_Brush_3,cid,var) addEvent(RunPart,400,combat4_Brush_6,cid,var) addEvent(RunPart,400,combat4_Brush_3,cid,var) return true end
  7. function checkStages(cid) local premiumexp = 2 --- edite qual multiplicador você quer na exp normal local level = getPlayerLevel(cid) if isPromoted(cid) == false then premiumexp = 1 end for i = 1, # STAGES do if (level >= STAGES.level) then doPlayerSetRate(cid, 8, STAGES.rate * premiumexp) return end end doPlayerSetRate(cid, 8, DEFAULT_RATE) end
  8. config = { minlevel = 150, --- Level inical para resetar price = 10000, --- Preço inicial para resetar newlevel = 20, --- Level após reset priceByReset = 0, --- Preço acrescentado por reset percent = 10, ---- Porcentagem da vida/mana que você terá ao resetar (em relação à sua antiga vida total) maxresets = 50, ---- Maximo de resets levelbyreset = 0 --- Quanto de level vai precisar a mais no próximo reset }
  9. Npc para o sistema de reset: http://www.xtibia.com/forum/topic/238305-sistema-de-resetes/ data/npc/ reseter.XML : <?xml version="1.0" encoding="UTF-8"?> <npc name="Reseter" script="reseter.lua"> <health now="1000" max="1000"/> <look type="133" head="95" body="86" legs="86" feet="38" addons="3"/> <parameters> <parameter key="message_greet" value="Hello |PLAYERNAME|.I've been waiting for you to come.. Say 'reset' or 'quantity'" /> <parameter key="message_farewell" value="Cya folk." /> <parameter key="message_walkaway" value="How Rude!" /> </parameters> </npc> data/npc/scripts reseter.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 creatureSayCallback(cid, type, msg) if not npcHandler:isFocused(cid) then return false end local player = Player(cid) config = { minlevel = 150, --- Level inical para resetar price = 10000, --- Preço inicial para resetar newlevel = 20, --- Level após reset priceByReset = 0, --- Preço acrescentado por reset percent = 10, ---- Porcentagem da vida/mana que você terá ao resetar (em relação à sua antiga vida total) maxresets = 50, ---- Maximo de resets levelbyreset = 0 --- Quanto de level vai precisar a mais no próximo reset } function addReset(cid) player = Player(cid) resets = player:getResets() hp = player:getMaxHealth() resethp = hp*(config.percent/100) player:setMaxHealth(resethp) mana = player:getMaxMana() resetmana = mana*(config.percent/100) player:setMaxMana(resetmana) playerid = player:getGuid() player:remove() db.query("UPDATE `players` SET `resets`="..resets.. + 1",`experience`= 0 WHERE `players`.`id`= ".. playerid .."") db.query("UPDATE `players` SET `level`="..config.newlevel..",`experience`= 0 WHERE `players`.`id`= ".. playerid .."") return true end local newPrice = config.price + (getResets(cid) * config.priceByReset) local newminlevel = config.minlevel + (getResets(cid) * config.levelbyreset) if msgcontains(msg, 'reset') then if getResets(cid) < config.maxresets then npcHandler:say('You want to reset your character? It will cost '..newPrice..' gp\'s!', cid) npcHandler.topic[cid] = 1 else npcHandler:say('You already reached the maximum reset level!', cid) end elseif msgcontains(msg, 'yes') and npcHandler.topic[cid] == 1 then if player:getLevel() > newminlevel then if player:removeMoney(newPrice) then addEvent(function() if isPlayer(cid) then addReset(cid) end end, 3000) local number = getResets(cid)+1 local msg ="---[Reset: "..number.."]-- You have reseted! You'll be disconnected in 3 seconds." player:popupFYI(msg) npcHandler.topic[cid] = 0 npcHandler:releaseFocus(cid) else npcHandler:say('Its necessary to have at least '..newPrice..' gp\'s for reseting!', cid) npcHandler.topic[cid] = 0 end else npcHandler:say('The minimum level for reseting is '..newminlevel..'!', cid) npcHandler.topic[cid] = 0 end elseif(msgcontains(msg, 'no')) and isInArray({1}, talkState[talkUser]) == TRUE then npcHandler.topic[cid] = 0 npcHandler:releaseFocus(cid) npcHandler:say('Ok.', cid) elseif msgcontains(msg, 'quantity') then npcHandler:say('You have a total of '..getResets(cid)..' reset(s).', cid) npcHandler.topic[cid] = 0 end return true end npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback) npcHandler:addModule(FocusModule:new()) Para configurar mexa nessa parte do npc : config = { minlevel = 150, --- Level inical para resetar price = 10000, --- Preço inicial para resetar newlevel = 20, --- Level após reset priceByReset = 0, --- Preço acrescentado por reset percent = 10, ---- Porcentagem da vida/mana que você terá ao resetar (em relação à sua antiga vida total) maxresets = 50, ---- Maximo de resets levelbyreset = 0 --- Quanto de level vai precisar a mais no próximo reset } Créditos: Flavio S
  10. Kemix

    task

    Poste seu npc que o erro pode estar nele e substitua o script movements por esse e veja se aparece algum erro no seu char: -- Sistema de Task feito por Leoric (Omega no XTibia) -- function onKill(cid, target) if not isPlayer(cid) then return true end if isSummon(target) then return true end local monster, permission = getPlayerStorageValue(cid,taskstg.monster), getPlayerStorageValue(cid,taskstg.permission) local kills, killstotal = getPlayerStorageValue(cid,taskstg.kills), getPlayerStorageValue(cid,taskstg.killstotal) if monster ~= -1 and monster ~= 0 then if isInArray(taskmonsters[monster],string.lower(getCreatureName(target))) then if kills == -1 then setPlayerStorageValue(cid,taskstg.kills,1) elseif kills + 1 == killstotal and taskMsg.bool == true then doPlayerSendTextMessage(cid, 21, taskMsg.msg) setPlayerStorageValue(cid,taskstg.kills,kills+1) else setPlayerStorageValue(cid,taskstg.kills,kills+1) end else doPlayerSendTextMessage(cid, 21, "erro 1") end else doPlayerSendTextMessage(cid, 21, "erro 2") end return true end
  11. function onStepIn(cid, item, position, fromPosition) local config = { msgDenied = "Você não e vip II , faça a quest vip II ", msgWelcome = "Seja Bem Vindo a Area vip II." } if getPlayerStorageValue(cid, 13540) <= 0 then doTeleportThing(cid, fromPosition, true) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, config.msgDenied) doSendMagicEffect(getThingPos(cid), CONST_ME_MAGIC_BLUE) return TRUE end doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, config.msgWelcome) return TRUE end
  12. Estou procurando uma equipe para me ajudar em meu otserv, sou programador em lua e conheço c++. Faz uns anos que estou parado mas peguei um global do forum para mexer e pretendo lançar ele um dia. Ainda não deu pra mexer muito mas implantei uns sistemas para dar a ideia do diferencial que eu quero no meu otserv: Sistema de resetes: Sistema de modificações de itens: Estou procurando pessoas que gostaram do projeto e queiram ajudar em qualquer área, de preferencia 18+. Deixem o contato ou mandem pm. Obrigado!
  13. Como ja tinha falado, Ja tentei e da o mesmo erro, mas no lugar o executeQuery mostra query.
  14. Esta dando erro no script. Acho que minha distro n tem essa função. Alguem pode falar como mecho com a database sem ser por db.executeQuery ou alguma outra opção? Erro: Script: Oque ja tentei: -Em vez de db.executeQuery usar db.Query -Em vez de db.executeQuery usar db.query
  • Quem Está Navegando   0 membros estão online

    • Nenhum usuário registrado visualizando esta página.
×
×
  • Criar Novo...