mirror of
https://github.com/ahwootech/BRUTAL.git
synced 2026-11-26 04:58:24 +01:00
323 lines
14 KiB
C#
323 lines
14 KiB
C#
// <auto-generated/>
|
|
// Generated by Brutal.Jolt.Generate; do not edit by hand.
|
|
#nullable enable
|
|
|
|
using Brutal.Interop;
|
|
using Brutal.Numerics;
|
|
namespace Brutal.JoltApi
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L53">Jolt/Physics/Character/CharacterBase.h:53</see>
|
|
/// <br/>
|
|
/// <c>class CharacterBase : public RefTarget<CharacterBase>, public NonCopyable</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Base class for character class
|
|
/// </para>
|
|
/// </remarks>
|
|
[InteropHandle]
|
|
public readonly partial struct CharacterBase : IDisposable
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L83">Jolt/Physics/Character/CharacterBase.h:83</see>
|
|
/// <br/>
|
|
/// <c>enum class EGroundState</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public enum EGroundState : int
|
|
{
|
|
/// <summary>
|
|
/// <para>
|
|
/// Character is on the ground and can move freely.
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L85">Jolt/Physics/Character/CharacterBase.h:85</see>
|
|
/// <br/>
|
|
/// <c>OnGround</c>
|
|
/// </para>
|
|
/// </summary>
|
|
OnGround,
|
|
/// <summary>
|
|
/// <para>
|
|
/// Character is on a slope that is too steep and can't climb up any further. The caller should start
|
|
/// applying downward velocity if sliding from the slope is desired.
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L86">Jolt/Physics/Character/CharacterBase.h:86</see>
|
|
/// <br/>
|
|
/// <c>OnSteepGround</c>
|
|
/// </para>
|
|
/// </summary>
|
|
OnSteepGround,
|
|
/// <summary>
|
|
/// <para>
|
|
/// Character is touching an object, but is not supported by it and should fall. The GetGroundXXX
|
|
/// functions will return information about the touched object.
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L87">Jolt/Physics/Character/CharacterBase.h:87</see>
|
|
/// <br/>
|
|
/// <c>NotSupported</c>
|
|
/// </para>
|
|
/// </summary>
|
|
NotSupported,
|
|
/// <summary>
|
|
/// <para>
|
|
/// Character is in the air and is not touching anything.
|
|
/// </para>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L88">Jolt/Physics/Character/CharacterBase.h:88</see>
|
|
/// <br/>
|
|
/// <c>InAir</c>
|
|
/// </para>
|
|
/// </summary>
|
|
InAir,
|
|
}
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L59">Jolt/Physics/Character/CharacterBase.h:59</see>
|
|
/// <br/>
|
|
/// <c>CharacterBase(const CharacterBaseSettings *inSettings, PhysicsSystem *inSystem)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Constructor
|
|
/// </para>
|
|
/// </remarks>
|
|
public static CharacterBase Create(CharacterBaseSettings settings, PhysicsSystem system) => Jolt.PInvoke.CharacterBase_Create(settings, system);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L65">Jolt/Physics/Character/CharacterBase.h:65</see>
|
|
/// <br/>
|
|
/// <c>void SetMaxSlopeAngle(float inMaxSlopeAngle)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Set the maximum angle of slope that character can still walk on (radians)
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetMaxSlopeAngle(float maxSlopeAngle) => Jolt.PInvoke.CharacterBase_SetMaxSlopeAngle(this, maxSlopeAngle);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L66">Jolt/Physics/Character/CharacterBase.h:66</see>
|
|
/// <br/>
|
|
/// <c>float GetCosMaxSlopeAngle() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public float GetCosMaxSlopeAngle() => Jolt.PInvoke.CharacterBase_GetCosMaxSlopeAngle(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L69">Jolt/Physics/Character/CharacterBase.h:69</see>
|
|
/// <br/>
|
|
/// <c>void SetUp(Vec3Arg inUp)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Set the up vector for the character
|
|
/// </para>
|
|
/// </remarks>
|
|
public void SetUp(float3 up) => Jolt.PInvoke.CharacterBase_SetUp(this, up);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L70">Jolt/Physics/Character/CharacterBase.h:70</see>
|
|
/// <br/>
|
|
/// <c>Vec3 GetUp() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
public float3 GetUp() => Jolt.PInvoke.CharacterBase_GetUp(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L73">Jolt/Physics/Character/CharacterBase.h:73</see>
|
|
/// <br/>
|
|
/// <c>bool IsSlopeTooSteep(Vec3Arg inNormal) const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Check if the normal of the ground surface is too steep to walk on
|
|
/// </para>
|
|
/// </remarks>
|
|
public bool IsSlopeTooSteep(float3 normal) => Jolt.PInvoke.CharacterBase_IsSlopeTooSteep(this, normal);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L81">Jolt/Physics/Character/CharacterBase.h:81</see>
|
|
/// <br/>
|
|
/// <c>const Shape * GetShape() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Get the current shape that the character is using.
|
|
/// </para>
|
|
/// </remarks>
|
|
public Shape GetShape() => Jolt.PInvoke.CharacterBase_GetShape(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L92">Jolt/Physics/Character/CharacterBase.h:92</see>
|
|
/// <br/>
|
|
/// <c>static const char * sToString(EGroundState inState)</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Debug function to convert enum values to string
|
|
/// </para>
|
|
/// </remarks>
|
|
public static unsafe RefString8 sToString(CharacterBase.EGroundState state) => (Ptr<byte>)Jolt.PInvoke.CharacterBase_sToString(state);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L97">Jolt/Physics/Character/CharacterBase.h:97</see>
|
|
/// <br/>
|
|
/// <c>EGroundState GetGroundState() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Current ground state
|
|
/// </para>
|
|
/// </remarks>
|
|
public CharacterBase.EGroundState GetGroundState() => Jolt.PInvoke.CharacterBase_GetGroundState(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L100">Jolt/Physics/Character/CharacterBase.h:100</see>
|
|
/// <br/>
|
|
/// <c>bool IsSupported() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Returns true if the player is supported by normal or steep ground
|
|
/// </para>
|
|
/// </remarks>
|
|
public bool IsSupported() => Jolt.PInvoke.CharacterBase_IsSupported(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L103">Jolt/Physics/Character/CharacterBase.h:103</see>
|
|
/// <br/>
|
|
/// <c>RVec3 GetGroundPosition() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Get the contact point with the ground
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetGroundPosition() => Jolt.PInvoke.CharacterBase_GetGroundPosition(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L106">Jolt/Physics/Character/CharacterBase.h:106</see>
|
|
/// <br/>
|
|
/// <c>Vec3 GetGroundNormal() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Get the contact normal with the ground
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetGroundNormal() => Jolt.PInvoke.CharacterBase_GetGroundNormal(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L109">Jolt/Physics/Character/CharacterBase.h:109</see>
|
|
/// <br/>
|
|
/// <c>Vec3 GetGroundVelocity() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Velocity in world space of ground
|
|
/// </para>
|
|
/// </remarks>
|
|
public float3 GetGroundVelocity() => Jolt.PInvoke.CharacterBase_GetGroundVelocity(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L112">Jolt/Physics/Character/CharacterBase.h:112</see>
|
|
/// <br/>
|
|
/// <c>const PhysicsMaterial * GetGroundMaterial() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Material that the character is standing on
|
|
/// </para>
|
|
/// </remarks>
|
|
public PhysicsMaterial GetGroundMaterial() => Jolt.PInvoke.CharacterBase_GetGroundMaterial(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L115">Jolt/Physics/Character/CharacterBase.h:115</see>
|
|
/// <br/>
|
|
/// <c>BodyID GetGroundBodyID() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// BodyID of the object the character is standing on. Note may have been removed!
|
|
/// </para>
|
|
/// </remarks>
|
|
public uint GetGroundBodyID() => Jolt.PInvoke.CharacterBase_GetGroundBodyID(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L118">Jolt/Physics/Character/CharacterBase.h:118</see>
|
|
/// <br/>
|
|
/// <c>SubShapeID GetGroundSubShapeID() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// Sub part of the body that we're standing on.
|
|
/// </para>
|
|
/// </remarks>
|
|
public uint GetGroundSubShapeID() => Jolt.PInvoke.CharacterBase_GetGroundSubShapeID(this);
|
|
/// <summary>
|
|
/// <para>
|
|
/// C++:
|
|
/// <see href="https://github.com/jrouwe/JoltPhysics/blob/23dadd0e603f1b321142d4c74df07fce85064989/Jolt/Physics/Character/CharacterBase.h#L121">Jolt/Physics/Character/CharacterBase.h:121</see>
|
|
/// <br/>
|
|
/// <c>uint64 GetGroundUserData() const</c>
|
|
/// </para>
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// <para>
|
|
/// User data value of the body that we're standing on
|
|
/// </para>
|
|
/// </remarks>
|
|
public ulong GetGroundUserData() => Jolt.PInvoke.CharacterBase_GetGroundUserData(this);
|
|
public void AddRef() => Jolt.PInvoke.CharacterBase_AddRef(this);
|
|
public void Release() => Jolt.PInvoke.CharacterBase_Release(this);
|
|
public uint GetRefCount() => Jolt.PInvoke.CharacterBase_GetRefCount(this);
|
|
public void Dispose()
|
|
{
|
|
if (IsNull()) return;
|
|
Release();
|
|
}
|
|
}
|
|
}
|