mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-21 10:27:44 +01:00
stop mobs from targeting afk players (#564)
Co-authored-by: Encode42 <me@encode42.dev>
This commit is contained in:
@@ -18,10 +18,10 @@ index 239bb3f470fe1b323a7fbad622fcff05cb23cc31..124c9bdba9dc95390831e9c43ddacca0
|
||||
long l = this.levelData.getDayTime() + 24000L;
|
||||
TimeSkipEvent event = new TimeSkipEvent(this.getWorld(), TimeSkipEvent.SkipReason.NIGHT_SKIP, (l - l % 24000L) - this.getDayTime());
|
||||
diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
index b4fa4646e240ffe93365f47cd7c3ec46b59cf826..c994f82b392e26a55f1e0d8f1d95a9b68d6b3ad3 100644
|
||||
index 9560ed69f0a17a78cc7129b64499a6c4de55a434..30e1679f4d342634fdfd8c64520d9c87eeee1462 100644
|
||||
--- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
+++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
@@ -310,6 +310,7 @@ public class PurpurWorldConfig {
|
||||
@@ -311,6 +311,7 @@ public class PurpurWorldConfig {
|
||||
public boolean playerFixStuckPortal = false;
|
||||
public boolean creativeOnePunch = false;
|
||||
public boolean playerSleepNearMonsters = false;
|
||||
@@ -29,7 +29,7 @@ index b4fa4646e240ffe93365f47cd7c3ec46b59cf826..c994f82b392e26a55f1e0d8f1d95a9b6
|
||||
private void playerSettings() {
|
||||
idleTimeoutKick = getBoolean("gameplay-mechanics.player.idle-timeout.kick-if-idle", idleTimeoutKick);
|
||||
idleTimeoutTickNearbyEntities = getBoolean("gameplay-mechanics.player.idle-timeout.tick-nearby-entities", idleTimeoutTickNearbyEntities);
|
||||
@@ -324,6 +325,7 @@ public class PurpurWorldConfig {
|
||||
@@ -326,6 +327,7 @@ public class PurpurWorldConfig {
|
||||
playerFixStuckPortal = getBoolean("gameplay-mechanics.player.fix-stuck-in-portal", playerFixStuckPortal);
|
||||
creativeOnePunch = getBoolean("gameplay-mechanics.player.one-punch-in-creative", creativeOnePunch);
|
||||
playerSleepNearMonsters = getBoolean("gameplay-mechanics.player.sleep-ignore-nearby-mobs", playerSleepNearMonsters);
|
||||
|
||||
Reference in New Issue
Block a user