forked from github/server
remove race.precombatspell
This commit is contained in:
parent
a754975ef9
commit
daa7554361
|
@ -1283,7 +1283,6 @@
|
|||
<attack type="4" damage="5d30"/>
|
||||
<attack type="6" spell="drain_skills" level="12"/>
|
||||
<attack type="6" spell="aura_of_fear" level="12"/>
|
||||
<precombatspell spell="shadowcall"/>
|
||||
</race>
|
||||
<race name="shadowbat" magres="80" maxaura="0.000000" regaura="0.000000" weight="500" capacity="540" speed="1.000000" hp="1" ac="4" damage="2d4" unarmedattack="0" unarmeddefense="0" attackmodifier="3" defensemodifier="3" scarepeasants="yes" fly="yes" walk="yes" teach="no" getitem="yes">
|
||||
<ai splitsize="5000" killpeasants="yes"/>
|
||||
|
|
|
@ -277,7 +277,6 @@ void free_races(void) {
|
|||
free(at->data.dice);
|
||||
}
|
||||
}
|
||||
spellref_free(races->precombatspell);
|
||||
free(xrefs);
|
||||
xrefs = 0;
|
||||
free(races->_name);
|
||||
|
@ -337,7 +336,6 @@ race *rc_create(const char *zName)
|
|||
assert(strchr(zName, ' ') == NULL);
|
||||
}
|
||||
rc->_name = strdup(zName);
|
||||
rc->precombatspell = NULL;
|
||||
|
||||
rc->attack[0].type = AT_COMBATSPELL;
|
||||
for (i = 1; i < RACE_ATTACKS; ++i)
|
||||
|
|
|
@ -138,7 +138,6 @@ extern "C" {
|
|||
int df_default; /* Verteidigungsskill Unbewaffnet (default: -2) */
|
||||
int at_bonus; /* Ver<65>ndert den Angriffsskill (default: 0) */
|
||||
int df_bonus; /* Ver<65>ndert den Verteidigungskill (default: 0) */
|
||||
struct spellref *precombatspell;
|
||||
signed char *study_speed; /* study-speed-bonus in points/turn (0=30 Tage) */
|
||||
int flags;
|
||||
int battle_flags;
|
||||
|
|
|
@ -1849,17 +1849,6 @@ static int parse_races(xmlDocPtr doc)
|
|||
}
|
||||
xmlXPathFreeObject(result);
|
||||
|
||||
/* reading eressea/races/race/precombatspell */
|
||||
xpath->node = node;
|
||||
result = xmlXPathEvalExpression(BAD_CAST "precombatspell", xpath);
|
||||
assert(rc->precombatspell == NULL
|
||||
|| !"precombatspell is already initialized");
|
||||
for (k = 0; k != result->nodesetval->nodeNr; ++k) {
|
||||
xmlNodePtr node = result->nodesetval->nodeTab[k];
|
||||
rc->precombatspell = xml_spellref(node, "spell");
|
||||
}
|
||||
xmlXPathFreeObject(result);
|
||||
|
||||
/* reading eressea/races/race/attack */
|
||||
xpath->node = node;
|
||||
result = xmlXPathEvalExpression(BAD_CAST "attack", xpath);
|
||||
|
|
|
@ -561,13 +561,6 @@ const spell *get_combatspell(const unit * u, int nr)
|
|||
if (m) {
|
||||
return m->combatspells[nr].sp;
|
||||
}
|
||||
else {
|
||||
const race * rc = u_race(u);
|
||||
if (rc->precombatspell) {
|
||||
return spellref_get(rc->precombatspell);
|
||||
}
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue