equality issues and docs
This commit is contained in:
1 parent
2167c929d5
commit
768c44cc14
12 files changed
+469
-429
No files matched your search
@@ -202,11 +202,11 @@ public class NBTSerializableValue extends Value implements ContainerValueInterfa
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(final Value o)
|
||||
public boolean equals(final Object o)
|
||||
{
|
||||
if (o instanceof NBTSerializableValue)
|
||||
return getTag().equals(((NBTSerializableValue) o).getTag());
|
||||
return super.equals(o);
|
||||
return super.equals((Value)o);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -408,17 +408,13 @@ public class NBTSerializableValue extends Value implements ContainerValueInterfa
|
||||
}
|
||||
|
||||
@Override
|
||||
public Value remove(Value where)
|
||||
public Value delete(Value where)
|
||||
{
|
||||
NbtPathArgumentType.NbtPath path = cachePath(where.getString());
|
||||
Tag tag = getTag().copy();
|
||||
int removed = path.remove(tag);
|
||||
if (removed > 0)
|
||||
{
|
||||
replaceTag(tag);
|
||||
return Value.TRUE;
|
||||
}
|
||||
return Value.FALSE;
|
||||
if (removed > 0) replaceTag(tag);
|
||||
return new NumericValue(removed);
|
||||
}
|
||||
|
||||
public static class InventoryLocator
|
||||
|
||||
Reference in new issue
Block a user