mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/LCE-Revelations.git
synced 2026-09-24 13:20:44 +00:00
Merge upstream/main into main
This commit is contained in:
@@ -30,7 +30,7 @@ void Bat::defineSynchedData()
|
||||
|
||||
float Bat::getSoundVolume()
|
||||
{
|
||||
return 0.1f;
|
||||
return 0.8f;
|
||||
}
|
||||
|
||||
float Bat::getVoicePitch()
|
||||
|
||||
@@ -72,7 +72,7 @@ void Cow::playStepSound(int xt, int yt, int zt, int t)
|
||||
|
||||
float Cow::getSoundVolume()
|
||||
{
|
||||
return 0.4f;
|
||||
return 1.f;
|
||||
}
|
||||
|
||||
int Cow::getDeathLoot()
|
||||
|
||||
@@ -96,9 +96,20 @@ int Entity::getSmallId()
|
||||
puiUsedFlags++;
|
||||
}
|
||||
|
||||
#ifdef MINECRAFT_SERVER_BUILD
|
||||
// in mc server dedi, a server with 8+ playerrs can cause this to go wack
|
||||
int fallbackId = Entity::entityCounter++;
|
||||
|
||||
if (entityCounter == 0x7ffffff)
|
||||
{
|
||||
entityCounter = 2048;
|
||||
}
|
||||
return fallbackId;
|
||||
#else
|
||||
app.DebugPrintf("Out of small entity Ids... possible leak?\n");
|
||||
__debugbreak();
|
||||
return -1;
|
||||
#endif
|
||||
}
|
||||
|
||||
void Entity::countFlagsForPIX()
|
||||
|
||||
@@ -37,6 +37,7 @@ void FireworksRecipe::ReleaseThreadStorage()
|
||||
void FireworksRecipe::setResultItem(shared_ptr<ItemInstance> item)
|
||||
{
|
||||
ThreadStorage *tls = static_cast<ThreadStorage *>(TlsGetValue(tlsIdx));
|
||||
if (tls == nullptr) tls = tlsDefault;
|
||||
tls->resultItem = item;
|
||||
}
|
||||
|
||||
@@ -269,6 +270,7 @@ bool FireworksRecipe::matches(shared_ptr<CraftingContainer> craftSlots, Level *l
|
||||
shared_ptr<ItemInstance> FireworksRecipe::assemble(shared_ptr<CraftingContainer> craftSlots)
|
||||
{
|
||||
ThreadStorage *tls = static_cast<ThreadStorage *>(TlsGetValue(tlsIdx));
|
||||
if (tls == nullptr) tls = tlsDefault;
|
||||
return tls->resultItem->copy();
|
||||
//return resultItem->copy();
|
||||
}
|
||||
@@ -281,6 +283,7 @@ int FireworksRecipe::size()
|
||||
const ItemInstance *FireworksRecipe::getResultItem()
|
||||
{
|
||||
ThreadStorage *tls = static_cast<ThreadStorage *>(TlsGetValue(tlsIdx));
|
||||
if (tls == nullptr) tls = tlsDefault;
|
||||
return tls->resultItem.get();
|
||||
//return resultItem.get();
|
||||
}
|
||||
|
||||
@@ -16,7 +16,12 @@ using namespace std;
|
||||
|
||||
// 4J Stu - This value should be big enough that we don't get any crashes causes by memory overwrites,
|
||||
// however it does seem way too large for what is actually needed. Needs further investigation
|
||||
#ifdef MINECRAFT_SERVER_BUILD
|
||||
// fixes a crash when 8+ players are present
|
||||
#define LEVEL_CHUNKS_TO_UPDATE_MAX (32*32*8)
|
||||
#else
|
||||
#define LEVEL_CHUNKS_TO_UPDATE_MAX (19*19*8)
|
||||
#endif
|
||||
|
||||
class Vec3;
|
||||
class ChunkSource;
|
||||
|
||||
Reference in New Issue
Block a user