[SPIGOT-2041] Item.isCooling() and Item.setCooldown() Created: 24/Mar/16  Updated: 28/Apr/17  Resolved: 28/Apr/17

Status: Resolved
Project: Spigot
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Minor
Reporter: Daniel Bai Assignee: Unassigned
Resolution: Fixed Votes: 1
Labels: 1.9, bukkit, spigot


 Description   

Pretty self explanatory.
1.9 added item cooldowns and the only way to give items cooldowns is to either use nms to grab the ItemCooldown object in the Item class or send the PacketPlayOutSetCooldown to players.

Or a method of similar function



 Comments   
Comment by Matthew Steglinski [ 28/Apr/17 ]

817fefd8466

Comment by Black Hole [ 24/Mar/16 ]

Related to SPIGOT-1769

Comment by Daniel Bai [ 24/Mar/16 ]

Just did a bit more digging on this and realized the cooldown is tied to the player.
So a suitable method would be like Player.isCooling(item) or Player.setCooldown(item, ticks) instead.

Generated at Fri Apr 11 15:51:05 UTC 2025 using Jira 10.3.3#10030003-sha1:d220e3fefc8dfc6d47f522d3b9a20c1455e12b7b.