All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.tealcube.minecraft.bukkit.mythicdrops.settings.spawning.MythicNumberOfPasses.kt Maven / Gradle / Ivy

There is a newer version: 9.0.4
Show newest version
package com.tealcube.minecraft.bukkit.mythicdrops.settings.spawning

import com.tealcube.minecraft.bukkit.mythicdrops.api.settings.spawning.NumberOfPasses
import com.tealcube.minecraft.bukkit.mythicdrops.safeRandom
import kotlin.math.max
import kotlin.math.min

data class MythicNumberOfPasses(
    private val pMinimum: Int,
    private val pMaximum: Int,
    override val minimum: Int = min(pMinimum, pMaximum),
    override val maximum: Int = max(pMinimum, pMaximum)
) : NumberOfPasses {
    override fun random(): Int = (minimum..maximum).safeRandom()
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy