Custom Events
ObjectNet allows developers to create, listen, and send custom events managed by NetworkEventsManager.
NetworkEventsManager allows users to create customized events to catch the specific events of their game.

You can find a full example of how to implement custom events on "16 - Global Events" scene.
Registering Event
To register a new event you need to select NetworkEventsManager and click on Event Editor button.

A new Events Database window shall appear :

Fill the event name and press "Register Event"

A new event shall appear on events list.

Each event will have its own unique code, this code is an Integer that is used to identify events over the network.
User Event
User Event is the way to NetworkEventsManager allows the user to listen when some custom event arrives.
Select the event that you wish to listen to and click on "Register event to listen".

The selected event will be registered.

Now you need to select the action to take when this event arrives.

You can find a full example of how to implement custom events on "16 - Custom Events" scene. In this scene, you will find scripts and objects to clarify how to implement your own custom events.

User Actions
User Action is how NetworkEventsManager allows the user to send vents when some status is reached.
Fill in the action name and click on "Register Action" button.

The action will be registered on the User Actions list.

The first to do is select which event you wish to send when action is triggered.

The next step is to decide when you wish to trigger this event, the possible values can be found on ActionExecutionMode ( see API ).

Now you need to assign the object and component to watch, this component must be a component that exists in scene .

Now you to fill the expression that will be evaluated to check if this condition matches with the selected on ActionExecutionMode.
On this part you can select component ( script ) attributes or function witch return allowed types. The system will evaluate this condition on each execution frame to check if condition is reached.

The last step ( when applicable ) is define witch values will be included on message when the selected event was send.

Those values will be included on event when ObjectNet send it over network, and must be read when message arrives.
You can found a full example about how to implement custom events on "16 - Custom Events" scene. On this scene you will find scripts and objects to clarify how implement you own custom events.
