organize that
This commit is contained in:
parent
38af4e9ba1
commit
d639d725f0
1 changed files with 9 additions and 0 deletions
|
@ -21,6 +21,9 @@ public abstract class ItemsMixin {
|
|||
at = @At(value = "INVOKE", target = "Lnet/minecraft/item/BlockItem;<init>(Lnet/minecraft/block/Block;Lnet/minecraft/item/Item$Settings;)V")
|
||||
)
|
||||
private static Item.Settings ModifySettings(Block block, Item.Settings settings) {
|
||||
/*
|
||||
REASONABLY FOOD (so no .snack modifier
|
||||
*/
|
||||
/* TODO: Make pumpkin give player a carved pumpkin
|
||||
if (block == Blocks.PUMPKIN) {
|
||||
return settings.food(new FoodComponent.Builder()
|
||||
|
@ -48,8 +51,12 @@ public abstract class ItemsMixin {
|
|||
.statusEffect(new StatusEffectInstance(StatusEffects.SLOWNESS, 5, 1 / 2), 0.7f)
|
||||
.build());
|
||||
}
|
||||
/*
|
||||
NOT FOOD (so .snack modifier
|
||||
*/
|
||||
if (block == Blocks.BEEHIVE) {
|
||||
return settings.food(new FoodComponent.Builder()
|
||||
.snack()
|
||||
.hunger(9)
|
||||
.saturationModifier(0.3F)
|
||||
.statusEffect(new StatusEffectInstance(StatusEffects.INSTANT_DAMAGE, 1, 1 / 2), 1f)
|
||||
|
@ -58,6 +65,7 @@ public abstract class ItemsMixin {
|
|||
}
|
||||
if (block == Blocks.BEE_NEST) {
|
||||
return settings.food(new FoodComponent.Builder()
|
||||
.snack()
|
||||
.hunger(9)
|
||||
.saturationModifier(0.3F)
|
||||
.statusEffect(new StatusEffectInstance(StatusEffects.INSTANT_DAMAGE, 1, 1 / 2), 1f)
|
||||
|
@ -71,6 +79,7 @@ public abstract class ItemsMixin {
|
|||
.statusEffect(new StatusEffectInstance(StatusEffects.INSTANT_DAMAGE, 1, 1 / 3), 1f)
|
||||
.build());
|
||||
}
|
||||
// else return edible snacky
|
||||
else {
|
||||
return settings.food(
|
||||
new FoodComponent.Builder()
|
||||
|
|
Loading…
Reference in a new issue