VisuTwin Canvas
C++ 3D Engine — Metal Backend
Loading...
Searching...
No Matches
rigidBodyComponent.cpp
Go to the documentation of this file.
1// SPDX-License-Identifier: Apache-2.0
2// Copyright 2025-2026 Arnis Lektauers
4
6#include "framework/entity.h"
7
8namespace visutwin::canvas
9{
15
17 {
18 std::erase(_instances, this);
19 }
20
21 void RigidBodyComponent::setType(const std::string& type)
22 {
23 if (type == "dynamic") {
25 } else if (type == "kinematic") {
27 } else {
29 }
30 }
31
36}
Entity * entity() const
Definition component.cpp:16
Component(IComponentSystem *system, Entity *entity)
Definition component.cpp:12
IComponentSystem * system() const
Definition component.h:47
ECS entity — a GraphNode that hosts components defining its behavior.
Definition entity.h:32
void setType(const RigidBodyType type)
RigidBodyComponent(IComponentSystem *system, Entity *entity)
CollisionComponent * collision() const