little help

Jump to navigation Jump to search
Revision as of 9 June 2012 at 11:17.
This is the thread's initial revision.

little help

Hi mate. You can change the color with:

  public void run() {
      // all the same color
       setAllColors(Color.RED);

      // or different for body , gun , radar
      setRadarColor(Color.GREEN);
      setGunColor(Color.BLUE);
      setBodyColor(Color.BLACK);
       ...
   }

You can make a bookmark to the robocode api Robocode API and there you find all the functions you can use. It looks a bit complicated if you are not familiar whit this kind of documentation but with a little help you get used to it very quickly.

For example if you look for the color. Hit the "AdvancedRobot" in the left frame "All Classes" and search just for "Color" in the right frame. Every function has a short description so just poke around a little.

And don't be shy just ask whatever you wan't to know.

take care

    Wompi12:17, 9 June 2012