Component:CharacterController: Difference between revisions

From Resonite Wiki
Automated: update Fields, Categories
fix link, add more info
Line 10: Line 10:
{{Table ComponentFields
{{Table ComponentFields
|SimulatingUser|User| The user who is currently simulating and networking this Character Controller.
|SimulatingUser|User| The user who is currently simulating and networking this Character Controller.
|CharacterRoot|Slot| {{stub}}
|CharacterRoot|Slot| The slot to simulate
|HeadReference|Slot| What the Simulation uses for the capsule height (TODO: is this correct?)
|HeadReference|Slot| What the Simulation uses for the capsule height
|SimulateRotation|Bool|
|SimulateRotation|Bool| Allow the object simulated by this object to rotate, essentially making it a rigid body. See warning.
|MassScaling|PhysicsScalingMode| {{stub}}
|MassScaling|PhysicsScalingMode| {{stub}}
|ForceScaling|PhysicsScalingMode| {{stub}}
|ForceScaling|PhysicsScalingMode| {{stub}}
Line 38: Line 38:
|Gravity|Float3| Force of Gravity for this character controller
|Gravity|Float3| Force of Gravity for this character controller
|GravitySpace|{{RootFieldType|RootSpace}}|TypeAdv28=true|
|GravitySpace|{{RootFieldType|RootSpace}}|TypeAdv28=true|
|DebugVisualDuration|'''[[Type:Nullable`1|Nullable`1]]<[[Type:Float|Float]]>'''|TypeAdv29=true|
|DebugVisualDuration|'''[[Type:Nullable`1|Nullable`1]]<[[Type:Float|Float]]>'''|TypeAdv29=true| Allows for the component to visualize the force vectors acting on the character simulator if set above 0.
|__height|Float| Height of the driven [[CapsuleCollider (Component)]]
|__height|Float| Height of the driven [[CapsuleCollider (Component)]] Currently does nothing.
|__radius|Float| Radius of the driven [[CapsuleCollider (Component)]]
|__radius|Float| Radius of the driven [[CapsuleCollider (Component)]] Currently does nothing.
|__mass|Float| {{stub}}
|__mass|Float| Mass of the of the driven [[CapsuleCollider (Component)]] Currently does nothing.
|__collideWithOtherCharacters|Bool| {{stub}}
|__collideWithOtherCharacters|Bool| Currently does nothing.
|__ignoreRaycasts|Bool| {{stub}}
|__ignoreRaycasts|Bool| Currently does nothing.
|__rootAtBottom|Bool| {{stub}}
|__rootAtBottom|Bool| Currently does nothing.
}}
}}


Line 51: Line 51:
This component is usually used internally by Resonite to simulate user movement physics like walking and climbing.  
This component is usually used internally by Resonite to simulate user movement physics like walking and climbing.  


But the node can also be manipulated to create "Fake Players" commonly known by Resonite users as "NPC's". Before doing this, know that the physics simulation is always inconsistent when viewed by different players in the same session. It also causes high amounts of networking and FPS lag. Use too many and you may start rising in [[Queued Packets]]. The character controller can also be used as a ball, but for things that fly or bounce, using a [[Trajectory Position(ProtoFlux)| Trajectory Position]] ProtoFlux node is vastly superior.
But the node can also be manipulated to create "Fake Players" commonly known by Resonite users as "NPC's". Before doing this, know that the physics simulation is always inconsistent when viewed by different players in the same session. It also causes high amounts of networking and FPS lag. Use too many and you may start rising in [[Queued Packets]]. The character controller can also be used as a ball, but for things that fly or bounce, using a [[ProtoFlux:Trajectory Position| Trajectory Position]] ProtoFlux node is vastly superior.
{{stub}}
{{stub}}
<!--T:4-->
== Examples ==


A Shrike NPC running around the cloud home:
A Shrike NPC running around the cloud home:
Line 58: Line 61:
[[File:Example_Of_A_CharacterController_NPC.webp|200px|A 4 foot tall Avali NPC with the likeness of a user named Shrike, running in the Resonite Default Cloud Home. It is set to Nighttime and the NPC is near the Reading Nook running towards it.]]
[[File:Example_Of_A_CharacterController_NPC.webp|200px|A 4 foot tall Avali NPC with the likeness of a user named Shrike, running in the Resonite Default Cloud Home. It is set to Nighttime and the NPC is near the Reading Nook running towards it.]]
<br>
<br>
<!--T:4-->
== Examples ==
{{stub}}


