Capycore Engine  0.1.0
A simple and lightweight game engine written in C++ based on the Unity API architecture.
Loading...
Searching...
No Matches
physics_creation_flags.h
Go to the documentation of this file.
1#pragma once
2
3#include <cstdint>
4
5constexpr uint16_t default_collision_category = 0x0001;
6constexpr uint16_t default_collision_mask = 0xFFFF;
7
20 bool dynamic{true};
21
27 bool enable_rotation{false};
28
35 bool sensor{false};
36
44
57
65 bool is_bullet{false};
66
75
84
91 float desired_mass{1.0f};
92
99 float friction{0.5f};
100
107 float bounciness{0.5f};
108};
constexpr uint16_t default_collision_category
Definition physics_creation_flags.h:5
constexpr uint16_t default_collision_mask
Definition physics_creation_flags.h:6
Flags for creating physics bodies.
Definition physics_creation_flags.h:14
bool enable_sensor_events
Whether to enable sensor events for the body.
Definition physics_creation_flags.h:56
bool dynamic
Density of the body.
Definition physics_creation_flags.h:20
bool enable_rotation
Whether to enable rotation for the body.
Definition physics_creation_flags.h:27
float friction
Friction coefficient of the body.
Definition physics_creation_flags.h:99
uint16_t mask
Collision mask filtering.
Definition physics_creation_flags.h:83
bool sensor
Whether the body is a sensor.
Definition physics_creation_flags.h:35
uint16_t category
Collision category filtering.
Definition physics_creation_flags.h:74
float desired_mass
Desired mass of the body.
Definition physics_creation_flags.h:91
float bounciness
Bounciness (restitution) of the body.
Definition physics_creation_flags.h:107
bool is_bullet
Whether the body is treated as a bullet.
Definition physics_creation_flags.h:65
bool enable_contact_events
Whether to enable contact events for the body.
Definition physics_creation_flags.h:43