Commit f09c20f7 authored by Frozen Water's avatar Frozen Water

Merge pull request #1706 from sidschingis/patch-2

Increase amount of characters available for the effect description
parents b9447645 c5438158
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
namespace ygo { namespace ygo {
const wchar_t* DataManager::unknown_string = L"???"; const wchar_t* DataManager::unknown_string = L"???";
wchar_t DataManager::strBuffer[2048]; wchar_t DataManager::strBuffer[4096];
DataManager dataManager; DataManager dataManager;
bool DataManager::LoadDB(const char* file) { bool DataManager::LoadDB(const char* file) {
......
...@@ -46,7 +46,7 @@ public: ...@@ -46,7 +46,7 @@ public:
wchar_t tpBuffer[128]; wchar_t tpBuffer[128];
wchar_t scBuffer[128]; wchar_t scBuffer[128];
static wchar_t strBuffer[2048]; static wchar_t strBuffer[4096];
static const wchar_t* unknown_string; static const wchar_t* unknown_string;
static int CardReader(int, void*); static int CardReader(int, void*);
......
...@@ -638,7 +638,7 @@ void Game::InitStaticText(irr::gui::IGUIStaticText* pControl, u32 cWidth, u32 cH ...@@ -638,7 +638,7 @@ void Game::InitStaticText(irr::gui::IGUIStaticText* pControl, u32 cWidth, u32 cH
void Game::SetStaticText(irr::gui::IGUIStaticText* pControl, u32 cWidth, irr::gui::CGUITTFont* font, const wchar_t* text, u32 pos) { void Game::SetStaticText(irr::gui::IGUIStaticText* pControl, u32 cWidth, irr::gui::CGUITTFont* font, const wchar_t* text, u32 pos) {
int pbuffer = 0; int pbuffer = 0;
u32 _width = 0, _height = 0; u32 _width = 0, _height = 0;
for(int i = 0; text[i] != 0 && i < 1023; ++i) { for(int i = 0; text[i] != 0 && i < wcslen(text); ++i) {
u32 w = font->getCharDimension(text[i]).Width; u32 w = font->getCharDimension(text[i]).Width;
if(text[i] == L'\n') { if(text[i] == L'\n') {
dataManager.strBuffer[pbuffer++] = L'\n'; dataManager.strBuffer[pbuffer++] = L'\n';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment