• 🏆 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] Mass entangle type spell not working

Status
Not open for further replies.
Level 7
Joined
Jan 11, 2022
Messages
108
I'm working on a mass entangling type spell, StrangleHand should basically root multiple enemies (just like mass entangle but with different model that I've already put in the spell StrangleHand). For some reason it doesn't show the AoE effect, i can only select one enemy and it doesnt even work. It just roots the target and does it repetitively for couple second and then leaves simple root from Entangling Roots ability

  • Entangling Roots
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to StrangleHand
    • Actions
      • Set ER_AoE = 205.00
      • Set ER_Loc = (Target point of ability being cast)
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units within ER_AoE of ER_Loc matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to YES)) and do (Actions)
        • Loop - Actions
          • Unit - Create 1 DUMMY for (Owner of (Triggering unit)) at ER_Loc facing Default building facing degrees
          • Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
          • Unit - Add Roots dummy to (Last created unit)
          • Unit - Set level of Roots dummy for (Last created unit) to (Level of StrangleHand for (Triggering unit))
          • Unit - Order (Last created unit) to Night Elf Keeper Of The Grove: Entangling Roots (Picked unit)
      • Custom script: call RemoveLocation(udg_ER_Loc)
StrangleHand is the spell itself, it doesnt have damage, only the effect of the hand, cooldown and mana needed
Roots dummy is supposed to be those additional mass roots, its set to 0 mana needed, no cooldown, it has the effect of a hand, and has damage it does and time it should last for
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,564
First, I would double check the Dummy unit to see if it's setup properly. Your Dummy should be based on the Locust unit with these important changes:
Attacks Enabled = None, Movement Type = None, Speed Base = 0, Model = None, Shadow = None.

Also, note how the Locust unit's Art - Cast Point and Art - Cast Backswing are both set to 0.00. This is very important for making the unit cast spells immediately.

Now double check to make sure the Roots dummy ability is able to target units properly. You can test this by giving the ability to your Hero and seeing if you can manually cast it yourself.

Finally, let's optimize the trigger and rule out any Event Response issues by using some more variables:
  • Entangling Roots
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to StrangleHand
    • Actions
      • Set ER_AoE = 205.00
      • Set ER_Loc = (Target point of ability being cast)
      • Set ER_Group = (Units within ER_AoE of ER_Loc matching (Matching unit) belongs to an enemy of (Owner of (Triggering unit))
      • Unit - Create 1 DUMMY for (Owner of (Triggering unit)) at ER_Loc facing Default building facing degrees
      • Set ER_Dummy = (Last created unit)
      • Unit - Add a 2.00 second Generic expiration timer to ER_Dummy
      • Unit - Add Roots dummy to ER_Dummy
      • Unit - Set level of Roots dummy for ER_Dummy to (Level of StrangleHand for (Triggering unit))
      • Unit Group - Pick every unit in ER_Group and do (Actions)
        • Loop - Actions
          • Unit - Order ER_Dummy to Night Elf Keeper Of The Grove: Entangling Roots (Picked unit)
      • Custom script: call RemoveLocation(udg_ER_Loc)
      • Custom script: call DestroyGroup(udg_ER_Group)
Note how only a single Dummy unit is needed if everything is setup properly. Also, you can use the "bj_wantDestroyGroup" method instead but I would try this way first. Lastly, ER_Group could use some more filters. Currently it's adding Dead units to the Unit Group as well.

If that still doesn't work then you may be making a simple mistake somewhere like referencing the wrong Dummy unit-type or wrong ability. Maybe you have two copies of the same object or two objects with the same name and are using the wrong one.
 
Last edited:
Level 20
Joined
Aug 29, 2012
Messages
829
There's something that bugs me in this:

  • Unit Group - Pick every unit in (Units within ER_AoE of ER_Loc matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to YES)) and do (Actions)
Is "YES" a custom boolean variable of yours? I believe the default text is "True", hence my question. If that's the case, did you make sure your "yes" boolean is actually set to be true?
 
Last edited:
Level 7
Joined
Jan 11, 2022
Messages
108
There's something that bugs me in this:

  • Unit Group - Pick every unit in (Units within ER_AoE of ER_Loc matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to YES)) and do (Actions)
