• 🏆 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] War3 crashes - what to look for?

Status
Not open for further replies.
Level 4
Joined
Feb 5, 2005
Messages
38
hi guys

I'm writing an ai for a very old risk map (completely triggered). Now I added a lot of new triggers and many of them start each other (trigger run x (ignoring conditions)) and i use a lot of arrays. the code is quite complex so i didn't had the time to look through everything atm.

However if i try to run the map the game crashes with a memory alloc error (read error). Can anybody tell me, what i should look for in my code? array crap? trigger run? something different? i really don't have the slightiest idea where to look at.

otherwise i will start adding text output to see how far my triggers reach until it crashes :ugly:

thanks in advance, regards,

blackcud
 
Level 18
Joined
Aug 23, 2008
Messages
2,319
With a lot of triggers activating eachother, it's pretty much possible you made a circle of triggers activating eachother.

trigger 1 ===> trigger 2
. . /\ . . . . . . . . || . . .
. . || . . . . . . . . || . . .
. . || . . . . . . . . \/ . . .
trigger 3 ===> trigger 4

This causes all 4 to be triggers infinitely, causing leaks. You must avoid infinitely running triggers, so make sure there are no such stuff as the 'image' above. Read the 'Things that Leak' thread (The sticky one in Triggers & Scripts) to see how to check for leaks and how to prevent them.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
Impropper use of JASS, like the return bug can cause crashes. Issuing orders improperly can cause crashes (like moving to the units exact location). Some infinate loops can cause crashes. Also moving too many units in to hard to path areas is known to cause crashes. Destroying triggers to often has been known to cause a handle allocation error resulting in a crash, avoid doing it unnescescarily.
 
Level 6
Joined
Jun 14, 2008
Messages
176
Impropper use of JASS, like the return bug can cause crashes. Issuing orders improperly can cause crashes (like moving to the units exact location). Some infinate loops can cause crashes. Also moving too many units in to hard to path areas is known to cause crashes. Destroying triggers to often has been known to cause a handle allocation error resulting in a crash, avoid doing it unnescescarily.

Hmm, you know if there is a list of known possible crashes for WC3?

If not, we should really make a list and sticky it or something.

I know about a couple of odd things that may cause WC3 to crash, we should make a list of them in a topic or something if there isn't already a list somewhere.
 
Status
Not open for further replies.
Top