3 static void getcd(int, int);
\r
6 double angle, deltax, deltay, bigger, x, y,
\r
7 finald, finalx, finaly, stopegy;
\r
8 int trbeam = 0, n, l, ix, iy, kink, kinks, iquad;
\r
11 prout("Helmsman Sulu- \"Leaving standard orbit.\"");
\r
15 angle = ((15.0 - direc) * 0.5235988);
\r
16 deltax = -sin(angle);
\r
17 deltay = cos(angle);
\r
18 if (fabs(deltax) > fabs(deltay))
\r
19 bigger = fabs(deltax);
\r
21 bigger = fabs(deltay);
\r
26 /* If tractor beam is to occur, don't move full distance */
\r
27 if (game.state.date+Time >= game.future[FTBEAM]) {
\r
30 dist = dist*(game.future[FTBEAM]-game.state.date)/Time + 0.1;
\r
31 Time = game.future[FTBEAM] - game.state.date + 1e-5;
\r
33 /* Move within the quadrant */
\r
34 game.quad[sectx][secty] = IHDOT;
\r
37 n = 10.0*dist*bigger+0.5;
\r
40 for (l = 1; l <= n; l++) {
\r
41 ix = (x += deltax) + 0.5;
\r
42 iy = (y += deltay) + 0.5;
\r
43 if (ix < 1 || ix > 10 || iy < 1 || iy > 10) {
\r
44 /* Leaving quadrant -- allow final enemy attack */
\r
45 /* Don't do it if being pushed by Nova */
\r
46 if (nenhere != 0 && iattak != 2) {
\r
48 for (l = 1; l <= nenhere; l++) {
\r
49 finald = sqrt((ix-game.kx[l])*(double)(ix-game.kx[l]) +
\r
50 (iy-game.ky[l])*(double)(iy-game.ky[l]));
\r
51 game.kavgd[l] = 0.5 * (finald+game.kdist[l]);
\r
53 if (game.state.galaxy[quadx][quady] != 1000) attack(0);
\r
54 if (alldone) return;
\r
56 /* compute final position -- new quadrant and sector */
\r
57 x = 10*(quadx-1)+sectx;
\r
58 y = 10*(quady-1)+secty;
\r
59 ix = x+10.0*dist*bigger*deltax+0.5;
\r
60 iy = y+10.0*dist*bigger*deltay+0.5;
\r
61 /* check for edge of galaxy */
\r
81 if (kink) kinks = 1;
\r
87 /* Three strikes -- you're out! */
\r
91 prout("\nYOU HAVE ATTEMPTED TO CROSS THE NEGATIVE ENERGY BARRIER\n"
\r
92 "AT THE EDGE OF THE GALAXY. THE THIRD TIME YOU TRY THIS,\n"
\r
93 "YOU WILL BE DESTROYED.\n");
\r
95 /* Compute final position in new quadrant */
\r
96 if (trbeam) return; /* Don't bother if we are to be beamed */
\r
99 sectx = ix - 10*(quadx-1);
\r
100 secty = iy - 10*(quady-1);
\r
102 prout("Entering %s.",
\r
103 cramlc(quadrant, quadx, quady));
\r
104 game.quad[sectx][secty] = ship;
\r
108 iquad = game.quad[ix][iy];
\r
109 if (iquad != IHDOT) {
\r
110 /* object encountered in flight path */
\r
111 stopegy = 50.0*dist/Time;
\r
112 dist=0.1*sqrt((sectx-ix)*(double)(sectx-ix) +
\r
113 (secty-iy)*(double)(secty-iy));
\r
115 case IHT: /* Ram a Tholian */
\r
116 case IHK: /* Ram enemy ship */
\r
122 ram(0, iquad, sectx, secty);
\r
128 prouts("***RED ALERT! RED ALERT!");
\r
132 proutn(" pulled into black hole at ");
\r
133 prout(cramlc(sector, ix, iy));
\r
137 /* something else */
\r
140 if (iquad == IHWEB)
\r
141 proutn(" encounters Tholian web at ");
\r
143 proutn(" blocked by object at ");
\r
144 proutn(cramlc(sector, ix,iy));
\r
146 proutn("Emergency stop required ");
\r
147 prout("%2d units of energy.", (int)stopegy);
\r
149 finalx = x-deltax+0.5;
\r
151 finaly = y-deltay+0.5;
\r
159 goto label100; /* sorry! */
\r
162 dist = 0.1*sqrt((sectx-ix)*(double)(sectx-ix) +
\r
163 (secty-iy)*(double)(secty-iy));
\r
170 /* No quadrant change -- compute new avg enemy distances */
\r
171 game.quad[sectx][secty] = ship;
\r
173 for (l = 1; l <= nenhere; l++) {
\r
174 finald = sqrt((ix-game.kx[l])*(double)(ix-game.kx[l]) +
\r
175 (iy-game.ky[l])*(double)(iy-game.ky[l]));
\r
176 game.kavgd[l] = 0.5 * (finald+game.kdist[l]);
\r
177 game.kdist[l] = finald;
\r
180 if (game.state.galaxy[quadx][quady] != 1000 && iattak == 0)
\r
182 for (l = 1 ; l <= nenhere; l++) game.kavgd[l] = game.kdist[l];
\r
191 if (condit == IHDOCKED) {
\r
192 prout("Already docked.");
\r
196 prout("You must first leave standard orbit.");
\r
199 if (basex==0 || abs(sectx-basex) > 1 || abs(secty-basey) > 1) {
\r
201 prout(" not adjacent to base.");
\r
206 if (energy < inenrg) energy = inenrg;
\r
210 if (stdamtim != 1e30 &&
\r
211 (game.future[FCDBAS] < 1e30 || isatb == 1) && iseenit == 0) {
\r
212 /* get attack report from base */
\r
213 prout("Lt. Uhura- \"Captain, an important message from the starbase:\"");
\r
219 static void getcd(int isprobe, int akey) {
\r
220 /* This program originally required input in terms of a (clock)
\r
221 direction and distance. Somewhere in history, it was changed to
\r
222 cartesian coordinates. So we need to convert. I think
\r
223 "manual" input should still be done this way -- it's a real
\r
224 pain if the computer isn't working! Manual mode is still confusing
\r
225 because it involves giving x and y motions, yet the coordinates
\r
226 are always displayed y - x, where +y is downward! */
\r
229 int irowq=quadx, icolq=quady, irows, icols, itemp=0, iprompt=0, key;
\r
230 double xi, xj, xk, xl;
\r
231 double deltax, deltay;
\r
232 int automatic = -1;
\r
234 /* Get course direction and distance. If user types bad values, return
\r
235 with DIREC = -1.0. */
\r
239 if (landed == 1 && !isprobe) {
\r
240 prout("Dummy! You can't leave standard orbit until you");
\r
241 proutn("are back abourt the ");
\r
247 while (automatic == -1) {
\r
248 if (game.damage[DCOMPTR]) {
\r
250 prout("Computer damaged; manual navigation only");
\r
252 prout("Computer damaged; manual movement only");
\r
258 if (isprobe && akey != -1) {
\r
259 /* For probe launch, use pre-scaned value first time */
\r
266 if (key == IHEOL) {
\r
267 proutn("Manual or automatic- ");
\r
271 else if (key == IHALPHA) {
\r
272 if (isit("manual")) {
\r
277 else if (isit("automatic")) {
\r
288 else { /* numeric */
\r
290 prout("(Manual navigation assumed.)");
\r
292 prout("(Manual movement assumed.)");
\r
299 while (key == IHEOL) {
\r
301 proutn("Target quadrant or quadrant§or- ");
\r
303 proutn("Destination sector or quadrant§or- ");
\r
309 if (key != IHREAL) {
\r
315 if (key != IHREAL){
\r
321 if (key == IHREAL) {
\r
322 /* both quadrant and sector specified */
\r
325 if (key != IHREAL) {
\r
338 /* only quadrant specified -- go to center of dest quad */
\r
349 if (irowq<1 || irowq > 8 || icolq<1 || icolq > 8 ||
\r
350 irows<1 || irows > 10 || icols<1 || icols > 10) {
\r
358 proutn("Helmsman Sulu- \"Course locked in for %s.\"",
\r
359 cramlc(sector, irows, icols));
\r
362 else prout("Ensign Chekov- \"Course laid in, Captain.\"");
\r
364 deltax = icolq - quady + 0.1*(icols-secty);
\r
365 deltay = quadx - irowq + 0.1*(sectx-irows);
\r
367 else { /* manual */
\r
368 while (key == IHEOL) {
\r
369 proutn("X and Y displacements- ");
\r
375 if (key != IHREAL) {
\r
381 if (key != IHREAL) {
\r
387 /* Check for zero movement */
\r
388 if (deltax == 0 && deltay == 0) {
\r
392 if (itemp == 2 && !isprobe) {
\r
394 prout("Helmsman Sulu- \"Aye, Sir.\"");
\r
396 dist = sqrt(deltax*deltax + deltay*deltay);
\r
397 direc = atan2(deltax, deltay)*1.90985932;
\r
398 if (direc < 0.0) direc += 12.0;
\r
406 void impuls(void) {
\r
410 if (game.damage[DIMPULS]) {
\r
413 prout("Engineer Scott- \"The impulse engines are damaged, Sir.\"");
\r
417 if (energy > 30.0) {
\r
419 if (direc == -1.0) return;
\r
420 power = 20.0 + 100.0*dist;
\r
425 if (power >= energy) {
\r
426 /* Insufficient power for trip */
\r
428 prout("First Officer Spock- \"Captain, the impulse engines");
\r
429 prout("require 20.0 units to engage, plus 100.0 units per");
\r
431 proutn("quadrant. We can go, therefore, a maximum of %d",
\r
432 (int)(0.01 * (energy-20.0)-0.05));
\r
433 prout(" quadrants.\"");
\r
436 prout("quadrant. They are, therefore, useless.\"");
\r
441 /* Make sure enough time is left for the trip */
\r
443 if (Time >= game.state.remtime) {
\r
444 prout("First Officer Spock- \"Captain, our speed under impulse");
\r
445 prout("power is only 0.95 sectors per stardate. Are you sure");
\r
446 prout("we dare spend the time?\"");
\r
447 if (ja() == 0) return;
\r
449 /* Activate impulse engines and pay the cost */
\r
452 if (alldone) return;
\r
453 power = 20.0 + 100.0*dist;
\r
456 if (energy <= 0) finish(FNRG);
\r
462 int blooey=0, twarp=0, iwarp;
\r
465 if (i!=2) { /* Not WARPX entry */
\r
467 if (game.damage[DWARPEN] > 10.0) {
\r
470 prout("Engineer Scott- \"The impulse engines are damaged, Sir.\"");
\r
473 if (game.damage[DWARPEN] > 0.0 && warpfac > 4.0) {
\r
476 prout("Engineer Scott- \"Sorry, Captain. Until this damage");
\r
477 prout(" is repaired, I can only give you warp 4.\"");
\r
481 /* Read in course and distance */
\r
483 if (direc == -1.0) return;
\r
485 /* Make sure starship has enough energy for the trip */
\r
486 power = (dist+0.05)*warpfac*warpfac*warpfac*(shldup+1);
\r
489 if (power >= energy) {
\r
490 /* Insufficient power for trip */
\r
493 prout("Engineering to bridge--");
\r
494 if (shldup==0 || 0.5*power > energy) {
\r
495 iwarp = pow((energy/(dist+0.05)), 0.333333333);
\r
497 prout("We can't do it, Captain. We haven't the energy.");
\r
500 proutn("We haven't the energy, but we could do it at warp %d", iwarp);
\r
503 prout("if you'll lower the shields.");
\r
510 prout("We haven't the energy to go that far with the shields up.");
\r
514 /* Make sure enough time is left for the trip */
\r
515 Time = 10.0*dist/wfacsq;
\r
516 if (Time >= 0.8*game.state.remtime) {
\r
518 prout("First Officer Spock- \"Captain, I compute that such");
\r
519 proutn(" a trip would require approximately %2.0f",
\r
520 100.0*Time/game.state.remtime);
\r
521 prout(" percent of our");
\r
522 prout(" remaining time. Are you sure this is wise?\"");
\r
523 if (ja() == 0) { ididit = 0; return;}
\r
527 if (warpfac > 6.0) {
\r
528 /* Decide if engine damage will occur */
\r
529 double prob = dist*(6.0-warpfac)*(6.0-warpfac)/66.666666666;
\r
530 if (prob > Rand()) {
\r
532 dist = Rand()*dist;
\r
534 /* Decide if time warp will occur */
\r
535 if (0.5*dist*pow(7.0,warpfac-10.0) > Rand()) twarp=1;
\r
537 if (idebug &&warpfac==10 && twarp==0) {
\r
539 proutn("Force time warp? ");
\r
540 if (ja()==1) twarp=1;
\r
543 if (blooey || twarp) {
\r
544 /* If time warp or engine damage, check path */
\r
545 /* If it is obstructed, don't do warp or damage */
\r
546 double angle = ((15.0-direc)*0.5235998);
\r
547 double deltax = -sin(angle);
\r
548 double deltay = cos(angle);
\r
549 double bigger, x, y;
\r
551 if (fabs(deltax) > fabs(deltay))
\r
552 bigger = fabs(deltax);
\r
554 bigger = fabs(deltay);
\r
558 n = 10.0 * dist * bigger +0.5;
\r
561 for (l = 1; l <= n; l++) {
\r
564 if (ix < 1 || ix > 10) break;
\r
567 if (iy < 1 || iy > 10) break;
\r
568 if (game.quad[ix][iy] != IHDOT) {
\r
577 /* Activate Warp Engines and pay the cost */
\r
579 if (alldone) return;
\r
580 energy -= dist*warpfac*warpfac*warpfac*(shldup+1);
\r
581 if (energy <= 0) finish(FNRG);
\r
582 Time = 10.0*dist/wfacsq;
\r
583 if (twarp) timwrp();
\r
585 game.damage[DWARPEN] = damfac*(3.0*Rand()+1.0);
\r
587 prout("Engineering to bridge--");
\r
588 prout(" Scott here. The warp engines are damaged.");
\r
589 prout(" We'll have to reduce speed to warp 4.");
\r
597 void setwrp(void) {
\r
601 while ((key=scan()) == IHEOL) {
\r
603 proutn("Warp factor-");
\r
606 if (key != IHREAL) {
\r
610 if (game.damage[DWARPEN] > 10.0) {
\r
611 prout("Warp engines inoperative.");
\r
614 if (game.damage[DWARPEN] > 0.0 && aaitem > 4.0) {
\r
615 prout("Engineer Scott- \"I'm doing my best, Captain,\n"
\r
616 " but right now we can only go warp 4.\"");
\r
619 if (aaitem > 10.0) {
\r
620 prout("Helmsman Sulu- \"Our top speed is warp 10, Captain.\"");
\r
623 if (aaitem < 1.0) {
\r
624 prout("Helmsman Sulu- \"We can't go below warp 1, Captain.\"");
\r
629 wfacsq=warpfac*warpfac;
\r
630 if (warpfac <= oldfac || warpfac <= 6.0) {
\r
631 proutn("Helmsman Sulu- \"Warp factor %do, Captain.\"",
\r
635 if (warpfac < 8.00) {
\r
636 prout("Engineer Scott- \"Aye, but our maximum safe speed is warp 6.\"");
\r
639 if (warpfac == 10.0) {
\r
640 prout("Engineer Scott- \"Aye, Captain, we'll try it.\"");
\r
643 prout("Engineer Scott- \"Aye, Captain, but our engines may not take it.\"");
\r
647 void atover(int igrab) {
\r
648 double power, distreq;
\r
651 /* is captain on planet? */
\r
653 if (game.damage[DTRANSP]) {
\r
657 prout("Scotty rushes to the transporter controls.");
\r
659 prout("But with the shields up it's hopeless.");
\r
662 prouts("His desperate attempt to rescue you . . .");
\r
663 if (Rand() <= 0.5) {
\r
668 prout("SUCCEEDS!");
\r
671 proutn("The crystals mined were ");
\r
672 if (Rand() <= 0.25) {
\r
683 /* Check to see if captain in shuttle craft */
\r
684 if (icraft) finish(FSTRACTOR);
\r
685 if (alldone) return;
\r
687 /* Inform captain of attempt to reach safety */
\r
691 prouts("***RED ALERT! READ ALERT!");
\r
695 prout(" has stopped in a quadrant containing");
\r
696 prouts(" a supernova.");
\r
699 proutn("***Emergency automatic override attempts to hurl ");
\r
702 prout("safely out of quadrant.");
\r
703 game.starch[quadx][quady] = game.damage[DRADIO] > 0.0 ? game.state.galaxy[quadx][quady]+1000:1;
\r
705 /* Try to use warp engines */
\r
706 if (game.damage[DWARPEN]) {
\r
708 prout("Warp engines damaged.");
\r
712 warpfac = 6.0+2.0*Rand();
\r
713 wfacsq = warpfac * warpfac;
\r
714 prout("Warp factor set to %d", (int)warpfac);
\r
715 power = 0.75*energy;
\r
716 dist = power/(warpfac*warpfac*warpfac*(shldup+1));
\r
717 distreq = 1.4142+Rand();
\r
718 if (distreq < dist) dist = distreq;
\r
719 Time = 10.0*dist/wfacsq;
\r
720 direc = 12.0*Rand(); /* How dumb! */
\r
725 /* This is bad news, we didn't leave quadrant. */
\r
726 if (alldone) return;
\r
728 prout("Insufficient energy to leave quadrant.");
\r
732 /* Repeat if another snova */
\r
733 } while (game.state.galaxy[quadx][quady] == 1000);
\r
734 if (game.state.remkl==0) finish(FWON); /* Snova killed remaining enemy. */
\r
739 prout("***TIME WARP ENTERED.");
\r
740 if (game.state.snap && Rand() < 0.5) {
\r
741 /* Go back in time */
\r
742 prout("You are traveling backwards in time %d stardates.",
\r
743 (int)(game.state.date-game.snapsht.date));
\r
744 game.state = game.snapsht;
\r
745 game.state.snap = 0;
\r
746 if (game.state.remcom) {
\r
747 game.future[FTBEAM] = game.state.date + expran(intime/game.state.remcom);
\r
748 game.future[FBATTAK] = game.state.date + expran(0.3*intime);
\r
750 game.future[FSNOVA] = game.state.date + expran(0.5*intime);
\r
751 game.future[FSNAP] = game.state.date +expran(0.25*game.state.remtime); /* next snapshot will
\r
753 if (game.state.nscrem) game.future[FSCMOVE] = 0.2777;
\r
755 game.future[FCDBAS] = game.future[FSCDBAS] = 1e30;
\r
758 /* Make sure Galileo is consistant -- Snapshot may have been taken
\r
759 when on planet, which would give us two Galileos! */
\r
761 for (l = 0; l < inplan; l++) {
\r
762 if (game.state.plnets[l].known == shuttle_down) {
\r
764 if (iscraft==1 && ship==IHE) {
\r
765 prout("Checkov- \"Security reports the Galileo has disappeared, Sir!");
\r
770 /* Likewise, if in the original time the Galileo was abandoned, but
\r
771 was on ship earlier, it would have vanished -- lets restore it */
\r
772 if (iscraft==0 && gotit==0 && game.damage[DSHUTTL] >= 0.0) {
\r
773 prout("Checkov- \"Security reports the Galileo has reappeared in the dock!\"");
\r
777 /* Revert star chart to earlier era, if it was known then*/
\r
778 if (game.damage[DRADIO]==0.0 || stdamtim > game.state.date) {
\r
779 for (l = 1; l <= 8; l++)
\r
780 for (ll = 1; ll <= 8; ll++)
\r
781 if (game.starch[l][ll] > 1)
\r
782 game.starch[l][ll]=game.damage[DRADIO]>0.0 ? game.state.galaxy[l][ll]+1000 :1;
\r
783 prout("Spock has reconstructed a correct star chart from memory");
\r
784 if (game.damage[DRADIO] > 0.0) stdamtim = game.state.date;
\r
788 /* Go forward in time */
\r
789 Time = -0.5*intime*log(Rand());
\r
790 prout("You are traveling forward in time %d stardates.", (int)Time);
\r
791 /* cheat to make sure no tractor beams occur during time warp */
\r
792 game.future[FTBEAM] += Time;
\r
793 game.damage[DRADIO] += Time;
\r
799 double angle, bigger;
\r
801 /* New code to launch a deep space probe */
\r
802 if (nprobes == 0) {
\r
806 prout("Engineer Scott- \"We have no more deep space probes, Sir.\"");
\r
808 prout("Ye Faerie Queene has no deep space probes.");
\r
811 if (game.damage[DDSP] != 0.0) {
\r
814 prout("Engineer Scott- \"The probe launcher is damaged, Sir.\"");
\r
817 if (game.future[FDSPROB] != 1e30) {
\r
820 if (game.damage[DRADIO] != 0 && condit != IHDOCKED) {
\r
821 prout("Spock- \"Records show the previous probe has not yet");
\r
822 prout(" reached its destination.\"");
\r
825 prout("Uhura- \"The previous probe is still reporting data, Sir.\"");
\r
830 if (key == IHEOL) {
\r
831 /* slow mode, so let Kirk know how many probes there are left */
\r
832 prout(nprobes==1 ? "%d probe left." : "%d probes left.", nprobes);
\r
833 proutn("Are you sure you want to fire a probe? ");
\r
834 if (ja()==0) return;
\r
838 if (key == IHALPHA && strcmp(citem,"armed") == 0) {
\r
842 else if (key == IHEOL) {
\r
843 proutn("Arm NOVAMAX warhead?");
\r
847 if (direc == -1.0) return;
\r
849 angle = ((15.0 - direc) * 0.5235988);
\r
850 probeinx = -sin(angle);
\r
851 probeiny = cos(angle);
\r
852 if (fabs(probeinx) > fabs(probeiny))
\r
853 bigger = fabs(probeinx);
\r
855 bigger = fabs(probeiny);
\r
857 probeiny /= bigger;
\r
858 probeinx /= bigger;
\r
859 proben = 10.0*dist*bigger +0.5;
\r
860 probex = quadx*10 + sectx - 1; // We will use better packing than original
\r
861 probey = quady*10 + secty - 1;
\r
864 game.future[FDSPROB] = game.state.date + 0.01; // Time to move one sector
\r
865 prout("Ensign Chekov- \"The deep space probe is launched, Captain.\"");
\r
870 /* There's more than one way to move in this game! */
\r
871 double ddist, xdist, probf;
\r
872 int line, l, ix, iy;
\r
875 /* Test for conditions which prevent calling for help */
\r
876 if (condit == IHDOCKED) {
\r
877 prout("Lt. Uhura- \"But Captain, we're already docked.\"");
\r
880 if (game.damage[DRADIO] != 0) {
\r
881 prout("Subspace radio damaged.");
\r
884 if (game.state.rembase==0) {
\r
885 prout("Lt. Uhura- \"Captain, I'm not getting any response from Starbase.\"");
\r
889 proutn("You must be aboard the ");
\r
894 /* OK -- call for help from nearest starbase */
\r
897 /* There's one in this quadrant */
\r
898 ddist = sqrt(square(basex-sectx)+square(basey-secty));
\r
902 for (l = 1; l <= game.state.rembase; l++) {
\r
903 xdist=10.0*sqrt(square(game.state.baseqx[l]-quadx)+square(game.state.baseqy[l]-quady));
\r
904 if (xdist < ddist) {
\r
909 /* Since starbase not in quadrant, set up new quadrant */
\r
910 quadx = game.state.baseqx[line];
\r
911 quady = game.state.baseqy[line];
\r
914 /* dematerialize starship */
\r
915 game.quad[sectx][secty]=IHDOT;
\r
916 proutn("Starbase in %s responds--", cramlc(quadrant, quadx, quady));
\r
919 prout(" dematerializes.");
\r
920 /* Give starbase three chances to rematerialize starship */
\r
921 probf = pow((1.0 - pow(0.98,ddist)), 0.33333333);
\r
922 for (l = 1; l <= 3; l++) {
\r
924 case 1: proutn("1st"); break;
\r
925 case 2: proutn("2nd"); break;
\r
926 case 3: proutn("3rd"); break;
\r
928 proutn(" attempt to re-materialize ");
\r
930 prouts(" . . . . . ");
\r
931 if (Rand() > probf) break;
\r
935 finish(FMATERIALIZE);
\r
938 /* Rematerialization attempt should succeed if can get adj to base */
\r
939 for (l = 1; l <= 5; l++) {
\r
940 ix = basex+3.0*Rand()-1;
\r
941 iy = basey+3.0*Rand()-1;
\r
942 if (ix>=1 && ix<=10 && iy>=1 && iy<=10 && game.quad[ix][iy]==IHDOT) {
\r
943 /* found one -- finish up */
\r
944 prout("succeeds.");
\r
947 game.quad[ix][iy]=ship;
\r
950 prout("Lt. Uhura- \"Captain, we made it!\"");
\r
954 finish(FMATERIALIZE);
\r