|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectBasicCollisionGroup
vooga.games.grandius.collisions.BasicCollision
vooga.examples.player.PlayerEnemyCollision
public class PlayerEnemyCollision
This class takes care of collisions between the player and a common enemy - a Boomer or a Zipster. An instance of this class needs to be added to the playfield using the playfield's addCollisionGroup method. Once this is done,the playfield checks for a collision between the player and an enemy every time the playfield is updated.
Field Summary |
---|
Fields inherited from class vooga.games.grandius.collisions.BasicCollision |
---|
myGame |
Constructor Summary | |
---|---|
PlayerEnemyCollision(Game game)
|
Method Summary | |
---|---|
void |
collided(Sprite playerSprite,
Sprite enemy)
|
Methods inherited from class vooga.games.grandius.collisions.BasicCollision |
---|
getPlayer |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PlayerEnemyCollision(Game game)
Method Detail |
---|
public void collided(Sprite playerSprite, Sprite enemy)
collided
in class BasicCollision
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |