The soution is too simple. I had this problem too a half year ago. The whole thing is a "block" that prevents that warcraft kill your computer. I see that you put 8192 array sizes and they are allways inneed. Array size is just good for that if you want to have all e.g. 5 or 19 (integer). It looks like in jass:
JASS:
set i = 0
loop
exitwhen ( i > 8192 )
set udg_AVARIABLE[i]=0
set i = i + 1
endloop
It looks like in GUI:
-
GUI
-
Events
-
Conditions
-
Actions
-
Do Multiple ActionsFor each (Integer A) from 1 to 8192, do (Actions)
-
Loop - Actions
-
Set ANYVARIABLE[(Integer A)] = 0
So you set the whole variables but warcraft can do LIMITED amount of functions ( variable set ) at a trigger. Just about 10000 of Set function. Others will be skipped.
So why it isn't working?? The whole thing fails at the Initialization at variable set up because:
JASS:
function main takes nothing returns nothing
call SetCameraBounds(- 8192.0 + GetCameraMargin(CAMERA_MARGIN_LEFT) , - 8192.0 + GetCameraMargin(CAMERA_MARGIN_BOTTOM) , 8192.0 - GetCameraMargin(CAMERA_MARGIN_RIGHT) , 8192.0 - GetCameraMargin(CAMERA_MARGIN_TOP) , - 8192.0 + GetCameraMargin(CAMERA_MARGIN_LEFT) , 8192.0 - GetCameraMargin(CAMERA_MARGIN_TOP) , 8192.0 - GetCameraMargin(CAMERA_MARGIN_RIGHT) , - 8192.0 + GetCameraMargin(CAMERA_MARGIN_BOTTOM))
call SetDayNightModels("Environment\\DNC\\DNCLordaeron\\DNCLordaeronTerrain\\DNCLordaeronTerrain.mdl" , "Environment\\DNC\\DNCLordaeron\\DNCLordaeronUnit\\DNCLordaeronUnit.mdl")
call SetTerrainFogEx(0 , 1000.0 , 9000.0 , 0.000 , 0.396 , 0.361 , 0.239)
call NewSoundEnvironment("Default")
call SetAmbientDaySound("BarrensDay")
call SetAmbientNightSound("BarrensNight")
call SetMapMusic("Music" , true , 0)
call InitSounds()
call CreateRegions()
call CreateAllDestructables()
call CreateAllItems()
call CreateAllUnits()
call InitBlizzard()
call ExecuteFunc("jasshelper__initstructs8392421")
call ExecuteFunc("Acceleration___Init") // It still OK here
call InitGlobals() // Variable setup FAILS!!! Too much action ( About 40000 on your map of maximal 10000 :S ) so the remaining will not be run.
call InitCustomTriggers() // JASS triggers - It will not be run.
call RunInitializationTriggers() // GUI triggers - This won't be too
: (
endfunction
How to prevent that?? Simply. Try not to use Variable Arrays which is bigger than 1.
But how can I use variable arrays bigger than 1?
The same way as 1. All variable types got a base value. ( Almost all null )
-
A simple var calling
-
Events
-
Conditions
-
Actions
-
-------- ANYVARIABLE's size is just 1 --------
-
Game - Display to (All players) the text: (String(ANYVARIABLE[121]))
It will show you 0 but ANYVAR[121] is not edited.
Integer base = 0
Real base = 0.00
Boolean base = true or false I think
Unit = no unit = null
Dialog = new dialog
and others are null