|
Tramway SDK v0.1.1
|
Namespaces | |
| namespace | API |
| Physics backend API. | |
Classes | |
| struct | Collision |
| Physics collision data. More... | |
| class | CollisionModel |
| Physics CollisionShape model. More... | |
| struct | CollisionShape |
| Shape for a collider. More... | |
| struct | collisionshape_t |
| struct | CollisionTriangle |
| class | PathAction |
| struct | rigidbody_t |
| struct | trigger_t |
Enumerations | |
| enum | Shape : uint32_t { SHAPE_SPHERE , SHAPE_CYLINDER , SHAPE_CAPSULE , SHAPE_CONE , SHAPE_BOX , SHAPE_HULL , SHAPE_MESH } |
| enum | CollisionGroup : uint32_t { COLL_WORLDOBJ = 2 , COLL_STATICOBJ = 4 , COLL_DYNAMICOBJ = 8 , COLL_TRIGGER = 16 , COLL_PLAYER = 32 , COLL_MONSTER = 64 , COLL_VEHICLE = 128 } |
Functions | |
| void | Init () |
| Initializes the physics system. More... | |
| void | Update () |
| Updates the physics system. More... | |
| Collision | Raycast (const vec3 &from, const vec3 &to, uint32_t collision_mask) |
| Performs a raycast. More... | |
| std::vector< Collision > | Shapecast (const CollisionShape &shape, const vec3 &from, const vec3 &to, uint32_t collision_mask) |
| I have no idea if this function works. (yes it does) More... | |
| enum tram::Physics::CollisionGroup : uint32_t |
| enum tram::Physics::Shape : uint32_t |
| void tram::Physics::Init | ( | ) |
Initializes the physics system.
Performs a raycast.
Performs a raycast from from to to.
| std::vector< Collision > tram::Physics::Shapecast | ( | const CollisionShape & | shape, |
| const vec3 & | from, | ||
| const vec3 & | to, | ||
| uint32_t | collision_mask | ||
| ) |
I have no idea if this function works. (yes it does)
| void tram::Physics::Update | ( | ) |
Updates the physics system.
Should only be called once in the update cycle.