Code: Select all
AddMapPoint()
AddMapLine()
GetMapPoints()
GetMapLines()
the Add methods only add lines when they will be visible...
i don't really get how it works, but i can explain how i tested it:
I made my AI add random points when i chat "add point" and likewise with "add line". i had 2 instances of the AI running.
team 0 is yellow
team 1 is red
my chatlog:
/cheat
/team 1
add point
<i see a red point somewhere on the map>
add line
<additionally a red line>
/spectator
<now i see the 2 red things plus a WHITE line and a WHITE point>
add point
<a red point and a white point get added>
/team 0
<no points or lines are visible at all>
add point
<a yellow point appears>
/spectator
<now everything is visible, the red, the white and the yellow stuff>
add point
<a yellow and a white point get added>
/team 1
<now only the red line and the FIRST red point are visible, but not the one that was added when i was in spectator mode the first time>
the Get methods seem to work, as they return all points/lines that are of the color of the (ai) player, even the ones that are not visible.
but with the Add methods, and what is getting shown, something seems to be wrong. when spectating, it seems to remember the last team, and draw correctly for it, but with white for the other one.
.. its nothing important, but still wrong, as i see it.
should i make a bug report?
edit:
woops, i just saw that i made the Add methods, but this should not make a big difference, as they just use the AIHCAddMapPoint and AIHCAddMapLine structs through HandleCommand().