Next: , Previous: , Up: Interaction.Output   [Contents][Index]


9.2.6 MessageRelay

Component: MessageRelay

This component sends a list of messages when receiving the ’Relay’ message. You can attach this to a child object (appropriately named) and use it as a logic gate, or just expand the reach of other message senders based on context.

To use, populate the list of ’Messages’ above with what ever you’d like to send to other objects or components. Then attach a Message sender of some kind to another object, possibly this object’s parent. When this component receives ’Relay’ it will send all of the messages in the list. To write a message in a script, simply implement a new method as such: public void MyNewMessage( ) The message you implement may have 0 arguments, or it may take an integer, float, bool, or string. This will tell MultiGame to add it to the Messages list when you hit ’Refresh Messages’. Any method that fits the argument types may be called, even if it does not appear, by locking the message sender and then typing in the method name manually. When you do this, MultiGame will turn the message box cyan to indicate that you’re sending a custom message.

Field of MessageRelay: List<MessageManager.ManagedMessage> messages

List of messages we will send

Default value: new List<MessageManager.ManagedMessage>()

Message on MessageRelay: Relay ()

Activates this Message Relay, sending all ’Messages’

Field of MessageRelay: List<MessageManager.ManagedMessage> messages

List of messages we will send

Default value: new List<MessageManager.ManagedMessage>()

Message on MessageRelay: Relay ()

Activates this Message Relay, sending all ’Messages’


Next: , Previous: , Up: Interaction.Output   [Contents][Index]