Message
Properties & Methods
property | type | summary |
---|---|---|
text | string | the text to be sent. |
time | int | the time to display the text for. |
should_clear | bool | If true, clears the previous messages. |
with_text | method | Sets the message text |
for_seconds | method | Sets the message timer |
clear_previous_messages | method | Determines if the previous messages should be cleared |
Example
message:with_text
Adds text to an ephemeral message shown to the user on the upper RHS of the screen.
param | type | summary |
---|---|---|
txt | string | the text to be sent. |
Returns self
message:for_seconds
Sets the message duration
param | type | summary |
---|---|---|
seconds | int | the number of seconds to apply the message to the screen before it is erased. Defaults to 10 seconds |
Returns self
Example
message:clear_previous_messages
Upon displaying this message, remove all other messages
Returns self
Example
message:send
Display this message, to all players, in all coalitions. Messages appear in the upper RHS of the screen.
Returns self