|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsimogl.model.AbstractMD2Model
public abstract class AbstractMD2Model
This class represents a model that has been loaded from a md2 file. Such models are usually used as characters in the game. Notice, that this is an abstract class. You cannot intanciate an object of this class directly.
Field Summary | |
---|---|
static int |
STAND
|
static int |
WALK
|
Constructor Summary | |
---|---|
AbstractMD2Model(float x,
float y,
float z)
Creates a new md2 model at the specified location |
Method Summary | |
---|---|
Animation |
getCurrentAnim()
Returns the animation that is currently assigned to the model. |
int |
getCurrentAnimState()
Returns the int that symbolizes the current animation state like "WALK" or "STAND". |
void |
setAnimationState(int state)
Sets the current animation of the model. |
void |
update(long elapsedTime)
Updates a md2 model |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int WALK
public static final int STAND
Constructor Detail |
---|
public AbstractMD2Model(float x, float y, float z)
x
- x-coordinatey
- y-coordinatez
- z-coordinateMethod Detail |
---|
public void setAnimationState(int state)
goblinModelObject.setAnimation(MD2Goblin.WALK)
state
- a constant that defines an animation statepublic Animation getCurrentAnim()
public int getCurrentAnimState()
public void update(long elapsedTime)
elapsedTime
- time between two frames
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |