Package squidpony.squidgrid.gui.gdx
Class WildMapView
java.lang.Object
squidpony.squidgrid.gui.gdx.WildMapView
public class WildMapView extends Object
Created by Tommy Ettinger on 9/6/2019.
-
Field Summary
Fields Modifier and Type Field Description float[]
BIOME_COLOR_TABLE
float[]
BIOME_DARK_COLOR_TABLE
protected float[]
biomeColors
protected float[][]
colorMap
protected int
height
Map<String,? extends ICellVisible>
viewer
protected int
width
WildMap
wildMap
-
Constructor Summary
Constructors Constructor Description WildMapView()
WildMapView(long seed, int width, int height, int biome)
WildMapView(WildMap wildMap)
WildMapView(WildMap wildMap, Map<String,? extends ICellVisible> viewer)
-
Method Summary
Modifier and Type Method Description static HashMap<String,? extends ICellVisible>
defaultViewer()
void
generate()
float[][]
getColorMap()
int
getHeight()
int
getWidth()
WildMap
getWildMap()
void
initialize()
void
initialize(float hue, float saturation, float brightness, float contrast)
void
initialize(com.badlogic.gdx.graphics.Color desertColor, com.badlogic.gdx.graphics.Color savannaColor, com.badlogic.gdx.graphics.Color tropicalRainforestColor, com.badlogic.gdx.graphics.Color grasslandColor, com.badlogic.gdx.graphics.Color woodlandColor, com.badlogic.gdx.graphics.Color seasonalForestColor, com.badlogic.gdx.graphics.Color temperateRainforestColor, com.badlogic.gdx.graphics.Color borealForestColor, com.badlogic.gdx.graphics.Color tundraColor, com.badlogic.gdx.graphics.Color iceColor, com.badlogic.gdx.graphics.Color beachColor, com.badlogic.gdx.graphics.Color rockyColor, com.badlogic.gdx.graphics.Color shallowColor, com.badlogic.gdx.graphics.Color deepColor, com.badlogic.gdx.graphics.Color emptyColor)
Initializes the colors to use for each biome (these are almost always mixed with other biome colors in practice).void
setWildMap(WildMap wildMap)
void
show(SparseLayers layers)
-
Field Details
-
Constructor Details
-
Method Details
-
getWidth
-
getHeight
-
getColorMap
-
getWildMap
-
setWildMap
-
defaultViewer
-
initialize
-
initialize
-
initialize
public void initialize(com.badlogic.gdx.graphics.Color desertColor, com.badlogic.gdx.graphics.Color savannaColor, com.badlogic.gdx.graphics.Color tropicalRainforestColor, com.badlogic.gdx.graphics.Color grasslandColor, com.badlogic.gdx.graphics.Color woodlandColor, com.badlogic.gdx.graphics.Color seasonalForestColor, com.badlogic.gdx.graphics.Color temperateRainforestColor, com.badlogic.gdx.graphics.Color borealForestColor, com.badlogic.gdx.graphics.Color tundraColor, com.badlogic.gdx.graphics.Color iceColor, com.badlogic.gdx.graphics.Color beachColor, com.badlogic.gdx.graphics.Color rockyColor, com.badlogic.gdx.graphics.Color shallowColor, com.badlogic.gdx.graphics.Color deepColor, com.badlogic.gdx.graphics.Color emptyColor)Initializes the colors to use for each biome (these are almost always mixed with other biome colors in practice). Each parameter may be null to use the default for an Earth-like world; otherwise it should be a libGDXColor
or some subclass, likeSColor
. All non-null parameters should probably be fully opaque, exceptemptyColor
, which is only used for world maps that show empty space (like a globe, as produced byWorldMapGenerator.RotatingSpaceMap
).- Parameters:
desertColor
- hot, dry, barren land; may be sandy, but many real-world deserts don't have much sandsavannaColor
- hot, mostly-dry land with some parched vegetation; also called scrub or chaparraltropicalRainforestColor
- hot, extremely wet forests with dense rich vegetationgrasslandColor
- prairies that are dry and usually wind-swept, but not especially hot or coldwoodlandColor
- part-way between a prairie and a forest; not especially hot or coldseasonalForestColor
- forest that becomes barren in winter (deciduous trees); not especially hot or coldtemperateRainforestColor
- forest that tends to be slightly warm but very wetborealForestColor
- forest that tends to be cold and very wettundraColor
- very cold plains that still have some low-lying vegetation; also called taigaiceColor
- cold barren land covered in permafrost; also used for rivers and lakes that are frozenbeachColor
- sandy or otherwise light-colored shorelines; here, these are more common in warmer placesrockyColor
- rocky or otherwise rugged shorelines; here, these are more common in colder placesshallowColor
- the color of very shallow water; will be mixed withdeepColor
to get most ocean colorsdeepColor
- the color of very deep water; will be mixed withshallowColor
to get most ocean colorsemptyColor
- the color used for empty space off the edge of the world map; may be transparent
-
generate
-
show
-