Learn / Documentation / Script Reference / GameEventMessage
Manual

GameEventMessage

class in Doozy.Engine / Inherits from Message

Description

The GameEventMessage is a Game Event global Message
See Also: Message

Properties

  • public bool HasCustomObject – Returns TRUE if this message contains a reference to a custom Object

  • public bool HasGameEvent – Returns TRUE if this message contains a game event string. If FALSE, then this message was used only to send a GameObject reference.

  • public bool HasSource – Returns TRUE if this message contains a reference to the source GameObject that sent it

  • public bool IsSystemEvent – Returns TRUE if this message contains a game event string that is also a system event. A game event string is considered to be a system event if it is contained in the SystemGameEvent enum values.

Public Variables

  • public readonly string EventName – The game event string sent with this message. If “None”, then no game event is considered to have been passed with this message

  • public GameObject Source – The source GameObject  reference that sent this message. If null, then no GameObject reference was passed with this message

  • public Object CustomObject – A custom Object reference passed with this message

Constructors

  • public GameEventMessage(SystemGameEvent systemGameEvent) – Initializes a new instance of the class with the passed SystemGameEvent

  • public GameEventMessage(string gameEvent) – Initializes a new instance of the class with the passed game event string value

  • public GameEventMessage(GameObject source) – Initializes a new instance of the class with a GameObject reference and no game event string. This overload can be used to send only a GameObject reference.

  • public GameEventMessage(SystemGameEvent systemGameEvent, GameObject source, Object customObject = null) – Initializes a new instance of the class with a SystemGameEvent and a GameObject reference

  • public GameEventMessage(GameObject source, Object customObject) – Initializes a new instance of the class with a source GameObject reference and a custom Object reference

  • public GameEventMessage(string gameEvent, Object customObject) – Initializes a new instance of the class with a game event string and a custom Object reference

  • public GameEventMessage(string gameEvent, GameObject source, Object customObject) – Initializes a new instance of the class with a game event string, a source GameObject reference and a custom Object reference

Static Methods