Package xyz.calcugames.levelz
Class Level3D
java.lang.Object
xyz.calcugames.levelz.Level
xyz.calcugames.levelz.Level3D
- All Implemented Interfaces:
Cloneable
,Iterable<LevelObject>
Represents a 3D level.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionclone()
@NotNull @Unmodifiable Set<LevelObject>
Gets an immutable copy of all blocks to their coordinates in this level.Gets an immutable copy of all coordinates in this level.getSpawn()
Gets the spawn point for this level.Methods inherited from class xyz.calcugames.levelz.Level
getHeaders, iterator
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
Level3D
public Level3D()Creates an empty 3D Level. -
Level3D
Creates a new 3D Level with the given headers.- Parameters:
headers
- Level Headers
-
Level3D
public Level3D(@NotNull @NotNull Map<String, String> headers, @NotNull @NotNull Collection<LevelObject> blocks) Creates a new 3D Level with the given headers and blocks.- Parameters:
headers
- Level Headersblocks
- Level Blocks
-
-
Method Details
-
getSpawn
Description copied from class:Level
Gets the spawn point for this level. -
getCoordinates
Description copied from class:Level
Gets an immutable copy of all coordinates in this level.- Specified by:
getCoordinates
in classLevel
- Returns:
- Level Coordinates
-
getBlocks
Description copied from class:Level
Gets an immutable copy of all blocks to their coordinates in this level. -
clone
-