public class TunnelFloorDimension extends RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
Dimension
of which the terrain height follows the floor of a
particular Custom Cave/Tunnel Layer.
Created by pepijn on 31-7-15.Dimension.Anchor, Dimension.Border, Dimension.LayerAnchor, Dimension.Listener, Dimension.Role, Dimension.TileVisitationBuilder, Dimension.TileVisitor, Dimension.WallType
InstanceKeeper.InstantiationListener<T>
dimension, tileCache
POSSIBLE_AUTO_BIOMES
Constructor and Description |
---|
TunnelFloorDimension(Dimension dimension,
TunnelLayer layer,
TunnelLayerHelper helper) |
Modifier and Type | Method and Description |
---|---|
protected float |
determineHeight(boolean inTunnelLayer,
int tunnelFloorLevel,
int tunnelRoofLevel,
float realHeight) |
float |
getHeightAt(int x,
int y)
Get the terrain height at the specified coordinates, if a tile exists in the specified location.
|
float |
getHeightAt(java.awt.Point coords)
Get the terrain height at the specified coordinates, if a tile exists in the specified location.
|
int |
getIntHeightAt(int x,
int y)
Get the terrain height at the specified coordinates, rounded to the nearest integer, if a tile exists in the
specified location.
|
int |
getIntHeightAt(int x,
int y,
int defaultValue)
Get the terrain height at the specified coordinates, rounded to the nearest integer, if a tile exists in the
specified location.
|
int |
getIntHeightAt(java.awt.Point coords)
Get the terrain height at the specified coordinates, rounded to the nearest integer, if a tile exists in the
specified location.
|
int |
getWaterLevelAt(int x,
int y) |
int |
getWaterLevelAt(java.awt.Point coords) |
protected org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile |
wrapTile(Tile tile) |
addDimensionListener, addOverlay, addPropertyChangeListener, addPropertyChangeListener, addTile, allBitLayerDataChanged, allNonBitlayerDataChanged, applyTheme, applyTheme, armSavePoint, changed, clearLayerData, clearRedo, clearUndo, containsOneOf, doGetTile, getAllLayers, getAllLayerSettings, getAllTerrains, getAnchor, getBitLayerValueAt, getBorder, getBorderLevel, getBorderSize, getChangeNo, getContourSeparation, getCustomBiomes, getDistanceToEdge, getFloodedCount, getGarden, getGridSize, getHeight, getHighestX, getHighestY, getLastViewPosition, getLayerSettings, getLayerValueAt, getLayerValueAt, getLowestX, getLowestY, getMaxHeight, getMinecraftSeed, getMinimumLayers, getName, getOverlays, getRawHeightAt, getRawHeightAt, getRoofType, getSeed, getSlope, getSnapshot, getSubsurfaceMaterial, getTerrainAt, getTile, getTile, getTileCoords, getTileCount, getTileFactory, getTiles, getTopLayerDepth, getTopLayerMinDepth, getTopLayerVariation, getWallType, getWidth, getWorld, heightMapChanged, isBottomless, isContoursEnabled, isEventsInhibited, isGridEnabled, isOverlaysEnabled, isPopulate, isTilePresent, isUndoAvailable, layerDataChanged, registerUndoManager, removeDimensionListener, removeOverlay, removePropertyChangeListener, removePropertyChangeListener, removeTile, removeTile, removeTile, seedsChanged, setBitLayerValueAt, setBorder, setBorderLevel, setBorderSize, setBottomless, setContoursEnabled, setContourSeparation, setCustomBiomes, setEventsInhibited, setGridEnabled, setGridSize, setHeightAt, setHeightAt, setLastViewPosition, setLayerSettings, setLayerValueAt, setMaxHeight, setMinecraftSeed, setOverlaysEnabled, setPopulate, setRawHeightAt, setRawHeightAt, setRoofType, setSubsurfaceMaterial, setTerrainAt, setTerrainAt, setTopLayerMinDepth, setTopLayerVariation, setWallType, setWaterLevelAt, terrainChanged, transform, undoChanges, unregisterUndoManager, waterLevelChanged
clearLayerData, doGetDistanceToEdge, doGetFloodedCount, doGetSlope, getAttribute, getAutoBiome, getAutoBiome, getAutoBiome, getAutoBiome, getBitLayerCount, getCeilingHeight, getCustomLayers, getCustomLayers, getDistancesToEdge, getExportSettings, getExtent, getGenerator, getHeightRange, getHiddenPalettes, getHighestHeight, getHighestIntHeight, getHighestRawHeight, getId, getIntHeightRange, getLayersAt, getLowestHeight, getLowestIntHeight, getLowestRawHeight, getMinHeight, getMostPrevalentBiome, getRawHeightRange, getScale, getSoloedPalette, getSubsurfaceLayerAnchor, getTileForEditing, getTileForEditing, getTopLayerAnchor, getUndergroundBiome, isBorderTile, isCoverSteepTerrain, isFixOverlayCoords, rememberChanges, save, setAttribute, setCeilingHeight, setCoverSteepTerrain, setCustomLayers, setExportSettings, setFixOverlayCoords, setGenerator, setHiddenPalettes, setMinHeight, setName, setScale, setSoloedPalette, setSubsurfaceLayerAnchor, setTopLayerAnchor, setUndergroundBiome, setWorld, visitTiles, visitTilesForEditing
setInstantiationListener
public TunnelFloorDimension(Dimension dimension, TunnelLayer layer, TunnelLayerHelper helper)
protected float determineHeight(boolean inTunnelLayer, int tunnelFloorLevel, int tunnelRoofLevel, float realHeight)
public float getHeightAt(int x, int y)
Dimension
getHeightAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
x
- The X coordinate to query.y
- The Y coordinate to query.-Float.MAX_VALUE
if there is
no tile at the specified coordinates.public float getHeightAt(java.awt.Point coords)
Dimension
getHeightAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
coords
- The coordinates to query.-Float.MAX_VALUE
if there is
no tile at the specified coordinates.public int getWaterLevelAt(int x, int y)
getWaterLevelAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
public int getWaterLevelAt(java.awt.Point coords)
getWaterLevelAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
public int getIntHeightAt(int x, int y)
Dimension
getIntHeightAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
x
- The X coordinate to query.y
- The Y coordinate to query.Integer.MIN_VALUE
if there is no tile at the specified coordinates.public int getIntHeightAt(int x, int y, int defaultValue)
Dimension
getIntHeightAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
x
- The X coordinate to query.y
- The Y coordinate to query.defaultValue
- The value to return if there is no tile at the specified coordinates.defaultHeight
if there is no tile at the specified coordinates.public int getIntHeightAt(java.awt.Point coords)
Dimension
getIntHeightAt
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>
coords
- The coordinates to query.Integer.MIN_VALUE
if there is no tile at the specified coordinates.protected org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile wrapTile(Tile tile)
wrapTile
in class RODelegatingDimension<org.pepsoft.worldpainter.layers.tunnel.TunnelDimension.TunnelTile>