mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-17 12:15:11 +00:00
ScriptItemStack, ScriptEntity, ScriptBlock, & ScriptBlockPos:
-Implemented equals() functions for comparing objects of these types
This commit is contained in:
1 parent
826a90bd6d
commit
29fb8d1dcf
5 files changed
+19
-6
No files matched your search
@@ -409,4 +409,8 @@ public class ScriptItemStack implements IItemStack {
|
||||
public int itemHash() {
|
||||
return item.hashCode();
|
||||
}
|
||||
|
||||
public boolean equals(Object object) {
|
||||
return object instanceof ScriptItemStack && ((ScriptItemStack) object).getMCItemStack().equals(this.getMCItemStack());
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user