|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--roboplayer.core.RoboCore
In the next version all of the helper function will be moved to separated class.
Field Summary | |
static int |
DASH_FAST
|
static int |
DASH_NORMAL
|
static int |
DASH_SLOW
|
Constructor Summary | |
RoboCore(java.net.InetAddress host,
int port)
Standard constructor |
Method Summary | |
void |
dashTo(Polar pos,
int mode)
Dash to given position Helper function |
void |
dashTo(Vector2d pos,
int mode)
Dash to given position Helper function |
void |
dashToBackward(Polar object)
This function sends dash message Helper function |
void |
dashToBackward(Vector2d pos)
This function sends dash message Helper function |
void |
debug(java.lang.String msg)
Print debug message |
Body |
getBody()
Get robot body |
Memory |
getMemory()
Get robot memory |
Params |
getParams()
Get robot parameters |
int |
getStepCount(double distance)
Calculate how many steps are needed to pass this distance. |
boolean |
init(java.lang.String teamName,
boolean goalie)
Connect to server |
boolean |
isReady()
Check if robot is ready to play. |
void |
kickAt(double power,
double dir)
This function kicks ball at specified direction. |
void |
run()
Run robot |
void |
setDebugMode(boolean mode)
Set debug mode |
void |
setHeadAngle(double angle)
Set head angle. |
void |
stop()
Stop robot |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int DASH_SLOW
public static final int DASH_NORMAL
public static final int DASH_FAST
Constructor Detail |
public RoboCore(java.net.InetAddress host, int port) throws java.net.SocketException
host
- Server hostport
- server port
java.net.SocketException
- when we can't connect to the serverMethod Detail |
public boolean init(java.lang.String teamName, boolean goalie)
teamName
- name of the teamgoalie
- true if goalkeeper
public Body getBody()
public Memory getMemory()
public Params getParams()
public void run()
public void stop()
public boolean isReady()
public void dashTo(Vector2d pos, int mode)
public void dashTo(Polar pos, int mode)
public int getStepCount(double distance)
distance
- distance to pass
public void kickAt(double power, double dir)
public void setHeadAngle(double angle)
angle
- angle to setpublic void dashToBackward(Polar object)
public void dashToBackward(Vector2d pos)
public void setDebugMode(boolean mode)
mode
- true to enable debugingpublic void debug(java.lang.String msg)
msg
- message
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |