summaryrefslogtreecommitdiffstats
path: root/warp/play.c
diff options
context:
space:
mode:
authorchristos <christos@NetBSD.org>2020-11-10 22:42:19 +0000
committerchristos <christos@NetBSD.org>2020-11-10 22:42:19 +0000
commita6ad8fb14c6bed68eb8b37750e1b2fea36a8c908 (patch)
tree96a006165d8615e5e0cb4e78ef064e66b8e16437 /warp/play.c
parent1bb28c57a5d2c06152fff5de57a902bec60cc30d (diff)
downloadbsdgames-darwin-a6ad8fb14c6bed68eb8b37750e1b2fea36a8c908.tar.gz
bsdgames-darwin-a6ad8fb14c6bed68eb8b37750e1b2fea36a8c908.tar.zst
bsdgames-darwin-a6ad8fb14c6bed68eb8b37750e1b2fea36a8c908.zip
Time warp forward 34 years so that it compiles (but not work)
Diffstat (limited to 'warp/play.c')
-rw-r--r--warp/play.c26
1 files changed, 14 insertions, 12 deletions
diff --git a/warp/play.c b/warp/play.c
index 7c040497..a26f76c7 100644
--- a/warp/play.c
+++ b/warp/play.c
@@ -24,20 +24,20 @@
#include "play.h"
void
-play_init()
+play_init(void)
{
;
}
void
-play()
+play(void)
{
- bool done = FALSE;
- Reg1 OBJECT *curobj;
- Reg2 OBJECT *to;
- Reg3 int i;
- Reg4 int x;
- Reg5 int y;
+ bool done = false;
+ OBJECT *curobj;
+ OBJECT *to;
+ int i;
+ int x;
+ int y;
display_status();
#ifdef TIOCOUTQ
@@ -48,7 +48,7 @@ play()
do {
timer++;
nxtbang = 0;
- banging = FALSE;
+ banging = false;
display_status();
#ifdef TIOCOUTQ
while (output_pending() > charsperhalfsec)
@@ -69,7 +69,7 @@ play()
ent->energy -= ent->energy/40;
}
else
- cloaking = FALSE;
+ cloaking = false;
cloaked = cloaking;
}
if (base) {
@@ -138,6 +138,8 @@ play()
possiblescore += 5000;
}
if (apolloflag & 2) {
+/*###141 [cc] warning: array subscript has type 'char' [-Wchar-subscripts]%%%*/
+/*###141 [cc] warning: array subscript has type 'char' [-Wchar-subscripts]%%%*/
if (blast[realapollo->posy][realapollo->posx] <= 32000)
bvely = bvelx = 0;
realapollo->energy = 32000;
@@ -152,7 +154,7 @@ play()
if (aretorps) {
aretorps = 0;
for (i=0;i<2;i++) for (y=0;y<3;y++) for (x=0;x<3;x++) {
- if (curobj = isatorp[i][y][x]) {
+ if ((curobj = isatorp[i][y][x]) != NULL) {
to = occupant[(curobj->posy+curobj->vely+YSIZE00)%YSIZE]
[(curobj->posx+curobj->velx+XSIZE00)%XSIZE];
if (to && !to->vely && !to->velx) {
@@ -170,7 +172,7 @@ play()
if (finish) {
finish--;
if (!finish && (!(numenemies || numos) || (!ent && !base))) {
- done = TRUE;
+ done = true;
timer -= 5;
}
}