• 🏆 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!

Pausing Unit.

Status
Not open for further replies.
Level 20
Joined
Aug 13, 2013
Messages
1,696
There's alternative use of UnitPropWindow but It's only disable movement like ensnare, what do I like is pausing the units like from disabling them to attack and cast a spell, but seems pausing unit can do that, not UnitPropWindow :((
Is there any way??
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Hey jake,
how about ordering the unit you wish to pause to cast a non visible ability based on channel, with the disable abilities tag true and set the follow thru time to the duration of the pause? Couple this with setunitpropwindow so they cannot move, maybe change turnrate to 0 for a very accurate depiction of pause.

Alternatively if the unit should just stand their idle you could stun them with a 0 duration and remove the buff when they should be unpaused
 
Level 20
Joined
Aug 13, 2013
Messages
1,696
@ Malhorne

Thanks! but I don't want to show the message "miss" xD.

@pOke

Nice suggestion about stun ability ;) I'll try that xD thanks!

@Wrathion

Re:Thanks! but I don't want to show the message "miss" xD.

@WaterKnight

What do you mean :) ?

@Maker

But I want to pause a unit like it will not face the other unit and turning rate to 0.

Thanks all guys for the suggestion :D +Rep.


( It is from DotA the Chronosphere Ability by Faceless Void )
 
Re:Thanks! but I don't want to show the message "miss" xD.
Disable attacks cause temporary removal of the ability 'Aatk', hence, not allowing you to attack at all and not allowing you to miss consequentially.
( It is from DotA the Chronosphere Ability by Faceless Void )
^Poke already said it.
 
Level 26
Joined
Aug 18, 2009
Messages
4,097
@WaterKnight

What do you mean :) ?

If you use a spell effect that disables both movement and attack for example, then you can obviously only concurrently disable both, not individually, respectively you would have to build an isolated method for different cases.

Since you would not want to solve the problem anew everywhere (like creating a dummy caster for each part of code and handling it via code), you build yourself central functions you call instead and thereby gain scope-overlapping power (like if you want to switch the implementation later on).
 
Status
Not open for further replies.
Top