From 475d62a5aa6f44dcabdc8f7d4397082d487c091a Mon Sep 17 00:00:00 2001 From: Zero Fanker Date: Mon, 27 May 2024 23:06:09 -0400 Subject: [PATCH] silence compile warning . --- MissionEditor/inlines.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/MissionEditor/inlines.h b/MissionEditor/inlines.h index 1444709..6191c63 100644 --- a/MissionEditor/inlines.h +++ b/MissionEditor/inlines.h @@ -54,8 +54,9 @@ inline CString GetUnitPictureFilename(const CString& lpUnitName, DWORD dwPicInde { CIniFile& ini = Map->GetIniFile(); - char n[50]; - _itoa_s(dwPicIndex, n, 10); + CString n; + n.Format("%d", dwPicIndex); + // store differently for each type even they shares same image, // because they can have different components, e.g. turret image if (pics.find(lpUnitName + n) != pics.end()) {