NetworkState
Contains or links to all network-related data for a specific World.
Unless otherwise specified, all functions in this class are only to be called from the network configurator context.
Properties
A sequence of all ProtoNetworks.
Functions
Tries to connect endPoint to bridge from face over networkType, adding all ProtoNetworks whose clusters need to be enlarged with endPoint to clustersToEnlarge.
Connects endPoint to other from face over networkType and adds the new ProtoNetwork to clustersToInit.
Creates a new ProtoNetwork with the given type and a random UUID.
Disconnects endPoint from bridge at face over networkType, adding all ProtoNetworks whose clusters need to be reinitialized to clustersToInit.
Disconnects endPoint from other at face over networkType, adding all ProtoNetworks whose clusters need to be reinitialized to clustersToInit.
Iterates over all NetworkNodes connected to node, calling action for each connection. The action parameters describe using which NetworkType and through wich BlockFace the NetworkNode is connected. Some NetworkNodes may be connected through multiple NetworkTypes.
Iterates over all NetworkNodes connected to node using networkType, calling action for each connection. The action parameters describe through wich BlockFace the NetworkNode is connected.
Iterates over all networks of endPoint, calling action for each network. The action parameters describe with which NetworkType and through which BlockFace the endPoint is connected to the given ProtoNetwork.
Iterates over all networkType networks of endPoint, calling action for each network. The action parameters describe through which BlockFace the endPoint is connected to the given ProtoNetwork.
Gets a set of allowed BlockFaces with which bridge is allowed to connect to Networks of the given type, which are all supported faces if the NetworkBridge supports the NetworkType.
Computes a set of allowed BlockFaces with which endPoint is allowed to connect to Networks of the given type. Will be empty if the NetworkEndPoint does not contain all required holder types.
Gets the NetworkBridgeData for bridge, or throws an exception if there is no data.
Gets the allowed faces for bridge.
Gets the NetworkNode connected to node at face, or null
if there is no connection.
Gets the NetworkNode connected to node at face using networkType, or null
if there is no connection.
Creates a table that describes using which NetworkType and BlockFace which NetworkNodes are connected to node.
Gets the NetworkEndPointData for endPoint, or throws an exception if there is no data.
Finds all nearby NetworkNodes of pos using the given faces.
Gets the network of bridge of networkType, or null
if there is no connection.
Gets the ProtoNetwork with the given networkId and type, or throws an exception if no such network exists.
Gets the NetworkNodeData for pos, potentially loading the corresponding network region if necessary and throws an exception if there is no data.
Gets all network node data for the given pos.
Gets the NetworkNodeData for node, or throws an exception if there is no data.
Gets or creates a ProtoNetwork with the given type and networkId.
Gets the supported network types for bridge.
Performs network connect/disconnect actions based on the new allowed faces of endPoint for networkType at face.
Checks whether node has a connection at face using networkType.
Forgets a connection of node at face using networkType.
Forgets the connection of bridge to the network of networkType.
Forgets the connection of endPoint to the network of networkType at all faces.
Forgets the connection of endPoint to the network of networkType at face.
Removes the data for node.
Resolves a NetworkNode by its pos.
Remembers a connection of node at face using networkType.
Remembers the connection of bridge to network under ProtoNetwork.type.