[ci skip] Replace some magic values with constant references
This commit is contained in:
parent
b2a6d575dd
commit
7eaff48d7c
10 changed files with 30 additions and 30 deletions
|
@ -240,7 +240,7 @@ index 0000000000000000000000000000000000000000..8e6dac2cef7af26ad74928eff631c182
|
|||
+}
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/loottable/PaperLootableInventoryData.java b/src/main/java/com/destroystokyo/paper/loottable/PaperLootableInventoryData.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..5408cbc21fc7577a6100b5a1ca0463e899d2df8b
|
||||
index 0000000000000000000000000000000000000000..6e72c43b9d3834eb91c02ce68e7d114ad907812d
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/com/destroystokyo/paper/loottable/PaperLootableInventoryData.java
|
||||
@@ -0,0 +1,188 @@
|
||||
|
@ -364,8 +364,8 @@ index 0000000000000000000000000000000000000000..5408cbc21fc7577a6100b5a1ca0463e8
|
|||
+ if (comp.contains("numRefills")) {
|
||||
+ this.numRefills = comp.getInt("numRefills");
|
||||
+ }
|
||||
+ if (comp.contains("lootedPlayers", 9)) { // 9 = list
|
||||
+ ListTag list = comp.getList("lootedPlayers", 10); // 10 = compound
|
||||
+ if (comp.contains("lootedPlayers", net.minecraft.nbt.Tag.TAG_LIST)) {
|
||||
+ ListTag list = comp.getList("lootedPlayers", net.minecraft.nbt.Tag.TAG_COMPOUND);
|
||||
+ final int size = list.size();
|
||||
+ if (size > 0) {
|
||||
+ this.lootedPlayers = new HashMap<>(list.size());
|
||||
|
@ -504,7 +504,7 @@ index 0000000000000000000000000000000000000000..9cfa5d36a6991067a3866e0d437749fa
|
|||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
index cc762d3eb68d2f8bf9529ecf07adfc343953c7a2..1b7b3114cd6ced0587a0e7e4a4c94584c72ed17f 100644
|
||||
index e0534859f631e0bdec2db4ae92de0036c4bc62d2..d63cbd3e0e49a5c00d411574a3ca1d081c23dfdd 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
@@ -236,6 +236,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, S
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue