[Discontinued] Cooldown API | 1.8.8/1.9.2/1.9.4/1.10 1.0

Cooldown API to help you code

  1. Pyshicon
    Tested Minecraft Versions:
    • 1.8
    • 1.9
    • 1.10
    Contributors:
    Pyshicon
    Cooldown API

    How to use,

    To use Cooldown API you need to understand some methods.
    But first to use the API put this in your class:
    Code (Text):
    public Cooldown cd = new Cooldown();
    the "cd" is optional, you can name it whatever you want.


    And now here's the methods available:

    Get player's cooldown.
    Type: int

    Code (Text):
    cd.getPlayer(player);
    Get if player is added to cooldown
    Type: boolean

    Code (Text):
    cd.containsPlayer(player);
    Add and Remove player from cooldown
    Type: void

    Code (Text):
    cd.addPlayer(player);
    Code (Text):
    cd.removePlayer(player);
    Run the timer
    Type: void

    Code (Text):
    cd.runTimer(player);
    Get time left from a player's cooldown
    Type: int

    Code (Text):
    cd.getDaysLeft(player);
    Code (Text):
    cd.getHoursLeft(player);
    Code (Text):
    cd.getMinutesLeft(player);
    Code (Text):
    cd.getSecondsLeft(player);
    Supported version,
    • 1.8.8
    • 1.9.2
    • 1.9.4
    • 1.10
    RuverQ and Yoyo522 like this.