-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🚀 try catch the circles clicker player
- Loading branch information
Showing
3 changed files
with
225 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
yiski-common/src/main/kotlin/one/devos/yiski/common/utils/NazTimeHelper.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package one.devos.yiski.common.utils | ||
|
||
import kotlin.time.Duration | ||
|
||
fun Duration.toTimeString() : String { | ||
return "${zeroPad(this.inWholeMinutes - (this.inWholeHours * 60))}:${zeroPad(this.inWholeSeconds - (this.inWholeMinutes * 60))}" | ||
} | ||
|
||
private fun zeroPad(num: Long): String { | ||
return if (num <= 9) | ||
"0$num" | ||
else | ||
"$num" | ||
} |
Oops, something went wrong.