From 7448e4e9a942cc8ea64315ba3084541af8e6c8a2 Mon Sep 17 00:00:00 2001 From: Matthew Cline Date: Mon, 26 Oct 2009 00:48:14 -0700 Subject: FR 1837856: note vaults generated in dump Include new dump section "vaults", which for game-end dumps (or any wizard-mode dumps) will include a list (by place) of all the vaults generated in the game. The savefile now includes a player-associated CrawlHashTable (you.props), which can be used for storing player information which doesn't need to be accessed efficiently. --- crawl-ref/source/place.cc | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'crawl-ref/source/place.cc') diff --git a/crawl-ref/source/place.cc b/crawl-ref/source/place.cc index 9322716835..2064fb0dfb 100644 --- a/crawl-ref/source/place.cc +++ b/crawl-ref/source/place.cc @@ -198,3 +198,16 @@ bool level_type_is_stash_trackable(level_area_type type) { return (type != LEVEL_ABYSS && type != LEVEL_LABYRINTH); } + +std::vector all_dungeon_ids() +{ + std::vector out; + for (int i = 0; i < NUM_BRANCHES; i++) + { + const Branch &branch = branches[i]; + + for (int depth = 1; depth <= branch.depth; depth++) + out.push_back(level_id(branch.id, depth)); + } + return (out); +} -- cgit v1.2.3-54-g00ecf