Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void handleConsumable(Player player, int id, int slot) {
- Optional<Consumable> consumable = Consumable.get(id);
- if (!consumable.isPresent())
- return;
- /*
- * TODO: Reset Combat, skilling...
- * TODO: Animation
- * TODO: GFX
- */
- consumable.get().onConsumption();
- player.getInventory().set(slot, consumable.get().replacement(id), true);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement