Alien Ruin fix, various cherrypicked upstream fixes
Also adds new buildmode
This commit is contained in:
@@ -13,8 +13,9 @@
|
||||
var/environment_type = "asteroid"
|
||||
var/turf_type = /turf/open/floor/plating/asteroid //Because caves do whacky shit to revert to normal
|
||||
var/floor_variance = 20 //probability floor has a different icon state
|
||||
archdrops = list(/obj/item/stack/ore/glass = list(ARCH_PROB = 100,ARCH_MAXDROP = 5))
|
||||
attachment_holes = FALSE
|
||||
var/obj/item/stack/digResult = /obj/item/stack/ore/glass/basalt
|
||||
var/dug
|
||||
|
||||
/turf/open/floor/plating/asteroid/Initialize()
|
||||
var/proper_name = name
|
||||
@@ -23,6 +24,14 @@
|
||||
if(prob(floor_variance))
|
||||
icon_state = "[environment_type][rand(0,12)]"
|
||||
|
||||
/turf/open/floor/plating/asteroid/proc/getDug()
|
||||
new digResult(src, 5)
|
||||
if(postdig_icon_change)
|
||||
if(!postdig_icon)
|
||||
icon_plating = "[environment_type]_dug"
|
||||
icon_state = "[environment_type]_dug"
|
||||
dug = TRUE
|
||||
|
||||
/turf/open/floor/plating/asteroid/try_replace_tile(obj/item/stack/tile/T, mob/user, params)
|
||||
return
|
||||
|
||||
@@ -36,11 +45,26 @@
|
||||
return
|
||||
|
||||
/turf/open/floor/plating/asteroid/attackby(obj/item/W, mob/user, params)
|
||||
if(..())
|
||||
return TRUE
|
||||
if(istype(W, /obj/item/storage/bag/ore))
|
||||
for(var/obj/item/stack/ore/O in src)
|
||||
SEND_SIGNAL(W, COMSIG_PARENT_ATTACKBY, O)
|
||||
. = ..()
|
||||
if(!.)
|
||||
if(W.tool_behaviour == TOOL_SHOVEL || W.tool_behaviour == TOOL_MINING)
|
||||
if(dug)
|
||||
to_chat(user, "<span class='notice'>Looks like someone has dug here already.</span>")
|
||||
return TRUE
|
||||
|
||||
if(!isturf(user.loc))
|
||||
return
|
||||
|
||||
to_chat(user, "<span class='notice'>You start digging...</span>")
|
||||
|
||||
if(W.use_tool(src, user, 40, volume=50))
|
||||
to_chat(user, "<span class='notice'>You dig a hole.</span>")
|
||||
getDug()
|
||||
SSblackbox.record_feedback("tally", "pick_used_mining", 1, W.type)
|
||||
return TRUE
|
||||
else if(istype(W, /obj/item/storage/bag/ore))
|
||||
for(var/obj/item/stack/ore/O in src)
|
||||
SEND_SIGNAL(W, COMSIG_PARENT_ATTACKBY, O)
|
||||
|
||||
/turf/open/floor/plating/asteroid/singularity_act()
|
||||
if(is_planet_level(z))
|
||||
@@ -61,8 +85,8 @@
|
||||
icon_state = "basalt"
|
||||
icon_plating = "basalt"
|
||||
environment_type = "basalt"
|
||||
archdrops = list(/obj/item/stack/ore/glass/basalt = list(ARCH_PROB = 100,ARCH_MAXDROP = 5))
|
||||
floor_variance = 15
|
||||
digResult = /obj/item/stack/ore/glass/basalt
|
||||
|
||||
/turf/open/floor/plating/asteroid/basalt/lava //lava underneath
|
||||
baseturfs = /turf/open/lava/smooth
|
||||
@@ -73,9 +97,10 @@
|
||||
/turf/open/floor/plating/asteroid/basalt/Initialize()
|
||||
. = ..()
|
||||
set_basalt_light(src)
|
||||
GET_COMPONENT(arch, /datum/component/archaeology)
|
||||
ASSERT(isnull(arch.callback))
|
||||
arch.callback = CALLBACK(src, /atom/proc/set_light, 0)
|
||||
|
||||
/turf/open/floor/plating/asteroid/getDug()
|
||||
set_light(0)
|
||||
return ..()
|
||||
|
||||
/proc/set_basalt_light(turf/open/floor/B)
|
||||
switch(B.icon_state)
|
||||
@@ -276,10 +301,10 @@
|
||||
environment_type = "snow"
|
||||
flags_1 = NONE
|
||||
planetary_atmos = TRUE
|
||||
archdrops = list(/obj/item/stack/sheet/mineral/snow = list(ARCH_PROB = 100, ARCH_MAXDROP = 5))
|
||||
burnt_states = list("snow_dug")
|
||||
bullet_sizzle = TRUE
|
||||
bullet_bounce_sound = null
|
||||
digResult = /obj/item/stack/sheet/mineral/snow
|
||||
|
||||
/turf/open/floor/plating/asteroid/snow/burn_tile()
|
||||
if(!burnt)
|
||||
@@ -312,4 +337,4 @@
|
||||
|
||||
/turf/open/floor/plating/asteroid/snow/atmosphere
|
||||
initial_gas_mix = "o2=22;n2=82;TEMP=180"
|
||||
planetary_atmos = FALSE
|
||||
planetary_atmos = FALSE
|
||||
Reference in New Issue
Block a user