* Add platform definitions file thanks to @Vruk11

Fixes #13
This commit is contained in:
iProgramInCpp
2023-08-05 15:54:41 +03:00
parent 90d72ac7e2
commit 386fac3ff6
4 changed files with 42 additions and 18 deletions

View File

@@ -0,0 +1,31 @@
/********************************************************************
Minecraft: Pocket Edition - Decompilation Project
Copyright (C) 2023 iProgramInCpp
The following code is licensed under the BSD 1 clause license.
SPDX-License-Identifier: BSD-1-Clause
********************************************************************/
#pragma once
// Sound Systems
#include "client/sound/SoundSystem.hpp"
#if false
// Add sound system overrides here
#elif defined(_WIN32)
// -- DirectSound based sound system for Windows
#include "windows/SoundSystemWindows.hpp"
#define SOUND_SYSTEM_TYPE SoundSystemWindows
#else
// -- Empty SoundSystem placeholder.
#define SOUND_SYSTEM_TYPE SoundSystem
#endif
// @TODO: SoundSystemSL - Use this for the Android port

View File

@@ -13,18 +13,7 @@
#include "SoundSystem.hpp"
#include "SoundRepository.hpp"
// Platform specific type for the sound system.
#ifdef _WIN32
#include "../../platforms/windows/SoundSystemWindows.hpp"
#define SOUND_SYSTEM_TYPE SoundSystemWindows
#else
#define SOUND_SYSTEM_TYPE SoundSystem
#endif
//#define SOUND_SYSTEM_TYPE SoundSystemSL
// @TODO: SoundSystemSL - Use this for the Android port
#include "platforms/PlatformDefinitions.hpp"
class SoundEngine
{

View File

@@ -27,6 +27,7 @@
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\platforms\PlatformDefinitions.hpp" />
<ClInclude Include="..\platforms\windows\AppPlatform_windows.hpp" />
<ClInclude Include="..\platforms\windows\SoundSystemWindows.hpp" />
<ClInclude Include="..\source\App.hpp" />
@@ -762,7 +763,7 @@
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_USE_MATH_DEFINES;_WINSOCK_DEPRECATED_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<FloatingPointModel>Precise</FloatingPointModel>
<ShowIncludes>false</ShowIncludes>
</ClCompile>
@@ -778,7 +779,7 @@
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_USE_MATH_DEFINES;_WINSOCK_DEPRECATED_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<FloatingPointModel>Precise</FloatingPointModel>
<ShowIncludes>false</ShowIncludes>
</ClCompile>
@@ -796,7 +797,7 @@
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_USE_MATH_DEFINES;_WINSOCK_DEPRECATED_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<FloatingPointModel>Precise</FloatingPointModel>
<ShowIncludes>false</ShowIncludes>
</ClCompile>
@@ -814,7 +815,7 @@
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_USE_MATH_DEFINES;_WINSOCK_DEPRECATED_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<FloatingPointModel>Precise</FloatingPointModel>
<ShowIncludes>false</ShowIncludes>
</ClCompile>
@@ -830,7 +831,7 @@
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_USE_MATH_DEFINES;_WINSOCK_DEPRECATED_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<FloatingPointModel>Precise</FloatingPointModel>
<ShowIncludes>false</ShowIncludes>
</ClCompile>
@@ -848,7 +849,7 @@
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_USE_MATH_DEFINES;_WINSOCK_DEPRECATED_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<MultiProcessorCompilation>false</MultiProcessorCompilation>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<FloatingPointModel>Precise</FloatingPointModel>
<ShowIncludes>false</ShowIncludes>
</ClCompile>

View File

@@ -981,6 +981,9 @@
<ClInclude Include="..\platforms\windows\SoundSystemWindows.hpp">
<Filter>source\platforms\windows</Filter>
</ClInclude>
<ClInclude Include="..\platforms\PlatformDefinitions.hpp">
<Filter>source\platforms</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\thirdparty\raknet\TwoWayAuthentication.cpp">