forked from github/server
code-polishing: Vertraute werden nicht mehr als RC_* gebraucht.find_spellbyid() kriegt nen magietyp für den fall wo zwei zauber gleich heissen, und nicht über ihre 'alte' id erkannt werden, sondern den hash des namens (für seenspell)
This commit is contained in:
parent
9eb50890c6
commit
4dec5c914d
|
@ -17,6 +17,7 @@
|
||||||
|
|
||||||
/* kernel includes */
|
/* kernel includes */
|
||||||
#include <kernel/item.h>
|
#include <kernel/item.h>
|
||||||
|
#include <kernel/race.h>
|
||||||
#include <kernel/region.h>
|
#include <kernel/region.h>
|
||||||
#include <kernel/faction.h>
|
#include <kernel/faction.h>
|
||||||
#include <kernel/unit.h>
|
#include <kernel/unit.h>
|
||||||
|
|
|
@ -552,6 +552,10 @@ race_compat(void)
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i=0;i!=MAXRACES;++i) {
|
for (i=0;i!=MAXRACES;++i) {
|
||||||
|
const char * rcname = oldracenames[i];
|
||||||
|
if (rcname==NULL) {
|
||||||
|
new_race[i] = NULL;
|
||||||
|
} else {
|
||||||
race * rc = rc_find(oldracenames[i]);
|
race * rc = rc_find(oldracenames[i]);
|
||||||
if (rc) {
|
if (rc) {
|
||||||
new_race[i] = rc;
|
new_race[i] = rc;
|
||||||
|
@ -562,6 +566,7 @@ race_compat(void)
|
||||||
log_warning(("could not find old race %s\n", oldracenames[i]));
|
log_warning(("could not find old race %s\n", oldracenames[i]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static potion_type *
|
static potion_type *
|
||||||
|
|
Loading…
Reference in New Issue