diff options
Diffstat (limited to 'crawl-ref/source/ghost.cc')
-rw-r--r-- | crawl-ref/source/ghost.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/crawl-ref/source/ghost.cc b/crawl-ref/source/ghost.cc index 5e4044dde7..3ca0ee78b9 100644 --- a/crawl-ref/source/ghost.cc +++ b/crawl-ref/source/ghost.cc @@ -534,6 +534,7 @@ std::vector<ghost_demon> ghost_demon::find_ghosts() ghost_demon player; player.init_player_ghost(); + announce_ghost(player); gs.push_back(player); find_extra_ghosts( gs, n_extra_ghosts() ); @@ -541,6 +542,13 @@ std::vector<ghost_demon> ghost_demon::find_ghosts() return (gs); } +void ghost_demon::announce_ghost(const ghost_demon &g) +{ +#ifdef DEBUG_DIAGNOSTICS + mprf(MSGCH_DIAGNOSTICS, "Saving ghost: %s", g.name.c_str()); +#endif +} + void ghost_demon::find_extra_ghosts( std::vector<ghost_demon> &gs, int n ) { for (int i = 0; n > 0 && i < MAX_MONSTERS; ++i) @@ -551,6 +559,7 @@ void ghost_demon::find_extra_ghosts( std::vector<ghost_demon> &gs, int n ) if (menv[i].type == MONS_PLAYER_GHOST && menv[i].ghost.get()) { // Bingo! + announce_ghost(*menv[i].ghost); gs.push_back( *menv[i].ghost ); --n; } |