internal void SetCharacterInput(BepuUtilities.Memory.BufferPool bufferpool, int bodyHandle, Simulation simulation) { characterControllers = new Demos.Demos.Characters.CharacterControllers(bufferpool); collider.bodyHandle = bodyHandle; characterInput = new CharacterInput(characterControllers, bodyHandle, simulation, this.Position, new Capsule(0.5f, 1), 0.1f, 1, 20, 100, 6, 4, MathF.PI * 0.4f); }
internal CharacterInput(Demos.Demos.Characters.CharacterControllers characters, int bodyHandle, Simulation simulation, System.Numerics.Vector3 initialPosition, Capsule shape, float speculativeMargin, float mass, float maximumHorizontalForce, float maximumVerticalGlueForce, float jumpVelocity, float speed, float maximumSlope = MathF.PI * 0.25f) { this.bodyHandle = bodyHandle; this.Simulation = simulation; this.characters = characters; ref var character = ref characters.AllocateCharacter(bodyHandle);