• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Can these two triggers lag my map on multiplayer games?

Status
Not open for further replies.
Trigger 1:

Events:
Every 1 second of game.

Actions:
Create 1 unit at random point in region.
Order last created unit attack random unit in unit group.




Trigger 2:

Events:
Every 0.25 secs of game

Actions:
Move unit to position of unit.




Can these two triggers lag my map on multiplayer games?

Like everyone else said, it leaks and can cause lag overtime because of it. Leak Check is good, but for some problems, it won't work (according to some users), here is how you clear the leaks:
  • Test Trigger
  • Events:
  • Time - Every 1.00 seconds of game time
  • Conditions:
  • Actions:
  • Set RandpointRegion = (Random Point in (<Region>))
  • Unit - Create 1 <Unit> for <Player> at (RandpointRegion) facing Default Building Facing Degrees
  • //I think you have to do something like this//
  • Custom Script: set bj_wantDestroyGroup = true
  • Unit - Order (Last Created Unit) to attack (Random Unit in (Unit_Group)
  • Custom Script: call RemoveLocation( udg_RandpointRegion )
I'm not sure about the destroy group, you might have to instead clear it or something but, I'm not sure...I think you could set it in the trigger such as:
Code:
Set Unit_Group = <Whatever>
then destroy it so that it sets it every time...
Here is the next one:
  • Test Trigger 2
  • Events:
  • Time - Every 0.25 seconds of game time
  • Conditions:
  • Actions:
  • Set UnitLoc = (Position of (<Unit>))
  • Unit - Move <Unit> instantly to (UnitLoc)
  • Custom Script: call RemoveLocation( udg_UnitLoc )
I dunno if these triggers are exact or will work, but they are close enough. :grin:
I hope this helps!
 
Status
Not open for further replies.
Top