Initial 1.18 update
This commit is contained in:
parent
30cb7d0407
commit
c2e2281f29
556 changed files with 3417 additions and 3610 deletions
|
@ -5,10 +5,10 @@ Subject: [PATCH] Beacon API - custom effect ranges
|
|||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
|
||||
index 76a401bcfdacded2137142ed38d739ed65d9fae6..008d486f4166d9f384e3aab48af6d66a255f3564 100644
|
||||
index 4b7da0df927f669845c7d4c9b4a0acfab8efe657..82976b3675f581a9f3ccb9e23048bd44864203f8 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
|
||||
@@ -78,6 +78,26 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
@@ -77,6 +77,26 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
return (BeaconBlockEntity.hasSecondaryEffect(this.levels, this.primaryPower, this.secondaryPower)) ? CraftPotionUtil.toBukkit(new MobEffectInstance(this.secondaryPower, BeaconBlockEntity.getLevel(this.levels), BeaconBlockEntity.getAmplification(this.levels, this.primaryPower, this.secondaryPower), true, true)) : null;
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
@ -35,7 +35,7 @@ index 76a401bcfdacded2137142ed38d739ed65d9fae6..008d486f4166d9f384e3aab48af6d66a
|
|||
|
||||
public BeaconBlockEntity(BlockPos pos, BlockState state) {
|
||||
super(BlockEntityType.BEACON, pos, state);
|
||||
@@ -181,7 +201,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
@@ -180,7 +200,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
}
|
||||
|
||||
if (blockEntity.levels > 0 && !blockEntity.beamSections.isEmpty()) {
|
||||
|
@ -44,7 +44,7 @@ index 76a401bcfdacded2137142ed38d739ed65d9fae6..008d486f4166d9f384e3aab48af6d66a
|
|||
BeaconBlockEntity.playSound(world, pos, SoundEvents.BEACON_AMBIENT);
|
||||
}
|
||||
}
|
||||
@@ -267,8 +287,13 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
@@ -266,8 +286,13 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
}
|
||||
|
||||
public static List getHumansInRange(Level world, BlockPos blockposition, int i) {
|
||||
|
@ -59,7 +59,7 @@ index 76a401bcfdacded2137142ed38d739ed65d9fae6..008d486f4166d9f384e3aab48af6d66a
|
|||
|
||||
AABB axisalignedbb = (new AABB(blockposition)).inflate(d0).expandTowards(0.0D, (double) world.getHeight(), 0.0D);
|
||||
List<Player> list = world.getEntitiesOfClass(Player.class, axisalignedbb);
|
||||
@@ -309,12 +334,17 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
@@ -308,12 +333,17 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
}
|
||||
|
||||
private static void applyEffects(Level world, BlockPos pos, int beaconLevel, @Nullable MobEffect primaryEffect, @Nullable MobEffect secondaryEffect) {
|
||||
|
@ -78,7 +78,7 @@ index 76a401bcfdacded2137142ed38d739ed65d9fae6..008d486f4166d9f384e3aab48af6d66a
|
|||
|
||||
BeaconBlockEntity.applyEffect(list, primaryEffect, j, b0, true, pos); // Paper - BeaconEffectEvent
|
||||
|
||||
@@ -364,6 +394,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
@@ -363,6 +393,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
}
|
||||
|
||||
this.lockKey = LockCode.fromTag(nbt);
|
||||
|
@ -86,7 +86,7 @@ index 76a401bcfdacded2137142ed38d739ed65d9fae6..008d486f4166d9f384e3aab48af6d66a
|
|||
}
|
||||
|
||||
@Override
|
||||
@@ -377,6 +408,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
@@ -376,6 +407,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider {
|
||||
}
|
||||
|
||||
this.lockKey.addToTag(nbt);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue