|
| | BoxCollision (Entities::Scene *scene, entt::entity entity, const glm::vec3 &halfExtents=glm::vec3(0.5f)) |
| | Constructs a BoxCollisionComponent.
|
| | BoxCollision (const Entities::SpawnContext &context, const glm::vec3 &halfExtents=glm::vec3(0.5f)) |
| | Constructs a BoxCollisionComponent from spawn context data.
|
| | ~BoxCollision () override=default |
| | Destroys the box collision component.
|
| btCollisionShape * | createShape () override |
| | Creates the Bullet collision shape.
|
| void | debugDraw (const glm::mat4 &worldTransform) const override |
| | Draws debug visualization of the box.
|
| void | setHalfExtents (const glm::vec3 &halfExtents) |
| | Sets the half extents of the box.
|
| glm::vec3 | getHalfExtents () const |
| | Gets the half extents of the box.
|
| | Collision (Engine::Entities::Scene *scene, entt::entity entity) |
| | Constructs a CollisionComponent.
|
| | ~Collision () override |
| | Clears callback subscriptions and destroys the current Bullet shape.
|
| void | beginPlay () override |
| | Creates the Bullet shape and registers this component with a same-entity physics body.
|
| void | endPlay () override |
| | Clears callbacks, unregisters from the physics body, and destroys the Bullet shape.
|
| bool | drawImGui () override |
| | Draws the base logic component ImGui controls.
|
| virtual void | destroyShape () |
| | Destroys the current shape.
|
| void | markDirty () |
| | Marks the shape as needing rebuild. Call after changing shape properties (halfExtents, radius, etc.).
|
| void | rebuild () |
| | Rebuilds the shape and notifies PhysicsBodyComponent.
|
| btCollisionShape * | getShape () const |
| | Gets the current collision shape.
|
| void | setLocalOffset (const glm::vec3 &offset) |
| | Sets the local position offset relative to the body.
|
| glm::vec3 | getLocalOffset () const |
| | Gets the local position offset.
|
| void | setLocalRotation (const glm::quat &rotation) |
| | Sets the local rotation relative to the body.
|
| glm::quat | getLocalRotation () const |
| | Gets the local rotation.
|
| glm::mat4 | getLocalTransform () const |
| | Gets the local transform matrix.
|
| void | setIsTrigger (bool trigger) |
| | Sets whether this collision is a trigger (overlap only, no physics response).
|
| bool | isTrigger () const |
| | Checks if this collision is a trigger.
|
| void | setCollisionProfile (Physics::CollisionProfileHandle profile) |
| | Sets the collision profile handle used for filtering and response lookup.
|
| void | setCollisionProfileByName (const std::string &profileName) |
| | Sets the collision profile by registered profile name.
|
| Physics::CollisionProfileHandle | getCollisionProfile () const |
| | Gets the effective collision profile handle.
|
| template<typename ProfileEnum> |
| void | setCollisionProfile (ProfileEnum profile) |
| | Sets the collision profile from an enum registered with the active collision profile registry.
|
| virtual void | onCollisionBegin (Components::Collision *other) |
| | Called when a collision with another object begins.
|
| virtual void | onCollisionEnd (Components::Collision *other) |
| | Called when a collision with another object ends.
|
| virtual void | onCollisionStay (Components::Collision *other) |
| | Called every frame while colliding with another object.
|
| virtual void | onOverlapBegin (Components::Collision *other) |
| | Called when an overlap with another collision component begins.
|
| virtual void | onOverlapEnd (Components::Collision *other) |
| | Called when an overlap with another collision component ends.
|
| virtual void | onOverlapStay (Components::Collision *other) |
| | Called every frame while overlapping another collision component.
|
| template<typename ActorType, typename Callback> |
| CollisionCallbackHandle | onOverlapBegin (Callback &&callback) |
| | Registers a typed overlap-begin callback.
|
| template<typename ActorType, typename Callback> |
| CollisionCallbackHandle | onOverlapEnd (Callback &&callback) |
| | Registers a typed overlap-end callback.
|
| void | removeOverlapCallback (CollisionCallbackHandle handle) |
| | Removes an overlap callback registered with Collision::onOverlapBegin() or Collision::onOverlapEnd().
|
| void | dispatchOverlapBegin (Components::Collision *other) |
| | Dispatches overlap begin hooks and callbacks.
|
| void | dispatchOverlapEnd (Components::Collision *other) |
| | Dispatches overlap end hooks and callbacks.
|
| void | dispatchOverlapStay (Components::Collision *other) |
| | Dispatches overlap stay hooks.
|
| void | dispatchCollisionBegin (Components::Collision *other) |
| | Dispatches collision begin hooks.
|
| void | dispatchCollisionEnd (Components::Collision *other) |
| | Dispatches collision end hooks.
|
| void | dispatchCollisionStay (Components::Collision *other) |
| | Dispatches collision stay hooks.
|
| Components::PhysicsBody * | getBodyComponent () const |
| | Gets the physics body component this collision is registered with.
|
| Physics::CollisionHandle | getCollisionHandle () const |
| | Gets the runtime collision handle assigned by the physics engine.
|
| void | setCollisionHandle (Physics::CollisionHandle handle) |
| | Sets the runtime collision handle assigned by the physics engine.
|
| void | setDebugColorSeed (std::uint64_t seed) |
| | Sets a stable seed used for random debug color selection.
|
| void | setDebugName (std::string name) |
| | Sets the debug display name for this collision component.
|
| const std::string & | getDebugName () const |
| | Gets the debug display name for this collision component.
|
| | Logic (Entities::Scene *owningScene) |
| | Constructs a logic component owned by a scene.
|
| | Logic (const Entities::SpawnContext &context) |
| | Constructs a logic component from spawn context data.
|
| virtual | ~Logic ()=default |
| | Destroys the logic component.
|
| virtual std::string | getComponentName () const |
| | Gets the component type name for debugging/UI.
|
| virtual bool | drawImGuiName () |
| | Used to alter the name of the entity in the outliner.
|
| virtual void | tick (double deltaTime) |
| | Called every frame if ticking is enabled.
|
| bool | hasBegunPlay () const |
| | Checks whether beginPlay() has been called without a matching endPlay().
|
| bool | canTick () const |
| | Checks if the component is currently set to tick.
|
| void | setCanTick (bool enable) |
| | Enables or disables ticking for this component.
|
| Entities::Entity * | getOwningEntity () const |
| | Gets the entity this component belongs to.
|
Collision component using a box shape.
Definition at line 12 of file BoxCollisionComponent.h.