mappings
This commit is contained in:
1 parent
0a21c4fa21
commit
c61429099a
24 files changed
+54
-54
No files matched your search
@@ -33,16 +33,16 @@ public abstract class FlatChunkGeneratorMixin extends ChunkGenerator
|
||||
{
|
||||
if (CarpetSettings.flatWorldStructureSpawning)
|
||||
{
|
||||
if (accessor.method_28388(pos, true, StructureFeature.field_24851).hasChildren())
|
||||
if (accessor.method_28388(pos, true, StructureFeature.SWAMP_HUT).hasChildren())
|
||||
{ //swamp hut
|
||||
if (group == SpawnGroup.MONSTER)
|
||||
{
|
||||
return StructureFeature.field_24851.getMonsterSpawns();
|
||||
return StructureFeature.SWAMP_HUT.getMonsterSpawns();
|
||||
}
|
||||
|
||||
if (group == SpawnGroup.CREATURE)
|
||||
{
|
||||
return StructureFeature.field_24851.getCreatureSpawns();
|
||||
return StructureFeature.SWAMP_HUT.getCreatureSpawns();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@ public abstract class ServerChunkManagerMixin implements ServerChunkManagerInter
|
||||
private int setupTracking(ChunkTicketManager chunkTicketManager)
|
||||
{
|
||||
int j = chunkTicketManager.getSpawningChunkCount();
|
||||
RegistryKey<World> dim = this.world.method_27983(); // getDimensionType;
|
||||
RegistryKey<World> dim = this.world.getRegistryKey(); // getDimensionType;
|
||||
//((WorldInterface)world).getPrecookedMobs().clear(); not needed because mobs are compared with predefined BBs
|
||||
SpawnReporter.chunkCounts.put(dim, j);
|
||||
|
||||
@@ -79,7 +79,7 @@ public abstract class ServerChunkManagerMixin implements ServerChunkManagerInter
|
||||
{
|
||||
for (SpawnGroup cat: SpawnGroup.values())
|
||||
{
|
||||
RegistryKey<World> dim = world.method_27983(); // getDimensionType;
|
||||
RegistryKey<World> dim = world.getRegistryKey(); // getDimensionType;
|
||||
Pair key = Pair.of(dim, cat);
|
||||
int spawnTries = SpawnReporter.spawn_tries.get(cat);
|
||||
if (!SpawnReporter.local_spawns.containsKey(cat))
|
||||
|
||||
@@ -95,7 +95,7 @@ public abstract class ServerPlayerEntity_scarpetEventMixin extends PlayerEntity
|
||||
private void logPreviousCoordinates(RegistryKey<DimensionType> newDimension, CallbackInfoReturnable<Entity> cir)
|
||||
{
|
||||
previousLocation = getPos();
|
||||
previousDimension = world.method_27983(); //dimension type
|
||||
previousDimension = world.getRegistryKey(); //dimension type
|
||||
}
|
||||
|
||||
@Inject(method = "changeDimension", at = @At("RETURN"))
|
||||
@@ -105,7 +105,7 @@ public abstract class ServerPlayerEntity_scarpetEventMixin extends PlayerEntity
|
||||
{
|
||||
ServerPlayerEntity player = (ServerPlayerEntity) (Object)this;
|
||||
Vec3d to = null;
|
||||
if (!notInAnyWorld || previousDimension != World.field_25181 || newDimension != World.field_25179) // end ow
|
||||
if (!notInAnyWorld || previousDimension != World.END || newDimension != World.OVERWORLD) // end ow
|
||||
{
|
||||
to = getPos();
|
||||
}
|
||||
|
||||
@@ -281,7 +281,7 @@ public class SpawnHelperMixin
|
||||
SpawnGroup entityCategory = var6[var8];
|
||||
if ((spawnAnimals || !entityCategory.isPeaceful()) && (spawnMonsters || entityCategory.isPeaceful()) && (shouldSpawnAnimals || !entityCategory.isAnimal()) )
|
||||
{
|
||||
RegistryKey<World> dim = world.method_27983(); // getDimensionType;
|
||||
RegistryKey<World> dim = world.getRegistryKey(); // getDimensionType;
|
||||
int newCap = (int) ((double)entityCategory.getCapacity()*(Math.pow(2.0,(SpawnReporter.mobcap_exponent/4))));
|
||||
int int_2 = SpawnReporter.chunkCounts.get(dim); // eligible chunks for spawning
|
||||
int int_3 = newCap * int_2 / CHUNK_AREA; //current spawning limits
|
||||
|
||||
@@ -120,7 +120,7 @@ public abstract class VillagerEntity_aiMixin extends AbstractTraderEntity
|
||||
if (itemStack_1.getItem() == Items.EMERALD)
|
||||
{
|
||||
GlobalPos bedPos = this.brain.getOptionalMemory(MemoryModuleType.HOME).orElse(null);
|
||||
if (bedPos == null || bedPos.getDimension() != world.method_27983()) // get DImension
|
||||
if (bedPos == null || bedPos.getDimension() != world.getRegistryKey()) // get DImension
|
||||
{
|
||||
sayNo();
|
||||
((ServerWorld) getEntityWorld()).spawnParticles(ParticleTypes.BARRIER, getX(), getY() + getStandingEyeHeight() + 1, getZ(), 1, 0.1, 0.1, 0.1, 0.0);
|
||||
|
||||
Reference in new issue
Block a user