Enables overmap on SC, adds Sif to SC skybox (#6954)

* Enables overmap on SC, adds wip Sif to SC skybox

* codersprites
This commit is contained in:
Atermonera
2020-06-17 16:12:20 -07:00
committed by Leshana
parent 730e5899ce
commit ebe7bd1975
10 changed files with 119 additions and 7 deletions

View File

@@ -0,0 +1,98 @@
/obj/effect/overmap/visitable/planet
name = "planet"
icon_state = "globe"
in_space = 0
var/datum/gas_mixture/atmosphere
var/atmosphere_color = "FFFFFF"
var/mountain_color = "#735555"
var/surface_color = "#304A35"
var/water_color = "#436499"
var/has_rings = FALSE // set to true to get rings
var/icecaps = null // Iconstate in icons/skybox/planet.dmi for the planet's icecaps
var/ice_color = "E6F2F6"
var/ring_color
var/skybox_offset_x = 0
var/skybox_offset_y = 0
/obj/effect/overmap/visitable/planet/Initialize()
. = ..()
/obj/effect/overmap/visitable/planet/get_skybox_representation()
var/image/skybox_image = image('icons/skybox/planet.dmi', "")
skybox_image.overlays += get_base_image()
// for(var/datum/exoplanet_theme/theme in themes)
// skybox_image.overlays += theme.get_planet_image_extra()
if(mountain_color)
var/image/mountains = image('icons/skybox/planet.dmi', "mountains")
mountains.color = mountain_color
mountains.appearance_flags = PIXEL_SCALE
skybox_image.overlays += mountains
if(water_color)
var/image/water = image('icons/skybox/planet.dmi', "water")
water.color = water_color
water.appearance_flags = PIXEL_SCALE
// water.transform = water.transform.Turn(rand(0,360))
skybox_image.overlays += water
if(icecaps)
var/image/ice = image('icons/skybox/planet.dmi', icecaps)
ice.color = ice_color
ice.appearance_flags = PIXEL_SCALE
skybox_image.overlays += ice
if(atmosphere && atmosphere.return_pressure() > SOUND_MINIMUM_PRESSURE)
var/atmo_color = get_atmosphere_color()
if(!atmo_color)
atmo_color = COLOR_WHITE
var/image/clouds = image('icons/skybox/planet.dmi', "weak_clouds")
if(water_color)
clouds.overlays += image('icons/skybox/planet.dmi', "clouds")
clouds.color = atmo_color
skybox_image.overlays += clouds
var/image/atmo = image('icons/skybox/planet.dmi', "atmoring")
skybox_image.underlays += atmo
var/image/shadow = image('icons/skybox/planet.dmi', "shadow")
shadow.blend_mode = BLEND_MULTIPLY
skybox_image.overlays += shadow
var/image/light = image('icons/skybox/planet.dmi', "lightrim")
skybox_image.overlays += light
if(has_rings)
var/image/rings = image('icons/skybox/planet_rings.dmi')
rings.icon_state = pick("sparse", "dense")
if(!ring_color)
rings.color = pick("#f0fcff", "#dcc4ad", "#d1dcad", "#adb8dc")
else
rings.color = ring_color
rings.pixel_x = -128
rings.pixel_y = -128
skybox_image.overlays += rings
skybox_image.pixel_x = rand(0,64) + skybox_offset_x
skybox_image.pixel_y = rand(128,256) + skybox_offset_y
skybox_image.appearance_flags = RESET_COLOR
return skybox_image
/obj/effect/overmap/visitable/planet/proc/get_base_image()
var/image/base = image('icons/skybox/planet.dmi', "base")
base.color = get_surface_color()
return base
/obj/effect/overmap/visitable/planet/proc/get_surface_color()
return surface_color
/obj/effect/overmap/visitable/planet/proc/get_atmosphere_color()
return atmosphere_color

View File

@@ -6,7 +6,7 @@
scannable = TRUE
scanner_desc = "!! No Data Available !!"
var/list/map_z = list()
var/list/map_z = null
var/list/extra_z_levels //if you need to manually insist that these z-levels are part of this sector, for things like edge-of-map step trigger transitions rather than multi-z complexes
var/list/initial_generic_waypoints //store landmark_tag of landmarks that should be added to the actual lists below on init.
@@ -31,7 +31,8 @@
if(. == INITIALIZE_HINT_QDEL)
return
find_z_levels() // This populates map_z and assigns z levels to the ship.
if(!map_z) // If map_z is already defined, we don't need to find where we are
find_z_levels() // This populates map_z and assigns z levels to the ship.
register_z_levels() // This makes external calls to update global z level information.
if(!global.using_map.overmap_z)