Skip to content

Instantly share code, notes, and snippets.

@its-jackson
Created August 13, 2023 02:44
Show Gist options
  • Save its-jackson/1abba56f18b94810907ee6636f53fdc9 to your computer and use it in GitHub Desktop.
Save its-jackson/1abba56f18b94810907ee6636f53fdc9 to your computer and use it in GitHub Desktop.
package scripts.kotlin.api.framework.routine.api.interfaces
import scripts.kotlin.api.framework.routine.api.Consumable
interface TribotConsumableManager : ConsumableManager {
val consumables: Array<Consumable>
override fun checkAll(): Consumable? {
for (c in consumables) {
if (consume(c)) {
logger.debug("Consumed: $c")
logger.debug("Total doses left for $c: ${c.getTotalDoses()}")
return c
}
}
return null
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment