diff --git a/src/common/gamecode/creport.c b/src/common/gamecode/creport.c index e9796c549..d3b8422a2 100644 --- a/src/common/gamecode/creport.c +++ b/src/common/gamecode/creport.c @@ -983,12 +983,12 @@ cr_reportspell(FILE * F, spellid_t id, const struct locale * lang) if (!(sp->sptyp & NOTFAMILIARCAST)) fputs("1;familiar\n", F); fputs("KOMPONENTEN\n", F); - for (k = 0; k < MAXINGREDIENT; k++) { - resource_t res = sp->komponenten[k][0]; - int itemanz = sp->komponenten[k][1]; - int costtyp = sp->komponenten[k][2]; + for (k = 0; sp->components[k].type; ++k) { + const resource_type * rtype = sp->components[k].type; + int itemanz = sp->components[k].amount; + int costtyp = sp->components[k].cost; if (itemanz > 0) { - const char * name = resname(res, 0); + const char * name = resourcename(rtype, 0); fprintf(F, "%d %d;%s\n", itemanz, costtyp == SPC_LEVEL || costtyp == SPC_LINEAR, add_translation(name, LOC(lang, name))); } diff --git a/src/common/gamecode/report.c b/src/common/gamecode/report.c index 8488d46a7..2f72187ff 100644 --- a/src/common/gamecode/report.c +++ b/src/common/gamecode/report.c @@ -402,7 +402,6 @@ static void report_spell(FILE * F, spellid_t id, const struct locale * lang) { int k, itemanz, costtyp; - resource_t res; int dh = 0; spell *sp = find_spellbyid(id); char * bufp; @@ -430,13 +429,13 @@ report_spell(FILE * F, spellid_t id, const struct locale * lang) strcpy(buf, "Komponenten:"); rps(F, buf); - for (k = 0; k < MAXINGREDIENT; k++) { - res = sp->komponenten[k][0]; - itemanz = sp->komponenten[k][1]; - costtyp = sp->komponenten[k][2]; - if(itemanz > 0){ + for (k = 0; sp->components[k].type; ++k) { + const resource_type * rtype = sp->components[k].type; + itemanz = sp->components[k].amount; + costtyp = sp->components[k].cost; + if (itemanz > 0){ if (sp->sptyp & SPELLLEVEL) { - bufp = buf + sprintf(buf, " %d %s", itemanz, LOC(lang, resname(res, itemanz!=1))); + bufp = buf + sprintf(buf, " %d %s", itemanz, LOC(lang, resourcename(rtype, itemanz!=1))); if (costtyp == SPC_LEVEL || costtyp == SPC_LINEAR ) { bufp += strxcpy(bufp, " * Stufe"); } @@ -444,7 +443,7 @@ report_spell(FILE * F, spellid_t id, const struct locale * lang) if (costtyp == SPC_LEVEL || costtyp == SPC_LINEAR ) { itemanz *= sp->level; } - sprintf(buf, " %d %s", itemanz, LOC(lang, resname(res, itemanz!=1))); + sprintf(buf, " %d %s", itemanz, LOC(lang, resourcename(rtype, itemanz!=1))); } rps(F, buf); } diff --git a/src/common/kernel/alchemy.c b/src/common/kernel/alchemy.c index c83b2b199..476f42907 100644 --- a/src/common/kernel/alchemy.c +++ b/src/common/kernel/alchemy.c @@ -100,10 +100,7 @@ use_potion(unit * u, const item_type * itype, int amount, struct order *ord) return ECUSTOM; } - if (ptype->use) { - int nRetval = ptype->use(u, ptype, amount, ord); - if (nRetval) return nRetval; - } else if (ptype==oldpotiontype[P_LIFE]) { + if (ptype==oldpotiontype[P_LIFE]) { region * r = u->region; int holz = 0; diff --git a/src/common/kernel/alchemy.h b/src/common/kernel/alchemy.h index 2a6ffeab7..0bdac409b 100644 --- a/src/common/kernel/alchemy.h +++ b/src/common/kernel/alchemy.h @@ -52,32 +52,6 @@ enum { NOPOTION = (potion_t) - 1 }; -enum { - H_PLAIN_1, - H_PLAIN_2, - H_PLAIN_3, - H_FOREST_1, - H_FOREST_2, - H_FOREST_3, - H_SWAMP_1, - H_SWAMP_2, - H_SWAMP_3, - H_DESERT_1, - H_DESERT_2, - H_DESERT_3, - H_HIGHLAND_1, - H_HIGHLAND_2, - H_HIGHLAND_3, - H_MOUNTAIN_1, - H_MOUNTAIN_2, - H_MOUNTAIN_3, - H_GLACIER_1, - H_GLACIER_2, - H_GLACIER_3, - MAX_HERBS, - NOHERB = (herb_t) - 1 -}; - herb_t rherb2herb(struct region *r); void herbsearch(struct region * r, struct unit * u, int max); int use_potion(struct unit * u, const struct item_type * itype, int amount, struct order *); diff --git a/src/common/kernel/eressea.h b/src/common/kernel/eressea.h index a29f6e08c..d00ae038f 100644 --- a/src/common/kernel/eressea.h +++ b/src/common/kernel/eressea.h @@ -99,7 +99,6 @@ struct building_type; /* feature-dis/en-able */ #define NEW_DRIVE /* Neuer Algorithmus Transportiere/Fahre */ #define PARTIAL_STUDY /* Wenn nicht genug Silber vorhanden, wird ein Talent anteilig gelernt */ -#define NEW_RECEIPIES /* Vereinfachte, besser verteilte Kräuterzutaten für Tränke */ #define GOBLINKILL #define MONSTER_FACTION 0 /* Die Partei, in der die Monster sind. */ diff --git a/src/common/kernel/item.c b/src/common/kernel/item.c index 7dd90b6d9..91bd0278b 100644 --- a/src/common/kernel/item.c +++ b/src/common/kernel/item.c @@ -55,6 +55,32 @@ potion_type * potiontypes; #define IMAXHASH 127 static item_type * itemtypes[IMAXHASH]; +enum { + H_PLAIN_1, + H_PLAIN_2, + H_PLAIN_3, + H_FOREST_1, + H_FOREST_2, + H_FOREST_3, + H_SWAMP_1, + H_SWAMP_2, + H_SWAMP_3, + H_DESERT_1, + H_DESERT_2, + H_DESERT_3, + H_HIGHLAND_1, + H_HIGHLAND_2, + H_HIGHLAND_3, + H_MOUNTAIN_1, + H_MOUNTAIN_2, + H_MOUNTAIN_3, + H_GLACIER_1, + H_GLACIER_2, + H_GLACIER_3, + MAX_HERBS, + NOHERB = (herb_t) - 1 +}; + static int res_changeaura(unit * u, const resource_type * rtype, int delta) { @@ -351,8 +377,9 @@ rt_find(const char * name) unsigned int hash = hashstring(name); resource_type * rtype; - for (rtype=resourcetypes; rtype; rtype=rtype->next) - if (rtype->hashkey==hash && !strcmp(rtype->_name[0], name)) break; + for (rtype=resourcetypes; rtype; rtype=rtype->next) { + if (rtype->hashkey==hash && !strcmp(rtype->_name[0], name)) break; + } return rtype; } @@ -1198,286 +1225,12 @@ init_olditems(void) } } -const char *herbdata[3][MAXHERBS] = -{ - { - "Flachwurz", /* PLAIN_1 */ - "Würziger Wagemut", /* PLAIN_2 */ - "Eulenauge", /* PLAIN_3 */ - "Grüner Spinnerich", /* H_FOREST_1 */ - "Blauer Baumringel", - "Elfenlieb", - "Gurgelkraut", /* SWAMP_1 */ - "Knotiger Saugwurz", - "Blasenmorchel", /* SWAMP_3 */ - "Wasserfinder", - "Kakteenschwitz", - "Sandfäule", - "Windbeutel", /* HIGHLAND_1 */ - "Fjordwuchs", - "Alraune", - "Steinbeißer", /* MOUNTAIN_1 */ - "Spaltwachs", - "Höhlenglimm", - "Eisblume", /* GLACIER_1 */ - "Weißer Wüterich", - "Schneekristall" - }, - { - "Flachwurz", - "Würzige Wagemut", - "Eulenaugen", - "Grüne Spinneriche", - "Blaue Baumringel", - "Elfenlieb", - "Gurgelkräuter", - "Knotige Saugwurze", - "Blasenmorcheln", - "Wasserfinder", - "Kakteenschwitze", - "Sandfäulen", - "Windbeutel", - "Fjordwuchse", - "Alraunen", - "Steinbeißer", - "Spaltwachse", - "Höhlenglimme", - "Eisblumen", - "Weiße Wüteriche", - "Schneekristalle" - }, - { - "4", - "10", - "7", - "2", - "4", - "1", - "5", - "5", - "4", - "3", - "3", - "5", - "4", - "6", - "1", - "3", - "1", - "5", - "1", - "1", - "3" - } -}; - -void -init_oldherbs(void) -{ - herb_t h; - const char * names[2]; - const char * appearance[2] = { "herbbag", "herbbag" }; - - const struct locale * lang = find_locale("de"); - assert(lang); - - for (h=0;h!=MAXHERBS;++h) { - item_type * itype; - resource_type * rtype; - - names[0] = NULL; - { - int ci; - for (ci=0;translation[ci][0];++ci) { - if (!strcmp(translation[ci][0], herbdata[0][h])) { - names[0] = translation[ci][1]; - names[1] = translation[ci][2]; - } - } - } - if (!names[0]) { - names[0] = reverse_lookup(lang, herbdata[0][h]); - names[1] = reverse_lookup(lang, herbdata[1][h]); - } - - rtype = new_resourcetype(names, appearance, RTF_ITEM|RTF_POOLED); - itype = new_itemtype(rtype, ITF_HERB, 0, 0); - - oldresourcetype[herb2res(h)] = rtype; - } -} - const item_type * oldherbtype(herb_t h) { return oldresourcetype[herb2res(h)]->itype; } - -static const char *potionnames[3][MAXPOTIONS] = -{ - { - /* Stufe 1: */ - "Siebenmeilentee", - "Goliathwasser", - "Wasser des Lebens", - /* Stufe 2: */ - "Schaffenstrunk", - "Wundsalbe", - "Bauernblut", - /* Stufe 3: */ - "Gehirnschmalz", - "Dumpfbackenbrot", - "Nestwärme", - "Pferdeglück", - "Berserkerblut", - /* Stufe 4: */ - "Bauernlieb", - "Trank der Wahrheit", - "Elixier der Macht", - "Heiltrank" - }, - { - /* Stufe 1: */ - "Siebenmeilentees", - "Goliathwasser", - "Wasser des Lebens", - /* Stufe 2: */ - "Schaffenstrünke", - "Wundsalben", - "Bauernblut", - /* Stufe 3: */ - "Gehirnschmalz", - "Dumpfbackenbrote", - "Nestwärme", - "Pferdeglück", - "Berserkerblut", - /* Stufe 4: */ - "Bauernlieb", - "Tränke der Wahrheit", - "Elixiere der Macht", - "Heiltränke" - }, - { - /* Stufe 1: */ - "einen Siebenmeilentee", - "ein Goliathwasser", - "ein Wasser des Lebens", - /* Stufe 2: */ - "einen Schaffenstrunk", - "eine Wundsalbe", - "ein Bauernblut", - /* Stufe 3: */ - "ein Gehirnschmalz", - "ein Dumpfbackenbrot", - "eine Nestwärme", - "ein Pferdeglück", - "ein Berserkerblut", - /* Stufe 4: */ - "ein Bauernlieb", - "ein Trank der Wahrheit", - "ein Elixier der Macht", - "einen Heiltrank" - } -}; - -int potionlevel[MAXPOTIONS] = -{ - 1, - 1, - 1, - 2, - 2, - 2, - 3, - 3, - 3, - 3, - 3, - 4, - 1, - 4, - 4 -}; - -#ifdef NEW_RECEIPIES -herb_t potionherbs[MAXPOTIONS][MAXHERBSPERPOTION] = -{ /* Benötigte Kräuter */ - /* Stufe 1: */ - /* Siebenmeilentee: */ - {H_FOREST_2, H_HIGHLAND_1, NOHERB, NOHERB, NOHERB, NOHERB}, - /* Goliathwasser: */ - {H_SWAMP_1, H_HIGHLAND_2, NOHERB, NOHERB, NOHERB, NOHERB}, - /* Wasser des Lebens: */ - {H_FOREST_3, H_SWAMP_2, NOHERB, NOHERB, NOHERB, NOHERB}, - /* Stufe 2: */ - /* Schaffenstrunk: */ - {H_HIGHLAND_3, H_MOUNTAIN_2, H_PLAIN_2, NOHERB, NOHERB, NOHERB}, - /* Wundsalbe: */ - {H_GLACIER_2, H_FOREST_2, H_PLAIN_2, NOHERB, NOHERB, NOHERB}, - /* Bauernblut: */ - {H_MOUNTAIN_3, H_HIGHLAND_2, H_FOREST_2, NOHERB, NOHERB, NOHERB}, - /* Stufe 3: */ - /* Gehirnschmalz: */ - {H_DESERT_1, H_MOUNTAIN_1, H_HIGHLAND_1, H_SWAMP_1, NOHERB, NOHERB}, - /* Dumpfbackenbrote: */ - {H_PLAIN_3, H_FOREST_1, H_MOUNTAIN_3, H_HIGHLAND_2, NOHERB, NOHERB}, - /* Nestwärme: */ - {H_GLACIER_1, H_FOREST_1, H_MOUNTAIN_2, H_DESERT_2, NOHERB, NOHERB}, - /* Pferdeglueck: */ - {H_FOREST_2, H_DESERT_3, H_DESERT_2, H_SWAMP_2, NOHERB, NOHERB}, - /* Berserkerblut: */ - {H_GLACIER_2, H_HIGHLAND_3, H_PLAIN_1, H_DESERT_3, NOHERB, NOHERB}, - /* Stufe 4: */ - /* Bauernlieb: */ - {H_HIGHLAND_3, H_GLACIER_3, H_MOUNTAIN_1, H_SWAMP_3, H_FOREST_3, NOHERB}, - /* Trank der Wahrheit: */ - {H_PLAIN_1, H_HIGHLAND_2, NOHERB, NOHERB, NOHERB, NOHERB}, - /* Elixier der Macht: */ - {H_FOREST_3, H_DESERT_1, H_HIGHLAND_1, H_FOREST_1, H_SWAMP_3, NOHERB}, - /* Heiltrank: */ - {H_SWAMP_1, H_HIGHLAND_1, H_GLACIER_1, H_FOREST_3, H_MOUNTAIN_2, NOHERB} -}; -#else -herb_t potionherbs[MAXPOTIONS][MAXHERBSPERPOTION] = -{ /* Benötigte Kräuter */ - /* Stufe 1: */ - /* Siebenmeilentee: */ - {H_PLAIN_2, H_FOREST_1, H_HIGHLAND_1, NOHERB, NOHERB, NOHERB}, - /* Goliathwasser: */ - {H_PLAIN_1, H_SWAMP_3, H_HIGHLAND_2, NOHERB, NOHERB, NOHERB}, - /* Wasser des Lebens: */ - {H_FOREST_2, H_PLAIN_1, H_SWAMP_2, NOHERB, NOHERB, NOHERB}, - /* Stufe 2: */ - /* Schaffenstrunk: */ - {H_PLAIN_1, H_HIGHLAND_2, H_MOUNTAIN_1, H_PLAIN_2, NOHERB, NOHERB}, - /* Scheusalsbier/Wundsalbe: */ - {H_FOREST_2, H_MOUNTAIN_3, H_FOREST_1, H_PLAIN_3, NOHERB, NOHERB}, - /* Duft der Rose/Bauernblut: */ - {H_MOUNTAIN_1, H_HIGHLAND_1, H_FOREST_2, H_PLAIN_2, NOHERB, NOHERB}, - /* Stufe 3: */ - /* Gehirnschmalz: */ - {H_FOREST_1, H_DESERT_1, H_MOUNTAIN_3, H_HIGHLAND_1, H_SWAMP_1, NOHERB}, - /* Dumpfbackenbrote: */ - {H_PLAIN_1, H_FOREST_1, H_MOUNTAIN_2, H_SWAMP_2, H_HIGHLAND_1, NOHERB}, - /* Stahlpasten/Nestwärme: */ - {H_GLACIER_3, H_FOREST_2, H_MOUNTAIN_3, H_DESERT_1, H_SWAMP_3, NOHERB}, - /* Pferdeglueck: */ - {H_FOREST_3, H_DESERT_2, H_HIGHLAND_1, H_MOUNTAIN_1, H_SWAMP_3, NOHERB}, - /* Berserkerblut: */ - {H_GLACIER_2, H_MOUNTAIN_1, H_HIGHLAND_1, H_PLAIN_2, H_DESERT_2, NOHERB}, - /* Stufe 4: */ - /* Bauernlieb: */ - {H_FOREST_1, H_HIGHLAND_2, H_GLACIER_3, H_MOUNTAIN_2, H_SWAMP_3, H_FOREST_3}, - /* Riesengras/Trank der Wahrheit: */ - {H_PLAIN_1, H_SWAMP_3, H_HIGHLAND_1, NOHERB, NOHERB, NOHERB}, - /* Faulobstschnaps/Elixier der Macht: */ - {H_FOREST_2, H_DESERT_3, H_HIGHLAND_3, H_FOREST_1, H_SWAMP_2, H_SWAMP_1}, - /* Heiltrank: */ - {H_SWAMP_1, H_PLAIN_3, H_HIGHLAND_3, H_GLACIER_1, H_FOREST_1, H_MOUNTAIN_3} -}; -#endif - static const char *potiontext[MAXPOTIONS] = { /* Stufe 1: */ @@ -1609,7 +1362,7 @@ heal(unit * user, int effect) } static int -use_healingpotion(struct unit *user, const struct potion_type *ptype, int amount, struct order * ord) +use_healingpotion(struct unit *user, const struct item_type *itype, int amount, struct order * ord) { int effect = amount * 400; unit * u = user->region->units; @@ -1620,13 +1373,17 @@ use_healingpotion(struct unit *user, const struct potion_type *ptype, int amount } u = u->next; } + new_use_pooled(user, itype->rtype, GET_SLACK|GET_RESERVE|GET_POOLED_SLACK, amount); + usetpotionuse(user, itype->rtype->ptype); + + ADDMSG(&user->faction->msgs, msg_message("usepotion", + "unit potion", user, itype->rtype)); return 0; } static int -use_warmthpotion(struct unit *u, const struct potion_type *ptype, int amount, struct order * ord) +use_warmthpotion(struct unit *u, const struct item_type *itype, int amount, struct order * ord) { - assert(ptype==oldpotiontype[P_WARMTH]); if (u->faction->race == new_race[RC_INSECT]) { fset(u, UFL_WARMTH); } else { @@ -1634,8 +1391,12 @@ use_warmthpotion(struct unit *u, const struct potion_type *ptype, int amount, st cmistake(u, ord, 163, MSG_EVENT); return ECUSTOM; } - unused(ptype); - return 0; + new_use_pooled(u, itype->rtype, GET_SLACK|GET_RESERVE|GET_POOLED_SLACK, amount); + usetpotionuse(u, itype->rtype->ptype); + + ADDMSG(&u->faction->msgs, msg_message("usepotion", + "unit potion", u, itype->rtype)); + return 0; } static int @@ -1652,19 +1413,17 @@ use_foolpotion(struct unit *u, int targetno, const struct item_type *itype, int } ADDMSG(&u->faction->msgs, msg_message("givedumb", "unit recipient amount", u, target, amount)); - assert(oldpotiontype[P_FOOL]->itype==itype); - change_effect(target, oldpotiontype[P_FOOL], amount); + + change_effect(target, itype->rtype->ptype, amount); new_use_pooled(u, itype->rtype, GET_DEFAULT, amount); return 0; } static int -use_bloodpotion(struct unit *u, const struct potion_type *ptype, int amount, struct order * ord) +use_bloodpotion(struct unit *u, const struct item_type *itype, int amount, struct order * ord) { - assert(ptype==oldpotiontype[P_BAUERNBLUT]); - unused(ptype); if (u->race == new_race[RC_DAEMON] ) { - change_effect(u, ptype, 100*amount); + change_effect(u, itype->rtype->ptype, 100*amount); } else { trigger * trestore = trigger_changerace(u, u->race, u->irace); int duration = 2 + rand() % 8; @@ -1672,6 +1431,11 @@ use_bloodpotion(struct unit *u, const struct potion_type *ptype, int amount, str add_trigger(&u->attribs, "timer", trigger_timeout(duration, trestore)); u->irace = u->race = new_race[RC_TOAD]; } + new_use_pooled(u, itype->rtype, GET_SLACK|GET_RESERVE|GET_POOLED_SLACK, amount); + usetpotionuse(u, itype->rtype->ptype); + + ADDMSG(&u->faction->msgs, msg_message("usepotion", + "unit potion", u, itype->rtype)); return 0; } @@ -1728,85 +1492,17 @@ use_snowball(struct unit * user, const struct item_type * itype, int amount, str static void init_oldpotions(void) { + const char * potionnames[MAX_POTIONS] = { + "p0", "goliathwater", "p2", "p3", "p4", "peasantblood", "p6", + "p7", "nestwarmth", "p9", "p10", "p11", "truthpotion", "p13", "p14" + }; potion_t p; - const char * names[2]; - const char * appearance[2] = { "vial", "vial_p" }; - const struct locale * lang = find_locale("de"); - assert(lang); - - for (p=0;p!=MAXPOTIONS;++p) { - item_type * itype; - resource_type * rtype; - construction * con = calloc(sizeof(construction), 1); - int i = 0; - while (i!=MAXHERBSPERPOTION && potionherbs[p][i]!=NOHERB) ++i; - if (p==P_BAUERNBLUT || p==P_MACHT) ++i; - - con->materials = calloc(sizeof(requirement), i + 1); - for (i=0;i!=MAXHERBSPERPOTION && potionherbs[p][i]!=NOHERB;++i) { -#ifdef NO_OLD_ITEMS - con->materials[i].rtype = oldresourcetype[herb2res(potionherbs[p][i])]; -#else - con->materials[i].type = herb2res(potionherbs[p][i]); -#endif - con->materials[i].number = 1; - con->materials[i].recycle = 0; - } - if (p == P_BAUERNBLUT) { - con->materials[i].number = 1; - con->materials[i].recycle = 0; -#ifdef NO_OLD_ITEMS - con->materials[i].rtype = oldresourcetype[R_PEASANTS]; -#else - con->materials[i].type = R_PEASANTS; -#endif - ++i; - } - else if (p == P_MACHT) { - con->materials[i].number = 1; - con->materials[i].recycle = 0; -#ifdef NO_OLD_ITEMS - con->materials[i].rtype = oldresourcetype[R_DRACHENBLUT]; -#else - con->materials[i].type = R_DRACHENBLUT; -#endif - ++i; - } - con->skill = SK_ALCHEMY; - con->minskill = potionlevel[p]*2; - con->maxsize = -1; - con->reqsize = 1; - - names[0] = NULL; - { - int ci; - for (ci=0;translation[ci][0];++ci) { - if (!strcmp(translation[ci][0], potionnames[0][p])) { - names[0] = translation[ci][1]; - names[1] = translation[ci][2]; - } - } - } - if (!names[0]) { - names[0] = reverse_lookup(lang, potionnames[0][p]); - names[1] = reverse_lookup(lang, potionnames[1][p]); - } - - rtype = new_resourcetype(names, appearance, RTF_ITEM|RTF_POOLED); - if (p==P_FOOL) rtype->flags |= RTF_SNEAK; - oldresourcetype[potion2res(p)] = rtype; - itype = new_itemtype(rtype, ITF_POTION, 0, 0); - itype->construction = con; - itype->use = use_potion; - oldpotiontype[p] = new_potiontype(itype, (terrain_t)p/3); - oldpotiontype[p]->level = potionlevel[p]; - oldpotiontype[p]->text = potiontext[p]; - if (p==P_FOOL) itype->useonother = &use_foolpotion; + for (p=0;p!=MAXPOTIONS;++p) { + item_type * itype = it_find(potionnames[p]); + itype->rtype->ptype->text = potiontext[p]; + oldpotiontype[p] = itype->rtype->ptype; } - oldpotiontype[P_WARMTH]->use = &use_warmthpotion; - oldpotiontype[P_HEILWASSER]->use = &use_healingpotion; - oldpotiontype[P_BAUERNBLUT]->use = &use_bloodpotion; } resource_type * r_silver; @@ -1924,7 +1620,6 @@ init_resources(void) /* alte typen registrieren: */ init_olditems(); - init_oldherbs(); init_oldpotions(); init_oldscores(); } @@ -2127,6 +1822,7 @@ register_resources(void) register_function((pf_generic)use_birthdayamulet, "usebirthdayamulet"); register_function((pf_generic)use_warmthpotion, "usewarmthpotion"); register_function((pf_generic)use_bloodpotion, "usebloodpotion"); + register_function((pf_generic)use_healingpotion, "usehealingpotion"); register_function((pf_generic)use_foolpotion, "usefoolpotion"); register_function((pf_generic)use_mistletoe, "usemistletoe"); register_function((pf_generic)use_magicboost, "usemagicboost"); diff --git a/src/common/kernel/item.h b/src/common/kernel/item.h index 6c2fe7036..ed8d3381a 100644 --- a/src/common/kernel/item.h +++ b/src/common/kernel/item.h @@ -49,8 +49,8 @@ typedef int (*rtype_uget)(const struct unit * user, const struct resource_type * typedef char * (*rtype_name)(const struct resource_type * rtype, int flags); typedef struct resource_type { /* --- constants --- */ - const char * _name[2]; /* wie es heißt */ - const char * _appearance[2]; /* wie es für andere aussieht */ + char * _name[2]; /* wie es heißt */ + char * _appearance[2]; /* wie es für andere aussieht */ unsigned int flags; /* --- functions --- */ rtype_uchange uchange; @@ -137,7 +137,6 @@ typedef struct potion_type { const item_type * itype; int level; const char * text; - int (*use)(struct unit *, const struct potion_type *, int, struct order *); } potion_type; extern potion_type * potiontypes; diff --git a/src/common/kernel/magic.c b/src/common/kernel/magic.c index 12424f1b5..d0430cd1a 100644 --- a/src/common/kernel/magic.c +++ b/src/common/kernel/magic.c @@ -718,12 +718,12 @@ spellcost(unit *u, const spell * sp) int k, aura = 0; int count = countspells(u, 0); - for (k = 0; k < MAXINGREDIENT; k++) { - if (sp->komponenten[k][0] == R_AURA) { - aura = sp->komponenten[k][1]; - } + for (k = 0; sp->components[k].type; k++) { + if (sp->components[k].type == r_aura) { + aura = sp->components[k].amount; + } } - aura *= (int)pow(2.0,(double)count); + aura *= (1<components[k].type; k++) { if (costtyp == SPC_LINEAR) return SPC_LINEAR; - if (sp->komponenten[k][2] == SPC_LINEAR) { + if (sp->components[k].cost == SPC_LINEAR) { return SPC_LINEAR; } /* wenn keine Fixkosten, Typ übernehmen */ - if (sp->komponenten[k][2] != SPC_FIX) { - costtyp = sp->komponenten[k][2]; + if (sp->components[k].cost != SPC_FIX) { + costtyp = sp->components[k].cost; } } return costtyp; @@ -770,32 +770,32 @@ eff_spelllevel(unit *u, const spell * sp, int cast_level, int range) int needplevel; int costtyp = SPC_FIX; - for (k = 0; k < MAXINGREDIENT; k++) { + for (k = 0; sp->components[k].type; k++) { if (cast_level == 0) return 0; - if (sp->komponenten[k][1] > 0) { + if (sp->components[k].amount > 0) { /* Die Kosten für Aura sind auch von der Zahl der bereits * gezauberten Sprüche abhängig */ - if (sp->komponenten[k][0] == R_AURA) { + if (sp->components[k].type == r_aura) { needplevel = spellcost(u, sp) * range; } else { - needplevel = sp->komponenten[k][1] * range; + needplevel = sp->components[k].amount * range; } - maxlevel = get_pooled(u, u->region, sp->komponenten[k][0])/needplevel; + maxlevel = new_get_pooled(u, sp->components[k].type, GET_DEFAULT)/needplevel; /* sind die Kosten fix, so muss die Komponente nur einmal vorhanden * sein und der cast_level ändert sich nicht */ - if (sp->komponenten[k][2] == SPC_FIX) { + if (sp->components[k].cost == SPC_FIX) { if (maxlevel < 1) cast_level = 0; /* ansonsten wird das Minimum aus maximal möglicher Stufe und der * gewünschten gebildet */ - } else if (sp->komponenten[k][2] == SPC_LEVEL) { + } else if (sp->components[k].cost == SPC_LEVEL) { costtyp = SPC_LEVEL; cast_level = min(cast_level, maxlevel); /* bei Typ Linear müssen die Kosten in Höhe der Stufe vorhanden * sein, ansonsten schlägt der Spruch fehl */ - } else if (sp->komponenten[k][2] == SPC_LINEAR) { + } else if (sp->components[k].cost == SPC_LINEAR) { costtyp = SPC_LINEAR; if (maxlevel < cast_level) cast_level = 0; } @@ -823,20 +823,20 @@ pay_spell(unit * u, const spell * sp, int cast_level, int range) int k; int resuse; - for (k = 0; k != MAXINGREDIENT; k++) { - if (sp->komponenten[k][0] == R_AURA) { + for (k = 0; sp->components[k].type; k++) { + if (sp->components[k].type == r_aura) { resuse = spellcost(u, sp) * range; } else { - resuse = sp->komponenten[k][1] * range; + resuse = sp->components[k].amount * range; } - if (sp->komponenten[k][2] == SPC_LINEAR - || sp->komponenten[k][2] == SPC_LEVEL) + if (sp->components[k].cost == SPC_LINEAR + || sp->components[k].cost == SPC_LEVEL) { resuse *= cast_level; } - use_pooled(u, u->region, sp->komponenten[k][0], resuse); + new_use_pooled(u, sp->components[k].type, resuse, GET_DEFAULT); } } @@ -888,7 +888,6 @@ boolean cancast(unit * u, const spell * sp, int level, int range, struct order * ord) { int k; - resource_t res; int itemanz; boolean b = true; @@ -904,21 +903,21 @@ cancast(unit * u, const spell * sp, int level, int range, struct order * ord) return false; } - for (k = 0; k < MAXINGREDIENT; k++) { - if (sp->komponenten[k][1] > 0) { - res = sp->komponenten[k][0]; + for (k = 0; sp->components[k].type; ++k) { + if (sp->components[k].amount > 0) { + const resource_type * rtype = sp->components[k].type; /* Die Kosten für Aura sind auch von der Zahl der bereits * gezauberten Sprüche abhängig */ - if (sp->komponenten[k][0] == R_AURA) { + if (rtype == r_aura) { itemanz = spellcost(u, sp) * range; } else { - itemanz = sp->komponenten[k][1] * range; + itemanz = sp->components[k].amount * range; } /* sind die Kosten stufenabhängig, so muss itemanz noch mit dem * level multipliziert werden */ - switch(sp->komponenten[k][2]) { + switch(sp->components[k].cost) { case SPC_LEVEL: case SPC_LINEAR: itemanz *= level; @@ -928,7 +927,7 @@ cancast(unit * u, const spell * sp, int level, int range, struct order * ord) break; } - if (get_pooled(u, u->region, res) < itemanz) { + if (new_get_pooled(u, rtype, GET_DEFAULT) < itemanz) { if (b == false) { /* es fehlte schon eine andere Komponente, wir basteln die * Meldung weiter zusammen */ @@ -939,7 +938,7 @@ cancast(unit * u, const spell * sp, int level, int range, struct order * ord) } icat(itemanz); scat(" "); - scat(LOC(u->faction->locale, resname(res, itemanz!=1))); + scat(LOC(u->faction->locale, resourcename(rtype, (itemanz!=1)?NMF_PLURAL:0))); } } } @@ -2755,10 +2754,7 @@ magic(void) const char * spell_info(const spell * sp, const struct locale * lang) { - if (sp->info==NULL) { - return LOC(lang, mkname("spellinfo", sp->sname)); - } - return sp->info; + return LOC(lang, mkname("spellinfo", sp->sname)); } const char * diff --git a/src/common/kernel/magic.h b/src/common/kernel/magic.h index 1faadb39d..bb6f54070 100644 --- a/src/common/kernel/magic.h +++ b/src/common/kernel/magic.h @@ -145,17 +145,22 @@ typedef int (*cspell_f) (struct fighter*, int, double, const struct spell * sp); /* zauber-patzer: */ typedef void (*pspell_f) (castorder *); +typedef struct spell_component { + const struct resource_type * type; + int amount; + int cost; +} spell_component; + typedef struct spell { spellid_t id; - const char *sname; - const char *info; - const char *syntax; - const char *parameter; + char *sname; + char *syntax; + char *parameter; magic_t magietyp; int sptyp; char rank; /* Reihenfolge der Zauber */ int level; /* Stufe des Zaubers */ - resource_t komponenten[MAXINGREDIENT][3]; + struct spell_component * components; spell_f sp_function; void (*patzer) (castorder*); } spell; diff --git a/src/common/kernel/xmlreader.c b/src/common/kernel/xmlreader.c index 77680e17c..dc5f2eb19 100644 --- a/src/common/kernel/xmlreader.c +++ b/src/common/kernel/xmlreader.c @@ -130,6 +130,22 @@ xml_cleanup_string(xmlChar * str) return str; } +static const resource_type * +rt_findorcreate(const char * name) +{ + resource_type * rtype = rt_find(name); + if (rtype==NULL) { + const char * names[2]; + char * namep = strcat(strcpy((char*)malloc(strlen(name)+3), name), "_p"); + /* we'll make a placeholder */ + names[0] = name; + names[1] = namep; + rtype = new_resourcetype(names, NULL, RTF_NONE); + free(namep); + } + return rtype; +} + static void xml_readrequirements(xmlNodePtr * nodeTab, int nodeNr, requirement ** reqArray) { @@ -147,12 +163,11 @@ xml_readrequirements(xmlNodePtr * nodeTab, int nodeNr, requirement ** reqArray) const resource_type * rtype; resource_t type; - radd->number = xml_ivalue(node, "quantity", 0); + radd->number = xml_ivalue(node, "quantity", 1); radd->recycle = xml_fvalue(node, "recycle", 0.0); property = xmlGetProp(node, BAD_CAST "type"); - rtype = rt_find((const char*)property); - assert(rtype!=NULL); + rtype = rt_findorcreate((const char*)property); for (type=0;type!=MAX_RESOURCES;++type) { if (oldresourcetype[type]==rtype) { radd->type = type; @@ -563,6 +578,16 @@ race_compat(void) } } +static potion_type * +xml_readpotion(xmlXPathContextPtr xpath, item_type * itype) +{ + int level = xml_ivalue(xpath->node, "level", 0); + + assert(level>0); + return new_potiontype(itype, level); +} + + static armor_type * xml_readarmor(xmlXPathContextPtr xpath, item_type * itype) { @@ -693,6 +718,7 @@ xml_readitem(xmlXPathContextPtr xpath, resource_type * rtype) if (xml_bvalue(node, "cursed", false)) flags |= ITF_CURSED; if (xml_bvalue(node, "notlost", false)) flags |= ITF_NOTLOST; + if (xml_bvalue(node, "herb", false)) flags |= ITF_HERB; if (xml_bvalue(node, "big", false)) flags |= ITF_BIG; if (xml_bvalue(node, "animal", false)) flags |= ITF_ANIMAL; itype = new_itemtype(rtype, flags, weight, capacity); @@ -717,6 +743,17 @@ xml_readitem(xmlXPathContextPtr xpath, resource_type * rtype) } xmlXPathFreeObject(result); + /* reading item/potion */ + xpath->node = node; + result = xmlXPathEvalExpression(BAD_CAST "potion", xpath); + assert(result->nodesetval->nodeNr<=1); + if (result->nodesetval->nodeNr!=0) { + itype->flags |= ITF_POTION; + xpath->node = result->nodesetval->nodeTab[0]; + rtype->ptype = xml_readpotion(xpath, itype); + } + xmlXPathFreeObject(result); + /* reading item/armor */ xpath->node = node; result = xmlXPathEvalExpression(BAD_CAST "armor", xpath); @@ -770,43 +807,56 @@ parse_resources(xmlDocPtr doc) xmlNodeSetPtr nodes; int i; - /* make sure old items (used in requirements) are available */ - init_resources(); - /* reading eressea/resources/resource */ resources = xmlXPathEvalExpression(BAD_CAST "/eressea/resources/resource", xpath); nodes = resources->nodesetval; for (i=0;i!=nodes->nodeNr;++i) { xmlNodePtr node = nodes->nodeTab[i]; - xmlChar * property; - char *names[2], *appearance[2]; + xmlChar *property, *name, *appearance; + const char *names[2], *appearances[2]; + char * namep = NULL, * appearancep = NULL; resource_type * rtype; unsigned int flags = RTF_NONE; xmlXPathObjectPtr result; int k; if (xml_bvalue(node, "pooled", true)) flags |= RTF_POOLED; + if (xml_bvalue(node, "sneak", true)) flags |= RTF_SNEAK; - property = xmlGetProp(node, BAD_CAST "name"); - assert(property!=NULL); - names[0] = strdup((const char*)property); - names[1] = strcat(strcpy((char*)malloc(strlen(names[0])+3), names[0]), "_p"); - xmlFree(property); + name = xmlGetProp(node, BAD_CAST "name"); + appearance = xmlGetProp(node, BAD_CAST "appearance"); + assert(name!=NULL); - property = xmlGetProp(node, BAD_CAST "appearance"); - if (property!=NULL) { - assert(property!=NULL); - appearance[0] = strdup((const char*)property); - appearance[1] = strcat(strcpy((char*)malloc(strlen(appearance[0])+3), appearance[0]), "_p"); - rtype = new_resourcetype((const char**)names, (const char**)appearance, flags); - xmlFree(property); - free(appearance[0]); - free(appearance[1]); - } else { - rtype = new_resourcetype((const char**)names, NULL, flags); + if (appearance!=NULL) { + appearancep = strcat(strcpy((char*)malloc(strlen((char*)appearance)+3), (char*)appearance), "_p"); } - free(names[0]); - free(names[1]); + + rtype = rt_find((const char *)name); + if (rtype!=NULL) { + /* dependency from another item, was created earlier */ + rtype->flags |= flags; + if (appearance) { + rtype->_appearance[0] = strdup((const char*)appearance); + rtype->_appearance[1] = appearancep; + free(appearancep); + } + } else { + namep = strcat(strcpy((char*)malloc(strlen((char*)name)+3), (char*)name), "_p"); + names[0] = (const char*)name; + names[1] = namep; + if (appearance) { + appearances[0] = (const char*)appearance; + appearances[1] = appearancep; + rtype = new_resourcetype((const char**)names, (const char**)appearances, flags); + free(appearancep); + } else { + rtype = new_resourcetype(names, NULL, flags); + } + free(namep); + } + + if (name) xmlFree(name); + if (appearance) xmlFree(appearance); if (gamecode_enabled) { /* reading eressea/resources/resource/function */ @@ -892,6 +942,9 @@ parse_resources(xmlDocPtr doc) xmlXPathFreeContext(xpath); + /* make sure old items (used in requirements) are available */ + init_resources(); + /* old resources now extern (for spells */ oldresourcetype[R_SWORD] = rt_find("sword"); @@ -1158,32 +1211,29 @@ parse_spells(xmlDocPtr doc) /* reading eressea/spells/spell/resource */ xpath->node = node; result = xmlXPathEvalExpression(BAD_CAST "resource", xpath); - for (k=0;k!=result->nodesetval->nodeNr && k!=MAXINGREDIENT;++k) { + if (result->nodesetval->nodeNr) { + sp->components = malloc(sizeof(spell_component)*(result->nodesetval->nodeNr+1)); + sp->components[result->nodesetval->nodeNr].type = 0; + } + for (k=0;k!=result->nodesetval->nodeNr;++k) { xmlNodePtr node = result->nodesetval->nodeTab[k]; - resource_t res; - sp->komponenten[k][0] = 0; property = xmlGetProp(node, BAD_CAST "name"); assert(property); - for (res=0;res!=MAX_RESOURCES;++res) { - if (strcmp(oldresourcetype[res]->_name[0], (const char *)property)==0) { - sp->komponenten[k][0] = res; - break; - } - } + sp->components[k].type = rt_find((const char *)property); + assert(sp->components[k].type); xmlFree(property); - sp->komponenten[k][1] = (resource_t)xml_ivalue(node, "amount", 1); - sp->komponenten[k][2] = SPC_FIX; + sp->components[k].amount = (resource_t)xml_ivalue(node, "amount", 1); + sp->components[k].cost = SPC_FIX; property = xmlGetProp(node, BAD_CAST "cost"); if (property!=NULL) { if (strcmp((const char *)property, "linear")==0) { - sp->komponenten[k][2] = SPC_LINEAR; + sp->components[k].cost = SPC_LINEAR; } else if (strcmp((const char *)property, "level")==0) { - sp->komponenten[k][2] = SPC_LEVEL; + sp->components[k].cost = SPC_LEVEL; } xmlFree(property); } } - if (kkomponenten[k][0] = 0; xmlXPathFreeObject(result); sp->id = 0; register_spell(sp); @@ -1496,6 +1546,7 @@ parse_terrains(xmlDocPtr doc) property = xmlGetProp(nodeProd, BAD_CAST "name"); assert(property!=NULL); terrain->production[k].type = rt_find((const char*)property); + assert(terrain->production[k].type); xmlFree(property); property = xmlGetProp(nodeProd, BAD_CAST "level"); diff --git a/src/common/spells/spells.c b/src/common/spells/spells.c index 653d55a48..4a8c561c1 100644 --- a/src/common/spells/spells.c +++ b/src/common/spells/spells.c @@ -7172,7 +7172,26 @@ sp_earn_silver(castorder *co) return co->level; } -static spell spelldaten[] = +typedef struct spelldata { + spellid_t id; + const char *sname; + const char *info; + const char *syntax; + const char *parameter; + magic_t magietyp; + int sptyp; + char rank; /* Reihenfolge der Zauber */ + int level; /* Stufe des Zaubers */ + struct component { + const char * name; + int amount; + int flags; + } components[5]; + spell_f sp_function; + void (*patzer) (castorder*); +} spelldata; + +static spelldata spelldaten[] = { /* M_DRUIDE */ { @@ -7181,7 +7200,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | REGIONSPELL), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7196,7 +7215,7 @@ static spell spelldaten[] = (SPELLLEVEL|ONSHIPCAST), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7208,9 +7227,9 @@ static spell spelldaten[] = SPL_STONEGOLEM, "stonegolem", NULL, NULL, NULL, M_DRUIDE, (SPELLLEVEL), 4, 1, { - { R_AURA, 2, SPC_LEVEL }, - { R_STONE, 1, SPC_LEVEL }, - { R_TREES, 1, SPC_FIX }, + { "aura", 2, SPC_LEVEL }, + { "stone", 1, SPC_LEVEL }, + { "p2", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -7220,9 +7239,9 @@ static spell spelldaten[] = SPL_IRONGOLEM, "irongolem", NULL, NULL, NULL, M_DRUIDE, (SPELLLEVEL), 4, 2, { - { R_AURA, 2, SPC_LEVEL }, - { R_IRON, 1, SPC_LEVEL }, - { R_TREES, 1, SPC_FIX }, + { "aura", 2, SPC_LEVEL }, + { "iron", 1, SPC_LEVEL }, + { "p2", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -7234,9 +7253,9 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 5, 2, { - { R_AURA, 4, SPC_LEVEL }, - { R_WOOD, 1, SPC_LEVEL }, - { R_TREES, 1, SPC_FIX }, + { "aura", 4, SPC_LEVEL }, + { "log", 1, SPC_LEVEL }, + { "p2", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -7249,7 +7268,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | UNITSPELL | TESTCANSEE | TESTRESISTANCE), 5, 3, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7264,7 +7283,7 @@ static spell spelldaten[] = (UNITSPELL | SPELLLEVEL | TESTCANSEE | ONSHIPCAST), 5, 3, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7276,7 +7295,7 @@ static spell spelldaten[] = SPL_HAGEL, "hail", NULL, NULL, NULL, M_DRUIDE, (COMBATSPELL|SPELLLEVEL), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7290,7 +7309,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 5, 3, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7304,9 +7323,9 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | REGIONSPELL | ONSHIPCAST | TESTRESISTANCE), 5, 4, { - { R_AURA, 1, SPC_LEVEL }, - { R_STONE, 1, SPC_FIX }, - { R_WOOD, 1, SPC_FIX }, + { "aura", 1, SPC_LEVEL }, + { "stone", 1, SPC_FIX }, + { "log", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -7316,7 +7335,7 @@ static spell spelldaten[] = SPL_WINDSHIELD, "windshield", NULL, NULL, NULL, M_DRUIDE, (PRECOMBATSPELL | SPELLLEVEL), 5, 4, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7330,9 +7349,9 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 5, 4, { - { R_AURA, 6, SPC_LEVEL }, - { R_MALLORN, 1, SPC_LEVEL }, - { R_TREES, 1, SPC_FIX }, + { "aura", 6, SPC_LEVEL }, + { "mallorn", 1, SPC_LEVEL }, + { "p2", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -7344,7 +7363,7 @@ static spell spelldaten[] = (SHIPSPELL|ONSHIPCAST|SPELLLEVEL|ONETARGET|TESTRESISTANCE), 5, 4, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7356,7 +7375,7 @@ static spell spelldaten[] = SPL_HEALING, "healing", NULL, NULL, NULL, M_DRUIDE, (POSTCOMBATSPELL | SPELLLEVEL), 5, 5, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7368,7 +7387,7 @@ static spell spelldaten[] = SPL_REELING_ARROWS, "reelingarrows", NULL, NULL, NULL, M_DRUIDE, (PRECOMBATSPELL | SPELLLEVEL), 5, 5, { - { R_AURA, 15, SPC_FIX }, + { "aura", 15, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7380,7 +7399,7 @@ static spell spelldaten[] = SPL_GWYRRD_FUMBLESHIELD, "gwyrrdfumbleshield", NULL, NULL, NULL, M_DRUIDE, (PRECOMBATSPELL | SPELLLEVEL), 2, 5, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7394,7 +7413,7 @@ static spell spelldaten[] = "ui", M_DRUIDE, (UNITSPELL|ONSHIPCAST|ONETARGET), 1, 6, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7406,8 +7425,8 @@ static spell spelldaten[] = SPL_EARTHQUAKE, "earthquake", NULL, NULL, NULL, M_DRUIDE, (FARCASTING|REGIONSPELL|TESTRESISTANCE), 5, 6, { - { R_AURA, 25, SPC_FIX }, - { R_EOG, 2, SPC_FIX }, + { "aura", 25, SPC_FIX }, + { "laen", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7421,7 +7440,7 @@ static spell spelldaten[] = (SHIPSPELL | ONSHIPCAST | OCEANCASTABLE | TESTRESISTANCE | SPELLLEVEL), 5, 6, { - { R_AURA, 6, SPC_LEVEL }, + { "aura", 6, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7433,8 +7452,8 @@ static spell spelldaten[] = SPL_HOMESTONE, "homestone", NULL, NULL, NULL, M_DRUIDE, (0), 5, 7, { - { R_AURA, 50, SPC_FIX }, - { R_PERMAURA, 1, SPC_FIX }, + { "aura", 50, SPC_FIX }, + { "permaura", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7445,7 +7464,7 @@ static spell spelldaten[] = SPL_WOLFHOWL, "wolfhowl", NULL, NULL, NULL, M_DRUIDE, (PRECOMBATSPELL | SPELLLEVEL ), 5, 7, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7457,7 +7476,7 @@ static spell spelldaten[] = SPL_VERSTEINERN, "versteinern", NULL, NULL, NULL, M_DRUIDE, (COMBATSPELL | SPELLLEVEL), 5, 8, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7469,7 +7488,7 @@ static spell spelldaten[] = SPL_STRONG_WALL, "strongwall", NULL, NULL, NULL, M_DRUIDE, (PRECOMBATSPELL | SPELLLEVEL), 5, 8, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7488,7 +7507,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | ONETARGET | TESTCANSEE), 2, 8, { - { R_AURA, 6, SPC_LEVEL }, + { "aura", 6, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7501,7 +7520,7 @@ static spell spelldaten[] = "u+", M_DRUIDE, (UNITSPELL | SPELLLEVEL | TESTCANSEE), 7, 9, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7515,7 +7534,7 @@ static spell spelldaten[] = "ru+", M_DRUIDE, (UNITSPELL | SPELLLEVEL | TESTCANSEE), 7, 9, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7527,8 +7546,8 @@ static spell spelldaten[] = SPL_HOLYGROUND, "holyground", NULL, NULL, NULL, M_DRUIDE, (0), 5, 9, { - { R_AURA, 80, SPC_FIX }, - { R_PERMAURA, 3, SPC_FIX }, + { "aura", 80, SPC_FIX }, + { "permaura", 3, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7539,7 +7558,7 @@ static spell spelldaten[] = SPL_SUMMONENT, "summonent", NULL, NULL, NULL, M_DRUIDE, (SPELLLEVEL), 5, 10, { - { R_AURA, 6, SPC_LEVEL }, + { "aura", 6, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7551,8 +7570,8 @@ static spell spelldaten[] = SPL_GWYRRD_FAMILIAR, "gwyrrdfamiliar", NULL, NULL, NULL, M_DRUIDE, (NOTFAMILIARCAST), 5, 10, { - { R_AURA, 100, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, + { "aura", 100, SPC_FIX }, + { "permaura", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7564,8 +7583,8 @@ static spell spelldaten[] = "b", M_DRUIDE, (BUILDINGSPELL | ONETARGET), 5, 11, { - { R_AURA, 350, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, + { "aura", 350, SPC_FIX }, + { "permaura", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7576,7 +7595,7 @@ static spell spelldaten[] = SPL_GWYRRD_ARMORSHIELD, "barkskin", NULL, NULL, NULL, M_DRUIDE, (PRECOMBATSPELL | SPELLLEVEL), 2, 12, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7588,7 +7607,7 @@ static spell spelldaten[] = SPL_DROUGHT, "summonfireelemental", NULL, NULL, NULL, M_DRUIDE, (FARCASTING|REGIONSPELL|TESTRESISTANCE), 5, 13, { - { R_AURA, 600, SPC_FIX }, + { "aura", 600, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7602,7 +7621,7 @@ static spell spelldaten[] = (FARCASTING|SPELLLEVEL), 5, 14, { - { R_AURA, 8, SPC_LEVEL }, + { "aura", 8, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7620,8 +7639,8 @@ static spell spelldaten[] = (OCEANCASTABLE | ONSHIPCAST | REGIONSPELL | TESTRESISTANCE), 5, 15, { - { R_AURA, 200, SPC_FIX }, - { R_SEASERPENTHEAD, 1, SPC_FIX }, + { "aura", 200, SPC_FIX }, + { "seaserpenthead", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7639,9 +7658,9 @@ static spell spelldaten[] = (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 16, { - { R_AURA, 250, SPC_FIX }, - { R_PERMAURA, 10, SPC_FIX }, - { R_TOADSLIME, 1, SPC_FIX }, + { "aura", 250, SPC_FIX }, + { "permaura", 10, SPC_FIX }, + { "toadslime", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -7659,7 +7678,7 @@ static spell spelldaten[] = (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 17, { - { R_AURA, 800, SPC_FIX }, + { "aura", 800, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7673,7 +7692,7 @@ static spell spelldaten[] = "u", M_CHAOS, (UNITSPELL | TESTCANSEE | SPELLLEVEL | ONETARGET), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7687,7 +7706,7 @@ static spell spelldaten[] = NULL, M_CHAOS, (SPELLLEVEL|ONSHIPCAST), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7699,7 +7718,7 @@ static spell spelldaten[] = SPL_FIREBALL, "fireball", NULL, NULL, NULL, M_CHAOS, (COMBATSPELL | SPELLLEVEL), 5, 2, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7711,7 +7730,7 @@ static spell spelldaten[] = SPL_MAGICBOOST, "magicboost", NULL, NULL, NULL, M_CHAOS, (ONSHIPCAST), 3, 3, { - { R_AURA, 2, SPC_LINEAR }, + { "aura", 2, SPC_LINEAR }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7723,7 +7742,7 @@ static spell spelldaten[] = SPL_BLOODSACRIFICE, "bloodsacrifice", NULL, NULL, NULL, M_CHAOS, (ONSHIPCAST), 1, 4, { - { R_HITPOINTS, 4, SPC_LEVEL }, + { "hp", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7735,8 +7754,8 @@ static spell spelldaten[] = SPL_BERSERK, "berserk", NULL, NULL, NULL, M_CHAOS, (PRECOMBATSPELL | SPELLLEVEL), 4, 5, { - { R_AURA, 5, SPC_LEVEL }, - { R_PEASANTS, 1, SPC_FIX }, + { "aura", 5, SPC_LEVEL }, + { "peasant", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7750,7 +7769,7 @@ static spell spelldaten[] = (UNITSPELL | SPELLLEVEL | ONETARGET | TESTCANSEE | TESTRESISTANCE), 4, 5, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7763,7 +7782,7 @@ static spell spelldaten[] = M_CHAOS, (SPELLLEVEL | FARCASTING | ONSHIPCAST), 5, 6, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7775,7 +7794,7 @@ static spell spelldaten[] = SPL_COMBATRUST, "combatrust", NULL, NULL, NULL, M_CHAOS, (COMBATSPELL | SPELLLEVEL), 5, 6, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7789,7 +7808,7 @@ static spell spelldaten[] = "ui", M_CHAOS, (UNITSPELL|ONSHIPCAST|ONETARGET), 1, 7, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7803,7 +7822,7 @@ static spell spelldaten[] = "c", M_CHAOS, (SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 4, 7, { - { R_AURA, 6, SPC_LEVEL }, + { "aura", 6, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7817,8 +7836,8 @@ static spell spelldaten[] = (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 7, { - { R_AURA, 30, SPC_FIX }, - { R_PEASANTS, 50, SPC_FIX }, + { "aura", 30, SPC_FIX }, + { "peasant", 50, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7829,8 +7848,8 @@ static spell spelldaten[] = SPL_CHAOSROW, "chaosrow", NULL, NULL, NULL, M_CHAOS, (PRECOMBATSPELL | SPELLLEVEL), 5, 8, { - { R_AURA, 3, SPC_LEVEL }, - { R_PEASANTS, 10, SPC_FIX }, + { "aura", 3, SPC_LEVEL }, + { "peasant", 10, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7841,7 +7860,7 @@ static spell spelldaten[] = SPL_SUMMONSHADOW, "summonshadow", NULL, NULL, NULL, M_CHAOS, (SPELLLEVEL), 5, 8, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7853,7 +7872,7 @@ static spell spelldaten[] = SPL_UNDEADHERO, "undeadhero", NULL, NULL, NULL, M_CHAOS, (POSTCOMBATSPELL | SPELLLEVEL), 5, 9, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7865,8 +7884,8 @@ static spell spelldaten[] = SPL_AURALEAK, "auraleak", NULL, NULL, NULL, M_CHAOS, (REGIONSPELL | TESTRESISTANCE), 3, 9, { - { R_AURA, 35, SPC_FIX }, - { R_DRACHENBLUT, 1, SPC_FIX }, + { "aura", 35, SPC_FIX }, + { "dragonblood", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7877,7 +7896,7 @@ static spell spelldaten[] = SPL_DRAIG_FUMBLESHIELD, "draigfumbleshield", NULL, NULL, NULL, M_CHAOS, (PRECOMBATSPELL | SPELLLEVEL), 2, 9, { - { R_AURA, 6, SPC_LEVEL }, + { "aura", 6, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7889,8 +7908,8 @@ static spell spelldaten[] = SPL_FOREST_FIRE, "forestfire", NULL, NULL, NULL, M_CHAOS, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 10, { - { R_AURA, 50, SPC_FIX }, - { R_OIL, 1, SPC_FIX }, + { "aura", 50, SPC_FIX }, + { "oil", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7908,7 +7927,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | ONETARGET | TESTCANSEE), 2, 10, { - { R_AURA, 10, SPC_LEVEL }, + { "aura", 10, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7921,8 +7940,8 @@ static spell spelldaten[] = "u+", M_CHAOS, (UNITSPELL | SPELLLEVEL | TESTCANSEE), 5, 14, { - { R_AURA, 10, SPC_LEVEL }, - { R_PEASANTS, 5, SPC_LEVEL }, + { "aura", 10, SPC_LEVEL }, + { "peasant", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7933,8 +7952,8 @@ static spell spelldaten[] = SPL_DEATHCLOUD, "deathcloud", NULL, NULL, NULL, M_CHAOS, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 11, { - { R_AURA, 40, SPC_FIX }, - { R_HITPOINTS, 15, SPC_FIX }, + { "aura", 40, SPC_FIX }, + { "hp", 15, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7945,8 +7964,8 @@ static spell spelldaten[] = SPL_SUMMONDRAGON, "summondragon", NULL, NULL, NULL, M_CHAOS, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 11, { - { R_AURA, 80, SPC_FIX }, - { R_DRAGONHEAD, 1, SPC_FIX }, + { "aura", 80, SPC_FIX }, + { "dragonhead", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7957,7 +7976,7 @@ static spell spelldaten[] = SPL_SUMMONSHADOWLORDS, "summonshadowlords", NULL, NULL, NULL, M_CHAOS, (SPELLLEVEL), 5, 12, { - { R_AURA, 7, SPC_LEVEL }, + { "aura", 7, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -7969,8 +7988,8 @@ static spell spelldaten[] = SPL_DRAIG_FAMILIAR, "draigfamiliar", NULL, NULL, NULL, M_CHAOS, (NOTFAMILIARCAST), 5, 13, { - { R_AURA, 100, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, + { "aura", 100, SPC_FIX }, + { "permaura", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7981,8 +8000,8 @@ static spell spelldaten[] = SPL_CHAOSSUCTION, "chaossuction", NULL, NULL, NULL, M_CHAOS, (0), 5, 14, { - { R_AURA, 150, SPC_FIX }, - { R_PEASANTS, 200, SPC_FIX }, + { "aura", 150, SPC_FIX }, + { "peasant", 200, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -7997,7 +8016,7 @@ static spell spelldaten[] = (UNITSPELL | TESTCANSEE | SPELLLEVEL | ONETARGET | ONSHIPCAST), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8011,7 +8030,7 @@ static spell spelldaten[] = NULL, M_TRAUM, (SPELLLEVEL|ONSHIPCAST), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8023,7 +8042,7 @@ static spell spelldaten[] = SPL_SHADOWKNIGHTS, "shadowknights", NULL, NULL, NULL, M_TRAUM, (PRECOMBATSPELL | SPELLLEVEL), 4, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8035,7 +8054,7 @@ static spell spelldaten[] = SPL_FLEE, "flee", NULL, NULL, NULL, M_TRAUM, (PRECOMBATSPELL | SPELLLEVEL), 5, 2, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8047,8 +8066,8 @@ static spell spelldaten[] = SPL_PUTTOREST, "puttorest", NULL, NULL, NULL, M_TRAUM, (SPELLLEVEL), 5, 2, { - { R_AURA, 3, SPC_LEVEL }, - { R_TREES, 1, SPC_FIX }, + { "aura", 3, SPC_LEVEL }, + { "p2", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -8061,7 +8080,7 @@ static spell spelldaten[] = "c", M_TRAUM, (0), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8075,7 +8094,7 @@ static spell spelldaten[] = "ui", M_TRAUM, (UNITSPELL|ONSHIPCAST|ONETARGET), 1, 3, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8089,7 +8108,7 @@ static spell spelldaten[] = "uc", M_TRAUM, (UNITSPELL|SPELLLEVEL|ONETARGET), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8102,7 +8121,7 @@ static spell spelldaten[] = "u", M_TRAUM, (FARCASTING | UNITSPELL | ONETARGET | TESTRESISTANCE), 5, 4, { - { R_AURA, 8, SPC_FIX }, + { "aura", 8, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8114,7 +8133,7 @@ static spell spelldaten[] = SPL_TIREDSOLDIERS, "tiredsoldiers", NULL, NULL, NULL, M_TRAUM, (PRECOMBATSPELL | SPELLLEVEL), 5, 4, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8126,7 +8145,7 @@ static spell spelldaten[] = SPL_REANIMATE, "reanimate", NULL, NULL, NULL, M_TRAUM, (POSTCOMBATSPELL | SPELLLEVEL), 4, 5, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8139,7 +8158,7 @@ static spell spelldaten[] = "u", M_TRAUM, (UNITSPELL | ONSHIPCAST | ONETARGET | TESTCANSEE), 5, 5, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8151,7 +8170,7 @@ static spell spelldaten[] = SPL_DISTURBINGDREAMS, "disturbingdreams", NULL, NULL, NULL, M_TRAUM, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 6, { - { R_AURA, 18, SPC_FIX }, + { "aura", 18, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8163,7 +8182,7 @@ static spell spelldaten[] = SPL_SLEEP, "sleep", NULL, NULL, NULL, M_TRAUM, (COMBATSPELL | SPELLLEVEL ), 5, 7, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8181,7 +8200,7 @@ static spell spelldaten[] = "c", M_TRAUM, (SPELLLEVEL | FARCASTING), 5, 7, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8194,7 +8213,7 @@ static spell spelldaten[] = "u", M_TRAUM, (UNITSPELL | ONETARGET), 5, 7, { - { R_AURA, 20, SPC_FIX }, + { "aura", 20, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8208,7 +8227,7 @@ static spell spelldaten[] = (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 8, { - { R_AURA, 80, SPC_FIX }, + { "aura", 80, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8227,7 +8246,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | ONETARGET | TESTCANSEE), 2, 8, { - { R_AURA, 6, SPC_LEVEL }, + { "aura", 6, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8239,8 +8258,8 @@ static spell spelldaten[] = SPL_ILLAUN_FAMILIAR, "illaunfamiliar", NULL, NULL, NULL, M_TRAUM, (NOTFAMILIARCAST), 5, 9, { - { R_AURA, 100, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, + { "aura", 100, SPC_FIX }, + { "permaura", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -8260,10 +8279,10 @@ static spell spelldaten[] = "nach dem Tod zu schwach ist, das neue Gefäß zu erreichen.", NULL, NULL, M_TRAUM, (NOTFAMILIARCAST), 5, 9, { - { R_AURA, 100, SPC_FIX }, - { R_PERMAURA, 20, SPC_FIX }, - { R_DRACHENBLUT, 5, SPC_FIX }, - { R_TREES, 5, SPC_FIX }, + { "aura", 100, SPC_FIX }, + { "permaura", 20, SPC_FIX }, + { "dragonblood", 5, SPC_FIX }, + { "p2", 5, SPC_FIX }, { 0, 0, 0 } }, (spell_f)sp_clonecopy, NULL @@ -8276,7 +8295,7 @@ static spell spelldaten[] = M_TRAUM, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 10, { - { R_AURA, 90, SPC_FIX }, + { "aura", 90, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8288,7 +8307,7 @@ static spell spelldaten[] = SPL_MINDBLAST, "mindblast", NULL, NULL, NULL, M_TRAUM, (COMBATSPELL | SPELLLEVEL), 5, 11, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8302,7 +8321,7 @@ static spell spelldaten[] = M_TRAUM, (UNITSPELL | TESTRESISTANCE | TESTCANSEE | SPELLLEVEL), 5, 12, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8316,9 +8335,9 @@ static spell spelldaten[] = (UNITSPELL | ONETARGET | SEARCHGLOBAL | TESTRESISTANCE), 5, 15, { - { R_AURA, 350, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, - { R_SWAMP_3, 1, SPC_FIX }, + { "aura", 350, SPC_FIX }, + { "permaura", 5, SPC_FIX }, + { "h8", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -8330,7 +8349,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL), 5, 16, { - { R_AURA, 7, SPC_LEVEL }, + { "aura", 7, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8343,7 +8362,7 @@ static spell spelldaten[] = SPL_DENYATTACK, "appeasement", NULL, NULL, NULL, M_BARDE, (PRECOMBATSPELL | SPELLLEVEL ), 5, 1, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8355,7 +8374,7 @@ static spell spelldaten[] = SPL_CERDDOR_EARN_SILVER, "jugglery", NULL, NULL, NULL, M_BARDE, (SPELLLEVEL|ONSHIPCAST), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8367,7 +8386,7 @@ static spell spelldaten[] = SPL_HEALINGSONG, "song_of_healing", NULL, NULL, NULL, M_BARDE, (POSTCOMBATSPELL | SPELLLEVEL), 5, 2, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8381,7 +8400,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | REGIONSPELL | TESTRESISTANCE), 5, 2, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8395,7 +8414,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | REGIONSPELL), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8407,7 +8426,7 @@ static spell spelldaten[] = SPL_SONG_OF_FEAR, "song_of_fear", NULL, NULL, NULL, M_BARDE, (COMBATSPELL | SPELLLEVEL), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8419,7 +8438,7 @@ static spell spelldaten[] = SPL_RECRUIT, "courting", NULL, NULL, NULL, M_BARDE, (SPELLLEVEL), 5, 4, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8431,7 +8450,7 @@ static spell spelldaten[] = SPL_SONG_OF_CONFUSION, "song_of_confusion", NULL, NULL, NULL, M_BARDE, (PRECOMBATSPELL | SPELLLEVEL), 5, 4, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8443,7 +8462,7 @@ static spell spelldaten[] = SPL_BABBLER, "blabbermouth", NULL, NULL, "u", M_BARDE, (UNITSPELL | ONETARGET | TESTCANSEE), 5, 4, { - { R_AURA, 10, SPC_FIX }, + { "aura", 10, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8455,7 +8474,7 @@ static spell spelldaten[] = SPL_HERO, "heroic_song", NULL, NULL, NULL, M_BARDE, (PRECOMBATSPELL | SPELLLEVEL), 4, 5, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8468,7 +8487,7 @@ static spell spelldaten[] = "ui", M_BARDE, (UNITSPELL|ONSHIPCAST|ONETARGET), 1, 5, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8483,7 +8502,7 @@ static spell spelldaten[] = (UNITSPELL | ONSHIPCAST | ONETARGET | TESTCANSEE), 5, 5, { - { R_AURA, 10, SPC_FIX }, + { "aura", 10, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8495,7 +8514,7 @@ static spell spelldaten[] = SPL_CERRDOR_FUMBLESHIELD, "cerrdorfumbleshield", NULL, NULL, NULL, M_BARDE, (PRECOMBATSPELL | SPELLLEVEL), 2, 5, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8513,7 +8532,7 @@ static spell spelldaten[] = (UNITSPELL | ONSHIPCAST | ONETARGET | TESTRESISTANCE | TESTCANSEE), 5, 6, { - { R_AURA, 15, SPC_FIX }, + { "aura", 15, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8531,7 +8550,7 @@ static spell spelldaten[] = (UNITSPELL | ONETARGET | TESTRESISTANCE | TESTCANSEE), 5, 6, { - { R_AURA, 12, SPC_FIX }, + { "aura", 12, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8574,9 +8593,9 @@ static spell spelldaten[] = (UNITSPELL | ONETARGET | TESTRESISTANCE | TESTCANSEE), 5, 7, { - { R_AURA, 4, SPC_LINEAR }, - { R_SWAMP_2, 3, SPC_FIX }, - { R_SILVER, 50, SPC_FIX }, + { "aura", 4, SPC_LINEAR }, + { "h7", 3, SPC_FIX }, + { "money", 50, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -8591,8 +8610,8 @@ static spell spelldaten[] = "ur", M_BARDE, (UNITSPELL | ONETARGET | TESTCANSEE), 5, 7, { - { R_AURA, 4, SPC_FIX }, - { R_SILVER, 100, SPC_FIX }, + { "aura", 4, SPC_FIX }, + { "money", 100, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -8610,7 +8629,7 @@ static spell spelldaten[] = "achten sie kaum auf sich selbst.", NULL, NULL, M_BARDE, (PRECOMBATSPELL | SPELLLEVEL), 4, 7, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8625,7 +8644,7 @@ static spell spelldaten[] = "und Furcht ihren Schildarm lähmen.", NULL, NULL, M_BARDE, (PRECOMBATSPELL | SPELLLEVEL), 5, 8, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8646,7 +8665,7 @@ static spell spelldaten[] = "kc?", M_BARDE, (SPELLLEVEL|ONSHIPCAST), 5, 8, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8668,7 +8687,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | ONETARGET | TESTCANSEE), 2, 8, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8692,8 +8711,8 @@ static spell spelldaten[] = "u", M_BARDE, (UNITSPELL | SPELLLEVEL | ONETARGET | TESTCANSEE), 5, 9, { - { R_AURA, 3, SPC_LEVEL }, - { R_PERMAURA, 1, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, + { "permaura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -8707,8 +8726,8 @@ static spell spelldaten[] = "Magier anschließen wird.", NULL, NULL, M_BARDE, (NOTFAMILIARCAST), 5, 9, { - { R_AURA, 100, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, + { "aura", 100, SPC_FIX }, + { "permaura", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -8725,7 +8744,7 @@ static spell spelldaten[] = "Kraft seines Gesangs ab.", NULL, NULL, M_BARDE, (SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 5, 10, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8748,7 +8767,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 2, 10, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8763,7 +8782,7 @@ static spell spelldaten[] = "Hütten zurückziehen und kein Silber in den Theatern und Tavernen lassen.", NULL, NULL, M_BARDE, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 11, { - { R_AURA, 40, SPC_FIX }, + { "aura", 40, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8781,7 +8800,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 2, 12, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8796,7 +8815,7 @@ static spell spelldaten[] = "Die Wirkung kann etliche Wochen andauern", NULL, NULL, M_BARDE, (SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 5, 12, { - { R_AURA, 20, SPC_LEVEL }, + { "aura", 20, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8813,7 +8832,7 @@ static spell spelldaten[] = "u", M_BARDE, (UNITSPELL | ONETARGET | TESTCANSEE), 5, 13, { - { R_AURA, 40, SPC_FIX }, + { "aura", 40, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8833,7 +8852,7 @@ static spell spelldaten[] = "Überzeugungskraft zu lehren.'", NULL, NULL, M_BARDE, (SPELLLEVEL), 5, 14, { - { R_AURA, 20, SPC_LEVEL }, + { "aura", 20, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8848,7 +8867,7 @@ static spell spelldaten[] = "und wieder auf ihre Felder zurückkehren.", NULL, NULL, M_BARDE, (FARCASTING), 5, 15, { - { R_AURA, 30, SPC_FIX }, + { "aura", 30, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8865,7 +8884,7 @@ static spell spelldaten[] = "beruhigt sich der Mob wieder.", NULL, NULL, M_BARDE, (FARCASTING | REGIONSPELL | TESTRESISTANCE), 5, 16, { - { R_AURA, 40, SPC_FIX }, + { "aura", 40, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8883,7 +8902,7 @@ static spell spelldaten[] = "kc?", M_ASTRAL, (SPELLLEVEL | UNITSPELL | ONSHIPCAST | TESTCANSEE), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8896,7 +8915,7 @@ static spell spelldaten[] = "u", M_ASTRAL, (SPELLLEVEL | UNITSPELL | ONSHIPCAST | ONETARGET), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8908,7 +8927,7 @@ static spell spelldaten[] = SPL_TYBIED_EARN_SILVER, "miracle_doctor", NULL, NULL, NULL, M_ASTRAL, (SPELLLEVEL|ONSHIPCAST), 5, 1, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8920,7 +8939,7 @@ static spell spelldaten[] = SPL_TYBIED_FUMBLESHIELD, "tybiedfumbleshield", NULL, NULL, NULL, M_ASTRAL, (PRECOMBATSPELL | SPELLLEVEL), 2, 2, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8935,7 +8954,7 @@ static spell spelldaten[] = "so alle Einheiten innerhalb eines astralen Radius von Stufe/5 Regionen.", NULL, NULL, M_ASTRAL, (SPELLLEVEL), 5, 2, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8950,7 +8969,7 @@ static spell spelldaten[] = (UNITSPELL | SPELLLEVEL | ONSHIPCAST | TESTCANSEE), 2, 3, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8962,7 +8981,7 @@ static spell spelldaten[] = SPL_KEEPLOOT, "keeploot", NULL, NULL, NULL, M_ASTRAL, ( POSTCOMBATSPELL | SPELLLEVEL ), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8974,7 +8993,7 @@ static spell spelldaten[] = SPL_ENTERASTRAL, "enterastral", 0, 0, "u+", M_ASTRAL, (UNITSPELL|SPELLLEVEL), 7, 4, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -8989,7 +9008,7 @@ static spell spelldaten[] = "ru+", M_ASTRAL, (UNITSPELL |SPELLLEVEL), 7, 4, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9007,7 +9026,7 @@ static spell spelldaten[] = "ui", M_ASTRAL, (UNITSPELL|ONSHIPCAST|ONETARGET), 1, 5, { - { R_AURA, 1, SPC_FIX }, + { "aura", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9019,7 +9038,7 @@ static spell spelldaten[] = SPL_SHOCKWAVE, "shockwave", NULL, NULL, NULL, M_ASTRAL, (COMBATSPELL|SPELLLEVEL), 5, 5, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9032,7 +9051,7 @@ static spell spelldaten[] = M_ASTRAL, (FARCASTING | SPELLLEVEL | REGIONSPELL | TESTRESISTANCE), 2, 5, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9051,7 +9070,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | ONSHIPCAST | ONETARGET | TESTCANSEE), 2, 5, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9066,7 +9085,7 @@ static spell spelldaten[] = "ru+", M_ASTRAL, (UNITSPELL | SEARCHGLOBAL | SPELLLEVEL), 7, 6, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9079,7 +9098,7 @@ static spell spelldaten[] = SPL_FETCHASTRAL, "fetch_astral", NULL, NULL, "u+", M_ASTRAL, (UNITSPELL | SEARCHGLOBAL | SPELLLEVEL), 7, 6, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9093,7 +9112,7 @@ static spell spelldaten[] = (FARCASTING | SPELLLEVEL | UNITSPELL | ONETARGET | TESTRESISTANCE | TESTCANSEE), 3, 6, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9105,9 +9124,9 @@ static spell spelldaten[] = SPL_FLYING_SHIP, "airship", NULL, NULL, "s", M_ASTRAL, (ONSHIPCAST | SHIPSPELL | ONETARGET | TESTRESISTANCE), 5, 6, { - { R_AURA, 10, SPC_FIX }, - { R_HIGHLAND_1, 1, SPC_FIX }, - { R_GLACIER_3, 1, SPC_FIX }, + { "aura", 10, SPC_FIX }, + { "h12", 1, SPC_FIX }, + { "h20", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -9122,7 +9141,7 @@ static spell spelldaten[] = "kcc", M_ASTRAL, (FARCASTING | SPELLLEVEL | ONSHIPCAST | TESTCANSEE), 3, 7, { - { R_AURA, 3, SPC_LEVEL }, + { "aura", 3, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9138,8 +9157,8 @@ static spell spelldaten[] = (SPELLLEVEL | BUILDINGSPELL | ONETARGET | TESTRESISTANCE | ONSHIPCAST), 5, 7, { - { R_AURA, 50, SPC_FIX }, - { R_PERMAURA, 1, SPC_FIX }, + { "aura", 50, SPC_FIX }, + { "permaura", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9161,7 +9180,7 @@ static spell spelldaten[] = "kc", M_ASTRAL, (ONSHIPCAST | TESTRESISTANCE), 2, 8, { - { R_AURA, 20, SPC_FIX }, + { "aura", 20, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9180,7 +9199,7 @@ static spell spelldaten[] = "Je stärker der Magier, desto mehr Schaden hält der Schild aus.", NULL, NULL, M_ASTRAL, (PRECOMBATSPELL | SPELLLEVEL), 2, 8, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9195,7 +9214,7 @@ static spell spelldaten[] = "angreifen können.", NULL, NULL, M_ASTRAL, (PRECOMBATSPELL | SPELLLEVEL), 5, 9, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9210,7 +9229,7 @@ static spell spelldaten[] = "erkennen.", NULL, NULL, M_ASTRAL, (0), 5, 10, { - { R_AURA, 40, SPC_FIX }, + { "aura", 40, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9227,7 +9246,7 @@ static spell spelldaten[] = "u+", M_ASTRAL, (UNITSPELL | SPELLLEVEL | ONSHIPCAST | TESTCANSEE), 5, 11, { - { R_AURA, 5, SPC_LEVEL }, + { "aura", 5, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9243,7 +9262,7 @@ static spell spelldaten[] = "im Kampf auflösen wird.", NULL, NULL, M_ASTRAL, (PRECOMBATSPELL | SPELLLEVEL), 2, 12, { - { R_AURA, 4, SPC_LEVEL }, + { "aura", 4, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9258,8 +9277,8 @@ static spell spelldaten[] = "Magier anschließen wird.", NULL, NULL, M_ASTRAL, (NOTFAMILIARCAST), 5, 12, { - { R_AURA, 100, SPC_FIX }, - { R_PERMAURA, 5, SPC_FIX }, + { "aura", 100, SPC_FIX }, + { "permaura", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9282,9 +9301,9 @@ static spell spelldaten[] = (SPELLLEVEL | BUILDINGSPELL | ONETARGET | TESTRESISTANCE), 5, 13, { - { R_AURA, 10, SPC_LEVEL }, - { R_PERMAURA, 1, SPC_FIX }, - { R_EOG, 5, SPC_FIX }, + { "aura", 10, SPC_LEVEL }, + { "permaura", 1, SPC_FIX }, + { "laen", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 } }, @@ -9299,7 +9318,7 @@ static spell spelldaten[] = "für Stufe/3 Wochen gestört.", NULL, NULL, M_ASTRAL, (REGIONSPELL), 4, 14, { - { R_AURA, 140, SPC_FIX }, + { "aura", 140, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9317,7 +9336,7 @@ static spell spelldaten[] = "ui", M_ASTRAL, (UNITSPELL|ONETARGET), 1, 15, { - { R_AURA, 100, SPC_FIX }, + { "aura", 100, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9332,7 +9351,7 @@ static spell spelldaten[] = "Ein Schauer von Meteoren regnet über das Schlachtfeld.", NULL, NULL, M_GRAU, (COMBATSPELL | SPELLLEVEL), 5, 3, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9350,8 +9369,8 @@ static spell spelldaten[] = "Zeit brauchen, um sich zu erholen.", NULL, NULL, M_GRAU, 0, 5, 1, { - { R_AURA, 1, SPC_FIX }, - { R_PERMAURA, 1, SPC_FIX }, + { "aura", 1, SPC_FIX }, + { "permaura", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9363,7 +9382,7 @@ static spell spelldaten[] = "Verbrennt die Feinde", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 3, { - { R_AURA, 1, SPC_FIX }, + { "aura", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9375,7 +9394,7 @@ static spell spelldaten[] = "Tötet die Feinde", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 6, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9387,7 +9406,7 @@ static spell spelldaten[] = "Verbrennt die Feinde", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 12, { - { R_AURA, 3, SPC_FIX }, + { "aura", 3, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9399,7 +9418,7 @@ static spell spelldaten[] = "Entzieht Talentstufen und macht Schaden wie Großer Odem", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 12, { - { R_AURA, 4, SPC_FIX }, + { "aura", 4, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9412,7 +9431,7 @@ static spell spelldaten[] = "Panik", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 12, { - { R_AURA, 1, SPC_LEVEL }, + { "aura", 1, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9425,7 +9444,7 @@ static spell spelldaten[] = "Ruft Schattenwesen.", NULL, NULL, M_GRAU, (PRECOMBATSPELL), 5, 12, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9438,7 +9457,7 @@ static spell spelldaten[] = "Verletzt alle Gegner.", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 12, { - { R_AURA, 2, SPC_LEVEL }, + { "aura", 2, SPC_LEVEL }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9450,7 +9469,7 @@ static spell spelldaten[] = "Tötet die Feinde", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 8, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9462,7 +9481,7 @@ static spell spelldaten[] = "Tötet die Feinde", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 8, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9474,7 +9493,7 @@ static spell spelldaten[] = "Tötet die Feinde", NULL, NULL, M_GRAU, (COMBATSPELL), 5, 8, { - { R_AURA, 2, SPC_FIX }, + { "aura", 2, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 }, @@ -9489,8 +9508,8 @@ static spell spelldaten[] = "Region für den Pyramidenbau geeignet ist.", NULL, NULL, M_TRAUM, (0), 5, 4, { - { R_AURA, 2, SPC_FIX }, - { R_PLAIN_3, 1, SPC_FIX }, + { "aura", 2, SPC_FIX }, + { "h2", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9503,8 +9522,8 @@ static spell spelldaten[] = "Region für den Pyramidenbau geeignet ist.", NULL, NULL, M_ASTRAL, (0), 5, 3, { - { R_AURA, 4, SPC_FIX }, - { R_WISE, 1, SPC_FIX }, + { "aura", 4, SPC_FIX }, + { "p6", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9518,8 +9537,8 @@ static spell spelldaten[] = "Region für den Pyramidenbau geeignet ist.", NULL, NULL, M_DRUIDE, (0), 5, 5, { - { R_AURA, 3, SPC_FIX }, - { R_MALLORN, 5, SPC_FIX }, + { "aura", 3, SPC_FIX }, + { "mallorn", 5, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9532,8 +9551,8 @@ static spell spelldaten[] = "Region für den Pyramidenbau geeignet ist.", NULL, NULL, M_BARDE, (0), 5, 4, { - { R_AURA, 2, SPC_FIX }, - { R_HIGHLAND_3, 1, SPC_FIX }, + { "aura", 2, SPC_FIX }, + { "h14", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9546,8 +9565,8 @@ static spell spelldaten[] = "Region für den Pyramidenbau geeignet ist.", NULL, NULL, M_CHAOS, (0), 5, 5, { - { R_AURA, 1, SPC_FIX }, - { R_PERMAURA, 1, SPC_FIX }, + { "aura", 1, SPC_FIX }, + { "permaura", 1, SPC_FIX }, { 0, 0, 0 }, { 0, 0, 0 }, { 0, 0, 0 } @@ -9612,7 +9631,32 @@ init_spells(void) /* register all the old spells in the spelldata array */ for (i=0;spelldaten[i].id!=SPL_NOSPELL;++i) { - register_spell(spelldaten+i); + spelldata * data = spelldaten+i; + spell * sp = malloc(sizeof(spell)); + int n; + + sp->id = data->id; + sp->sname = strdup(data->sname); + if (data->info) { + locale_setstring(default_locale, mkname("spellinfo", data->sname), data->info); + } + sp->parameter = data->parameter?strdup(data->parameter):0; + sp->syntax = data->syntax?strdup(data->syntax):0; + sp->magietyp = data->magietyp; + sp->sptyp = data->sptyp; + sp->rank = data->rank; + sp->level = data->level; + for (n=0;n!=5 && data->components[n].name;++n); + sp->components = malloc(sizeof(spell_component) *(n+1)); + sp->components[n].type = NULL; + while (n-->0) { + sp->components[n].type = rt_find(data->components[n].name); + sp->components[n].amount = data->components[n].amount; + sp->components[n].cost = data->components[n].flags; + } + sp->sp_function = data->sp_function; + sp->patzer = data->patzer; + register_spell(sp); } at_register(&at_cursewall); at_register(&at_unitdissolve); diff --git a/src/res/resources.xml b/src/res/resources.xml index 2d6ea7c39..aa7c46468 100644 --- a/src/res/resources.xml +++ b/src/res/resources.xml @@ -214,4 +214,281 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +