|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.eside.flingbox.physics.collisions.Collider
public abstract class Collider
Abstract collision manager for any object.
Constructor Summary | |
---|---|
Collider(PhysicBody physicBody)
Local constructor for any collider. |
Method Summary | |
---|---|
boolean |
canContact(Collider collider)
|
abstract Contact[] |
checkContacts(Collider collider)
Checks if objects can collide |
PhysicBody |
getAssociatedBody()
|
float |
getBoundingCircle()
|
Vector2D |
getPosition()
|
void |
onMovement(Vector2D newPosition,
float newAngle)
Called when a movement occurs |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Collider(PhysicBody physicBody)
listener
- Collision listenerMethod Detail |
---|
public abstract Contact[] checkContacts(Collider collider)
collider
- other objects collider.
public boolean canContact(Collider collider)
public void onMovement(Vector2D newPosition, float newAngle)
onMovement
in interface PhysicBody.OnMovementListener
newPosition
- new body's positionpublic Vector2D getPosition()
getPosition
in interface PositionComparator.Positionable
public float getBoundingCircle()
public PhysicBody getAssociatedBody()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |