Hello, community of SC2Mapster! I have a question. Is there something... Wrong that I can't see in the triggers that I posted as Attachment photos?
What I want with this trigger is this:
When units owned by player 13 / 14 kills each other, units within the group "PLAYER UNITS" will gain [minerals/gas/terrazine] whenever they are near the KILLING UNIT, or the TRIGGERING UNIT(Killed unit)
So I made the trigger - to only see it not working. When the units owned by Player 14 killed a unit owned by Player 13, nothing happened. While nothing happened as well the other way around. People in my development team didn't have a single idea about why this was going on too... So I'm asking.
First of all, why are you disabling error messages during test document? Go to Map --> Map Options and uncheck that. The error messages make it quite obvious what the problem is: you're trying to access an element past the end of an array. That is, TL Max Score has size 7, and in your if-statement condition you're trying to access TL Max Score[13]. This kind of error halts execution of the rest of the trigger. Increase the size of that array to 15 and it will work.
There are a bunch of other errors you should probably fix before doing anything else.
Thanks for the heads up! I'll make sure to uncheck the "Error Messages" to see why I'm getting the errors more easily. And yes, doing that solved the issue!
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hello, community of SC2Mapster! I have a question. Is there something... Wrong that I can't see in the triggers that I posted as Attachment photos?
What I want with this trigger is this:
When units owned by player 13 / 14 kills each other, units within the group "PLAYER UNITS" will gain [minerals/gas/terrazine] whenever they are near the KILLING UNIT, or the TRIGGERING UNIT(Killed unit)
So I made the trigger - to only see it not working. When the units owned by Player 14 killed a unit owned by Player 13, nothing happened. While nothing happened as well the other way around. People in my development team didn't have a single idea about why this was going on too... So I'm asking.
Why is this not working?
Frustrated Bump. I've managed to recreate this error in an example map. Hope this gets fixed so my map can progress!
MAP DOWNLOAD LINK:
https://www.sc2mapster.com/projects/viacre-chapter-02-another-world/files/2456651/download
First of all, why are you disabling error messages during test document? Go to Map --> Map Options and uncheck that. The error messages make it quite obvious what the problem is: you're trying to access an element past the end of an array. That is, TL Max Score has size 7, and in your if-statement condition you're trying to access TL Max Score[13]. This kind of error halts execution of the rest of the trigger. Increase the size of that array to 15 and it will work.
There are a bunch of other errors you should probably fix before doing anything else.
In reply to temhawk: