projects
/
super-star-trek.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
allow gcc to still do the bounds checking
[super-star-trek.git]
/
src
/
setup.c
diff --git
a/src/setup.c
b/src/setup.c
index b254a548ff2fa2df5d8c85cd175044c011f8e033..e0ca59da9b9d3c5e3bf76c72cca660eb538b1980 100644
(file)
--- a/
src/setup.c
+++ b/
src/setup.c
@@
-175,8
+175,8
@@
static void setup_names(void)
/* Sets up some arrays with localized names.
* Must be done after iostart() for localization to work. */
{
/* Sets up some arrays with localized names.
* Must be done after iostart() for localization to work. */
{
- char *tmp1[] = SYSTEM_NAMES;
- char *tmp2[] = DEVICE_NAMES;
+ char *tmp1[
ARRAY_SIZE(systnames)
] = SYSTEM_NAMES;
+ char *tmp2[
ARRAY_SIZE(device)
] = DEVICE_NAMES;
memcpy(systnames, tmp1, sizeof(systnames));
memcpy(device, tmp2, sizeof(device));
memcpy(systnames, tmp1, sizeof(systnames));
memcpy(device, tmp2, sizeof(device));
@@
-274,12
+274,12
@@
void setup(bool needprompt)
if (distq < 6.0*(BASEMAX+1-game.inbase) && Rand() < 0.75) {
contflag = true;
if (idebug)
if (distq < 6.0*(BASEMAX+1-game.inbase) && Rand() < 0.75) {
contflag = true;
if (idebug)
- prout(
_("=== Abandoning base #%d at %d-%d")
, i, w.x, w.y);
+ prout(
"=== Abandoning base #%d at %d-%d"
, i, w.x, w.y);
break;
}
else if (distq < 6.0 * (BASEMAX+1-game.inbase)) {
if (idebug)
break;
}
else if (distq < 6.0 * (BASEMAX+1-game.inbase)) {
if (idebug)
- prout(
_("=== Saving base #%d, close to #%d")
, i, j);
+ prout(
"=== Saving base #%d, close to #%d"
, i, j);
}
}
} while (contflag);
}
}
} while (contflag);
@@
-407,7
+407,7
@@
void setup(bool needprompt)
waitfor();
newqad(false);
if (game.nenhere-iqhere-game.ithere) game.shldup = true;
waitfor();
newqad(false);
if (game.nenhere-iqhere-game.ithere) game.shldup = true;
- if (game.neutz) attack(
0);
// bad luck to start in a Romulan Neutral Zone
+ if (game.neutz) attack(
false);
// bad luck to start in a Romulan Neutral Zone
}
bool choose(bool needprompt)
}
bool choose(bool needprompt)