• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[Spell] Rapid Slashes via Trigger?

Status
Not open for further replies.
Level 2
Joined
Apr 25, 2015
Messages
11
Hi again. I'd like to do an trigger were my hero (sword hero) uses an ability, and a trigger orders this unit to rapidly slash like 5+ times in front of him, dealing aoe damage in front of him. But lets skip the damage trigger (you can still give me some advice)

How do animate my unit fast enough to fully perfom all slashes. Think of it like in DotA when you activate Omnislash but in place. When I create the animation triggers in rapid succession it is only halfway done when starting the next animation (i put in a 0.2sec delay)

E:Add info: It is an imported unit model, the Vrykul thane model, if that is any help. (Because omnislash is done with the standart orc blademaster)

Greatly appreaciated IF there is a solution, that it is done in GUI. Just starting to work on the WE again after good 7 years, so JASS is still too difficult for me (although i know SOME java)

Thanks!
 

Chaosy

Tutorial Reviewer
Level 40
Joined
Jun 9, 2011
Messages
13,183
You could do something like:

base spell on "Channel" set animation to attack

and when "Channel" is cast set animation speed to 300% or something.

Pick every unit in X of caster

(in a loop)
check if angle between points >= facing of caster - 45 or angle between points <= facing of caster + 45
deal damage to picked unit
 
Level 2
Joined
Apr 25, 2015
Messages
11
Does the unit continue to attack as long as it is channeling? Or do i need to overlap the channel animations somehow?

Thank you already, will try tomorrow.
 
Level 2
Joined
Apr 25, 2015
Messages
11
Now I did some testing, and with help from this thread http://www.hiveworkshop.com/forums/triggers-scripts-269/picking-all-units-front-another-unit-195945/

I worked out this trigger, animations worked fine but after I tried to implement the damage section it broke the animation.

  • Ereignisse
    • Einheit - A unit Beginnt, eine Fähigkeit zu kanalisieren
  • Bedingungen
    • (Ability being cast) Gleich slashy
  • Aktionen
    • Set TreshVAR = (Triggering unit)
    • Set ThreshLOC1 = (Position of (Triggering unit))
    • Animation - Change TreshVAR's animation speed to 400.00% of its original speed
    • Custom script: set bj_wantDestroyGroup = true
    • Set ThousBLADEGroup = (Units within 300.00 of ThreshLOC1)
    • Einheitengruppe - Pick every unit in ThousBLADEGroup and do (Actions)
      • Schleifen - Aktionen
        • Set ThreshLOC2 = (Position of (Picked unit))
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • 'IF'-Bedingungen
            • (Acos((Cos(((Facing of (Triggering unit)) - (Angle from ThreshLOC1 to ThreshLOC2)))))) greater than equal to 0.76
          • 'THEN'-Aktionen
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
            • Wait 0.02 seconds
            • Animation - Play TreshVAR's attack animation
            • Einheit - Cause TreshVAR to damage (Picked unit), dealing 10.00 damage of attack type Normal and damage type Normal
          • 'ELSE'-Aktionen
    • Wait 1.00 seconds
    • Custom script: call DestroyGroup(udg_ThousBLADEGroup)
    • Custom script: call RemoveLocation(udg_ThreshLOC1)
    • Custom script: call RemoveLocation(udg_ThreshLOC2)
    • Animation - Reset TreshVAR's animation
    • Animation - Change TreshVAR's animation speed to 100.00% of its original speed
Sadly it is in german but you should be able to understand most of it.

What happens is that ALL units are selected in the 300AOE at the point of the triggering unit, and all receive damage not just the units in the cone, also it'll only start the 1rst damage trigger.

Id like to accomplis a multislashing attack in a 45° cone in front of my unit dealing X damage multiple times.


Can anyone spot the mistakes?
 
Last edited:
Status
Not open for further replies.
Top