Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-12-26 16:12:46 +01:00
GeyserItemStack: Remove item from equalsAndHashCode
Dieser Commit ist enthalten in:
Ursprung
545087fba4
Commit
58b593ef99
@ -28,6 +28,7 @@ package org.geysermc.geyser.inventory;
|
||||
import com.github.steveice10.mc.protocol.data.game.entity.metadata.ItemStack;
|
||||
import com.github.steveice10.opennbt.tag.builtin.CompoundTag;
|
||||
import lombok.AccessLevel;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.Getter;
|
||||
import org.cloudburstmc.protocol.bedrock.data.inventory.ItemData;
|
||||
import lombok.Data;
|
||||
@ -48,6 +49,10 @@ public class GeyserItemStack {
|
||||
private CompoundTag nbt;
|
||||
private int netId;
|
||||
|
||||
@Getter(AccessLevel.NONE)
|
||||
@EqualsAndHashCode.Exclude
|
||||
private Item item;
|
||||
|
||||
private GeyserItemStack(int javaId, int amount, CompoundTag nbt) {
|
||||
this(javaId, amount, nbt, 1);
|
||||
}
|
||||
@ -109,9 +114,6 @@ public class GeyserItemStack {
|
||||
return session.getItemMappings().getMapping(this.javaId);
|
||||
}
|
||||
|
||||
@Getter(AccessLevel.NONE)
|
||||
private Item item; //TODO
|
||||
|
||||
public Item asItem() {
|
||||
if (item == null) {
|
||||
return (item = Registries.JAVA_ITEMS.get().get(javaId));
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren