1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-21 22:13:07 +01:00

Use std::string for objects

This commit is contained in:
Ted John
2017-12-05 12:55:33 +00:00
committed by Michael Steenbeek
parent eed00ea363
commit 31e112cf3b
13 changed files with 104 additions and 111 deletions

View File

@@ -18,6 +18,7 @@
#ifdef __cplusplus
#include <string>
#include <vector>
#include "../common.h"
@@ -26,9 +27,9 @@ interface IStream;
struct StringTableEntry
{
uint8 Id;
uint8 LanguageId;
utf8 * Text;
uint8 Id;
uint8 LanguageId;
std::string Text;
};
class StringTable
@@ -37,11 +38,10 @@ private:
std::vector<StringTableEntry> _strings;
public:
~StringTable();
void Read(IReadObjectContext * context, IStream * stream, uint8 id);
void Sort();
const utf8 * GetString(uint8 id) const;
std::string GetString(uint8 id) const;
void SetString(uint8 id, uint8 language, const std::string &text);
};
#endif