|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.event.KeyAdapter components.GameObject components.Ball
public class Ball
A Ball is a mutable object that bounces around the GameSpace
Field Summary |
---|
Fields inherited from class components.GameObject |
---|
center, coRef, delay, depth, frozen, g, height, name, orientAngle, orientVect, selected, shape, targets, velocity, visible, width |
Constructor Summary | |
---|---|
Ball(Map<String,String> p,
GameSpace g)
|
|
Ball(Vect3 tlf,
String name,
GameSpace g)
|
|
Ball(Vect3 tlf,
Vect3 velocity,
String name,
GameSpace g)
|
|
Ball(Vect3 tlf,
Vect3 velocity,
Vect3 ov,
Angle oa,
String name,
GameSpace g)
|
Method Summary | |
---|---|
protected Map<String,String> |
defaults()
sets all the defaults for this class. |
void |
getBasicPropertyMap(Map<String,String> m)
changes the map to represent the values of this GameObject required by the xml spec |
Vect3 |
getDiff()
in order for the ball to be in the middle of a grid, the center is offset by .5 from the tlf on the z axis |
GameObjectClassification |
getGOClassification()
Requires that all obejects return their own classification |
Set<Vect3> |
getOccupiedPositions()
|
Vect3 |
getTLF()
balls have the same center and tlf, so don't do that thar rounding thing |
protected Shape |
shape()
the Shape of the object |
void |
stepFrame()
This is overriden in mobile objects |
Methods inherited from class components.GameObject |
---|
action, actionPerformed, addTarget, clearTargets, equals, getBounds, getCenter, getCoRef, getDelay, getDepth, getGameSpace, getHeight, getName, getNonRoundedTLF, getOrientAngle, getOrientVector, getRoundedTLF, getShape, getTargets, getVelocity, getWidth, hashCode, isFrozen, isSelected, isVisible, onCollision, putInVect3, putInVect3, removeTarget, setCenter, setCoRef, setDelay, setDepth, setFrozen, setHeight, setOrientAngle, setOrientVect, setProperty, setSelected, setTLF, setVelocity, setVisible, setWidth, toString |
Methods inherited from class java.awt.event.KeyAdapter |
---|
keyPressed, keyReleased, keyTyped |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Ball(Vect3 tlf, Vect3 velocity, Vect3 ov, Angle oa, String name, GameSpace g)
public Ball(Vect3 tlf, Vect3 velocity, String name, GameSpace g)
public Ball(Vect3 tlf, String name, GameSpace g)
public Ball(Map<String,String> p, GameSpace g)
Method Detail |
---|
public Vect3 getDiff()
getDiff
in class GameObject
public Vect3 getTLF()
getTLF
in class GameObject
protected Map<String,String> defaults()
GameObject
defaults
in class GameObject
public void stepFrame()
GameObject
stepFrame
in class GameObject
public GameObjectClassification getGOClassification()
GameObject
getGOClassification
in class GameObject
public void getBasicPropertyMap(Map<String,String> m)
GameObject
getBasicPropertyMap
in class GameObject
protected Shape shape()
GameObject
shape
in class GameObject
public Set<Vect3> getOccupiedPositions()
getOccupiedPositions
in class GameObject
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |