aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/DLCTexturePack.h
diff options
context:
space:
mode:
authordaoge_cmd <3523206925@qq.com>2026-03-01 12:16:08 +0800
committerdaoge_cmd <3523206925@qq.com>2026-03-01 12:16:08 +0800
commitb691c43c44ff180d10e7d4a9afc83b98551ff586 (patch)
tree3e9849222cbc6ba49f2f1fc6e5fe7179632c7390 /Minecraft.Client/DLCTexturePack.h
parentdef8cb415354ac390b7e89052a50605285f1aca9 (diff)
Initial commit
Diffstat (limited to 'Minecraft.Client/DLCTexturePack.h')
-rw-r--r--Minecraft.Client/DLCTexturePack.h72
1 files changed, 72 insertions, 0 deletions
diff --git a/Minecraft.Client/DLCTexturePack.h b/Minecraft.Client/DLCTexturePack.h
new file mode 100644
index 00000000..14e6ea23
--- /dev/null
+++ b/Minecraft.Client/DLCTexturePack.h
@@ -0,0 +1,72 @@
+#pragma once
+
+#include "AbstractTexturePack.h"
+
+class DLCPack;
+class StringTable;
+
+class DLCTexturePack : public AbstractTexturePack
+{
+private:
+ DLCPack *m_dlcInfoPack; // Description, icon etc
+ DLCPack *m_dlcDataPack; // Actual textures
+ StringTable *m_stringTable;
+ bool bUILoaded;
+ bool m_bLoadingData, m_bHasLoadedData;
+ bool m_bUsingDefaultColourTable;
+ //bool m_bHasAudio;
+ ArchiveFile *m_archiveFile;
+
+
+
+public:
+ using AbstractTexturePack::getResource;
+
+ DLCTexturePack(DWORD id, DLCPack *pack, TexturePack *fallback);
+ ~DLCTexturePack();
+
+ virtual wstring getResource(const wstring& name);
+ virtual DLCPack * getDLCPack();
+ // Added for sound banks with MashUp packs
+#ifdef _XBOX
+ IXACT3WaveBank *m_pStreamedWaveBank;
+ IXACT3SoundBank *m_pSoundBank;
+#endif
+protected:
+ //@Override
+ void loadIcon();
+ void loadComparison();
+ void loadName();
+ void loadDescription();
+ InputStream *getResourceImplementation(const wstring &name); //throws IOException
+
+public:
+ //@Override
+ bool hasFile(const wstring &name);
+ bool isTerrainUpdateCompatible();
+
+ // 4J Added
+ virtual wstring getPath(bool bTitleUpdateTexture = false);
+ virtual wstring getAnimationString(const wstring &textureName, const wstring &path);
+ virtual BufferedImage *getImageResource(const wstring& File, bool filenameHasExtension = false, bool bTitleUpdateTexture=false, const wstring &drive =L"");
+ virtual void loadColourTable();
+ virtual bool hasData() { return m_bHasLoadedData; }
+ virtual bool isLoadingData() { return m_bLoadingData; }
+
+private:
+ static wstring getRootPath(DWORD packId, bool allowOverride, bool bAddDataFolder);
+ static wstring getFilePath(DWORD packId, wstring filename, bool bAddDataFolder=true);
+
+public:
+ static int packMounted(LPVOID pParam,int iPad,DWORD dwErr,DWORD dwLicenceMask);
+ virtual void loadData();
+ virtual void loadUI();
+ virtual void unloadUI();
+ virtual wstring getXuiRootPath();
+ virtual ArchiveFile *getArchiveFile() { return m_archiveFile; }
+
+ virtual unsigned int getDLCParentPackId();
+ virtual DLCPack *getDLCInfoParentPack();
+ virtual unsigned char getDLCSubPackId();
+ XCONTENTDEVICEID GetDLCDeviceID();
+};