Push forward
This commit is contained in:
+7
-7
@@ -16,7 +16,7 @@ index 8bcc8b6f83ab4d5a472741185511b5d84f4974be..7e78e67c32f5b577518fe735eaba4ce2
|
||||
- if (testPosState.is(Blocks.TRIPWIRE) || testPosState.is(Blocks.TRIPWIRE_HOOK)) {
|
||||
- if (!io.papermc.paper.configuration.GlobalConfiguration.get().blockUpdates.disableTripwireUpdates || !testPosState.is(Blocks.TRIPWIRE)) level.setBlock(testPos, wireData.trySetValue(ATTACHED, attached), Block.UPDATE_ALL); // Paper - prevent tripwire from updating
|
||||
+ // Shiroha start - tripwire and tripwireHook dupe
|
||||
+ if (moe.monnairealms.camellia.config.modules.function.TripwireBehaviorConfig.enabled) {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.function.TripwireBehaviorConfig.enabled) {
|
||||
+ level.setBlock(testPos, wireData.trySetValue(ATTACHED, attached), 3);
|
||||
+ level.getBlockState(testPos);
|
||||
+ } else {
|
||||
@@ -41,7 +41,7 @@ index b67f5f7b76037ab77548c37a83e4d0918915223a..4407333785e8e76d08bb8b18510e6db9
|
||||
+ // Shiroha start - tripwire behavior modifier
|
||||
+ java.util.List<BlockPos> blockList1 = new java.util.ArrayList<>();
|
||||
+ java.util.List<BlockPos> blockList2 = new java.util.ArrayList<>();
|
||||
+ boolean flag21 = moe.monnairealms.camellia.config.modules.function.TripwireBehaviorConfig.behaviorMode == moe.monnairealms.camellia.enums.EnumTripwireBehavior.VANILLA21; for (int dz = -2; dz <= 2; dz++) {
|
||||
+ boolean flag21 = io.nanachiyo0721.shiroha.config.modules.function.TripwireBehaviorConfig.behaviorMode == io.nanachiyo0721.shiroha.enums.EnumTripwireBehavior.VANILLA21; for (int dz = -2; dz <= 2; dz++) {
|
||||
for (int dx = -2; dx <= 2; dx++) {
|
||||
for (int dy = -1; dy < 3; dy++) {
|
||||
BlockPos blockPos = pos.set(origin).move(dx, dy, dz);
|
||||
@@ -50,12 +50,12 @@ index b67f5f7b76037ab77548c37a83e4d0918915223a..4407333785e8e76d08bb8b18510e6db9
|
||||
if (dropResources) {
|
||||
- blockList.destroyBlock(blockPos, true, null); // CraftBukkit
|
||||
+ boolean flag = false;
|
||||
+ if (moe.monnairealms.camellia.config.modules.function.TripwireBehaviorConfig.enabled) {
|
||||
+ switch (moe.monnairealms.camellia.config.modules.function.TripwireBehaviorConfig.behaviorMode) {
|
||||
+ case moe.monnairealms.camellia.enums.EnumTripwireBehavior.VANILLA20: {
|
||||
+ if (io.nanachiyo0721.shiroha.config.modules.function.TripwireBehaviorConfig.enabled) {
|
||||
+ switch (io.nanachiyo0721.shiroha.config.modules.function.TripwireBehaviorConfig.behaviorMode) {
|
||||
+ case io.nanachiyo0721.shiroha.enums.EnumTripwireBehavior.VANILLA20: {
|
||||
+ flag = true;
|
||||
+ }
|
||||
+ case moe.monnairealms.camellia.enums.EnumTripwireBehavior.MIXED: {
|
||||
+ case io.nanachiyo0721.shiroha.enums.EnumTripwireBehavior.MIXED: {
|
||||
+ net.minecraft.world.level.block.state.BlockState state = newLevel.getBlockState(blockPos);
|
||||
+ if (state.is(Blocks.TRIPWIRE)) {
|
||||
+ if (state.getValue(net.minecraft.world.level.block.TripWireBlock.DISARMED)) {
|
||||
@@ -84,7 +84,7 @@ index b67f5f7b76037ab77548c37a83e4d0918915223a..4407333785e8e76d08bb8b18510e6db9
|
||||
- if (dropResources) {
|
||||
- blockList.placeBlocks(state -> newLevel.destroyBlock(state.getPosition(), true, null));
|
||||
+ // Shiroha start - prevent tripwire dupe in end platform generate
|
||||
+ if (flag21 || !moe.monnairealms.camellia.config.modules.function.TripwireBehaviorConfig.enabled) {
|
||||
+ if (flag21 || !io.nanachiyo0721.shiroha.config.modules.function.TripwireBehaviorConfig.enabled) {
|
||||
+ if (dropResources) {
|
||||
+ blockList.placeBlocks(state -> newLevel.destroyBlock(state.getPosition(), true, null));
|
||||
+ } else {
|
||||
|
||||
Reference in New Issue
Block a user