ParelVRDocs
Player site

Scripting / Reference

Instance

Types in the ParelVR.Volt.Instance namespace.

VoltInstance#

ParelVR.Volt.Instance.VoltInstance static

The running copy of the world that the local player is in.

VoltInstance properties#

static VoltPlayer Authority { get; }

The player with authority over shared state that has no owner. In ParelVR this is the master.

static string[] BannedNames { get; }

Names of the players banned from this instance.

static int Capacity { get; }

Most players the instance accepts.

static string InstanceId { get; }

Id of this instance.

static VoltPlayer LocalPlayer { get; }

The player on this client.

static VoltPlayer Master { get; }

The instance master: the player who decides when several clients could.

static int PlayerCount { get; }

Number of players in the instance, in every subroom.

static VoltInstancePrivacy Privacy { get; }

Who can join the instance.

static string WorldId { get; }

Id of the world this is an instance of.

VoltInstance methods#

static void Ban(VoltPlayer player)

Kicks a player and keeps them out for as long as the instance lives. Master only.

static string GetProperty(string key)

A property of the instance, such as "region" or "name". Empty when there is no such property.

static bool IsBanned(VoltPlayer player)

True when the player is banned from this instance.

static void Kick(VoltPlayer player)

Sends a player out of the instance; their client goes back to the hub. Master only.

static void Unban(string displayName)

Lets a banned player back in, by the name they had when banned. Master only.

VoltInstancePrivacy#

ParelVR.Volt.Instance.VoltInstancePrivacy enum

Who can join an instance.

Values: Unknown, Public, FriendsPlus, Friends, InvitePlus, Invite, Group