Worlds

open class Worlds

Contains utility methods for accessing worlds

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open fun getAll(): List<World>
Gets a list of all worlds
open fun getAll(filter: Predicate<World>): List<World>
Gets a list of all worlds matching the specified filter
Link copied to clipboard
Gets the current world
Link copied to clipboard
open fun getFirst(worldNumber: Array<Int>): Optional<World>
Gets the first world with one of the specified world numbers
open fun getFirst(filter: Predicate<World>): Optional<World>
Gets the first world matching the specified filter
Link copied to clipboard
open fun getRandom(worldNumber: Array<Int>): Optional<World>
Gets a random world with one of the specified world numbers
open fun getRandom(filter: Predicate<World>): Optional<World>
Gets a random world that matches the specified filter
Link copied to clipboard
Gets a random members world, where the worlds types is exactly MEMBERS (won't match pvp worlds and so on)
Link copied to clipboard
Gets a random non members world, where the world has exactly no types (won't match pvp worlds and so on)