summaryrefslogtreecommitdiffstats
path: root/src/common/restext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/restext.cpp')
-rw-r--r--src/common/restext.cpp17
1 files changed, 11 insertions, 6 deletions
diff --git a/src/common/restext.cpp b/src/common/restext.cpp
index 729a883..d61fa63 100644
--- a/src/common/restext.cpp
+++ b/src/common/restext.cpp
@@ -295,6 +295,7 @@ void InitializeRestext()
stringsEvent[EVENT_OBJECT_MPOWER] = "..power cell";
stringsEvent[EVENT_OBJECT_BHELP] = "Instructions for the mission (\\key help;)";
stringsEvent[EVENT_OBJECT_BTAKEOFF] = "Take off to finish the mission";
+ stringsEvent[EVENT_OBJECT_BDESTROY] = "Destroy";
stringsEvent[EVENT_OBJECT_BDERRICK] = "Build a derrick";
stringsEvent[EVENT_OBJECT_BSTATION] = "Build a power station";
stringsEvent[EVENT_OBJECT_BFACTORY] = "Build a bot factory";
@@ -539,6 +540,7 @@ void InitializeRestext()
+ stringsErr[ERR_GENERIC] = "Internal error - tell the developers";
stringsErr[ERR_CMD] = "Unknown command";
stringsErr[ERR_MANIP_VEH] = "Inappropriate bot";
stringsErr[ERR_MANIP_FLY] = "Impossible when flying";
@@ -563,6 +565,8 @@ void InitializeRestext()
stringsErr[ERR_BUILD_NARROW] = "Too close to a building";
stringsErr[ERR_BUILD_MOTOR] = "Impossible when moving";
stringsErr[ERR_SEARCH_FLY] = "Impossible when flying";
+ stringsErr[ERR_BUILD_DISABLED] = "Can not produce this object in this mission";
+ stringsErr[ERR_BUILD_RESEARCH] = "Can not produce not researched object";
stringsErr[ERR_SEARCH_VEH] = "Inappropriate bot";
stringsErr[ERR_SEARCH_MOTOR] = "Impossible when moving";
stringsErr[ERR_TERRA_VEH] = "Inappropriate bot";
@@ -620,6 +624,8 @@ void InitializeRestext()
stringsErr[ERR_FLAG_CREATE] = "Too many flags of this color (maximum 5)";
stringsErr[ERR_FLAG_PROXY] = "Too close to an existing flag";
stringsErr[ERR_FLAG_DELETE] = "No flag nearby";
+ stringsErr[ERR_DESTROY_NOTFOUND]= "Not found anything to destroy";
+ stringsErr[ERR_WRONG_OBJ] = "Inappropriate object";
stringsErr[ERR_MISSION_NOTERM] = "The mission is not accomplished yet (press \\key help; for more details)";
stringsErr[ERR_DELETEMOBILE] = "Bot destroyed";
stringsErr[ERR_DELETEBUILDING] = "Building destroyed";
@@ -729,9 +735,9 @@ void InitializeRestext()
static char g_gamerName[100];
-void SetGlobalGamerName(char *name)
+void SetGlobalGamerName(std::string name)
{
- strcpy(g_gamerName, name);
+ strcpy(g_gamerName, name.c_str());
}
@@ -842,10 +848,8 @@ static const char* GetResourceBase(ResType type, int num)
case RES_EVENT:
if (num >= EVENT_STD_MAX)
- {
- GetLogger()->Trace("GetResource event num out of range: %d\n", num); // TODO: fix later
- return "";
- }
+ return ""; // can be safely ignored (user events)
+
str = stringsEvent[num];
break;
@@ -914,3 +918,4 @@ bool GetResource(ResType type, int num, char* text)
PutKeyName(text, tmpl);
return true;
}
+