Merge branch 'master' of https://github.com/Citadel-Station-13/Citadel-Station-13 into station_traits
This commit is contained in:
@@ -126,7 +126,7 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
|
||||
ambientsounds = RUINS
|
||||
area_flags = UNIQUE_AREA | NO_ALERTS
|
||||
|
||||
/area/asteroid/artifactroom/Initialize()
|
||||
/area/asteroid/artifactroom/Initialize(mapload)
|
||||
. = ..()
|
||||
set_dynamic_lighting()
|
||||
|
||||
|
||||
@@ -31,6 +31,6 @@
|
||||
cam.lostTargetRef(WEAKREF(O))
|
||||
return
|
||||
|
||||
/area/ai_monitored/turret_protected/ai/Initialize()
|
||||
/area/ai_monitored/turret_protected/ai/Initialize(mapload)
|
||||
. = ..()
|
||||
src.area_flags |= ABDUCTOR_PROOF
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
|
||||
///Will objects this area be needing power?
|
||||
var/requires_power = TRUE
|
||||
/// This gets overridden to 1 for space in area/Initialize().
|
||||
/// This gets overridden to 1 for space in area/Initialize(mapload).
|
||||
var/always_unpowered = FALSE
|
||||
|
||||
var/power_equip = TRUE
|
||||
@@ -197,7 +197,7 @@ GLOBAL_LIST_EMPTY(teleportlocs)
|
||||
*
|
||||
* returns INITIALIZE_HINT_LATELOAD
|
||||
*/
|
||||
/area/Initialize()
|
||||
/area/Initialize(mapload)
|
||||
icon_state = ""
|
||||
map_name = name // Save the initial (the name set in the map) name of the area.
|
||||
canSmoothWithAreas = typecacheof(canSmoothWithAreas)
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
icon_state = "supplypod_loading"
|
||||
var/loading_id = ""
|
||||
|
||||
/area/centcom/supplypod/loading/Initialize()
|
||||
/area/centcom/supplypod/loading/Initialize(mapload)
|
||||
. = ..()
|
||||
if(!loading_id)
|
||||
CRASH("[type] created without a loading_id")
|
||||
|
||||
@@ -169,7 +169,7 @@
|
||||
name = "planet z helper"
|
||||
layer = POINT_LAYER
|
||||
|
||||
/obj/effect/mapping_helpers/planet_z/Initialize()
|
||||
/obj/effect/mapping_helpers/planet_z/Initialize(mapload)
|
||||
. = ..()
|
||||
var/datum/space_level/S = SSmapping.get_level(z)
|
||||
S.traits["Planet"] = TRUE //This probably doesn't work as I expect. But maybe!!
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
Asserts are to avoid the inevitable infinite loops
|
||||
*/
|
||||
|
||||
/area/holodeck/Initialize()
|
||||
/area/holodeck/Initialize(mapload)
|
||||
. = ..()
|
||||
var/list/update_holodeck_cache = SSholodeck?.rejected_areas[type]
|
||||
if(update_holodeck_cache)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
// area_limited_icon_smoothing = /area/shuttle
|
||||
sound_environment = SOUND_ENVIRONMENT_ROOM
|
||||
|
||||
/area/shuttle/Initialize()
|
||||
/area/shuttle/Initialize(mapload)
|
||||
if(!canSmoothWithAreas)
|
||||
canSmoothWithAreas = type
|
||||
. = ..()
|
||||
|
||||
+36
-8
@@ -9,6 +9,9 @@
|
||||
plane = GAME_PLANE
|
||||
appearance_flags = TILE_BOUND
|
||||
|
||||
/// pass_flags that we are. If any of this matches a pass_flag on a moving thing, by default, we let them through.
|
||||
var/pass_flags_self = NONE
|
||||
|
||||
var/level = 2
|
||||
///If non-null, overrides a/an/some in all cases
|
||||
var/article
|
||||
@@ -267,14 +270,29 @@
|
||||
var/a_incidence_s = abs(incidence_s)
|
||||
if(a_incidence_s > 90 && a_incidence_s < 270)
|
||||
return FALSE
|
||||
if((P.flag in list("bullet", "bomb")) && P.ricochet_incidence_leeway)
|
||||
if((P.flag in list(BULLET, BOMB)) && P.ricochet_incidence_leeway)
|
||||
if((a_incidence_s < 90 && a_incidence_s < 90 - P.ricochet_incidence_leeway) || (a_incidence_s > 270 && a_incidence_s -270 > P.ricochet_incidence_leeway))
|
||||
return
|
||||
return FALSE
|
||||
var/new_angle_s = SIMPLIFY_DEGREES(face_angle + incidence_s)
|
||||
P.setAngle(new_angle_s)
|
||||
return TRUE
|
||||
|
||||
/atom/proc/CanPass(atom/movable/mover, turf/target)
|
||||
//SHOULD_CALL_PARENT(TRUE)
|
||||
if(mover.movement_type & PHASING)
|
||||
return TRUE
|
||||
. = CanAllowThrough(mover, target)
|
||||
// This is cheaper than calling the proc every time since most things dont override CanPassThrough
|
||||
if(!mover.generic_canpass)
|
||||
return mover.CanPassThrough(src, target, .)
|
||||
|
||||
/// Returns true or false to allow the mover to move through src
|
||||
/atom/proc/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
//SHOULD_CALL_PARENT(TRUE)
|
||||
if(mover.pass_flags & pass_flags_self)
|
||||
return TRUE
|
||||
if(mover.throwing && (pass_flags_self & LETPASSTHROW))
|
||||
return TRUE
|
||||
return !density
|
||||
|
||||
/**
|
||||
@@ -445,9 +463,19 @@
|
||||
wires.emp_pulse(severity)
|
||||
return protection // Pass the protection value collected here upwards
|
||||
|
||||
/atom/proc/bullet_act(obj/item/projectile/P, def_zone)
|
||||
/**
|
||||
* React to a hit by a projectile object
|
||||
*
|
||||
* Default behaviour is to send the [COMSIG_ATOM_BULLET_ACT] and then call [on_hit][/obj/item/projectile/proc/on_hit] on the projectile
|
||||
*
|
||||
* @params
|
||||
* P - projectile
|
||||
* def_zone - zone hit
|
||||
* piercing_hit - is this hit piercing or normal?
|
||||
*/
|
||||
/atom/proc/bullet_act(obj/item/projectile/P, def_zone, piercing_hit = FALSE)
|
||||
SEND_SIGNAL(src, COMSIG_ATOM_BULLET_ACT, P, def_zone)
|
||||
. = P.on_hit(src, 0, def_zone)
|
||||
. = P.on_hit(src, 0, def_zone, piercing_hit)
|
||||
|
||||
//used on altdisarm() for special interactions between the shoved victim (target) and the src, with user being the one shoving the target on it.
|
||||
// IMPORTANT: if you wish to add a new own shove_act() to a certain object, remember to add SHOVABLE_ONTO to its obj_flags bitfied var first.
|
||||
@@ -860,10 +888,11 @@
|
||||
var/datum/progressbar/progress = new(user, things.len, src)
|
||||
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
||||
if(STR == src_object)
|
||||
progress.end_progress()
|
||||
return
|
||||
while (do_after(user, 10, TRUE, src, FALSE, CALLBACK(STR, /datum/component/storage.proc/handle_mass_item_insertion, things, src_object, user, progress)))
|
||||
stoplag(1)
|
||||
qdel(progress)
|
||||
progress.end_progress()
|
||||
to_chat(user, "<span class='notice'>You dump as much of [src_object.parent]'s contents into [STR.insert_preposition]to [src] as you can.</span>")
|
||||
if(user.active_storage) //refresh the HUD to show the transfered contents
|
||||
user.active_storage.ui_show(user)
|
||||
@@ -896,9 +925,6 @@
|
||||
SEND_SIGNAL(src, COMSIG_ATOM_DIR_CHANGE, dir, newdir)
|
||||
dir = newdir
|
||||
|
||||
/atom/proc/mech_melee_attack(obj/mecha/M)
|
||||
return
|
||||
|
||||
//If a mob logouts/logins in side of an object you can use this proc
|
||||
/atom/proc/on_log(login)
|
||||
if(loc)
|
||||
@@ -1162,6 +1188,8 @@
|
||||
log_game(log_text)
|
||||
if(LOG_GAME)
|
||||
log_game(log_text)
|
||||
if(LOG_MECHA)
|
||||
log_mecha(log_text)
|
||||
if(LOG_SHUTTLE)
|
||||
log_shuttle(log_text)
|
||||
else
|
||||
|
||||
@@ -25,7 +25,10 @@
|
||||
var/inertia_moving = 0
|
||||
var/inertia_next_move = 0
|
||||
var/inertia_move_delay = 5
|
||||
var/pass_flags = 0
|
||||
/// Things we can pass through while moving. If any of this matches the thing we're trying to pass's [pass_flags_self], then we can pass through.
|
||||
var/pass_flags = NONE
|
||||
/// If false makes CanPass call CanPassThrough on this type instead of using default behaviour
|
||||
var/generic_canpass = TRUE
|
||||
var/moving_diagonally = 0 //0: not doing a diagonal move. 1 and 2: doing the first/second step of the diagonal move
|
||||
var/atom/movable/moving_from_pull //attempt to resume grab after moving instead of before.
|
||||
var/list/acted_explosions //for explosion dodging
|
||||
@@ -473,10 +476,15 @@
|
||||
/atom/movable/proc/move_crushed(atom/movable/pusher, force = MOVE_FORCE_DEFAULT, direction)
|
||||
return FALSE
|
||||
|
||||
/atom/movable/CanPass(atom/movable/mover, turf/target)
|
||||
/atom/movable/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
if(mover in buckled_mobs)
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/// Returns true or false to allow src to move through the blocker, mover has final say
|
||||
/atom/movable/proc/CanPassThrough(atom/blocker, turf/target, blocker_opinion)
|
||||
SHOULD_CALL_PARENT(TRUE)
|
||||
return blocker_opinion
|
||||
|
||||
/// called when this atom is removed from a storage item, which is passed on as S. The loc variable is already set to the new destination before this is called.
|
||||
/atom/movable/proc/on_exit_storage(datum/component/storage/concrete/S) // rename S to master_storage
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
desc = "advanced clown shoes that protect the wearer and render them nearly immune to slipping on their own peels. They also squeak at 100% capacity."
|
||||
clothing_flags = NOSLIP
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
armor = list("melee" = 25, "bullet" = 25, "laser" = 25, "energy" = 25, "bomb" = 50, "bio" = 10, "rad" = 0, "fire" = 70, "acid" = 50)
|
||||
armor = list(MELEE = 25, BULLET = 25, LASER = 25, ENERGY = 25, BOMB = 50, BIO = 10, RAD = 0, FIRE = 70, ACID = 50)
|
||||
strip_delay = 70
|
||||
resistance_flags = NONE
|
||||
permeability_coefficient = 0.05
|
||||
@@ -28,7 +28,7 @@
|
||||
name = "mk-honk combat shoes"
|
||||
desc = "The culmination of years of clown combat research, these shoes leave a trail of chaos in their wake. They will slowly recharge themselves over time, or can be manually charged with bananium."
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
armor = list("melee" = 25, "bullet" = 25, "laser" = 25, "energy" = 25, "bomb" = 50, "bio" = 10, "rad" = 0, "fire" = 70, "acid" = 50)
|
||||
armor = list(MELEE = 25, BULLET = 25, LASER = 25, ENERGY = 25, BOMB = 50, BIO = 10, RAD = 0, FIRE = 70, ACID = 50)
|
||||
strip_delay = 70
|
||||
resistance_flags = NONE
|
||||
permeability_coefficient = 0.05
|
||||
@@ -37,7 +37,7 @@
|
||||
var/max_recharge = 3000 //30 peels worth
|
||||
var/recharge_rate = 34 //about 1/3 of a peel per tick
|
||||
|
||||
/obj/item/clothing/shoes/clown_shoes/banana_shoes/combat/Initialize()
|
||||
/obj/item/clothing/shoes/clown_shoes/banana_shoes/combat/Initialize(mapload)
|
||||
. = ..()
|
||||
var/datum/component/material_container/bananium = GetComponent(/datum/component/material_container)
|
||||
bananium.insert_amount_mat(max_recharge, /datum/material/bananium)
|
||||
@@ -69,7 +69,7 @@
|
||||
var/next_trombone_allowed = 0
|
||||
var/datum/component/slippery/slipper
|
||||
|
||||
/obj/item/melee/transforming/energy/sword/bananium/Initialize()
|
||||
/obj/item/melee/transforming/energy/sword/bananium/Initialize(mapload)
|
||||
. = ..()
|
||||
slipper = LoadComponent(/datum/component/slippery, 81, GALOSHES_DONT_HELP)
|
||||
slipper.signal_enabled = active
|
||||
@@ -128,7 +128,7 @@
|
||||
on_throw_speed = 1
|
||||
var/datum/component/slippery/slipper
|
||||
|
||||
/obj/item/shield/energy/bananium/Initialize()
|
||||
/obj/item/shield/energy/bananium/Initialize(mapload)
|
||||
. = ..()
|
||||
slipper = LoadComponent(/datum/component/slippery, 81, GALOSHES_DONT_HELP)
|
||||
slipper.signal_enabled = active
|
||||
@@ -173,7 +173,7 @@
|
||||
var/det_time = 50
|
||||
var/obj/item/grenade/syndieminibomb/bomb
|
||||
|
||||
/obj/item/grown/bananapeel/bombanana/Initialize()
|
||||
/obj/item/grown/bananapeel/bombanana/Initialize(mapload)
|
||||
. = ..()
|
||||
AddComponent(/datum/component/slippery, det_time)
|
||||
bomb = new /obj/item/grenade/syndieminibomb(src)
|
||||
@@ -219,7 +219,7 @@
|
||||
/obj/item/clothing/mask/fakemoustache/sticky
|
||||
var/unstick_time = 2 MINUTES
|
||||
|
||||
/obj/item/clothing/mask/fakemoustache/sticky/Initialize()
|
||||
/obj/item/clothing/mask/fakemoustache/sticky/Initialize(mapload)
|
||||
. = ..()
|
||||
ADD_TRAIT(src, TRAIT_NODROP, STICKY_MOUSTACHE_TRAIT)
|
||||
addtimer(TRAIT_CALLBACK_REMOVE(src, TRAIT_NODROP, STICKY_MOUSTACHE_TRAIT), unstick_time)
|
||||
@@ -243,7 +243,7 @@
|
||||
projectiles = 8
|
||||
projectile_energy_cost = 1000
|
||||
|
||||
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/banana_mortar/bombanana/can_attach(obj/mecha/combat/honker/M)
|
||||
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/banana_mortar/bombanana/can_attach(obj/vehicle/sealed/mecha/combat/honker/M)
|
||||
if(..())
|
||||
if(istype(M))
|
||||
return TRUE
|
||||
@@ -261,42 +261,33 @@
|
||||
equip_cooldown = 60
|
||||
det_time = 20
|
||||
|
||||
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/flashbang/tearstache/can_attach(obj/mecha/combat/honker/M)
|
||||
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/flashbang/tearstache/can_attach(obj/vehicle/sealed/mecha/combat/honker/M)
|
||||
if(..())
|
||||
if(istype(M))
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/obj/mecha/combat/honker/dark
|
||||
/obj/vehicle/sealed/mecha/combat/honker/dark
|
||||
desc = "Produced by \"Tyranny of Honk, INC\", this exosuit is designed as heavy clown-support. This one has been painted black for maximum fun. HONK!"
|
||||
name = "\improper Dark H.O.N.K"
|
||||
icon_state = "darkhonker"
|
||||
max_integrity = 300
|
||||
deflect_chance = 15
|
||||
armor = list("melee" = 40, "bullet" = 40, "laser" = 50, "energy" = 35, "bomb" = 20, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 100)
|
||||
armor = list(MELEE = 40, BULLET = 40, LASER = 50, ENERGY = 35, BOMB = 20, BIO = 0, RAD = 0, FIRE = 100, ACID = 100)
|
||||
max_temperature = 35000
|
||||
operation_req_access = list(ACCESS_SYNDICATE)
|
||||
internals_req_access = list(ACCESS_SYNDICATE)
|
||||
wreckage = /obj/structure/mecha_wreckage/honker/dark
|
||||
max_equip = 3
|
||||
|
||||
/obj/mecha/combat/honker/dark/GrantActions(mob/living/user, human_occupant = 0)
|
||||
..()
|
||||
thrusters_action.Grant(user, src)
|
||||
|
||||
|
||||
/obj/mecha/combat/honker/dark/RemoveActions(mob/living/user, human_occupant = 0)
|
||||
..()
|
||||
thrusters_action.Remove(user)
|
||||
|
||||
/obj/mecha/combat/honker/dark/add_cell(obj/item/stock_parts/cell/C)
|
||||
/obj/vehicle/sealed/mecha/combat/honker/dark/add_cell(obj/item/stock_parts/cell/C)
|
||||
if(C)
|
||||
C.forceMove(src)
|
||||
cell = C
|
||||
return
|
||||
cell = new /obj/item/stock_parts/cell/hyper(src)
|
||||
|
||||
/obj/mecha/combat/honker/dark/loaded/Initialize()
|
||||
/obj/vehicle/sealed/mecha/combat/honker/dark/loaded/Initialize(mapload)
|
||||
. = ..()
|
||||
var/obj/item/mecha_parts/mecha_equipment/ME = new /obj/item/mecha_parts/mecha_equipment/weapon/honker()
|
||||
ME.attach(src)
|
||||
|
||||
@@ -281,7 +281,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event
|
||||
var/meteorgibs = /obj/effect/gibspawner/generic
|
||||
threat = 2
|
||||
|
||||
/obj/effect/meteor/meaty/Initialize()
|
||||
/obj/effect/meteor/meaty/Initialize(mapload)
|
||||
for(var/path in meteordrop)
|
||||
if(path == /obj/item/reagent_containers/food/snacks/meat/slab/human/mutant)
|
||||
meteordrop -= path
|
||||
@@ -312,7 +312,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event
|
||||
meteordrop = list(/obj/item/reagent_containers/food/snacks/meat/slab/xeno, /obj/item/organ/tongue/alien)
|
||||
meteorgibs = /obj/effect/gibspawner/xeno
|
||||
|
||||
/obj/effect/meteor/meaty/xeno/Initialize()
|
||||
/obj/effect/meteor/meaty/xeno/Initialize(mapload)
|
||||
meteordrop += subtypesof(/obj/item/organ/alien)
|
||||
return ..()
|
||||
|
||||
@@ -363,7 +363,7 @@ GLOBAL_LIST_INIT(meteorsSPOOKY, list(/obj/effect/meteor/pumpkin))
|
||||
meteordrop = list(/obj/item/clothing/head/hardhat/pumpkinhead, /obj/item/reagent_containers/food/snacks/grown/pumpkin)
|
||||
threat = 100
|
||||
|
||||
/obj/effect/meteor/pumpkin/Initialize()
|
||||
/obj/effect/meteor/pumpkin/Initialize(mapload)
|
||||
. = ..()
|
||||
meteorsound = pick('sound/hallucinations/im_here1.ogg','sound/hallucinations/im_here2.ogg')
|
||||
//////////////////////////
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
idle_power_usage = 0
|
||||
var/obj/item/beacon/Beacon
|
||||
|
||||
/obj/machinery/bluespace_beacon/Initialize()
|
||||
/obj/machinery/bluespace_beacon/Initialize(mapload)
|
||||
. = ..()
|
||||
var/turf/T = loc
|
||||
Beacon = new(T)
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
if(storedpda)
|
||||
. += "[initial(icon_state)]-closed"
|
||||
|
||||
/obj/machinery/pdapainter/Initialize()
|
||||
/obj/machinery/pdapainter/Initialize(mapload)
|
||||
. = ..()
|
||||
var/list/blocked = list(
|
||||
/obj/item/pda/ai/pai,
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
payment_department = ACCOUNT_MED
|
||||
fair_market_price = 5
|
||||
|
||||
/obj/machinery/sleeper/Initialize()
|
||||
/obj/machinery/sleeper/Initialize(mapload)
|
||||
. = ..()
|
||||
// if(mapload)
|
||||
// component_parts -= circuit
|
||||
@@ -278,7 +278,7 @@
|
||||
icon_state = "sleeper_s"
|
||||
controls_inside = TRUE
|
||||
|
||||
/obj/machinery/sleeper/syndie/Initialize()
|
||||
/obj/machinery/sleeper/syndie/Initialize(mapload)
|
||||
. = ..()
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/circuitboard/machine/sleeper/syndie(null)
|
||||
@@ -289,7 +289,7 @@
|
||||
component_parts += new /obj/item/stack/cable_coil(null)
|
||||
RefreshParts()
|
||||
|
||||
/obj/machinery/sleeper/syndie/fullupgrade/Initialize()
|
||||
/obj/machinery/sleeper/syndie/fullupgrade/Initialize(mapload)
|
||||
. = ..()
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/circuitboard/machine/sleeper/syndie(null)
|
||||
|
||||
@@ -90,6 +90,7 @@ Class Procs:
|
||||
verb_say = "beeps"
|
||||
verb_yell = "blares"
|
||||
pressure_resistance = 15
|
||||
pass_flags_self = PASSMACHINE
|
||||
max_integrity = 200
|
||||
layer = BELOW_OBJ_LAYER //keeps shit coming out of the machine from ending up underneath it.
|
||||
flags_1 = DEFAULT_RICOCHET_1
|
||||
@@ -134,9 +135,9 @@ Class Procs:
|
||||
var/market_verb = "Customer"
|
||||
var/payment_department = ACCOUNT_ENG
|
||||
|
||||
/obj/machinery/Initialize()
|
||||
/obj/machinery/Initialize(mapload)
|
||||
if(!armor)
|
||||
armor = list("melee" = 25, "bullet" = 10, "laser" = 10, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 70)
|
||||
armor = list(MELEE = 25, BULLET = 10, LASER = 10, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 50, ACID = 70)
|
||||
. = ..()
|
||||
GLOB.machines += src
|
||||
|
||||
@@ -370,7 +371,7 @@ Class Procs:
|
||||
user.DelayNextAction(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src, ATTACK_EFFECT_PUNCH)
|
||||
user.visible_message("<span class='danger'>[user.name] smashes against \the [src.name] with its paws.</span>", null, null, COMBAT_MESSAGE_RANGE)
|
||||
take_damage(4, BRUTE, "melee", 1)
|
||||
take_damage(4, BRUTE, MELEE, 1)
|
||||
|
||||
/obj/machinery/attack_robot(mob/user)
|
||||
if(!(interaction_flags_machine & INTERACT_MACHINE_ALLOW_SILICON) && !IsAdminGhost(user))
|
||||
@@ -448,6 +449,12 @@ Class Procs:
|
||||
update_icon()
|
||||
updateUsrDialog()
|
||||
|
||||
/obj/machinery/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
|
||||
if(mover.pass_flags & PASSMACHINE)
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/proc/default_deconstruction_screwdriver(mob/user, icon_state_open, icon_state_closed, obj/item/I)
|
||||
if(!(flags_1 & NODECONSTRUCT_1) && I.tool_behaviour == TOOL_SCREWDRIVER)
|
||||
I.play_tool_sound(src, 50)
|
||||
@@ -590,7 +597,7 @@ Class Procs:
|
||||
if(prob(85) && (zap_flags & ZAP_MACHINE_EXPLOSIVE))
|
||||
explosion(src, 1, 2, 4, flame_range = 2, adminlog = FALSE, smoke = FALSE)
|
||||
else if(zap_flags & ZAP_OBJ_DAMAGE)
|
||||
take_damage(power/2000, BURN, "energy")
|
||||
take_damage(power/2000, BURN, ENERGY)
|
||||
if(prob(40))
|
||||
emp_act(50)
|
||||
|
||||
@@ -614,7 +621,7 @@ Class Procs:
|
||||
AM.pixel_y = -8 + (round( . / 3)*8)
|
||||
|
||||
/obj/machinery/rust_heretic_act()
|
||||
take_damage(500, BRUTE, "melee", 1)
|
||||
take_damage(500, BRUTE, MELEE, 1)
|
||||
|
||||
/**
|
||||
* Alerts the AI that a hack is in progress.
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
layer = PROJECTILE_HIT_THRESHHOLD_LAYER
|
||||
plane = FLOOR_PLANE
|
||||
max_integrity = 200
|
||||
armor = list("melee" = 50, "bullet" = 20, "laser" = 20, "energy" = 20, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 30)
|
||||
armor = list(MELEE = 50, BULLET = 20, LASER = 20, ENERGY = 20, BOMB = 0, BIO = 0, RAD = 0, FIRE = 50, ACID = 30)
|
||||
|
||||
var/uses = 20
|
||||
var/cooldown = 0
|
||||
|
||||
@@ -152,7 +152,7 @@
|
||||
frequency = new_frequency
|
||||
radio_connection = SSradio.add_object(src, frequency, RADIO_AIRLOCK)
|
||||
|
||||
/obj/machinery/airlock_sensor/Initialize()
|
||||
/obj/machinery/airlock_sensor/Initialize(mapload)
|
||||
. = ..()
|
||||
set_frequency(frequency)
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ GLOBAL_LIST_EMPTY(announcement_systems)
|
||||
var/pinklight = "Light_Pink"
|
||||
var/errorlight = "Error_Red"
|
||||
|
||||
/obj/machinery/announcement_system/Initialize()
|
||||
/obj/machinery/announcement_system/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.announcement_systems += src
|
||||
radio = new /obj/item/radio/headset/silicon/ai(src)
|
||||
|
||||
@@ -8,14 +8,14 @@
|
||||
max_integrity = 200
|
||||
var/obj/item/bodypart/storedpart
|
||||
var/initial_icon_state
|
||||
var/static/list/style_list_icons = list("standard" = 'icons/mob/augmentation/augments.dmi',
|
||||
"engineer" = 'icons/mob/augmentation/augments_engineer.dmi',
|
||||
"security" = 'icons/mob/augmentation/augments_security.dmi',
|
||||
"mining" = 'icons/mob/augmentation/augments_mining.dmi',
|
||||
"Talon" = 'icons/mob/augmentation/cosmetic_prosthetic/talon.dmi',
|
||||
"Nanotrasen" = 'icons/mob/augmentation/cosmetic_prosthetic/nanotrasen.dmi',
|
||||
"Hephaesthus" = 'icons/mob/augmentation/cosmetic_prosthetic/hephaestus.dmi',
|
||||
"Bishop" = 'icons/mob/augmentation/cosmetic_prosthetic/bishop.dmi',
|
||||
var/static/list/style_list_icons = list("standard" = 'icons/mob/augmentation/augments.dmi',
|
||||
"engineer" = 'icons/mob/augmentation/augments_engineer.dmi',
|
||||
"security" = 'icons/mob/augmentation/augments_security.dmi',
|
||||
"mining" = 'icons/mob/augmentation/augments_mining.dmi',
|
||||
"Talon" = 'icons/mob/augmentation/cosmetic_prosthetic/talon.dmi',
|
||||
"Nanotrasen" = 'icons/mob/augmentation/cosmetic_prosthetic/nanotrasen.dmi',
|
||||
"Hephaesthus" = 'icons/mob/augmentation/cosmetic_prosthetic/hephaestus.dmi',
|
||||
"Bishop" = 'icons/mob/augmentation/cosmetic_prosthetic/bishop.dmi',
|
||||
"Xion" = 'icons/mob/augmentation/cosmetic_prosthetic/xion.dmi',
|
||||
"Grayson" = 'icons/mob/augmentation/cosmetic_prosthetic/grayson.dmi',
|
||||
"Cybersolutions" = 'icons/mob/augmentation/cosmetic_prosthetic/cybersolutions.dmi',
|
||||
@@ -27,7 +27,7 @@
|
||||
if(storedpart)
|
||||
. += "<span class='notice'>Alt-click to eject the limb.</span>"
|
||||
|
||||
/obj/machinery/aug_manipulator/Initialize()
|
||||
/obj/machinery/aug_manipulator/Initialize(mapload)
|
||||
initial_icon_state = initial(icon_state)
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
"Imported"
|
||||
)
|
||||
|
||||
/obj/machinery/autolathe/Initialize()
|
||||
/obj/machinery/autolathe/Initialize(mapload)
|
||||
. = ..()
|
||||
wires = new /datum/wires/autolathe(src)
|
||||
stored_research = new /datum/techweb/specialized/autounlocking/autolathe
|
||||
@@ -429,7 +429,7 @@
|
||||
desc = "It produces items using metal and glass. This model was reprogrammed without some of the more hazardous designs."
|
||||
circuit = /obj/item/circuitboard/machine/autolathe/secure
|
||||
|
||||
/obj/machinery/autolathe/secure/Initialize()
|
||||
/obj/machinery/autolathe/secure/Initialize(mapload)
|
||||
. = ..()
|
||||
// let's not leave the parent datum floating, right?
|
||||
if(stored_research)
|
||||
@@ -452,14 +452,14 @@
|
||||
"Misc",
|
||||
"Imported"
|
||||
)
|
||||
/obj/machinery/autolathe/toy/Initialize()
|
||||
/obj/machinery/autolathe/toy/Initialize(mapload)
|
||||
. = ..()
|
||||
// let's not leave the parent datum floating, right?
|
||||
if(stored_research)
|
||||
QDEL_NULL(stored_research)
|
||||
stored_research = new /datum/techweb/specialized/autounlocking/autolathe/toy
|
||||
|
||||
/obj/machinery/autolathe/toy/hacked/Initialize()
|
||||
/obj/machinery/autolathe/toy/hacked/Initialize(mapload)
|
||||
. = ..()
|
||||
adjust_hacked(TRUE)
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
var/minimum_time_between_warnings = 400
|
||||
var/syphoning_credits = 0
|
||||
|
||||
/obj/machinery/computer/bank_machine/Initialize()
|
||||
/obj/machinery/computer/bank_machine/Initialize(mapload)
|
||||
. = ..()
|
||||
radio = new(src)
|
||||
radio.subspace_transmission = TRUE
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
var/efficiency = 0
|
||||
var/productivity = 0
|
||||
|
||||
/obj/machinery/bloodbankgen/Initialize()
|
||||
/obj/machinery/bloodbankgen/Initialize(mapload)
|
||||
. = ..()
|
||||
create_reagents(maxbloodstored, AMOUNT_VISIBLE)
|
||||
update_icon()
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
var/device_type = null
|
||||
var/id = null
|
||||
var/initialized_button = 0
|
||||
armor = list("melee" = 50, "bullet" = 50, "laser" = 50, "energy" = 50, "bomb" = 10, "bio" = 100, "rad" = 100, "fire" = 90, "acid" = 70)
|
||||
armor = list(MELEE = 50, BULLET = 50, LASER = 50, ENERGY = 50, BOMB = 10, BIO = 100, RAD = 100, FIRE = 90, ACID = 70)
|
||||
use_power = IDLE_POWER_USE
|
||||
idle_power_usage = 2
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
resistance_flags = FIRE_PROOF
|
||||
|
||||
armor = list("melee" = 50, "bullet" = 20, "laser" = 20, "energy" = 20, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 90, "acid" = 50)
|
||||
armor = list(MELEE = 50, BULLET = 20, LASER = 20, ENERGY = 20, BOMB = 0, BIO = 0, RAD = 0, FIRE = 90, ACID = 50)
|
||||
max_integrity = 100
|
||||
integrity_failure = 0.5
|
||||
var/list/network = list("ss13")
|
||||
@@ -273,7 +273,7 @@
|
||||
return ..()
|
||||
|
||||
/obj/machinery/camera/run_obj_armor(damage_amount, damage_type, damage_flag = 0, attack_dir)
|
||||
if(damage_flag == "melee" && damage_amount < 12 && !(stat & BROKEN))
|
||||
if(damage_flag == MELEE && damage_amount < 12 && !(stat & BROKEN))
|
||||
return 0
|
||||
. = ..()
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
c_tag = "Arena"
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF | FREEZE_PROOF
|
||||
|
||||
/obj/machinery/camera/motion/thunderdome/Initialize()
|
||||
/obj/machinery/camera/motion/thunderdome/Initialize(mapload)
|
||||
. = ..()
|
||||
proximity_monitor.SetRange(7)
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
/obj/machinery/camera/emp_proof
|
||||
start_active = TRUE
|
||||
|
||||
/obj/machinery/camera/emp_proof/Initialize()
|
||||
/obj/machinery/camera/emp_proof/Initialize(mapload)
|
||||
. = ..()
|
||||
upgradeEmpProof()
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
start_active = TRUE
|
||||
icon_state = "xraycam" // Thanks to Krutchen for the icons.
|
||||
|
||||
/obj/machinery/camera/xray/Initialize()
|
||||
/obj/machinery/camera/xray/Initialize(mapload)
|
||||
. = ..()
|
||||
upgradeXRay()
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
start_active = TRUE
|
||||
name = "motion-sensitive security camera"
|
||||
|
||||
/obj/machinery/camera/motion/Initialize()
|
||||
/obj/machinery/camera/motion/Initialize(mapload)
|
||||
. = ..()
|
||||
upgradeMotion()
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
/obj/machinery/camera/all
|
||||
start_active = TRUE
|
||||
|
||||
/obj/machinery/camera/all/Initialize()
|
||||
/obj/machinery/camera/all/Initialize(mapload)
|
||||
. = ..()
|
||||
upgradeEmpProof()
|
||||
upgradeXRay()
|
||||
@@ -43,7 +43,7 @@
|
||||
var/number = 0 //camera number in area
|
||||
|
||||
//This camera type automatically sets it's name to whatever the area that it's in is called.
|
||||
/obj/machinery/camera/autoname/Initialize()
|
||||
/obj/machinery/camera/autoname/Initialize(mapload)
|
||||
..()
|
||||
return INITIALIZE_HINT_LATELOAD
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
fair_market_price = 5 // He nodded, because he knew I was right. Then he swiped his credit card to pay me for arresting him.
|
||||
payment_department = ACCOUNT_MED
|
||||
|
||||
/obj/machinery/clonepod/Initialize()
|
||||
/obj/machinery/clonepod/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
countdown = new(src)
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
var/datum/techweb/linked_techweb
|
||||
light_color = LIGHT_COLOR_BLUE
|
||||
|
||||
/obj/machinery/computer/operating/Initialize()
|
||||
/obj/machinery/computer/operating/Initialize(mapload)
|
||||
. = ..()
|
||||
linked_techweb = SSresearch.science_tech
|
||||
find_table()
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
active_power_usage = 300
|
||||
max_integrity = 200
|
||||
integrity_failure = 0.5
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 40, "acid" = 20)
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 40, ACID = 20)
|
||||
var/brightness_on = 1
|
||||
var/icon_keyboard = "generic_key"
|
||||
var/icon_screen = "generic"
|
||||
@@ -101,10 +101,10 @@
|
||||
switch(severity)
|
||||
if(1)
|
||||
if(prob(50))
|
||||
obj_break("energy")
|
||||
obj_break(ENERGY)
|
||||
if(2)
|
||||
if(prob(10))
|
||||
obj_break("energy")
|
||||
obj_break(ENERGY)
|
||||
|
||||
/obj/machinery/computer/deconstruct(disassembled = TRUE, mob/user)
|
||||
on_deconstruction()
|
||||
|
||||
@@ -77,7 +77,7 @@ GLOBAL_LIST_INIT(arcade_prize_pool, list(
|
||||
/obj/machinery/computer/arcade/proc/Reset()
|
||||
return
|
||||
|
||||
/obj/machinery/computer/arcade/Initialize()
|
||||
/obj/machinery/computer/arcade/Initialize(mapload)
|
||||
. = ..()
|
||||
// If it's a generic arcade machine, pick a random arcade
|
||||
// circuit board for it and make the new machine
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
var/killed_crew = 0
|
||||
|
||||
|
||||
/obj/machinery/computer/arcade/orion_trail/Initialize()
|
||||
/obj/machinery/computer/arcade/orion_trail/Initialize(mapload)
|
||||
. = ..()
|
||||
Radio = new /obj/item/radio(src)
|
||||
Radio.listening = 0
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
|
||||
light_color = LIGHT_COLOR_CYAN
|
||||
|
||||
/obj/machinery/computer/atmos_alert/Initialize()
|
||||
/obj/machinery/computer/atmos_alert/Initialize(mapload)
|
||||
. = ..()
|
||||
set_frequency(receive_frequency)
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
name = "gas sensor"
|
||||
icon = 'icons/obj/stationobjs.dmi'
|
||||
icon_state = "gsensor1"
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 0)
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 100, ACID = 0)
|
||||
|
||||
var/on = TRUE
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
frequency = new_frequency
|
||||
radio_connection = SSradio.add_object(src, frequency, RADIO_ATMOSIA)
|
||||
|
||||
/obj/machinery/air_sensor/Initialize()
|
||||
/obj/machinery/air_sensor/Initialize(mapload)
|
||||
. = ..()
|
||||
SSair.atmos_air_machinery += src
|
||||
set_frequency(frequency)
|
||||
@@ -126,7 +126,7 @@ GLOBAL_LIST_EMPTY(atmos_air_controllers)
|
||||
var/datum/radio_frequency/radio_connection
|
||||
|
||||
|
||||
/obj/machinery/computer/atmos_control/Initialize()
|
||||
/obj/machinery/computer/atmos_control/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.atmos_air_controllers += src
|
||||
set_frequency(frequency)
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
interaction_flags_machine = INTERACT_MACHINE_ALLOW_SILICON | INTERACT_MACHINE_SET_MACHINE //| INTERACT_MACHINE_REQUIRES_SIGHT
|
||||
|
||||
/obj/machinery/computer/security/Initialize()
|
||||
/obj/machinery/computer/security/Initialize(mapload)
|
||||
. = ..()
|
||||
// Map name has to start and end with an A-Z character,
|
||||
// and definitely NOT with a square bracket or even a number.
|
||||
@@ -275,7 +275,7 @@
|
||||
var/icon_state_off = "entertainment_blank"
|
||||
var/icon_state_on = "entertainment"
|
||||
|
||||
/obj/machinery/computer/security/telescreen/entertainment/Initialize()
|
||||
/obj/machinery/computer/security/telescreen/entertainment/Initialize(mapload)
|
||||
. = ..()
|
||||
RegisterSignal(src, COMSIG_CLICK, .proc/BigClick)
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
light_color = LIGHT_COLOR_RED
|
||||
|
||||
/obj/machinery/computer/camera_advanced/Initialize()
|
||||
/obj/machinery/computer/camera_advanced/Initialize(mapload)
|
||||
. = ..()
|
||||
for(var/i in networks)
|
||||
networks -= i
|
||||
|
||||
@@ -56,7 +56,7 @@ GLOBAL_VAR_INIT(time_last_changed_position, 0)
|
||||
/obj/machinery/computer/card/centcom/get_jobs()
|
||||
return get_all_centcom_jobs()
|
||||
|
||||
/obj/machinery/computer/card/Initialize()
|
||||
/obj/machinery/computer/card/Initialize(mapload)
|
||||
. = ..()
|
||||
change_position_cooldown = CONFIG_GET(number/id_console_jobslot_delay)
|
||||
|
||||
@@ -586,7 +586,7 @@ GLOBAL_VAR_INIT(time_last_changed_position, 0)
|
||||
icon_screen = "idminor"
|
||||
circuit = /obj/item/circuitboard/computer/card/minor
|
||||
|
||||
/obj/machinery/computer/card/minor/Initialize()
|
||||
/obj/machinery/computer/card/minor/Initialize(mapload)
|
||||
. = ..()
|
||||
var/obj/item/circuitboard/computer/card/minor/typed_circuit = circuit
|
||||
if(target_dept)
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
light_color = LIGHT_COLOR_BLUE
|
||||
|
||||
/obj/machinery/computer/cloning/Initialize()
|
||||
/obj/machinery/computer/cloning/Initialize(mapload)
|
||||
. = ..()
|
||||
updatemodules(TRUE)
|
||||
var/obj/item/circuitboard/computer/cloning/board = circuit
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
/// The last lines used for changing the status display
|
||||
var/static/last_status_display
|
||||
|
||||
/obj/machinery/computer/communications/Initialize()
|
||||
/obj/machinery/computer/communications/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.shuttle_caller_list += src
|
||||
AddComponent(/datum/component/gps, "Secured Communications Signal")
|
||||
@@ -89,6 +89,7 @@
|
||||
/obj/machinery/computer/communications/ui_act(action, list/params)
|
||||
var/static/list/approved_states = list(STATE_BUYING_SHUTTLE, STATE_CHANGING_STATUS, STATE_MAIN, STATE_MESSAGES)
|
||||
var/static/list/approved_status_pictures = list("biohazard", "blank", "default", "lockdown", "redalert", "shuttle")
|
||||
var/static/list/state_status_pictures = list("blank", "shuttle")
|
||||
|
||||
. = ..()
|
||||
if (.)
|
||||
@@ -307,7 +308,10 @@
|
||||
var/picture = params["picture"]
|
||||
if (!(picture in approved_status_pictures))
|
||||
return
|
||||
post_status("alert", picture)
|
||||
if(picture in state_status_pictures)
|
||||
post_status(picture)
|
||||
else
|
||||
post_status("alert", picture)
|
||||
playsound(src, "terminal_type", 50, FALSE)
|
||||
if ("toggleAuthentication")
|
||||
// Log out if we're logged in
|
||||
|
||||
@@ -199,7 +199,7 @@
|
||||
|
||||
eject_disk(user)
|
||||
|
||||
/obj/machinery/computer/scan_consolenew/Initialize()
|
||||
/obj/machinery/computer/scan_consolenew/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
// Connect with a nearby DNA Scanner on init
|
||||
@@ -263,7 +263,7 @@
|
||||
if(!ui)
|
||||
ui = new(user, src, "DnaConsole")
|
||||
ui.open()
|
||||
|
||||
|
||||
/obj/machinery/computer/scan_consolenew/ui_assets()
|
||||
. = ..() || list()
|
||||
. += get_asset_datum(/datum/asset/simple/genetics)
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
var/list/obj/machinery/launchpad/launchpads
|
||||
var/maximum_pads = 4
|
||||
|
||||
/obj/machinery/computer/launchpad/Initialize()
|
||||
/obj/machinery/computer/launchpad/Initialize(mapload)
|
||||
launchpads = list()
|
||||
. = ..()
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
/// Countdown timer for the mass driver's delayed launch functionality.
|
||||
COOLDOWN_DECLARE(massdriver_countdown)
|
||||
|
||||
/obj/machinery/computer/pod/Initialize()
|
||||
/obj/machinery/computer/pod/Initialize(mapload)
|
||||
. = ..()
|
||||
for(var/obj/machinery/mass_driver/M in range(range, src))
|
||||
if(M.id == id)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
light_color = LIGHT_COLOR_RED
|
||||
|
||||
/obj/machinery/computer/prisoner/gulag_teleporter_computer/Initialize()
|
||||
/obj/machinery/computer/prisoner/gulag_teleporter_computer/Initialize(mapload)
|
||||
. = ..()
|
||||
scan_machinery()
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
|
||||
light_color = LIGHT_COLOR_CYAN
|
||||
|
||||
/obj/machinery/computer/station_alert/Initialize()
|
||||
/obj/machinery/computer/station_alert/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.alert_consoles += src
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ GLOBAL_LIST_INIT(possible_uplinker_IDs, list("Alfa","Bravo","Charlie","Delta","E
|
||||
var/obj/item/uplinkholder = null
|
||||
var/obj/machinery/computer/telecrystals/boss/linkedboss = null
|
||||
|
||||
/obj/machinery/computer/telecrystals/uplinker/Initialize()
|
||||
/obj/machinery/computer/telecrystals/uplinker/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
var/ID = pick_n_take(GLOB.possible_uplinker_IDs)
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
var/turf/target
|
||||
var/obj/item/implant/imp_t
|
||||
|
||||
/obj/machinery/computer/teleporter/Initialize()
|
||||
/obj/machinery/computer/teleporter/Initialize(mapload)
|
||||
. = ..()
|
||||
id = "[rand(1000, 9999)]"
|
||||
link_power_station()
|
||||
|
||||
@@ -38,7 +38,7 @@ GLOBAL_LIST_EMPTY(cryopod_computers)
|
||||
var/obj/O = i
|
||||
O.forceMove(drop_location())
|
||||
|
||||
/obj/machinery/computer/cryopod/Initialize()
|
||||
/obj/machinery/computer/cryopod/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.cryopod_computers += src
|
||||
|
||||
@@ -144,7 +144,7 @@ GLOBAL_LIST_EMPTY(cryopod_computers)
|
||||
var/datum/weakref/control_computer_weakref
|
||||
COOLDOWN_DECLARE(last_no_computer_message)
|
||||
|
||||
/obj/machinery/cryopod/Initialize()
|
||||
/obj/machinery/cryopod/Initialize(mapload)
|
||||
..()
|
||||
return INITIALIZE_HINT_LATELOAD //Gotta populate the cryopod computer GLOB first
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
var/obj/item/defibrillator/defib //this mount's defibrillator
|
||||
var/clamps_locked = FALSE //if true, and a defib is loaded, it can't be removed without unlocking the clamps
|
||||
|
||||
/obj/machinery/defibrillator_mount/loaded/Initialize() //loaded subtype for mapping use
|
||||
/obj/machinery/defibrillator_mount/loaded/Initialize(mapload) //loaded subtype for mapping use
|
||||
. = ..()
|
||||
defib = new/obj/item/defibrillator/loaded(src)
|
||||
|
||||
|
||||
@@ -37,22 +37,19 @@
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/structure/barricade/CanPass(atom/movable/mover, turf/target)//So bullets will fly over and stuff.
|
||||
/obj/structure/barricade/CanAllowThrough(atom/movable/mover, turf/target)//So bullets will fly over and stuff.
|
||||
. = ..()
|
||||
if(locate(/obj/structure/barricade) in get_turf(mover))
|
||||
return 1
|
||||
return TRUE
|
||||
else if(istype(mover, /obj/item/projectile))
|
||||
if(!anchored)
|
||||
return 1
|
||||
return TRUE
|
||||
var/obj/item/projectile/proj = mover
|
||||
if(proj.firer && Adjacent(proj.firer))
|
||||
return 1
|
||||
return TRUE
|
||||
if(prob(proj_pass_rate))
|
||||
return 1
|
||||
return 0
|
||||
else
|
||||
return !density
|
||||
|
||||
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/////BARRICADE TYPES///////
|
||||
|
||||
@@ -79,7 +76,6 @@
|
||||
return
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/barricade/wooden/crude
|
||||
name = "crude plank barricade"
|
||||
desc = "This space is blocked off by a crude assortment of planks."
|
||||
@@ -96,7 +92,6 @@
|
||||
/obj/structure/barricade/wooden/make_debris()
|
||||
new /obj/item/stack/sheet/mineral/wood(get_turf(src), drop_amount)
|
||||
|
||||
|
||||
/obj/structure/barricade/sandbags
|
||||
name = "sandbags"
|
||||
desc = "Bags of sand. Self explanatory."
|
||||
@@ -104,13 +99,12 @@
|
||||
icon_state = "sandbags"
|
||||
max_integrity = 280
|
||||
proj_pass_rate = 20
|
||||
pass_flags = LETPASSTHROW
|
||||
pass_flags_self = LETPASSTHROW
|
||||
bar_material = SAND
|
||||
climbable = TRUE
|
||||
smooth = SMOOTH_TRUE
|
||||
canSmoothWith = list(/obj/structure/barricade/sandbags, /turf/closed/wall, /turf/closed/wall/r_wall, /obj/structure/falsewall, /obj/structure/falsewall/reinforced, /turf/closed/wall/rust, /turf/closed/wall/r_wall/rust, /obj/structure/barricade/security)
|
||||
|
||||
|
||||
/obj/structure/barricade/security
|
||||
name = "security barrier"
|
||||
desc = "A deployable barrier. Provides good cover in fire fights."
|
||||
@@ -120,13 +114,12 @@
|
||||
anchored = FALSE
|
||||
max_integrity = 180
|
||||
proj_pass_rate = 20
|
||||
armor = list("melee" = 10, "bullet" = 50, "laser" = 50, "energy" = 50, "bomb" = 10, "bio" = 100, "rad" = 100, "fire" = 10, "acid" = 0)
|
||||
armor = list(MELEE = 10, BULLET = 50, LASER = 50, ENERGY = 50, BOMB = 10, BIO = 100, RAD = 100, FIRE = 10, ACID = 0)
|
||||
|
||||
var/deploy_time = 40
|
||||
var/deploy_message = TRUE
|
||||
|
||||
|
||||
/obj/structure/barricade/security/Initialize()
|
||||
/obj/structure/barricade/security/Initialize(mapload)
|
||||
. = ..()
|
||||
addtimer(CALLBACK(src, .proc/deploy), deploy_time)
|
||||
|
||||
@@ -137,7 +130,6 @@
|
||||
if(deploy_message)
|
||||
visible_message("<span class='warning'>[src] deploys!</span>")
|
||||
|
||||
|
||||
/obj/item/grenade/barrier
|
||||
name = "barrier grenade"
|
||||
desc = "Instant cover."
|
||||
@@ -194,7 +186,6 @@
|
||||
/obj/item/grenade/barrier/ui_action_click(mob/user)
|
||||
toggle_mode(user)
|
||||
|
||||
|
||||
#undef SINGLE
|
||||
#undef VERTICAL
|
||||
#undef HORIZONTAL
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
var/suction_enabled = TRUE
|
||||
var/transmit_enabled = TRUE
|
||||
|
||||
/obj/machinery/dish_drive/Initialize()
|
||||
/obj/machinery/dish_drive/Initialize(mapload)
|
||||
. = ..()
|
||||
RefreshParts()
|
||||
|
||||
|
||||
@@ -163,7 +163,7 @@
|
||||
var/max_mutations = 6
|
||||
var/read_only = FALSE //Well,it's still a floppy disk
|
||||
|
||||
/obj/item/disk/data/Initialize()
|
||||
/obj/item/disk/data/Initialize(mapload)
|
||||
. = ..()
|
||||
icon_state = "datadisk[rand(0,6)]"
|
||||
add_overlay("datadisk_gene")
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
/// sigh
|
||||
var/unelectrify_timerid
|
||||
|
||||
/obj/machinery/door/airlock/Initialize()
|
||||
/obj/machinery/door/airlock/Initialize(mapload)
|
||||
. = ..()
|
||||
wires = new wiretypepath(src) //CIT CHANGE - makes it possible for airlocks to have different wire datums
|
||||
if(frequency)
|
||||
|
||||
@@ -485,7 +485,7 @@
|
||||
var/friendly = FALSE
|
||||
var/stealthy = FALSE
|
||||
|
||||
/obj/machinery/door/airlock/cult/Initialize()
|
||||
/obj/machinery/door/airlock/cult/Initialize(mapload)
|
||||
. = ..()
|
||||
new openingoverlaytype(loc)
|
||||
|
||||
@@ -576,7 +576,7 @@
|
||||
desc = "An airlock hastily corrupted by blood magic, it is unusually brittle in this state."
|
||||
normal_integrity = 150
|
||||
damage_deflection = 5
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0,"energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 0, "acid" = 0)
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0,ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 0, ACID = 0)
|
||||
|
||||
//Pinion airlocks: Clockwork doors that only let servants of Ratvar through.
|
||||
/obj/machinery/door/airlock/clockwork
|
||||
@@ -593,7 +593,7 @@
|
||||
normal_integrity = 240
|
||||
var/construction_state = GEAR_SECURE //Pinion airlocks have custom deconstruction
|
||||
|
||||
/obj/machinery/door/airlock/clockwork/Initialize()
|
||||
/obj/machinery/door/airlock/clockwork/Initialize(mapload)
|
||||
. = ..()
|
||||
new /obj/effect/temp_visual/ratvar/door(loc)
|
||||
new /obj/effect/temp_visual/ratvar/beam/door(loc)
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
var/air_frequency = FREQ_ATMOS_ALARMS
|
||||
autoclose = FALSE
|
||||
|
||||
/obj/machinery/door/airlock/alarmlock/Initialize()
|
||||
/obj/machinery/door/airlock/alarmlock/Initialize(mapload)
|
||||
. = ..()
|
||||
air_connection = new
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
air_connection = null
|
||||
return ..()
|
||||
|
||||
/obj/machinery/door/airlock/alarmlock/Initialize()
|
||||
/obj/machinery/door/airlock/alarmlock/Initialize(mapload)
|
||||
. = ..()
|
||||
SSradio.remove_object(src, air_frequency)
|
||||
air_connection = SSradio.add_object(src, air_frequency, RADIO_TO_AIRALARM)
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
maptext_height = 26
|
||||
maptext_width = 32
|
||||
|
||||
/obj/machinery/door_timer/Initialize()
|
||||
/obj/machinery/door_timer/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
Radio = new/obj/item/radio(src)
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
power_channel = ENVIRON
|
||||
max_integrity = 350
|
||||
damage_deflection = 10
|
||||
armor = list("melee" = 30, "bullet" = 30, "laser" = 20, "energy" = 20, "bomb" = 10, "bio" = 100, "rad" = 100, "fire" = 80, "acid" = 70)
|
||||
armor = list(MELEE = 30, BULLET = 30, LASER = 20, ENERGY = 20, BOMB = 10, BIO = 100, RAD = 100, FIRE = 80, ACID = 70)
|
||||
CanAtmosPass = ATMOS_PASS_DENSITY
|
||||
flags_1 = PREVENT_CLICK_UNDER_1|DEFAULT_RICOCHET_1
|
||||
ricochet_chance_mod = 0.8
|
||||
@@ -60,7 +60,7 @@
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/obj/machinery/door/Initialize()
|
||||
/obj/machinery/door/Initialize(mapload)
|
||||
. = ..()
|
||||
set_init_door_layer()
|
||||
update_freelook_sight()
|
||||
@@ -107,19 +107,6 @@
|
||||
return
|
||||
bumpopen(M)
|
||||
return
|
||||
|
||||
if(ismecha(AM))
|
||||
var/obj/mecha/mecha = AM
|
||||
if(density)
|
||||
if(mecha.occupant)
|
||||
if(world.time - mecha.occupant.last_bumped <= 10)
|
||||
return
|
||||
mecha.occupant.last_bumped = world.time
|
||||
if(mecha.occupant && (src.allowed(mecha.occupant) || src.check_access_list(mecha.operation_req_access)))
|
||||
open()
|
||||
else
|
||||
do_animate("deny")
|
||||
return
|
||||
return
|
||||
|
||||
/obj/machinery/door/Move()
|
||||
@@ -127,10 +114,14 @@
|
||||
. = ..()
|
||||
move_update_air(T)
|
||||
|
||||
/obj/machinery/door/CanPass(atom/movable/mover, turf/target)
|
||||
/obj/machinery/door/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
if(.)
|
||||
return
|
||||
|
||||
// Snowflake handling for PASSGLASS.
|
||||
if(istype(mover) && (mover.pass_flags & PASSGLASS))
|
||||
return !opacity
|
||||
return !density
|
||||
|
||||
/obj/machinery/door/proc/bumpopen(mob/user)
|
||||
if(operating)
|
||||
@@ -362,7 +353,7 @@
|
||||
C.bleed(DOOR_CRUSH_DAMAGE)
|
||||
else
|
||||
L.add_splatter_floor(location)
|
||||
for(var/obj/mecha/M in get_turf(src))
|
||||
for(var/obj/vehicle/sealed/mecha/M in get_turf(src))
|
||||
M.take_damage(DOOR_CRUSH_DAMAGE)
|
||||
|
||||
/obj/machinery/door/proc/autoclose()
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
layer = BELOW_OPEN_DOOR_LAYER
|
||||
closingLayer = CLOSED_FIREDOOR_LAYER
|
||||
assemblytype = /obj/structure/firelock_frame
|
||||
armor = list("melee" = 30, "bullet" = 30, "laser" = 20, "energy" = 20, "bomb" = 10, "bio" = 100, "rad" = 100, "fire" = 95, "acid" = 70)
|
||||
armor = list(MELEE = 30, BULLET = 30, LASER = 20, ENERGY = 20, BOMB = 10, BIO = 100, RAD = 100, FIRE = 95, ACID = 70)
|
||||
interaction_flags_machine = INTERACT_MACHINE_WIRES_IF_OPEN | INTERACT_MACHINE_ALLOW_SILICON | INTERACT_MACHINE_OPEN_SILICON | INTERACT_MACHINE_REQUIRES_SILICON | INTERACT_MACHINE_OPEN
|
||||
air_tight = TRUE
|
||||
attack_hand_is_action = TRUE
|
||||
@@ -31,7 +31,7 @@
|
||||
var/boltslocked = TRUE
|
||||
var/list/affecting_areas
|
||||
|
||||
/obj/machinery/door/firedoor/Initialize()
|
||||
/obj/machinery/door/firedoor/Initialize(mapload)
|
||||
. = ..()
|
||||
CalculateAffectingAreas()
|
||||
|
||||
@@ -347,21 +347,18 @@
|
||||
return 0 // not big enough to matter
|
||||
return start_point.air.return_pressure() < 20 ? -1 : 1
|
||||
|
||||
/obj/machinery/door/firedoor/border_only/CanPass(atom/movable/mover, turf/target)
|
||||
if(istype(mover) && (mover.pass_flags & PASSGLASS))
|
||||
return TRUE
|
||||
if(get_dir(loc, target) == dir) //Make sure looking at appropriate border
|
||||
return !density
|
||||
else
|
||||
/obj/machinery/door/firedoor/border_only/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
if(!(get_dir(loc, target) == dir)) //Make sure looking at appropriate border
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/door/firedoor/border_only/CanAStarPass(obj/item/card/id/ID, to_dir)
|
||||
return !density || (dir != to_dir)
|
||||
|
||||
/obj/machinery/door/firedoor/border_only/CheckExit(atom/movable/mover as mob|obj, turf/target)
|
||||
if(istype(mover) && (mover.pass_flags & PASSGLASS))
|
||||
return TRUE
|
||||
if(get_dir(loc, target) == dir)
|
||||
return !density
|
||||
else
|
||||
return TRUE
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/door/firedoor/border_only/CanAtmosPass(turf/T)
|
||||
if(get_dir(loc, T) == dir)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
explosion_block = 3
|
||||
heat_proof = TRUE
|
||||
max_integrity = 600
|
||||
armor = list("melee" = 100, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 100, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100)
|
||||
armor = list(MELEE = 100, BULLET = 100, LASER = 100, ENERGY = 100, BOMB = 100, BIO = 100, RAD = 100, FIRE = 100, ACID = 100)
|
||||
resistance_flags = INDESTRUCTIBLE | FIRE_PROOF | ACID_PROOF | LAVA_PROOF
|
||||
damage_deflection = 70
|
||||
var/password = "Swordfish"
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
heat_proof = TRUE
|
||||
safe = FALSE
|
||||
max_integrity = 600
|
||||
armor = list("melee" = 50, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 50, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 70)
|
||||
armor = list(MELEE = 50, BULLET = 100, LASER = 100, ENERGY = 100, BOMB = 50, BIO = 100, RAD = 100, FIRE = 100, ACID = 70)
|
||||
resistance_flags = FIRE_PROOF
|
||||
damage_deflection = 70
|
||||
poddoor = TRUE
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
icon = 'icons/obj/doors/shutters.dmi'
|
||||
layer = SHUTTER_LAYER
|
||||
closingLayer = SHUTTER_LAYER
|
||||
armor = list("melee" = 20, "bullet" = 20, "laser" = 20, "energy" = 75, "bomb" = 25, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 70)
|
||||
armor = list(MELEE = 20, BULLET = 20, LASER = 20, ENERGY = 75, BOMB = 25, BIO = 100, RAD = 100, FIRE = 100, ACID = 70)
|
||||
damage_deflection = 20
|
||||
max_integrity = 100
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
desc = "These shutters have an armoured frame; it looks like plasteel. These shutters look robust enough to survive explosions."
|
||||
icon = 'icons/obj/doors/shutters_old.dmi'
|
||||
icon_state = "closed"
|
||||
armor = list("melee" = 30, "bullet" = 30, "laser" = 30, "energy" = 75, "bomb" = 30, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 70)
|
||||
armor = list(MELEE = 30, BULLET = 30, LASER = 30, ENERGY = 75, BOMB = 30, BIO = 100, RAD = 100, FIRE = 100, ACID = 70)
|
||||
max_integrity = 300
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/old/preopen
|
||||
|
||||
@@ -9,9 +9,10 @@
|
||||
var/base_state = "left"
|
||||
max_integrity = 150 //If you change this, consider changing ../door/window/brigdoor/ max_integrity at the bottom of this .dm file
|
||||
integrity_failure = 0
|
||||
armor = list("melee" = 20, "bullet" = 50, "laser" = 50, "energy" = 50, "bomb" = 10, "bio" = 100, "rad" = 100, "fire" = 70, "acid" = 100)
|
||||
armor = list(MELEE = 20, BULLET = 50, LASER = 50, ENERGY = 50, BOMB = 10, BIO = 100, RAD = 100, FIRE = 70, ACID = 100)
|
||||
visible = FALSE
|
||||
flags_1 = ON_BORDER_1|DEFAULT_RICOCHET_1
|
||||
pass_flags_self = PASSGLASS
|
||||
opacity = 0
|
||||
CanAtmosPass = ATMOS_PASS_PROC
|
||||
interaction_flags_machine = INTERACT_MACHINE_WIRES_IF_OPEN | INTERACT_MACHINE_ALLOW_SILICON | INTERACT_MACHINE_OPEN_SILICON | INTERACT_MACHINE_REQUIRES_SILICON | INTERACT_MACHINE_OPEN
|
||||
@@ -77,11 +78,13 @@
|
||||
return
|
||||
if (!( ismob(AM) ))
|
||||
if(ismecha(AM))
|
||||
var/obj/mecha/mecha = AM
|
||||
if(mecha.occupant && src.allowed(mecha.occupant))
|
||||
open_and_close()
|
||||
else
|
||||
do_animate("deny")
|
||||
var/obj/vehicle/sealed/mecha/mecha = AM
|
||||
for(var/O in mecha.occupants)
|
||||
var/mob/living/occupant = O
|
||||
if(allowed(occupant))
|
||||
open_and_close()
|
||||
return
|
||||
do_animate("deny")
|
||||
return
|
||||
if (!( SSticker ))
|
||||
return
|
||||
@@ -103,11 +106,12 @@
|
||||
do_animate("deny")
|
||||
return
|
||||
|
||||
/obj/machinery/door/window/CanPass(atom/movable/mover, turf/target)
|
||||
if(istype(mover) && (mover.pass_flags & PASSGLASS))
|
||||
return 1
|
||||
/obj/machinery/door/window/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
if(.)
|
||||
return
|
||||
if(get_dir(loc, target) == dir) //Make sure looking at appropriate border
|
||||
return !density
|
||||
return
|
||||
if(istype(mover, /obj/structure/window))
|
||||
var/obj/structure/window/W = mover
|
||||
if(!valid_window_location(loc, W.ini_dir))
|
||||
@@ -119,7 +123,7 @@
|
||||
else if(istype(mover, /obj/machinery/door/window) && !valid_window_location(loc, mover.dir))
|
||||
return FALSE
|
||||
else
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/door/window/CanAtmosPass(turf/T)
|
||||
if(get_dir(loc, T) == dir)
|
||||
@@ -131,13 +135,12 @@
|
||||
/obj/machinery/door/window/CanAStarPass(obj/item/card/id/ID, to_dir)
|
||||
return !density || (dir != to_dir) || (check_access(ID) && hasPower())
|
||||
|
||||
/obj/machinery/door/window/CheckExit(atom/movable/mover as mob|obj, turf/target)
|
||||
if(istype(mover) && (mover.pass_flags & PASSGLASS))
|
||||
return 1
|
||||
/obj/machinery/door/window/CheckExit(atom/movable/mover, turf/target)
|
||||
if((pass_flags_self & mover.pass_flags) || ((pass_flags_self & LETPASSTHROW) && mover.throwing))
|
||||
return TRUE
|
||||
if(get_dir(loc, target) == dir)
|
||||
return !density
|
||||
else
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/door/window/open(forced=0)
|
||||
if (src.operating == 1) //doors can still open when emag-disabled
|
||||
|
||||
@@ -14,7 +14,7 @@ GLOBAL_LIST_EMPTY(doppler_arrays)
|
||||
verb_say = "states coldly"
|
||||
var/list/message_log = list()
|
||||
|
||||
/obj/machinery/doppler_array/Initialize()
|
||||
/obj/machinery/doppler_array/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.doppler_arrays += src
|
||||
|
||||
@@ -218,6 +218,6 @@ GLOBAL_LIST_EMPTY(doppler_arrays)
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/doppler_array/research/science/Initialize()
|
||||
/obj/machinery/doppler_array/research/science/Initialize(mapload)
|
||||
. = ..()
|
||||
linked_techweb = SSresearch.science_tech
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
var/break_message = "lets out a tinny alarm before falling dark."
|
||||
var/break_sound = 'sound/machines/warning-buzzer.ogg'
|
||||
|
||||
/obj/machinery/droneDispenser/Initialize()
|
||||
/obj/machinery/droneDispenser/Initialize(mapload)
|
||||
. = ..()
|
||||
var/datum/component/material_container/materials = AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass), MINERAL_MATERIAL_AMOUNT * MAX_STACK_SIZE * 2, TRUE, /obj/item/stack)
|
||||
materials.insert_amount_mat(starting_amount)
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
/obj/machinery/doorButtons/proc/findObjsByTag()
|
||||
return
|
||||
|
||||
/obj/machinery/doorButtons/Initialize()
|
||||
/obj/machinery/doorButtons/Initialize(mapload)
|
||||
..()
|
||||
return INITIALIZE_HINT_LATELOAD
|
||||
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
SSradio.remove_object(src,frequency)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/embedded_controller/radio/Initialize()
|
||||
/obj/machinery/embedded_controller/radio/Initialize(mapload)
|
||||
. = ..()
|
||||
set_frequency(frequency)
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
plane = ABOVE_WALL_PLANE
|
||||
max_integrity = 250
|
||||
integrity_failure = 0.4
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 100, "rad" = 100, "fire" = 90, "acid" = 30)
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 100, RAD = 100, FIRE = 90, ACID = 30)
|
||||
use_power = IDLE_POWER_USE
|
||||
idle_power_usage = 2
|
||||
active_power_usage = 6
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
return flash()
|
||||
|
||||
/obj/machinery/flasher/run_obj_armor(damage_amount, damage_type, damage_flag = 0, attack_dir)
|
||||
if(damage_flag == "melee" && damage_amount < 10) //any melee attack below 10 dmg does nothing
|
||||
if(damage_flag == MELEE && damage_amount < 10) //any melee attack below 10 dmg does nothing
|
||||
return 0
|
||||
. = ..()
|
||||
|
||||
@@ -159,7 +159,7 @@
|
||||
new /obj/item/stack/sheet/metal (loc, 2)
|
||||
qdel(src)
|
||||
|
||||
/obj/machinery/flasher/portable/Initialize()
|
||||
/obj/machinery/flasher/portable/Initialize(mapload)
|
||||
. = ..()
|
||||
proximity_monitor = new(src, 0)
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ The console is located at computer/gulag_teleporter.dm
|
||||
/obj/item/clothing/mask/breath,
|
||||
/obj/item/clothing/mask/gas))
|
||||
|
||||
/obj/machinery/gulag_teleporter/Initialize()
|
||||
/obj/machinery/gulag_teleporter/Initialize(mapload)
|
||||
. = ..()
|
||||
locate_reclaimer()
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
var/allow_clothing = FALSE
|
||||
var/allow_living = FALSE
|
||||
|
||||
/obj/machinery/harvester/Initialize()
|
||||
/obj/machinery/harvester/Initialize(mapload)
|
||||
. = ..()
|
||||
if(prob(1))
|
||||
name = "auto-autopsy"
|
||||
|
||||
@@ -40,7 +40,7 @@ Possible to do for anyone motivated enough:
|
||||
idle_power_usage = 5
|
||||
active_power_usage = 100
|
||||
max_integrity = 300
|
||||
armor = list("melee" = 50, "bullet" = 20, "laser" = 20, "energy" = 20, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 0)
|
||||
armor = list(MELEE = 50, BULLET = 20, LASER = 20, ENERGY = 20, BOMB = 0, BIO = 0, RAD = 0, FIRE = 50, ACID = 0)
|
||||
circuit = /obj/item/circuitboard/machine/holopad
|
||||
/// List of living mobs that use the holopad
|
||||
var/list/masters
|
||||
@@ -85,7 +85,7 @@ Possible to do for anyone motivated enough:
|
||||
desc = "It's a floor-mounted device for projecting holographic images. This one will refuse to auto-connect incoming calls."
|
||||
secure = TRUE
|
||||
|
||||
/obj/machinery/holopad/secure/Initialize()
|
||||
/obj/machinery/holopad/secure/Initialize(mapload)
|
||||
. = ..()
|
||||
var/obj/item/circuitboard/machine/holopad/board = circuit
|
||||
board.secure = TRUE
|
||||
@@ -144,7 +144,7 @@ Possible to do for anyone motivated enough:
|
||||
if(!replay_mode && (disk?.record))
|
||||
replay_start()
|
||||
|
||||
/obj/machinery/holopad/Initialize()
|
||||
/obj/machinery/holopad/Initialize(mapload)
|
||||
. = ..()
|
||||
if(on_network)
|
||||
holopads += src
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
var/timerid = 0 ///Timer ID for interrogations
|
||||
var/message_cooldown = 0 ///Cooldown for breakout message
|
||||
|
||||
/obj/machinery/hypnochair/Initialize()
|
||||
/obj/machinery/hypnochair/Initialize(mapload)
|
||||
. = ..()
|
||||
open_machine()
|
||||
update_icon()
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
idle_power_usage = 2
|
||||
active_power_usage = 4
|
||||
max_integrity = 300
|
||||
armor = list("melee" = 50, "bullet" = 30, "laser" = 70, "energy" = 50, "bomb" = 20, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 70)
|
||||
armor = list(MELEE = 50, BULLET = 30, LASER = 70, ENERGY = 50, BOMB = 20, BIO = 0, RAD = 0, FIRE = 100, ACID = 70)
|
||||
resistance_flags = FIRE_PROOF
|
||||
var/id = null
|
||||
var/on = FALSE
|
||||
@@ -40,7 +40,7 @@
|
||||
location.hotspot_expose(700,10,1)
|
||||
return 1
|
||||
|
||||
/obj/machinery/igniter/Initialize()
|
||||
/obj/machinery/igniter/Initialize(mapload)
|
||||
. = ..()
|
||||
icon_state = "igniter[on]"
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
/obj/machinery/sparker/toxmix
|
||||
id = INCINERATOR_TOXMIX_IGNITER
|
||||
|
||||
/obj/machinery/sparker/Initialize()
|
||||
/obj/machinery/sparker/Initialize(mapload)
|
||||
. = ..()
|
||||
spark_system = new /datum/effect_system/spark_spread
|
||||
spark_system.set_up(2, 1, src)
|
||||
|
||||
@@ -229,7 +229,7 @@
|
||||
/obj/item/storage/briefcase/launchpad
|
||||
var/obj/machinery/launchpad/briefcase/pad
|
||||
|
||||
/obj/item/storage/briefcase/launchpad/Initialize()
|
||||
/obj/item/storage/briefcase/launchpad/Initialize(mapload)
|
||||
pad = new(null, src) //spawns pad in nullspace to hide it from briefcase contents
|
||||
. = ..()
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
dir = EAST
|
||||
pixel_x = -26
|
||||
|
||||
/obj/machinery/light_switch/Initialize()
|
||||
/obj/machinery/light_switch/Initialize(mapload)
|
||||
. = ..()
|
||||
if(istext(area))
|
||||
area = text2path(area)
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
)
|
||||
var/obj/item/disk/data/dna_disk
|
||||
|
||||
/obj/machinery/limbgrower/Initialize()
|
||||
/obj/machinery/limbgrower/Initialize(mapload)
|
||||
create_reagents(100, OPENCONTAINER)
|
||||
stored_research = new /datum/techweb/specialized/autounlocking/limbgrower
|
||||
. = ..()
|
||||
@@ -60,7 +60,7 @@
|
||||
reagent_type = reagent_id.type
|
||||
)
|
||||
data["reagents"] += list(reagent_data)
|
||||
else
|
||||
else
|
||||
data["reagents"] = list()
|
||||
data["total_reagents"] = reagents.total_volume
|
||||
data["max_reagents"] = reagents.maximum_volume
|
||||
@@ -335,6 +335,12 @@
|
||||
if(!features["breasts_producing"])
|
||||
boobs.genital_flags &= ~(GENITAL_FUID_PRODUCTION|CAN_CLIMAX_WITH|CAN_MASTURBATE_WITH)
|
||||
boobs.update()
|
||||
if(/obj/item/organ/genital/butt)
|
||||
var/obj/item/organ/genital/butt/ass = new(loc)
|
||||
if(features["has_butt"])
|
||||
ass.color = sanitize_hexcolor(features["butt_color"], 6, TRUE)
|
||||
ass.size = features["butt_size"]
|
||||
ass.update()
|
||||
else
|
||||
new built_typepath(loc)
|
||||
else
|
||||
@@ -373,7 +379,7 @@
|
||||
C.undershirt = "Nude"
|
||||
C.saved_underwear = ""
|
||||
C.saved_undershirt = ""
|
||||
|
||||
|
||||
// Just enough to start reviving them, I hope
|
||||
C.blood_volume = BLOOD_VOLUME_SURVIVE
|
||||
// At some point, make a way to deal with species regenerate_organs
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
var/center_y = 0
|
||||
var/max_dist = 20 // absolute value of center_x,y cannot exceed this integer
|
||||
|
||||
/obj/machinery/magnetic_module/Initialize()
|
||||
/obj/machinery/magnetic_module/Initialize(mapload)
|
||||
..()
|
||||
var/turf/T = loc
|
||||
hide(T.intact)
|
||||
@@ -213,7 +213,7 @@
|
||||
var/datum/radio_frequency/radio_connection
|
||||
|
||||
|
||||
/obj/machinery/magnetic_controller/Initialize()
|
||||
/obj/machinery/magnetic_controller/Initialize(mapload)
|
||||
. = ..()
|
||||
if(autolink)
|
||||
for(var/obj/machinery/magnetic_module/M in GLOB.machines)
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
///List of consoles that can access the pad
|
||||
var/list/obj/machinery/computer/mechpad/consoles
|
||||
|
||||
/obj/machinery/mechpad/Initialize()
|
||||
/obj/machinery/mechpad/Initialize(mapload)
|
||||
. = ..()
|
||||
display_name = "Orbital Pad - [get_area_name(src)]"
|
||||
GLOB.mechpad_list += src
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
level = 1 // underfloor
|
||||
layer = LOW_OBJ_LAYER
|
||||
max_integrity = 500
|
||||
armor = list("melee" = 70, "bullet" = 70, "laser" = 70, "energy" = 70, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 80, "acid" = 80)
|
||||
armor = list(MELEE = 70, BULLET = 70, LASER = 70, ENERGY = 70, BOMB = 0, BIO = 0, RAD = 0, FIRE = 80, ACID = 80)
|
||||
|
||||
var/open = FALSE // true if cover is open
|
||||
var/locked = TRUE // true if controls are locked
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
req_one_access = list(ACCESS_ENGINE, ACCESS_ROBOTICS)
|
||||
|
||||
/obj/machinery/navbeacon/Initialize()
|
||||
/obj/machinery/navbeacon/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
set_codes()
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
power_channel = EQUIP //drains power from the EQUIPMENT channel
|
||||
max_integrity = 160 //the turret's health
|
||||
integrity_failure = 0.5
|
||||
armor = list("melee" = 50, "bullet" = 30, "laser" = 30, "energy" = 30, "bomb" = 30, "bio" = 0, "rad" = 0, "fire" = 90, "acid" = 90)
|
||||
armor = list(MELEE = 50, BULLET = 30, LASER = 30, ENERGY = 30, BOMB = 30, BIO = 0, RAD = 0, FIRE = 90, ACID = 90)
|
||||
/// Base turret icon state
|
||||
base_icon_state = "standard"
|
||||
/// Scan range of the turret for locating targets
|
||||
@@ -98,7 +98,7 @@
|
||||
/// MISSING:
|
||||
var/shot_stagger = 0
|
||||
|
||||
/obj/machinery/porta_turret/Initialize()
|
||||
/obj/machinery/porta_turret/Initialize(mapload)
|
||||
. = ..()
|
||||
if(!base)
|
||||
base = src
|
||||
@@ -478,10 +478,12 @@
|
||||
|
||||
for(var/A in GLOB.mechas_list)
|
||||
if((get_dist(A, base) < scan_range) && can_see(base, A, scan_range))
|
||||
var/obj/mecha/Mech = A
|
||||
if(Mech.occupant && !in_faction(Mech.occupant)) //If there is a user and they're not in our faction
|
||||
if(assess_perp(Mech.occupant) >= 4)
|
||||
targets += Mech
|
||||
var/obj/vehicle/sealed/mecha/mech = A
|
||||
for(var/O in mech.occupants)
|
||||
var/mob/living/occupant = O
|
||||
if(!in_faction(occupant)) //If there is a user and they're not in our faction
|
||||
if(assess_perp(occupant) >= 4)
|
||||
targets += mech
|
||||
|
||||
if((turret_flags & TURRET_FLAG_SHOOT_ANOMALOUS) && GLOB.blobs.len && (mode == TURRET_LETHAL))
|
||||
for(var/obj/structure/blob/B in view(scan_range, base))
|
||||
@@ -774,7 +776,7 @@
|
||||
/obj/machinery/porta_turret/syndicate/energy/pirate
|
||||
max_integrity = 260
|
||||
integrity_failure = 0.08
|
||||
armor = list("melee" = 50, "bullet" = 30, "laser" = 30, "energy" = 30, "bomb" = 50, "bio" = 0, "rad" = 0, "fire" = 90, "acid" = 90)
|
||||
armor = list(MELEE = 50, BULLET = 30, LASER = 30, ENERGY = 30, BOMB = 50, BIO = 0, RAD = 0, FIRE = 90, ACID = 90)
|
||||
|
||||
/obj/machinery/porta_turret/syndicate/energy/raven
|
||||
stun_projectile = /obj/item/projectile/beam/laser
|
||||
@@ -794,7 +796,7 @@
|
||||
lethal_projectile = /obj/item/projectile/bullet/p50/penetrator/shuttle
|
||||
lethal_projectile_sound = 'sound/weapons/gunshot_smg.ogg'
|
||||
stun_projectile_sound = 'sound/weapons/gunshot_smg.ogg'
|
||||
armor = list("melee" = 50, "bullet" = 30, "laser" = 30, "energy" = 30, "bomb" = 80, "bio" = 0, "rad" = 0, "fire" = 90, "acid" = 90)
|
||||
armor = list(MELEE = 50, BULLET = 30, LASER = 30, ENERGY = 30, BOMB = 80, BIO = 0, RAD = 0, FIRE = 90, ACID = 90)
|
||||
|
||||
/obj/machinery/porta_turret/syndicate/pod/toolbox
|
||||
max_integrity = 100
|
||||
@@ -835,7 +837,7 @@
|
||||
/obj/machinery/porta_turret/aux_base/interact(mob/user) //Controlled solely from the base console.
|
||||
return
|
||||
|
||||
/obj/machinery/porta_turret/aux_base/Initialize()
|
||||
/obj/machinery/porta_turret/aux_base/Initialize(mapload)
|
||||
. = ..()
|
||||
cover.name = name
|
||||
cover.desc = desc
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
var/map_pad_id = "" as text //what's my name
|
||||
var/map_pad_link_id = "" as text //who's my friend
|
||||
|
||||
/obj/machinery/quantumpad/Initialize()
|
||||
/obj/machinery/quantumpad/Initialize(mapload)
|
||||
. = ..()
|
||||
if(map_pad_id)
|
||||
mapped_quantum_pads[map_pad_id] = src
|
||||
|
||||
@@ -14,13 +14,13 @@
|
||||
var/recharge_speed
|
||||
var/repairs
|
||||
|
||||
/obj/machinery/recharge_station/Initialize()
|
||||
/obj/machinery/recharge_station/Initialize(mapload)
|
||||
. = ..()
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/recharge_station/upgraded
|
||||
|
||||
/obj/machinery/recharge_station/upgraded/Initialize()
|
||||
/obj/machinery/recharge_station/upgraded/Initialize(mapload)
|
||||
. = ..()
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/circuitboard/machine/cyborgrecharger(null)
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
/obj/machinery/recharge_station/fullupgrade
|
||||
|
||||
/obj/machinery/recharge_station/fullupgrade/Initialize()
|
||||
/obj/machinery/recharge_station/fullupgrade/Initialize(mapload)
|
||||
. = ..()
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/circuitboard/machine/cyborgrecharger(null)
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
var/eat_victim_items = TRUE
|
||||
var/item_recycle_sound = 'sound/items/welder.ogg'
|
||||
|
||||
/obj/machinery/recycler/Initialize()
|
||||
/obj/machinery/recycler/Initialize(mapload)
|
||||
AddComponent(/datum/component/butchering/recycler, 1, amount_produced,amount_produced/5)
|
||||
AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass, /datum/material/silver, /datum/material/plasma, /datum/material/gold, /datum/material/diamond, /datum/material/plastic, /datum/material/uranium, /datum/material/bananium, /datum/material/titanium, /datum/material/bluespace), INFINITY, FALSE, null, null, null, TRUE)
|
||||
. = ..()
|
||||
@@ -87,7 +87,7 @@
|
||||
is_powered = FALSE
|
||||
icon_state = icon_name + "[is_powered]" + "[(blood ? "bld" : "")]" // add the blood tag at the end
|
||||
|
||||
/obj/machinery/recycler/CanPass(atom/movable/AM)
|
||||
/obj/machinery/recycler/CanAllowThrough(atom/movable/AM)
|
||||
. = ..()
|
||||
if(!anchored)
|
||||
return
|
||||
@@ -120,10 +120,10 @@
|
||||
var/obj/item/bodypart/head/as_head = AM
|
||||
var/obj/item/mmi/as_mmi = AM
|
||||
if(istype(AM, /obj/item/organ/brain) || (istype(as_head) && as_head.brain) || (istype(as_mmi) && as_mmi.brain) || istype(AM, /obj/item/dullahan_relay))
|
||||
living_detected = living_detected || AM
|
||||
living_detected = living_detected ? living_detected : AM
|
||||
nom += AM
|
||||
else if(isliving(AM))
|
||||
living_detected = living_detected || TRUE
|
||||
living_detected = living_detected ? living_detected : AM
|
||||
crunchy_nom += AM
|
||||
var/not_eaten = to_eat.len - nom.len - crunchy_nom.len
|
||||
if(living_detected) // First, check if we have any living beings detected.
|
||||
|
||||
@@ -55,7 +55,7 @@ GLOBAL_LIST_EMPTY(allConsoles)
|
||||
var/emergency //If an emergency has been called by this device. Acts as both a cooldown and lets the responder know where it the emergency was triggered from
|
||||
var/receive_ore_updates = FALSE //If ore redemption machines will send an update when it receives new ores.
|
||||
max_integrity = 300
|
||||
armor = list("melee" = 70, "bullet" = 30, "laser" = 30, "energy" = 30, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 90, "acid" = 90)
|
||||
armor = list(MELEE = 70, BULLET = 30, LASER = 30, ENERGY = 30, BOMB = 0, BIO = 0, RAD = 0, FIRE = 90, ACID = 90)
|
||||
|
||||
/obj/machinery/requests_console/power_change()
|
||||
..()
|
||||
@@ -85,7 +85,7 @@ GLOBAL_LIST_EMPTY(allConsoles)
|
||||
else
|
||||
icon_state = "req_comp0"
|
||||
|
||||
/obj/machinery/requests_console/Initialize()
|
||||
/obj/machinery/requests_console/Initialize(mapload)
|
||||
. = ..()
|
||||
name = "\improper [department] requests console"
|
||||
GLOB.allConsoles += src
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
layer = BELOW_OBJ_LAYER
|
||||
var/busy_processing = FALSE
|
||||
|
||||
/obj/machinery/sheetifier/Initialize()
|
||||
/obj/machinery/sheetifier/Initialize(mapload)
|
||||
. = ..()
|
||||
AddComponent(/datum/component/material_container, list(/datum/material/meat), MINERAL_MATERIAL_AMOUNT * MAX_STACK_SIZE * 2, TRUE, /obj/item/reagent_containers/food/snacks/meat/slab, CALLBACK(src, .proc/CanInsertMaterials), CALLBACK(src, .proc/AfterInsertMaterials))
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
max_integrity = 200 //The shield can only take so much beating (prevents perma-prisons)
|
||||
CanAtmosPass = ATMOS_PASS_DENSITY
|
||||
|
||||
/obj/structure/emergency_shield/Initialize()
|
||||
/obj/structure/emergency_shield/Initialize(mapload)
|
||||
. = ..()
|
||||
setDir(pick(GLOB.cardinals))
|
||||
air_update_turf(1)
|
||||
@@ -28,7 +28,7 @@
|
||||
if(severity >= 70)
|
||||
qdel(src)
|
||||
else
|
||||
take_damage(severity/1.3, BRUTE, "energy", 0)
|
||||
take_damage(severity/1.3, BRUTE, ENERGY, 0)
|
||||
|
||||
/obj/structure/emergency_shield/play_attack_sound(damage, damage_type = BRUTE, damage_flag = 0)
|
||||
switch(damage_type)
|
||||
@@ -454,11 +454,10 @@
|
||||
if(gen_secondary) //using power may cause us to be destroyed
|
||||
gen_secondary.use_stored_power(drain_amount*0.5)
|
||||
|
||||
/obj/machinery/shieldwall/CanPass(atom/movable/mover, turf/target)
|
||||
/obj/machinery/shieldwall/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
if(istype(mover) && (mover.pass_flags & PASSGLASS))
|
||||
return prob(20)
|
||||
else
|
||||
if(istype(mover, /obj/item/projectile))
|
||||
return prob(10)
|
||||
else
|
||||
return !density
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
var/icon_state_open = "burst_plasma_open"
|
||||
var/icon_state_off = "burst_plasma_off"
|
||||
|
||||
/obj/machinery/shuttle/Initialize()
|
||||
/obj/machinery/shuttle/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.custom_shuttle_machines += src
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
bluespace_capable = TRUE
|
||||
cooldown = 90
|
||||
|
||||
/obj/machinery/shuttle/engine/Initialize()
|
||||
/obj/machinery/shuttle/engine/Initialize(mapload)
|
||||
. = ..()
|
||||
check_setup()
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
density = TRUE
|
||||
max_integrity = 400
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 100, "bomb" = 0, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 30)
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 100, BOMB = 0, BIO = 100, RAD = 100, FIRE = 100, ACID = 30)
|
||||
layer = OBJ_LAYER
|
||||
showpipe = TRUE
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
var/list/symbols = list(SEVEN = 1, "<font color='orange'>&</font>" = 2, "<font color='yellow'>@</font>" = 2, "<font color='green'>$</font>" = 2, "<font color='blue'>?</font>" = 2, "<font color='grey'>#</font>" = 2, "<font color='white'>!</font>" = 2, "<font color='fuchsia'>%</font>" = 2) //if people are winning too much, multiply every number in this list by 2 and see if they are still winning too much.
|
||||
|
||||
|
||||
/obj/machinery/computer/slot_machine/Initialize()
|
||||
/obj/machinery/computer/slot_machine/Initialize(mapload)
|
||||
. = ..()
|
||||
jackpots = rand(1, 4) //false hope
|
||||
plays = rand(75, 200)
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
name = "space heater"
|
||||
desc = "Made by Space Amish using traditional space techniques, this heater/cooler is guaranteed not to set the station on fire. Warranty void if used in engines."
|
||||
max_integrity = 250
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 100, "rad" = 100, "fire" = 80, "acid" = 10)
|
||||
armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 100, RAD = 100, FIRE = 80, ACID = 10)
|
||||
circuit = /obj/item/circuitboard/machine/space_heater
|
||||
var/obj/item/stock_parts/cell/cell
|
||||
var/on = FALSE
|
||||
@@ -28,7 +28,7 @@
|
||||
/obj/machinery/space_heater/get_cell()
|
||||
return cell
|
||||
|
||||
/obj/machinery/space_heater/Initialize()
|
||||
/obj/machinery/space_heater/Initialize(mapload)
|
||||
. = ..()
|
||||
cell = new(src)
|
||||
update_icon()
|
||||
|
||||
@@ -0,0 +1,153 @@
|
||||
#define STASIS_TOGGLE_COOLDOWN 50
|
||||
/obj/machinery/stasis
|
||||
name = "lifeform stasis unit"
|
||||
desc = "A not so comfortable looking bed with some nozzles at the top and bottom. It will keep someone in stasis."
|
||||
icon = 'icons/obj/machines/stasis.dmi'
|
||||
icon_state = "stasis"
|
||||
base_icon_state = "stasis"
|
||||
density = FALSE
|
||||
// obj_flags = NO_BUILD
|
||||
can_buckle = TRUE
|
||||
buckle_lying = 90
|
||||
circuit = /obj/item/circuitboard/machine/stasis
|
||||
idle_power_usage = 40
|
||||
active_power_usage = 340
|
||||
fair_market_price = 10
|
||||
payment_department = ACCOUNT_MED
|
||||
var/stasis_enabled = TRUE
|
||||
var/last_stasis_sound = FALSE
|
||||
COOLDOWN_DECLARE(stasis_can_toggle)
|
||||
var/mattress_state = "stasis_on"
|
||||
var/obj/effect/overlay/vis/mattress_on
|
||||
|
||||
/obj/machinery/stasis/examine(mob/user)
|
||||
. = ..()
|
||||
. += span_notice("Alt-click to [stasis_enabled ? "turn off" : "turn on"] the machine.")
|
||||
|
||||
/obj/machinery/stasis/proc/play_power_sound()
|
||||
var/_running = stasis_running()
|
||||
if(last_stasis_sound != _running)
|
||||
var/sound_freq = rand(5120, 8800)
|
||||
if(_running)
|
||||
playsound(src, 'sound/machines/synth_yes.ogg', 50, TRUE, frequency = sound_freq)
|
||||
else
|
||||
playsound(src, 'sound/machines/synth_no.ogg', 50, TRUE, frequency = sound_freq)
|
||||
last_stasis_sound = _running
|
||||
|
||||
/obj/machinery/stasis/AltClick(mob/user)
|
||||
. = ..()
|
||||
if(!can_interact(user))
|
||||
return
|
||||
if(COOLDOWN_FINISHED(src, stasis_can_toggle) && user.canUseTopic(src, !issilicon(user)))
|
||||
stasis_enabled = !stasis_enabled
|
||||
COOLDOWN_START(src, stasis_can_toggle, STASIS_TOGGLE_COOLDOWN)
|
||||
playsound(src, 'sound/machines/click.ogg', 60, TRUE)
|
||||
user.visible_message(span_notice("\The [src] [stasis_enabled ? "powers on" : "shuts down"]."), \
|
||||
span_notice("You [stasis_enabled ? "power on" : "shut down"] \the [src]."), \
|
||||
span_hear("You hear a nearby machine [stasis_enabled ? "power on" : "shut down"]."))
|
||||
play_power_sound()
|
||||
update_appearance()
|
||||
|
||||
/obj/machinery/stasis/Exited(atom/movable/gone, atom/newloc)
|
||||
if(gone == occupant)
|
||||
var/mob/living/L = gone
|
||||
if(IS_IN_STASIS(L))
|
||||
thaw_them(L)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/stasis/proc/stasis_running()
|
||||
return stasis_enabled && is_operational()
|
||||
|
||||
/obj/machinery/stasis/update_icon_state()
|
||||
if(stat & BROKEN)
|
||||
icon_state = "[base_icon_state]_broken"
|
||||
return ..()
|
||||
if(panel_open || stat & MAINT)
|
||||
icon_state = "[base_icon_state]_maintenance"
|
||||
return ..()
|
||||
icon_state = base_icon_state
|
||||
return ..()
|
||||
|
||||
/obj/machinery/stasis/update_overlays()
|
||||
. = ..()
|
||||
if(!mattress_state)
|
||||
return
|
||||
var/_running = stasis_running()
|
||||
if(!mattress_on)
|
||||
mattress_on = SSvis_overlays.add_vis_overlay(src, icon, mattress_state, BELOW_OBJ_LAYER, plane, dir, alpha = 0, unique = TRUE)
|
||||
else
|
||||
vis_contents += mattress_on
|
||||
if(managed_vis_overlays)
|
||||
managed_vis_overlays += mattress_on
|
||||
else
|
||||
managed_vis_overlays = list(mattress_on)
|
||||
|
||||
if(mattress_on.alpha ? !_running : _running) //check the inverse of _running compared to truthy alpha, to see if they differ
|
||||
var/new_alpha = _running ? 255 : 0
|
||||
var/easing_direction = _running ? EASE_OUT : EASE_IN
|
||||
animate(mattress_on, alpha = new_alpha, time = 50, easing = CUBIC_EASING|easing_direction)
|
||||
|
||||
/obj/machinery/stasis/obj_break(damage_flag)
|
||||
. = ..()
|
||||
if(.)
|
||||
play_power_sound()
|
||||
|
||||
/obj/machinery/stasis/power_change()
|
||||
. = ..()
|
||||
if(.)
|
||||
play_power_sound()
|
||||
|
||||
/obj/machinery/stasis/proc/chill_out(mob/living/target)
|
||||
if(target != occupant)
|
||||
return
|
||||
var/freq = rand(24750, 26550)
|
||||
playsound(src, 'sound/effects/spray.ogg', 5, TRUE, 2, frequency = freq)
|
||||
target.apply_status_effect(/datum/status_effect/grouped/stasis, STASIS_MACHINE_EFFECT)
|
||||
// ADD_TRAIT(target, TRAIT_TUMOR_SUPPRESSED, TRAIT_GENERIC)
|
||||
target.ExtinguishMob()
|
||||
use_power = ACTIVE_POWER_USE
|
||||
|
||||
/obj/machinery/stasis/proc/thaw_them(mob/living/target)
|
||||
target.remove_status_effect(/datum/status_effect/grouped/stasis, STASIS_MACHINE_EFFECT)
|
||||
// REMOVE_TRAIT(target, TRAIT_TUMOR_SUPPRESSED, TRAIT_GENERIC)
|
||||
if(target == occupant)
|
||||
use_power = IDLE_POWER_USE
|
||||
|
||||
/obj/machinery/stasis/post_buckle_mob(mob/living/L)
|
||||
if(!can_be_occupant(L))
|
||||
return
|
||||
occupant = L
|
||||
if(stasis_running() && check_nap_violations())
|
||||
chill_out(L)
|
||||
update_appearance()
|
||||
|
||||
/obj/machinery/stasis/post_unbuckle_mob(mob/living/L)
|
||||
thaw_them(L)
|
||||
if(L == occupant)
|
||||
occupant = null
|
||||
update_appearance()
|
||||
|
||||
/obj/machinery/stasis/process()
|
||||
if(!(occupant && isliving(occupant) && check_nap_violations()))
|
||||
use_power = IDLE_POWER_USE
|
||||
return
|
||||
var/mob/living/L_occupant = occupant
|
||||
if(stasis_running())
|
||||
if(!IS_IN_STASIS(L_occupant))
|
||||
chill_out(L_occupant)
|
||||
else if(IS_IN_STASIS(L_occupant))
|
||||
thaw_them(L_occupant)
|
||||
|
||||
/obj/machinery/stasis/screwdriver_act(mob/living/user, obj/item/I)
|
||||
. = ..()
|
||||
. |= default_deconstruction_screwdriver(user, "[base_icon_state]_maintenance", "[base_icon_state]", I)
|
||||
update_appearance()
|
||||
|
||||
/obj/machinery/stasis/crowbar_act(mob/living/user, obj/item/I)
|
||||
. = ..()
|
||||
return default_deconstruction_crowbar(I) || .
|
||||
|
||||
/obj/machinery/stasis/nap_violation(mob/violator)
|
||||
unbuckle_mob(violator, TRUE)
|
||||
|
||||
#undef STASIS_TOGGLE_COOLDOWN
|
||||
@@ -4,102 +4,182 @@
|
||||
#define CHARS_PER_LINE 5
|
||||
#define FONT_SIZE "5pt"
|
||||
#define FONT_COLOR "#09f"
|
||||
#define FONT_STYLE "Arial Black"
|
||||
#define SCROLL_SPEED 2
|
||||
#define FONT_STYLE "Small Fonts"
|
||||
#define SCROLL_RATE (0.04 SECONDS) // time per pixel
|
||||
#define LINE1_Y -8
|
||||
#define LINE2_Y -15
|
||||
|
||||
#define SD_BLANK 0 // 0 = Blank
|
||||
#define SD_EMERGENCY 1 // 1 = Emergency Shuttle timer
|
||||
#define SD_MESSAGE 2 // 2 = Arbitrary message(s)
|
||||
#define SD_PICTURE 3 // 3 = alert picture
|
||||
|
||||
#define SD_AI_EMOTE 1 // 1 = AI emoticon
|
||||
#define SD_AI_BSOD 2 // 2 = Blue screen of death
|
||||
|
||||
/// Status display which can show images and scrolling text. !!!USE /obj/machinery/status_display/evac NOT THIS!!!
|
||||
/// Status display which can show images and scrolling text.
|
||||
/obj/machinery/status_display
|
||||
name = "status display"
|
||||
desc = null
|
||||
icon = 'icons/obj/status_display.dmi'
|
||||
icon_state = "frame"
|
||||
plane = ABOVE_WALL_PLANE
|
||||
base_icon_state = "unanchoredstatusdisplay"
|
||||
verb_say = "beeps"
|
||||
verb_ask = "beeps"
|
||||
verb_exclaim = "beeps"
|
||||
density = FALSE
|
||||
use_power = IDLE_POWER_USE
|
||||
idle_power_usage = 10
|
||||
layer = ABOVE_WINDOW_LAYER
|
||||
|
||||
maptext_height = 26
|
||||
maptext_width = 32
|
||||
var/obj/effect/overlay/status_display_text/message1_overlay
|
||||
var/obj/effect/overlay/status_display_text/message2_overlay
|
||||
var/current_picture = ""
|
||||
var/current_mode = SD_BLANK
|
||||
var/message1 = ""
|
||||
var/message2 = ""
|
||||
|
||||
var/message1 = "" // message line 1
|
||||
var/message2 = "" // message line 2
|
||||
var/index1 // display index for scrolling messages or 0 if non-scrolling
|
||||
var/index2
|
||||
/obj/item/wallframe/status_display
|
||||
name = "status display frame"
|
||||
desc = "Used to build status displays, just secure to the wall."
|
||||
icon_state = "unanchoredstatusdisplay"
|
||||
custom_materials = list(/datum/material/iron=14000, /datum/material/glass=8000)
|
||||
result_path = /obj/machinery/status_display/evac
|
||||
pixel_shift = -32
|
||||
|
||||
/// Immediately blank the display.
|
||||
/obj/machinery/status_display/proc/remove_display()
|
||||
cut_overlays()
|
||||
if(maptext)
|
||||
maptext = ""
|
||||
/obj/machinery/status_display/wrench_act(mob/living/user, obj/item/tool)
|
||||
. = ..()
|
||||
balloon_alert(user, "[anchored ? "un" : ""]securing...")
|
||||
tool.play_tool_sound(src)
|
||||
if(tool.use_tool(src, user, 6 SECONDS))
|
||||
playsound(loc, 'sound/items/deconstruct.ogg', 50, TRUE)
|
||||
balloon_alert(user, "[anchored ? "un" : ""]secured")
|
||||
deconstruct()
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/status_display/welder_act(mob/living/user, obj/item/tool)
|
||||
if(user.a_intent == INTENT_HARM)
|
||||
return
|
||||
if(obj_integrity >= max_integrity)
|
||||
balloon_alert(user, "it doesn't need repairs!")
|
||||
return TRUE
|
||||
user.balloon_alert_to_viewers("repairing display...", "repairing...")
|
||||
if(!tool.use_tool(src, user, 4 SECONDS, amount = 0, volume=50))
|
||||
return TRUE
|
||||
balloon_alert(user, "repaired")
|
||||
obj_integrity = max_integrity
|
||||
set_machine_stat(stat & ~BROKEN)
|
||||
update_appearance()
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/status_display/deconstruct(disassembled = TRUE)
|
||||
if(flags_1 & NODECONSTRUCT_1)
|
||||
return
|
||||
if(!disassembled)
|
||||
new /obj/item/stack/sheet/metal(drop_location(), 2)
|
||||
new /obj/item/shard(drop_location())
|
||||
new /obj/item/shard(drop_location())
|
||||
else
|
||||
new /obj/item/wallframe/status_display(drop_location())
|
||||
qdel(src)
|
||||
|
||||
/// Immediately change the display to the given picture.
|
||||
/obj/machinery/status_display/proc/set_picture(state)
|
||||
remove_display()
|
||||
add_overlay(state)
|
||||
if(state != current_picture)
|
||||
current_picture = state
|
||||
|
||||
update_appearance()
|
||||
|
||||
/// Immediately change the display to the given two lines.
|
||||
/obj/machinery/status_display/proc/update_display(line1, line2)
|
||||
var/new_text = {"<div style="font-size:[FONT_SIZE];color:[FONT_COLOR];font:'[FONT_STYLE]';text-align:center;" valign="top">[line1]<br>[line2]</div>"}
|
||||
if(maptext != new_text)
|
||||
maptext = new_text
|
||||
/obj/machinery/status_display/proc/set_messages(line1, line2)
|
||||
line1 = uppertext(line1)
|
||||
line2 = uppertext(line2)
|
||||
|
||||
/// Prepare the display to marquee the given two lines.
|
||||
///
|
||||
/// Call with no arguments to disable.
|
||||
/obj/machinery/status_display/proc/set_message(m1, m2)
|
||||
if(m1)
|
||||
index1 = (length_char(m1) > CHARS_PER_LINE)
|
||||
message1 = m1
|
||||
else
|
||||
message1 = ""
|
||||
index1 = 0
|
||||
if(line1 != message1)
|
||||
message1 = line1
|
||||
|
||||
if(m2)
|
||||
index2 = (length_char(m2) > CHARS_PER_LINE)
|
||||
message2 = m2
|
||||
else
|
||||
message2 = ""
|
||||
index2 = 0
|
||||
if(line2 != message2)
|
||||
message2 = line2
|
||||
|
||||
// Timed process - performs default marquee action if so needed.
|
||||
update_appearance()
|
||||
|
||||
/**
|
||||
* Remove both message objs and null the fields.
|
||||
* Don't call this in subclasses.
|
||||
*/
|
||||
/obj/machinery/status_display/proc/remove_messages()
|
||||
if(message1_overlay)
|
||||
QDEL_NULL(message1_overlay)
|
||||
if(message2_overlay)
|
||||
QDEL_NULL(message2_overlay)
|
||||
|
||||
/**
|
||||
* Create/update message overlay.
|
||||
* They must be handled as real objects for the animation to run.
|
||||
* Don't call this in subclasses.
|
||||
* Arguments:
|
||||
* * overlay - the current /obj/effect/overlay/status_display_text instance
|
||||
* * line_y - The Y offset to render the text.
|
||||
* * message - the new message text.
|
||||
* Returns new /obj/effect/overlay/status_display_text or null if unchanged.
|
||||
*/
|
||||
/obj/machinery/status_display/proc/update_message(obj/effect/overlay/status_display_text/overlay, line_y, message)
|
||||
if(overlay && message == overlay.message)
|
||||
return null
|
||||
|
||||
if(overlay)
|
||||
qdel(overlay)
|
||||
|
||||
var/obj/effect/overlay/status_display_text/new_status_display_text = new(src, line_y, message)
|
||||
vis_contents += new_status_display_text
|
||||
return new_status_display_text
|
||||
|
||||
/obj/machinery/status_display/update_appearance(updates=ALL)
|
||||
. = ..()
|
||||
if( \
|
||||
(stat & (NOPOWER|BROKEN)) || \
|
||||
(current_mode == SD_BLANK) || \
|
||||
(current_mode != SD_PICTURE && message1 == "" && message2 == "") \
|
||||
)
|
||||
set_light(0)
|
||||
return
|
||||
set_light(1.4, 0.7, LIGHT_COLOR_BLUE) // blue light
|
||||
|
||||
/obj/machinery/status_display/update_overlays()
|
||||
. = ..()
|
||||
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
remove_messages()
|
||||
return
|
||||
|
||||
switch(current_mode)
|
||||
if(SD_BLANK)
|
||||
remove_messages()
|
||||
// Turn off backlight.
|
||||
return
|
||||
if(SD_PICTURE)
|
||||
remove_messages()
|
||||
. += mutable_appearance(icon, current_picture)
|
||||
else
|
||||
var/overlay = update_message(message1_overlay, LINE1_Y, message1)
|
||||
if(overlay)
|
||||
message1_overlay = overlay
|
||||
overlay = update_message(message2_overlay, LINE2_Y, message2)
|
||||
if(overlay)
|
||||
message2_overlay = overlay
|
||||
|
||||
// Turn off backlight if message is blank
|
||||
if(message1 == "" && message2 == "")
|
||||
return
|
||||
|
||||
. += emissive_appearance(icon, "outline", alpha = src.alpha)
|
||||
|
||||
// Timed process - performs nothing in the base class
|
||||
/obj/machinery/status_display/process()
|
||||
if(stat & NOPOWER)
|
||||
// No power, no processing.
|
||||
remove_display()
|
||||
return PROCESS_KILL
|
||||
update_appearance()
|
||||
|
||||
var/line1 = message1
|
||||
if(index1)
|
||||
line1 = copytext_char("[message1]|[message1]", index1, index1+CHARS_PER_LINE)
|
||||
var/message1_len = length_char(message1)
|
||||
index1 += SCROLL_SPEED
|
||||
if(index1 > message1_len + 1)
|
||||
index1 -= (message1_len + 1)
|
||||
|
||||
var/line2 = message2
|
||||
if(index2)
|
||||
line2 = copytext_char("[message2]|[message2]", index2, index2+CHARS_PER_LINE)
|
||||
var/message2_len = length(message2)
|
||||
index2 += SCROLL_SPEED
|
||||
if(index2 > message2_len + 1)
|
||||
index2 -= (message2_len + 1)
|
||||
|
||||
update_display(line1, line2)
|
||||
if (!index1 && !index2)
|
||||
// No marquee, no processing.
|
||||
return PROCESS_KILL
|
||||
return PROCESS_KILL
|
||||
|
||||
/// Update the display and, if necessary, re-enable processing.
|
||||
/obj/machinery/status_display/proc/update()
|
||||
if (process() != PROCESS_KILL)
|
||||
if (process(SSMACHINES_DT) != PROCESS_KILL)
|
||||
START_PROCESSING(SSmachines, src)
|
||||
|
||||
/obj/machinery/status_display/power_change()
|
||||
@@ -110,22 +190,23 @@
|
||||
. = ..()
|
||||
if(stat & (NOPOWER|BROKEN) || . & EMP_PROTECT_SELF)
|
||||
return
|
||||
current_mode = SD_PICTURE
|
||||
set_picture("ai_bsod")
|
||||
|
||||
/obj/machinery/status_display/examine(mob/user)
|
||||
. = ..()
|
||||
if (message1 || message2)
|
||||
if (current_mode == SD_MESSAGE && (message1_overlay?.message || message2_overlay?.message))
|
||||
. += "The display says:"
|
||||
if (message1)
|
||||
. += "\t<tt>[html_encode(message1)]</tt>"
|
||||
if (message2)
|
||||
. += "\t<tt>[html_encode(message2)]</tt>"
|
||||
if (message1_overlay.message)
|
||||
. += "\t<tt>[html_encode(message1_overlay.message)]</tt>"
|
||||
if (message2_overlay.message)
|
||||
. += "\t<tt>[html_encode(message2_overlay.message)]</tt>"
|
||||
|
||||
// Helper procs for child display types.
|
||||
/obj/machinery/status_display/proc/display_shuttle_status(obj/docking_port/mobile/shuttle)
|
||||
if(!shuttle)
|
||||
// the shuttle is missing - no processing
|
||||
update_display("shutl?","")
|
||||
set_messages("shutl?","")
|
||||
return PROCESS_KILL
|
||||
else if(shuttle.timer)
|
||||
var/line1 = "-[shuttle.getModeStr()]-"
|
||||
@@ -133,10 +214,10 @@
|
||||
|
||||
if(length_char(line2) > CHARS_PER_LINE)
|
||||
line2 = "error"
|
||||
update_display(line1, line2)
|
||||
set_messages(line1, line2)
|
||||
else
|
||||
// don't kill processing, the timer might turn back on
|
||||
remove_display()
|
||||
set_messages("", "")
|
||||
|
||||
/obj/machinery/status_display/proc/examine_shuttle(mob/user, obj/docking_port/mobile/shuttle)
|
||||
if (shuttle)
|
||||
@@ -150,18 +231,75 @@
|
||||
else
|
||||
return "The display says:<br>\t<tt>Shuttle missing!</tt>"
|
||||
|
||||
/obj/machinery/status_display/Destroy()
|
||||
remove_messages()
|
||||
return ..()
|
||||
|
||||
/**
|
||||
* Nice overlay to make text smoothly scroll with no client updates after setup.
|
||||
*/
|
||||
/obj/effect/overlay/status_display_text
|
||||
icon = 'icons/obj/status_display.dmi'
|
||||
vis_flags = VIS_INHERIT_LAYER | VIS_INHERIT_PLANE | VIS_INHERIT_ID
|
||||
|
||||
var/message
|
||||
|
||||
/obj/effect/overlay/status_display_text/Initialize(mapload, yoffset, line)
|
||||
. = ..()
|
||||
|
||||
maptext_y = yoffset
|
||||
message = line
|
||||
|
||||
var/line_length = length_char(line)
|
||||
|
||||
if(line_length > CHARS_PER_LINE)
|
||||
// Marquee text
|
||||
var/marquee_message = "[line] • [line] • [line]"
|
||||
var/marquee_length = line_length * 3 + 6
|
||||
maptext = generate_text(marquee_message, center = FALSE)
|
||||
maptext_width = 6 * marquee_length
|
||||
maptext_x = 32
|
||||
|
||||
// Mask off to fit in screen.
|
||||
add_filter("mask", 1, alpha_mask_filter(icon = icon(icon, "outline")))
|
||||
|
||||
// Scroll.
|
||||
var/width = 4 * marquee_length
|
||||
var/time = (width + 32) * SCROLL_RATE
|
||||
animate(src, maptext_x = -width, time = time, loop = -1)
|
||||
animate(maptext_x = 32, time = 0)
|
||||
else
|
||||
// Centered text
|
||||
maptext = generate_text(line, center = TRUE)
|
||||
maptext_x = 0
|
||||
|
||||
/obj/effect/overlay/status_display_text/proc/generate_text(text, center)
|
||||
return {"<div style="font-size:[FONT_SIZE];color:[FONT_COLOR];font:'[FONT_STYLE]'[center ? ";text-align:center" : ""]" valign="top">[text]</div>"}
|
||||
|
||||
/// Evac display which shows shuttle timer or message set by Command.
|
||||
/obj/machinery/status_display/evac
|
||||
current_mode = SD_EMERGENCY
|
||||
var/frequency = FREQ_STATUS_DISPLAYS
|
||||
var/mode = SD_EMERGENCY
|
||||
var/friendc = FALSE // track if Friend Computer mode
|
||||
var/last_picture // For when Friend Computer mode is undone
|
||||
|
||||
/obj/machinery/status_display/evac/Initialize()
|
||||
// MAPPING_DIRECTIONAL_HELPERS(/obj/machinery/status_display/evac, 32)
|
||||
|
||||
//makes it go on the wall when built
|
||||
/obj/machinery/status_display/Initialize(mapload, ndir, building)
|
||||
. = ..()
|
||||
update_appearance()
|
||||
|
||||
/obj/machinery/status_display/evac/Initialize(mapload)
|
||||
. = ..()
|
||||
// register for radio system
|
||||
SSradio.add_object(src, frequency)
|
||||
// Circuit USB
|
||||
/*
|
||||
AddComponent(/datum/component/usb_port, list(
|
||||
/obj/item/circuit_component/status_display,
|
||||
))
|
||||
*/
|
||||
|
||||
/obj/machinery/status_display/evac/Destroy()
|
||||
SSradio.remove_object(src,frequency)
|
||||
@@ -170,23 +308,23 @@
|
||||
/obj/machinery/status_display/evac/process()
|
||||
if(stat & NOPOWER)
|
||||
// No power, no processing.
|
||||
remove_display()
|
||||
update_appearance()
|
||||
return PROCESS_KILL
|
||||
|
||||
if(friendc) //Makes all status displays except supply shuttle timer display the eye -- Urist
|
||||
current_mode = SD_PICTURE
|
||||
set_picture("ai_friend")
|
||||
return PROCESS_KILL
|
||||
|
||||
switch(mode)
|
||||
switch(current_mode)
|
||||
if(SD_BLANK)
|
||||
remove_display()
|
||||
return PROCESS_KILL
|
||||
|
||||
if(SD_EMERGENCY)
|
||||
return display_shuttle_status(SSshuttle.emergency)
|
||||
|
||||
if(SD_MESSAGE)
|
||||
return ..()
|
||||
return PROCESS_KILL
|
||||
|
||||
if(SD_PICTURE)
|
||||
set_picture(last_picture)
|
||||
@@ -194,7 +332,7 @@
|
||||
|
||||
/obj/machinery/status_display/evac/examine(mob/user)
|
||||
. = ..()
|
||||
if(mode == SD_EMERGENCY)
|
||||
if(current_mode == SD_EMERGENCY)
|
||||
. += examine_shuttle(user, SSshuttle.emergency)
|
||||
else if(!message1 && !message2)
|
||||
. += "The display is blank."
|
||||
@@ -202,16 +340,16 @@
|
||||
/obj/machinery/status_display/evac/receive_signal(datum/signal/signal)
|
||||
switch(signal.data["command"])
|
||||
if("blank")
|
||||
mode = SD_BLANK
|
||||
set_message(null, null)
|
||||
current_mode = SD_BLANK
|
||||
update_appearance()
|
||||
if("shuttle")
|
||||
mode = SD_EMERGENCY
|
||||
set_message(null, null)
|
||||
current_mode = SD_EMERGENCY
|
||||
set_messages("", "")
|
||||
if("message")
|
||||
mode = SD_MESSAGE
|
||||
set_message(signal.data["msg1"], signal.data["msg2"])
|
||||
current_mode = SD_MESSAGE
|
||||
set_messages(signal.data["msg1"] || "", signal.data["msg2"] || "")
|
||||
if("alert")
|
||||
mode = SD_PICTURE
|
||||
current_mode = SD_PICTURE
|
||||
last_picture = signal.data["picture_state"]
|
||||
set_picture(last_picture)
|
||||
if("friendcomputer")
|
||||
@@ -222,11 +360,12 @@
|
||||
/// Supply display which shows the status of the supply shuttle.
|
||||
/obj/machinery/status_display/supply
|
||||
name = "supply display"
|
||||
current_mode = SD_MESSAGE
|
||||
|
||||
/obj/machinery/status_display/supply/process()
|
||||
if(stat & NOPOWER)
|
||||
// No power, no processing.
|
||||
remove_display()
|
||||
update_appearance()
|
||||
return PROCESS_KILL
|
||||
|
||||
var/line1
|
||||
@@ -240,12 +379,15 @@
|
||||
if(is_station_level(SSshuttle.supply.z))
|
||||
line1 = "CARGO"
|
||||
line2 = "Docked"
|
||||
else
|
||||
line1 = ""
|
||||
line2 = ""
|
||||
else
|
||||
line1 = "CARGO"
|
||||
line2 = SSshuttle.supply.getTimerStr()
|
||||
if(length_char(line2) > CHARS_PER_LINE)
|
||||
line2 = "Error"
|
||||
update_display(line1, line2)
|
||||
set_messages(line1, line2)
|
||||
|
||||
/obj/machinery/status_display/supply/examine(mob/user)
|
||||
. = ..()
|
||||
@@ -265,12 +407,13 @@
|
||||
/// General-purpose shuttle status display.
|
||||
/obj/machinery/status_display/shuttle
|
||||
name = "shuttle display"
|
||||
current_mode = SD_MESSAGE
|
||||
var/shuttle_id
|
||||
|
||||
/obj/machinery/status_display/shuttle/process()
|
||||
if(!shuttle_id || (stat & NOPOWER))
|
||||
// No power, no processing.
|
||||
remove_display()
|
||||
update_appearance()
|
||||
return PROCESS_KILL
|
||||
|
||||
return display_shuttle_status(SSshuttle.getShuttle(shuttle_id))
|
||||
@@ -291,7 +434,7 @@
|
||||
update()
|
||||
|
||||
/obj/machinery/status_display/shuttle/connect_to_shuttle(obj/docking_port/mobile/port, obj/docking_port/stationary/dock, idnum, override)
|
||||
if (port && (shuttle_id == initial(shuttle_id) || override))
|
||||
if(port && (shuttle_id == initial(shuttle_id) || override))
|
||||
shuttle_id = port.id
|
||||
update()
|
||||
|
||||
@@ -300,11 +443,34 @@
|
||||
/obj/machinery/status_display/ai
|
||||
name = "\improper AI display"
|
||||
desc = "A small screen which the AI can use to present itself."
|
||||
current_mode = SD_PICTURE
|
||||
|
||||
var/mode = SD_BLANK
|
||||
var/emotion = "Neutral"
|
||||
var/emotion = AI_EMOTION_BLANK
|
||||
|
||||
/obj/machinery/status_display/ai/Initialize()
|
||||
/// A mapping between AI_EMOTION_* string constants, which also double as user readable descriptions, and the name of the iconfile.
|
||||
var/static/list/emotion_map = list(
|
||||
AI_EMOTION_BLANK = "ai_off",
|
||||
AI_EMOTION_VERY_HAPPY = "ai_veryhappy",
|
||||
AI_EMOTION_HAPPY = "ai_happy",
|
||||
AI_EMOTION_NEUTRAL = "ai_neutral",
|
||||
AI_EMOTION_UNSURE = "ai_unsure",
|
||||
AI_EMOTION_CONFUSED = "ai_confused",
|
||||
AI_EMOTION_SAD = "ai_sad",
|
||||
AI_EMOTION_BSOD = "ai_bsod",
|
||||
AI_EMOTION_PROBLEMS = "ai_trollface",
|
||||
AI_EMOTION_AWESOME = "ai_awesome",
|
||||
AI_EMOTION_DORFY = "ai_urist",
|
||||
AI_EMOTION_THINKING = "ai_thinking",
|
||||
AI_EMOTION_FACEPALM = "ai_facepalm",
|
||||
AI_EMOTION_FRIEND_COMPUTER = "ai_friend",
|
||||
AI_EMOTION_BLUE_GLOW = "ai_sal",
|
||||
AI_EMOTION_RED_GLOW = "ai_hal",
|
||||
)
|
||||
|
||||
|
||||
// MAPPING_DIRECTIONAL_HELPERS(/obj/machinery/status_display/ai, 32)
|
||||
|
||||
/obj/machinery/status_display/ai/Initialize(mapload)
|
||||
. = ..()
|
||||
GLOB.ai_status_displays.Add(src)
|
||||
|
||||
@@ -313,57 +479,109 @@
|
||||
. = ..()
|
||||
|
||||
/obj/machinery/status_display/ai/attack_ai(mob/living/silicon/ai/user)
|
||||
if(isAI(user))
|
||||
user.ai_statuschange()
|
||||
if(!isAI(user))
|
||||
return
|
||||
var/list/choices = list()
|
||||
for(var/emotion_const in emotion_map)
|
||||
var/icon_state = emotion_map[emotion_const]
|
||||
choices[emotion_const] = image(icon = 'icons/obj/status_display.dmi', icon_state = icon_state)
|
||||
|
||||
var/emotion_result = show_radial_menu(user, src, choices, tooltips = TRUE)
|
||||
for(var/_emote in typesof(/datum/emote/ai/emotion_display))
|
||||
var/datum/emote/ai/emotion_display/emote = _emote
|
||||
if(initial(emote.emotion) == emotion_result)
|
||||
user.emote(initial(emote.key))
|
||||
break
|
||||
|
||||
/obj/machinery/status_display/ai/process()
|
||||
if(mode == SD_BLANK || (stat & NOPOWER))
|
||||
remove_display()
|
||||
if(stat & NOPOWER)
|
||||
update_appearance()
|
||||
return PROCESS_KILL
|
||||
|
||||
if(mode == SD_AI_EMOTE)
|
||||
switch(emotion)
|
||||
if("Very Happy")
|
||||
set_picture("ai_veryhappy")
|
||||
if("Happy")
|
||||
set_picture("ai_happy")
|
||||
if("Neutral")
|
||||
set_picture("ai_neutral")
|
||||
if("Unsure")
|
||||
set_picture("ai_unsure")
|
||||
if("Confused")
|
||||
set_picture("ai_confused")
|
||||
if("Sad")
|
||||
set_picture("ai_sad")
|
||||
if("BSOD")
|
||||
set_picture("ai_bsod")
|
||||
if("Blank")
|
||||
set_picture("ai_off")
|
||||
if("Problems?")
|
||||
set_picture("ai_trollface")
|
||||
if("Awesome")
|
||||
set_picture("ai_awesome")
|
||||
if("Dorfy")
|
||||
set_picture("ai_urist")
|
||||
if("Thinking")
|
||||
set_picture("ai_thinking")
|
||||
if("Facepalm")
|
||||
set_picture("ai_facepalm")
|
||||
if("Friend Computer")
|
||||
set_picture("ai_friend")
|
||||
if("Blue Glow")
|
||||
set_picture("ai_sal")
|
||||
if("Red Glow")
|
||||
set_picture("ai_hal")
|
||||
return PROCESS_KILL
|
||||
set_picture(emotion_map[emotion])
|
||||
return PROCESS_KILL
|
||||
|
||||
if(mode == SD_AI_BSOD)
|
||||
set_picture("ai_bsod")
|
||||
return PROCESS_KILL
|
||||
/*
|
||||
/obj/item/circuit_component/status_display
|
||||
display_name = "Status Display"
|
||||
desc = "Output text and pictures to a status display."
|
||||
circuit_flags = CIRCUIT_FLAG_INPUT_SIGNAL|CIRCUIT_FLAG_OUTPUT_SIGNAL
|
||||
|
||||
var/datum/port/input/option/command
|
||||
var/datum/port/input/option/picture
|
||||
var/datum/port/input/message1
|
||||
var/datum/port/input/message2
|
||||
|
||||
var/obj/machinery/status_display/connected_display
|
||||
|
||||
var/list/command_map
|
||||
var/list/picture_map
|
||||
|
||||
/obj/item/circuit_component/status_display/populate_ports()
|
||||
message1 = add_input_port("Message 1", PORT_TYPE_STRING)
|
||||
message2 = add_input_port("Message 2", PORT_TYPE_STRING)
|
||||
|
||||
/obj/item/circuit_component/status_display/populate_options()
|
||||
var/static/list/command_options = list(
|
||||
"Blank" = "blank",
|
||||
"Shuttle" = "shuttle",
|
||||
"Message" = "message",
|
||||
"Alert" = "alert"
|
||||
)
|
||||
|
||||
var/static/list/picture_options = list(
|
||||
"Default" = "default",
|
||||
"Red Alert" = "redalert",
|
||||
"Biohazard" = "biohazard",
|
||||
"Lockdown" = "lockdown",
|
||||
"Happy" = "ai_happy",
|
||||
"Neutral" = "ai_neutral",
|
||||
"Very Happy" = "ai_veryhappy",
|
||||
"Sad" = "ai_sad",
|
||||
"Unsure" = "ai_unsure",
|
||||
"Confused" = "ai_confused",
|
||||
"Surprised" = "ai_surprised",
|
||||
"BSOD" = "ai_bsod"
|
||||
)
|
||||
|
||||
command = add_option_port("Command", command_options)
|
||||
command_map = command_options
|
||||
|
||||
picture = add_option_port("Picture", picture_options)
|
||||
picture_map = picture_options
|
||||
|
||||
/obj/item/circuit_component/status_display/register_usb_parent(atom/movable/shell)
|
||||
. = ..()
|
||||
if(istype(shell, /obj/machinery/status_display))
|
||||
connected_display = shell
|
||||
|
||||
/obj/item/circuit_component/status_display/unregister_usb_parent(atom/movable/parent)
|
||||
connected_display = null
|
||||
return ..()
|
||||
|
||||
/obj/item/circuit_component/status_display/input_received(datum/port/input/port)
|
||||
// Just use command handling built into status display.
|
||||
// The option inputs thankfully sanitize command and picture for us.
|
||||
|
||||
if(!connected_display)
|
||||
return
|
||||
|
||||
var/command_value = command_map[command.value]
|
||||
var/datum/signal/status_signal = new(list("command" = command_value))
|
||||
switch(command_value)
|
||||
if("message")
|
||||
status_signal.data["msg1"] = message1.value
|
||||
status_signal.data["msg2"] = message2.value
|
||||
if("alert")
|
||||
status_signal.data["picture_state"] = picture_map[picture.value]
|
||||
|
||||
connected_display.receive_signal(status_signal)
|
||||
*/
|
||||
|
||||
#undef CHARS_PER_LINE
|
||||
#undef FONT_SIZE
|
||||
#undef FONT_COLOR
|
||||
#undef FONT_STYLE
|
||||
#undef SCROLL_SPEED
|
||||
#undef SCROLL_RATE
|
||||
#undef LINE1_Y
|
||||
#undef LINE2_Y
|
||||
|
||||
@@ -120,7 +120,7 @@
|
||||
state_open = TRUE
|
||||
density = FALSE
|
||||
|
||||
/obj/machinery/suit_storage_unit/Initialize()
|
||||
/obj/machinery/suit_storage_unit/Initialize(mapload)
|
||||
. = ..()
|
||||
wires = new /datum/wires/suit_storage_unit(src)
|
||||
if(suit_type)
|
||||
|
||||
@@ -84,7 +84,7 @@
|
||||
countdown.stop()
|
||||
STOP_PROCESSING(SSfastprocess, src)
|
||||
|
||||
/obj/machinery/syndicatebomb/Initialize()
|
||||
/obj/machinery/syndicatebomb/Initialize(mapload)
|
||||
. = ..()
|
||||
wires = new /datum/wires/syndicatebomb(src)
|
||||
if(payload)
|
||||
@@ -242,7 +242,7 @@
|
||||
open_panel = TRUE
|
||||
timer_set = 120
|
||||
|
||||
/obj/machinery/syndicatebomb/empty/Initialize()
|
||||
/obj/machinery/syndicatebomb/empty/Initialize(mapload)
|
||||
. = ..()
|
||||
wires.cut_all()
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
flags_1 = NODECONSTRUCT_1
|
||||
|
||||
/obj/machinery/telecomms/allinone/Initialize()
|
||||
/obj/machinery/telecomms/allinone/Initialize(mapload)
|
||||
. = ..()
|
||||
if (intercept)
|
||||
freq_listening = list(FREQ_SYNDICATE)
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
freq_listening = list(FREQ_ENGINEERING)
|
||||
autolinkers = list("processor4", "engineering", "common")
|
||||
|
||||
/obj/machinery/telecomms/bus/preset_four/Initialize()
|
||||
/obj/machinery/telecomms/bus/preset_four/Initialize(mapload)
|
||||
. = ..()
|
||||
for(var/i = MIN_FREQ, i <= MAX_FREQ, i += 2)
|
||||
freq_listening |= i
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
use_power = IDLE_POWER_USE
|
||||
idle_power_usage = 10
|
||||
active_power_usage = 100
|
||||
armor = list("melee" = 25, "bullet" = 10, "laser" = 10, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 70)
|
||||
armor = list(MELEE = 25, BULLET = 10, LASER = 10, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 50, ACID = 70)
|
||||
var/obj/item/stored
|
||||
|
||||
/obj/machinery/blackbox_recorder/Initialize()
|
||||
/obj/machinery/blackbox_recorder/Initialize(mapload)
|
||||
. = ..()
|
||||
stored = new /obj/item/blackbox(src)
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
var/list/datum/data_rc_msg/rc_msgs = list()
|
||||
var/decryptkey
|
||||
|
||||
/obj/machinery/telecomms/message_server/Initialize()
|
||||
/obj/machinery/telecomms/message_server/Initialize(mapload)
|
||||
. = ..()
|
||||
if (!decryptkey)
|
||||
decryptkey = GenerateKey()
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
freq_listening = list(FREQ_COMMAND, FREQ_ENGINEERING, FREQ_SECURITY)
|
||||
|
||||
//Common and other radio frequencies for people to freely use
|
||||
/obj/machinery/telecomms/receiver/preset_right/Initialize()
|
||||
/obj/machinery/telecomms/receiver/preset_right/Initialize(mapload)
|
||||
. = ..()
|
||||
for(var/i = MIN_FREQ, i <= MAX_FREQ, i += 2)
|
||||
freq_listening |= i
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
var/list/log_entries = list()
|
||||
var/totaltraffic = 0 // gigabytes (if > 1024, divide by 1024 -> terrabytes)
|
||||
|
||||
/obj/machinery/telecomms/server/Initialize()
|
||||
/obj/machinery/telecomms/server/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
/obj/machinery/telecomms/server/RefreshParts()
|
||||
@@ -72,7 +72,7 @@
|
||||
/obj/machinery/telecomms/server/presets
|
||||
network = "tcommsat"
|
||||
|
||||
/obj/machinery/telecomms/server/presets/Initialize()
|
||||
/obj/machinery/telecomms/server/presets/Initialize(mapload)
|
||||
. = ..()
|
||||
name = id
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
autolinkers = list("common")
|
||||
|
||||
//Common and other radio frequencies for people to freely use
|
||||
/obj/machinery/telecomms/server/presets/common/Initialize()
|
||||
/obj/machinery/telecomms/server/presets/common/Initialize(mapload)
|
||||
. = ..()
|
||||
for(var/i = MIN_FREQ, i <= MAX_FREQ, i += 2)
|
||||
freq_listening |= i
|
||||
@@ -123,6 +123,6 @@
|
||||
freq_listening = list(FREQ_SECURITY)
|
||||
autolinkers = list("security")
|
||||
|
||||
/obj/machinery/telecomms/server/presets/common/birdstation/Initialize()
|
||||
/obj/machinery/telecomms/server/presets/common/birdstation/Initialize(mapload)
|
||||
. = ..()
|
||||
freq_listening = list()
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
var/obj/machinery/teleport/station/power_station
|
||||
var/calibrated //Calibration prevents mutation
|
||||
|
||||
/obj/machinery/teleport/hub/Initialize()
|
||||
/obj/machinery/teleport/hub/Initialize(mapload)
|
||||
. = ..()
|
||||
link_power_station()
|
||||
|
||||
@@ -100,7 +100,7 @@
|
||||
/obj/machinery/teleport/hub/proc/is_ready()
|
||||
. = !panel_open && !(stat & (BROKEN|NOPOWER)) && power_station && power_station.engaged && !(power_station.stat & (BROKEN|NOPOWER))
|
||||
|
||||
/obj/machinery/teleport/hub/syndicate/Initialize()
|
||||
/obj/machinery/teleport/hub/syndicate/Initialize(mapload)
|
||||
. = ..()
|
||||
component_parts += new /obj/item/stock_parts/matter_bin/super(null)
|
||||
RefreshParts()
|
||||
@@ -120,7 +120,7 @@
|
||||
var/list/linked_stations = list()
|
||||
var/efficiency = 0
|
||||
|
||||
/obj/machinery/teleport/station/Initialize()
|
||||
/obj/machinery/teleport/station/Initialize(mapload)
|
||||
. = ..()
|
||||
link_console_and_hub()
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
var/obj/effect/countdown/transformer/countdown
|
||||
var/mob/living/silicon/ai/masterAI
|
||||
|
||||
/obj/machinery/transformer/Initialize()
|
||||
/obj/machinery/transformer/Initialize(mapload)
|
||||
// On us
|
||||
. = ..()
|
||||
new /obj/machinery/conveyor/auto(locate(x - 1, y, z), WEST)
|
||||
@@ -57,14 +57,14 @@
|
||||
AM.forceMove(drop_location())
|
||||
do_transform(AM)
|
||||
|
||||
/obj/machinery/transformer/CanPass(atom/movable/mover, turf/target)
|
||||
/obj/machinery/transformer/CanAllowThrough(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
// Allows items to go through,
|
||||
// to stop them from blocking the conveyor belt.
|
||||
if(!ishuman(mover))
|
||||
var/dir = get_dir(src, mover)
|
||||
if(dir == EAST)
|
||||
return ..()
|
||||
return 0
|
||||
if(get_dir(src, mover) == EAST)
|
||||
return
|
||||
return FALSE
|
||||
|
||||
/obj/machinery/transformer/process()
|
||||
if(cooldown && (cooldown_timer <= world.time))
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user