mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-22 02:25:28 +01:00
Fix a few cases of the vanilla mob goals
This commit is contained in:
parent
3fb6b93f96
commit
08fe6d3c86
@ -36,10 +36,10 @@ index 86cce7143abd317326cc755118bf61435e82e479..4233698d499b520dfc07c4184cefca63
|
||||
<!-- This builds a completely 'ready to start' jar with all dependencies inside -->
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java b/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..9efe7e29faf09901e8cde8713db80ceb31453412
|
||||
index 0000000000000000000000000000000000000000..dfc026d183adab1dde5942f36e7a281b3a2fc699
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java
|
||||
@@ -0,0 +1,463 @@
|
||||
@@ -0,0 +1,467 @@
|
||||
+package com.destroystokyo.paper.entity.ai;
|
||||
+
|
||||
+import com.destroystokyo.paper.entity.RangedEntity;
|
||||
@ -279,6 +279,8 @@ index 0000000000000000000000000000000000000000..9efe7e29faf09901e8cde8713db80ceb
|
||||
+
|
||||
+ ignored.add("goal_selector_1");
|
||||
+ ignored.add("goal_selector_2");
|
||||
+ ignored.add("selector_1");
|
||||
+ ignored.add("selector_2");
|
||||
+ ignored.add("wrapped");
|
||||
+
|
||||
+ bukkitMap.put(net.minecraft.world.entity.Mob.class, Mob.class);
|
||||
@ -396,6 +398,8 @@ index 0000000000000000000000000000000000000000..9efe7e29faf09901e8cde8713db80ceb
|
||||
+ }
|
||||
+ }
|
||||
+ name = name.replace("PathfinderGoal", "");
|
||||
+ name = name.replace("TargetGoal", "");
|
||||
+ name = name.replace("Goal", "");
|
||||
+ StringBuilder sb = new StringBuilder();
|
||||
+ for (char c : name.toCharArray()) {
|
||||
+ if (c >= 'A' && c <= 'Z') {
|
||||
@ -937,7 +941,7 @@ index 130ab05393a7136020e06ec199256a031ba66091..8dd93620a770855450ed222dad6572e2
|
||||
}
|
||||
diff --git a/src/test/java/com/destroystokyo/paper/entity/ai/VanillaMobGoalTest.java b/src/test/java/com/destroystokyo/paper/entity/ai/VanillaMobGoalTest.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..33597ba747c10bc9e2a89e6920f64ce5a737967e
|
||||
index 0000000000000000000000000000000000000000..b2d510459bcf90a3611f3d91dae4ccc3d29b4079
|
||||
--- /dev/null
|
||||
+++ b/src/test/java/com/destroystokyo/paper/entity/ai/VanillaMobGoalTest.java
|
||||
@@ -0,0 +1,105 @@
|
||||
|
Loading…
Reference in New Issue
Block a user