Subversion Repositories svnkaklik

Compare Revisions

No changes between revisions

Ignore whitespace Rev 5 → Rev 6

/programy/Robocode/Robot.java
0,0 → 1,45
package kaklik;
import robocode.*;
import java.awt.Color;
//setColors(Color.green,Color.blue);
 
/**
* Robot - a robot by (your name here)
*/
public class Robot extends Robot
{
/**
* run: Robot's default behavior
*/
public void run()
{
// After trying out your robot, try uncommenting the import at the top,
// and the next line:
//setColors(Color.red,Color.blue,Color.green);
while(true)
{
// Replace the next 4 lines with any behavior you would like
ahead(100);
turnGunRight(360);
back(100);
turnGunRight(360);
}
}
 
/**
* onScannedRobot: What to do when you see another robot
*/
public void onScannedRobot(ScannedRobotEvent e)
{
fire(1);
}
 
/**
* onHitByBullet: What to do when you're hit by a bullet
*/
public void onHitByBullet(HitByBulletEvent e)
{
turnLeft(90 - e.getBearing());
}
}
/programy/Robocode/vssver.scc
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Property changes:
Added: svn:mime-type
+application/octet-stream
\ No newline at end of property