![]() |
VR-Forces Developer's Guide
|
CPU-side pool slot descriptor for a single GPU-simulated bullet.
Owns no physics state; position, velocity, and liveness are managed entirely by the GPU pipeline. This object tracks the pool slot index and the firing entity ID so the manager can write spawn data and release slots on projectile death.
Public Member Functions | |
| DtBallisticProjectile (int index) | |
| virtual | ~DtBallisticProjectile () |
| virtual void | deactivate () |
| virtual int | index () const |
| virtual const DtUniqueID & | uniqueId () const |
| virtual void | setUniqueId (const DtUniqueID &uniqueId) |
| virtual bool | isActive () const |
| virtual void | setIsActive (bool active) |
Protected Attributes | |
| int | myIndex |
| DtUniqueID | myUniqueId |
| bool | myIsActive |
| makVrv::DtBallisticProjectile::DtBallisticProjectile | ( | int | index | ) |
Constructs a projectile assigned to the given pool slot.
| index | Pool slot index (stable offset into SpawnBuffer and StateBuffer). |
|
virtual |
Virtual destructor.
|
virtual |
Resets this slot for return to the pool; does not modify GPU buffers.
|
virtual |
Returns the pool slot index.
|
virtual |
Returns the unique ID of the entity that fired this projectile.
|
virtual |
Sets the unique ID of the firing entity.
| uniqueId | Unique ID to associate with this projectile. |
|
virtual |
Returns true while this slot is acquired from the pool and not yet released.
|
virtual |
Sets the CPU-side liveness flag.
| active | True to mark the slot as live; false to mark it as free. |
|
protected |
Pool slot index; stable offset into SpawnBuffer and StateBuffer.
|
protected |
Unique ID of the entity that fired this projectile.
|
protected |
CPU-side liveness flag; authoritative source is the GPU readback.