Is "YES" a custom boolean variable of yours? I believe the default text is "True", hence my question. If that's the case, did you make sure your "yes" boolean is actually set to be true?
It's "true" but in my language "tak" means both "yes" and "true" and honestly didn't know which one should I write down here on hiveworkshop (since I had to fix some names due to weird signs in my language like "ą, ę" that didnt display on site

First, I would double check the Dummy unit to see if it's setup properly. Your Dummy should be based on the Locust unit with these important changes:
Attacks Enabled = None, Movement Type = None, Speed Base = 0, Model = None, Shadow = None.

Also, note how the Locust unit's Art - Cast Point and Art - Cast Backswing are both set to 0.00. This is very important for making the unit cast spells immediately.

Now double check to make sure the Roots dummy ability is able to target units properly. You can test this by giving the ability to your Hero and seeing if you can manually cast it yourself.

Finally, let's optimize the trigger and rule out any Event Response issues by using some more variables:
  • Entangling Roots
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to StrangleHand
    • Actions
      • Set ER_AoE = 205.00
      • Set ER_Loc = (Target point of ability being cast)
      • Set ER_Group = (Units within ER_AoE of ER_Loc matching (Matching unit) belongs to an enemy of (Owner of (Triggering unit))
      • Unit - Create 1 DUMMY for (Owner of (Triggering unit)) at ER_Loc facing Default building facing degrees
      • Set ER_Dummy = (Last created unit)
      • Unit - Add a 2.00 second Generic expiration timer to ER_Dummy
      • Unit - Add Roots dummy to ER_Dummy
      • Unit - Set level of Roots dummy for ER_Dummy to (Level of StrangleHand for (Triggering unit))
      • Unit Group - Pick every unit in ER_Group and do (Actions)
        • Loop - Actions
          • Unit - Order ER_Dummy to Night Elf Keeper Of The Grove: Entangling Roots (Picked unit)
      • Custom script: call RemoveLocation(udg_ER_Loc)
      • Custom script: call DestroyGroup(udg_ER_Group)
Note how only a single Dummy unit is needed if everything is setup properly. Also, you can use the "bj_wantDestroyGroup" method instead but I would try this way first. Lastly, ER_Group could use some more filters. Currently it's adding Dead units to the Unit Group as well.

If that still doesn't work then you may be making a simple mistake somewhere like referencing the wrong Dummy unit-type or wrong ability. Maybe you have two copies of the same object or two objects with the same name and are using the wrong one.
I will try to make these adjustments right now and see if that works, thank you for that!
 
Level 7
Joined
Jan 11, 2022
Messages
108
First, I would double check the Dummy unit to see if it's setup properly. Your Dummy should be based on the Locust unit with these important changes:
Attacks Enabled = None, Movement Type = None, Speed Base = 0, Model = None, Shadow = None.

Also, note how the Locust unit's Art - Cast Point and Art - Cast Backswing are both set to 0.00. This is very important for making the unit cast spells immediately.

Now double check to make sure the Roots dummy ability is able to target units properly. You can test this by giving the ability to your Hero and seeing if you can manually cast it yourself.

Finally, let's optimize the trigger and rule out any Event Response issues by using some more variables:
  • Entangling Roots
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to StrangleHand
    • Actions
      • Set ER_AoE = 205.00
      • Set ER_Loc = (Target point of ability being cast)
      • Set ER_Group = (Units within ER_AoE of ER_Loc matching (Matching unit) belongs to an enemy of (Owner of (Triggering unit))
      • Unit - Create 1 DUMMY for (Owner of (Triggering unit)) at ER_Loc facing Default building facing degrees
      • Set ER_Dummy = (Last created unit)
      • Unit - Add a 2.00 second Generic expiration timer to ER_Dummy
      • Unit - Add Roots dummy to ER_Dummy
      • Unit - Set level of Roots dummy for ER_Dummy to (Level of StrangleHand for (Triggering unit))
      • Unit Group - Pick every unit in ER_Group and do (Actions)
        • Loop - Actions
          • Unit - Order ER_Dummy to Night Elf Keeper Of The Grove: Entangling Roots (Picked unit)
      • Custom script: call RemoveLocation(udg_ER_Loc)
      • Custom script: call DestroyGroup(udg_ER_Group)
Note how only a single Dummy unit is needed if everything is setup properly. Also, you can use the "bj_wantDestroyGroup" method instead but I would try this way first. Lastly, ER_Group could use some more filters. Currently it's adding Dead units to the Unit Group as well.

If that still doesn't work then you may be making a simple mistake somewhere like referencing the wrong Dummy unit-type or wrong ability. Maybe you have two copies of the same object or two objects with the same name and are using the wrong one.
So it seems to kind of work now, but I have hard time setting
(Units within ER_AoE of ER_Loc matching (Matching unit) belongs to an enemy of (Owner of (Triggering unit))
I can't set the condition to "belongs to..." i only have "Equal to". I don't know how important is setting that instead of Just "Units Withing ER_AoE of ER_Loc" but that may be the case it doesnt work. I also noticed that I didn't set StrangleHand with the base of blizzard or other AoE spell and I was wondering why I only can target one unit instead of Area. So far I can put the Area but it only Strangles one unit


Edit: I found that feature and it still grabs just one unit
 
Last edited:
Level 20
Joined
Feb 27, 2019
Messages
592
If StrangleHand is based on Entangling Roots its a single target ability opposed to a point target ability so there is no target point to be retrieved.

In order to show an AoE Image when clicking on the spell you need to create a Dummy ability based on an AoE ability such as Silence or a correctly configured "Channel". The dummy ability will not do anything but display all information about the spell for the player and show an AoE Image when clicking the spell while your trigger will take care of what happens when the spell has been cast. https://world-editor-tutorials.thehelper.net/cat_usersubmit.php?view=44234
"20. Channel

AbilityId : ANcl

Channel is an ability made by Blizzard that works with triggers. It has a lot of options, more than your thought. This ability ever requires a trigger, because without that, it can't do something. It can also be used to trigger an effect without a trigger.

You can specify it to :
  • Target a unit
  • Target a point
  • Target an area of effect (The circle thing)
  • No Target (Instant cast)

And Spell type to :
  • Physical Spell (Go through Anti-Magic Shell, Magic Immune..)
  • Universal Spell (Go through anything)
  • Unique Cast
  • Target an Image (Determines if it Target an area of effect has an AoE Image)

The channeling time can be changed through the Follow Through Time, and the icon is disabled in option. The effect you want to the ability Channel must be triggered.

Also, the orderId of the spell can be modified."
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,564
So it seems to kind of work now, but I have hard time setting

I can't set the condition to "belongs to..." i only have "Equal to". I don't know how important is setting that instead of Just "Units Withing ER_AoE of ER_Loc" but that may be the case it doesnt work. I also noticed that I didn't set StrangleHand with the base of blizzard or other AoE spell and I was wondering why I only can target one unit instead of Area. So far I can put the Area but it only Strangles one unit


Edit: I found that feature and it still grabs just one unit
Abilities either target Nothing, a Unit, or a Point and the Event Responses available to use depend on this.

So there is no (Target point of ability being cast) without a Point being targeted. If StrangleHand is a Unit targeting ability then simply set ER_Loc to the (Position of (Target unit of ability being cast)). If StrangleHand targets Nothing then set ER_Loc to the (Position of (Triggering unit)).
 
Last edited:
Level 7
Joined
Jan 11, 2022
Messages
108
I found a way around it, now it grabs multiple enemies. Base of the spell is set to blizzard. But got one more question since I'm still new into triggers. How do I set the level of the spell? Because I think it will just cast level 1 of the stranglehand. I USED DIFFERENT VARIABLES because I copied this trigger from my other abillity that works and changed couple things

  • Strangle
    • Events
      • Unit - Kostucha 0881 <gen> Starts the effect of an abillity
    • Conditions
      • (Ability being cast) Equal to StrangleHold (dummy)
    • Actions
      • Set PD_Temppoint = (Target point of ability being cast)
      • Set PD_caster = (Casting unit)
      • Group Unit - Pick every unit in (Units within 400.00 of PD_Temppoint) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Owner of (Picked unit)) is an enemy of (Owner of PD_caster)) Equal to True
            • Then - Actions
              • Unit - Create 1 dummy strangle for (Owner of PD_caster) at PD_Temppoint facing default building facing degrees
              • Unit - Order (Last created unit) to Night Elf Keeper Of the Grove (Picked unit)
              • Unit - Make (Last created unit) Niezniszczalny
              • Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
            • Or - Actions
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,564
My method will work just fine if you use Blizzard as the base spell so there's no reason to do all of that. Even your first trigger you posted in this thread will work fine. The only issue I can see was that your base spell didn't target a Point so there was no (Target point of ability being cast). That's why it wasn't working.

And I don't really understand your question because you were already doing this in your first trigger.
You Set the level of the ability the same way you were already doing it, with the Set Level of Ability action:
  • Unit - Set level of Roots dummy for (Last created unit) to (Level of StrangleHand for (Triggering unit))
(Triggering unit) and (Casting unit) are the same thing in this trigger so use whichever one you want. Or use the variable that's been set to the caster.

If that still somehow fails then the issue lies with your Dummy unit and/or your Dummy ability.

The Dummy unit should be based on the Locust unit (copy and paste it), with the changes I suggested. Then make sure the spell the Dummy casts has 999999 cast range, 0 cooldown, and 0 mana cost.
 
Last edited:
Level 7
Joined
Jan 11, 2022
Messages
108
My method will work just fine if you use Blizzard as the base spell so there's no reason to do all of that. Even your first trigger you posted in this thread will work fine. The only issue I can see was that your base spell didn't target a Point so there was no (Target point of ability being cast). That's why it wasn't working.

And I don't really understand your question because you were already doing this in your first trigger.
You Set the level of the ability the same way you were already doing it, with the Set Level of Ability action:
  • Unit - Set level of Roots dummy for (Last created unit) to (Level of StrangleHand for (Triggering unit))
(Triggering unit) and (Casting unit) are the same thing in this trigger so use whichever one you want. Or use the variable that's been set to the caster.

If that still somehow fails then the issue lies with your Dummy unit and/or your Dummy ability.

The Dummy unit should be based on the Locust unit (copy and paste it), with the changes I suggested. Then make sure the spell the Dummy casts has 999999 cast range, 0 cooldown, and 0 mana cost.
I used Blizzard as the base spell and for some reason it just targeted one unit. I am using the same Blizzard base in this second trigger and it's working fine so I think it's something wrong with Dummy ability.

And yeah silly me, I didn't even notice i've already done that level setup in the first trigger. Idk how I forgot how to do it. I'ma try it now and see if that works

Edit: Tested now and everything works smoothly, thank y'all!
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,564
If you followed my method and it only targeted one unit then the Dummy and/or the ability wasn't setup properly. If not that then it'd be something weird like an issue with your version of Warcraft 3 (I can see by your triggers that you're on an older patch) or something weird like that.

If you want to you could attach the map here or maybe a demo map if you're more comfortable with that and I could tell you exactly what's wrong.

But if you don't feel like doing that I would understand. I just wanted to get the point across that a single Dummy unit is all that should ever be needed. There's a lot of misinformation on this topic or at the very least outdated info which tells otherwise and leads people to making inefficient triggers with tons of unnecessary Dummy units.
 
Level 7
Joined
Jan 11, 2022
Messages
108
If you followed my method and it only targeted one unit then the Dummy and/or the ability wasn't setup properly. If not that then it'd be something weird like an issue with your version of Warcraft 3 (I can see by your triggers that you're on an older patch) or something weird like that.

If you want to you could attach the map here or maybe a demo map if you're more comfortable with that and I could tell you exactly what's wrong.

But if you don't feel like doing that I would understand. I just wanted to get the point across that a single Dummy unit is all that should ever be needed. There's a lot of misinformation on this topic or at the very least outdated info which tells otherwise and leads people to making inefficient triggers with tons of unnecessary Dummy units.
I think I followed all of those, so it has to be something with Dummies, I created quickly a demo map just for that spell. I'd be cool if you find a fix for that so others and me myself can learn from that (even though I found a way around, it'll be nice to know the other way)
 

Attachments

  • demo map.w3x
    72.5 KB · Views: 3

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,564
Your Roots dummy ability has a 15 second cooldown and 800 cast range. The cd needs to be 0 and cast range should be 99999.

The Dummy unit has an Unknown ability, assumedly a working ability that got messed up during the map transferring process. Regardless, it shouldn't have any ability besides Locust since we're adding the Entangling Roots ability to it via triggers.

I've tested the map with these fixes and it works great.

Also, make sure that the Area of Effect of the trigger matches the Area of Effect of the Blizzard ability.
 
Level 7
Joined
Jan 11, 2022
Messages
108
Your Roots dummy ability has a 15 second cooldown and 800 cast range. The cd needs to be 0 and cast range should be 99999.

The Dummy unit has an Unknown ability, assumedly a working ability that got messed up during the map transferring process. Regardless, it shouldn't have any ability besides Locust since we're adding the Entangling Roots ability to it via triggers.

I've tested the map with these fixes and it works great.

Also, make sure that the Area of Effect of the trigger matches the Area of Effect of the Blizzard ability.
With these fixes all works perfectly, I too noticed that AoE data of the trigger isn't the same as in blizzard so changed that. Have to remember now to set up Dummies properly, Thank you so much!
 
Status
Not open for further replies.
Top