iqx = quadx+(lookx+9)/10 - 1;\r
iqy = quady+(looky+9)/10 - 1;\r
if (iqx < 1 || iqx > 8 || iqy < 1 || iqy > 8 ||\r
- d.galaxy[iqx][iqy] > 899)\r
+ game.state.galaxy[iqx][iqy] > 899)\r
return 0; /* no can do -- neg energy, supernovae, or >8 Klingons */\r
if (ienm == IHR) return 0; /* Romulans cannot escape! */\r
if (irun == 0) {\r
/* avoid intruding on another commander's territory */\r
if (ienm == IHC) {\r
- for (l = 1; l <= d.remcom; l++)\r
- if (d.cx[l]==iqx && d.cy[l]==iqy) return 0;\r
+ for (l = 1; l <= game.state.remcom; l++)\r
+ if (game.state.cx[l]==iqx && game.state.cy[l]==iqy) return 0;\r
/* refuse to leave if currently attacking starbase */\r
if (batx==quadx && baty==quady) return 0;\r
}\r
/* don't leave if over 1000 units of energy */\r
- if (kpower[loccom] > 1000.) return 0;\r
+ if (game.kpower[loccom] > 1000.) return 0;\r
}\r
/* print escape message and move out of quadrant.\r
We know this if either short or long range sensors are working */\r
- if (damage[DSRSENS] == 0.0 || damage[DLRSENS] == 0.0 ||\r
+ if (game.damage[DSRSENS] == 0.0 || game.damage[DLRSENS] == 0.0 ||\r
condit == IHDOCKED) {\r
proutn("***");\r
cramen(ienm);\r
- proutn(" escapes to");\r
- cramlc(1, iqx, iqy);\r
- prout(" (and regains strength).");\r
+ proutn(" escapes to %s (and regains strength).",\r
+ cramlc(quadrant, iqx, iqy));\r
}\r
/* handle local matters related to escape */\r
- kx[loccom] = kx[nenhere];\r
- ky[loccom] = ky[nenhere];\r
- kavgd[loccom] = kavgd[nenhere];\r
- kpower[loccom] = kpower[nenhere];\r
- kdist[loccom] = kdist[nenhere];\r
+ game.kx[loccom] = game.kx[nenhere];\r
+ game.ky[loccom] = game.ky[nenhere];\r
+ game.kavgd[loccom] = game.kavgd[nenhere];\r
+ game.kpower[loccom] = game.kpower[nenhere];\r
+ game.kdist[loccom] = game.kdist[nenhere];\r
klhere--;\r
nenhere--;\r
if (condit != IHDOCKED) newcnd();\r
/* Handle global matters related to escape */\r
- d.galaxy[quadx][quady] -= 100;\r
- d.galaxy[iqx][iqy] += 100;\r
+ game.state.galaxy[quadx][quady] -= 100;\r
+ game.state.galaxy[iqx][iqy] += 100;\r
if (ienm==IHS) {\r
ishere=0;\r
iscate=0;\r
ientesc=0;\r
isatb=0;\r
- future[FSCMOVE]=0.2777+d.date;\r
- future[FSCDBAS]=1e30;\r
- d.isx=iqx;\r
- d.isy=iqy;\r
+ game.future[FSCMOVE]=0.2777+game.state.date;\r
+ game.future[FSCDBAS]=1e30;\r
+ game.state.isx=iqx;\r
+ game.state.isy=iqy;\r
}\r
else {\r
- for (l=1; l<=d.remcom; l++) {\r
- if (d.cx[l]==quadx && d.cy[l]==quady) {\r
- d.cx[l]=iqx;\r
- d.cy[l]=iqy;\r
+ for (l=1; l<=game.state.remcom; l++) {\r
+ if (game.state.cx[l]==quadx && game.state.cy[l]==quady) {\r
+ game.state.cx[l]=iqx;\r
+ game.state.cy[l]=iqy;\r
break;\r
}\r
}\r
(comhere + ishere);\r
double dist1, forces;\r
\r
- dist1 = kdist[loccom];\r
+ dist1 = game.kdist[loccom];\r
mdist = dist1 + 0.5; /* Nearest integer distance */\r
\r
/* If SC, check with spy to see if should hi-tail it */\r
if (ienm==IHS &&\r
- (kpower[loccom] <= 500.0 || (condit==IHDOCKED && damage[DPHOTON]==0))) {\r
+ (game.kpower[loccom] <= 500.0 || (condit==IHDOCKED && game.damage[DPHOTON]==0))) {\r
irun = 1;\r
motion = -10;\r
}\r
* Motion is limited to skill level, except for SC hi-tailing it out.\r
*/\r
\r
- forces = kpower[loccom]+100.0*nenhere+400*(nbaddys-1);\r
+ forces = game.kpower[loccom]+100.0*nenhere+400*(nbaddys-1);\r
if (shldup==0) forces += 1000; /* Good for enemy if shield is down! */\r
- if (damage[DPHASER] == 0.0 || damage[DPHOTON] == 0.0) {\r
- if (damage[DPHASER] != 0) /* phasers damaged */\r
+ if (game.damage[DPHASER] == 0.0 || game.damage[DPHOTON] == 0.0) {\r
+ if (game.damage[DPHASER] != 0) /* phasers damaged */\r
forces += 300.0;\r
else\r
forces -= 0.2*(energy - 2500.0);\r
- if (damage[DPHOTON] != 0) /* photon torpedoes damaged */\r
+ if (game.damage[DPHOTON] != 0) /* photon torpedoes damaged */\r
forces += 300.0;\r
else\r
forces -= 50.0*torps;\r
}\r
#ifdef DEBUG\r
if (idebug) {\r
- proutn("MOTION = ");\r
- cramf(motion, 1, 2);\r
- proutn(" FORCES = ");\r
- cramf(forces, 1, 2);\r
- skip(1);\r
+ proutn("MOTION = %1.2f", motion);\r
+ proutn(" FORCES = %1,2f", forces);\r
}\r
#endif\r
/* don't move if no motion */\r
if (nsteps < 1) nsteps = 1; /* This shouldn't be necessary */\r
#ifdef DEBUG\r
if (idebug) {\r
- proutn("NSTEPS = ");\r
- crami(nsteps, 1);\r
- skip(1);\r
+ prout("NSTEPS = %d", nsteps);\r
}\r
#endif\r
/* Compute preferred values of delta X and Y */\r
if (my != 0) my = my*motion < 0 ? -1 : 1;\r
nextx = comx;\r
nexty = comy;\r
- quad[comx][comy] = IHDOT;\r
+ game.quad[comx][comy] = IHDOT;\r
/* main move loop */\r
for (ll = 1; ll <= nsteps; ll++) {\r
#ifdef DEBUG\r
if (idebug) {\r
- crami(ll,2);\r
- skip(1);\r
+ prout("%d", ll);\r
}\r
#endif\r
/* Check if preferred position available */\r
looky = nexty + krawly;\r
krawly = -krawly;\r
}\r
- else if (quad[lookx][looky] != IHDOT) {\r
+ else if (game.quad[lookx][looky] != IHDOT) {\r
/* See if we should ram ship */\r
- if (quad[lookx][looky] == ship &&\r
+ if (game.quad[lookx][looky] == ship &&\r
(ienm == IHC || ienm == IHS)) {\r
ram(1, ienm, comx, comy);\r
return;\r
nexty = looky;\r
#ifdef DEBUG\r
if (idebug) {\r
- cramlc(0, nextx, nexty);\r
- skip(1);\r
+ prout(cramlc(neither, nextx, nexty));\r
}\r
#endif\r
}\r
else break; /* done early */\r
}\r
/* Put commander in place within same quadrant */\r
- quad[nextx][nexty] = ienm;\r
+ game.quad[nextx][nexty] = ienm;\r
if (nextx != comx || nexty != comy) {\r
/* it moved */\r
- kx[loccom] = nextx;\r
- ky[loccom] = nexty;\r
- kdist[loccom] = kavgd[loccom] =\r
+ game.kx[loccom] = nextx;\r
+ game.ky[loccom] = nexty;\r
+ game.kdist[loccom] = game.kavgd[loccom] =\r
sqrt(square(sectx-nextx)+square(secty-nexty));\r
- if (damage[DSRSENS] == 0 || condit == IHDOCKED) {\r
+ if (game.damage[DSRSENS] == 0 || condit == IHDOCKED) {\r
proutn("***");\r
cramen(ienm);\r
- if (kdist[loccom] < dist1) proutn(" advances to");\r
- else proutn(" retreats to");\r
- cramlc(2, nextx, nexty);\r
- skip(1);\r
+ if (game.kdist[loccom] < dist1) proutn(" advances to");\r
+ else proutn(" retreats to ");\r
+ prout(cramlc(sector, nextx, nexty));\r
}\r
}\r
}\r
/* Figure out which Klingon is the commander (or Supercommander)\r
and do move */\r
if (comhere) for (i = 1; i <= nenhere; i++) {\r
- ix = kx[i];\r
- iy = ky[i];\r
- if (quad[ix][iy] == IHC) {\r
+ ix = game.kx[i];\r
+ iy = game.ky[i];\r
+ if (game.quad[ix][iy] == IHC) {\r
movebaddy(ix, iy, i, IHC);\r
break;\r
}\r
}\r
if (ishere) for (i = 1; i <= nenhere; i++) {\r
- ix = kx[i];\r
- iy = ky[i];\r
- if (quad[ix][iy] == IHS) {\r
+ ix = game.kx[i];\r
+ iy = game.ky[i];\r
+ if (game.quad[ix][iy] == IHS) {\r
movebaddy(ix, iy, i, IHS);\r
break;\r
}\r
Move these last so they can base their actions on what the\r
commander(s) do. */\r
if (skill > 3) for (i = 1; i <= nenhere; i++) {\r
- ix = kx[i];\r
- iy = ky[i];\r
- if (quad[ix][iy] == IHK || quad[ix][iy] == IHR)\r
- movebaddy(ix, iy, i, quad[ix][iy]);\r
+ ix = game.kx[i];\r
+ iy = game.ky[i];\r
+ if (game.quad[ix][iy] == IHK || game.quad[ix][iy] == IHR)\r
+ movebaddy(ix, iy, i, game.quad[ix][iy]);\r
}\r
\r
sortkl();\r
\r
if ((iqx==quadx && iqy==quady) ||\r
iqx < 1 || iqx > 8 || iqy < 1 || iqy > 8 ||\r
- d.galaxy[iqx][iqy] > 899) return 1;\r
+ game.state.galaxy[iqx][iqy] > 899) return 1;\r
if (flag) {\r
/* Avoid quadrants with bases if we want to avoid Enterprise */\r
- for (i = 1; i <= d.rembase; i++)\r
- if (d.baseqx[i]==iqx && d.baseqy[i]==iqy) return 1;\r
+ for (i = 1; i <= game.state.rembase; i++)\r
+ if (game.state.baseqx[i]==iqx && game.state.baseqy[i]==iqy) return 1;\r
}\r
\r
/* do the move */\r
- d.galaxy[d.isx][d.isy] -= 100;\r
- d.isx = iqx;\r
- d.isy = iqy;\r
- d.galaxy[d.isx][d.isy] += 100;\r
+ game.state.galaxy[game.state.isx][game.state.isy] -= 100;\r
+ game.state.isx = iqx;\r
+ game.state.isy = iqy;\r
+ game.state.galaxy[game.state.isx][game.state.isy] += 100;\r
if (iscate) {\r
/* SC has scooted, Remove him from current quadrant */\r
iscate=0;\r
isatb=0;\r
ishere=0;\r
ientesc=0;\r
- future[FSCDBAS]=1e30;\r
+ game.future[FSCDBAS]=1e30;\r
for (i = 1; i <= nenhere; i++) \r
- if (quad[kx[i]][ky[i]] == IHS) break;\r
- quad[kx[i]][ky[i]] = IHDOT;\r
- kx[i] = kx[nenhere];\r
- ky[i] = ky[nenhere];\r
- kdist[i] = kdist[nenhere];\r
- kavgd[i] = kavgd[nenhere];\r
- kpower[i] = kpower[nenhere];\r
+ if (game.quad[game.kx[i]][game.ky[i]] == IHS) break;\r
+ game.quad[game.kx[i]][game.ky[i]] = IHDOT;\r
+ game.kx[i] = game.kx[nenhere];\r
+ game.ky[i] = game.ky[nenhere];\r
+ game.kdist[i] = game.kdist[nenhere];\r
+ game.kavgd[i] = game.kavgd[nenhere];\r
+ game.kpower[i] = game.kpower[nenhere];\r
klhere--;\r
nenhere--;\r
if (condit!=IHDOCKED) newcnd();\r
sortkl();\r
}\r
/* check for a helpful planet */\r
- for (i = 1; i <= inplan; i++) {\r
- if (d.plnets[i].x==d.isx && d.plnets[i].y==d.isy &&\r
- d.plnets[i].crystals == 1) {\r
+ for (i = 0; i < inplan; i++) {\r
+ if (game.state.plnets[i].x==game.state.isx && game.state.plnets[i].y==game.state.isy &&\r
+ game.state.plnets[i].crystals == 1) {\r
/* destroy the planet */\r
- d.plnets[i] = nulplanet;\r
- d.newstuf[d.isx][d.isy] -= 1;\r
- if (damage[DRADIO] == 0.0 || condit == IHDOCKED) {\r
+ DESTROY(&game.state.plnets[i]);\r
+ game.state.newstuf[game.state.isx][game.state.isy] -= 1;\r
+ if (game.damage[DRADIO] == 0.0 || condit == IHDOCKED) {\r
if (*ipage==0) pause(1);\r
*ipage = 1;\r
prout("Lt. Uhura- \"Captain, Starfleet Intelligence reports");\r
- proutn(" a planet in");\r
- cramlc(1, d.isx, d.isy);\r
+ proutn(" a planet in ");\r
+ proutn(cramlc(quadrant, game.state.isx, game.state.isy));\r
prout(" has been destroyed");\r
prout(" by the Super-commander.\"");\r
}\r
#endif\r
\r
/* Decide on being active or passive */\r
- flag = ((d.killc+d.killk)/(d.date+0.01-indate) < 0.1*skill*(skill+1.0) ||\r
- (d.date-indate) < 3.0);\r
+ flag = ((game.state.killc+game.state.killk)/(game.state.date+0.01-indate) < 0.1*skill*(skill+1.0) ||\r
+ (game.state.date-indate) < 3.0);\r
if (iscate==0 && flag) {\r
/* compute move away from Enterprise */\r
- ideltax = d.isx-quadx;\r
- ideltay = d.isy-quady;\r
+ ideltax = game.state.isx-quadx;\r
+ ideltay = game.state.isy-quady;\r
if (sqrt(ideltax*(double)ideltax+ideltay*(double)ideltay) > 2.0) {\r
/* circulate in space */\r
- ideltax = d.isy-quady;\r
- ideltay = quadx-d.isx;\r
+ ideltax = game.state.isy-quady;\r
+ ideltay = quadx-game.state.isx;\r
}\r
}\r
else {\r
/* compute distances to starbases */\r
- if (d.rembase <= 0) {\r
+ if (game.state.rembase <= 0) {\r
/* nothing left to do */\r
- future[FSCMOVE] = 1e30;\r
+ game.future[FSCMOVE] = 1e30;\r
return;\r
}\r
- sx = d.isx;\r
- sy = d.isy;\r
- for (i = 1; i <= d.rembase; i++) {\r
+ sx = game.state.isx;\r
+ sy = game.state.isy;\r
+ for (i = 1; i <= game.state.rembase; i++) {\r
basetbl[i] = i;\r
- ibqx = d.baseqx[i];\r
- ibqy = d.baseqy[i];\r
+ ibqx = game.state.baseqx[i];\r
+ ibqy = game.state.baseqy[i];\r
bdist[i] = sqrt(square(ibqx-sx) + square(ibqy-sy));\r
}\r
- if (d.rembase > 1) {\r
+ if (game.state.rembase > 1) {\r
/* sort into nearest first order */\r
int iswitch;\r
do {\r
iswitch = 0;\r
- for (i=1; i < d.rembase-1; i++) {\r
+ for (i=1; i < game.state.rembase-1; i++) {\r
if (bdist[i] > bdist[i+1]) {\r
int ti = basetbl[i];\r
double t = bdist[i];\r
without too many Klingons, and not already under attack. */\r
ifindit = iwhichb = 0;\r
\r
- for (i2 = 1; i2 <= d.rembase; i2++) {\r
+ for (i2 = 1; i2 <= game.state.rembase; i2++) {\r
i = basetbl[i2]; /* bug in original had it not finding nearest*/\r
- ibqx = d.baseqx[i];\r
- ibqy = d.baseqy[i];\r
+ ibqx = game.state.baseqx[i];\r
+ ibqy = game.state.baseqy[i];\r
if ((ibqx == quadx && ibqy == quady) ||\r
(ibqx == batx && ibqy == baty) ||\r
- d.galaxy[ibqx][ibqy] > 899) continue;\r
+ game.state.galaxy[ibqx][ibqy] > 899) continue;\r
/* if there is a commander, an no other base is appropriate,\r
we will take the one with the commander */\r
- for (j = 1; j <= d.remcom; j++) {\r
- if (ibqx==d.cx[j] && ibqy==d.cy[j] && ifindit!= 2) {\r
+ for (j = 1; j <= game.state.remcom; j++) {\r
+ if (ibqx==game.state.cx[j] && ibqy==game.state.cy[j] && ifindit!= 2) {\r
ifindit = 2;\r
iwhichb = i;\r
break;\r
}\r
}\r
- if (j > d.remcom) { /* no commander -- use this one */\r
+ if (j > game.state.remcom) { /* no commander -- use this one */\r
ifindit = 1;\r
iwhichb = i;\r
break;\r
}\r
}\r
if (ifindit==0) return; /* Nothing suitable -- wait until next time*/\r
- ibqx = d.baseqx[iwhichb];\r
- ibqy = d.baseqy[iwhichb];\r
+ ibqx = game.state.baseqx[iwhichb];\r
+ ibqy = game.state.baseqy[iwhichb];\r
/* decide how to move toward base */\r
- ideltax = ibqx - d.isx;\r
- ideltay = ibqy - d.isy;\r
+ ideltax = ibqx - game.state.isx;\r
+ ideltay = ibqy - game.state.isy;\r
}\r
/* Maximum movement is 1 quadrant in either or both axis */\r
if (ideltax > 1) ideltax = 1;\r
if (ideltay < -1) ideltay = -1;\r
\r
/* try moving in both x and y directions */\r
- iqx = d.isx + ideltax;\r
- iqy = d.isy + ideltax;\r
+ iqx = game.state.isx + ideltax;\r
+ iqy = game.state.isy + ideltax;\r
if (checkdest(iqx, iqy, flag, ipage)) {\r
/* failed -- try some other maneuvers */\r
if (ideltax==0 || ideltay==0) {\r
/* attempt angle move */\r
if (ideltax != 0) {\r
- iqy = d.isy + 1;\r
+ iqy = game.state.isy + 1;\r
if (checkdest(iqx, iqy, flag, ipage)) {\r
- iqy = d.isy - 1;\r
+ iqy = game.state.isy - 1;\r
checkdest(iqx, iqy, flag, ipage);\r
}\r
}\r
else {\r
- iqx = d.isx + 1;\r
+ iqx = game.state.isx + 1;\r
if (checkdest(iqx, iqy, flag, ipage)) {\r
- iqx = d.isx - 1;\r
+ iqx = game.state.isx - 1;\r
checkdest(iqx, iqy, flag, ipage);\r
}\r
}\r
}\r
else {\r
/* try moving just in x or y */\r
- iqy = d.isy;\r
+ iqy = game.state.isy;\r
if (checkdest(iqx, iqy, flag, ipage)) {\r
- iqy = d.isy + ideltay;\r
- iqx = d.isx;\r
+ iqy = game.state.isy + ideltay;\r
+ iqx = game.state.isx;\r
checkdest(iqx, iqy, flag, ipage);\r
}\r
}\r
}\r
/* check for a base */\r
- if (d.rembase == 0) {\r
- future[FSCMOVE] = 1e30;\r
+ if (game.state.rembase == 0) {\r
+ game.future[FSCMOVE] = 1e30;\r
}\r
- else for (i=1; i<=d.rembase; i++) {\r
- ibqx = d.baseqx[i];\r
- ibqy = d.baseqy[i];\r
- if (ibqx==d.isx && ibqy == d.isy && d.isx != batx && d.isy != baty) {\r
+ else for (i=1; i<=game.state.rembase; i++) {\r
+ ibqx = game.state.baseqx[i];\r
+ ibqy = game.state.baseqy[i];\r
+ if (ibqx==game.state.isx && ibqy == game.state.isy && game.state.isx != batx && game.state.isy != baty) {\r
/* attack the base */\r
if (flag) return; /* no, don't attack base! */\r
iseenit = 0;\r
isatb=1;\r
- future[FSCDBAS] = d.date + 1.0 +2.0*Rand();\r
- if (batx != 0) future[FSCDBAS] += future[FCDBAS]-d.date;\r
- if (damage[DRADIO] > 0 && condit != IHDOCKED)\r
+ game.future[FSCDBAS] = game.state.date + 1.0 +2.0*Rand();\r
+ if (batx != 0) game.future[FSCDBAS] += game.future[FCDBAS]-game.state.date;\r
+ if (game.damage[DRADIO] > 0 && condit != IHDOCKED)\r
return; /* no warning */\r
iseenit = 1;\r
if (*ipage == 0) pause(1);\r
*ipage=1;\r
- proutn("Lt. Uhura- \"Captain, the starbase in");\r
- cramlc(1, d.isx, d.isy);\r
+ proutn("Lt. Uhura- \"Captain, the starbase in ");\r
+ proutn(cramlc(quadrant, game.state.isx, game.state.isy));\r
skip(1);\r
prout(" reports that it is under attack from the Klingon Super-commander.");\r
- proutn(" It can survive until stardate ");\r
- cramf(future[FSCDBAS], 0, 1);\r
- prout(" .\"");\r
+ proutn(" It can survive until stardate %d.\"",\r
+ (int)game.future[FSCDBAS]);\r
if (resting==0) return;\r
prout("Mr. Spock- \"Captain, shall we cancel the rest period?\"");\r
if (ja()==0) return;\r
idebug==0 &&\r
#endif\r
(Rand() > 0.2 ||\r
- (damage[DRADIO] > 0.0 && condit != IHDOCKED) ||\r
- starch[d.isx][d.isy] > 0))\r
+ (game.damage[DRADIO] > 0.0 && condit != IHDOCKED) ||\r
+ game.starch[game.state.isx][game.state.isy] > 0))\r
return;\r
if (*ipage==0) pause(1);\r
*ipage = 1;\r
prout("Lt. Uhura- \"Captain, Starfleet Intelligence reports");\r
- proutn(" the Super-commander is in");\r
- cramlc(1, d.isx, d.isy);\r
+ proutn(" the Super-commander is in ");\r
+ proutn(cramlc(quadrant, game.state.isx, game.state. isy));\r
prout(".\"");\r
return;\r
}\r
}\r
\r
/* Do nothing if we are blocked */\r
- if (quad[idx][idy]!= IHDOT && quad[idx][idy]!= IHWEB) return;\r
- quad[ithx][ithy] = IHWEB;\r
+ if (game.quad[idx][idy]!= IHDOT && game.quad[idx][idy]!= IHWEB) return;\r
+ game.quad[ithx][ithy] = IHWEB;\r
\r
if (ithx != idx) {\r
/* move in x axis */\r
im = fabs((double)idx - ithx)/((double)idx - ithx);\r
while (ithx != idx) {\r
ithx += im;\r
- if (quad[ithx][ithy]==IHDOT) quad[ithx][ithy] = IHWEB;\r
+ if (game.quad[ithx][ithy]==IHDOT) game.quad[ithx][ithy] = IHWEB;\r
}\r
}\r
else if (ithy != idy) {\r
im = fabs((double)idy - ithy)/((double)idy - ithy);\r
while (ithy != idy) {\r
ithy += im;\r
- if (quad[ithx][ithy]==IHDOT) quad[ithx][ithy] = IHWEB;\r
+ if (game.quad[ithx][ithy]==IHDOT) game.quad[ithx][ithy] = IHWEB;\r
}\r
}\r
- quad[ithx][ithy] = IHT;\r
+ game.quad[ithx][ithy] = IHT;\r
\r
/* check to see if all holes plugged */\r
for (i = 1; i < 11; i++) {\r
- if (quad[1][i]!=IHWEB && quad[1][i]!=IHT) return;\r
- if (quad[10][i]!=IHWEB && quad[10][i]!=IHT) return;\r
- if (quad[i][1]!=IHWEB && quad[i][1]!=IHT) return;\r
- if (quad[i][10]!=IHWEB && quad[i][10]!=IHT) return;\r
+ if (game.quad[1][i]!=IHWEB && game.quad[1][i]!=IHT) return;\r
+ if (game.quad[10][i]!=IHWEB && game.quad[10][i]!=IHT) return;\r
+ if (game.quad[i][1]!=IHWEB && game.quad[i][1]!=IHT) return;\r
+ if (game.quad[i][10]!=IHWEB && game.quad[i][10]!=IHT) return;\r
}\r
/* All plugged up -- Tholian splits */\r
- quad[ithx][ithy]=IHWEB;\r
+ game.quad[ithx][ithy]=IHWEB;\r
dropin(IHBLANK, &dum, &my);\r
crmena(1,IHT, 2, ithx, ithy);\r
prout(" completes web.");\r