diff options
author | Stijn Buys <ingar@osirion.org> | 2012-11-18 17:59:52 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2012-11-18 17:59:52 +0000 |
commit | df20ff5ad47b1d8a04385956589a7564522258a6 (patch) | |
tree | 55112286358004c7f5099c9a78f74cc5113063f3 /src/game/base/spacemine.h | |
parent | 2cd1f55f26f2236641fa2f3b36d9d23b99ca072f (diff) |
Support for ownerid() on projectiles and spacemines,
show assassin name in death messages.
Diffstat (limited to 'src/game/base/spacemine.h')
-rw-r--r-- | src/game/base/spacemine.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/game/base/spacemine.h b/src/game/base/spacemine.h index 4f95849..3c314c2 100644 --- a/src/game/base/spacemine.h +++ b/src/game/base/spacemine.h @@ -41,6 +41,14 @@ public: return spacemine_damage; } + /** + * @brief id of the player who dropped the spacemine + * */ + inline const int ownerid() const + { + return spacemine_ownerid; + } + /* --- mutators -------------------------------------------- */ /** @@ -50,11 +58,21 @@ public: { spacemine_damage = damage; } + + /** + * @brief set the id of the player who dropped the spacemine + * */ + inline void set_ownerid(const int ownerid) + { + spacemine_ownerid = ownerid; + } private: unsigned long spacemine_detonated_timestamp; float spacemine_damage; + int spacemine_ownerid; + static const Template *spacemine_template; }; |