• 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.

Game Freezes

Status
Not open for further replies.
Level 20
Joined
Jun 27, 2011
Messages
1,864
I don't know, but this trigger keeps freezing the game whenever a unit enters the triggering region.

  • Grass Trim
    • Events
      • Time - Every 0.03 seconds of game time
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units in Grass Trim <gen>) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has buff Slow (Grass Trim)) Equal to False
            • Then - Actions
              • Set Temp_Point = (Center of (Playable map area))
              • Unit - Create 1 Dummy for Neutral Hostile at Temp_Point facing Default building facing degrees
              • Unit - Add a 0.05 second Generic expiration timer to (Last created unit)
              • Unit - Add Slow to (Last created unit)
              • Unit - Order (Last created unit) to Human Sorceress - Slow (Picked unit)
              • Custom script: call RemoveLocation( udg_Temp_Point )
            • Else - Actions
 

TKF

TKF

Level 19
Joined
Nov 29, 2006
Messages
1,267
I cannot see why this should cause the game to freeze.


But I do it like this. I'm not sure this will solve the issue. If not, its something else that causes the game to freeze.

  • Set Temp_Group = (Units in Grass Trim <gen>)
  • Unit Group - Pick every unit in Temp_Group and do (Actions)
  • ...
  • your triggers...
  • ...
  • Custom script: call DestroyGroup(udg_Temp_Group)
 
Level 20
Joined
Jun 27, 2011
Messages
1,864
Is your dummy movement type none and all animation cast points 0?
If it has movement type, it needs to face the unit it is trying to cast, which will take up to ~0.3 seconds.
I can imagine if the dummy isn't casting the slow buff in time, the trigger continues to spawn dummies every 0.03 seconds?

Yes, the dummy unit's movement type is none and all animation cast points are set to 0.
 
Level 16
Joined
Mar 27, 2011
Messages
1,349
Are there any other triggers such as:

A unit enters the map, or anything, which could conflict with this trigger?
Just check your other triggers to see if they are accidently fired.
Thats all I can think of, the trigger itself seems ok.
 
Level 37
Joined
Mar 6, 2006
Messages
9,243
It could be an infinite loop.

Unit enters region -> create dummy -> triggers unit enters region -> creates dummy -> triggers unit enters region...

If that is the case, turn off the trigger before creating the dummy and then turn it on after the unit is created. Also make sure the Animation - cast point of the dummy is 0.
 
Last edited:
Status
Not open for further replies.
Top