mirror of
https://github.com/Xiao-MoMi/craft-engine.git
synced 2025-12-29 11:59:11 +00:00
移除一些方法以便重构
This commit is contained in:
@@ -280,16 +280,6 @@ public class AbstractItem<W extends ItemWrapper<I>, I> implements Item<I> {
|
||||
return this.factory.load(this.item);
|
||||
}
|
||||
|
||||
@Override
|
||||
public I loadCopy() {
|
||||
return this.factory.loadCopy(this.item);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void update() {
|
||||
this.factory.update(this.item);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Item<I> copyWithCount(int count) {
|
||||
return new AbstractItem<>(this.factory, this.item.copyWithCount(count));
|
||||
|
||||
@@ -114,10 +114,6 @@ public interface Item<I> {
|
||||
|
||||
I load();
|
||||
|
||||
I loadCopy();
|
||||
|
||||
void update();
|
||||
|
||||
int maxStackSize();
|
||||
|
||||
Item<I> maxStackSize(int amount);
|
||||
|
||||
@@ -45,14 +45,10 @@ public abstract class ItemFactory<P extends Plugin, W extends ItemWrapper<I>, I>
|
||||
|
||||
protected abstract void resetComponent(ItemWrapper<I> item, Key type);
|
||||
|
||||
protected abstract void update(ItemWrapper<I> item);
|
||||
|
||||
protected abstract I load(ItemWrapper<I> item);
|
||||
|
||||
protected abstract I getItem(ItemWrapper<I> item);
|
||||
|
||||
protected abstract I loadCopy(ItemWrapper<I> item);
|
||||
|
||||
protected abstract void customModelData(ItemWrapper<I> item, Integer data);
|
||||
|
||||
protected abstract Optional<Integer> customModelData(ItemWrapper<I> item);
|
||||
|
||||
@@ -6,12 +6,8 @@ public interface ItemWrapper<I> {
|
||||
|
||||
I getItem();
|
||||
|
||||
void update();
|
||||
|
||||
I load();
|
||||
|
||||
I loadCopy();
|
||||
|
||||
Object getLiteralObject();
|
||||
|
||||
boolean set(Object value, Object... path);
|
||||
|
||||
Reference in New Issue
Block a user