mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
add 'static' entity body-type
This commit is contained in:
parent
d6696b54cb
commit
2b7b68f3c2
7 changed files with 8 additions and 18 deletions
|
|
@ -411,7 +411,7 @@ void Entities::updatePhysics(float delta) {
|
|||
auto view = registry.view<EntityId, Transform, Rigidbody>();
|
||||
auto physics = level->physics.get();
|
||||
for (auto [entity, eid, transform, rigidbody] : view.each()) {
|
||||
if (!rigidbody.enabled) {
|
||||
if (!rigidbody.enabled || rigidbody.hitbox.type == BodyType::STATIC) {
|
||||
continue;
|
||||
}
|
||||
auto& hitbox = rigidbody.hitbox;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue