Push forward
This commit is contained in:
+54
-54
@@ -187,7 +187,7 @@ index 08ea8107fc8cbec3742278ab5cf03ef9048720f9..e59250af5d769076578017fb880e9168
|
||||
}
|
||||
|
||||
private void ensureMapOwnership() {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.copyOnWrite && this.subscriber != null) this.subscriber.lithium$notify((PatchedDataComponentMap) (Object) this, 0); // Leaves - Lithium Sleeping Block Entity (only notify when actually copying, matches Lithium mixin semantics)
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.copyOnWrite && this.subscriber != null) this.subscriber.lithium$notify((PatchedDataComponentMap) (Object) this, 0); // Leaves - Lithium Sleeping Block Entity (only notify when actually copying, matches Lithium mixin semantics)
|
||||
if (this.copyOnWrite) {
|
||||
this.patch = new Reference2ObjectArrayMap<>(this.patch);
|
||||
this.copyOnWrite = false;
|
||||
@@ -222,7 +222,7 @@ index f2c5a6ce769d8a5fdb4b836eae6a61a4da91cb3f..968cdfa8a153b892963428967fd35c61
|
||||
try (ProblemReporter.ScopedCollector reporter = new ProblemReporter.ScopedCollector(this.entity.problemPath(), LOGGER)) {
|
||||
this.entity.load(TagValueInput.create(reporter, this.entity.registryAccess(), tag));
|
||||
this.entity.setUUID(uuid);
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.entity instanceof net.minecraft.world.entity.item.ItemEntity itemEntity) itemEntity.levelCallback.onMove(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.entity instanceof net.minecraft.world.entity.item.ItemEntity itemEntity) itemEntity.levelCallback.onMove(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
}
|
||||
|
||||
@@ -276,7 +276,7 @@ index 18e0572fe28461e57edb13e6ed6f5a0b6b3604c9..83914a091cc8fd6ef726f2732238b164
|
||||
+ // Shiroha start - Region threading for lithium sleeping block entity
|
||||
+ private void notifyLithiumTrackerIfNeeded() {
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (!moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) return;
|
||||
+ if (!io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) return;
|
||||
+ var currentWorldData = io.papermc.paper.threadedregions.TickRegionScheduler.getCurrentRegionizedWorldData();
|
||||
+ if (currentWorldData == null || currentWorldData.world != this.level) return;
|
||||
+ if (this instanceof ItemEntity) {
|
||||
@@ -319,7 +319,7 @@ index 9a75c6b38f1cabd4415067d781f6ad49f4d8ebc8..1606bb148203d4bf7bdacb58acf1144c
|
||||
|
||||
public void setItem(final ItemStack itemStack) {
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.subscriber != null) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.subscriber != null) {
|
||||
+ ItemStack oldStack = this.getItem();
|
||||
+ if (oldStack != itemStack) {
|
||||
+ if (!oldStack.isEmpty()) {
|
||||
@@ -454,7 +454,7 @@ index 136e018d83c5be90894358a97b23f5fcfa6c0d38..93c94a059873993b2e3e03a47c61f90d
|
||||
|
||||
float totalPercent = 0.0F;
|
||||
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && container instanceof org.leavesmc.leaves.lithium.api.inventory.LithiumInventory optimizedInventory) return org.leavesmc.leaves.lithium.common.hopper.InventoryHelper.getLithiumStackList(optimizedInventory).getSignalStrength(container); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && container instanceof org.leavesmc.leaves.lithium.api.inventory.LithiumInventory optimizedInventory) return org.leavesmc.leaves.lithium.common.hopper.InventoryHelper.getLithiumStackList(optimizedInventory).getSignalStrength(container); // Leaves - Lithium Sleeping Block Entity
|
||||
for (int i = 0; i < container.getContainerSize(); i++) {
|
||||
ItemStack itemStack = container.getItem(i);
|
||||
if (!itemStack.isEmpty()) {
|
||||
@@ -480,7 +480,7 @@ index dc1e9acce122f3ebd7bf2b03150b4045db9493df..0bd2f2da669aa1a59d0af65aea3b305d
|
||||
// CraftBukkit end
|
||||
|
||||
public <T> @Nullable T set(final DataComponentType<T> type, final @Nullable T value) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && type == DataComponents.ENCHANTMENTS && this.subscriber instanceof ChangeSubscriber.EnchantmentSubscriber<ItemStack> enchantmentSubscriber) enchantmentSubscriber.lithium$notifyAfterEnchantmentChange(this, this.subscriberData); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && type == DataComponents.ENCHANTMENTS && this.subscriber instanceof ChangeSubscriber.EnchantmentSubscriber<ItemStack> enchantmentSubscriber) enchantmentSubscriber.lithium$notifyAfterEnchantmentChange(this, this.subscriberData); // Leaves - Lithium Sleeping Block Entity
|
||||
return this.components.set(type, value);
|
||||
}
|
||||
|
||||
@@ -489,7 +489,7 @@ index dc1e9acce122f3ebd7bf2b03150b4045db9493df..0bd2f2da669aa1a59d0af65aea3b305d
|
||||
|
||||
public void setCount(final int count) {
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && count != this.count) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && count != this.count) {
|
||||
+ if (this.subscriber instanceof ChangeSubscriber.CountChangeSubscriber<ItemStack> countChangeSubscriber) {
|
||||
+ countChangeSubscriber.lithium$notifyCount(this, this.subscriberData, count);
|
||||
+ }
|
||||
@@ -666,7 +666,7 @@ index 69e3969242ad52168e947af209e6fa72f36178ae..82f041a6c72eb09d365b5f83dd473146
|
||||
}
|
||||
// Paper end - Add CompostItemEvent and EntityCompostItemEvent
|
||||
this.level.levelEvent(LevelEvent.COMPOSTER_FILL, this.pos, newState != this.state ? 1 : 0);
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.changed = false; // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.changed = false; // Leaves - Lithium Sleeping Block Entity
|
||||
this.removeItemNoUpdate(0);
|
||||
}
|
||||
}
|
||||
@@ -685,7 +685,7 @@ index 2339099e05af80b234e64778822b012cc6318157..d828f2535a4860d96f3ca6c95a54e00b
|
||||
@Override
|
||||
protected void onPlace(final BlockState state, final Level level, final BlockPos pos, final BlockState oldState, final boolean movedByPiston) {
|
||||
this.updateNeighborsInFront(level, pos, state);
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this instanceof ComparatorBlock && !oldState.is(Blocks.COMPARATOR)) org.leavesmc.leaves.lithium.common.block.entity.inventory_comparator_tracking.ComparatorTracking.notifyNearbyBlockEntitiesAboutNewComparator(level, pos); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this instanceof ComparatorBlock && !oldState.is(Blocks.COMPARATOR)) org.leavesmc.leaves.lithium.common.block.entity.inventory_comparator_tracking.ComparatorTracking.notifyNearbyBlockEntitiesAboutNewComparator(level, pos); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -708,7 +708,7 @@ index 3932da81757ea0ab7a41617165f5b64dc44ea3eb..2ccabd98f9fa7f2a228c7ee320d0f8c9
|
||||
this.checkPoweredState(level, pos, state);
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ //invalidate caches of nearby hoppers when placing an update suppressed hopper
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && level.getBlockState(pos) != state) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && level.getBlockState(pos) != state) {
|
||||
+ for (Direction direction : UPDATE_SHAPE_ORDER) {
|
||||
+ BlockEntity hopper = level.lithium$getLoadedExistingBlockEntity(pos.relative(direction));
|
||||
+ if (hopper instanceof org.leavesmc.leaves.lithium.common.hopper.UpdateReceiver updateReceiver) {
|
||||
@@ -724,7 +724,7 @@ index 3932da81757ea0ab7a41617165f5b64dc44ea3eb..2ccabd98f9fa7f2a228c7ee320d0f8c9
|
||||
protected void neighborChanged(
|
||||
final BlockState state, final Level level, final BlockPos pos, final Block block, final @Nullable Orientation orientation, final boolean movedByPiston
|
||||
) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && level.lithium$getLoadedExistingBlockEntity(pos) instanceof org.leavesmc.leaves.lithium.common.hopper.UpdateReceiver updateReceiver) updateReceiver.lithium$invalidateCacheOnUndirectedNeighborUpdate(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && level.lithium$getLoadedExistingBlockEntity(pos) instanceof org.leavesmc.leaves.lithium.common.hopper.UpdateReceiver updateReceiver) updateReceiver.lithium$invalidateCacheOnUndirectedNeighborUpdate(); // Leaves - Lithium Sleeping Block Entity
|
||||
this.checkPoweredState(level, pos, state);
|
||||
}
|
||||
|
||||
@@ -771,7 +771,7 @@ index 78dbdf43ac9095eb3cf0b0653bab2603d5527ff4..601471d7578b93f30d8033bfab4d4050
|
||||
this.recipesUsed.clear();
|
||||
this.recipesUsed.putAll(input.read("RecipesUsed", RECIPES_USED_CODEC).orElse(Map.of()));
|
||||
this.cookSpeedMultiplier = input.getDoubleOr("Paper.CookSpeedMultiplier", 1); // Paper - cook speed multiplier API
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -779,7 +779,7 @@ index 78dbdf43ac9095eb3cf0b0653bab2603d5527ff4..601471d7578b93f30d8033bfab4d4050
|
||||
if (changed) {
|
||||
setChanged(level, pos, state);
|
||||
}
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(state); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(state); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
private static void consumeFuel(final NonNullList<ItemStack> items, final ItemStack fuel) {
|
||||
@@ -854,7 +854,7 @@ index 118af4e35eec652e7eb8a484a44652cfabc1bab5..fd2c62a4c9a9dbd81c3c4d1410694e5c
|
||||
@Override
|
||||
protected void setItems(final NonNullList<ItemStack> items) {
|
||||
this.items = items;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -904,7 +904,7 @@ index 0e594121b60aa5a01b5bbe94b80350f2fc698b1a..f100d51275522748664592453c9c51cb
|
||||
super.loadAdditional(input);
|
||||
this.lockKey = LockCode.fromTag(input);
|
||||
this.name = parseCustomNameSafe(input, "CustomName");
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this instanceof InventoryChangeTracker inventoryChangeTracker) inventoryChangeTracker.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this instanceof InventoryChangeTracker inventoryChangeTracker) inventoryChangeTracker.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1042,7 +1042,7 @@ index 2887cbaa954771d0fe357d8ec8df75073e9afa91..69227ca2534a3abe3be3d5c704335bc5
|
||||
if (this.level != null) {
|
||||
if (IGNORE_TILE_UPDATES.get().booleanValue()) return; // Paper - Perf: Optimize Hoppers // Folia - region threading
|
||||
setChanged(this.level, this.worldPosition, this.blockState);
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) lithium$handleSetChanged(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) lithium$handleSetChanged(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1052,7 +1052,7 @@ index 2887cbaa954771d0fe357d8ec8df75073e9afa91..69227ca2534a3abe3be3d5c704335bc5
|
||||
public void setRemoved() {
|
||||
+ this.hasComparators = UNKNOWN; // Leaves - Lithium Sleeping Block Entity
|
||||
this.remove = true;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.level != null && !this.level.isClientSide() && this instanceof InventoryChangeTracker inventoryChangeTracker) inventoryChangeTracker.lithium$emitRemoved(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.level != null && !this.level.isClientSide() && this instanceof InventoryChangeTracker inventoryChangeTracker) inventoryChangeTracker.lithium$emitRemoved(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public void clearRemoved() {
|
||||
@@ -1060,7 +1060,7 @@ index 2887cbaa954771d0fe357d8ec8df75073e9afa91..69227ca2534a3abe3be3d5c704335bc5
|
||||
public void setBlockState(final BlockState blockState) {
|
||||
this.validateBlockState(blockState);
|
||||
this.blockState = blockState;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$handleSetBlockState(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$handleSetBlockState(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
protected void applyImplicitComponents(final DataComponentGetter components) {
|
||||
@@ -1114,7 +1114,7 @@ index 5d26efb1feb1fd7d0f3bcc0fd7678b303518312a..bd320bcaa7964bf5532c6cb9634a5227
|
||||
}
|
||||
|
||||
public static void serverTick(final Level level, final BlockPos pos, final BlockState selfState, final BrewingStandBlockEntity entity) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(selfState); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(selfState); // Leaves - Lithium Sleeping Block Entity
|
||||
ItemStack fuel = entity.items.get(4);
|
||||
if (entity.fuel <= 0 && fuel.is(ItemTags.BREWING_FUEL)) {
|
||||
// CraftBukkit start
|
||||
@@ -1122,7 +1122,7 @@ index 5d26efb1feb1fd7d0f3bcc0fd7678b303518312a..bd320bcaa7964bf5532c6cb9634a5227
|
||||
fuel.shrink(1);
|
||||
}
|
||||
// CraftBukkit end
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
setChanged(level, pos, selfState);
|
||||
}
|
||||
|
||||
@@ -1131,7 +1131,7 @@ index 5d26efb1feb1fd7d0f3bcc0fd7678b303518312a..bd320bcaa7964bf5532c6cb9634a5227
|
||||
entity.brewTime = 0;
|
||||
}
|
||||
-
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
setChanged(level, pos, selfState);
|
||||
} else if (brewable && entity.fuel > 0) {
|
||||
entity.fuel--;
|
||||
@@ -1139,7 +1139,7 @@ index 5d26efb1feb1fd7d0f3bcc0fd7678b303518312a..bd320bcaa7964bf5532c6cb9634a5227
|
||||
entity.brewTime = event.getBrewingTime(); // 400 -> event.getTotalBrewTime() // Paper - use brewing time from event
|
||||
// CraftBukkit end
|
||||
entity.ingredient = ingredient.getItem();
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
setChanged(level, pos, selfState);
|
||||
}
|
||||
|
||||
@@ -1147,7 +1147,7 @@ index 5d26efb1feb1fd7d0f3bcc0fd7678b303518312a..bd320bcaa7964bf5532c6cb9634a5227
|
||||
}
|
||||
|
||||
this.fuel = input.getByteOr("Fuel", (byte)0);
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1223,7 +1223,7 @@ index 64d0d60d9025de2b5eb16b31c6437372d4c20c5e..54070ae70b1d4a6ed4fd51ba758dead4
|
||||
if (changed) {
|
||||
setChanged(level, pos, state);
|
||||
- }
|
||||
+ } else if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.lithium$startSleeping(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ } else if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.lithium$startSleeping(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public static void cooldownTick(final Level level, final BlockPos pos, final BlockState state, final CampfireBlockEntity entity) {
|
||||
@@ -1232,7 +1232,7 @@ index 64d0d60d9025de2b5eb16b31c6437372d4c20c5e..54070ae70b1d4a6ed4fd51ba758dead4
|
||||
if (changed) {
|
||||
setChanged(level, pos, state);
|
||||
- }
|
||||
+ } else if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.lithium$startSleeping(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ } else if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.lithium$startSleeping(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public static void particleTick(final Level level, final BlockPos pos, final BlockState state, final CampfireBlockEntity entity) {
|
||||
@@ -1240,7 +1240,7 @@ index 64d0d60d9025de2b5eb16b31c6437372d4c20c5e..54070ae70b1d4a6ed4fd51ba758dead4
|
||||
System.arraycopy(cookingState, 0, this.stopCooking, 0, Math.min(this.stopCooking.length, bytes.capacity()));
|
||||
});
|
||||
// Paper end - Add more Campfire API
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1248,7 +1248,7 @@ index 64d0d60d9025de2b5eb16b31c6437372d4c20c5e..54070ae70b1d4a6ed4fd51ba758dead4
|
||||
this.cookingTime[slot] = event.getTotalCookTime(); // recipe.get().value().cookingTime() -> event.getTotalCookTime()
|
||||
// CraftBukkit end
|
||||
this.cookingProgress[slot] = 0;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
this.items.set(slot, placeItem.consumeAndReturn(1, sourceEntity));
|
||||
serverLevel.gameEvent(GameEvent.BLOCK_CHANGE, this.getBlockPos(), GameEvent.Context.of(sourceEntity, this.getBlockState()));
|
||||
this.markUpdated();
|
||||
@@ -1300,7 +1300,7 @@ index a9273aebb5c8efe78e88158f11e1ee2af0dff3f1..c0d636ebe2fd9f2c63c1b9cb62ba257b
|
||||
|
||||
public static void lidAnimateTick(final Level level, final BlockPos pos, final BlockState state, final ChestBlockEntity entity) {
|
||||
entity.chestLidController.tickLid();
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public static void playSound(final Level level, final BlockPos worldPosition, final BlockState blockState, final SoundEvent event) {
|
||||
@@ -1308,7 +1308,7 @@ index a9273aebb5c8efe78e88158f11e1ee2af0dff3f1..c0d636ebe2fd9f2c63c1b9cb62ba257b
|
||||
@Override
|
||||
public boolean triggerEvent(final int b0, final int b1) {
|
||||
if (b0 == EVENT_SET_OPEN_COUNT) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.sleepingTicker != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.sleepingTicker != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
this.chestLidController.shouldBeOpen(b1 > 0);
|
||||
return true;
|
||||
} else {
|
||||
@@ -1316,7 +1316,7 @@ index a9273aebb5c8efe78e88158f11e1ee2af0dff3f1..c0d636ebe2fd9f2c63c1b9cb62ba257b
|
||||
@Override
|
||||
protected void setItems(final NonNullList<ItemStack> items) {
|
||||
this.items = items;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1410,7 +1410,7 @@ index 02d86d0675de22546a225dd6eaac5875eba0ce54..d3aff67c70b7c69daf6c6674325b26a4
|
||||
}
|
||||
});
|
||||
this.containerData.set(9, input.getIntOr("triggered", 0));
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1418,12 +1418,12 @@ index 02d86d0675de22546a225dd6eaac5875eba0ce54..d3aff67c70b7c69daf6c6674325b26a4
|
||||
level.setBlock(blockPos, blockState.setValue(CrafterBlock.CRAFTING, false), Block.UPDATE_ALL);
|
||||
}
|
||||
}
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && craftingTicksRemaining < 0) entity.checkSleep(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && craftingTicksRemaining < 0) entity.checkSleep(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public void setCraftingTicksRemaining(final int maxCraftingTicks) {
|
||||
this.craftingTicksRemaining = maxCraftingTicks;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.isSleeping() && this.level != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public int getRedstoneSignal() {
|
||||
@@ -1488,7 +1488,7 @@ index 736f5fd76f4a86ab16740904b5c0823413d65cd2..8995d91aed44b8c7933eaf0111332d83
|
||||
@Override
|
||||
protected void setItems(final NonNullList<ItemStack> items) {
|
||||
this.items = items;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1525,13 +1525,13 @@ index 6109d8da984b398bb1eb6cd6ab9a55f0511a615c..4b92beb60cb56dc35107dd2c2e7cc6a2
|
||||
|
||||
public static void lidAnimateTick(final Level level, final BlockPos pos, final BlockState state, final EnderChestBlockEntity entity) {
|
||||
entity.chestLidController.tickLid();
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleep(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean triggerEvent(final int b0, final int b1) {
|
||||
if (b0 == ChestBlock.EVENT_SET_OPEN_COUNT) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.sleepingTicker != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.sleepingTicker != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
this.chestLidController.shouldBeOpen(b1 > 0);
|
||||
return true;
|
||||
} else {
|
||||
@@ -1633,7 +1633,7 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
|
||||
@Override
|
||||
public void setBlockState(final BlockState blockState) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.level != null && !this.level.isClientSide() && blockState.getValue(HopperBlock.FACING) != this.getBlockState().getValue(HopperBlock.FACING)) this.invalidateCachedData(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.level != null && !this.level.isClientSide() && blockState.getValue(HopperBlock.FACING) != this.getBlockState().getValue(HopperBlock.FACING)) this.invalidateCachedData(); // Leaves - Lithium Sleeping Block Entity
|
||||
super.setBlockState(blockState);
|
||||
this.facing = blockState.getValue(HopperBlock.FACING);
|
||||
}
|
||||
@@ -1641,7 +1641,7 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
entity.setCooldown(0);
|
||||
// Spigot start
|
||||
boolean result = tryMoveItems(level, pos, state, entity, () -> suckInItems(level, entity));
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleepingConditions(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) entity.checkSleepingConditions(); // Leaves - Lithium Sleeping Block Entity
|
||||
if (!result && entity.level.spigotConfig.hopperCheck > 1) {
|
||||
entity.setCooldown(entity.level.spigotConfig.hopperCheck);
|
||||
}
|
||||
@@ -1650,7 +1650,7 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
entity.setCooldown(level.spigotConfig.hopperTransfer); // Spigot
|
||||
setChanged(level, pos, state);
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled
|
||||
+ && !entity.isOnCooldown()
|
||||
+ && !entity.isSleeping()
|
||||
+ && !state.getValue(HopperBlock.ENABLED)) {
|
||||
@@ -1673,14 +1673,14 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
|
||||
private static boolean ejectItems(final Level level, final BlockPos blockPos, final HopperBlockEntity self) {
|
||||
- Container container = getAttachedContainer(level, blockPos, self);
|
||||
+ Container container = moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled ? self.getInsertInventory(level) : getAttachedContainer(level, blockPos, self); // Leaves - Lithium Sleeping Block Entity
|
||||
+ Container container = io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled ? self.getInsertInventory(level) : getAttachedContainer(level, blockPos, self); // Leaves - Lithium Sleeping Block Entity
|
||||
if (container == null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Direction direction = self.facing.getOpposite();
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) {
|
||||
+ Boolean res = lithiumInsert(level, blockPos, self, container);
|
||||
+ if (res != null) {
|
||||
+ return res;
|
||||
@@ -1696,12 +1696,12 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
BlockState blockState = level.getBlockState(blockPos);
|
||||
- Container container = getSourceContainer(level, hopper, blockPos, blockState);
|
||||
- if (container != null) {
|
||||
+ Container sourceContainer = moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled ? getExtractInventory(level, hopper, blockPos, blockState) : getSourceContainer(level, hopper, blockPos, blockState); // Leaves - Lithium Sleeping Block Entity
|
||||
+ Container sourceContainer = io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled ? getExtractInventory(level, hopper, blockPos, blockState) : getSourceContainer(level, hopper, blockPos, blockState); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (sourceContainer != null) {
|
||||
Direction direction = Direction.DOWN;
|
||||
worldData.skipPullModeEventFire = worldData.skipHopperEvents; // Paper - Perf: Optimize Hoppers // Folia - region threading
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) {
|
||||
+ Boolean res = lithiumExtract(level, hopper, sourceContainer);
|
||||
+ if (res != null) {
|
||||
+ return res;
|
||||
@@ -1721,7 +1721,7 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
&& !blockState.is(BlockTags.DOES_NOT_BLOCK_HOPPERS);
|
||||
if (!isBlocked) {
|
||||
- for (ItemEntity entity : getItemsAtAndAbove(level, hopper)) {
|
||||
+ for (ItemEntity entity : moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled ? lithiumGetInputItemEntities(level, hopper) : getItemsAtAndAbove(level, hopper)) { // Leaves - Lithium Sleeping Block Entity
|
||||
+ for (ItemEntity entity : io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled ? lithiumGetInputItemEntities(level, hopper) : getItemsAtAndAbove(level, hopper)) { // Leaves - Lithium Sleeping Block Entity
|
||||
if (addItem(hopper, entity)) {
|
||||
return true;
|
||||
}
|
||||
@@ -1739,7 +1739,7 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
|
||||
public void setCooldown(final int time) {
|
||||
+ // Leaves start - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) {
|
||||
+ if (time == 7) {
|
||||
+ if (this.tickedGameTime == Long.MAX_VALUE) {
|
||||
+ this.sleepOnlyCurrentTick();
|
||||
@@ -1758,7 +1758,7 @@ index 4c9d0bcd8820b250b51c06fff4531021ab57d408..fa34778b1ce7a34385c192182e521b00
|
||||
@Override
|
||||
protected void setItems(final NonNullList<ItemStack> items) {
|
||||
this.items = items;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public static void entityInside(final Level level, final BlockPos pos, final BlockState blockState, final Entity entity, final HopperBlockEntity hopper) {
|
||||
@@ -2538,7 +2538,7 @@ index 174e39fb109bef3dd27ebc14aa13f6faabb10547..e898171acd7c4ef83d630e25c71222f4
|
||||
doNeighborUpdates(level, pos, blockState);
|
||||
}
|
||||
}
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.animationStatus == ShulkerBoxBlockEntity.AnimationStatus.CLOSED && this.progressOld == 0.0f && this.progress == 0.0f) this.lithium$startSleeping(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.animationStatus == ShulkerBoxBlockEntity.AnimationStatus.CLOSED && this.progressOld == 0.0f && this.progress == 0.0f) this.lithium$startSleeping(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
public ShulkerBoxBlockEntity.AnimationStatus getAnimationStatus() {
|
||||
@@ -2546,7 +2546,7 @@ index 174e39fb109bef3dd27ebc14aa13f6faabb10547..e898171acd7c4ef83d630e25c71222f4
|
||||
|
||||
@Override
|
||||
public boolean triggerEvent(final int b0, final int b1) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.sleepingTicker != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && this.sleepingTicker != null) this.wakeUpNow(); // Leaves - Lithium Sleeping Block Entity
|
||||
if (b0 == EVENT_SET_OPEN_COUNT) {
|
||||
this.openCount = b1;
|
||||
if (b1 == 0) {
|
||||
@@ -2554,7 +2554,7 @@ index 174e39fb109bef3dd27ebc14aa13f6faabb10547..e898171acd7c4ef83d630e25c71222f4
|
||||
@Override
|
||||
protected void setItems(final NonNullList<ItemStack> items) {
|
||||
this.itemStacks = items;
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$emitStackListReplaced(); // Leaves - Lithium Sleeping Block Entity
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -2628,7 +2628,7 @@ index c78d77089e34c4bb559f173b449bfb7d91b05d5c..f4cce42ddd319cfd11cc43d68044f51b
|
||||
final BlockState neighbourState,
|
||||
final RandomSource random
|
||||
) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$handleShapeUpdate(level, state, pos, neighbourPos, neighbourState); // Leaves - Lithium Sleeping Block Entity /* Triggers when a shape update (= update that observers can detect) is sent */
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) this.lithium$handleShapeUpdate(level, state, pos, neighbourPos, neighbourState); // Leaves - Lithium Sleeping Block Entity /* Triggers when a shape update (= update that observers can detect) is sent */
|
||||
return state;
|
||||
}
|
||||
|
||||
@@ -2669,14 +2669,14 @@ index 0e84b695a677e71f443a29c78fc5025eec7ae7f4..3cb6c24a21538569d73b95803dde7e4a
|
||||
this.tickersInLevel.compute(blockEntity.getBlockPos(), (blockPos, existingTicker) -> {
|
||||
TickingBlockEntity actualTicker = this.createTicker(blockEntity, ticker);
|
||||
if (existingTicker != null) {
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && blockEntity instanceof org.leavesmc.leaves.lithium.common.block.entity.SleepingBlockEntity sleepingBlockEntity) sleepingBlockEntity.lithium$setTickWrapper(existingTicker); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) existingTicker.createdBy = blockEntity; // Shiroha - Region threading for lithium sleeping block entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && blockEntity instanceof org.leavesmc.leaves.lithium.common.block.entity.SleepingBlockEntity sleepingBlockEntity) sleepingBlockEntity.lithium$setTickWrapper(existingTicker); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) existingTicker.createdBy = blockEntity; // Shiroha - Region threading for lithium sleeping block entity
|
||||
existingTicker.rebind(actualTicker);
|
||||
return (LevelChunk.RebindableTickingBlockEntityWrapper)existingTicker;
|
||||
} else if (this.isInLevel()) {
|
||||
LevelChunk.RebindableTickingBlockEntityWrapper result = new LevelChunk.RebindableTickingBlockEntityWrapper(actualTicker);
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && blockEntity instanceof org.leavesmc.leaves.lithium.common.block.entity.SleepingBlockEntity sleepingBlockEntity) sleepingBlockEntity.lithium$setTickWrapper(result); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (moe.monnairealms.camellia.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) result.createdBy = blockEntity; // Shiroha - Region threading for lithium sleeping block entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled && blockEntity instanceof org.leavesmc.leaves.lithium.common.block.entity.SleepingBlockEntity sleepingBlockEntity) sleepingBlockEntity.lithium$setTickWrapper(result); // Leaves - Lithium Sleeping Block Entity
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.optimizations.LeavesSleepingBlockEntityConfig.enabled) result.createdBy = blockEntity; // Shiroha - Region threading for lithium sleeping block entity
|
||||
this.level.addBlockEntityTicker(result);
|
||||
return result;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user