forked from github/server
Merge branch 'locales' into develop
This commit is contained in:
commit
6a612b3b2a
|
@ -22,7 +22,6 @@
|
|||
void config_reset(void) {
|
||||
default_locale = 0;
|
||||
free_config();
|
||||
free_locales();
|
||||
free_nrmesssages();
|
||||
free_spells();
|
||||
free_buildingtypes();
|
||||
|
@ -37,7 +36,6 @@ int config_parse(const char *json)
|
|||
if (conf) {
|
||||
json_config(conf);
|
||||
cJSON_Delete(conf);
|
||||
init_locales();
|
||||
return 0;
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -517,7 +517,7 @@ static void reset_game(void)
|
|||
for (f = factions; f; f = f->next) {
|
||||
f->flags &= FFL_SAVEMASK;
|
||||
}
|
||||
init_locales();
|
||||
// init_locales();
|
||||
}
|
||||
|
||||
static int tolua_process_orders(lua_State * L)
|
||||
|
|
|
@ -203,7 +203,7 @@ param_t findparam(const char *s, const struct locale * lang)
|
|||
void **tokens = get_translations(lang, UT_PARAMS);
|
||||
critbit_tree *cb = (critbit_tree *)*tokens;
|
||||
if (!cb) {
|
||||
log_error("no parameters defined in locale %s", locale_name(lang));
|
||||
log_warning("no parameters defined in locale %s", locale_name(lang));
|
||||
}
|
||||
else if (cb_find_prefix(cb, str, strlen(str), &match, 1, 0)) {
|
||||
cb_get_kv(match, &i, sizeof(int));
|
||||
|
|
|
@ -4196,6 +4196,7 @@ void init_processor(void)
|
|||
|
||||
void processorders(void)
|
||||
{
|
||||
init_locales();
|
||||
init_processor();
|
||||
process();
|
||||
/*************************************************/
|
||||
|
|
|
@ -301,7 +301,7 @@ void init_translations(const struct locale *lang, int ut, const char * (*string_
|
|||
add_translation(cb, key, i);
|
||||
}
|
||||
else {
|
||||
log_error("no translation for %s in locale %s", s, lang->name);
|
||||
log_warning("no translation for %s in locale %s", s, lang->name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue