mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-04-30 00:37:58 +03:00
Moving to stringed keys for game strings
This commit is contained in:
parent
41fadcb4fd
commit
a4467c2a4b
10 changed files with 254 additions and 197 deletions
|
@ -179,7 +179,10 @@ bool __cdecl readGameFlowLevelChunks(ChunkId* chunkId, int maxSize, int arg)
|
|||
level->Background = str;
|
||||
free(str);
|
||||
|
||||
level->NameStringIndex = LEB128::ReadUInt32(g_ScriptChunkIO->GetRawStream());
|
||||
g_ScriptChunkIO->GetRawStream()->ReadString(&str);
|
||||
level->NameStringKey = string(str);
|
||||
free(str);
|
||||
|
||||
level->Soundtrack = LEB128::ReadUInt32(g_ScriptChunkIO->GetRawStream());
|
||||
|
||||
return true;
|
||||
|
@ -366,9 +369,10 @@ bool GameFlow::ExecuteScript(char* luaFilename)
|
|||
return true;
|
||||
}
|
||||
|
||||
char* GameFlow::GetString(int id)
|
||||
char* GameFlow::GetString(const char* id)
|
||||
{
|
||||
return (char*)(CurrentStrings->Strings[id].c_str());
|
||||
return (char*)id;
|
||||
//return (char*)(CurrentStrings->Strings[id].c_str());
|
||||
}
|
||||
|
||||
GameScriptSettings* GameFlow::GetSettings()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue