Enfusion Script API
Loading...
Searching...
No Matches
WorldController Interface Reference
Inheritance diagram for WorldController:
EventProvider ScriptAndConfig Managed DialogueController PlayerNameInputController RplSchedulerDebugController

Public Member Functions

proto external World GetWorld ()
 
proto external WorldSystems GetSystems ()
 
proto external RplNode GetNode ()
 
proto external bool IsMyOwn ()
 
proto external PlayerId GetOwnerPlayerId ()
 Returns PlayerId of the player who owns this controller.
 
proto external UUID GetOwnerIdentityId ()
 Returns Identity Id of the player who owns this controller.
 
proto external RplIdentity GetOwnerRplIdentity ()
 Returns RplIdentity of the player who owns this controller if it is available.
 
proto external WorldSystem FindSystem (TypeName interfaceType)
 
proto external BaseContainer FindSystemSource (TypeName interfaceType)
 
- Public Member Functions inherited from Managed
proto external ref Managed Clone ()
 Return shallow copy of object, or null if it is not allowed (not public constructor)
 

Static Public Member Functions

static void InitInfo (WorldControllerInfo outInfo)
 
- Static Public Member Functions inherited from EventProvider
static proto bool ConnectEvent (func eventSender, func eventReceiver)
 Connects receiver callback to provider event.
 
static proto bool ConnectEventFiltered (func eventSender, func eventReceiver, void filter)
 Connects receiver callback to provider event.
 
static proto bool DisconnectEvent (func eventSender, func eventReceiver)
 Disconnect single event connection.
 
static proto bool DisconnectEventFiltered (func eventSender, func eventReceiver, void filter)
 Disconnect single event connection.
 
static proto bool DisconnectEvents (EventProvider provider, Managed receiver)
 Disconnect all connections between provider and receiver.
 

Protected Member Functions

proto void Rpc (func method, void p0=NULL, void p1=NULL, void p2=NULL, void p3=NULL, void p4=NULL, void p5=NULL, void p6=NULL, void p7=NULL)
 Attempts to run a remote procedure call (RPC) of this instance with parameters specified in method RplRpc attribute.
 
void OnAuthorityReady ()
 
void OnAuthorityClosing ()
 
- Protected Member Functions inherited from EventProvider
proto external void ThrowEvent (func eventSender, void param1=null, void param2=null, void param3=null, void param4=null, void param5=null, void param6=null, void param7=null, void param8=null, void param9=null)
 Emit event on provider.
 

Member Function Documentation

◆ FindSystem()

proto external WorldSystem WorldController.FindSystem ( TypeName interfaceType)

◆ FindSystemSource()

proto external BaseContainer WorldController.FindSystemSource ( TypeName interfaceType)

◆ GetNode()

proto external RplNode WorldController.GetNode ( )

◆ GetOwnerIdentityId()

proto external UUID WorldController.GetOwnerIdentityId ( )

Returns Identity Id of the player who owns this controller.

This function will return correct player identifier when called both on client and on server.

◆ GetOwnerPlayerId()

proto external PlayerId WorldController.GetOwnerPlayerId ( )

Returns PlayerId of the player who owns this controller.

This function will return correct player identifier when called both on client and on server.

◆ GetOwnerRplIdentity()

proto external RplIdentity WorldController.GetOwnerRplIdentity ( )

Returns RplIdentity of the player who owns this controller if it is available.

As RplIdentity is specific to each Replication instance, this function may return different values for different instances of the same controller. In other words, controller of particular player will return different identity depending on its role (authority or proxy). Specifically:

  • authority always returns RplIdentity of player who owns the controller (on listen server, it returns RplIdentity::Local() for local player)
  • proxy returns RplIdentity::Local() when it belongs to local player
  • proxy returns RplIdentity::Invalid() when it does not belong to local player
Returns
RplIdentity representing player who owns the controller on this Replication instance, or invalid identity when this player cannot be addressed from this Replication instance.

◆ GetSystems()

proto external WorldSystems WorldController.GetSystems ( )

◆ GetWorld()

proto external World WorldController.GetWorld ( )

◆ InitInfo()

static void WorldController.InitInfo ( WorldControllerInfo outInfo)
static

Implemented in PlayerNameInputController.

◆ IsMyOwn()

proto external bool WorldController.IsMyOwn ( )

◆ OnAuthorityClosing()

void WorldController.OnAuthorityClosing ( )
protected

◆ OnAuthorityReady()

void WorldController.OnAuthorityReady ( )
protected

Implemented in PlayerNameInputController.

◆ Rpc()

proto void WorldController.Rpc ( func method,
void p0 = NULL,
void p1 = NULL,
void p2 = NULL,
void p3 = NULL,
void p4 = NULL,
void p5 = NULL,
void p6 = NULL,
void p7 = NULL )
protected

Attempts to run a remote procedure call (RPC) of this instance with parameters specified in method RplRpc attribute.

Parameters
methodMember function to be invoked as an RPC.

The documentation for this interface was generated from the following file: