diff --git a/src/common/gamecode/economy.c b/src/common/gamecode/economy.c index 9aa121911..b22090c30 100644 --- a/src/common/gamecode/economy.c +++ b/src/common/gamecode/economy.c @@ -798,7 +798,7 @@ maintain(building * b, boolean first) } if (paid && c>0) { /* TODO: wieviel von was wurde bezahlt */ - message * msg; + message * msg = NULL; if (first) { msg = add_message(&u->faction->msgs, msg_message("maintenance", "unit building", u, b)); @@ -806,7 +806,7 @@ maintain(building * b, boolean first) msg = add_message(&u->faction->msgs, msg_message("maintenance_late", "building", b)); } - msg_release(msg); + if (msg) msg_release(msg); fset(b, BLD_MAINTAINED); if (work) fset(b, BLD_WORKING); for (c=0;b->type->maintenance[c].number;++c) { diff --git a/src/common/gamecode/laws.c b/src/common/gamecode/laws.c index 63f6dc382..01aad3abe 100644 --- a/src/common/gamecode/laws.c +++ b/src/common/gamecode/laws.c @@ -1380,6 +1380,7 @@ synonym_cmd(unit * u, struct order * ord) static int display_cmd(unit * u, struct order * ord) { + building * b = u->building; char **s = NULL; region * r = u->region; @@ -1389,7 +1390,7 @@ display_cmd(unit * u, struct order * ord) switch (getparam(u->faction->locale)) { case P_BUILDING: case P_GEBAEUDE: - if (!u->building) { + if (!b) { cmistake(u, ord, 145, MSG_PRODUCE); break; } @@ -1397,19 +1398,19 @@ display_cmd(unit * u, struct order * ord) cmistake(u, ord, 5, MSG_PRODUCE); break; } - if (u->building->type == bt_find("generic")) { + if (b->type == bt_find("generic")) { cmistake(u, ord, 279, MSG_PRODUCE); break; } - if (u->building->type == bt_find("monument") && u->building->display[0] != 0) { + if (b->type == bt_find("monument") && b->display && b->display[0] != 0) { cmistake(u, ord, 29, MSG_PRODUCE); break; } - if (u->building->type == bt_find("artsculpture") && u->building->display[0] != 0) { + if (b->type == bt_find("artsculpture") && b->display && b->display[0] != 0) { cmistake(u, ord, 29, MSG_PRODUCE); break; } - s = &u->building->display; + s = &b->display; break; case P_SHIP: @@ -1440,7 +1441,7 @@ display_cmd(unit * u, struct order * ord) break; case P_REGION: - if (!u->building) { + if (!b) { cmistake(u, ord, 145, MSG_EVENT); break; } @@ -1448,7 +1449,7 @@ display_cmd(unit * u, struct order * ord) cmistake(u, ord, 148, MSG_EVENT); break; } - if (u->building != largestbuilding(r,false)) { + if (b != largestbuilding(r,false)) { cmistake(u, ord, 147, MSG_EVENT); break; } @@ -1478,6 +1479,7 @@ display_cmd(unit * u, struct order * ord) static int name_cmd(unit * u, struct order * ord) { + building * b = u->building; region * r = u->region; char **s = NULL; param_t p; @@ -1534,7 +1536,7 @@ name_cmd(unit * u, struct order * ord) } s = &b->name; } else { - if (!u->building) { + if (!b) { cmistake(u, ord, 145, MSG_PRODUCE); break; } @@ -1542,21 +1544,21 @@ name_cmd(unit * u, struct order * ord) cmistake(u, ord, 148, MSG_PRODUCE); break; } - if (u->building->type == bt_find("generic")) { + if (b->type == bt_find("generic")) { cmistake(u, ord, 278, MSG_EVENT); break; } - sprintf(buf, "Monument %d", u->building->no); - if (u->building->type == bt_find("monument") - && !strcmp(u->building->name, buf)) { + sprintf(buf, "Monument %d", b->no); + if (b->type == bt_find("monument") + && !strcmp(b->name, buf)) { cmistake(u, ord, 29, MSG_EVENT); break; } - if (u->building->type == bt_find("artsculpure")) { + if (b->type == bt_find("artsculpure")) { cmistake(u, ord, 29, MSG_EVENT); break; } - s = &u->building->name; + s = &b->name; } break; @@ -1682,7 +1684,7 @@ name_cmd(unit * u, struct order * ord) break; case P_REGION: - if (!u->building) { + if (!b) { cmistake(u, ord, 145, MSG_EVENT); break; } @@ -1690,7 +1692,7 @@ name_cmd(unit * u, struct order * ord) cmistake(u, ord, 148, MSG_EVENT); break; } - if (u->building != largestbuilding(r,false)) { + if (b != largestbuilding(r,false)) { cmistake(u, ord, 147, MSG_EVENT); break; } @@ -3468,9 +3470,19 @@ setdefaults (void) /* Über dieser Zeile nur Befehle, die auch eine idle Faction machen darf */ if (idle (u->faction)) { set_order(&u->thisorder, default_order(u->faction->locale)); - break; + } else { + set_order(&u->thisorder, ord); } - /* else fall through */ + break; + + case K_FOLLOW: + /* FOLLOW is only a long order if we are following a ship. */ + init_tokens(ord); + skip_token(); + if (getparam(u->faction->locale) == P_SHIP) { + set_order(&u->thisorder, ord); + } + break; case K_ROUTE: case K_WORK: diff --git a/src/common/gamecode/report.c b/src/common/gamecode/report.c index 713c643fe..91728b4ca 100644 --- a/src/common/gamecode/report.c +++ b/src/common/gamecode/report.c @@ -1274,7 +1274,7 @@ describe(FILE * F, const region * r, int partial, faction * f) } scat("."); - if (r->display[0]) { + if (r->display && r->display[0]) { scat(" "); scat(r->display); @@ -1954,7 +1954,7 @@ report_building(FILE *F, const region * r, const building * b, const faction * f } } i = 0; - if (b->display[0]) { + if (b->display && b->display[0]) { scat("; "); scat(b->display); i = b->display[strlen(b->display) - 1]; @@ -2371,7 +2371,7 @@ report(FILE *F, faction * f, const faction_list * addresses, } } ch = 0; - if (sh->display[0]) { + if (sh->display && sh->display[0]) { scat("; "); scat(sh->display); diff --git a/src/common/kernel/eressea.c b/src/common/kernel/eressea.c index b82e759f2..195dbcbc1 100644 --- a/src/common/kernel/eressea.c +++ b/src/common/kernel/eressea.c @@ -1697,7 +1697,7 @@ freestrlist (strlist * s) /* - Meldungen und Fehler ------------------------------------------------- */ -boolean nomsg = false; +boolean lomem = false; /* - Namen der Strukturen -------------------------------------- */ typedef char name[OBJECTIDSIZE + 1]; diff --git a/src/common/kernel/eressea.h b/src/common/kernel/eressea.h index 74df5cfb8..0bc11914f 100644 --- a/src/common/kernel/eressea.h +++ b/src/common/kernel/eressea.h @@ -1166,6 +1166,8 @@ extern settings global; extern int produceexp(struct unit * u, skill_t sk, int n); extern boolean sqlpatch; +extern boolean lomem; /* save memory */ + extern const char * dbrace(const struct race * rc); extern void set_param(struct param ** p, const char * name, const char * data); diff --git a/src/common/kernel/message.c b/src/common/kernel/message.c index 14e4aa4c1..d77aadef7 100644 --- a/src/common/kernel/message.c +++ b/src/common/kernel/message.c @@ -353,8 +353,7 @@ extern unsigned int new_hashstring(const char* s); message * add_message(message_list** pm, message * m) { - if (m==NULL) return NULL; - else { + if (!lomem && m!=NULL) { struct mlist * mnew = malloc(sizeof(struct mlist)); if (*pm==NULL) { *pm = malloc(sizeof(message_list)); diff --git a/src/common/kernel/order.c b/src/common/kernel/order.c index 5d1eeeb5b..93e636614 100644 --- a/src/common/kernel/order.c +++ b/src/common/kernel/order.c @@ -101,28 +101,44 @@ parse_order(const char * s, const struct locale * lang) while (*s && !isalnum(*(unsigned char*)s) && !ispunct(*(unsigned char*)s)) ++s; if (*s==0) return NULL; else { + keyword_t kwd; const char * sptr; - order * ord = (order*)malloc(sizeof(order)); + order * ord = NULL; + int persistent = 0; int i; +#ifdef AT_PERSISTENT + while (*s=='@') { + persistent = 1; + ++s; + } +#endif + sptr = s; + kwd = findkeyword(parse_token(&sptr), lang); + + /* if this is just nonsense, then we skip it. */ + if (lomem) { + switch (kwd) { + case K_KOMMENTAR: + case NOKEYWORD: + return NULL; + default: + break; + } + } + + ord = (order*)malloc(sizeof(order)); for (i=0;i!=nlocales;++i) { if (locale_array[i]==lang) break; } if (i==nlocales) locale_array[nlocales++] = lang; ord->_lindex = (unsigned char)i; ord->_str = NULL; - ord->_persistent = 0; + ord->_persistent = persistent; ord->_refcount = 1; ord->next = NULL; -#ifdef AT_PERSISTENT - while (*s=='@') { - ord->_persistent = 1; - ++s; - } -#endif - sptr = s; - ord->_keyword = findkeyword(parse_token(&sptr), lang); + ord->_keyword = kwd; #ifdef SHORT_STRINGS if (ord->_keyword==NOKEYWORD) { ord->_str = strdup(s); diff --git a/src/common/kernel/reports.c b/src/common/kernel/reports.c index ffa613eb4..a299f47d9 100644 --- a/src/common/kernel/reports.c +++ b/src/common/kernel/reports.c @@ -424,7 +424,7 @@ bufunit(const faction * f, const unit * u, int indent, int mode) } i = 0; - if (u->display[0]) { + if (u->display && u->display[0]) { scat("; "); scat(u->display); @@ -579,7 +579,7 @@ bufunit_ugroupleader(const faction * f, const unit * u, int indent, int mode) if(show) while(show) i_free(i_remove(&show, show)); i = 0; - if (u->display[0]) { + if (u->display && u->display[0]) { scat("; "); scat(u->display); diff --git a/src/common/kernel/save.c b/src/common/kernel/save.c index 181ee7cce..7dde7ac25 100644 --- a/src/common/kernel/save.c +++ b/src/common/kernel/save.c @@ -249,9 +249,10 @@ rds(FILE * F, char **ds) rc(F); assert(s <= buffer + DISPLAYSIZE + 1); *s = 0; - (*ds) = realloc(*ds, sizeof(char) * (strlen(buffer) + 1)); - - strcpy(*ds, buffer); + if (ds) { + (*ds) = realloc(*ds, sizeof(char) * (strlen(buffer) + 1)); + strcpy(*ds, buffer); + } } #define rcf(F) (getc(F)); @@ -509,7 +510,7 @@ unitorders(FILE * F, struct faction * f) if (buf[0]) { /* Nun wird der Befehl erzeut und eingehängt */ *ordp = parse_order(buf, u->faction->locale); - ordp = &(*ordp)->next; + if (*ordp) ordp = &(*ordp)->next; } } @@ -618,7 +619,6 @@ readorders(const char *filename) } b = getbuf(F); - break; /* in factionorders wird nur eine zeile gelesen: @@ -643,8 +643,12 @@ readorders(const char *filename) case P_NEXT: f = NULL; - default: + b = getbuf(F); + break; + + default: b = getbuf(F); + break; } } @@ -1034,10 +1038,11 @@ readunit(FILE * F) if (f!=u->faction) u_setfaction(u, f); } rds(F, &u->name); - rds(F, &u->display); + if (lomem) rds(F, 0); + else rds(F, &u->display); #ifndef NDEBUG if (strlen(u->name)>=NAMESIZE) u->name[NAMESIZE] = 0; - if (strlen(u->display)>=DISPLAYSIZE) u->name[DISPLAYSIZE] = 0; + if (u->display && strlen(u->display)>=DISPLAYSIZE) u->display[DISPLAYSIZE] = 0; #endif number = ri(F); if (global.data_versionno); wi36(F, u->faction->no); ws(F, u->name); - ws(F, u->display); + ws(F, u->display?u->display:""); wi(F, u->number); wi(F, u->age); ws(F, u->race->_name[0]); @@ -1266,8 +1271,10 @@ readregion(FILE * F, int x, int y) } r->land = 0; } - rds(F, &r->display); - ter = ri(F); + if (lomem) rds(F, 0); + else rds(F, &r->display); + + ter = ri(F); if (global.data_version < NOFOREST_VERSION) { if (ter>T_PLAIN) --ter; } @@ -1416,7 +1423,7 @@ readregion(FILE * F, int x, int y) void writeregion(FILE * F, const region * r) { - ws(F, r->display); + ws(F, r->display?r->display:""); wi(F, rterrain(r)); wi(F, r->flags & RF_SAVEMASK); wi(F, r->age); @@ -1878,10 +1885,11 @@ readgame(const char * filename, int backup) b->no = rid(F); bhash(b); rds(F, &b->name); - rds(F, &b->display); + if (lomem) rds(F, 0); + else rds(F, &b->display); #ifndef NDEBUG if (strlen(b->name)>=NAMESIZE) b->name[NAMESIZE] = 0; - if (strlen(b->display)>=DISPLAYSIZE) b->name[DISPLAYSIZE] = 0; + if (b->display && strlen(b->display)>=DISPLAYSIZE) b->display[DISPLAYSIZE] = 0; #endif b->size = ri(F); if (global.data_version < TYPES_VERSION) { @@ -1908,10 +1916,11 @@ readgame(const char * filename, int backup) sh->no = rid(F); shash(sh); rds(F, &sh->name); - rds(F, &sh->display); + if (lomem) rds(F, 0); + else rds(F, &sh->display); #ifndef NDEBUG - if (strlen(sh->name)>=NAMESIZE) sh->name[NAMESIZE] = 0; - if (strlen(sh->display)>=DISPLAYSIZE) sh->name[DISPLAYSIZE] = 0; + if (sh->name && strlen(sh->name)>=NAMESIZE) sh->name[NAMESIZE] = 0; + if (sh->display && strlen(sh->display)>=DISPLAYSIZE) sh->display[DISPLAYSIZE] = 0; #endif rs(F, buf); @@ -2140,7 +2149,7 @@ writegame(const char *filename, char quiet) for (b = r->buildings; b; b = b->next) { wi36(F, b->no); ws(F, b->name); - ws(F, b->display); + ws(F, b->display?b->display:""); wi(F, b->size); ws(F, b->type->_name); wnl(F); @@ -2154,7 +2163,7 @@ writegame(const char *filename, char quiet) assert(sh->region == r); wi36(F, sh->no); ws(F, sh->name); - ws(F, sh->display); + ws(F, sh->display?sh->display:""); ws(F, sh->type->name[0]); wi(F, sh->size); wi(F, sh->damage); diff --git a/src/common/kernel/spell.c b/src/common/kernel/spell.c index f1c434103..f9cda99d5 100644 --- a/src/common/kernel/spell.c +++ b/src/common/kernel/spell.c @@ -458,8 +458,6 @@ report_effect(region * r, unit * mage, message * seen, message * unseen) if (!fval(mage->faction, FL_DH)) { add_message(&mage->faction->msgs, seen); } - msg_release(seen); - if (unseen) msg_release(unseen); } /* ------------------------------------------------------------- */ @@ -922,6 +920,8 @@ sp_magicstreet(castorder *co) message * seen = msg_message("path_effect", "mage region", mage, r); message * unseen = msg_message("path_effect", "mage region", NULL, r); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return co->level; @@ -988,6 +988,8 @@ sp_summonent(castorder *co) message * seen = msg_message("ent_effect", "mage amount", mage, ents); message * unseen = msg_message("ent_effect", "mage amount", NULL, ents); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; } @@ -1081,6 +1083,8 @@ sp_maelstrom(castorder *co) message * seen = msg_message("maelstrom_effect", "mage", mage); message * unseen = msg_message("maelstrom_effect", "mage", NULL); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -1128,6 +1132,8 @@ sp_mallorn(castorder *co) message * seen = msg_message("mallorn_effect", "mage", mage); message * unseen = msg_message("mallorn_effect", "mage", NULL); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -1162,6 +1168,8 @@ sp_blessedharvest(castorder *co) message * seen = msg_message("harvest_effect", "mage", mage); message * unseen = msg_message("harvest_effect", "mage", NULL); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -1210,6 +1218,8 @@ sp_hain(castorder *co) message * seen = msg_message("growtree_effect", "mage amount", mage, trees); message * unseen = msg_message("growtree_effect", "mage amount", NULL, trees); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -1257,6 +1267,8 @@ sp_mallornhain(castorder *co) message * seen = msg_message("growtree_effect", "mage amount", mage, trees); message * unseen = msg_message("growtree_effect", "mage amount", NULL, trees); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -1290,6 +1302,7 @@ patzer_ents(castorder *co) { message * unseen = msg_message("entrise", "region", r); report_effect(r, mage, unseen, unseen); + msg_release(unseen); } } @@ -3061,6 +3074,8 @@ sp_firewall(castorder *co) message * seen = msg_message("firewall_effect", "mage region", mage, r); message * unseen = msg_message("firewall_effect", "mage region", NULL, r); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -3149,6 +3164,8 @@ sp_wisps(castorder *co) message * seen = msg_message("wisps_effect", "mage region", mage, r); message * unseen = msg_message("wisps_effect", "mage region", NULL, r); report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); } return cast_level; @@ -5078,13 +5095,16 @@ sp_puttorest(castorder *co) unit *mage = (unit *)co->magician; int dead = deathcount(r); int laid_to_rest = dice((int)(co->force * 2), 100); - laid_to_rest = max(laid_to_rest, dead); + message * seen = msg_message("puttorest", "mage", mage); + message * unseen = msg_message("puttorest", "mage", NULL); + + laid_to_rest = max(laid_to_rest, dead); deathcounts(r, -laid_to_rest); - report_effect(r, mage, - msg_message("puttorest", "mage", mage), - msg_message("puttorest", "mage", NULL)); + report_effect(r, mage, seen, unseen); + msg_release(seen); + msg_release(unseen); return co->level; } diff --git a/src/eressea.sln b/src/eressea.sln index 1b2548def..49e83336c 100644 --- a/src/eressea.sln +++ b/src/eressea.sln @@ -1,21 +1,4 @@ Microsoft Visual Studio Solution File, Format Version 8.00 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "attributes", "common\attributes\attributes.vcproj", "{330712B5-8B27-4B17-B3CF-7A02CC0F93C3}" - ProjectSection(ProjectDependencies) = postProject - EndProjectSection -EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "eressea", "eressea\eressea.vcproj", "{B859D542-781E-4647-BCAB-3FE5ED077366}" - ProjectSection(ProjectDependencies) = postProject - {C14E3D2B-8189-4570-A4E3-9010C873E4FD} = {C14E3D2B-8189-4570-A4E3-9010C873E4FD} - {79659D44-EC28-42B9-9475-6C0D62D0AAE0} = {79659D44-EC28-42B9-9475-6C0D62D0AAE0} - {EF495253-2EEC-4F83-B6C0-D651F88B2198} = {EF495253-2EEC-4F83-B6C0-D651F88B2198} - {1D80D05F-BCF5-4971-8F06-D9581FD3B1F4} = {1D80D05F-BCF5-4971-8F06-D9581FD3B1F4} - {601CF164-F483-4DE7-8014-64BDD30680B5} = {601CF164-F483-4DE7-8014-64BDD30680B5} - {EDB0DE67-8215-4AF7-ACA1-F23CB11FF211} = {EDB0DE67-8215-4AF7-ACA1-F23CB11FF211} - {0EE778AB-8445-40DB-8F65-6BE378A91B97} = {0EE778AB-8445-40DB-8F65-6BE378A91B97} - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3} = {330712B5-8B27-4B17-B3CF-7A02CC0F93C3} - {4C837BEC-A428-4287-84B3-8F8F9DE7FA00} = {4C837BEC-A428-4287-84B3-8F8F9DE7FA00} - EndProjectSection -EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gamecode", "common\gamecode\gamecode.vcproj", "{79659D44-EC28-42B9-9475-6C0D62D0AAE0}" ProjectSection(ProjectDependencies) = postProject EndProjectSection @@ -36,7 +19,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mapper", "mapper\mapper.vcp {601CF164-F483-4DE7-8014-64BDD30680B5} = {601CF164-F483-4DE7-8014-64BDD30680B5} {EDB0DE67-8215-4AF7-ACA1-F23CB11FF211} = {EDB0DE67-8215-4AF7-ACA1-F23CB11FF211} {0EE778AB-8445-40DB-8F65-6BE378A91B97} = {0EE778AB-8445-40DB-8F65-6BE378A91B97} - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3} = {330712B5-8B27-4B17-B3CF-7A02CC0F93C3} {4C837BEC-A428-4287-84B3-8F8F9DE7FA00} = {4C837BEC-A428-4287-84B3-8F8F9DE7FA00} EndProjectSection EndProject @@ -69,7 +51,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "eressea-lua", "eressea\eres {601CF164-F483-4DE7-8014-64BDD30680B5} = {601CF164-F483-4DE7-8014-64BDD30680B5} {EDB0DE67-8215-4AF7-ACA1-F23CB11FF211} = {EDB0DE67-8215-4AF7-ACA1-F23CB11FF211} {0EE778AB-8445-40DB-8F65-6BE378A91B97} = {0EE778AB-8445-40DB-8F65-6BE378A91B97} - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3} = {330712B5-8B27-4B17-B3CF-7A02CC0F93C3} {4C837BEC-A428-4287-84B3-8F8F9DE7FA00} = {4C837BEC-A428-4287-84B3-8F8F9DE7FA00} EndProjectSection EndProject @@ -80,18 +61,6 @@ Global Release = Release EndGlobalSection GlobalSection(ProjectConfiguration) = postSolution - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3}.Debug.ActiveCfg = Debug|Win32 - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3}.Debug.Build.0 = Debug|Win32 - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3}.Profile.ActiveCfg = Profile|Win32 - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3}.Profile.Build.0 = Profile|Win32 - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3}.Release.ActiveCfg = Release|Win32 - {330712B5-8B27-4B17-B3CF-7A02CC0F93C3}.Release.Build.0 = Release|Win32 - {B859D542-781E-4647-BCAB-3FE5ED077366}.Debug.ActiveCfg = Debug|Win32 - {B859D542-781E-4647-BCAB-3FE5ED077366}.Debug.Build.0 = Debug|Win32 - {B859D542-781E-4647-BCAB-3FE5ED077366}.Profile.ActiveCfg = Profile|Win32 - {B859D542-781E-4647-BCAB-3FE5ED077366}.Profile.Build.0 = Profile|Win32 - {B859D542-781E-4647-BCAB-3FE5ED077366}.Release.ActiveCfg = Release|Win32 - {B859D542-781E-4647-BCAB-3FE5ED077366}.Release.Build.0 = Release|Win32 {79659D44-EC28-42B9-9475-6C0D62D0AAE0}.Debug.ActiveCfg = Debug|Win32 {79659D44-EC28-42B9-9475-6C0D62D0AAE0}.Debug.Build.0 = Debug|Win32 {79659D44-EC28-42B9-9475-6C0D62D0AAE0}.Profile.ActiveCfg = Profile|Win32 diff --git a/src/eressea/main.c b/src/eressea/main.c index 755149534..a43d5ed1b 100644 --- a/src/eressea/main.c +++ b/src/eressea/main.c @@ -108,7 +108,6 @@ extern boolean nonr; extern boolean nocr; extern boolean noreports; extern boolean nomer; -extern boolean nomsg; extern boolean nobattle; extern boolean nomonsters; extern boolean nobattledebug; @@ -432,7 +431,7 @@ usage(const char * prog, const char * arg) "-l logfile : specify an alternative logfile\n" "-R : erstellt nur die Reports neu\n" "--noeiswald : beruhigt ungemein\n" - "--nomsg : keine Messages (RAM sparen)\n" + "--lomem : keine Messages (RAM sparen)\n" "--nobattle : keine Kämpfe\n" "--nomonsters : keine monster KI\n" "--nodebug : keine Logfiles für Kämpfe\n" @@ -465,7 +464,7 @@ read_args(int argc, char **argv) else if (strcmp(argv[i]+2, "xml")==0) xmlfile = argv[++i]; else if (strcmp(argv[i]+2, "dirtyload")==0) dirtyload = true; else if (strcmp(argv[i]+2, "nonr")==0) nonr = true; - else if (strcmp(argv[i]+2, "nomsg")==0) nomsg = true; + else if (strcmp(argv[i]+2, "lomem")==0) lomem = true; else if (strcmp(argv[i]+2, "noeiswald")==0) g_killeiswald = true; else if (strcmp(argv[i]+2, "nobattle")==0) nobattle = true; else if (strcmp(argv[i]+2, "nomonsters")==0) nomonsters = true; diff --git a/src/eressea/server.cpp b/src/eressea/server.cpp index 91ba8f99a..e262c52dc 100644 --- a/src/eressea/server.cpp +++ b/src/eressea/server.cpp @@ -117,7 +117,6 @@ extern "C" { extern boolean nocr; extern boolean noreports; extern boolean nomer; - extern boolean nomsg; extern boolean nobattle; extern boolean nomonsters; extern boolean nobattledebug; @@ -465,7 +464,7 @@ usage(const char * prog, const char * arg) "-C : run in interactive mode\n" "-e script : main lua script (default: default.lua)\n" "-R : erstellt nur die Reports neu\n" - "--nomsg : keine Messages (RAM sparen)\n" + "--lomem : keine Messages (RAM sparen)\n" "--nobattle : keine Kämpfe\n" "--nomonsters : keine monster KI\n" "--nodebug : keine Logfiles für Kämpfe\n" @@ -510,7 +509,7 @@ read_args(int argc, char **argv, lua_State * luaState) else if (strcmp(argv[i]+2, "xml")==0) xmlfile = argv[++i]; else if (strcmp(argv[i]+2, "dirtyload")==0) dirtyload = true; else if (strcmp(argv[i]+2, "nonr")==0) nonr = true; - else if (strcmp(argv[i]+2, "nomsg")==0) nomsg = true; + else if (strcmp(argv[i]+2, "lomem")==0) lomem = true; else if (strcmp(argv[i]+2, "nobattle")==0) nobattle = true; else if (strcmp(argv[i]+2, "nomonsters")==0) nomonsters = true; else if (strcmp(argv[i]+2, "nodebug")==0) nobattledebug = true;