PlayModeRigManager

csharp
public sealed class PlayModeRigManager : MonoBehaviour, IFluxLocalPlayer

Namespace NodeWorld.SDK.Client.PlayMode.

The player of a world's Play mode: the rig of the client (SDKConfig.XRRigPrefab) with the default avatar, driven by the headset, or without one (or with NWWorldRef.ForceDesktopInPlayMode) by the desktop controls of the client. The world plays as in the client: same locomotion, gravity, avatar, interactions and mirrors.

Properties

Controller

csharp
public IPlayerController Controller { get; }

The local player's rig.

AvatarRig

csharp
public NWFullBodyAvatarRig AvatarRig { get; }

The IK rig of the local avatar, or null.

Controls

csharp
public NWPlayerControls Controls { get; }

What the world sets on the local player's locomotion.

Language

csharp
public string Language { get; }

The language of the system (en or fr).

Methods

TryGetBone

csharp
public bool TryGetBone(int syncedBone, out Vector3 position, out Quaternion rotation)

World position and rotation of a synced bone of the local avatar; false when it has none.

Respawn

csharp
public void Respawn()

Brings the local player back to the spawn point.

Initialize

csharp
public void Initialize(NWWorldRef worldRef, SDKConfig sdkConfig)

Creates the player rig of Play mode at the world's spawn point, with the SDK's settings.

Shutdown

csharp
public void Shutdown()

Removes the rig.

Events

LanguageChanged

csharp
public event System.Action LanguageChanged

Never raised in Play mode.

Respawned

csharp
public event System.Action Respawned

Raised when the local player respawns.