Merge remote-tracking branch 'citadel/master' into mobility_flags
This commit is contained in:
@@ -79,13 +79,17 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
color = "#ffffff"
|
||||
|
||||
// the power cable object
|
||||
/obj/structure/cable/Initialize(mapload, param_color)
|
||||
/obj/structure/cable/Initialize(mapload, param_color, _d1, _d2)
|
||||
. = ..()
|
||||
|
||||
// ensure d1 & d2 reflect the icon_state for entering and exiting cable
|
||||
var/dash = findtext(icon_state, "-")
|
||||
d1 = text2num( copytext( icon_state, 1, dash ) )
|
||||
d2 = text2num( copytext( icon_state, dash+1 ) )
|
||||
if(isnull(_d1) || isnull(_d2))
|
||||
// ensure d1 & d2 reflect the icon_state for entering and exiting cable
|
||||
var/dash = findtext(icon_state, "-")
|
||||
d1 = text2num( copytext( icon_state, 1, dash ) )
|
||||
d2 = text2num( copytext( icon_state, dash+1 ) )
|
||||
else
|
||||
d1 = _d1
|
||||
d2 = _d2
|
||||
|
||||
var/turf/T = get_turf(src) // hide if turf is not intact
|
||||
if(level==1)
|
||||
|
||||
@@ -23,6 +23,7 @@ GLOBAL_LIST_EMPTY(gravity_generators) // We will keep track of this by adding ne
|
||||
desc = "A device which produces a graviton field when set up."
|
||||
icon = 'icons/obj/machines/gravity_generator.dmi'
|
||||
density = TRUE
|
||||
move_resist = INFINITY
|
||||
use_power = NO_POWER_USE
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
var/sprite_number = 0
|
||||
|
||||
@@ -756,7 +756,7 @@
|
||||
/obj/item/light/bulb/broken
|
||||
status = LIGHT_BROKEN
|
||||
|
||||
/obj/item/light/throw_impact(atom/hit_atom)
|
||||
/obj/item/light/throw_impact(atom/hit_atom, datum/thrownthing/throwingdatum)
|
||||
if(!..()) //not caught by a mob
|
||||
shatter()
|
||||
|
||||
|
||||
@@ -103,6 +103,8 @@
|
||||
. += "<span class='notice'>The generator has [sheets] units of [sheet_name] fuel left, producing [power_gen] per cycle.</span>"
|
||||
if(crit_fail)
|
||||
. += "<span class='danger'>The generator seems to have broken down.</span>"
|
||||
if(in_range(user, src) || isobserver(user))
|
||||
. += "<span class='notice'>The status display reads: Fuel efficiency increased by <b>[(consumption*100)-100]%</b>.</span>"
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/HasFuel()
|
||||
if(sheets >= 1 / (time_per_sheet / power_output) - sheet_left)
|
||||
|
||||
@@ -36,6 +36,11 @@
|
||||
|
||||
power_gen = initial(power_gen) * part_level
|
||||
|
||||
/obj/machinery/power/rtg/examine(mob/user)
|
||||
. = ..()
|
||||
if(in_range(user, src) || isobserver(user))
|
||||
. += "<span class='notice'>The status display reads: Power generation now at <b>[power_gen*0.001]</b>kW.</span>"
|
||||
|
||||
/obj/machinery/power/rtg/attackby(obj/item/I, mob/user, params)
|
||||
if(default_deconstruction_screwdriver(user, "[initial(icon_state)]-open", initial(icon_state), I))
|
||||
return
|
||||
@@ -74,7 +79,7 @@
|
||||
addtimer(CALLBACK(GLOBAL_PROC, .proc/explosion, get_turf(src), 2, 3, 4, 8), 100) // Not a normal explosion.
|
||||
|
||||
/obj/machinery/power/rtg/abductor/bullet_act(obj/item/projectile/Proj)
|
||||
..()
|
||||
. = ..()
|
||||
if(!going_kaboom && istype(Proj) && !Proj.nodamage && ((Proj.damage_type == BURN) || (Proj.damage_type == BRUTE)))
|
||||
message_admins("[ADMIN_LOOKUPFLW(Proj.firer)] triggered an Abductor Core explosion at [AREACOORD(src)] via projectile.")
|
||||
log_game("[key_name(Proj.firer)] triggered an Abductor Core explosion at [AREACOORD(src)] via projectile.")
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
icon = 'icons/obj/singularity.dmi'
|
||||
icon_state = "Contain_F"
|
||||
density = FALSE
|
||||
move_resist = INFINITY
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
use_power = NO_POWER_USE
|
||||
interaction_flags_atom = NONE
|
||||
|
||||
@@ -68,6 +68,11 @@
|
||||
sparks.attach(src)
|
||||
sparks.set_up(1, TRUE, src)
|
||||
|
||||
/obj/machinery/power/emitter/examine(mob/user)
|
||||
. = ..()
|
||||
if(in_range(user, src) || isobserver(user))
|
||||
. += "<span class='notice'>The status display reads: Emitting one beam each <b>[fire_delay*0.1]</b> seconds.<br>Power consumption at <b>[active_power_usage]W</b>.</span>"
|
||||
|
||||
/obj/machinery/power/emitter/ComponentInitialize()
|
||||
. = ..()
|
||||
AddComponent(/datum/component/empprotection, EMP_PROTECT_SELF | EMP_PROTECT_WIRES)
|
||||
|
||||
@@ -245,6 +245,7 @@ field_generator power level display
|
||||
if(state != FG_WELDED || !anchored)
|
||||
turn_off()
|
||||
return
|
||||
move_resist = INFINITY
|
||||
spawn(1)
|
||||
setup_field(1)
|
||||
spawn(2)
|
||||
@@ -335,6 +336,7 @@ field_generator power level display
|
||||
message_admins("A singulo exists and a containment field has failed at [ADMIN_VERBOSEJMP(T)].")
|
||||
investigate_log("has <font color='red'>failed</font> whilst a singulo exists at [AREACOORD(T)].", INVESTIGATE_SINGULO)
|
||||
O.last_warning = world.time
|
||||
move_resist = initial(move_resist)
|
||||
|
||||
/obj/machinery/field/generator/shock(mob/living/user)
|
||||
if(fields.len)
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
icon_state = "singularity_s1"
|
||||
anchored = TRUE
|
||||
density = TRUE
|
||||
move_resist = INFINITY
|
||||
layer = MASSIVE_OBJ_LAYER
|
||||
light_range = 6
|
||||
appearance_flags = 0
|
||||
@@ -113,7 +114,8 @@
|
||||
|
||||
|
||||
/obj/singularity/bullet_act(obj/item/projectile/P)
|
||||
return 0 //Will there be an impact? Who knows. Will we see it? No.
|
||||
qdel(P)
|
||||
return BULLET_ACT_HIT //Will there be an impact? Who knows. Will we see it? No.
|
||||
|
||||
|
||||
/obj/singularity/Bump(atom/A)
|
||||
|
||||
@@ -521,7 +521,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_crystal)
|
||||
has_been_powered = TRUE
|
||||
else if(takes_damage)
|
||||
damage += Proj.damage * config_bullet_energy
|
||||
return FALSE
|
||||
return BULLET_ACT_HIT
|
||||
|
||||
/obj/machinery/power/supermatter_crystal/singularity_act()
|
||||
var/gain = 100
|
||||
|
||||
@@ -36,6 +36,11 @@
|
||||
zap_cooldown -= (C.rating * 20)
|
||||
input_power_multiplier = power_multiplier
|
||||
|
||||
/obj/machinery/power/tesla_coil/examine(mob/user)
|
||||
. = ..()
|
||||
if(in_range(user, src) || isobserver(user))
|
||||
. += "<span class='notice'>The status display reads: Power generation at <b>[input_power_multiplier*100]%</b>.<br>Shock interval at <b>[zap_cooldown*0.1]</b> seconds.</span>"
|
||||
|
||||
/obj/machinery/power/tesla_coil/on_construction()
|
||||
if(anchored)
|
||||
connect_to_network()
|
||||
|
||||
@@ -94,6 +94,11 @@
|
||||
E += M.rating
|
||||
efficiency = E / 6
|
||||
|
||||
/obj/machinery/power/compressor/examine(mob/user)
|
||||
. = ..()
|
||||
if(in_range(user, src) || isobserver(user))
|
||||
. += "<span class='notice'>The status display reads: Efficiency at <b>[efficiency*100]%</b>.</span>"
|
||||
|
||||
/obj/machinery/power/compressor/attackby(obj/item/I, mob/user, params)
|
||||
if(default_deconstruction_screwdriver(user, initial(icon_state), initial(icon_state), I))
|
||||
return
|
||||
@@ -176,6 +181,11 @@
|
||||
P += C.rating
|
||||
productivity = P / 6
|
||||
|
||||
/obj/machinery/power/turbine/examine(mob/user)
|
||||
. = ..()
|
||||
if(in_range(user, src) || isobserver(user))
|
||||
. += "<span class='notice'>The status display reads: Productivity at <b>[productivity*100]%</b>.</span>"
|
||||
|
||||
/obj/machinery/power/turbine/locate_machinery()
|
||||
if(compressor)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user