Events

Events are Bolt's way of setting up a RPC-like call over the network.

Global events can be both Reliable and Unreliable by passing in different parameters to the Create method. In general most global events will be Reliable and that is also the default if you don't pass in anything to change it. Global events are intended for things that exist around the game like dealing with authentication or handling stuff like player inventories, etc.

Entity events are always Unreliable, they are intended for small one-off effects like showing a damage indicator or maybe playing an explosion, things that are ephemeral and if one player misses it it doesn't matter.

Calling a global event

Calling an entity event (entity events are unreliable):

Receiving an event:

Make sure your script inherits from either:

Bolt.GlobalEventListener
or

Bolt.EntityEventListener / Bolt.EntityEventListener

(Note: These inherit from Bolt.EntityBehaviour already)

Then, to receive an event:

 To Document Top