|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jme.input.InputHandler
com.jme.input.ChaseCamera
net.sf.tankbattles.scene.camera.CustomChaseCamera
public class CustomChaseCamera
Same original jME ChaseCamera with a different update method. Avoids getting updated by the main loop update method to avoid the sttutering. Adds a custom update method witch should be called after the physics update step.
ChaseCameraUpdateCallback| Field Summary |
|---|
| Fields inherited from class com.jme.input.ChaseCamera |
|---|
DEFAULT_DAMPINGK, DEFAULT_ENABLESPRING, DEFAULT_MAINTAINAZIMUTH, DEFAULT_MAXDISTANCE, DEFAULT_MINDISTANCE, DEFAULT_SPRINGK, DEFAULT_STAYBEHINDTARGET, DEFAULT_WORLDUPVECTOR, PROP_DAMPINGK, PROP_ENABLESPRING, PROP_INITIALSPHERECOORDS, PROP_MAINTAINAZIMUTH, PROP_MAXDISTANCE, PROP_MINDISTANCE, PROP_SPRINGK, PROP_STAYBEHINDTARGET, PROP_TARGETOFFSET, PROP_WORLDUPVECTOR |
| Fields inherited from class com.jme.input.InputHandler |
|---|
AXIS_ALL, AXIS_NONE, BUTTON_ALL, BUTTON_NONE, DEVICE_ALL, DEVICE_KEYBOARD, DEVICE_MOUSE |
| Method Summary | |
|---|---|
void |
customUpdate(float tpf)
Custom update method to be called after physics update step. |
static com.jme.input.ChaseCamera |
getInstance(com.jme.renderer.Camera camera,
Mission mission)
Factory method for initializing the ChaseCamera. |
void |
nextTarget()
Sets the chaser to follow the next target (tank). |
void |
update(float tpf)
Default empty update method that is invoked at the main loop. |
| Methods inherited from class com.jme.input.ChaseCamera |
|---|
getCamera, getDampingK, getIdealPosition, getIdealSphereCoords, getMaxDistance, getMinDistance, getMouseLook, getSpeed, getSpringK, getTarget, getTargetOffset, isEnableSpring, isForceAzimuthUpdate, isLooking, isMaintainAzimuth, isStayBehindTarget, setActionSpeed, setCamera, setDampingK, setEnableSpring, setForceAzimuthUpdate, setIdealSphereCoords, setLooking, setMaintainAzimuth, setMaxDistance, setMinDistance, setSpringK, setStayBehindTarget, setTarget, setTargetOffset, setWorldUpVec, updateProperties |
| Methods inherited from class com.jme.input.InputHandler |
|---|
addAction, addAction, addAction, addAction, addAction, addAction, addDevice, addToAttachedHandlers, clearActions, getBooleanProp, getDevices, getFloatProp, getFromAttachedHandlers, getIntProp, getObjectProp, getParent, isEnabled, removeAction, removeAction, removeAllActions, removeAllFromAttachedHandlers, removeFromAttachedHandlers, setActionSpeed, setEnabled, setEnabledOfAttachedHandlers, sizeOfAttachedHandlers |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static com.jme.input.ChaseCamera getInstance(com.jme.renderer.Camera camera,
Mission mission)
camera - to have the position updated.target - to be followed.
public void nextTarget()
public void update(float tpf)
update in class com.jme.input.ChaseCameratpf - time per frameChaseCameraUpdateCallbackpublic void customUpdate(float tpf)
tpf - time per frameChaseCameraUpdateCallback
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||