summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/tutorial.cc
diff options
context:
space:
mode:
authorRobert Vollmert <rvollmert@gmx.net>2010-04-23 22:39:17 +0200
committerRobert Vollmert <rvollmert@gmx.net>2010-04-23 23:43:49 +0200
commitf7fe51cc8c502c5c12cbafcbb68782cfb1de716b (patch)
treeae1de8632d7ab76edb1e83d97066e7e42fc8832e /crawl-ref/source/tutorial.cc
parent7dd7c0d264d6fc8cbf915b2f8fcf6c8e6d29a26e (diff)
downloadcrawl-ref-f7fe51cc8c502c5c12cbafcbb68782cfb1de716b.tar.gz
crawl-ref-f7fe51cc8c502c5c12cbafcbb68782cfb1de716b.zip
A start at cleaning up handling of new game choices.
No more storing species and background indices. Instead, there's now a few instances of newgame_def: Options.game: command line and option game settings (used to be Options.cls, Options.race, ...) Options.prev_game: the previous game's choices (used to be Options.prev_cls, ...; should not be in Options) ngchoice: current choices, internal to newgame.cc The species and background choice now separate interrogating the user from applying settings from Options.game. This is not the case yet for the secondary choices. Secondary choice memory may be slightly broken at the moment.
Diffstat (limited to 'crawl-ref/source/tutorial.cc')
-rw-r--r--crawl-ref/source/tutorial.cc11
1 files changed, 5 insertions, 6 deletions
diff --git a/crawl-ref/source/tutorial.cc b/crawl-ref/source/tutorial.cc
index 9078bb0993..6ca214a618 100644
--- a/crawl-ref/source/tutorial.cc
+++ b/crawl-ref/source/tutorial.cc
@@ -196,10 +196,9 @@ bool pick_tutorial()
// Did the player recently see a monster turn invisible?
Tutorial.tut_seen_invisible = 0;
- Options.random_pick = false;
- if (!Options.book || Options.book == SBT_SUMM)
- Options.book = SBT_RANDOM;
- Options.weapon = WPN_HAND_AXE; // easiest choice for fighters
+ Options.game.fully_random = false;
+ Options.game.book = SBT_RANDOM;
+ Options.game.weapon = WPN_HAND_AXE; // easiest choice for fighters
crawl_state.type = GAME_TYPE_TUTORIAL;
@@ -211,8 +210,8 @@ bool pick_tutorial()
// In this case, undo previous choices.
you.species = SP_UNKNOWN;
you.char_class = JOB_UNKNOWN;
- Options.race = 0;
- Options.cls = 0;
+ Options.game.species = SP_UNKNOWN;
+ Options.game.job = JOB_UNKNOWN;
}
switch (keyn)