diff options
Diffstat (limited to 'src/core/player.h')
-rw-r--r-- | src/core/player.h | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/src/core/player.h b/src/core/player.h index 4620062..35a2f82 100644 --- a/src/core/player.h +++ b/src/core/player.h @@ -88,11 +88,24 @@ public: /*----- messages -------------------------------------------------- */ - void send(const std::string name); + /// send a text message + void send(const std::string text); + + /** + * @brief send a warning message + * Send the player a warning message abd set the warning + * message timestamp to the current application time + * @see last_warning() + */ + void send_warning(const std::string text); virtual void sound(const std::string name); virtual void message(core::Message::Channel channel, const std::string text); + + /// time of the last warning message + float last_warning() const { return player_warningtime; } + /*----- mutators -------------------------------------------------- */ @@ -204,6 +217,8 @@ private: // bit to indicate zone has changed bool player_zonechange; + float player_warningtime; + }; } |