mirror of
https://github.com/glest/glest-source.git
synced 2025-02-25 12:12:25 +01:00
- bugfix for lua strings
This commit is contained in:
parent
435e06db20
commit
f7423608ce
@ -680,7 +680,6 @@ void ScriptManager::addConsoleLangText(const char *fmt, ...){
|
||||
char szBuf[max_debug_buffer_size]="";
|
||||
vsnprintf(szBuf,max_debug_buffer_size-1,fmt, argList);
|
||||
|
||||
//displayText= wrapString(Lang::getInstance().getScenarioString(text), displayTextWrapCount);
|
||||
world->addConsoleTextWoLang(szBuf);
|
||||
va_end(argList);
|
||||
|
||||
@ -698,7 +697,6 @@ void ScriptManager::DisplayFormattedText(const char *fmt, ...) {
|
||||
char szBuf[max_debug_buffer_size]="";
|
||||
vsnprintf(szBuf,max_debug_buffer_size-1,fmt, argList);
|
||||
|
||||
//displayText= wrapString(Lang::getInstance().getScenarioString(text), displayTextWrapCount);
|
||||
displayText=szBuf;
|
||||
|
||||
va_end(argList);
|
||||
@ -716,7 +714,6 @@ void ScriptManager::DisplayFormattedLangText(const char *fmt, ...) {
|
||||
char szBuf[max_debug_buffer_size]="";
|
||||
vsnprintf(szBuf,max_debug_buffer_size-1,fmt, argList);
|
||||
|
||||
//displayText= wrapString(Lang::getInstance().getScenarioString(text), displayTextWrapCount);
|
||||
displayText=szBuf;
|
||||
|
||||
va_end(argList);
|
||||
@ -2062,6 +2059,9 @@ void ScriptManager::saveGame(XmlNode *rootNode) {
|
||||
for(std::list<ScriptManagerMessage>::iterator it = messageQueue.begin(); it != messageQueue.end(); ++it) {
|
||||
(*it).saveGame(scriptManagerNode);
|
||||
}
|
||||
|
||||
//printf("==== ScriptManager Savegame messageBox [%d][%s][%s] displayText [%s]\n",messageBox.getEnabled(),messageBox.getText().c_str(),messageBox.getHeader().c_str(),displayText.c_str());
|
||||
|
||||
// GraphicMessageBox messageBox;
|
||||
scriptManagerNode->addAttribute("messageBox_enabled",intToStr(messageBox.getEnabled()), mapTagReplacements);
|
||||
scriptManagerNode->addAttribute("messageBox_text",messageBox.getText(), mapTagReplacements);
|
||||
|
@ -283,9 +283,9 @@ void LuaScript::saveGame(XmlNode *rootNode) {
|
||||
}
|
||||
|
||||
// enclose the value in "" if it is a string
|
||||
if (value_type == LUA_TSTRING) {
|
||||
value_string = "\"" + value_string + "\"";
|
||||
}
|
||||
//if (value_type == LUA_TSTRING) {
|
||||
//value_string = "\"" + value_string + "\"";
|
||||
//}
|
||||
|
||||
if(skipTable == true) {
|
||||
if(debugLuaDump == true) printf("#2 SKIPPING TABLE\n");
|
||||
|
Loading…
x
Reference in New Issue
Block a user