Because my idea is the next:
Every time a unit enters the map i set its custom value to a number, and every time i do this i increase that number by 1 (with an integer variable).
So, every unit will have a index as its custom value that i can use later for diferent skills.
The problem is, that the map is a hero defense, so there will be a lot of units, and when they die more will come, and im afraid that the custom value can reach is maximum value.
And i do not know if i can reset the counter because some units (like the heroes for example) will remain the entire game.
Even though you have loads of units, I don't think it will surpass a few thousands. Custom value can go up to that magnitude. Oh and seems like you're trying to create an indexing system. Would be easier by vJASS actually :/
i guess the custom value is an integer, in which case it got 2^32 possible values, split into two halfs one of which is positive and one negative.
For all the lazy people around its about: 4 294 967 296 different values.
Might be wrong though if the custom value is not an integer but i dont think so.
I'm on a page about incorrect corrections, and spent the better part of like two hours trying to get someone to understand that -5^2 = -25, not 25, and then that post had comments get reposted because that group is self sustaining, and that person was in turn trying to explain what I just explained to them. And I'm taking that as a victory
I will be AFK for a couple of days you guys hold down the fort while I am gone. I will be checking in on my phone but that will severly limit me. Be back saturday!