HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Need Some Help (Triggered Stun)

06-24-2008, 06:16 PM#1
chobibo
Hello guys!, I just want to know if there is a function that orders a unit to be stunned, something like PauseUnit, but does not remove the command card.

I tried making a stun system which used PauseUnit, but it removes the command card, which doesn't feel right. I also tried ordering using a custom storm bolt with 0 duration, but it won't target Magic Immune units. The last thing I tried was to make a periodic timer order a unit to stop, this looks natural for wc3 but it uses a timer that runs at .02 secs, if I set it higher, the unit can move sometimes. I also tried using bash, but it's overcomplicated for me.

I don't intend to make a spell or anything, just practicing scripting so I wouldn't need pre-made systems, just options/alternatives. Thanks guys!
06-24-2008, 06:32 PM#2
the-thingy
Whenever the target is issued an order of any kind (targeting point, object, or no target), forcibly order them to stop? That'd probably be the simplest way of dealing with it
06-24-2008, 06:35 PM#3
chobibo
I tried that, It doesn't stun the unit, it will just make them ignore user-issued orders. If there's an enemy nearby they will still engage the enemy. In short, that would just make it ignore the human user issued orders.
06-24-2008, 07:14 PM#4
the-thingy
What about adding something like Slow Aura (Tornado) with a -100% slow effect (and minimum speed at 0 in Gameplay Constants), and set the target's turn speed to 0, along with Silence (or Begins Casting An Ability -> Order Unit to Stop)
06-24-2008, 07:20 PM#5
Anitarf
Quote:
Originally Posted by chobibo
I tried making a stun system which used PauseUnit, but it removes the command card, which doesn't feel right. I also tried ordering using a custom storm bolt with 0 duration, but it won't target Magic Immune units. The last thing I tried was to make a periodic timer order a unit to stop, this looks natural for wc3 but it uses a timer that runs at .02 secs, if I set it higher, the unit can move sometimes. I also tried using bash, but it's overcomplicated for me.
What do you mean overcomplicated, it's no more complicated than ordering a dummy caster to cast a storm bolt.

One thing worth trying is making the storm bolt a hero ability and making the required level for the spell above 1. That makes the game engine consider it an ultimate, and ultimates can affect magic immune units.
06-24-2008, 07:37 PM#6
chobibo
I mean bash, I need to consider things such as; when the attack will hit and other stuff lol, Simply put: I'm lazy lol.
Oh and thanks for telling me about the storm bolt thing, I didn't know that. If PauseUnit was unoticable then I would have prefered to use it. Thanks Anitarf!
06-24-2008, 07:56 PM#7
Themerion
Quote:
Originally Posted by Anitarf
One thing worth trying is making the storm bolt a hero ability and making the required level for the spell above 1. That makes the game engine consider it an ultimate, and ultimates can affect magic immune units.

Well, what would happen if another storm bolt hit the unit?

Wouldn't remained paused for the duration of that storm bolt, then become free again?

PauseUnit is evil. It also pauses buff durations (meaning that if you have a triggered spell checking for the buff, it might last muuuuuuch longer than expected)

Hidden information:
I will NEVER forgive Blizzard for not detecting that bug for Funny Bunny's Egg Hunt! Some bastard cast Shadow Egg Strike on me just before a mini-game. I bled well over 200 eggs!
06-24-2008, 09:11 PM#8
Feroc1ty
Just make a dummy unit that casts a harmless 0.1 stun storm bolt that has no model and is instant, and make a timer keep doing it until the time is up.
06-24-2008, 09:28 PM#9
the-thingy
That won't bypass magic immunity though

Quote:
I also tried ordering using a custom storm bolt with 0 duration, but it won't target Magic Immune units
06-24-2008, 09:50 PM#10
Themerion
Quote:
Originally Posted by Jokes-On_You
Just make a dummy unit that casts a harmless 0.1 stun storm bolt that has no model and is instant, and make a timer keep doing it until the time is up.

Quote:
Originally Posted by the-thingy
That won't bypass magic immunity though

Quote:
Originally Posted by Anitarf
One thing worth trying is making the storm bolt a hero ability and making the required level for the spell above 1. That makes the game engine consider it an ultimate, and ultimates can affect magic immune units.

EDIT: Just made a quick test to confirm. The target unit will be affected by the stun, but not by the damage (which is, precisely what we wanted, aye? :)

It will not work if the target is completely invulnerable though (even if you set targets allowed to invulnerable, the storm bolt will not make any effect at the unit). Perhaps PauseUnit is best for invulnerable units.