TimerAPI
An api easily create and coding as simple to timer.
Quick challenge
How far can you run before the mobs catch you?
Minecraft check
Confirm your run
Complete the quick check to get your code.
TimerAPI
TimerAPI
An api easily create and coding as simple to timer.
Features
* On start, end and tick handling * Method chain writing * Some utility methods * Run timer as async
Usage
Add below to `build.gradle.kts`. ```kotlin repositories { maven("https://repo.chihuyu.love/snapshots/") } ``` ```kotlin dependencies { compileOnly("love.chihuyu:TimerAPI:1.4.1-SNAPSHOT") } ```
Example
```kotlin // this timer length is 180 * 20(1sec) = 3600tick(3min) val timer = TimerAPI.build("wait ramen", duration = 180, period = 20, delay = 0) .start { hotWater.drip() } .tick { some() } .end { ramen.eat() }
timer.run() ```
Support
If you need any help or want to share some ideas to add, just DM me!
Discord: @hirosukt