Postado Janeiro 27, 2016 9 anos estou com uma spell de paladin, mais está acontecendo o seguinte, ela está quase perfeita, é uma spell que ao usa-la, você depois fica 35 seg com [COOLDRAW] mais caso voce tente usa-la novamente, a mana é gasta e a spell ainda está em COOLDRAW eu gostaria, que enquanto estivesse de COOLDRAW, não fosse possivel falar o nome da magia novamente !!!! se alguem puder me ajudar ficarei muito grato e reputarei com REP ++ @Xagah ------------------Script por Daniel Oliveira------------------ local acombat1 = createCombatObject() local combat1 = createCombatObject() setCombatParam(combat1, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat1, COMBAT_PARAM_DISTANCEEFFECT, 30) setCombatFormula(combat1, COMBAT_FORMULA_LEVELMAGIC, -7.7, 0, -10.9, 0) local condition = createConditionObject(CONDITION_PARALYZE) setConditionParam(condition, CONDITION_PARAM_TICKS, 6000) setConditionFormula(condition, -0.7, -0, -0.7, -0) setCombatCondition(acombat1, condition) local acombat2 = createCombatObject() local combat2 = createCombatObject() setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat2, COMBAT_PARAM_DISTANCEEFFECT, 30) setCombatFormula(combat2, COMBAT_FORMULA_LEVELMAGIC, -7.7, 0, -10.9, 0) local condition = createConditionObject(CONDITION_PARALYZE) setConditionParam(condition, CONDITION_PARAM_TICKS, 6000) setConditionFormula(condition, -0.7, -0, -0.7, -0) setCombatCondition(acombat2, condition) arr1 = { {0, 1, 1, 1, 0}, {1, 1, 1, 1, 1}, {1, 1, 2, 1, 1}, {1, 1, 1, 1, 1}, {0, 1, 1, 1, 0}, } arr2 = { {0, 0, 0, 1, 0, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, {0, 0, 1, 1, 1, 0, 0}, {1, 1, 1, 2, 1, 1, 1}, {0, 0, 1, 1, 1, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, } local area1 = createCombatArea(arr1) local area2 = createCombatArea(arr2) setCombatArea(acombat1, area1) setCombatArea(acombat2, area2) local function onCastSpell1(parameters) doCombat(parameters.cid, parameters.acombat1, parameters.var) end local function onCastSpell2(parameters) doCombat(parameters.cid, parameters.acombat2, parameters.var) end local function Cooldown(cid) if isPlayer(cid) == TRUE then doPlayerSendTextMessage(cid,MESSAGE_STATUS_WARNING,'CD: Exevo Gran Mas Shadow.') end end local exhausted_seconds = 35 -- Segundos que o Player Poderá castar a spell novamente local exhausted_storagevalue = 4345 -- Storage Value do Cool Down function onTargetCreature(cid, target) local function sun1(cid) doPlayerSay(cid,"...",16) return TRUE end local rand = math.random(1,5) if isPlayer(target) == true and rand == 5 then doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) return TRUE elseif isPlayer(target) == true and rand == 4 then doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) return TRUE elseif isPlayer(target) == true and rand < 4 then doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) doSendMagicEffect(getCreaturePosition(target), 60) return TRUE else doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) return TRUE end end setCombatCallback(combat1, CALLBACK_PARAM_TARGETCREATURE, "onTargetCreature") function onTargetTile(cid, pos) doCombat(cid,combat1,positionToVariant(pos)) end setCombatCallback(acombat1, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onTargetTile(cid, pos) doCombat(cid,combat2,positionToVariant(pos)) end setCombatCallback(acombat2, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) if(os.time() < getPlayerStorageValue(cid, exhausted_storagevalue)) then doPlayerSendCancel(cid,'O Cooldown não está pronto.') return TRUE end local function spell4(cid) return doCombat(cid, acombat1, var) end local function spell3(cid) addEvent(spell4, 1 * 450, cid) return doCombat(cid, acombat2, var) end local function spell3(cid) return doCombat(cid, acombat1, var) end local function spell2(cid) addEvent(spell3, 1 * 450, cid) return doCombat(cid, acombat2, var) end local function spell1(cid) addEvent(spell2, 1 * 450, cid) return doCombat(cid, acombat2, var) end addEvent(spell1, 1 * 450, cid) addEvent(Cooldown, 1*35000,cid) setPlayerStorageValue(cid, exhausted_storagevalue, os.time() + exhausted_seconds) return doCombat(cid, acombat1, var) end
Postado Janeiro 27, 2016 9 anos Cooldraw foi foda de ler :// é cooldown; enfim, arrumei seu script, tem muita coisa mal feita aí mas achei melhor não mudar muito. ------------------Script por Daniel Oliveira------------------ local acombat1 = createCombatObject() local combat1 = createCombatObject() setCombatParam(combat1, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat1, COMBAT_PARAM_DISTANCEEFFECT, 30) setCombatFormula(combat1, COMBAT_FORMULA_LEVELMAGIC, -7.7, 0, -10.9, 0) local condition = createConditionObject(CONDITION_PARALYZE) setConditionParam(condition, CONDITION_PARAM_TICKS, 6000) setConditionFormula(condition, -0.7, -0, -0.7, -0) setCombatCondition(acombat1, condition) local acombat2 = createCombatObject() local combat2 = createCombatObject() setCombatParam(combat2, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat2, COMBAT_PARAM_DISTANCEEFFECT, 30) setCombatFormula(combat2, COMBAT_FORMULA_LEVELMAGIC, -7.7, 0, -10.9, 0) local condition = createConditionObject(CONDITION_PARALYZE) setConditionParam(condition, CONDITION_PARAM_TICKS, 6000) setConditionFormula(condition, -0.7, -0, -0.7, -0) setCombatCondition(acombat2, condition) local arr1 = { {0, 1, 1, 1, 0}, {1, 1, 1, 1, 1}, {1, 1, 2, 1, 1}, {1, 1, 1, 1, 1}, {0, 1, 1, 1, 0}, } local arr2 = { {0, 0, 0, 1, 0, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, {0, 0, 1, 1, 1, 0, 0}, {1, 1, 1, 2, 1, 1, 1}, {0, 0, 1, 1, 1, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, } local area1 = createCombatArea(arr1) local area2 = createCombatArea(arr2) setCombatArea(acombat1, area1) setCombatArea(acombat2, area2) local function onCastSpell1(parameters) (parameters.cid, parameters.acombat1, parameters.var) end local function onCastSpell2(parameters) doCombat(parameters.cid, parameters.acombat2, parameters.var) end local function Cooldown(cid) if isPlayer(cid) then doPlayerSendTextMessage(cid,MESSAGE_STATUS_WARNING,'CD: Exevo Gran Mas Shadow.') end end local exhausted_seconds = 35 -- Segundos que o Player Poderá castar a spell novamente local exhausted_storagevalue = 4345 -- Storage Value do Cool Down function onTargetCreature(cid, target) local function sun1(cid) doPlayerSay(cid,"...",16) return true end local rand = math.random(1,5) if isPlayer(target) and rand == 5 then doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) elseif isPlayer(target) and rand == 4 then doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) elseif isPlayer(target) and rand < 4 then doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) doSendMagicEffect(getCreaturePosition(target), 60) else doSendAnimatedText(getCreaturePosition(target), "Stun!", TEXTCOLOR_WHITE_EXP) end return true end setCombatCallback(combat1, CALLBACK_PARAM_TARGETCREATURE, "onTargetCreature") function onTargetTile(cid, pos) doCombat(cid,combat1,positionToVariant(pos)) end setCombatCallback(acombat1, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onTargetTile(cid, pos) doCombat(cid,combat2,positionToVariant(pos)) end setCombatCallback(acombat2, CALLBACK_PARAM_TARGETTILE, "onTargetTile") function onCastSpell(cid, var) if(os.time() < getPlayerStorageValue(cid, exhausted_storagevalue)) then doPlayerSendCancel(cid,'O Cooldown não está pronto.') return false end local function spell4(cid) return doCombat(cid, acombat1, var) end local function spell3(cid) addEvent(spell4, 1 * 450, cid) return doCombat(cid, acombat2, var) end local function spell3(cid) return doCombat(cid, acombat1, var) end local function spell2(cid) addEvent(spell3, 1 * 450, cid) return doCombat(cid, acombat2, var) end local function spell1(cid) addEvent(spell2, 1 * 450, cid) return doCombat(cid, acombat2, var) end addEvent(spell1, 1 * 450, cid) addEvent(Cooldown, 1*35000,cid) setPlayerStorageValue(cid, exhausted_storagevalue, os.time() + exhausted_seconds) return doCombat(cid, acombat1, var) end Todos os meus trabalhos importantes estão na seção "Sobre mim" no meu perfil; Dá uma passada lá! "Há três caminhos para o fracasso: não ensinar o que se sabe, não praticar o que se ensina, e não perguntar o que se ignora." - São Beda (obg ao @Beeny por fazer essa linda sign <3)
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.