Item
Classes:
Protected Types
MaskBits { HiddenMask = Parent::NextFreeMask ThrowSrcMask = Parent::NextFreeMask << 1 PositionMask = Parent::NextFreeMask << 2 RotationMask = Parent::NextFreeMask << 3 NextFreeMask = Parent::NextFreeMask << 4 }
Parent
Public Types
LightType { NoLight = 0 ConstantLight PulsingLight NumLightTypes }
Protected Attributes
Protected Static Attributes
Private Attributes
Public Attributes
Protected Functions
advanceTime(F32 dt)
Advances simulation time for animations.
DECLARE_CALLBACK(void , onEnterLiquid , (const char *objID, F32 waterCoverage, const char *liquidType) )
DECLARE_CALLBACK(void , onLeaveLiquid , (const char *objID, const char *liquidType) )
DECLARE_CALLBACK(void , onStickyCollision , (const char *objID) )
prepRenderImage(SceneRenderState * state)
Public Functions
Item()
~Item()
applyImpulse(const Point3F & pos, const VectorF & vec)
Applies an impulse force to this object.
Gets the velocity of the object.
interpolateTick(F32 delta)
Interpolates between tick events.
bool
isAtRest()
bool
bool
isStatic()
bool
onAdd()
Called when the object is added to the sim.
bool
onNewDataBlock(GameBaseData * dptr, bool reload)
Called when a new datablock is set.
packUpdate(NetConnection * conn, U32 mask, BitStream * stream)
Instructs this object to pack its state for transfer over the network.
processTick(const Move * move)
Processes a move event and updates object state once every 32 milliseconds.
registerLights(LightManager * lightManager, bool lightingScene)
setCollisionTimeout(ShapeBase * obj)
setTransform(const MatrixF & mat)
Sets the Object -> World transform.
setVelocity(const VectorF & vel)
Sets the velocity of this object.
unpackUpdate(NetConnection * conn, BitStream * stream)
Instructs this object to read state data previously packed with packUpdate.
Private Functions
buildConvex(const Box3F & box, Convex * convex)
Builds a convex hull for this object.
bool
buildPolyList(PolyListContext context, AbstractPolyList * polyList, const Box3F & box, const SphereF & sphere)
Builds a list of polygons which intersect a bounding volume.
onDeleteNotify(SimObject * object)
Called when a SimObject is deleted.
updateVelocity(const F32 dt)
Private Static Functions
bool
_setRotate(void * object, const char * index, const char * data)
bool
_setStatic(void * object, const char * index, const char * data)
Public Static Functions
Detailed Description
Protected Types
MaskBits
Enumerator
- HiddenMask = Parent::NextFreeMask
- ThrowSrcMask = Parent::NextFreeMask << 1
- PositionMask = Parent::NextFreeMask << 2
- RotationMask = Parent::NextFreeMask << 3
- NextFreeMask = Parent::NextFreeMask << 4
typedef ShapeBase Parent
Public Types
LightType
Enumerator
- NoLight = 0
- ConstantLight
- PulsingLight
- NumLightTypes
Protected Attributes
bool mAtRest
S32 mAtRestCounter
ShapeBase * mCollisionObject
U32 mCollisionTimeout
ItemData * mDataBlock
StateDelta mDelta
bool mInLiquid
PhysicsBody * mPhysicsRep
bool mRotate
bool mStatic
bool mSubclassItemHandlesScene
A subclass of Item will handle all of the adding to the scene.
VectorF mVelocity
Protected Static Attributes
const S32 csmAtRestTimer
Private Attributes
OrthoBoxConvex mConvex
S32 mDropTime
LightInfo * mLight
Box3F mWorkingQueryBox
Public Attributes
Point3F mStickyCollisionNormal
Point3F mStickyCollisionPos
Protected Functions
_updatePhysics()
advanceTime(F32 dt)
Reimplemented from: ProcessObject
Reimplemented by: ProximityMine, AITurretShape, TurretShape
DECLARE_CALLBACK(void , onEnterLiquid , (const char *objID, F32 waterCoverage, const char *liquidType) )
DECLARE_CALLBACK(void , onLeaveLiquid , (const char *objID, const char *liquidType) )
DECLARE_CALLBACK(void , onStickyCollision , (const char *objID) )
prepRenderImage(SceneRenderState * state)
Reimplemented from: ShapeBase
Reimplemented by: ProximityMine, TurretShape
Public Functions
Item()
~Item()
applyImpulse(const Point3F & pos, const VectorF & vec)
Reimplemented from: ShapeBase
DECLARE_CONOBJECT(Item )
getCollisionObject()
getVelocity()
Reimplemented from: SceneObject
interpolateTick(F32 delta)
Reimplemented from: GameBase
Reimplemented by: TurretShape
isAtRest()
isRotating()
isStatic()
onAdd()
Reimplemented from: GameBase
Reimplemented by: ProximityMine, AITurretShape, TurretShape
onNewDataBlock(GameBaseData * dptr, bool reload)
Reimplemented from: GameBase
Reimplemented by: ProximityMine, AITurretShape, TurretShape
onRemove()
Reimplemented from: GameBase
Reimplemented by: ProximityMine, AITurretShape, TurretShape
packUpdate(NetConnection * conn, U32 mask, BitStream * stream)
Reimplemented from: GameBase
Reimplemented by: ProximityMine, AITurretShape, TurretShape
processTick(const Move * move)
Reimplemented from: GameBase
Reimplemented by: ProximityMine, AITurretShape, TurretShape
registerLights(LightManager * lightManager, bool lightingScene)
setCollisionTimeout(ShapeBase * obj)
setTransform(const MatrixF & mat)
Reimplemented from: SceneObject
Reimplemented by: ProximityMine, AITurretShape, TurretShape
setVelocity(const VectorF & vel)
Reimplemented from: ShapeBase
unpackUpdate(NetConnection * conn, BitStream * stream)
Reimplemented from: GameBase
Reimplemented by: ProximityMine, AITurretShape, TurretShape
Private Functions
buildConvex(const Box3F & box, Convex * convex)
Reimplemented from: SceneObject
buildPolyList(PolyListContext context, AbstractPolyList * polyList, const Box3F & box, const SphereF & sphere)
Reimplemented from: SceneObject
onDeleteNotify(SimObject * object)
Reimplemented from: ShapeBase
updatePos(const U32 mask, const F32 dt)
updateVelocity(const F32 dt)
updateWorkingCollisionSet(const U32 mask, const F32 dt)
Private Static Functions
_setRotate(void * object, const char * index, const char * data)
_setStatic(void * object, const char * index, const char * data)