|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectespresso3d.engine.base.E3DEngineItem
espresso3d.engine.renderer.base.E3DRenderable
espresso3d.engine.world.sector.base.E3DPortalEnabledRenderable
espresso3d.engine.world.sector.actor.E3DActor
| Constructor Summary | |
E3DActor(E3DActor toCopyActor)
This copies all the actor geometry into another actor. |
|
E3DActor(E3DEngine engine,
E3DWorld world,
E3DBoundingObject boundingObject,
java.lang.String actorID)
Create an actor with a bounding object |
|
E3DActor(E3DEngine engine,
E3DWorld world,
java.lang.String actorID)
Create an actor without a bounding object |
|
| Method Summary | |
void |
addSound3DToAssociatedList(E3DSound3D sound3D)
|
void |
addTriangle(E3DTriangle triangle)
When adding triangles, we could put the unique vertices into the reduced vertex list, however, since we probably won't add triangles much, its a lot less labor intensive to just calculate it the first time we try to grab the list. |
java.lang.String |
getActorID()
|
java.util.ArrayList |
getAssociatedSound3DList()
|
E3DBoundingObject |
getBoundingObject()
Return the bounding object or null for bounding collision tests |
E3DMesh |
getMesh()
|
E3DOrientation |
getOrientation()
|
E3DSkeleton |
getSkeleton()
|
E3DSortedRenderableMap |
getTextureSortedTriangleMap()
|
java.util.ArrayList |
getTriangleList()
Must return an ArrayList of E3DTriangles that make up the geometry of the object. |
java.util.ArrayList |
getUniqueVertexPositionList()
Returns a list of only the unique triangle vertices in the actor (no duplicates). |
E3DWorld |
getWorld()
|
abstract boolean |
isCollideable()
Override and return true if this actor is something other actors/objects can collide with. |
boolean |
isDebugBoundingObjectDisplayed()
|
boolean |
isDebugSkeletonDisplayed()
|
boolean |
isLit()
actorLit indicates whether or not the actor should be lit (if not, it will be fullbright) |
boolean |
isModelDisplayed()
When true, the actor triangles are rendered. |
boolean |
isNeedingLightRecalc()
Returns true if this actor has changed/moved/etc and needs to have its lighting recalculated |
void |
loadActor(java.lang.String actorFilename,
boolean fromJar)
Load an actor file's geometry into this actor |
void |
moveForward(double speed)
moves the actor along the vector it is facing (forward/backward) |
abstract void |
onCollisionActor(E3DCollision collision)
This gets called when an actor collides with this actor (collider or collidee. |
abstract void |
onCollisionSprite(E3DCollision collision)
This gets called when a particle collides with this actor |
abstract E3DActor |
onGetClone()
This method must be overriden to return a clone of the actor. |
void |
removeSound3DFromAssociatedList(E3DSound3D sound3D)
|
void |
render()
Actors are renderable, so this renders the actor directly but usually shouldn't be used. |
void |
rotate(double angle)
Rotates around the up vector |
void |
rotate(double angle,
E3DVector3F upVec)
Rotates the actor around the aroundVec. |
void |
scale(double scaleAmt)
Scale the actors triangles and bounding object (if it exists) |
void |
setActorID(java.lang.String actorID)
|
void |
setBoundingObject(E3DBoundingObject boundingObject)
|
void |
setDebugBoundingObjectDisplayed(boolean debugBoundingObjectDisplayed)
|
void |
setDebugSkeletonDisplayed(boolean debugSkeletonDisplayed)
|
void |
setLit(boolean actorLit)
Sets whether or not the actor sould be lit by the world. |
void |
setModelDisplayed(boolean displayMesh)
/** When true, the actor triangles are rendered. |
void |
setNeedingLightRecalc(boolean needingLightRecalc)
Set to true if this actor has changed/moved/etc and needs to have its lighting recalculated, otherwise false This is normally handled by the engine |
void |
setPosition(E3DVector3F positionVec)
This procedure will move the actor to the new position. |
void |
setRenderMode(int renderMode)
When an actor's render mode is set, all of its geometry must also be converted over to that render mode. |
void |
setSkeleton(E3DSkeleton skeleton)
|
void |
setWorld(E3DWorld world)
|
void |
translate(E3DVector3F translationAmt)
Move all the triangles of the actor and the position vec by translationAmt. |
void |
update(double lastFrameTimeSeconds)
Automatically updates any actor information that needs to be updated/checked every frame. |
| Methods inherited from class espresso3d.engine.world.sector.base.E3DPortalEnabledRenderable |
checkSectorChangeDuringMovement, getSector, setSector |
| Methods inherited from class espresso3d.engine.renderer.base.E3DRenderable |
getBlendMode, getKey, getRenderMode, initCorrectGeometryRenderer, isKeyChanged, setBlendMode, setKeyChanged |
| Methods inherited from class espresso3d.engine.base.E3DEngineItem |
getEngine, setEngine |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface espresso3d.engine.collision.base.E3DCollisionDetectableObject |
getEngine, getSector |
| Constructor Detail |
public E3DActor(E3DEngine engine,
E3DWorld world,
java.lang.String actorID)
engine - The engine the actor is part ofworld - Currently required because an actors textureset is loaded into the world's textureset so it can be shared across all objects (better
for memory allocation)actorID - A unique ID for the actor
public E3DActor(E3DEngine engine,
E3DWorld world,
E3DBoundingObject boundingObject,
java.lang.String actorID)
engine - The engine the actor is part ofworld - Currently required because an actors textureset is loaded into the world's textureset so it can be shared across all objects (better
for memory allocation)boundingObject - Bounding object for the actoractorID - A unique ID for the actorpublic E3DActor(E3DActor toCopyActor)
toCopyActor - | Method Detail |
public void loadActor(java.lang.String actorFilename,
boolean fromJar)
throws E3DMissingEngineException,
java.lang.Exception
actorFilename -
E3DMissingEngineException
java.lang.Exceptionpublic void addTriangle(E3DTriangle triangle)
triangle - public java.util.ArrayList getTriangleList()
E3DCollisionDetectableObject
getTriangleList in interface E3DCollisionDetectableObjectpublic void translate(E3DVector3F translationAmt)
public void scale(double scaleAmt)
scaleAmt -
public void rotate(double angle,
E3DVector3F upVec)
angle - Rotation angle in radiansupVec - Normalised central axis vector to rotate aroundpublic void rotate(double angle)
angle - Angle to rotate in radianspublic void setPosition(E3DVector3F positionVec)
public void moveForward(double speed)
public void render()
render in class E3DRenderablepublic E3DBoundingObject getBoundingObject()
E3DCollisionDetectableObject
getBoundingObject in interface E3DCollisionDetectableObjectpublic void setBoundingObject(E3DBoundingObject boundingObject)
boundingObject - Set the bounding object the actor uses. Eventually, lists of boundingobjects
will be supported, so you'll use addpublic boolean isNeedingLightRecalc()
public void setNeedingLightRecalc(boolean needingLightRecalc)
needingLightRecalc - The needingLightRecalc to set.public boolean isLit()
isLit in interface E3DLightableObjectpublic void setLit(boolean actorLit)
setLit in interface E3DLightableObjectactorLit - The actorLit to set.public E3DWorld getWorld()
public void setWorld(E3DWorld world)
world - Set the world the actor is inpublic java.lang.String getActorID()
public void setActorID(java.lang.String actorID)
actorID - The actorID to set. This can't be changed outside of the constructorpublic java.util.ArrayList getUniqueVertexPositionList()
getUniqueVertexPositionList in interface E3DCollisionDetectableObjectpublic abstract void onCollisionActor(E3DCollision collision)
onCollisionActor in interface E3DCollisionDetectableObjectcollision - public abstract void onCollisionSprite(E3DCollision collision)
onCollisionSprite in interface E3DCollisionDetectableObjectcollision -
public abstract E3DActor onGetClone()
throws java.lang.Exception
java.lang.Exceptionpublic boolean isModelDisplayed()
public void setModelDisplayed(boolean displayMesh)
public E3DSortedRenderableMap getTextureSortedTriangleMap()
public void setRenderMode(int renderMode)
setRenderMode in class E3DRenderablepublic abstract boolean isCollideable()
isCollideable in interface E3DCollisionDetectableObjectpublic E3DSkeleton getSkeleton()
public void setSkeleton(E3DSkeleton skeleton)
public void update(double lastFrameTimeSeconds)
lastFrameTimeSeconds - public boolean isDebugSkeletonDisplayed()
public void setDebugSkeletonDisplayed(boolean debugSkeletonDisplayed)
public boolean isDebugBoundingObjectDisplayed()
public void setDebugBoundingObjectDisplayed(boolean debugBoundingObjectDisplayed)
public E3DMesh getMesh()
public E3DOrientation getOrientation()
getOrientation in interface E3DCollisionDetectableObjectpublic java.util.ArrayList getAssociatedSound3DList()
public void addSound3DToAssociatedList(E3DSound3D sound3D)
public void removeSound3DFromAssociatedList(E3DSound3D sound3D)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||