1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  3. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  4. The Lich King demands your service! We've reached the 19th edition of the Icon Contest. Come along and make some chilling servants for the one true king.
    Dismiss Notice
  5. The 4th SFX Contest has started. Be sure to participate and have a fun factor in it.
    Dismiss Notice
  6. The poll for the 21st Terraining Contest is LIVE. Be sure to check out the entries and vote for one.
    Dismiss Notice
  7. The results are out! Check them out.
    Dismiss Notice
  8. Don’t forget to sign up for the Hive Cup. There’s a 555 EUR prize pool. Sign up now!
    Dismiss Notice
  9. The Hive Workshop Cup contest results have been announced! See the maps that'll be featured in the Hive Workshop Cup tournament!
    Dismiss Notice
  10. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Infinite Slashes v1.05

Submitted by WyrmSlayer
This bundle is marked as approved. It works and satisfies the submission rules.
The blademaster rushes to his enemy target. Once he reaches his target, he then attacks the target 10/14/18 times, dealing 50/100/150 damage per attack.

Made the config trigger.
Somethings arent configurable in the trigger. They need to be configurated in the object editor.
These are:
>the models of illusions following the master
>The animation index (used to make the caster walk)
before changing it you must know which is the correct number of the animation you want.
I used this because the walking animation cannot be played by the normal GUI trigger.

It is 6 here because it is the walking animation number of the blademaster.
The 7th animation of him, here in hiveworkshop.
6 because the index starts from 0.

Didnt use the script below about the moving of the caster, I couldnt understand it, Im new at this =)



Fixed the leaks too.

Here are the Triggers:

[
Trigger - Config
  • Configuration Trigger
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- Here you can set the Number of Attacks --------
      • Set CLMaxSlashes[1] = 10
      • Set CLMaxSlashes[2] = 14
      • Set CLMaxSlashes[3] = 18
      • -------- Here you can set the speed --------
      • Set CLSpeed = 25.00
      • -------- Here you can set the Animation --------
      • Set CLAnimation = Attack
      • -------- Here you can set the Special Effect --------
      • Set CLEffect = Abilities\Weapons\PhoenixMissile\Phoenix_Missile.mdl
      • -------- Here you can set the Attachment of the SFX --------
      • Set CLAttachment = weapon
      • -------- Here you can set the Damage --------
      • Set CLDamage[1] = 50.00
      • Set CLDamage[2] = 100.00
      • Set CLDamage[3] = 150.00
      • -------- Here you can set the animation speed --------
      • Set CLAnimationSpeed = 250.00
      • -------- Here you can set the transparency of the Illus --------
      • Set CLTransparency = 60.00
      • -------- Here you can set the duration of the Illusions --------
      • Set CLDuration = 0.40
      • -------- Here you can set the Minimum distance required to begin attacking --------
      • Set CLMinimumDistance = 100.00
      • -------- Here you can set the animation index --------
      • Set CLAnimationIndex = 6
      • -------- Here you can set the slash interval --------
      • Set CLSlashInterval = 5
      • -------- Here you can set the SFX when the target is slashed. --------
      • Set CLSFX = Objects\Spawnmodels\Human\HumanBlood\BloodElfSpellThiefBlood.mdl
      • -------- Here you can change the attachment of that SFX --------
      • Set CLAttach = chest

[
Trigger - Cast
  • Infinite Slashes Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Infinite Slashes
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • InfiniteSlashesIndex Equal to 0
        • Then - Actions
          • Trigger - Turn on Infinite Slashes Loop <gen>
        • Else - Actions
      • -------- Do not touch this --------
      • Set InfiniteSlashesIndex = (InfiniteSlashesIndex + 1)
      • Set InfiniteSlashesMui = (InfiniteSlashesMui + 1)
      • Set InfiniteSlashesBol1[InfiniteSlashesMui] = True
      • Set InfiniteSlashesBol2[InfiniteSlashesMui] = True
      • Set InfiniteSlashesCaster[InfiniteSlashesMui] = (Triggering unit)
      • Set InfiniteSlashesTarget[InfiniteSlashesMui] = (Target unit of ability being cast)
      • Set CLSpellLevel[InfiniteSlashesMui] = (Level of Infinite Slashes for InfiniteSlashesCaster[InfiniteSlashesMui])
      • -------- Do not touch this --------
      • Animation - Change InfiniteSlashesCaster[InfiniteSlashesMui]'s animation speed to CLAnimationSpeed% of its original speed
      • -------- Special Effect --------
      • Special Effect - Create a special effect attached to the CLAttachment of InfiniteSlashesCaster[InfiniteSlashesMui] using CLEffect
      • Set InfiniteSlashesSFX[InfiniteSlashesMui] = (Last created special effect)
      • -------- Setting Number of Slashes --------
      • Set InfiniteSlashesCount2[InfiniteSlashesMui] = CLMaxSlashes[CLSpellLevel[InfiniteSlashesMui]]
      • -------- Pausing the Caster --------
      • Unit - Pause InfiniteSlashesCaster[InfiniteSlashesMui]

[
Trigger - Loop
  • Infinite Slashes Loop
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • For each (Integer InfiniteSlashesLoop) from 1 to InfiniteSlashesMui, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • InfiniteSlashesBol1[InfiniteSlashesLoop] Equal to True
            • Then - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • InfiniteSlashesBol2[InfiniteSlashesLoop] Equal to True
                • Then - Actions
                  • -------- Moving the Caster --------
                  • Set InfiniteSlashesTargetLoc = (Position of InfiniteSlashesTarget[InfiniteSlashesLoop])
                  • Set InfiniteSlashesCasterLoc = (Position of InfiniteSlashesCaster[InfiniteSlashesLoop])
                  • Set InfiniteSlashesAngle[InfiniteSlashesLoop] = (Angle from InfiniteSlashesCasterLoc to InfiniteSlashesTargetLoc)
                  • Unit - Make InfiniteSlashesCaster[InfiniteSlashesLoop] face InfiniteSlashesAngle[InfiniteSlashesLoop] over 0.00 seconds
                  • Set InfiniteSlashesCasterLoc2 = (InfiniteSlashesCasterLoc offset by CLSpeed towards InfiniteSlashesAngle[InfiniteSlashesLoop] degrees)
                  • Custom script: call RemoveLocation(udg_InfiniteSlashesCasterLoc)
                  • Custom script: call SetUnitX(udg_InfiniteSlashesCaster[udg_InfiniteSlashesLoop],GetUnitX(udg_InfiniteSlashesCaster[udg_InfiniteSlashesLoop]) + udg_CLSpeed * Cos(udg_InfiniteSlashesAngle[udg_InfiniteSlashesLoop] * bj_DEGTORAD))
                  • Custom script: call SetUnitY(udg_InfiniteSlashesCaster[udg_InfiniteSlashesLoop],GetUnitY(udg_InfiniteSlashesCaster[udg_InfiniteSlashesLoop]) + udg_CLSpeed * Sin(udg_InfiniteSlashesAngle[udg_InfiniteSlashesLoop] * bj_DEGTORAD))
                  • Set InfiniteSlashesDistance[InfiniteSlashesLoop] = (Distance between InfiniteSlashesCasterLoc2 and InfiniteSlashesTargetLoc)
                  • Custom script: call SetUnitAnimationByIndex( udg_InfiniteSlashesCaster[udg_InfiniteSlashesLoop], udg_CLAnimationIndex)
                  • Unit - Create 1 Infinite Slashes Dummy for (Owner of InfiniteSlashesCaster[InfiniteSlashesLoop]) at InfiniteSlashesCasterLoc2 facing InfiniteSlashesAngle[InfiniteSlashesLoop] degrees
                  • Animation - Change (Last created unit)'s vertex coloring to (100.00%, 100.00%, 100.00%) with CLTransparency% transparency
                  • Unit - Add a CLDuration second Generic expiration timer to (Last created unit)
                  • Custom script: call SetUnitAnimationByIndex(GetLastCreatedUnit(), udg_CLAnimationIndex)
                  • Custom script: call RemoveLocation(udg_InfiniteSlashesCasterLoc2)
                  • Custom script: call RemoveLocation(udg_InfiniteSlashesTargetLoc)
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • InfiniteSlashesDistance[InfiniteSlashesLoop] Less than or equal to CLMinimumDistance
                    • Then - Actions
                      • -------- Setting the Loop to attack instead of move --------
                      • Set InfiniteSlashesBol2[InfiniteSlashesLoop] = False
                      • -------- Pausing the Target --------
                      • Unit - Pause InfiniteSlashesTarget[InfiniteSlashesLoop]
                    • Else - Actions
                • Else - Actions
                  • -------- Counting the time before each strike is executed --------
                  • Set InfiniteSlashesCount1[InfiniteSlashesLoop] = (InfiniteSlashesCount1[InfiniteSlashesLoop] + 1)
                  • -------- Here its every .2 seconds as the slash starts when the int is 5 --------
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • InfiniteSlashesCount1[InfiniteSlashesLoop] Equal to CLSlashInterval
                    • Then - Actions
                      • -------- Stopping previous sounds --------
                      • Sound - Stop MetalHeavySliceStone2 <gen> Immediately
                      • -------- Reseting the count --------
                      • Set InfiniteSlashesCount1[InfiniteSlashesLoop] = 0
                      • Animation - Play InfiniteSlashesCaster[InfiniteSlashesLoop]'s CLAnimation animation
                      • -------- Dealing Damage --------
                      • Unit - Cause InfiniteSlashesCaster[InfiniteSlashesLoop] to damage InfiniteSlashesTarget[InfiniteSlashesLoop], dealing CLDamage[CLSpellLevel[InfiniteSlashesLoop]] damage of attack type Normal and damage type Normal
                      • Special Effect - Create a special effect attached to the CLAttach of InfiniteSlashesTarget[InfiniteSlashesLoop] using CLSFX
                      • Special Effect - Destroy (Last created special effect)
                      • -------- Creating Sound --------
                      • Sound - Play MetalHeavySliceStone2 <gen> at 100.00% volume, attached to InfiniteSlashesTarget[InfiniteSlashesLoop]
                      • -------- Decreasing the remaining attacks --------
                      • Set InfiniteSlashesCount2[InfiniteSlashesLoop] = (InfiniteSlashesCount2[InfiniteSlashesLoop] - 1)
                      • -------- Do not touch this --------
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • (InfiniteSlashesTarget[InfiniteSlashesLoop] is paused) Not equal to True
                        • Then - Actions
                          • Unit - Pause InfiniteSlashesTarget[InfiniteSlashesLoop]
                        • Else - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • Or - Any (Conditions) are true
                            • Conditions
                              • (InfiniteSlashesCaster[InfiniteSlashesLoop] is alive) Not equal to True
                              • (InfiniteSlashesTarget[InfiniteSlashesLoop] is alive) Not equal to True
                              • InfiniteSlashesCount2[InfiniteSlashesLoop] Equal to 0
                        • Then - Actions
                          • -------- Do not touch this --------
                          • Unit - Order InfiniteSlashesCaster[InfiniteSlashesLoop] to Stop
                          • Set InfiniteSlashesBol1[InfiniteSlashesLoop] = False
                          • Special Effect - Destroy InfiniteSlashesSFX[InfiniteSlashesLoop]
                          • Unit - Unpause InfiniteSlashesTarget[InfiniteSlashesLoop]
                          • Unit - Unpause InfiniteSlashesCaster[InfiniteSlashesLoop]
                          • Animation - Change InfiniteSlashesCaster[InfiniteSlashesLoop]'s animation speed to 100.00% of its original speed
                          • Set InfiniteSlashesBol1[InfiniteSlashesLoop] = False
                          • Set InfiniteSlashesBol2[InfiniteSlashesLoop] = False
                          • Set InfiniteSlashesCaster[InfiniteSlashesLoop] = No unit
                          • Set InfiniteSlashesTarget[InfiniteSlashesLoop] = No unit
                          • Set InfiniteSlashesDistance[InfiniteSlashesLoop] = 0.00
                          • Set InfiniteSlashesCount2[InfiniteSlashesLoop] = 0
                          • Set InfiniteSlashesIndex = (InfiniteSlashesIndex - 1)
                          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                            • If - Conditions
                              • InfiniteSlashesIndex Equal to 0
                            • Then - Actions
                              • Set InfiniteSlashesMui = 0
                              • Trigger - Turn off (This trigger)
                            • Else - Actions
                          • -------- Do not touch this --------
                        • Else - Actions
                    • Else - Actions
            • Else - Actions

[
Trigger - Dummy
  • Infintie Slashes Dummy
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Infinite Slashes Dummy
    • Actions
      • Unit - Remove (Triggering unit) from the game


Keywords:
slash, slashes, omnislash, dash, blademaster, samurai, attack, charge, red, fire, slice, move
Contents

Infinite Slashes (Map)

Reviews
Moderator
01:36, 16th Dec 2012 Magtheridon96: Approved. I would suggest looking at Hanky's Dynamic Indexing Template
  1. WyrmSlayer

    WyrmSlayer

    Joined:
    Apr 18, 2010
    Messages:
    67
    Resources:
    1
    Spells:
    1
    Resources:
    1
    Just did sir =)
     
  2. Almia

    Almia

    Joined:
    Apr 24, 2012
    Messages:
    4,856
    Resources:
    35
    Spells:
    30
    Tutorials:
    4
    JASS:
    1
    Resources:
    35
    • Custom script:call SetUnitAnimationByIndex(GetLastCreatedUnit(), 6)

    You havent applied the animation index here.

    InfiniteSlashesCount1[InfiniteSlashesLoop] Equal to 5
    should be configurable same w/
    Special Effect - Create a special effect attached to the chest of InfiniteSlashesTarget[InfiniteSlashesLoop] using Objects\Spawnmodels\Human\HumanBlood\BloodElfSpellThiefBlood.mdl

    Should also add prefix so that it wont collide on the maps that will be imported from this spell.

    You havent fixed the SetUnitX/Y problem,please view my previous review.
     
  3. WyrmSlayer

    WyrmSlayer

    Joined:
    Apr 18, 2010
    Messages:
    67
    Resources:
    1
    Spells:
    1
    Resources:
    1
    can you make the trigger of that SETUNIT X/Y i dont really get how its done =)
     
  4. Almia

    Almia

    Joined:
    Apr 24, 2012
    Messages:
    4,856
    Resources:
    35
    Spells:
    30
    Tutorials:
    4
    JASS:
    1
    Resources:
    35
    i have posted the code,just put a line on the custom script,replace angle w/ your angle and replace speed w/ your own speed,replace also the unit.
     
  5. WyrmSlayer

    WyrmSlayer

    Joined:
    Apr 18, 2010
    Messages:
    67
    Resources:
    1
    Spells:
    1
    Resources:
    1
    Updated, the triggers are posted already =)
     
    Last edited: Dec 14, 2012
  6. meowie

    meowie

    Joined:
    Jun 13, 2010
    Messages:
    43
    Resources:
    0
    Resources:
    0
    There's no need to separate the configuration trigger. you can just combine it with Casting trigger.

    Damage[1]= 50
    replace
    Set Damage[InfiniteSlashesIndex] = (50.00 x (Real((Level of Infinite Slashes for InfiniteSlashesCaster[InfiniteSlashesMui]))))

    Unit - Cause InfiniteSlashesCaster[InfiniteSlashesLoop] to damage InfiniteSlashesTarget[InfiniteSlashesLoop], dealing Damage[SpellLevel[InfiniteSlashesLoop]] damage of attack type Normal and damage type Normal
    those are unnecessary indexing of an integer

    Since you are using a unit dummy. Create a Unit type Variable to Configure it so that users can use different Dummy unit.
    Pause is a lousy function it is not consistent. You need to add condition to check if caster and Target are STILL pausing . Multiple cast on a same hero will cause it to lose its constant. use if/else checking and pause the hero till the slashing is finish.
     
  7. WyrmSlayer

    WyrmSlayer

    Joined:
    Apr 18, 2010
    Messages:
    67
    Resources:
    1
    Spells:
    1
    Resources:
    1
    Cant they just change it in the object editor? Its the model of the dummy that needs to be changed =.= other than that is the fact that they need to know what number is the index of the anim for walking or doing something else.

    As for the damage, I cannot do that. It may seem that the damage dealt is 50xlevel but if a user wants to change it, then boom, the trigger dies.
    That is why randatamus wanted me to create a config trigger =)

    The damage part is fine already, dont need to change it
     
  8. Almia

    Almia

    Joined:
    Apr 24, 2012
    Messages:
    4,856
    Resources:
    35
    Spells:
    30
    Tutorials:
    4
    JASS:
    1
    Resources:
    35
    @meowie
    Are you kidding me?tell that in front of Mag.
    He will laugh at you.

    We are making this trigger so that users can easily see that constants of the spell and doest make the user scroll down and find the constants by them self,especially the beginners.
     
  9. WyrmSlayer

    WyrmSlayer

    Joined:
    Apr 18, 2010
    Messages:
    67
    Resources:
    1
    Spells:
    1
    Resources:
    1
    Anyways, i just added the pause detection thing, it would be helpful too =)
     
  10. meowie

    meowie

    Joined:
    Jun 13, 2010
    Messages:
    43
    Resources:
    0
    Resources:
    0
    User friendly wise i understand. However it's kinda inefficient since it declare the function at map int if it isn't used then it just waste of memory imo but no matter.



    The reason of using variable to declare unit type is to utilize the use variation. you wouldn't want 3 different unit model use the same Dummy. it look stupid.
    Secondly , Since you used unit index it's up to them solely to find the unit index. because it involve checking unit index from war3 viewer .Once again you don't expect this spell solely used on a hero with same animation index.

    Yes it "may" be fine as it is now. But you just declare pointless function such as this. Once again its up to user to configure its damage function with the help of Documentation.
    For the damage declare
    Set SpellLevel[InfiniteSlashesMui] = (Level of Infinite Slashes for InfiniteSlashesCaster[InfiniteSlashesMui])
    is that a need to convert to integer? No.

    Unit - Cause InfiniteSlashesCaster[InfiniteSlashesLoop] to damage InfiniteSlashesTarget[InfiniteSlashesLoop], dealing Damage[SpellLevel[InfiniteSlashesLoop]] damage of attack type Normal and damage type Normal


    Like i said its pointless. why use damage[1~4[index]] when u are just use damage[index].

    Set Damage[InfiniteSlashesIndex] = (50.00 x (Real((Level of Infinite Slashes for InfiniteSlashesCaster[InfiniteSlashesMui]))))

    just solve it and simple for user to configure rather use Inefficient indexing.
     
  11. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    1,100
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    Would you like to have 20 variables for a simple spell like this? It's just a waste of time creating 2 variables for model and attachment effect and saving their path to use them once. Anyway if users want to change it, they just can do easily lol, imo.
    ___________
     
    Last edited by a moderator: Dec 16, 2012
  12. Magtheridon96

    Magtheridon96

    Joined:
    Dec 12, 2008
    Messages:
    6,006
    Resources:
    26
    Maps:
    1
    Spells:
    8
    Tutorials:
    7
    JASS:
    10
    Resources:
    26
    ~8 posts deleted

    Enough is enough.

    Do not be inflammatory or spammy.
     
    Last edited: Dec 16, 2012
  13. Almia

    Almia

    Joined:
    Apr 24, 2012
    Messages:
    4,856
    Resources:
    35
    Spells:
    30
    Tutorials:
    4
    JASS:
    1
    Resources:
    35
    congratulations for the approved spell
     
  14. iChaos

    iChaos

    Joined:
    May 4, 2012
    Messages:
    167
    Resources:
    0
    Resources:
    0
    wow nice, i learned something from this spell xD