forked from github/server
goblin verteidigung nicht mehr hardgecodet sondern als race->df_default
This commit is contained in:
parent
06cdb2b292
commit
1f0e649185
|
@ -1,6 +1,6 @@
|
||||||
/* vi: set ts=2:
|
/* vi: set ts=2:
|
||||||
*
|
*
|
||||||
* $Id: battle.c,v 1.12 2001/02/14 01:38:50 enno Exp $
|
* $Id: battle.c,v 1.13 2001/02/14 08:35:12 katze Exp $
|
||||||
* Eressea PB(E)M host Copyright (C) 1998-2000
|
* Eressea PB(E)M host Copyright (C) 1998-2000
|
||||||
* Christian Schlittchen (corwin@amber.kn-bremen.de)
|
* Christian Schlittchen (corwin@amber.kn-bremen.de)
|
||||||
* Katja Zedel (katze@felidae.kn-bremen.de)
|
* Katja Zedel (katze@felidae.kn-bremen.de)
|
||||||
|
@ -598,6 +598,14 @@ weapon_skill(const weapon_type * wtype, const unit * u, boolean attacking)
|
||||||
} else {
|
} else {
|
||||||
skill = race[u->race].df_default;
|
skill = race[u->race].df_default;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
/* der rassen-defaultwert kann höher sein als der Talentwert von
|
||||||
|
* waffenloser kampf */
|
||||||
|
if (attacking) {
|
||||||
|
if (skill < race[u->race].at_default) skill = race[u->race].at_default;
|
||||||
|
} else {
|
||||||
|
if (skill < race[u->race].df_default) skill = race[u->race].df_default;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
/* changed: if we own a weapon, we have at least a skill of 0 */
|
/* changed: if we own a weapon, we have at least a skill of 0 */
|
||||||
|
@ -606,12 +614,14 @@ weapon_skill(const weapon_type * wtype, const unit * u, boolean attacking)
|
||||||
if (attacking) {
|
if (attacking) {
|
||||||
skill += wtype->offmod;
|
skill += wtype->offmod;
|
||||||
} else {
|
} else {
|
||||||
|
/* Fernkämpfer haben im Nahkampf Talent 0 */
|
||||||
if (fval(wtype, WTF_MISSILE)) skill = 0;
|
if (fval(wtype, WTF_MISSILE)) skill = 0;
|
||||||
else {
|
else {
|
||||||
skill += wtype->defmod;
|
skill += wtype->defmod;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
/* Rassenbonus auf Kampf */
|
||||||
if (attacking) {
|
if (attacking) {
|
||||||
skill += race[u->race].at_bonus;
|
skill += race[u->race].at_bonus;
|
||||||
} else {
|
} else {
|
||||||
|
@ -659,8 +669,7 @@ weapon_effskill(troop t, troop enemy, const weapon * w, boolean attacking, boole
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Burgenbonus, Pferdebonus. Der Waffenabhängige wird aber * nicht hier
|
/* Burgenbonus, Pferdebonus */
|
||||||
* gemacht, sondern in weapon_effskill */
|
|
||||||
if (riding(t) && (wtype==NULL || !fval(wtype, WTF_MISSILE))) {
|
if (riding(t) && (wtype==NULL || !fval(wtype, WTF_MISSILE))) {
|
||||||
skill += 2;
|
skill += 2;
|
||||||
#ifdef BETA_CODE
|
#ifdef BETA_CODE
|
||||||
|
@ -671,8 +680,9 @@ weapon_effskill(troop t, troop enemy, const weapon * w, boolean attacking, boole
|
||||||
}
|
}
|
||||||
|
|
||||||
if (t.index<tf->elvenhorses) {
|
if (t.index<tf->elvenhorses) {
|
||||||
/* Elfenpferde: Helfen dem Reiter, egal ob und welche Waffe. Das ist eleganter, und
|
/* Elfenpferde: Helfen dem Reiter, egal ob und welche Waffe. Das ist
|
||||||
* vor allem einfacher, sonst muß man noch ein WMF_ELVENHORSE einbauen. */
|
* eleganter, und vor allem einfacher, sonst muß man noch ein
|
||||||
|
* WMF_ELVENHORSE einbauen. */
|
||||||
skill += 2;
|
skill += 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1515,9 +1525,10 @@ skilldiff(troop at, troop dt, int dist)
|
||||||
skdiff -= buildingeffsize(df->building, false);
|
skdiff -= buildingeffsize(df->building, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* Goblin-Verteidigung */
|
/* Goblin-Verteidigung
|
||||||
|
* ist direkt in der Rassentabelle als df_default
|
||||||
if (du->race == RC_GOBLIN && dwp == NULL) skdiff -= 2;
|
if (du->race == RC_GOBLIN && dwp == NULL) skdiff -= 2;
|
||||||
|
*/
|
||||||
|
|
||||||
/* Effekte der Waffen */
|
/* Effekte der Waffen */
|
||||||
skdiff += weapon_effskill(at, dt, awp, true, dist>1);
|
skdiff += weapon_effskill(at, dt, awp, true, dist>1);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* vi: set ts=2:
|
/* vi: set ts=2:
|
||||||
*
|
*
|
||||||
* $Id: race.c,v 1.4 2001/02/03 13:45:32 enno Exp $
|
* $Id: race.c,v 1.5 2001/02/14 08:35:12 katze Exp $
|
||||||
* Eressea PB(E)M host Copyright (C) 1998-2000
|
* Eressea PB(E)M host Copyright (C) 1998-2000
|
||||||
* Christian Schlittchen (corwin@amber.kn-bremen.de)
|
* Christian Schlittchen (corwin@amber.kn-bremen.de)
|
||||||
* Katja Zedel (katze@felidae.kn-bremen.de)
|
* Katja Zedel (katze@felidae.kn-bremen.de)
|
||||||
|
@ -65,6 +65,12 @@
|
||||||
* familiars
|
* familiars
|
||||||
* */
|
* */
|
||||||
|
|
||||||
|
/* at_default, df_default
|
||||||
|
* Angriffs- bzw. Verteidigungswert von Unbewaffneten dieser Rasse, die
|
||||||
|
* nicht waffenlosen Kampf können. */
|
||||||
|
/* at_bonus, df_bonus
|
||||||
|
* Angriffs- bzw. Verteidigungsbonus auf den Kampfskill, der zusätzlich
|
||||||
|
* zum Talentwert gilt. */
|
||||||
|
|
||||||
/** dragon movement **/
|
/** dragon movement **/
|
||||||
boolean
|
boolean
|
||||||
|
@ -189,7 +195,7 @@ struct racedata race[MAXRACES] =
|
||||||
{"Goblin", "Goblins", "Goblins", "Goblin"},
|
{"Goblin", "Goblins", "Goblins", "Goblin"},
|
||||||
-0.05, 1.00, 1.00,
|
-0.05, 1.00, 1.00,
|
||||||
40, 10, 10000, 1000, 1.0,
|
40, 10, 10000, 1000, 1.0,
|
||||||
16, "1d5", 0, -2, -2, 0, 0,
|
16, "1d5", 0, -2, 0, 0, 0,
|
||||||
{
|
{
|
||||||
{AT_STANDARD, {NULL}, 0}, {AT_NONE, {NULL}, 0}, {AT_NONE, {NULL}, 0},
|
{AT_STANDARD, {NULL}, 0}, {AT_NONE, {NULL}, 0}, {AT_NONE, {NULL}, 0},
|
||||||
{AT_NONE, {NULL}, 0}, {AT_NONE, {NULL}, 0}, {AT_NONE, {NULL}, 0},
|
{AT_NONE, {NULL}, 0}, {AT_NONE, {NULL}, 0}, {AT_NONE, {NULL}, 0},
|
||||||
|
|
Loading…
Reference in New Issue