mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-22 02:47:43 +01:00
Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly Paper Changes:26c37d99d5create random seeds for features using SecureRandom589bf2f1bfUpgrade gson to 2.8.8 (Closes #6370)0a6103597bGet entity default attributes (#6449)40057019e0Correctly inflate villager activation bounding box (#6798)e5f9241d15Left handed API (#6775)40ee63496cAdd advancement display API (#6175)9d570042edAdd ItemFactory#getMonsterEgg API (#6772)55ca459515rename method to getSpawnEggbb397ba74cAdd critical damage API (#6275)f47aeafe00Add Horse Animation API (#5599)7a0886180fAT & Mapping fixes (#6809)5553432644docs: Update gradle instructions for Java 16 (#6811) [ci skip]a1f49e4c60Fix command suggestion leak (#6592)9472d38f3cFix method name for Critical damage (#6813)
This commit is contained in:
46
patches/server/0084-Squid-EAR-immunity.patch
Normal file
46
patches/server/0084-Squid-EAR-immunity.patch
Normal file
@@ -0,0 +1,46 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: William Blake Galbreath <blake.galbreath@gmail.com>
|
||||
Date: Mon, 13 Jul 2020 13:49:41 -0500
|
||||
Subject: [PATCH] Squid EAR immunity
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
index 213950f1d36c504824d0053843c3fe869f9eed84..1c1a1ed14a1e2a80b3a26cb990b2577904d73b0b 100644
|
||||
--- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
+++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
@@ -1289,6 +1289,7 @@ public class PurpurWorldConfig {
|
||||
|
||||
public boolean squidRidable = false;
|
||||
public double squidMaxHealth = 10.0D;
|
||||
+ public boolean squidImmuneToEAR = true;
|
||||
private void squidSettings() {
|
||||
squidRidable = getBoolean("mobs.squid.ridable", squidRidable);
|
||||
if (PurpurConfig.version < 10) {
|
||||
@@ -1297,6 +1298,7 @@ public class PurpurWorldConfig {
|
||||
set("mobs.squid.attributes.max_health", oldValue);
|
||||
}
|
||||
squidMaxHealth = getDouble("mobs.squid.attributes.max_health", squidMaxHealth);
|
||||
+ squidImmuneToEAR = getBoolean("mobs.squid.immune-to-EAR", squidImmuneToEAR);
|
||||
}
|
||||
|
||||
public boolean spiderRidable = false;
|
||||
diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java
|
||||
index ff33287dabcc9724920e747d53efb4dada006cb2..d1c78ca9d6eddf293dc81ee056275727c218a679 100644
|
||||
--- a/src/main/java/org/spigotmc/ActivationRange.java
|
||||
+++ b/src/main/java/org/spigotmc/ActivationRange.java
|
||||
@@ -14,6 +14,7 @@ import net.minecraft.world.entity.ambient.AmbientCreature;
|
||||
import net.minecraft.world.entity.animal.Animal;
|
||||
import net.minecraft.world.entity.animal.Bee;
|
||||
import net.minecraft.world.entity.animal.Sheep;
|
||||
+import net.minecraft.world.entity.animal.Squid;
|
||||
import net.minecraft.world.entity.animal.WaterAnimal;
|
||||
import net.minecraft.world.entity.animal.horse.Llama;
|
||||
import net.minecraft.world.entity.boss.EnderDragonPart;
|
||||
@@ -376,6 +377,7 @@ public class ActivationRange
|
||||
*/
|
||||
public static boolean checkIfActive(Entity entity)
|
||||
{
|
||||
+ if (entity.level.purpurConfig.squidImmuneToEAR && entity instanceof Squid) return true; // Purpur
|
||||
// Never safe to skip fireworks or entities not yet added to chunk
|
||||
if ( entity instanceof FireworkRocketEntity ) {
|
||||
return true;
|
||||
Reference in New Issue
Block a user