mirror of
https://github.com/PaperMC/Paper.git
synced 2025-07-31 20:22:05 -07:00
living entity allow attribute registration
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
--- a/net/minecraft/world/entity/ai/attributes/AttributeMap.java
|
||||
+++ b/net/minecraft/world/entity/ai/attributes/AttributeMap.java
|
||||
@@ -162,4 +162,12 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
+
|
||||
+ // Paper - start - living entity allow attribute registration
|
||||
+ public void registerAttribute(Holder<Attribute> attributeBase) {
|
||||
+ AttributeInstance attributeModifiable = new AttributeInstance(attributeBase, AttributeInstance::getAttribute);
|
||||
+ attributes.put(attributeBase, attributeModifiable);
|
||||
+ }
|
||||
+ // Paper - end - living entity allow attribute registration
|
||||
+
|
||||
}
|
Reference in New Issue
Block a user