Warcraft III resources & community, 2003–2006 · archived

Voiding Blade

not rated
Submitted by Div_STrigger Enhanced481 downloads22 KB
Screenshot
Screenshot
Simple Spell made for fun.



Voiding Blade:

When actived, gives a 27% chance to every attack made by the Naga Anti-Mage to deal 0.5 damage for every mana point missing of the attacked unit. Also increases the Feedback`s mana burn damage by: 5/10/15.
File Name
Voiding Blade.w3x
Author
Div
Download

Comments

13
yeah Geelad ur right, but there is a problem
i dont know too much about Jass or GUI

Cry4
well, i agree with u, i just did the way that i did cos i've forgot that another way, but now that u said that, i wouldnt do by the Zalvurek's way, cos first of all i have to put the Variable sentece: Chance = random less than or equal to 27, that is a concret way to grant the spell function

tnx for all of urs opinions, hope u guys keep posting them

Hope u guys keep posting ur opinions
ty
@Div_S: That's a nice spell, a bit like Anti-Mage's Mana Void.. The concept is OK and the spell is a bit imbalanced.

However, the triggering is lacking.

Effect
    Events
        Unit - A unit Is attacked
    Conditions
        ((Attacking unit) has buff Voiding Blade (Effect)) Equal to True
    Actions
        Set Caster = (Attacking unit)
        Set Target = (Attacked unit)
        Trigger - Turn on Damage
        Set Chance = (Random integer number between 1 and 100)
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                Chance Less than or equal to 27
            Then - Actions
                Unit - Cause Caster to damage Target, dealing (((Max mana of Target) - (Mana of Target)) x 0.50) damage of attack type Chaos and damage type Normal
                Wait 0.10 seconds
                Special Effect - Create a special effect at (Position of Target) using Abilities\Spells\Items\TomeOfRetraining\TomeOfRetrainingCaster.mdl
                Set Burst = (Last created special effect)
                Wait 0.20 seconds
                Special Effect - Destroy Burst
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Level of Feedback  for Caster) Equal to 1
            Then - Actions
                Unit - Set mana of Target to ((Mana of Target) - 5.00)
                Unit - Cause Caster to damage Target, dealing 5.00 damage of attack type Hero and damage type Normal
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Level of Feedback  for Caster) Equal to 2
            Then - Actions
                Unit - Set mana of Target to ((Mana of Target) - 10.00)
                Unit - Cause Caster to damage Target, dealing 10.00 damage of attack type Hero and damage type Normal
            Else - Actions
                Do nothing
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Level of Feedback  for Caster) Equal to 3
            Then - Actions
                Unit - Set mana of Target to ((Mana of Target) - 15.00)
                Unit - Cause Caster to damage Target, dealing 15.00 damage of attack type Hero and damage type Normal
            Else - Actions
                Do nothing


Instead of all this code, you could have had this:


function Trig_Effect_Conditions takes nothing returns boolean
return UnitHasBuff(GetAttacker(), 'B001')
endfunction

function Trig_Effect_Actions take nothing returns nothing
local unit u      = GetAttacker()
local unit t       = GetAttackedUnit()
local integer i   = GetRandomInt(1,100)
local effect fx   = "Abilities\\Spells\\Items\\TomeOfRetraining\\TomeOfRetrainingCaster.mdl"
local integer lvl = GetUnitAbilityLevel(u, 'A001')

call UnitDamageTarget( u, t, ( ( ( GetUnitStateSwap(UNIT_STATE_MAX_MANA, t) - GetUnitStateSwap(UNIT_STATE_MANA, t) ) * 0.50 ) + (5 * lvl ) ), ATTACK_TYPE_CHAOS, DAMAGE_TYPE_NORMAL )
call SetUnitMana( t, ( GetUnitStateSwap(UNIT_STATE_MANA, t) - ( 5.00 * lvl) ) )
call TriggerSleepAction( 0.25 ) //The wait function does not use values smaller than 0.25. If you put 0.10 in the Wait action, it will consider it as 0.25.
call AddSpecialEffectLoc( GetUnitLoc(t), fx)
call TriggerSleepAction( 0.25 )
call DestroyEffect( fx )

set fx  = null
set u   = null
set t   = null



@Zalvurek: The variables are used instead of values to prevent memory leaks.
AWWW REALLY I AM. I'M FLATTERED :oops: :oops: :)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Random integer number between 1 and 100) Less than or equal to 27

OK here's the thing about this one. It's a shorter and easier way to use in trigs just that the spell would need a source in this case the variable. Be a great idea but it's gonna bug somewhere around there. :? :? :wink:
Can someone explain why so many variables were used in the spell that could have been replaced by what they were set to?

For example; instead of
        Set Chance = (Random integer number between 1 and 100)
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                Chance Less than or equal to 27


Why wouldn't it be
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    If - Conditions
        (Random integer number between 1 and 100) Less than or equal to 27


That way you wouldn't need the variable and it cleans the trigger up.
Tanks Cry4 :)
ur my real budy :wink:
BAH it's an excellent spell let's just put it to that hehehe :D :D :D
"i dont get it"

... what dont u get? i didnt understand u.... :?
well, im sorry for the image, i couldnt get a good ss cos, what may i pick from this kind of spell? then i got a naga from the internet, nothing liked with the map one but, still making some sense ;P
i dont get it :?
D00d, that's the naga model from World of Warcraft... Screenshot looks like it was taken in the Ruins of Mathystra in Darkshore, Kalimdor.

The only way he'd get the model here is to extract it.
upload the model holding it!!
thats a creative one, for each MP missing 0.5 dmg

nice!