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

[Trigger] Buff Disables Movement?

Status
Not open for further replies.
Level 4
Joined
Jan 27, 2008
Messages
72
For some reason, one of the abilities I made renders the target unit immobile.

The ability is basically just a mana burn which curses a unit, making it explode 7 seconds after having its mana drained. The problem is that the affected unit cannot move for 7 seconds. How would I fix this?

  • QTheft Mana Drain
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Quintessence Theft
    • Actions
      • Unit - Create 1 Shards of Ice Dummy for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing Default building facing degrees
      • Unit - Set level of QTheft Mana Burn for (Last created unit) to (Level of Quintessence Theft for (Triggering unit))
      • Unit - Order (Last created unit) to Night Elf Demon Hunter - Mana Burn (Target unit of ability being cast)
      • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
  • QTheft Explosion
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Quintessence Theft
    • Actions
      • Set Target = (Target unit of ability being cast)
      • Wait 7.00 seconds
      • Unit - Create 1 Shards of Ice Dummy for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing Default building facing degrees
      • Unit - Set level of QTheft Explosion for (Last created unit) to (Level of Quintessence Theft for (Triggering unit))
      • Unit - Order (Last created unit) to Undead Lich - Frost Nova Target
      • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
 
Level 4
Joined
Jan 27, 2008
Messages
72
Oh, stupid mistake.

The affected unit is immobile because the ability of the casting unit was based off of storm bolt.

>.>

And yes, I'll take care of the leaks, thanks.
 
Level 20
Joined
Jun 27, 2011
Messages
1,864
many leaks, should be taken care of. Store the points into the variable, use it and afterwards destroy.
Things that Leak

Also, the spell is not MUI (the variable will get overwritten if anoth unit casts it)
MUI spells with waits

For the movement, I have no idea why is unit immobile....

You forgot to tell him to cache/store those function calls (Those who have brackets, ex. (Triggering Unit), (Last created unit), etc.) into a variable for better efficiency.
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
  • QTheft Explosion
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Quintessence Theft
    • Actions
      • Custom script: local unit udg_Target
      • Set Target = (Target unit of ability being cast)
      • Wait 7.00 seconds
      • Unit - Create 1 Shards of Ice Dummy for (Owner of (Triggering unit)) at (Position of (Triggering unit)) facing Default building facing degrees
      • Unit - Set level of QTheft Explosion for (Last created unit) to (Level of Quintessence Theft for (Triggering unit))
      • Unit - Order (Last created unit) to Undead Lich - Frost Nova Target
      • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
      • Custom script: set udg_Target = null
this is MUI now.
although check out my tutorial about waits and there inaccuracy.
 
Status
Not open for further replies.
Top