|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T d
Length: 2409 (0x969) Types: TextFile Names: »dock.c«
└─⟦b20c6495f⟧ Bits:30007238 EUUGD18: Wien-båndet, efterår 1987 └─⟦this⟧ »EUUGD18/General/Mpss/dock.c«
/********VERSION 1.4!!! (Files from different Versions are INCOMPATIBLE!*******/ /******************************************************************************* ******************************************************************************** ******************************************************************************** PERMISSION TO COPY THIS SOFTWARE IS HEREBY GIVEN BY THE AUTHOR PROVIDED THAT THIS LEADING MESSAGE IS INCLUDED IN ALL OF THE RELEVANT SOURCE FILES. P. SCHMITZ, UNIVERSITY OF KEELE, MAY 1988. ******************************************************************************** ******************************************************************************** *******************************************************************************/ #include "header.h" dock(cp) register struct player *cp; { int dockingok; dockingok=OFF; i=cp->xpos; j=cp->ypos; if ((inuniv(i,j)=='*') && ((cp->xvel==0) && (cp->yvel==0))) dockingok=ON; if (dockingok==OFF) { plot1(cp," Your'e not beside any starbase or spacedock Captain. "); plot2(cp," "); } else { if ((cp->cloakingdevice)||(cp->shields)) { if (cp->shields) { plot1(cp," "); plot2(cp," While you have your shields are up? Youre kidding! "); } else { plot1(cp," "); plot2(cp," While you are cloaked? -come off it! "); } } else { plot1(cp," Docking procedure completed. "); plot2(cp," Weapons and Crystal Units recharged Captain. "); plotstatus(cp,7); if (cp->maxenergy>=STARTENERGY) cp->energy=cp->maxenergy; else { cp->energy=STARTENERGY; cp->maxenergy=STARTENERGY; } cp->phaserbanks=cp->maxphaser; cp->photontorpedos=cp->maxphoton; plotenergy(cp); plotmaxenergy(cp); plotphaserbanks(cp); plotphotontorpedos(cp); } } } undock(cp) register struct player *cp; { if ((cp->stat==7) && (cp->xvel==0) && (cp->yvel==0)) { plot1(cp," Un-docking successful Captain. No casualties this time. "); plot2(cp," Your'e improving... "); plotstatus(cp,3); } else { plot1(cp,"Tell me :- How can you un-dock when your'e not docked??? "); plot2(cp," "); } }