Blamite Game Engine - blam!  00272.10.26.20.0001.blamite
The core library for the Blamite Game Engine.
engine_text.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <string>
4 #include <map>
5 
6 #define ENGINE_TEXT(x) Blam::EngineText::LookupString(x)
7 
8 #define GAME_ENGINE_TEXT_FILE "game_engine_text.xml"
9 
10 #ifndef BLAM
11 #define BLAM
12 #endif
13 
18 {
20 };
21 
25 struct BlamString
26 {
27  std::string id;
28  std::string text;
29 };
30 
31 namespace Blam
32 {
43  namespace EngineText
44  {
51 
59  BLAM std::string LookupString(std::string id);
60 
69  BLAM std::string LookupErrorString(int error_code);
70  }
71 }
Blam
Namespace surrounding all major engine components.
Definition: blam_api.h:18
BLAM
#define BLAM
Definition: engine_text.h:11
Blam::EngineText::LookupString
BLAM std::string LookupString(std::string id)
Finds a string with a given ID.
Definition: engine_text.cpp:206
BlamLanguage
BlamLanguage
Enum containing all supported languages within the engine.
Definition: engine_text.h:17
BlamString
Structure representing a Blamite string.
Definition: engine_text.h:25
en_US
@ en_US
Definition: engine_text.h:19
BlamString::text
std::string text
The content of the string.
Definition: engine_text.h:28
BlamString::id
std::string id
The ID of the string.
Definition: engine_text.h:27
Blam::EngineText::LoadGameEngineStrings
BLAM bool LoadGameEngineStrings()
Loads all strings from the default game engine text file.
Definition: engine_text.cpp:86
Blam::EngineText::LookupErrorString
BLAM std::string LookupErrorString(int error_code)
Finds a string message associated with a given error code.
Definition: engine_text.cpp:220