diff -rc server-2.4p7/docs/CHANGES server-2.4p8/docs/CHANGES *** server-2.4p7/docs/CHANGES Thu Jul 13 15:29:50 1995 --- server-2.4p8/docs/CHANGES Thu Jul 20 10:51:24 1995 *************** *** 44,46 **** --- 44,51 ---- client couldn't understand terrain. Note that these are probably not the same thing as Bronco feature packets. Define as FEATURE in config.h (on by default). + + 2.4 patch 8: (Gary Parnes, Ken Germann) + + * Added higher wtemp for butt torpers (Gary Parnes) + * Added ship-variable det distances (Ken Germann) diff -rc server-2.4p7/docs/CREDITS server-2.4p8/docs/CREDITS *** server-2.4p7/docs/CREDITS Thu Jul 13 15:29:50 1995 --- server-2.4p8/docs/CREDITS Thu Jul 20 10:52:04 1995 *************** *** 51,53 **** --- 51,54 ---- 2.4-5 05/??/95 Bob Glamm 2.4-6 06/12/95 Mike McGrath 2.4-7 07/13/95 Bob Glamm + 2.4-8 07/20/95 Gary Parnes, Ken Germann diff -rc server-2.4p7/src/config.h server-2.4p8/src/config.h *** server-2.4p7/src/config.h Thu Jul 13 15:29:51 1995 --- server-2.4p8/src/config.h Thu Jul 20 10:49:22 1995 *************** *** 118,125 **** // see data.c for the actual listing */ ! /* #define RANKS2 /* */ /* // Allow Iggy during TMODE */ --- 118,129 ---- // see data.c for the actual listing */ ! /* #define RANKS2 */ /* */ + /* CASSIUS_ROYALTY defines the structure to use cassius's royalty */ + + /* #define CASSIUS_ROYALTY */ + /* // Allow Iggy during TMODE */ *************** *** 157,169 **** // For the new det distance // */ - #define LARGEDET /**/ - /* // For FEATURE_PACKETS to determine client capabilities */ #define FEATURE /**/ #endif /* _config_h_ */ --- 161,174 ---- // For the new det distance // */ + #define SHIPDET /* */ /* // For FEATURE_PACKETS to determine client capabilities */ #define FEATURE /**/ + + #define BUTTORP_PENALTY /**/ #endif /* _config_h_ */ diff -rc server-2.4p7/src/data.c server-2.4p8/src/data.c *** server-2.4p7/src/data.c Thu Jul 13 15:29:52 1995 --- server-2.4p8/src/data.c Thu Jul 20 10:49:34 1995 *************** *** 111,117 **** { 300, 1700, 2.35, 6.1, 4.0, "Moff"}, { 500, 2500, 2.40, 6.2, 4.2, "Grand Moff"} }; ! struct royalty royal[NUMROYALRANKS] = { {"none"}, {"Wesley"}, --- 111,130 ---- { 300, 1700, 2.35, 6.1, 4.0, "Moff"}, { 500, 2500, 2.40, 6.2, 4.2, "Grand Moff"} }; ! #ifdef CASSIUS_ROYALTY ! struct royalty royal[NUMROYALRANKS] = { ! {"none"}, ! {"Wesley"}, ! {"Footslog"}, ! {"COMMODORE"}, ! {"Dread"}, ! {"Agent"}, ! {"Gorilla"}, ! {"Lord"}, ! {"Emperor"}, ! {"Q"} ! }; ! #else struct royalty royal[NUMROYALRANKS] = { {"none"}, {"Wesley"}, *************** *** 119,124 **** --- 132,138 ---- {"Emperor"}, {"Q"} }; + #endif /* Royalty */ #else struct rank ranks[NUMRANKS] = { *************** *** 159,165 **** int ping_ghostbust = 0; /* ghostbust timer */ ! char _PARAVERS[] = "@(#)version 2.4 patch 7"; char *PARAVERS = &(_PARAVERS[4]); char MCONTROL[] = "CONTROL->"; char UMPIRE[] = "Umpire "; --- 173,179 ---- int ping_ghostbust = 0; /* ghostbust timer */ ! char _PARAVERS[] = "@(#)version 2.4 patch 8"; char *PARAVERS = &(_PARAVERS[4]); char MCONTROL[] = "CONTROL->"; char UMPIRE[] = "Umpire "; diff -rc server-2.4p7/src/defs.h server-2.4p8/src/defs.h *** server-2.4p7/src/defs.h Tue Jun 27 15:36:56 1995 --- server-2.4p8/src/defs.h Thu Jul 20 10:49:38 1995 *************** *** 50,55 **** --- 50,62 ---- #define TGRID_SIZE MAX_GWIDTH/TGRID_GRANULARITY #define MAXTORP 8 + + /* Parnes's (Raynfala's) Butt Torp Code */ + /* HALFARC = (0-128), FACTOR = (0-16) */ + + #define TORP_PENALTY_HALFARC myship->s_torp.wtemp_halfarc + #define TORP_PENALTY_FACTOR myship->s_torp.wtemp_factor + #define NPTHINGIES 8 #define NGTHINGIES 40 #define TOTALTHINGIES (MAXPLAYER*NPTHINGIES + NGTHINGIES) *************** *** 60,66 **** --- 67,77 ---- #define CLOAK_PHASES 7 /* number of drawing phases in a cloak engage/disengage */ #define NUMRANKS 18 + #ifdef CASSIUS_ROYALTY + #define NUMROYALRANKS 10 + #else #define NUMROYALRANKS 5 + #endif #define GODLIKE (NUMROYALRANKS-2) /* These are configuration definitions */ *************** *** 69,76 **** #define WARP1 20 /* warp one will move 20 spaces per update */ #define SCALE 40 /* Window will be one pixel for 20 spaces */ #define SHIPDAMDIST 3000 /* At this range, an exploding ship does ! damage */ ! #define DETDIST 1700 /* At this range a torp can be detonated */ /* was 1600. 6/29/92 TC */ /* was 1800 8/1/92 TC */ #define NEWDETDIST 1750 --- 80,87 ---- #define WARP1 20 /* warp one will move 20 spaces per update */ #define SCALE 40 /* Window will be one pixel for 20 spaces */ #define SHIPDAMDIST 3000 /* At this range, an exploding ship does ! ! #define SHIPDET 1700 /* At this range a torp can be detonated */ /* was 1600. 6/29/92 TC */ /* was 1800 8/1/92 TC */ #define NEWDETDIST 1750 diff -rc server-2.4p7/src/detonate.c server-2.4p8/src/detonate.c *** server-2.4p7/src/detonate.c Tue Jun 27 15:36:57 1995 --- server-2.4p8/src/detonate.c Thu Jul 20 10:49:42 1995 *************** *** 82,94 **** if ((j->t_status == TMOVE) || (j->t_status == TSTRAIGHT)) { dx = j->t_x - me->p_x; /* if torp moving */ dy = j->t_y - me->p_y; /* get delta cords */ ! #ifdef LARGEDET if (ABS(dx) > NEWDETDIST || ABS(dy) > NEWDETDIST) continue; /* obviously too far away */ if (dx * dx + dy * dy < NEWDETDIST * NEWDETDIST) { /* close enough? */ #else ! if (ABS(dx) > DETDIST || ABS(dy) > DETDIST) ! continue; /* obviously too far away */ if (dx * dx + dy * dy < DETDIST * DETDIST) { /* close enough? */ #endif j->t_whodet = me->p_no; /* set who detted it */ --- 82,101 ---- if ((j->t_status == TMOVE) || (j->t_status == TSTRAIGHT)) { dx = j->t_x - me->p_x; /* if torp moving */ dy = j->t_y - me->p_y; /* get delta cords */ ! #ifdef SHIPDET ! if (ABS(dx) > myship->s_detdist || ABS(dy) > myship->s_detdist) ! continue; /* obviously too far away */ ! if (dx * dx + dy * dy < myship->s_detdist * myship->s_detdist ) { /* close enough? */ ! #elif LARGEDET if (ABS(dx) > NEWDETDIST || ABS(dy) > NEWDETDIST) continue; /* obviously too far away */ if (dx * dx + dy * dy < NEWDETDIST * NEWDETDIST) { /* close enough? */ #else ! /* DETDIST is normally set to 1700 unless SHIPDET is set. If SHIPDET is set */ ! /* then DETDIST is set as myship->s_detdist in defs.h which will make the */ ! /* det distances settable by ship type */ ! if (ABS(dx) > DETDIST || ABS(dy) > DETDIST) ! continue; /* obviously too far away */ if (dx * dx + dy * dy < DETDIST * DETDIST) { /* close enough? */ #endif j->t_whodet = me->p_no; /* set who detted it */ *************** *** 107,113 **** if (drn->ms_status == TMOVE || drn->ms_status == TSTRAIGHT) { dx = drn->ms_x - me->p_x; /* if torp moving */ dy = drn->ms_y - me->p_y; /* get delta cords */ ! #ifdef LARGEDET if (ABS(dx) > NEWDETDIST || ABS(dy) > NEWDETDIST) continue; /* obviously too far away */ if (dx * dx + dy * dy < NEWDETDIST * NEWDETDIST) { /* close enough? */ --- 114,126 ---- if (drn->ms_status == TMOVE || drn->ms_status == TSTRAIGHT) { dx = drn->ms_x - me->p_x; /* if torp moving */ dy = drn->ms_y - me->p_y; /* get delta cords */ ! ! #ifdef SHIPDET ! if (ABS(dx) > myship->s_detdist || ABS(dy) > myship->s_detdist) ! continue; /* obviously too far away */ ! if (dx * dx + dy * dy < myship->s_detdist * myship->s_detdist ) { /* close enough? */ ! #elif LARGEDET ! if (ABS(dx) > NEWDETDIST || ABS(dy) > NEWDETDIST) if (ABS(dx) > NEWDETDIST || ABS(dy) > NEWDETDIST) continue; /* obviously too far away */ if (dx * dx + dy * dy < NEWDETDIST * NEWDETDIST) { /* close enough? */ diff -rc server-2.4p7/src/shipvals.c server-2.4p8/src/shipvals.c *** server-2.4p7/src/shipvals.c Tue Jun 27 15:36:59 1995 --- server-2.4p8/src/shipvals.c Thu Jul 20 10:49:47 1995 *************** *** 101,106 **** --- 101,108 ---- shipvals[SCOUT].s_torp.fuse = 15; #endif shipvals[SCOUT].s_torp.wtemp = 7; + shipvals[SCOUT].s_torp.wtemp_halfarc = 32; + shipvals[SCOUT].s_torp.wtemp_factor = 9; shipvals[SCOUT].s_torp.aux = 0; shipvals[SCOUT].s_phaser.damage = 75; shipvals[SCOUT].s_phaser.speed = 4500; *************** *** 155,160 **** --- 157,163 ---- shipvals[SCOUT].s_maxshield = 75; shipvals[SCOUT].s_shieldcost = 2; shipvals[SCOUT].s_detcost = 100; + shipvals[SCOUT].s_detdist = 1700; if (configvals->bronco_shipvals) { shipvals[SCOUT].s_cloakcost = 85; shipvals[SCOUT].s_scanrange = -1; *************** *** 229,234 **** --- 232,239 ---- shipvals[DESTROYER].s_torp.cost = 210; shipvals[DESTROYER].s_torp.fuse = 30; shipvals[DESTROYER].s_torp.wtemp = 11; + shipvals[DESTROYER].s_torp.wtemp_halfarc = 32; + shipvals[DESTROYER].s_torp.wtemp_factor = 9; shipvals[DESTROYER].s_torp.aux = 0; shipvals[DESTROYER].s_phaser.damage = 85; shipvals[DESTROYER].s_phaser.speed = 5100; *************** *** 283,288 **** --- 288,294 ---- shipvals[DESTROYER].s_maxshield = 85; shipvals[DESTROYER].s_shieldcost = 3; shipvals[DESTROYER].s_detcost = 100; + shipvals[DESTROYER].s_detdist = 1950; if (configvals->bronco_shipvals) { shipvals[DESTROYER].s_cloakcost = 105; shipvals[DESTROYER].s_scanrange = -1; *************** *** 352,357 **** --- 358,365 ---- shipvals[CRUISER].s_torp.cost = 280; shipvals[CRUISER].s_torp.fuse = 40; shipvals[CRUISER].s_torp.wtemp = 18; + shipvals[CRUISER].s_torp.wtemp_halfarc = 32; + shipvals[CRUISER].s_torp.wtemp_factor = 9; shipvals[CRUISER].s_torp.aux = 0; shipvals[CRUISER].s_phaser.damage = 100; #ifndef OLDSHIPVALS *************** *** 407,412 **** --- 415,421 ---- shipvals[CRUISER].s_maxshield = 100; shipvals[CRUISER].s_shieldcost = 4; shipvals[CRUISER].s_detcost = 100; + shipvals[CRUISER].s_detdist = 1700; if (configvals->bronco_shipvals) shipvals[CRUISER].s_cloakcost = 130; else *************** *** 477,482 **** --- 486,493 ---- shipvals[BATTLESHIP].s_torp.cost = 300; shipvals[BATTLESHIP].s_torp.fuse = 40; shipvals[BATTLESHIP].s_torp.wtemp = 20; + shipvals[BATTLESHIP].s_torp.wtemp_halfarc = 32; + shipvals[BATTLESHIP].s_torp.wtemp_factor = 9; shipvals[BATTLESHIP].s_torp.aux = 0; shipvals[BATTLESHIP].s_phaser.damage = 105; #ifndef OLDSHIPVALS *************** *** 529,534 **** --- 540,546 ---- shipvals[BATTLESHIP].s_maxshield = 130; shipvals[BATTLESHIP].s_shieldcost = 5; shipvals[BATTLESHIP].s_detcost = 100; + shipvals[BATTLESHIP].s_detdist = 1500; shipvals[BATTLESHIP].s_cloakcost = 150; #ifdef LONG_SCANRANGE shipvals[BATTLESHIP].s_scanrange = 1000; *************** *** 596,601 **** --- 608,615 ---- shipvals[ASSAULT].s_torp.cost = 270; shipvals[ASSAULT].s_torp.fuse = 30; shipvals[ASSAULT].s_torp.wtemp = 17; + shipvals[ASSAULT].s_torp.wtemp_halfarc = 32; + shipvals[ASSAULT].s_torp.wtemp_factor = 9; shipvals[ASSAULT].s_torp.aux = 0; shipvals[ASSAULT].s_phaser.damage = 80; shipvals[ASSAULT].s_phaser.speed = 4800; *************** *** 649,654 **** --- 663,669 ---- shipvals[ASSAULT].s_maxshield = 80; shipvals[ASSAULT].s_shieldcost = 3; shipvals[ASSAULT].s_detcost = 100; + shipvals[ASSAULT].s_detdist = 1950; if (configvals->bronco_shipvals) shipvals[ASSAULT].s_cloakcost = 85; else *************** *** 729,734 **** --- 744,751 ---- else shipvals[STARBASE].s_torp.fuse = 45; shipvals[STARBASE].s_torp.wtemp = 20; + shipvals[STARBASE].s_torp.wtemp_halfarc = 0; + shipvals[STARBASE].s_torp.wtemp_factor = 0; shipvals[STARBASE].s_torp.aux = 0; shipvals[STARBASE].s_phaser.damage = 120; #ifndef OLDSHIPVALS *************** *** 792,797 **** --- 809,815 ---- shipvals[STARBASE].s_maxshield = 500; shipvals[STARBASE].s_shieldcost = 10; shipvals[STARBASE].s_detcost = 100; + shipvals[STARBASE].s_detdist = 2250; if (configvals->bronco_shipvals) { shipvals[STARBASE].s_cloakcost = 375; shipvals[STARBASE].s_scanrange = -1; *************** *** 856,861 **** --- 874,881 ---- shipvals[ATT].s_torp.cost = 1; shipvals[ATT].s_torp.fuse = 20; shipvals[ATT].s_torp.wtemp = 1; + shipvals[ATT].s_torp.wtemp_halfarc = 0; + shipvals[ATT].s_torp.wtemp_factor = 0; shipvals[ATT].s_torp.aux = 1; shipvals[ATT].s_phaser.damage = 110; shipvals[ATT].s_phaser.speed = 32000; *************** *** 894,899 **** --- 914,920 ---- shipvals[ATT].s_maxshield = 30000; shipvals[ATT].s_shieldcost = 1; shipvals[ATT].s_detcost = 1; + shipvals[ATT].s_detdist = 3000; shipvals[ATT].s_cloakcost = 1; shipvals[ATT].s_scanrange = 10000; shipvals[ATT].s_numports = 0; *************** *** 962,967 **** --- 983,990 ---- shipvals[JUMPSHIP].s_torp.cost = 1000; shipvals[JUMPSHIP].s_torp.fuse = 10; shipvals[JUMPSHIP].s_torp.wtemp = 99; + shipvals[JUMPSHIP].s_torp.wtemp_halfarc = 32; + shipvals[JUMPSHIP].s_torp.wtemp_factor = 9; shipvals[JUMPSHIP].s_torp.aux = 0; shipvals[JUMPSHIP].s_phaser.damage = 25; shipvals[JUMPSHIP].s_phaser.speed = 3000; *************** *** 1006,1011 **** --- 1029,1035 ---- shipvals[JUMPSHIP].s_maxshield = 5; shipvals[JUMPSHIP].s_shieldcost = 5; shipvals[JUMPSHIP].s_detcost = 100; + shipvals[JUMPSHIP].s_detdist = 1200; shipvals[JUMPSHIP].s_cloakcost = 1000; shipvals[JUMPSHIP].s_scanrange = -1; shipvals[JUMPSHIP].s_numports = 4; *************** *** 1064,1069 **** --- 1088,1095 ---- shipvals[FRIGATE].s_torp.cost = 290; shipvals[FRIGATE].s_torp.fuse = 40; shipvals[FRIGATE].s_torp.wtemp = 19; + shipvals[FRIGATE].s_torp.wtemp_halfarc = 32; + shipvals[FRIGATE].s_torp.wtemp_factor = 9; shipvals[FRIGATE].s_torp.aux = 0; #ifndef OLDSHIPVALS shipvals[FRIGATE].s_phaser.damage = 102; *************** *** 1118,1123 **** --- 1144,1150 ---- shipvals[FRIGATE].s_maxshield = 115; shipvals[FRIGATE].s_shieldcost = 5; shipvals[FRIGATE].s_detcost = 100; + shipvals[FRIGATE].s_detdist = 1700; if (configvals->bronco_shipvals) shipvals[FRIGATE].s_cloakcost = 140; else *************** *** 1190,1195 **** --- 1217,1224 ---- shipvals[WARBASE].s_torp.fuse = 18; #endif shipvals[WARBASE].s_torp.wtemp = 35; + shipvals[WARBASE].s_torp.wtemp_halfarc = 32; + shipvals[WARBASE].s_torp.wtemp_factor = 9; shipvals[WARBASE].s_torp.aux = 0; #ifndef OLDSHIPVALS shipvals[WARBASE].s_phaser.damage = 125; *************** *** 1237,1242 **** --- 1266,1272 ---- shipvals[WARBASE].s_maxshield = 250; shipvals[WARBASE].s_shieldcost = 10; shipvals[WARBASE].s_detcost = 100; + shipvals[WARBASE].s_detdist = 2000; shipvals[WARBASE].s_cloakcost = 1000; shipvals[WARBASE].s_scanrange = 5000; shipvals[WARBASE].s_numports = 2; *************** *** 1298,1303 **** --- 1328,1335 ---- #endif shipvals[LIGHTCRUISER].s_torp.fuse = 35; shipvals[LIGHTCRUISER].s_torp.wtemp = 16; + shipvals[LIGHTCRUISER].s_torp.wtemp_halfarc = 32; + shipvals[LIGHTCRUISER].s_torp.wtemp_factor = 9; shipvals[LIGHTCRUISER].s_torp.aux = 0; shipvals[LIGHTCRUISER].s_phaser.damage = 90; #ifndef OLDSHIPVALS *************** *** 1347,1352 **** --- 1379,1385 ---- shipvals[LIGHTCRUISER].s_maxshield = 95; shipvals[LIGHTCRUISER].s_shieldcost = 4; shipvals[LIGHTCRUISER].s_detcost = 100; + shipvals[LIGHTCRUISER].s_detdist = 1700; if (configvals->bronco_shipvals) shipvals[LIGHTCRUISER].s_cloakcost = 115; else *************** *** 1415,1420 **** --- 1448,1455 ---- shipvals[CARRIER].s_torp.fuse = 35; shipvals[CARRIER].s_torp.wtemp = 20; /* still used when fighters fire! */ + shipvals[CARRIER].s_torp.wtemp_halfarc = 32; + shipvals[CARRIER].s_torp.wtemp_factor = 9; shipvals[CARRIER].s_torp.aux = 0; shipvals[CARRIER].s_phaser.damage = 95; shipvals[CARRIER].s_phaser.speed = 6500; *************** *** 1461,1466 **** --- 1496,1502 ---- shipvals[CARRIER].s_maxshield = 120; shipvals[CARRIER].s_shieldcost = 5; shipvals[CARRIER].s_detcost = 100; + shipvals[CARRIER].s_detdist = 1875; if (configvals->bronco_shipvals) shipvals[CARRIER].s_cloakcost = 135; else *************** *** 1525,1530 **** --- 1561,1568 ---- shipvals[UTILITY].s_torp.cost = 250; shipvals[UTILITY].s_torp.fuse = 25; shipvals[UTILITY].s_torp.wtemp = 18; + shipvals[UTILITY].s_torp.wtemp_halfarc = 16; + shipvals[UTILITY].s_torp.wtemp_factor = 4; shipvals[UTILITY].s_torp.aux = 0; shipvals[UTILITY].s_phaser.damage = 80; shipvals[UTILITY].s_phaser.speed = 5600; *************** *** 1569,1574 **** --- 1607,1613 ---- shipvals[UTILITY].s_maxshield = 120; shipvals[UTILITY].s_shieldcost = 4; shipvals[UTILITY].s_detcost = 100; + shipvals[UTILITY].s_detdist = 1925; if (configvals->bronco_shipvals) shipvals[UTILITY].s_cloakcost = 180; else *************** *** 1629,1634 **** --- 1668,1675 ---- shipvals[PATROL].s_torp.cost = 180; shipvals[PATROL].s_torp.fuse = 18; shipvals[PATROL].s_torp.wtemp = 10; + shipvals[PATROL].s_torp.wtemp_halfarc = 32; + shipvals[PATROL].s_torp.wtemp_factor = 9; shipvals[PATROL].s_torp.aux = 0; shipvals[PATROL].s_phaser.damage = 50; shipvals[PATROL].s_phaser.speed = 5000; *************** *** 1673,1678 **** --- 1714,1720 ---- shipvals[PATROL].s_maxshield = 50; shipvals[PATROL].s_shieldcost = 2; shipvals[PATROL].s_detcost = 100; + shipvals[PATROL].s_detdist = 1200; if (configvals->bronco_shipvals) shipvals[PATROL].s_cloakcost = 40; else diff -rc server-2.4p7/src/struct.h server-2.4p8/src/struct.h *** server-2.4p7/src/struct.h Tue Jun 27 15:37:00 1995 --- server-2.4p8/src/struct.h Thu Jul 20 10:49:54 1995 *************** *** 56,61 **** --- 56,63 ---- short cost; /* fuel cost */ short fuse; /* how long they last */ short wtemp; /* weapon temperature cost */ + short wtemp_halfarc; /* Arc the penalty is calculated from */ + short wtemp_factor; /* Penalty Factor 1-16 of wtemp caused */ short count; /* how many we can have airborne */ short aux; /* aux field */ /* aux is turn rate for torps and plasmas. */ *************** *** 91,96 **** --- 93,104 ---- struct weaponstat s_plasma; /* plasma characteristics */ short s_missilestored; /* how many missiles can we store? */ + /* Raynfala's Butt Torp Code. Gjor's Ship Patch for his code to do it */ + /* for each ship. */ + + short s_torp_penalty_halfarc; + short s_torp_penalty_factor; + int s_maxwpntemp; /* max W-temp */ short s_wpncoolrate; /* weapon cool rate */ *************** *** 121,126 **** --- 129,135 ---- int s_shieldcost; /* cost in fuel of shields being up */ short s_detcost; /* fuel cost of detting */ + int s_detdist; /* fuel cost of detting */ short s_cloakcost; /* base fuel cost of cloaking */ short s_scanrange; /* range of the ship's scanners */ diff -rc server-2.4p7/src/structdesc.c server-2.4p8/src/structdesc.c *** server-2.4p7/src/structdesc.c Tue Mar 21 11:59:33 1995 --- server-2.4p8/src/structdesc.c Thu Jul 20 10:49:58 1995 *************** *** 81,86 **** --- 81,88 ---- {"torp.cost", FT_SHORT, OFFSET_OF(s_torp.cost)}, {"torp.fuse", FT_SHORT, OFFSET_OF(s_torp.fuse)}, {"torp.wtemp", FT_SHORT, OFFSET_OF(s_torp.wtemp)}, + {"torp.wtemp_halfarc", FT_SHORT, OFFSET_OF(s_torp.wtemp_halfarc)}, + {"torp.wtemp_factor", FT_SHORT, OFFSET_OF(s_torp.wtemp_factor)}, {"torpturns", FT_SHORT, OFFSET_OF(s_torp.aux)}, /* name anomaly */ {"phaser.damage", FT_SHORT, OFFSET_OF(s_phaser.damage)}, diff -rc server-2.4p7/src/torp.c server-2.4p8/src/torp.c *** server-2.4p7/src/torp.c Tue Mar 21 12:00:51 1995 --- server-2.4p8/src/torp.c Thu Jul 20 10:50:04 1995 *************** *** 69,74 **** --- 69,75 ---- { register int i; /* looping var */ register struct torp *k; /* to point to a torp */ + register unsigned char buttangle; if (me->p_flags & PFWEP) { /* no firing while */ warning("Torpedo launch tubes have exceeded maximum safe temperature!"); *************** *** 107,114 **** me->p_ntorp++; /* inc torps in the air */ me->p_fuel -= myship->s_torp.cost; /* dec the fuel */ ! me->p_wtemp += myship->s_torp.wtemp; /* Heat weapons */ ! for (i = me->p_no * MAXTORP, k = &torps[i]; /* Find a free torp */ i < me->p_no * MAXTORP + MAXTORP; i++, k++) { if (k->t_status == TFREE) break; --- 108,136 ---- me->p_ntorp++; /* inc torps in the air */ me->p_fuel -= myship->s_torp.cost; /* dec the fuel */ ! #ifdef BUTTORP_PENALTY ! /* figure out absolute difference of arc between rear of ship and torp */ ! if ((buttangle = course - me->p_dir - 128) > 128) buttangle = 256 - buttangle; ! ! /* Check if in penalty limit. Ships with no "front" are exempt, of course */ ! if (myship->s_type == WARBASE || myship->s_type == STARBASE || myship->s_type == ! JUMPSHIP || TORP_PENALTY_HALFARC < buttangle) { ! me->p_wtemp += myship->s_torp.wtemp; ! } ! else ! { ! /* You call that dogfighting? Bad dog! No biscuit! Bad dog! */ ! me->p_wtemp += myship->s_torp.wtemp + ! ( myship->s_torp.wtemp * ! (TORP_PENALTY_HALFARC - buttangle) * ! TORP_PENALTY_FACTOR * ! me->p_speed ! ) / (TORP_PENALTY_HALFARC * myship->s_imp.maxspeed); ! } ! #else ! me->p_wtemp += myship->s_torp.wtemp; ! #endif ! for (i = me->p_no * MAXTORP, k = &torps[i]; /* Find a free torp */ i < me->p_no * MAXTORP + MAXTORP; i++, k++) { if (k->t_status == TFREE) break;