mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2025-07-03 00:15:35 +00:00
mixin maintenance
This commit is contained in:
parent
a30859a3d4
commit
6209b86560
@ -20,12 +20,6 @@ public abstract class ItemStackMixin {
|
||||
@Shadow
|
||||
public abstract net.minecraft.item.Item getItem();
|
||||
|
||||
@Shadow
|
||||
public abstract boolean isDamageable();
|
||||
|
||||
@Shadow
|
||||
public abstract ItemStack copy();
|
||||
|
||||
public int terra$getAmount() {
|
||||
return getCount();
|
||||
}
|
||||
@ -34,7 +28,7 @@ public abstract class ItemStackMixin {
|
||||
setCount(i);
|
||||
}
|
||||
|
||||
public Item getType() {
|
||||
public Item terra$getType() {
|
||||
return (Item) getItem();
|
||||
}
|
||||
|
||||
|
@ -8,6 +8,7 @@ import net.minecraft.nbt.ListTag;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
import org.spongepowered.asm.mixin.Implements;
|
||||
import org.spongepowered.asm.mixin.Interface;
|
||||
import org.spongepowered.asm.mixin.Intrinsic;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.Shadow;
|
||||
|
||||
@ -31,6 +32,7 @@ public abstract class ItemStackMetaMixin {
|
||||
return this;
|
||||
}
|
||||
|
||||
@Intrinsic(displace = true)
|
||||
public Map<Enchantment, Integer> terra$getEnchantments() {
|
||||
if(!hasEnchantments()) return Collections.emptyMap();
|
||||
Map<Enchantment, Integer> map = new HashMap<>();
|
||||
|
Loading…
x
Reference in New Issue
Block a user