1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Join Texturing Contest #30 now in a legendary battle of mythological creatures!
    Dismiss Notice
  3. The Aftermath has been revealed for the 19th Terraining Contest! Be sure to check out the Results and see what came out of it.
    Dismiss Notice
  4. Melee Mapping Contest #3 - Results are out! Congratulate the winners and check plenty of new 4v4 melee maps designed for this competition!
    Dismiss Notice
  5. The winners of our cinematic soundtrack competition have been decided! Step by the Music Contest #11 - Results to check the entries and congratulate the winners!
    Dismiss Notice
  6. Check out the Staff job openings thread.
    Dismiss Notice

Counter Helix (v1.3)

Submitted by Losam
This bundle is marked as approved. It works and satisfies the submission rules.
Presentation


The concept of the spell (function) it is not of my authorship. However, it is my version of algorithms and functions of this spell.
I decided to update for 1.3 and to create this spell why taste of Axe (that is the hero that possesses this ability in it Endows him/it [it Defends the Elders]).


ChangeLogs


Current (v1.3)

  • New function (flotation texts)
  • Improvement in the general descriptions
  • A better ScreenShot (1600 x 1200 wiht 4 imagens)

Old (v1.2)

  • Old options (just of detection of trees)
  • Old description
  • Old ScreenShot


Spell's Function


When Mogul Kahn is attacked, in answer, he has 17% of chance to hit back the attack with a rotative blow that it punishes the opponents around.

  • Area of effect: 300.
  • Cause: 100/135/170/205 of damage.


Spell's Triggers


Setup

[trigger=Setup]
Counter Helix Setup
Events
Map initialization
Conditions
Actions
-------- // --------
Custom script: set udg_CH_Hash = InitHashtable()
-------- // --------
-------- Ability Counter Helix: --------
Set CH_Ability = Counter Helix
-------- // --------
-------- Ability that allows Mogul Kahn to rotate: --------
Set CH_Ability_Spin = Spin (Effect)
-------- // --------
-------- You want to see flotation texts what indicate how much the spell Counter Helix caused? If yes, maintain Boolean below as true: --------
Set CH_Allow_Text = True
-------- If you doesn't want to view flotation texts, set the booelan above has FALSE. --------
-------- // --------
-------- To destroy trees, mark the variable below as true: --------
Set CH_Allow_Tree = True
-------- For the spell not to destroy trees, configure the variable above as false. --------
-------- // --------
-------- Counter Helix's Buff: --------
Set CH_Buff = Counter Helix
-------- // --------
-------- Area of Effect: --------
Set CH_AoE[1] = 300.00
Set CH_AoE[2] = 300.00
Set CH_AoE[3] = 300.00
Set CH_AoE[4] = 300.00
-------- Note: area of effect per level. --------
-------- // --------
-------- Chance of executing this spell: --------
Set CH_Chance[1] = 17
Set CH_Chance[2] = 17
Set CH_Chance[3] = 17
Set CH_Chance[4] = 17
-------- Note: chance to spin per level. --------
-------- // --------
-------- Damage caused by this spell per level: --------
Set CH_Damage[1] = 100.00
Set CH_Damage[2] = 135.00
Set CH_Damage[3] = 170.00
Set CH_Damage[4] = 205.00
-------- // --------
-------- Maximum duration that Mogul Kahn can rotate: --------
Set CH_Spin_Max = 0.65
-------- Note: 0.65 are equal to 0.65 seconds. --------
-------- // --------
-------- Name of the Model of the Effect Special servant when an unit is punished by the Mogul kahn: --------
Set CH_Model = Abilities\Spells\Other\Stampede\StampedeMissileDeath.mdl
-------- // --------
-------- Angle that the flotation text will be guided: --------
Set CH_Text_Angle = 90.00
-------- Time (in Real) that the text takes to disappear of their views: --------
Set CH_Text_FadingAge = 1.50
-------- Time (in Real) that the flotation text takes to disappear definitively: --------
Set CH_Text_LifeSpan = 2.00
-------- Text size for the message that will be created: --------
Set CH_Text_Size = 11.50
-------- // --------
-------- Attack type caused by this spell: --------
Set CH_Type_Attack = Hero
-------- Damage type caused by this spell: --------
Set CH_Type_Damage = Universal
-------- // --------
-------- Type of responsible unit for destroying trees: --------
Set CH_Type_Dummy = Dummy
-------- // --------
-------- To destroy trees: --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
CH_Allow_Tree Equal to True
Then - Actions
-------- // --------
Set CH_Point = (Center of (Playable map area))
Unit - Create 1 CH_Type_Dummy for Neutral Passive at CH_Point facing Default building facing degrees
Set CH_Dummy = (Last created unit)
-------- // --------
-------- Destroy Leak: --------
Custom script: call RemoveLocation(udg_CH_Point)
-------- // --------
Else - Actions
-------- // --------
-------- To reduce the leg that can cause Trigger, use the following custom script: --------
Custom script: call DestroyTrigger (GetTriggeringTrigger())
-------- // --------
[/trigger]


Cast

[trigger=Cast]
Counter Helix
Events
Unit - A unit Is attacked
Conditions
((Triggering unit) has buff Stunned (Pause)) Equal to False
(Level of CH_Ability for (Triggering unit)) Greater than 0
((Triggering unit) has buff Stunned) Equal to False
((Triggering unit) has buff CH_Buff) Equal to True
((Triggering unit) is Stunned) Equal to False
((Triggering unit) is paused) Equal to False
Actions
-------- // --------
-------- Level of Spell Counter Helix for Caster: --------
Set CH_Level = (Level of CH_Ability for CH_Caster)
-------- // --------
-------- CH_Chance[0] it is to verify the probability of CH_Caster to rotate: --------
Set CH_Chance[0] = (Random integer number between 1 and 100)
-------- // --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
CH_Chance[0] Less than or equal to CH_Chance[CH_Level]
Then - Actions
-------- // --------
-------- Set the unit will go rotate: --------
Set CH_Caster = (Triggering unit)
-------- // --------
-------- Caster's Handle: --------
Set CH_Handle = (Triggering unit)
-------- // --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(CH_Caster is in CH_Group[1]) Equal to True
Then - Actions
-------- // --------
-------- Time that remains for Mogul Kahn to stop rotating: --------
Set CH_Spin_Current = (Load 1 of (Key CH_Handle) from CH_Hash)
-------- Save - 0.05 for Mogul Kahn whenever he rotates: --------
Hashtable - Save (CH_Spin_Current - 0.05) as 1 of (Key CH_Handle) in CH_Hash
-------- // --------
Else - Actions
-------- // --------
-------- Save 0.05 for Mogul Kahn whenever he rotates: --------
Hashtable - Save 0.00 as 1 of (Key CH_Handle) in CH_Hash
-------- // --------
-------- Add the ability that will allow Caster to rotate: --------
Unit - Add CH_Ability_Spin to CH_Caster
-------- // --------
-------- Order that Caster works the ability wins: --------
Unit - Order CH_Caster to Orc Blademaster - Bladestorm
-------- // --------
-------- Add Caster for the group: --------
Unit Group - Add CH_Caster to CH_Group[1]
-------- // --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Counter Helix Loop <gen> is on) Equal to True
Then - Actions
Else - Actions
-------- Turn ON the fallowing Trigger: --------
Trigger - Turn on Counter Helix Loop <gen>
-------- // --------
-------- // --------
-------- Point of CH_Caster: --------
Set CH_Point = (Position of CH_Caster)
-------- // --------
-------- Group of Units to be punished by CH_Caster: --------
Set CH_Group[2] = (Units within CH_AoE[CH_Level] of CH_Point)
-------- // --------
-------- Use the two lines below to remove mistakes: --------
Custom script: call RemoveLocation(udg_CH_Point)
Custom script: set bj_wantDestroyGroup = true
-------- // --------
-------- Catch the units of the group: --------
Unit Group - Pick every unit in CH_Group[2] and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked unit) belongs to an enemy of (Owner of CH_Caster)) Equal to True
((Picked unit) is A town-hall-type unit) Equal to False
((Picked unit) is Mechanical) Equal to False
((Picked unit) is A structure) Equal to False
((Picked unit) is Ethereal) Equal to False
((Picked unit) is hidden) Equal to False
((Picked unit) is dead) Equal to False
Then - Actions
-------- // --------
-------- Target that will be punished: --------
Set CH_Target = (Picked unit)
-------- // --------
-------- Special effect created in the target: --------
Special Effect - Create a special effect attached to the origin of CH_Target using CH_Model
Special Effect - Destroy (Last created special effect)
-------- The last created special effect was destroyed to remove any leaks. --------
-------- // --------
-------- Damage the affected target for this spell: --------
Unit - Cause CH_Caster to damage CH_Target, dealing CH_Damage[CH_Level] damage of attack type CH_Type_Attack and damage type CH_Type_Damage
-------- // --------
-------- In the next part it consists of the visualization of flotation texts. --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
CH_Allow_Text Equal to True
Then - Actions
-------- // --------
Set CH_Text_Player = (Player group((Owner of CH_Caster)))
-------- // --------
Floating Text - Create floating text that reads (|cffFF2B2B- + (String((Integer(CH_Damage[CH_Level]))))) above (Picked unit) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
Floating Text - Hide (Last created floating text) for (All players)
Floating Text - Show (Last created floating text) for CH_Text_Player
Floating Text - Change (Last created floating text): Disable permanence
Floating Text - Change the lifespan of (Last created floating text) to CH_Text_LifeSpan seconds
Floating Text - Change the fading age of (Last created floating text) to CH_Text_FadingAge seconds
Floating Text - Set the velocity of (Last created floating text) to 100.00 towards CH_Text_Angle degrees
-------- // --------
-------- Destroy/Remove any leak(s): --------
Custom script: call DestroyForce(udg_CH_Text_Player)
Custom script: set udg_CH_Text_Player = null
-------- // --------
Else - Actions
-------- // --------
Else - Actions
-------- // --------
Else - Actions
-------- // --------
[/trigger]


Loop

[trigger=Loop]
Counter Helix Loop
Events
Time - Every 0.05 seconds of game time
Conditions
Actions
Unit Group - Pick every unit in CH_Group[1] and do (Actions)
Loop - Actions
-------- // --------
-------- Caster: --------
Set CH_Caster = (Picked unit)
-------- // --------
-------- Caster's Handle: --------
Set CH_Handle = (Picked unit)
-------- // --------
-------- Time that remains for Mogul Kahn to stop rotating: --------
Set CH_Spin_Current = (Load 1 of (Key CH_Handle) from CH_Hash)
-------- // --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
Or - Any (Conditions) are true
Conditions
CH_Spin_Current Greater than or equal to CH_Spin_Max
(CH_Caster has buff Stunned (Pause)) Equal to True
(CH_Caster has buff Stunned) Equal to True
(CH_Caster is Stunned) Equal to True
(CH_Caster is paused) Equal to True
(CH_Caster is dead) Equal to True
Then - Actions
-------- Remove the ability that allows Caster to spin: --------
Unit - Remove CH_Ability_Spin from CH_Caster
-------- // --------
-------- Clean Mogul Kahn's saved data: --------
Hashtable - Clear all child hashtables of child (Key CH_Handle) in CH_Hash
-------- // --------
-------- When he stops rotating, remove of the group: --------
Unit Group - Remove CH_Caster from CH_Group[1]
-------- // --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(CH_Group[1] is empty) Equal to True
Then - Actions
-------- If the group (CH_Group[1]) is empty, turn OFF this trigger: --------
Trigger - Turn off (This trigger)
Else - Actions
-------- // --------
Else - Actions
-------- Increase the variable so that Mogul Kahn stops spinning: --------
Hashtable - Save (CH_Spin_Current + 0.05) as 1 of (Key CH_Handle) in CH_Hash
-------- // --------
-------- Level of Spell Counter Helix for Caster: --------
Set CH_Level = (Level of CH_Ability for CH_Caster)
-------- // --------
-------- To Destroy/Kill Trees: --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
CH_Allow_Tree Equal to True
Then - Actions
-------- Position of Caster: --------
Set CH_Point = (Position of CH_Caster)
-------- // --------
Destructible - Pick every destructible within CH_AoE[CH_Level] of CH_Point and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked destructible) is alive) Equal to True
Then - Actions
-------- // --------
-------- Order the dummy to harvest the picked destructible: --------
Unit - Order CH_Dummy to Harvest (Picked destructible)
-------- // --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Current order of CH_Dummy) Equal to (Order(harvest))
Then - Actions
-------- If the destructible is a tree, destroy: --------
Destructible - Kill (Picked destructible)
Else - Actions
-------- // --------
-------- Order that Dummy stops: --------
Unit - Order CH_Dummy to Stop
-------- // --------
Else - Actions
-------- // --------
-------- Destroy/Remove any leak(s): --------
Custom script: call RemoveLocation(udg_CH_Point)
-------- // --------
Else - Actions
-------- // --------
-------- --------------------------- --------
[/trigger]



How to Import


To import this spell in any map (it should be compatible with the version 1.26...) it is necessary to copy the triggers and custom objects and to put in the map.
Being:

  • Trigger - The paste "Counter Helix"
  • Abilities - "Counter Helix" and "Counter Helix (Effect) "
  • Buff - "Counter Helix"

Tip: Enable the option: Automatically create unknown variables while pasting trigger dates (Go to: File>Preferences>General in your Warcraft III World Editor)


Contact


  • Suggestions?
  • Doubts?
  • Critical?
  • Subjects?

For any question, I recommend sends her for me, in this page, in my profile or for a pm (private message).
I insist on helping.


Credits


  • For Hive WorkShop.
  • Moderator of this resource.
  • To you for the kindness, dowload and for everything! Thank you for participating in my work.


My request


If it uses my spell in any map, for kindness, thank for my work.
If it can, I ask that it rewards with reputation, in that way I can reward the favor.
Don't stop visiting my page for more resources.


Keywords:
Spell , Passive , Losam , DotA , Axe
Contents

Counter Helix (v1.3) (Map)

Reviews
Moderator
Counter Helix (v1.1) | Reviewed by Maker | 6th Jun 2013 APPROVED [IMG] Leakless and MUI [tr] [IMG] You could set caster has CH buff as the main condition to avoid unnecessary actions You save 0 as 1 of Trig unit, so...
  1. Counter Helix (v1.1) | Reviewed by Maker | 6th Jun 2013
    APPROVED

    [​IMG]
    • Leakless and MUI
    [​IMG]
    • You could set caster has CH buff as the main condition to
      avoid unnecessary actions
    • You save 0 as 1 of Trig unit, so take it out of the if/then/else
    • Don't check if the group is empty during every loop
      only when removing a unit from it
    • Making the unit repeatedly play the spin animation is not the best solution
      You could try hidden ability based on Channel and some follow through time
      You wouldn't need the looping trigger then


     
  2. deathismyfriend

    deathismyfriend

    Joined:
    Oct 24, 2012
    Messages:
    6,532
    Resources:
    14
    Spells:
    12
    Tutorials:
    2
    Resources:
    14
    u should store picked unit into a temp variable for better efficiency
     
  3. gorillabull

    gorillabull

    Joined:
    Jul 17, 2011
    Messages:
    1,368
    Resources:
    2
    Spells:
    2
    Resources:
    2
    very original and demonstrates a high skill in coding
     
  4. Maker

    Maker

    Joined:
    Mar 6, 2006
    Messages:
    9,193
    Resources:
    17
    Maps:
    2
    Spells:
    14
    Tutorials:
    1
    Resources:
    17
    It's copied from DotA.
     
  5. Losam

    Losam

    Joined:
    Mar 27, 2011
    Messages:
    260
    Resources:
    8
    Spells:
    8
    Resources:
    8
    I know this is a kind of copy, read the description of the spell?

    Note that not put the triggers why is there bugs in time to give uploading the spell.




    Well, very thanks.
     
    Last edited by a moderator: Jun 7, 2013
  6. MasterTrainer

    MasterTrainer

    Joined:
    Apr 14, 2012
    Messages:
    2,768
    Resources:
    3
    Icons:
    1
    Maps:
    1
    Spells:
    1
    Resources:
    3
    Could you post the triggers?
     
  7. Losam

    Losam

    Joined:
    Mar 27, 2011
    Messages:
    260
    Resources:
    8
    Spells:
    8
    Resources:
    8

    Well, in answer to your question, no. Do not put that there were bugs that doubled the triggers. But, in the next version I'll put the Triggers.
     
  8. Mythic

    Mythic

    Joined:
    Apr 24, 2012
    Messages:
    7,521
    Resources:
    45
    Models:
    32
    Icons:
    2
    Maps:
    3
    Spells:
    6
    Tutorials:
    2
    Resources:
    45
    LOL I tried to do this before with pulverize. But when the map got screwed, tried to do another again but failed. Anyways, GJ. :cgrin:
     
  9. zv27

    zv27

    Joined:
    Aug 21, 2010
    Messages:
    296
    Resources:
    0
    Resources:
    0
    I have a lot of open version of dota, and definitely, this is not a copy
    [It is possible that the author had access to dota var3map.j file, but definitely, this is not an identical copy]


    Anyway, good job.
     
  10. Mythic

    Mythic

    Joined:
    Apr 24, 2012
    Messages:
    7,521
    Resources:
    45
    Models:
    32
    Icons:
    2
    Maps:
    3
    Spells:
    6
    Tutorials:
    2
    Resources:
    45
    He means the idea is not original, like gorillabull said.
     
  11. The.Final.Blow

    The.Final.Blow

    Joined:
    May 9, 2012
    Messages:
    19
    Resources:
    0
    Resources:
    0
    very useful +rep
     
  12. Shade Da Scout

    Shade Da Scout

    Joined:
    Apr 23, 2011
    Messages:
    316
    Resources:
    1
    Icons:
    1
    Resources:
    1
    Still waiting for phoenix and ancient aparation spell pack :)
     
  13. Losam

    Losam

    Joined:
    Mar 27, 2011
    Messages:
    260
    Resources:
    8
    Spells:
    8
    Resources:
    8
    Reply to Shade Da Scout

    ... Did not quite understand, but I hope you like the spell and do not forget to participate!
     
  14. hemmedo

    hemmedo

    Joined:
    Jun 13, 2008
    Messages:
    264
    Resources:
    0
    Resources:
    0
    I deleted the buff conditions for some personal reasons and still working proper?...did I do wrong?