projects
/
super-star-trek.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improvements to the testing machinery, including the replay option.
[super-star-trek.git]
/
src
/
finish.c
diff --git
a/src/finish.c
b/src/finish.c
index c9e83335b56e4e0f0068af62af0a35ecab1dfdd9..54b5beaca08a7db10f4b5b19f89706390adf1b15 100644
(file)
--- a/
src/finish.c
+++ b/
src/finish.c
@@
-61,7
+61,7
@@
void kaboom(void)
int l=1;
while (l <= game.nenhere) {
if (game.kpower[l]*game.kdist[l] <= whammo)
int l=1;
while (l <= game.nenhere) {
if (game.kpower[l]*game.kdist[l] <= whammo)
- deadkl(game.k
x[l],game.ky[l], game.quad[game.kx[l]][game.ky[l]], game.kx[l], game.ky[l]
);
+ deadkl(game.k
s[l], game.quad[game.ks[l].x][game.ks[l].y], game.ks[l].x, game.ks[l].y
);
l++;
}
}
l++;
}
}
@@
-71,8
+71,8
@@
void kaboom(void)
void finish(FINTYPE ifin)
{
void finish(FINTYPE ifin)
{
-
int igotit = 0
;
- game.alldone =
1
;
+
bool igotit = false
;
+ game.alldone =
true
;
skip(3);
prout(_("It is stardate %.1f."), game.state.date);
skip(1);
skip(3);
prout(_("It is stardate %.1f."), game.state.date);
skip(1);
@@
-84,7
+84,7
@@
void finish(FINTYPE ifin)
prout(_("You have smashed the Klingon invasion fleet and saved"));
prout(_("the Federation."));
prout(_("You have smashed the Klingon invasion fleet and saved"));
prout(_("the Federation."));
- game.gamewon
=1
;
+ game.gamewon
= true
;
if (game.alive) {
double badpt;
badpt = 5.0*game.state.starkl + game.casual + 10.0*game.state.nplankl +
if (game.alive) {
double badpt;
badpt = 5.0*game.state.starkl + game.casual + 10.0*game.state.nplankl +
@@
-134,11
+134,7
@@
void finish(FINTYPE ifin)
break;
}
if (game.skill >= SKILL_EXPERT) {
break;
}
if (game.skill >= SKILL_EXPERT) {
- if (game.thawed
-#ifdef DEBUG
- && !game.idebug
-#endif
- )
+ if (game.thawed && !idebug)
prout(_("You cannot get a citation, so..."));
else {
proutn(_("Do you want your Commodore Emeritus Citation printed? "));
prout(_("You cannot get a citation, so..."));
else {
proutn(_("Do you want your Commodore Emeritus Citation printed? "));
@@
-330,7
+326,7
@@
void score(void)
if (game.gamewon == 0) game.state.nromrem = 0; // None captured if no win
iscore = 10*NKILLK + 50*NKILLC + ithperd + iwon
- 100*game.state.basekl - 100*klship - 45*game.nhelp -5*game.state.starkl - game.casual
if (game.gamewon == 0) game.state.nromrem = 0; // None captured if no win
iscore = 10*NKILLK + 50*NKILLC + ithperd + iwon
- 100*game.state.basekl - 100*klship - 45*game.nhelp -5*game.state.starkl - game.casual
- + 20*NKILLROM + 200*NKILLSC - 10*game.state.nplankl + game.state.nromrem;
+ + 20*NKILLROM + 200*NKILLSC - 10*game.state.nplankl
- 300*game.state.nworldkl
+ game.state.nromrem;
if (game.alive == 0) iscore -= 200;
skip(2);
prout(_("Your score --"));
if (game.alive == 0) iscore -= 200;
skip(2);
prout(_("Your score --"));
@@
-358,6
+354,9
@@
void score(void)
if (game.state.nplankl)
prout(_("%6d planets destroyed by your action %5d"),
game.state.nplankl, -10*game.state.nplankl);
if (game.state.nplankl)
prout(_("%6d planets destroyed by your action %5d"),
game.state.nplankl, -10*game.state.nplankl);
+ if ((game.options & OPTION_WORLDS) && game.state.nworldkl)
+ prout(_("%6d inhabited planets destroyed by your action %5d"),
+ game.state.nplankl, -300*game.state.nworldkl);
if (game.state.basekl)
prout(_("%6d bases destroyed by your action %5d"),
game.state.basekl, -100*game.state.basekl);
if (game.state.basekl)
prout(_("%6d bases destroyed by your action %5d"),
game.state.basekl, -100*game.state.basekl);