Antkeeper
0.0.1
|
Maintains a spatially partitioned set of collision meshes. More...
#include <collision-system.hpp>
Public Member Functions | |
collision_system (entity::registry ®istry) | |
~collision_system () | |
virtual void | update (float t, float dt) |
Perform's a system's update() function. More... | |
entity::id | pick_nearest (const geom::ray< float, 3 > &ray, std::uint32_t flags) const |
Picks the nearest entity with the specified picking flags that intersects a ray. More... | |
entity::id | pick_nearest (const math::fvec3 &origin, const math::fvec3 &normal, std::uint32_t flags) const |
Picks the nearest entity with the specified picking flags that has a non-negative distance from a plane. More... | |
![]() | |
updatable_system (entity::registry ®istry) | |
Creates an updatable system. More... | |
Additional Inherited Members | |
![]() | |
entity::registry & | registry |
Registry on which the system operate. More... | |
Maintains a spatially partitioned set of collision meshes.
Definition at line 31 of file collision-system.hpp.
|
explicit |
Definition at line 29 of file collision-system.cpp.
collision_system::~collision_system | ( | ) |
Definition at line 34 of file collision-system.cpp.
entity::id collision_system::pick_nearest | ( | const geom::ray< float, 3 > & | ray, |
std::uint32_t | flags | ||
) | const |
Picks the nearest entity with the specified picking flags that intersects a ray.
ray | Picking ray. |
flags | Picking flags. |
entt::null
if no entity was picked. Definition at line 43 of file collision-system.cpp.
entity::id collision_system::pick_nearest | ( | const math::fvec3 & | origin, |
const math::fvec3 & | normal, | ||
std::uint32_t | flags | ||
) | const |
Picks the nearest entity with the specified picking flags that has a non-negative distance from a plane.
origin | Origin of the picking plane. |
normal | Picking plane normal direction. |
flags | Picking flags. |
entt::null
if no entity was picked. Definition at line 83 of file collision-system.cpp.
|
virtual |
Perform's a system's update() function.
t | Total elapsed time, in seconds. |
dt | Delta time, in seconds. |
Implements updatable_system.
Definition at line 38 of file collision-system.cpp.