(MINE_LDAMAGE): Change to match damage suffered in lnd_hit_mine().

This increases damage suffered in retreat.  Fix info Damage.
(shp_hit_mine): Use MINE_DAMAGE().
(lnd_hit_mine): Use MINE_LDAMAGE().
This commit is contained in:
Markus Armbruster 2006-03-27 21:47:50 +00:00
parent 07015c3613
commit 9f658368b8
4 changed files with 5 additions and 5 deletions

View file

@ -40,7 +40,7 @@
#define DMINE_HITCHANCE(x) ((double) ( (x) / ((x)+20.0) ) ) #define DMINE_HITCHANCE(x) ((double) ( (x) / ((x)+20.0) ) )
#define DMINE_LHITCHANCE(x) ((double) ( (x) / ((x)+35.0) ) ) #define DMINE_LHITCHANCE(x) ((double) ( (x) / ((x)+35.0) ) )
#define MINE_DAMAGE() (22 + random()%21) #define MINE_DAMAGE() (22 + random()%21)
#define MINE_LDAMAGE() (10 + random()%11) #define MINE_LDAMAGE() (11 + random()%20)
#define DTORP_HITCHANCE(range, vis) ((double)(0.9/((range)+1)+(((vis)<6)?(5-(vis))*0.03:0))) #define DTORP_HITCHANCE(range, vis) ((double)(0.9/((range)+1)+(((vis)<6)?(5-(vis))*0.03:0)))
#define TORP_DAMAGE() (torpedo_damage + (random() % torpedo_damage) + \ #define TORP_DAMAGE() (torpedo_damage + (random() % torpedo_damage) + \
(random() % torpedo_damage)) (random() % torpedo_damage))

View file

@ -32,11 +32,11 @@ Whether you get a blam, Blam, or a BLAM depends on the accuracy of the
plane and the difficulty of the target (see info bomb). plane and the difficulty of the target (see info bomb).
Land mines Land mines
Land mines damage commodities by random(20) and land units by 10 + random(10). Land mines damage commodities by random(20) and land units by 10 + random(20).
If the land unit is an engineer, then the damags is cut in half. If the land unit is an engineer, then the damags is cut in half.
Sea mines Sea mines
Sea mines damage ships 22 + random(20). If the ship can sweep, then Sea mines damage ships 21 + random(21). If the ship can sweep, then
the damage is cut in half. the damage is cut in half.
Nuclear Detonation Nuclear Detonation

View file

@ -1019,7 +1019,7 @@ lnd_hit_mine(struct lndstr *lp, struct lchrstr *lcp)
nreport(lp->lnd_own, N_LHIT_MINE, 0, 1); nreport(lp->lnd_own, N_LHIT_MINE, 0, 1);
m = roll(20) + 10; m = MINE_LDAMAGE();
if (lcp->l_flags & L_ENGINEER) if (lcp->l_flags & L_ENGINEER)
m /= 2.0; m /= 2.0;

View file

@ -775,7 +775,7 @@ shp_hit_mine(struct shpstr *sp, struct mchrstr *mcp)
nreport(sp->shp_own, N_HIT_MINE, 0, 1); nreport(sp->shp_own, N_HIT_MINE, 0, 1);
m = 22.0 + (double)(random() % 21); m = MINE_DAMAGE();
if (mcp->m_flags & M_SWEEP) if (mcp->m_flags & M_SWEEP)
m /= 2.0; m /= 2.0;