forked from github/server
check for existence of spell descriptions
This commit is contained in:
parent
22e8e39a99
commit
231f9bb39a
|
@ -316,6 +316,20 @@ const curse_type *ct_find(const char *c)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
void ct_checknames() {
|
||||
int i, qi;
|
||||
quicklist *ctl;
|
||||
|
||||
for (i = 0; i < 256; ++i) {
|
||||
ctl = cursetypes[i];
|
||||
for (qi = 0; ctl; ql_advance(&ctl, &qi, 1)) {
|
||||
curse_type *type = (curse_type *)ql_get(ctl, qi);
|
||||
curse_name(type, default_locale);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------- */
|
||||
/* get_curse identifiziert eine Verzauberung über die ID und gibt
|
||||
* einen pointer auf die struct zurück.
|
||||
|
|
|
@ -288,6 +288,7 @@ extern "C" {
|
|||
int find_cursebyname(const char *c);
|
||||
const curse_type *ct_find(const char *c);
|
||||
void ct_register(const curse_type *);
|
||||
void ct_checknames(void);
|
||||
/* Regionszauber */
|
||||
|
||||
curse *cfindhash(int i);
|
||||
|
|
|
@ -1841,8 +1841,14 @@ static void write_script(FILE * F, const faction * f)
|
|||
fputc('\n', F);
|
||||
}
|
||||
|
||||
static void check_messages_exist(void) {
|
||||
ct_checknames();
|
||||
}
|
||||
|
||||
int init_reports(void)
|
||||
{
|
||||
check_messages_exist();
|
||||
|
||||
prepare_reports();
|
||||
{
|
||||
if (_access(reportpath(), 0) != 0) {
|
||||
|
|
Loading…
Reference in New Issue