-#ifdef SERGEEV
-#include <conio.h>
#include <unistd.h>
+#include "conio.h"
#include "sstlinux.h"
-#endif /* SERGEEV */
#include "sst.h"
void doshield(int i) {
#ifdef SERGEEV
crx=wherex();
cry=wherey();
- if (game.damage[DSRSENS]==0 || condit==IHDOCKED) setwnd(1);
- else setwnd(4);
+ if (game.damage[DSRSENS]==0 || condit==IHDOCKED) setwnd(LEFTUPPER_WINDOW);
+ else setwnd(LOWER_WINDOW);
#endif /* SERGEEV */
/* Loop to move a single torpedo */
for (l=1; l <= 15; l++) {
#ifndef SERGEEV
skip(1);
#else
- setwnd(4);
+ setwnd(LOWER_WINDOW);
gotoxy(crx,cry);
#endif
switch(iquad) {
1000.0*sqrt(square(ix-inx)+square(iy-iny))*
fabs(sin(bullseye-angle));
*hit = fabs(*hit);
-#ifndef SERGEEV
- newcnd(); /* undock */
-#endif /* SERGEEV */
+ newcnd(); /* we're blown out of dock */
/* We may be displaced. */
if (landed==1 || condit==IHDOCKED) return; /* Cheat if on a planet */
ang = angle + 2.5*(Rand()-0.5);
break;
}
#ifdef SERGEEV
- if(curwnd!=4) {
- setwnd(4);
+ if(curwnd!=LOWER_WINDOW) {
+ setwnd(LOWER_WINDOW);
gotoxy(crx,cry);
}
#endif /* SERGEEV */
int i,j;
-#ifdef SERGEEV
skip(1);
-#endif /* SERGEEV */
crmena(1, type, 2, ixx, iyy);
/* Decide what kind of enemy it is and update approriately */
if (type == IHR) {
void hittem(double *hits) {
double kp, kpow, wham, hit, dustfac, kpini;
#ifdef SERGEEV
- int cx, cy;
+ int crx, cry;
#endif /* SERGEEV */
int nenhr2=nenhere, k=1, kk=1, ii, jj, ienm;
if (game.damage[DSRSENS]==0){
crx=wherex();
cry=wherey();
- setwnd(1);
+ setwnd(LEFTUPPER_WINDOW);
drawmaps(2);
gotoxy(jj*2+3,ii+2);
highvideo();
nosound();
lowvideo();
proutn("%c", game.quad[ii][jj]);
- setwnd(4);
+ setwnd(LOWER_WINDOW);
gotoxy(crx,cry);
_setcursortype(_NORMALCURSOR);
delay(500);