Variable Arrays Problem

looneygr

New Member
Reaction score
0
varsck5.jpg


With those variables my triggers wont work(load?) when i test my map.If i delete 1 UnitGroup Array and 2 Real Arrays everything works perfect. What is going on?
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
> What is going on?

You're hitting the operations limit at map init with those insane array sizes.

The problem being that the arrays get initialized with the default value up to whatever you set as size.
Given the amount of arrays, and their sizes, that doesn't work.

And, actually, all arrays can hold the same number of entries, regardless of size.
Reduce all sizes to one, except those that have to work player based (use 12 or 16 there).

Are you really sure you need that many?
 

Chocobo

White-Flower
Reaction score
409
you can remove the array size of each variable it is useless as you are setting them to null or 0 or "nothing" at start (an array size of 1000 has an array size of 8191.... and it's variable between array 0 and 1000 would be the "Initial value"..)
when map initializes it will reach operation limits becaus you are doing something like 200000 actions.
 

looneygr

New Member
Reaction score
0
Well i'm little newbie in triggering so...!! I'm trying to make my spells MUI using this guide.So reducing all values to 1 will my spells be MUI?
 

Chocobo

White-Flower
Reaction score
409
Setting an array size to 0 or 1 or anything changes nothing, it only affects how many indexes of the variable will have the "Initial value".

ex:
Variable ABC integer with array size 5 and Initial Value 0
ABC[0] = 0
ABC[1] = 0
ABC[2] = 0
ABC[3] = 0
ABC[4] = 0
ABC[5] = 0
(6 calls while loading)

Variable ABC integer with array size 1000 and Initial Value 0
ABC[0] = 0
ABC[1] = 0
.....
ABC[1000] = 0
(1001 calls while loading)

Variable ABC integer with array size 5 and Initial Value 1234
ABC[0] = 1234
ABC[1] = 1234
ABC[2] = 1234
ABC[3] = 1234
ABC[4] = 1234
ABC[5] = 1234

Variable ABC integer with array size 1000 and Initial Value 1234
ABC[0] = 1234
ABC[1] = 1234
...
ABC[1000] = 1234
 

Metaldrummer

New Member
Reaction score
11
So the array size you set only affects the number of indexes that make a call while loading, and you can still set or reference as many pieces of that variable as you like during the game?
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top