|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfeud.testgame.model.LocalBulletManager
Manager class for bullets. A bullet is an instance of LocalBullet in this case.
Constructor Summary | |
LocalBulletManager()
Creates a new manager. |
Method Summary | |
LocalObject |
addBullet(LocalPlayerObject player,
com.threed.jpct.World world)
Adds a new bullet to the manager and, if not null, a new view for that bullet to the world. |
java.util.List |
fillOrKill(ExtendedDataContainer dc)
Prepares a data container with the data of all currently active bullets on a client and adds all still exisiting but inactive bullets to a "to-kill"-List. |
com.threed.jpct.SimpleVector |
getInitialPosition(LocalPlayerObject player)
Gets the initial position of a newly fired bullet. |
LocalObject |
getLocalObjectToView(ClientObject co)
The collision detection routines work with the view objects, not with the model. |
void |
moveLocalBullets(long ticks,
Level level)
Moves the bullets according top their speed. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public LocalBulletManager()
Method Detail |
public LocalObject getLocalObjectToView(ClientObject co)
co
- the view
public com.threed.jpct.SimpleVector getInitialPosition(LocalPlayerObject player)
player
- the player which fires the bullet
public LocalObject addBullet(LocalPlayerObject player, com.threed.jpct.World world)
player
- the player which fires the bulletworld
- the world in which the player exists
public void moveLocalBullets(long ticks, Level level)
ticks
- the game time that has passed since the last calllevel
- the current level (this can be null if the bullet has no view)public java.util.List fillOrKill(ExtendedDataContainer dc)
dc
- the container to be filled
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |