|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectrc.yoda.utils.Gun
rc.yoda.plugin.guns.Linear
public class Linear
Linear a Gun that assumes the enemy will not change its velocity or heading and fires at where it is expected to be
| Constructor Summary | |
|---|---|
Linear(robocode.AdvancedRobot robot)
Class Constructor specifying the robot this gun is virtually mounted on |
|
| Method Summary | |
|---|---|
double |
getBulletPower()
Returns the power of the bullet this gun wants to fire caculated in onScannedRobot |
double |
getFireAngle()
Returns the angle to fire this gun wants to fire caculated in onScannedRobot |
void |
onScannedRobot(robocode.ScannedRobotEvent e)
Event method called by Robocode when this robot's scanner passes over another robot |
| Methods inherited from class rc.yoda.utils.Gun |
|---|
onBulletHit, onBulletHitBullet, onBulletMissed, onDeath, onPaint, onWin |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Linear(robocode.AdvancedRobot robot)
| Method Detail |
|---|
public void onScannedRobot(robocode.ScannedRobotEvent e)
onScannedRobot in class GunScannedRobotEvent - information about the scanned robotpublic double getBulletPower()
getBulletPower in class Gunpublic double getFireAngle()
getFireAngle in class Gun
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||