Fix things so seed doesn't cost clock time.

This commit is contained in:
Eric S. Raymond 2017-05-30 20:08:55 -04:00
parent 6b6cfa37f1
commit 6a6670e3ca
4 changed files with 5 additions and 3 deletions

2
main.c
View file

@ -156,6 +156,8 @@ static bool fallback_handler(signed char *buf)
if (sscanf(buf, "seed %ld", &sv) == 1) {
set_seed(sv);
printf("Seed set to %ld\n", sv);
// autogenerated, so don't charge user time for it.
--TURNS;
// here we reconfigure any global game state that uses random numbers
ZZWORD=RNDVOC(3,0);
return true;

View file

@ -133,7 +133,7 @@ to try to reincarnate you?
OK
You scored 51 out of a possible 430, using 19 turns.
You scored 51 out of a possible 430, using 18 turns.
Your score qualifies you as a novice class adventurer.

View file

@ -379,7 +379,7 @@ to try to reincarnate you?
OK
You scored 81 out of a possible 430, using 56 turns.
You scored 81 out of a possible 430, using 55 turns.
Your score qualifies you as a novice class adventurer.

View file

@ -1902,7 +1902,7 @@ There is a massive vending machine here, swung back to reveal a
southward passage.
>
You scored 219 out of a possible 430, using 314 turns.
You scored 219 out of a possible 430, using 313 turns.
You may now consider yourself a "Seasoned Adventurer".