Robocode/FAQ

From Robowiki
< Robocode
Revision as of 00:21, 13 November 2007 by AaronR (talk | contribs) (Moving from Robocode Basics)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Frequently asked questions about Robocode.

Installing and Using

I can't install Robocode.
First make sure you have Java installed on your computer. To check it, run the command: java -version It should execute and show a version 1.5 or higher. If not, go to Sun site and download the last version. After, make sure you have downloaded the correct file (robocode-setup.jar). Execute the file by double-clicking on it, or if you want to do it manually, execute the following command: java -jar robocode-setup.jar. It will launch an installer that will install Robocode. The installer creates the icons to execute Robocode, but you can execute it manually by running the robocode.bat or robocode.sh file in the /robocode directory.
I have downloaded a robot from the Web, but I don't know how to use it, because it doesn't appear anywhere.
By default, robots are read from the /robocode/robots directory. You can select "Robot -> Import Downloaded Robot" to copy a robot JAR to this directory from another location.
What do I have to do to see the source code of a robot?
You can do two things. The first option is to open the Editor Window in Robocode and use the command in the File menu. The second option is to open the robot ".jar" file with a zip utility and find the source code there (assuming, of course, the robot is open source).