Package org.spongepowered.api.util
Interface MinecraftDayTime.Factory
- Enclosing interface:
- MinecraftDayTime
public static interface MinecraftDayTime.Factory
Creates
MinecraftDayTime
objects.-
Method Details
-
epoch
MinecraftDayTime epoch()- Returns:
- The
MinecraftDayTime
- See Also:
-
of
- Parameters:
engine
- TheEngine
to use in calculating the day timeduration
- The duration since the Minecraft Epoch.- Returns:
- The
MinecraftDayTime
- Throws:
IllegalArgumentException
- if the duration is negative- See Also:
-
of
- Parameters:
days
- The day to set. Must be positive.hours
- The hour to set in 24 hour time.minutes
- The minute to set.- Returns:
- The
MinecraftDayTime
. - Throws:
IllegalArgumentException
- if any of the listed constraints are violated.- See Also:
-
of
- Parameters:
engine
- TheEngine
to calculate the time for.ticks
- TheTicks
since the Minecraft Epoch.- Returns:
- The
MinecraftDayTime
- Throws:
IllegalArgumentException
- if the tick count is negative- See Also:
-