linux (compat): Add linux to most Win64 guards

This commit is contained in:
Anaël committed 2026-11-29 13:33:39 +01:00
1 parent 8cf5675892
commit 9626065598
180 files changed
+941 -935

No files matched your search

+4 -4
View File
@@ -11,7 +11,7 @@
#include "../Minecraft.World/net.minecraft.world.level.chunk.h"
#include "../Minecraft.World/net.minecraft.world.level.dimension.h"
#if defined(_WINDOWS64) && defined(MINECRAFT_SERVER_BUILD)
#if (defined(_WINDOWS64) || defined(__linux__)) && defined(MINECRAFT_SERVER_BUILD)
#include "../Minecraft.World/EnchantmentHelper.h"
#include "../Minecraft.World/ExperienceOrb.h"
#include "../Minecraft.Server/FourKitBridge.h"
@@ -255,7 +255,7 @@ bool ServerPlayerGameMode::destroyBlock(int x, int y, int z)
int t = level->getTile(x, y, z);
int data = level->getData(x, y, z);
#if defined(_WINDOWS64) && defined(MINECRAFT_SERVER_BUILD)
#if (defined(_WINDOWS64) || defined(__linux__)) && defined(MINECRAFT_SERVER_BUILD)
int eventExp = 0;
if (!isCreative() && !gameModeForPlayer->isAdventureRestricted() || !gameModeForPlayer->isSpectator())
{
@@ -350,13 +350,13 @@ bool ServerPlayerGameMode::destroyBlock(int x, int y, int z)
}
if (changed && canDestroy)
{
#if defined(_WINDOWS64) && defined(MINECRAFT_SERVER_BUILD)
#if (defined(_WINDOWS64) || defined(__linux__)) && defined(MINECRAFT_SERVER_BUILD)
g_suppressExpDrops = true;
#endif
Tile::tiles[t]->playerDestroy(level, player, x, y, z, data);
#if defined(_WINDOWS64) && defined(MINECRAFT_SERVER_BUILD)
#if (defined(_WINDOWS64) || defined(__linux__)) && defined(MINECRAFT_SERVER_BUILD)
g_suppressExpDrops = false;
if (finalExp > 0)
{