Commit 26c2446f authored by Chen Bill's avatar Chen Bill

avoid wcscat

parent f5d3cb23
...@@ -1582,8 +1582,8 @@ void Game::ShowCardInfo(int code, bool resize) { ...@@ -1582,8 +1582,8 @@ void Game::ShowCardInfo(int code, bool resize) {
offset_info = 15; offset_info = 15;
if(!(cd.type & TYPE_LINK)) { if(!(cd.type & TYPE_LINK)) {
const wchar_t* form = L"\u2605"; const wchar_t* form = L"\u2605";
if(cd.type & TYPE_XYZ) form = L"\u2606"; if(cd.type & TYPE_XYZ)
myswprintf(formatBuffer, L"[%ls%d] ", form, cd.level); form = L"\u2606";
wchar_t adBuffer[16]; wchar_t adBuffer[16];
if(cd.attack < 0 && cd.defense < 0) if(cd.attack < 0 && cd.defense < 0)
myswprintf(adBuffer, L"?/?"); myswprintf(adBuffer, L"?/?");
...@@ -1593,16 +1593,14 @@ void Game::ShowCardInfo(int code, bool resize) { ...@@ -1593,16 +1593,14 @@ void Game::ShowCardInfo(int code, bool resize) {
myswprintf(adBuffer, L"%d/?", cd.attack); myswprintf(adBuffer, L"%d/?", cd.attack);
else else
myswprintf(adBuffer, L"%d/%d", cd.attack, cd.defense); myswprintf(adBuffer, L"%d/%d", cd.attack, cd.defense);
wcscat(formatBuffer, adBuffer); myswprintf(formatBuffer, L"[%ls%d] %ls", form, cd.level, adBuffer);
} else { } else {
myswprintf(formatBuffer, L"[LINK-%d] ", cd.level);
wchar_t adBuffer[16]; wchar_t adBuffer[16];
if(cd.attack < 0) if(cd.attack < 0)
myswprintf(adBuffer, L"?/- "); myswprintf(adBuffer, L"?/- ");
else else
myswprintf(adBuffer, L"%d/- ", cd.attack); myswprintf(adBuffer, L"%d/- ", cd.attack);
wcscat(formatBuffer, adBuffer); myswprintf(formatBuffer, L"[LINK-%d] %ls%ls", cd.level, adBuffer, dataManager.FormatLinkMarker(cd.link_marker));
wcscat(formatBuffer, dataManager.FormatLinkMarker(cd.link_marker));
} }
if(cd.type & TYPE_PENDULUM) { if(cd.type & TYPE_PENDULUM) {
wchar_t scaleBuffer[16]; wchar_t scaleBuffer[16];
......
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