| 08-14-2007, 11:14 AM | #2 |
It would be a good idea to tell us what's not working or why else you need help. What I don't understand from the first look: Why are your loops going from 1 to 12 when you declared only Hero_Region[1] to Hero_Region[4]. |
| 08-17-2007, 04:22 AM | #3 |
the loop is because there will be 12 heros just there arent yet ;/ be ways just sometimes you bring the unit over the area and it doesnt work... also sometimes it takes nearly a second of being on the area before it picks the hero -.- |
| 08-17-2007, 12:10 PM | #4 |
in general it isn't a good idea to use variables which aren't initialized, that can cause unpredictable results, so better only loop through variables you have initialized. Another thing which isn't such a good idea is to use the same variable (in your case "Integer A") in loops which run inside another loop, because both loops change the value of the variable. But I don't think that will cause the error, because you leave the trigger after running the second loop once. I also don't understand the sense of the "wait 0.01 sec" at the beginning. Try to enclose the point where the error occurs by using debugmessages. |
| 08-17-2007, 07:19 PM | #5 |
the reason for the .01 was because it wasnt working and that made it work MORE often... |
| 08-19-2007, 08:41 PM | #6 |
Well i tried adding in debug messages and it seems to not work at different spots... I think it might be the "units in region" because maby the unit isnt in the region when it enters ;/ Ne ways also sometimes it takes 5+ seconds before the trigger picks a hero ~.~ so ya... no idea still |
