mirror of
https://github.com/Sollace/Unicopia.git
synced 2024-11-23 21:38:00 +01:00
The worm is no longer consumed when using the item in creative mode
This commit is contained in:
parent
ff18b2d4f0
commit
b3a46b0035
1 changed files with 8 additions and 6 deletions
|
@ -36,12 +36,14 @@ public class BaitedFishingRodItem extends FishingRodItem {
|
||||||
world.spawnEntity(bobber);
|
world.spawnEntity(bobber);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (oldFishHook != null
|
if (!user.isCreative()) {
|
||||||
&& oldFishHook.getHookedEntity() == null
|
if (oldFishHook != null
|
||||||
&& oldFishHook.getDataTracker().get(FishingBobberEntity.CAUGHT_FISH)
|
&& oldFishHook.getHookedEntity() == null
|
||||||
&& result.getValue().isOf(this)) {
|
&& oldFishHook.getDataTracker().get(FishingBobberEntity.CAUGHT_FISH)
|
||||||
ItemStack stack = result.getValue().withItem(Items.FISHING_ROD);
|
&& result.getValue().isOf(this)) {
|
||||||
return TypedActionResult.success(stack, world.isClient());
|
ItemStack stack = result.getValue().withItem(Items.FISHING_ROD);
|
||||||
|
return TypedActionResult.success(stack, world.isClient());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
|
|
Loading…
Reference in a new issue