|
virtual void | MmOnAwakeComplete () |
| Post Awake callback used between objects implementing this interface. This allows for initialization steps that must occur before one instance's Awake and its Start. More...
|
|
virtual void | MmOnStartComplete () |
| Post Start callback used between objects implementing this interface This allows for initialization steps that must occur before one instance's Start and its first Update. More...
|
|
void | MmRegisterAwakeCompleteCallback (IMmCallback callback) |
| It is possible that certain handles are not going to be in-place when registration of the OnAwakeComplete callback is invoked. The is especially true in scenarios where MmRelayNodes are networked. This allows for a deferred registration, eliminating most instances where the Awake callback invocations fail. More...
|
|
void | MmRegisterStartCompleteCallback (IMmCallback callback) |
| It is possible that certain handles are not going to be in-place when registration of the OnStartComplete callback is invoked. The is especially true in scenarios where MmRelayNodes are networked. This allows for a deferred registration, eliminating most instances where the Start callback invocations fail. More...
|
|
virtual void | MmInvoke (MmMessageType msgType, MmMessage message, int connectionId=-1) |
| This is the network equivalent of IMmResponder's MmInvoke. The difference is this class allows specification of connectionIDs which can be used to ensure messages are routed to the correct objects on network clients. More...
|
|
virtual void | Awake () |
| Awake gets the MmRelayNode, if one is present. Also calls the post-awake callback. More...
|
|
virtual void | Start () |
| Attempts to register the this responder with the MmNetworkManager. Also calls the post-start callback. More...
|
|
virtual void | MmSendMessageToServer (short msgType, MessageBase msg) |
| Method serializes message and sends it to server. More...
|
|
virtual void | MmSendMessageToClient (int channelId, short msgType, MmMessage msg) |
| Send a message to a specific client over chosen UNET. More...
|
|
virtual void | MmSendMessageToClient (short msgType, MmMessage msg) |
| Send a message to all clients using UNET More...
|
|
virtual void | RegisterToMmNetworkManager () |
|
virtual void | RemoveSelfFromMmNetworkManager () |
|
|
MmRelayNode | MmRelayNode [get] |
| Get a handle to an MmRelayNode that shares the same GameObject. More...
|
|
bool | AllowClientToSend [get] |
| Allows us to stop messages on client from sending. More...
|
|
bool | IsActiveAndEnabled [get] |
| Set when Network Obj is active & enabled. This is important since Objects in UNET scenarios UNET may not be awake/active at the same times. More...
|
|
bool | OnServer [get] |
| Indicates whether the network responder is executing on a server More...
|
|
bool | OnClient [get] |
| Indicates whether the network responder is executing on a client More...
|
|
bool | AllowClientToSend [get] |
| Allows us to stop messages on client from sending. More...
|
|
bool | IsActiveAndEnabled [get] |
| Set when Network Obj is active & enabled. This is important since Objects in UNET scenarios UNET may not be awake/active at the same times. More...
|
|
bool | OnServer [get] |
| Indicates whether the network responder is executing on a server More...
|
|
bool | OnClient [get] |
| Indicates whether the network responder is executing on a client More...
|
|
◆ Awake()
virtual void MercuryMessaging.MmNetworkResponder.Awake |
( |
| ) |
|
|
virtual |
Awake gets the MmRelayNode, if one is present. Also calls the post-awake callback.
◆ MmInvoke()
virtual void MercuryMessaging.MmNetworkResponder.MmInvoke |
( |
MmMessageType |
msgType, |
|
|
MmMessage |
message, |
|
|
int |
connectionId = -1 |
|
) |
| |
|
virtual |
This is the network equivalent of IMmResponder's MmInvoke. The difference is this class allows specification of connectionIDs which can be used to ensure messages are routed to the correct objects on network clients.
- Parameters
-
msgType | Type of message. This specifies the type of the payload. This is important in networked scenarios, when proper deseriaization into the correct type requires knowing what was used to serialize the object originally. |
msg | The message to send. This class builds on UNET's MessageBase so it is Auto [de]serialized by UNET. |
connectionId | Connection ID - use to identify clients. |
Implements MercuryMessaging.IMmNetworkResponder.
◆ MmOnAwakeComplete()
virtual void MercuryMessaging.MmNetworkResponder.MmOnAwakeComplete |
( |
| ) |
|
|
virtual |
Post Awake callback used between objects implementing this interface. This allows for initialization steps that must occur before one instance's Awake and its Start.
Implements MercuryMessaging.IMmNetworkResponder.
◆ MmOnStartComplete()
virtual void MercuryMessaging.MmNetworkResponder.MmOnStartComplete |
( |
| ) |
|
|
virtual |
Post Start callback used between objects implementing this interface This allows for initialization steps that must occur before one instance's Start and its first Update.
Implements MercuryMessaging.IMmNetworkResponder.
◆ MmRegisterAwakeCompleteCallback()
void MercuryMessaging.MmNetworkResponder.MmRegisterAwakeCompleteCallback |
( |
IMmCallback |
callback | ) |
|
It is possible that certain handles are not going to be in-place when registration of the OnAwakeComplete callback is invoked. The is especially true in scenarios where MmRelayNodes are networked. This allows for a deferred registration, eliminating most instances where the Awake callback invocations fail.
- Parameters
-
callback | Callback to be registered. |
Implements MercuryMessaging.IMmNetworkResponder.
◆ MmRegisterStartCompleteCallback()
void MercuryMessaging.MmNetworkResponder.MmRegisterStartCompleteCallback |
( |
IMmCallback |
callback | ) |
|
It is possible that certain handles are not going to be in-place when registration of the OnStartComplete callback is invoked. The is especially true in scenarios where MmRelayNodes are networked. This allows for a deferred registration, eliminating most instances where the Start callback invocations fail.
- Parameters
-
callback | Callback to be registered. |
Implements MercuryMessaging.IMmNetworkResponder.
◆ MmSendMessageToClient() [1/2]
virtual void MercuryMessaging.MmNetworkResponder.MmSendMessageToClient |
( |
int |
channelId, |
|
|
short |
msgType, |
|
|
MmMessage |
msg |
|
) |
| |
|
virtual |
Send a message to a specific client over chosen UNET.
- Parameters
-
channelId | Client connection ID |
msgType | Type of message. This specifies the type of the payload. This is important in networked scenarios, when proper deseriaization into the correct type requires knowing what was used to serialize the object originally. |
msg | The message to send. This utilises UNET's MessageBase so it is Auto [de]serialized by UNET. This also allows us to send messages that are not part of Mercury XM |
◆ MmSendMessageToClient() [2/2]
virtual void MercuryMessaging.MmNetworkResponder.MmSendMessageToClient |
( |
short |
msgType, |
|
|
MmMessage |
msg |
|
) |
| |
|
virtual |
Send a message to all clients using UNET
- Parameters
-
msgType | Type of message. This specifies the type of the payload. This is important in networked scenarios, when proper deseriaization into the correct type requires knowing what was used to serialize the object originally. |
msg | The message to send. This utilises UNET's MessageBase so it is Auto [de]serialized by UNET. This also allows us to send messages that are not part of Mercury XM |
◆ MmSendMessageToServer()
virtual void MercuryMessaging.MmNetworkResponder.MmSendMessageToServer |
( |
short |
msgType, |
|
|
MessageBase |
msg |
|
) |
| |
|
virtual |
Method serializes message and sends it to server.
- Parameters
-
msgType | Type of message. This specifies the type of the payload. This is important in networked scenarios, when proper deseriaization into the correct type requires knowing what was used to serialize the object originally. |
msg | The message to send. This utilises UNET's MessageBase so it is Auto [de]serialized by UNET. This also allows us to send messages that are not part of Mercury XM |
◆ Start()
virtual void MercuryMessaging.MmNetworkResponder.Start |
( |
| ) |
|
|
virtual |
Attempts to register the this responder with the MmNetworkManager. Also calls the post-start callback.
◆ AllowClientToSend
bool MercuryMessaging.MmNetworkResponder.AllowClientToSend |
|
get |
Allows us to stop messages on client from sending.
◆ IsActiveAndEnabled
bool MercuryMessaging.MmNetworkResponder.IsActiveAndEnabled |
|
get |
Set when Network Obj is active & enabled. This is important since Objects in UNET scenarios UNET may not be awake/active at the same times.
◆ MmRelayNode
MmRelayNode MercuryMessaging.MmNetworkResponder.MmRelayNode |
|
get |
Get a handle to an MmRelayNode that shares the same GameObject.
◆ OnClient
bool MercuryMessaging.MmNetworkResponder.OnClient |
|
get |
Indicates whether the network responder is executing on a client
◆ OnServer
bool MercuryMessaging.MmNetworkResponder.OnServer |
|
get |
Indicates whether the network responder is executing on a server
◆ MmAwake
IMmCallback MercuryMessaging.MmNetworkResponder.MmAwake |
Event triggered in the MmNetworkResponder when this object is awoken. Todo: Needs to be swapped for MmAwakeCompleteCallback
◆ MmStart
IMmCallback MercuryMessaging.MmNetworkResponder.MmStart |
Event triggered in the MmNetworkResponder when this object is started. Todo: Needs to be swapped for MmStartCompleteCallback
The documentation for this class was generated from the following file:
- C:/Users/ce223/Documents/Projects/MercuryMessaging/Assets/MercuryMessaging/Protocol/MmNetworkResponder.cs