Always with the indexing, you're discriminating Hashtable user :/
I constantly say it because your method of doing these things is always half-way there. I personally used hashtables all the time up to the last two spells I used myself, so I can't exactly discriminate against my own method.
defskull said:
About the loops, well I used 2 loops to handle 2 Unit Group, you suggest that I should merge those 2 Pick Unit Group Action in one trigger ?
And create an artificial wait either to one of the interval ?
And the trigger should be turned off when both Unit Group are empty ?
Yes because it would be more efficient and result in fewer triggers as well.
defskull said:
If I use your method, imagine how long the code would be ;p
Deal with it, there are pros and cons.
Also, to my eyes, the processing is fast enough.
Still shorter than most of my spells XD
Also, what are the pros? I personally can't think of any
For the record, though, how fast the processing is - what's good enough is up to the moderator who reviews it.
Anyway I'm not /attempting/ to discriminate at all, and do not think hashtables have no place, but rather think you're good enough to not since it'd cut off roughly 20+ lines of your code due to the way you're doing it, which actually bar having arrayed variables is almost there
On another note which I think got a bit left behind: As I said - since you set things into variables initially instead of directly to your hashtables, it's actually half as efficient (not literally but you get the idea) since it uses twice as many lines to do the same thing, which is why I say it's close to dyanmic indexing since if you just made those variables arrays and indexed them, you'd be done, - My point on using caches instead of a lot of different variables also got left behind, which is the typical method of using variables when loading from a hashtable, since there's not much point having individually named variables to load from each hashtable instead of having one or two arrayed variables able to store all the values.