battlecode / battlecode-2018

:rocket:
45 stars 22 forks source link

Mars doesn't see units in space #128

Closed simonlindholm closed 6 years ago

simonlindholm commented 6 years ago

[Bruteforcer] SiestaGuru: Found another issue, the specs say that units in space are shared, but the mars player doesn't seem to be able to see them. This code execute by the mars player never shows anything in the logs: [Bruteforcer] SiestaGuru:

            VecUnit v = Player.gc.units();
            for(long i = 0 ; i < v.size(); i++){
                if(v.get(i).location().isInSpace()){
                   System.out.println("Found space unit");
                }
            }

I'll take a look at this later.

simonlindholm commented 6 years ago

I suppose the answer is: you need units_in_space for that...