| 08-16-2007, 09:47 PM | #1 |
I probably played my map a thousand times and made so many changes over the course of 41 versions. One of the newest, yet strangest bug has boggled me after adding vehicles (very very light on triggers) to my map. The event "Map Initialization" no longer works. Some of my periodic triggers no longer work, when when combined or separated. They have no conditions whatsoever. I have about 132 triggers and 134 variables. My mapsize is 1000kb. Size is mostly due to imports. Has anyone ever heard of this happening before? Does anyone know how to fix it? |
| 08-16-2007, 09:54 PM | #2 |
Your map initialization is too big. You will have to make some of your triggers that use "On Map Init" event to use "after 5 game seconds" event to solve that. |
| 08-16-2007, 09:59 PM | #3 |
I also found out that if you have global arrays that are to big (like 5 8191 size arrays), your map will hit the op limit at the start. |
| 08-16-2007, 10:00 PM | #4 | |
Quote:
|
| 08-16-2007, 10:27 PM | #5 |
Yeah but they are better than crashing :P |
| 08-16-2007, 10:33 PM | #6 |
Not necessarily. ChaosWolfs: Which map is it? (name) |
| 08-16-2007, 10:37 PM | #7 |
Why not like 1 second instead of 5? Or 2 if its too much code |
| 08-16-2007, 10:48 PM | #8 |
Or maybe using ExecuteFunc :P |
| 08-16-2007, 10:50 PM | #9 |
The latest version (V41t) of my map (Defend the Bunker) is not really out in the public. Yes - I have solved the map initialization problem by setting every trigger to happen one second after the map is started. Although, I am disappointed that I now have a second lag/delay as soon as the map starts. No - My highest array is probably 100 or 1000. But - All of your answers did not say anything about why all of the sudden it does not work. I want to know why the event "Map Initialization" will not work and what I can do to make it work again. I also have some periodic triggers such as (Every 1 seconds) not working. These periodic triggers have NO conditions and for some reason, not all of them will run. Also - I have plans to revert from V40t and redo all the changes in an attempt to avoid or see what is causing the event (and a few others) to not work. I DO NOT want to do this due to the amount of changes I have made, but If I have to, I will. And - Thanks for all the responses, but none of them really helps me solve the error. I have triggers that have been working since Day 01 and now of the sudden, it is no longer working. They don't interfere with anything else and I have tracked it down to the map initialization. And it isn't just map initialization that is having problems, I have triggers that refuse to run, even without conditions. |
| 08-16-2007, 10:56 PM | #10 |
I think that an event can have a maximum number of events and after those maximum it stops to work. Same with time event? |
| 08-16-2007, 11:04 PM | #11 |
Periodic Triggers that are not working are probably dependant on some initialization triggers (they use data from them) And if data is invalid some triggers will simply stop. Make sure your initialization is ordered properly. I prefer to have only one Map initialization trigger and then call other triggers from it, that way I am sure what goes first. You can extend that to 1 second triggers as well |
| 08-16-2007, 11:29 PM | #13 |
use Game time collapsed 0 seconds... this is useful since it happens instantly. The Map init is just for waiting longer during loading screen |
| 08-17-2007, 12:47 AM | #14 |
x.x Wow. This latest version did more damage to the triggers than I thought. Boss Trigger: ![]() Conditions![]() Actions![]() ![]() If (All Conditions are True) then do (Then Actions) else do (Else Actions)![]() ![]() ![]() Then - Actions![]() ![]() ![]() ![]() Unit - Create 1 EnemyBoss[CurrentLevel] for Player 12 (Brown) at (Random point in Spawning Area <gen>) facing Default building facing (270.0) degrees![]() ![]() ![]() ![]() Set CurrentBoss = (Last created unit)![]() ![]() ![]() ![]() Unit - Order CurrentBoss to Attack-Move To (Random point in Checkpoint 01 <gen>)![]() ![]() ![]() ![]() Sound - Stop music Immediately![]() ![]() ![]() ![]() Sound - Play BossMusic <gen>![]() ![]() Wait until ((CurrentBoss is alive) Equal to False), checking every 1.00 seconds![]() ![]() Set Difficulty = (Difficulty + 1)![]() ![]() Set BonusGold = (50 x CurrentLevel)![]() ![]() Game - Display to (All players) the text: (Players will recieve + ((String(BonusGold)) + gold for killing the boss.))![]() ![]() Countdown Timer - Hide TimerBossWindow![]() ![]() Sound - Resume music![]() ![]() Sound - Stop BossMusic <gen> After fading![]() ![]() Trigger - Run Resupply <gen> (ignoring conditions)Resupply Trigger: ![]() Events![]() Conditions![]() Actions![]() ![]() Custom script: call DebugMsg("Resupply: Run")![]() ![]() Trigger - Run Power Gen Stocks <gen> (ignoring conditions)![]() ![]() For each (Integer PowerGen_Counter) from 0 to 33, do (Actions)![]() ![]() ![]() Loop - Actions![]() ![]() ![]() ![]() If (All Conditions are True) then do (Then Actions) else do (Else Actions)![]() ![]() ![]() ![]() ![]() If - Conditions![]() ![]() ![]() ![]() ![]() ![]() PowerGen_Counter Greater than or equal to 0![]() ![]() ![]() ![]() ![]() ![]() PowerGen_Counter Less than or equal to 10![]() ![]() ![]() ![]() ![]() Then - Actions![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Remove PowerGen_Units[PowerGen_Counter] from PowerGen[1]![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Remove PowerGen_Items[PowerGen_Counter] from PowerGen[1]![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Add PowerGen_Units[PowerGen_Counter] to PowerGen[1] with PowerGen_Stocks[PowerGen_Counter] in stock and a max stock of 1000000000![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Add PowerGen_Items[PowerGen_Counter] to PowerGen[1] with PowerGen_Stocks[PowerGen_Counter] in stock and a max stock of 1000000000![]() ![]() ![]() ![]() ![]() Else - Actions![]() ![]() ![]() ![]() If (All Conditions are True) then do (Then Actions) else do (Else Actions)![]() ![]() ![]() ![]() ![]() If - Conditions![]() ![]() ![]() ![]() ![]() ![]() PowerGen_Counter Greater than or equal to 11![]() ![]() ![]() ![]() ![]() ![]() PowerGen_Counter Less than or equal to 22![]() ![]() ![]() ![]() ![]() Then - Actions![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Remove PowerGen_Items[PowerGen_Counter] from PowerGen[2]![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Remove PowerGen_Units[PowerGen_Counter] from PowerGen[2]![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Add PowerGen_Items[PowerGen_Counter] to PowerGen[2] with PowerGen_Stocks[PowerGen_Counter] in stock and a max stock of 1000000000![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Add PowerGen_Units[PowerGen_Counter] to PowerGen[2] with PowerGen_Stocks[PowerGen_Counter] in stock and a max stock of 1000000000![]() ![]() ![]() ![]() ![]() Else - Actions![]() ![]() ![]() ![]() If (All Conditions are True) then do (Then Actions) else do (Else Actions)![]() ![]() ![]() ![]() ![]() If - Conditions![]() ![]() ![]() ![]() ![]() ![]() PowerGen_Counter Greater than or equal to 23![]() ![]() ![]() ![]() ![]() ![]() PowerGen_Counter Less than or equal to 34![]() ![]() ![]() ![]() ![]() Then - Actions![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Remove PowerGen_Items[PowerGen_Counter] from PowerGen[3]![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Remove PowerGen_Units[PowerGen_Counter] from PowerGen[3]![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Add PowerGen_Items[PowerGen_Counter] to PowerGen[3] with PowerGen_Stocks[PowerGen_Counter] in stock and a max stock of 1000000000![]() ![]() ![]() ![]() ![]() ![]() Neutral Building - Add PowerGen_Units[PowerGen_Counter] to PowerGen[3] with PowerGen_Stocks[PowerGen_Counter] in stock and a max stock of 1000000000![]() ![]() ![]() ![]() ![]() Else - Actions![]() ![]() Game - Display to (All players) the text: USS Command: Bunker...![]() ![]() For each (Integer A) from 2 to 8, do (Actions)![]() ![]() ![]() Loop - Actions![]() ![]() ![]() ![]() If (All Conditions are True) then do (Then Actions) else do (Else Actions)![]() ![]() ![]() ![]() ![]() Then - Actions![]() ![]() ![]() ![]() ![]() ![]() Unit - Move Hero_Dead_Save[(Integer A)] instantly to (Center of gg_rct_Middle)![]() ![]() ![]() ![]() ![]() ![]() Animation - Play Hero_Dead_Save[(Integer A)]'s stand animation![]() ![]() ![]() ![]() ![]() ![]() Unit - Unpause Hero_Dead_Save[(Integer A)]![]() ![]() ![]() ![]() ![]() ![]() Unit - Remove Invulnerable (Neutral) from Hero_Dead_Save[(Integer A)]![]() ![]() ![]() ![]() ![]() ![]() Unit - Set life of Hero_Dead_Save[(Integer A)] to 100.00%![]() ![]() ![]() ![]() ![]() ![]() Set Hero_Dead[(Integer A)] = False![]() ![]() ![]() ![]() ![]() Else - Actions![]() ![]() Trigger - Run Next Level <gen> (ignoring conditions)Resupply won't run. Its been running B4 V041. Now it doesn't even start. EDIT: Literally, everything was right. It is the weirdest bug. I just delete the "Run" trigger and added it back in. It works now. It was a WE Editor bug. |
