mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-21 18:37:42 +01:00
Beacon Activation Range Configurable
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
--- a/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
|
||||
+++ b/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
|
||||
@@ -139,6 +_,16 @@
|
||||
|
||||
public double getEffectRange() {
|
||||
if (this.effectRange < 0) {
|
||||
+ // Purpur start - Beacon Activation Range Configurable
|
||||
+ if (this.level != null) {
|
||||
+ switch (this.levels) {
|
||||
+ case 1: return this.level.purpurConfig.beaconLevelOne;
|
||||
+ case 2: return this.level.purpurConfig.beaconLevelTwo;
|
||||
+ case 3: return this.level.purpurConfig.beaconLevelThree;
|
||||
+ case 4: return this.level.purpurConfig.beaconLevelFour;
|
||||
+ }
|
||||
+ }
|
||||
+ // Purpur end - Beacon Activation Range Configurable
|
||||
return this.levels * 10 + 10;
|
||||
} else {
|
||||
return effectRange;
|
||||
Reference in New Issue
Block a user