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

[General] War Stomp lag issue

Status
Not open for further replies.
Level 10
Joined
Sep 25, 2013
Messages
521
I created a unit that has a 15% chance when attacking to war stomp. When the 15% chance occurs, a trigger creates a dummy unit at the point of the attacking unit and casts war stomp and then expires from an expiration timer. The problem is that war stomp seems to generate a lot of lag and stutters, especially when there are several of these units. Is there a way i can create a similar effect without the lag? Thanks!
 

sentrywiz

S

sentrywiz

I created a unit that has a 15% chance when attacking to war stomp. When the 15% chance occurs, a trigger creates a dummy unit at the point of the attacking unit and casts war stomp and then expires from an expiration timer. The problem is that war stomp seems to generate a lot of lag and stutters, especially when there are several of these units. Is there a way i can create a similar effect without the lag? Thanks!

  • change the War Stomp terrain deformations to normal. I think this is what causes your lag, especially if you modify it to 0.00 then I think that is infinite terrain deformations and it just stacks until your map becomes unplayable or it crashes
  • create a dummy firebolt / storm bolt spell. Then create as many dummy units as there are units around the area of the attacking unit and cause each of them to hit a picked unit.
  • instead of the above, you can create dummy units with attack type "Instant" and add a 100% Bash chance. Modify their attackspeed to 2.00 for example and give them expiration time 1 second, so they will expire before attacking again. Or you can just give the order "Attack Once"
 
Level 12
Joined
May 22, 2015
Messages
1,051
You can have just one unit with storm bolt and have it cast it on all the targets.

War stomp and shockwave lag the game very badly. Once you hit around 4 or 5 at the same time, it's really bad. At just around 10, the game may appear to freeze for a second. It took me a while to finally replace all my shockwaves with carrion swarm instead, but it is so much faster lol.
 

sentrywiz

S

sentrywiz

You can have just one unit with storm bolt and have it cast it on all the targets.

War stomp and shockwave lag the game very badly. Once you hit around 4 or 5 at the same time, it's really bad. At just around 10, the game may appear to freeze for a second. It took me a while to finally replace all my shockwaves with carrion swarm instead, but it is so much faster lol.

How would you have storm bolt / firebolt hit all targets from one units?
 
Level 10
Joined
Sep 25, 2013
Messages
521
change the War Stomp terrain deformations to normal. I think this is what causes your lag, especially if you modify it to 0.00 then I think that is infinite terrain deformations and it just stacks until your map becomes unplayable or

I never changed the terrain deformation data, it's set at the default level right now. What do you mean by change it to normal?

Thanks for the help btw!
 
Level 25
Joined
Sep 26, 2009
Messages
2,378
How would you have storm bolt / firebolt hit all targets from one units?
Simple. Make the spell cost no mana, have no CD and have 0 second cast time. Make a dummy unit which has "Animation - Cast point" and "Animation - Cast backswing" set to 0. Set the movement and turning speed of the dummy to 0 - this will allow the dummy to cast spells even when it is not turned towards the target (since it cannot move or turn).

Now pick all targets into unit group, create the dummy and iterate trhough the group and order the dummy to cast the stormbolt on each picked unit. If you did it correctly (and I didn't forget something), it will cast it on all targets.
With this you don't even need expiration timer on the dummy - you can remove it immediately after you're done.
 
Level 12
Joined
Jan 2, 2016
Messages
973
Simple. Make the spell cost no mana, have no CD and have 0 second cast time. Make a dummy unit which has "Animation - Cast point" and "Animation - Cast backswing" set to 0. Set the movement and turning speed of the dummy to 0 - this will allow the dummy to cast spells even when it is not turned towards the target (since it cannot move or turn)

The minimum turning rate I can give to a unit is 0,1. I tried to set it to 0 the way I set values to negative (with shift), but still didn't work.
 
Level 10
Joined
Sep 25, 2013
Messages
521
Now pick all targets into unit group, create the dummy and iterate trhough the group and order the dummy to cast the stormbolt on each picked unit. If you did it correctly (and I didn't forget something), it will cast it on all targets.
With this you don't even need expiration timer on the dummy - you can remove it immediately after you're done.

Good idea! But how do i order the dummy unit to actually cast thunder bolt on all the units in the unit group. I know you can order unit groups to do actions, but i don't know how to make a single unit do an action to every unit of a group.
 
Level 37
Joined
Jul 22, 2015
Messages
3,485
Good idea! But how do i order the dummy unit to actually cast thunder bolt on all the units in the unit group. I know you can order unit groups to do actions, but i don't know how to make a single unit do an action to every unit of a group.

Unit group functions are loops. That means it will loop X amount of times; X being the number of units selected in the group. So if you have 6 units in the unit group, the dummy will be ordered to cast the spell 6 times to each unit.
 
Level 10
Joined
Sep 25, 2013
Messages
521
Unit group functions are loops. That means it will loop X amount of times; X being the number of units selected in the group. So if you have 6 units in the unit group, the dummy will be ordered to cast the spell 6 times to each unit.

Oh wow... Thank you. You have opened my mind to all new possibilities. This whole time i've been using loops with the wrong understanding of how they really work. Well i guess that happens when you just learn everything by testing it around. Thank you, this will help my triggering greatly!
 

sentrywiz

S

sentrywiz

Simple. Make the spell cost no mana, have no CD and have 0 second cast time. Make a dummy unit which has "Animation - Cast point" and "Animation - Cast backswing" set to 0. Set the movement and turning speed of the dummy to 0 - this will allow the dummy to cast spells even when it is not turned towards the target (since it cannot move or turn).

Now pick all targets into unit group, create the dummy and iterate trhough the group and order the dummy to cast the stormbolt on each picked unit. If you did it correctly (and I didn't forget something), it will cast it on all targets.
With this you don't even need expiration timer on the dummy - you can remove it immediately after you're done.

I see. I always thought it wouldn't work because it didn't sound logically possible.

Awesome since its works. +rep
 
Status
Not open for further replies.
Top