System Status

Weep

Godspeed to the sound of the pounding
Reaction score
401
>HAX!!

>That's incredible!

I'm just standing on the shoulders of giants, in this case... :cool:
 

Jesus4Lyf

Good Idea™
Reaction score
397
Yay. ;)

By the way, slight modification because I forgot to remove debugging messages, please redownload code. I've also changed version number to 1.1.0.
Why don't you just pause the unit, using pause safety, timer.... ..... ..... UNPause?
Because pausing sucks - if you try issuing orders to a paused unit, it doesn't register at all. If you try issuing orders to a stunned unit, it actually changes the order the unit will return to after stun. So if you're playing a game where you have one second delay, and you're running into a battle and get stunned and realise you need to get the hell out, you're screwed if the author was lazy and used Pause. ;)

So this is the ultimate way to stun a unit. Any ideas for making it work on invulnerable? I tried adding it to targets.
 

Jesus4Lyf

Good Idea™
Reaction score
397
And setting the unit's animation speed to 0%?!
LET'S SAY RANDOM IRRELEVANT THINGS IN OTHER PEOPLE'S THREADS! Yay!! :(

I was thinking I could check if the order succeeded. If it failed, remove invuln, try again. If it succeeded, don't worry.

But that may break if the stun function is called from a condition - or group enumeration, right? There's no way with natives to directly assess if a unit is invulnerable, I believe.
 

uberfoop

~=Admiral Stukov=~
Reaction score
177
I could have sworn there was an IsUnitType, maybe not.

edit:
Crap, nvm, and that wouldn't make sense anyway.

Yeah, I believe that no native way is correct.
 

Azlier

Old World Ghost
Reaction score
461
>There's no way with natives to directly assess if a unit is invulnerable, I believe.

Well, I would try issuing an order to attack the target. From two dummy units: one with a magic attack (to work on ethereal), one with a normal ranged attack (for spell immune).

If both of the issued orders return false, the target SHOULD be invulnerable. Untested, however.
 

Weep

Godspeed to the sound of the pounding
Reaction score
401
Any ideas for making it work on invulnerable?
Aerial Shackles works, with the obvious downside of requiring one dummy per target. Could be used only if the target is invulnerable.

There's no way with natives to directly assess if a unit is invulnerable, I believe.
Store its health, set its life +1, ping it for 1 damage, see if the health dropped, reset health?
[edit] OK, and add a +1 HP life modifier ability, then remove it. :p
 

Azlier

Old World Ghost
Reaction score
461
>Store its health, set its life +1, ping it for 1 damage, see if the health dropped, reset health?

That would kill a unit with 1 health point (lol), and would that actually work on ethereal?
 

Jesus4Lyf

Good Idea™
Reaction score
397
I got a better idea.

Since you can't detect if a unit is invulnerable, maybe this shouldn't stun invulnerable. Otherwise making AoE stuns becomes awfully hard. And in most circumstances, this is illogical anyway - I think this would be a con if the system hit invulnerable units, as AoE stuns is a downside and I can't imagine an upside.

Signed, sealed, delivered, it's yours. I'm happy with the system as it stands.

Any further improvements? TriggerHappy suggested naming the functions UnitAddStun/UnitRemoveStun instead of just AddStun and RemoveStun. Yes, it fits WC3 conventions better. But it's more to type. Minor issue. Opinions? As mappers, which would you prefer? What's more intuitive?
 

GetTriggerUnit-

DogEntrepreneur
Reaction score
129
I think it should be UnitAddStun/UnitRemoveStun, wc3-ish of course.

I also like ice cream with chocolate chips and strawberries.
 

Azlier

Old World Ghost
Reaction score
461
UnitAddStun is nicer, because AddStun and my TrackableAddStun function are getting confused.

In case you didn't get it, what would you stun besides units?
 

Jesus4Lyf

Good Idea™
Reaction score
397
UnitAddStun is nicer, because AddStun and my TrackableAddStun function are getting confused.

In case you didn't get it, what would you stun besides units?
My thoughts exactly.

>it should be UnitAddStun/UnitRemoveStun, wc3-ish of course.
I'm not too concerned with what it should be, more concerned with what people would prefer it to be - ease of typing and intuitiveness.

My vote would be remain the same, by the way.
 

Viikuna

No Marlo no game.
Reaction score
265
StunUnit is teh best.

and RemoveStun maybe?

I stil think you should do that struct thingy, and allow other types of buffing spells than firebolt.

JASS:
set Stun=Buff.create( STUN_ABILITY_ID,STUN_ORDER_ID)
   set Roots=Buff.create( ROOTS_ABILITY_ID,ROOTS_ORDER_ID)  
   
   //...

   call Stun.add( unit )
   // ...
   call Stun.remove( unit )
 

Kenny

Back for now.
Reaction score
202
I like AddStun() and RemoveStun(), they are intuitive and easily understandable.

One thing:

JASS:
private constant integer OID_FIREBOLT=852231


You don't use this from what I can see. :p Still using the order string in the function.

Anyways, this is mad. Exactly what is needed in stun system. I say +1 approved vote, after the above is fixed though. :)
 

Jesus4Lyf

Good Idea™
Reaction score
397
You don't use this from what I can see. :p
Epic fail. :banghead:
Thanks. :)
Anyways, this is mad. Exactly what is needed in stun system. I say +1 approved vote
:D Glad you appreciate the simple interface. Originally I tried some timed stun thing, but then I had a revelation that there was something that much better answered the requirement... :thup:

I intend not to self approve, so if another moderator would kindly check this out...
 

Weep

Godspeed to the sound of the pounding
Reaction score
401
Where's the demo map? I was going to check whether the stun ability is instant-hit (speed 0) or not.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top