[[Category:ComponentStubs]]
[[Category:ComponentStubs]]
[[Category:Components:Physics{{#translation:}}|Character Controller]]
[[Category:Components:Physics{{#translation:}}|Character Controller]]
[[Category:Components{{#translation:}}|Character Controller]]
[[Category:Components{{#translation:}}|Character Controller]]

Revision as of 20:24, 19 March 2024


This article or section is a Stub. You can help the Resonite Wiki by expanding it.


Component image 
Character Controller component as seen in the Scene Inspector


Fields

Fields
Name Type Description
persistent Bool Determines whether or not this item will be saved to the server.
UpdateOrder Int Controls the order in which this component is updated.
Enabled Bool Controls whether or not this component is enabled.
SimulatingUser User The user who is currently simulating and networking this Character Controller.
CharacterRoot Slot The slot to simulate
HeadReference Slot What the Simulation uses for the capsule height
SimulateRotation Bool Allow the object simulated by this object to rotate, essentially making it a rigid body. See warning.
MassScaling PhysicsScalingMode This article or section is a Stub. You can help the Resonite Wiki by expanding it.
ForceScaling PhysicsScalingMode This article or section is a Stub. You can help the Resonite Wiki by expanding it.
SpeedScaling PhysicsScalingMode This article or section is a Stub. You can help the Resonite Wiki by expanding it.
JumpScaling PhysicsScalingMode This article or section is a Stub. You can help the Resonite Wiki by expanding it.
GravityScaling PhysicsScalingMode This article or section is a Stub. You can help the Resonite Wiki by expanding it.
LinearDamping Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
AngularDamping Float
Margin Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
StepUpHeight Float
StepUpCheckDistance Float
KillVerticalVelocityAfterStepUp Bool
EdgeDetectionDepth Float
Speed Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
SlidingSpeed Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
AirSpeed Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
TractionForce Float How much force is needed to overcome standing friction.
SlidingForce Float How much friction force is applied while the CharacterController is moving.
AirForce Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
MaximumGlueForce Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
MaximumTractionSlope Float Maximum Traction value before user slides down a slope.

This article or section is a Stub. You can help the Resonite Wiki by expanding it.

MaximumSupportSlope Float Maximum Support value before user slides down a slope.

This article or section is a Stub. You can help the Resonite Wiki by expanding it.

JumpSpeed Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
SlidingJumpSpeed Float This article or section is a Stub. You can help the Resonite Wiki by expanding it.
Gravity Float3 Force of Gravity for this character controller
GravitySpace direct RootSpace
DebugVisualDuration Nullable`1<Float> Allows for the component to visualize the force vectors acting on the character simulator if set above 0.
__height Float Height of the driven CapsuleCollider (Component) Currently does nothing.
__radius Float Radius of the driven CapsuleCollider (Component) Currently does nothing.
__mass Float Mass of the of the driven CapsuleCollider (Component) Currently does nothing.
__collideWithOtherCharacters Bool Currently does nothing.
__ignoreRaycasts Bool Currently does nothing.
__rootAtBottom Bool Currently does nothing.

Usage

This component is usually used internally by Resonite to simulate user movement physics like walking and climbing.

But the node can also be manipulated to create "Fake Players" commonly known by Resonite users as "NPC's". Before doing this, know that the physics simulation is always inconsistent when viewed by different players in the same session. It also causes high amounts of networking and FPS lag. Use too many and you may start rising in Queued Packets. The character controller can also be used as a ball, but for things that fly or bounce, using a Trajectory Position ProtoFlux node is vastly superior.

This article or section is a Stub. You can help the Resonite Wiki by expanding it.


Examples

A Shrike NPC running around the cloud home:

A 4 foot tall Avali NPC with the likeness of a user named Shrike, running in the Resonite Default Cloud Home. It is set to Nighttime and the NPC is near the Reading Nook running towards it.