Engine²
Open-source game engine written in C++.
Loading...
Searching...
No Matches
CharacterControllerInternal.hpp
Go to the documentation of this file.
1#pragma once
2
3// clang-format off
4#include <Jolt/Jolt.h>
5// clang-format on
6
7#include <Jolt/Physics/Character/CharacterVirtual.h>
8
9namespace Physics::Component {
10
16 JPH::Ref<JPH::CharacterVirtual> character;
17
20
23 explicit CharacterControllerInternal(JPH::CharacterVirtual *inCharacter) : character(inCharacter) {}
24
26 [[nodiscard]] bool IsValid() const { return character != nullptr; }
27};
28
29} // namespace Physics::Component
Definition BoxCollider.hpp:27
bool IsValid() const
Check whether the internal character is valid.
Definition CharacterControllerInternal.hpp:26
CharacterControllerInternal(JPH::CharacterVirtual *inCharacter)
Construct with an existing CharacterVirtual.
Definition CharacterControllerInternal.hpp:23
JPH::Ref< JPH::CharacterVirtual > character
Jolt virtual character (reference-counted, null until constructed).
Definition CharacterControllerInternal.hpp:16
CharacterControllerInternal()=default
Default constructor.