aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/Common
diff options
context:
space:
mode:
authorVivyaCC <21315274+enginelesscc@users.noreply.github.com>2026-03-06 23:25:57 +0100
committervoid_17 <heroerror3@gmail.com>2026-03-07 23:58:51 +0700
commit52b1882f13bfc35b052c68fafd4641829cbd34fe (patch)
tree477ef202101f015652da1ad96c808be48eecec7b /Minecraft.Client/Common
parent6dfdd9032892f933a2cd23470ccd03149d114811 (diff)
win cpp23 compat: Minecraft.Client
Diffstat (limited to 'Minecraft.Client/Common')
-rw-r--r--Minecraft.Client/Common/Audio/SoundEngine.cpp2
-rw-r--r--Minecraft.Client/Common/Audio/SoundEngine.h2
-rw-r--r--Minecraft.Client/Common/Colours/ColourTable.cpp2
-rw-r--r--Minecraft.Client/Common/Colours/ColourTable.h2
-rw-r--r--Minecraft.Client/Common/DLC/DLCAudioFile.cpp2
-rw-r--r--Minecraft.Client/Common/DLC/DLCAudioFile.h2
-rw-r--r--Minecraft.Client/Common/DLC/DLCManager.cpp2
-rw-r--r--Minecraft.Client/Common/DLC/DLCManager.h2
-rw-r--r--Minecraft.Client/Common/GameRules/GameRuleManager.cpp4
-rw-r--r--Minecraft.Client/Common/GameRules/GameRuleManager.h4
-rw-r--r--Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.cpp3
-rw-r--r--Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.cpp2
-rw-r--r--Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.h2
13 files changed, 16 insertions, 15 deletions
diff --git a/Minecraft.Client/Common/Audio/SoundEngine.cpp b/Minecraft.Client/Common/Audio/SoundEngine.cpp
index 13826da3..4b8f5f5b 100644
--- a/Minecraft.Client/Common/Audio/SoundEngine.cpp
+++ b/Minecraft.Client/Common/Audio/SoundEngine.cpp
@@ -103,7 +103,7 @@ char SoundEngine::m_szRedistName[]={"redist"};
#endif
-char *SoundEngine::m_szStreamFileA[eStream_Max]=
+const char *SoundEngine::m_szStreamFileA[eStream_Max]=
{
"calm1",
"calm2",
diff --git a/Minecraft.Client/Common/Audio/SoundEngine.h b/Minecraft.Client/Common/Audio/SoundEngine.h
index 5bd2fe4b..5417dcec 100644
--- a/Minecraft.Client/Common/Audio/SoundEngine.h
+++ b/Minecraft.Client/Common/Audio/SoundEngine.h
@@ -151,7 +151,7 @@ private:
static char m_szSoundPath[];
static char m_szMusicPath[];
static char m_szRedistName[];
- static char *m_szStreamFileA[eStream_Max];
+ static const char *m_szStreamFileA[eStream_Max];
AUDIO_LISTENER m_ListenerA[MAX_LOCAL_PLAYERS];
int m_validListenerCount;
diff --git a/Minecraft.Client/Common/Colours/ColourTable.cpp b/Minecraft.Client/Common/Colours/ColourTable.cpp
index e4bfe732..fa1e9d69 100644
--- a/Minecraft.Client/Common/Colours/ColourTable.cpp
+++ b/Minecraft.Client/Common/Colours/ColourTable.cpp
@@ -4,7 +4,7 @@
unordered_map<wstring,eMinecraftColour> ColourTable::s_colourNamesMap;
-wchar_t *ColourTable::ColourTableElements[eMinecraftColour_COUNT] =
+const wchar_t *ColourTable::ColourTableElements[eMinecraftColour_COUNT] =
{
L"NOTSET",
diff --git a/Minecraft.Client/Common/Colours/ColourTable.h b/Minecraft.Client/Common/Colours/ColourTable.h
index 8e0a348c..af99a8ed 100644
--- a/Minecraft.Client/Common/Colours/ColourTable.h
+++ b/Minecraft.Client/Common/Colours/ColourTable.h
@@ -5,7 +5,7 @@ class ColourTable
private:
unsigned int m_colourValues[eMinecraftColour_COUNT];
- static wchar_t *ColourTableElements[eMinecraftColour_COUNT];
+ static const wchar_t *ColourTableElements[eMinecraftColour_COUNT];
static unordered_map<wstring,eMinecraftColour> s_colourNamesMap;
public:
diff --git a/Minecraft.Client/Common/DLC/DLCAudioFile.cpp b/Minecraft.Client/Common/DLC/DLCAudioFile.cpp
index 6faf0c3b..7116f62d 100644
--- a/Minecraft.Client/Common/DLC/DLCAudioFile.cpp
+++ b/Minecraft.Client/Common/DLC/DLCAudioFile.cpp
@@ -26,7 +26,7 @@ PBYTE DLCAudioFile::getData(DWORD &dwBytes)
return m_pbData;
}
-WCHAR *DLCAudioFile::wchTypeNamesA[]=
+const WCHAR *DLCAudioFile::wchTypeNamesA[]=
{
L"CUENAME",
L"CREDIT",
diff --git a/Minecraft.Client/Common/DLC/DLCAudioFile.h b/Minecraft.Client/Common/DLC/DLCAudioFile.h
index 728512d7..f1a356fe 100644
--- a/Minecraft.Client/Common/DLC/DLCAudioFile.h
+++ b/Minecraft.Client/Common/DLC/DLCAudioFile.h
@@ -28,7 +28,7 @@ public:
e_AudioParamType_Max,
};
- static WCHAR *wchTypeNamesA[e_AudioParamType_Max];
+ static const WCHAR *wchTypeNamesA[e_AudioParamType_Max];
DLCAudioFile(const wstring &path);
diff --git a/Minecraft.Client/Common/DLC/DLCManager.cpp b/Minecraft.Client/Common/DLC/DLCManager.cpp
index 36f4d7f7..dd34e67f 100644
--- a/Minecraft.Client/Common/DLC/DLCManager.cpp
+++ b/Minecraft.Client/Common/DLC/DLCManager.cpp
@@ -7,7 +7,7 @@
#include "..\..\Minecraft.h"
#include "..\..\TexturePackRepository.h"
-WCHAR *DLCManager::wchTypeNamesA[]=
+const WCHAR *DLCManager::wchTypeNamesA[]=
{
L"DISPLAYNAME",
L"THEMENAME",
diff --git a/Minecraft.Client/Common/DLC/DLCManager.h b/Minecraft.Client/Common/DLC/DLCManager.h
index 27765232..d4dd2508 100644
--- a/Minecraft.Client/Common/DLC/DLCManager.h
+++ b/Minecraft.Client/Common/DLC/DLCManager.h
@@ -48,7 +48,7 @@ public:
e_DLCParamType_Max,
};
- static WCHAR *wchTypeNamesA[e_DLCParamType_Max];
+ static const WCHAR *wchTypeNamesA[e_DLCParamType_Max];
private:
vector<DLCPack *> m_packs;
diff --git a/Minecraft.Client/Common/GameRules/GameRuleManager.cpp b/Minecraft.Client/Common/GameRules/GameRuleManager.cpp
index 8f172443..0606808c 100644
--- a/Minecraft.Client/Common/GameRules/GameRuleManager.cpp
+++ b/Minecraft.Client/Common/GameRules/GameRuleManager.cpp
@@ -12,7 +12,7 @@
#include "ConsoleGameRules.h"
#include "GameRuleManager.h"
-WCHAR *GameRuleManager::wchTagNameA[] =
+const WCHAR *GameRuleManager::wchTagNameA[] =
{
L"", // eGameRuleType_Root
L"MapOptions", // eGameRuleType_LevelGenerationOptions
@@ -34,7 +34,7 @@ WCHAR *GameRuleManager::wchTagNameA[] =
L"UpdatePlayer", // eGameRuleType_UpdatePlayerRule
};
-WCHAR *GameRuleManager::wchAttrNameA[] =
+const WCHAR *GameRuleManager::wchAttrNameA[] =
{
L"descriptionName", // eGameRuleAttr_descriptionName
L"promptName", // eGameRuleAttr_promptName
diff --git a/Minecraft.Client/Common/GameRules/GameRuleManager.h b/Minecraft.Client/Common/GameRules/GameRuleManager.h
index e9e983b8..3f446e84 100644
--- a/Minecraft.Client/Common/GameRules/GameRuleManager.h
+++ b/Minecraft.Client/Common/GameRules/GameRuleManager.h
@@ -24,8 +24,8 @@ class WstringLookup;
class GameRuleManager
{
public:
- static WCHAR *wchTagNameA[ConsoleGameRules::eGameRuleType_Count];
- static WCHAR *wchAttrNameA[ConsoleGameRules::eGameRuleAttr_Count];
+ static const WCHAR *wchTagNameA[ConsoleGameRules::eGameRuleType_Count];
+ static const WCHAR *wchAttrNameA[ConsoleGameRules::eGameRuleAttr_Count];
static const short version_number = 2;
diff --git a/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.cpp b/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.cpp
index a2ab17a8..00462a90 100644
--- a/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.cpp
+++ b/Minecraft.Client/Common/UI/UIScene_LoadOrJoinMenu.cpp
@@ -1051,7 +1051,8 @@ void UIScene_LoadOrJoinMenu::GetSaveInfo()
m_pSaveDetails=StorageManager.ReturnSavesInfo();
if(m_pSaveDetails==NULL)
{
- C4JStorage::ESaveGameState eSGIStatus= StorageManager.GetSavesInfo(m_iPad,NULL,this,"save");
+ char savename[] = "save";
+ C4JStorage::ESaveGameState eSGIStatus = StorageManager.GetSavesInfo(m_iPad, NULL, this, savename);
}
#if TO_BE_IMPLEMENTED
diff --git a/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.cpp b/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.cpp
index d4f26ae7..9e0059f3 100644
--- a/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.cpp
+++ b/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.cpp
@@ -13,7 +13,7 @@
//#define SKIN_SELECT_PACK_PLAYER_CUSTOM 1
#define SKIN_SELECT_MAX_DEFAULTS 2
-WCHAR *UIScene_SkinSelectMenu::wchDefaultNamesA[]=
+const WCHAR *UIScene_SkinSelectMenu::wchDefaultNamesA[]=
{
L"USE LOCALISED VERSION", // Server selected
L"Steve",
diff --git a/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.h b/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.h
index e8d76096..60579ac6 100644
--- a/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.h
+++ b/Minecraft.Client/Common/UI/UIScene_SkinSelectMenu.h
@@ -6,7 +6,7 @@
class UIScene_SkinSelectMenu : public UIScene
{
private:
- static WCHAR *wchDefaultNamesA[eDefaultSkins_Count];
+ static const WCHAR *wchDefaultNamesA[eDefaultSkins_Count];
// 4J Stu - How many to show on each side of the main control
static const BYTE sidePreviewControls = 4;