mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-25 04:57:12 +01:00
Merge fix
This commit is contained in:
@@ -4,3 +4,11 @@
|
||||
|
||||
/obj/effect
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
burn_state = LAVA_PROOF | FIRE_PROOF
|
||||
resistance_flags = INDESTRUCTIBLE
|
||||
|
||||
/obj/effect/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir)
|
||||
return
|
||||
|
||||
/obj/effect/fire_act()
|
||||
return
|
||||
@@ -40,6 +40,11 @@
|
||||
icon = 'icons/misc/beach.dmi'
|
||||
icon_state = "coconuts"
|
||||
|
||||
/obj/effect/overlay/sparkles
|
||||
name = "sparkles"
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
icon_state = "shieldsparkles"
|
||||
|
||||
/obj/effect/overlay/adminoverlay
|
||||
name = "adminoverlay"
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
//temporary visual effects(/obj/effect/temp_visual) used by clockcult stuff
|
||||
/obj/effect/temp_visual/ratvar
|
||||
name = "ratvar's light"
|
||||
icon = 'icons/effects/clockwork_effects.dmi'
|
||||
duration = 8
|
||||
randomdir = 0
|
||||
layer = ABOVE_NORMAL_TURF_LAYER
|
||||
|
||||
/obj/effect/temp_visual/ratvar/beam
|
||||
icon_state = "ratvarbeamglow"
|
||||
|
||||
/obj/effect/temp_visual/ratvar/beam/grille
|
||||
layer = BELOW_OBJ_LAYER
|
||||
|
||||
/obj/effect/temp_visual/ratvar/floor
|
||||
icon_state = "ratvarfloorglow"
|
||||
|
||||
/obj/effect/temp_visual/ratvar/grille
|
||||
icon_state = "ratvargrilleglow"
|
||||
layer = BELOW_OBJ_LAYER
|
||||
|
||||
/obj/effect/temp_visual/ratvar/grille/broken
|
||||
icon_state = "ratvarbrokengrilleglow"
|
||||
@@ -80,9 +80,9 @@
|
||||
if(T.density && T.explosion_block)
|
||||
cached_exp_block[T] += T.explosion_block
|
||||
|
||||
for(var/obj/machinery/door/D in T)
|
||||
if(D.density && D.explosion_block)
|
||||
cached_exp_block[T] += D.explosion_block
|
||||
for(var/obj/O in T)
|
||||
var/the_block = O.explosion_block
|
||||
cached_exp_block[T] += the_block == EXPLOSION_BLOCK_PROC ? O.GetExplosionBlock() : the_block
|
||||
CHECK_TICK
|
||||
|
||||
for(var/A in affected_turfs)
|
||||
@@ -212,12 +212,12 @@
|
||||
var/turf/TT = T
|
||||
while(TT != epicenter)
|
||||
TT = get_step_towards(TT,epicenter)
|
||||
if(TT.density && TT.explosion_block)
|
||||
if(TT.density)
|
||||
dist += TT.explosion_block
|
||||
|
||||
for(var/obj/machinery/door/D in TT)
|
||||
if(D.density && D.explosion_block)
|
||||
dist += D.explosion_block
|
||||
for(var/obj/O in T)
|
||||
var/the_block = O.explosion_block
|
||||
dist += the_block == EXPLOSION_BLOCK_PROC ? O.GetExplosionBlock() : the_block
|
||||
|
||||
if(dist < dev)
|
||||
T.color = "red"
|
||||
|
||||
@@ -44,7 +44,6 @@ var/global/image/fire_overlay = image("icon" = 'icons/goonstation/effects/fire.d
|
||||
var/permeability_coefficient = 1 // for chemicals/diseases
|
||||
var/siemens_coefficient = 1 // for electrical admittance/conductance (electrocution checks and shit)
|
||||
var/slowdown = 0 // How much clothing is slowing you down. Negative values speeds you up
|
||||
var/armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0)
|
||||
var/armour_penetration = 0 //percentage of armour effectiveness to remove
|
||||
var/list/allowed = null //suit storage stuff.
|
||||
var/obj/item/device/uplink/hidden/hidden_uplink = null // All items can have an uplink hidden inside, just remember to add the triggers.
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
|
||||
|
||||
/obj/item/device/aicard/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/datum/topic_state/state = inventory_state)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "aicard.tmpl", "[name]", 600, 400, state = state)
|
||||
ui.open()
|
||||
|
||||
@@ -284,3 +284,19 @@ obj/item/device/flashlight/lamp/bananalamp
|
||||
else
|
||||
to_chat(user, "<span class='warning'>\The [src] needs time to recharge!</span>")
|
||||
return
|
||||
|
||||
/obj/item/device/flashlight/spotlight //invisible lighting source
|
||||
name = "disco light"
|
||||
desc = "Groovy..."
|
||||
icon_state = null
|
||||
light_color = null
|
||||
brightness_on = 0
|
||||
light_range = 0
|
||||
light_power = 10
|
||||
alpha = 0
|
||||
layer = 0
|
||||
on = TRUE
|
||||
anchored = TRUE
|
||||
var/range = null
|
||||
unacidable = TRUE
|
||||
burn_state = LAVA_PROOF
|
||||
@@ -99,7 +99,7 @@
|
||||
|
||||
|
||||
/obj/item/device/radio/electropack/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "radio_electro.tmpl", "[name]", 400, 500)
|
||||
ui.open()
|
||||
|
||||
@@ -107,7 +107,7 @@ var/global/list/default_medbay_channels = list(
|
||||
return ui_interact(user)
|
||||
|
||||
/obj/item/device/radio/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "radio_basic.tmpl", "[name]", 400, 550)
|
||||
ui.open()
|
||||
@@ -793,7 +793,7 @@ var/global/list/default_medbay_channels = list(
|
||||
. = ..()
|
||||
|
||||
/obj/item/device/radio/borg/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "radio_basic.tmpl", "[name]", 430, 500)
|
||||
ui.open()
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
w_class = I.w_class
|
||||
|
||||
update_icon()
|
||||
nanomanager.update_uis(src) // update all UIs attached to src
|
||||
SSnanoui.update_uis(src) // update all UIs attached to src
|
||||
//TODO: Have this take an assemblyholder
|
||||
else if(isassembly(I))
|
||||
var/obj/item/device/assembly/A = I
|
||||
@@ -67,7 +67,7 @@
|
||||
msg_admin_attack("[key_name_admin(user)]attached [A] to a transfer valve.")
|
||||
log_game("[key_name_admin(user)] attached [A] to a transfer valve.")
|
||||
attacher = user
|
||||
nanomanager.update_uis(src) // update all UIs attached to src
|
||||
SSnanoui.update_uis(src) // update all UIs attached to src
|
||||
|
||||
|
||||
/obj/item/device/transfer_valve/HasProximity(atom/movable/AM)
|
||||
@@ -90,7 +90,7 @@
|
||||
|
||||
/obj/item/device/transfer_valve/ui_interact(mob/user, ui_key = "main", datum/nanoui/ui = null, force_open = 1)
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -129,7 +129,7 @@ var/list/world_uplinks = list()
|
||||
if(!UI)
|
||||
return
|
||||
UI.buy(src,usr)
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
/* var/list/L = UI.spawn_item(get_turf(usr),src)
|
||||
if(ishuman(usr))
|
||||
@@ -190,7 +190,7 @@ var/list/world_uplinks = list()
|
||||
/obj/item/device/uplink/hidden/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/datum/topic_state/state = inventory_state)
|
||||
var/title = "Remote Uplink"
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
@@ -224,7 +224,7 @@ var/list/world_uplinks = list()
|
||||
if(!( istype(usr, /mob/living/carbon/human)))
|
||||
return 1
|
||||
var/mob/user = usr
|
||||
var/datum/nanoui/ui = nanomanager.get_open_ui(user, src, "main")
|
||||
var/datum/nanoui/ui = SSnanoui.get_open_ui(user, src, "main")
|
||||
if((usr.contents.Find(src.loc) || (in_range(src.loc, usr) && istype(src.loc.loc, /turf))))
|
||||
usr.set_machine(src)
|
||||
if(..(href, href_list))
|
||||
@@ -246,7 +246,7 @@ var/list/world_uplinks = list()
|
||||
show_descriptions = !show_descriptions
|
||||
update_nano_data()
|
||||
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
return 1
|
||||
|
||||
/obj/item/device/uplink/hidden/proc/update_nano_data(var/id)
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
/obj/item/flag
|
||||
name = "flag"
|
||||
desc = "It's a flag."
|
||||
icon = 'icons/obj/flag.dmi'
|
||||
icon_state = "ntflag"
|
||||
lefthand_file = 'icons/mob/inhands/flags_lefthand.dmi'
|
||||
@@ -6,13 +8,19 @@
|
||||
w_class = WEIGHT_CLASS_BULKY
|
||||
burntime = 20
|
||||
burn_state = FLAMMABLE
|
||||
var/rolled = FALSE
|
||||
|
||||
/obj/item/flag/attackby(obj/item/weapon/W, mob/user, params)
|
||||
..()
|
||||
if(is_hot(W) && burn_state != ON_FIRE)
|
||||
user.visible_message("<span class='notice'>[user] lights the [name] with [W].</span>")
|
||||
user.visible_message("<span class='notice'>[user] lights [src] with [W].</span>", "<span class='notice'>You light [src] with [W].</span>", "<span class='warning'>You hear a low whoosh.</span>")
|
||||
fire_act()
|
||||
|
||||
/obj/item/flag/attack_self(mob/user)
|
||||
rolled = !rolled
|
||||
user.visible_message("<span class='notice'>[user] [rolled ? "rolls up" : "unfurls"] [src].</span>", "<span class='notice'>You [rolled ? "roll up" : "unfurl"] [src].</span>", "<span class='warning'>You hear fabric rustling.</span>")
|
||||
update_icon()
|
||||
|
||||
/obj/item/flag/fire_act(global_overlay = FALSE)
|
||||
..()
|
||||
update_icon()
|
||||
@@ -23,16 +31,24 @@
|
||||
|
||||
/obj/item/flag/update_icon()
|
||||
overlays.Cut()
|
||||
updateFlagIcon()
|
||||
item_state = icon_state
|
||||
if(rolled)
|
||||
icon_state = "[icon_state]_rolled"
|
||||
if(burn_state == ON_FIRE)
|
||||
item_state = "[item_state]_fire"
|
||||
if(burn_state == ON_FIRE && rolled)
|
||||
overlays += image('icons/obj/flag.dmi', src , "fire_rolled")
|
||||
else if(burn_state == ON_FIRE && !rolled)
|
||||
overlays += image('icons/obj/flag.dmi', src , "fire")
|
||||
item_state = "[icon_state]_fire"
|
||||
else
|
||||
item_state = initial(icon_state)
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_r_hand()
|
||||
M.update_inv_l_hand()
|
||||
|
||||
/obj/item/flag/proc/updateFlagIcon()
|
||||
icon_state = initial(icon_state)
|
||||
|
||||
/obj/item/flag/nt
|
||||
name = "Nanotrasen flag"
|
||||
desc = "A flag proudly boasting the logo of NT."
|
||||
@@ -187,11 +203,16 @@
|
||||
desc = "A poor recreation of the official NT flag. It seems to shimmer a little."
|
||||
icon_state = "ntflag"
|
||||
origin_tech = "syndicate=4;magnets=4"
|
||||
var/used = 0
|
||||
var/updated_icon_state = null
|
||||
var/used = FALSE
|
||||
|
||||
/obj/item/flag/chameleon/New()
|
||||
updated_icon_state = icon_state
|
||||
..()
|
||||
|
||||
/obj/item/flag/chameleon/attack_self(mob/user)
|
||||
if(used)
|
||||
return
|
||||
return ..()
|
||||
|
||||
var/list/flag_types = typesof(/obj/item/flag) - list(src.type, /obj/item/flag)
|
||||
var/list/flag = list()
|
||||
@@ -208,12 +229,16 @@
|
||||
|
||||
var/obj/item/flag/chosen_flag = flag[input_flag]
|
||||
|
||||
if(chosen_flag)
|
||||
if(chosen_flag && !used)
|
||||
name = chosen_flag.name
|
||||
icon_state = chosen_flag.icon_state
|
||||
updated_icon_state = icon_state
|
||||
desc = chosen_flag.desc
|
||||
used = 1
|
||||
used = TRUE
|
||||
|
||||
/obj/item/flag/chameleon/burn()
|
||||
explosion(loc,1,2,4,4, flame_range = 4)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/flag/chameleon/updateFlagIcon()
|
||||
icon_state = updated_icon_state
|
||||
|
||||
@@ -34,6 +34,7 @@
|
||||
R.notify_ai(2)
|
||||
|
||||
R.uneq_all()
|
||||
R.sight_mode = null
|
||||
R.hands.icon_state = "nomod"
|
||||
R.icon_state = "robot"
|
||||
R.module.remove_subsystems_and_actions(R)
|
||||
|
||||
@@ -271,7 +271,6 @@
|
||||
created_window = /obj/structure/window/plasmabasic
|
||||
full_window = /obj/structure/window/full/plasmabasic
|
||||
|
||||
|
||||
/obj/item/stack/sheet/plasmaglass/attack_self(mob/user as mob)
|
||||
construct_window(user)
|
||||
|
||||
@@ -359,7 +358,7 @@
|
||||
origin_tech = "plasmatech=2;materials=2"
|
||||
created_window = /obj/structure/window/plasmareinforced
|
||||
full_window = /obj/structure/window/full/plasmareinforced
|
||||
|
||||
armor = list("melee" = 20, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0)
|
||||
|
||||
/obj/item/stack/sheet/plasmarglass/attack_self(mob/user as mob)
|
||||
construct_window(user)
|
||||
|
||||
@@ -97,14 +97,14 @@ var/global/list/datum/stack_recipe/abductor_recipes = list ( \
|
||||
new/datum/stack_recipe("alien bed", /obj/structure/stool/bed/abductor, 2, one_per_turf = 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("alien locker", /obj/structure/closet/abductor, 1, time = 15, one_per_turf = 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("alien table frame", /obj/structure/table_frame/abductor, 1, time = 15, one_per_turf = 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("alien airlock assembly", /obj/structure/door_assembly/door_assembly_abductor, 4, time = 20, one_per_turf = 1, on_floor = 1), \
|
||||
null, \
|
||||
new/datum/stack_recipe("alien floor tile", /obj/item/stack/tile/mineral/abductor, 1, 4, 20), \
|
||||
)
|
||||
|
||||
/obj/item/stack/sheet/mineral
|
||||
force = 5.0
|
||||
force = 5
|
||||
throwforce = 5
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
throw_speed = 3
|
||||
|
||||
/obj/item/stack/sheet/mineral/New()
|
||||
@@ -225,6 +225,56 @@ var/global/list/datum/stack_recipe/abductor_recipes = list ( \
|
||||
..()
|
||||
recipes = tranquillite_recipes
|
||||
|
||||
/*
|
||||
* Titanium
|
||||
*/
|
||||
/obj/item/stack/sheet/mineral/titanium
|
||||
name = "titanium"
|
||||
icon_state = "sheet-titanium"
|
||||
singular_name = "titanium sheet"
|
||||
force = 5
|
||||
throwforce = 5
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
throw_speed = 1
|
||||
throw_range = 3
|
||||
sheettype = "titanium"
|
||||
materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT)
|
||||
|
||||
var/global/list/datum/stack_recipe/titanium_recipes = list (
|
||||
new/datum/stack_recipe("titanium tile", /obj/item/stack/tile/mineral/titanium, 1, 4, 20),
|
||||
)
|
||||
|
||||
/obj/item/stack/sheet/mineral/titanium/New(loc, amount=null)
|
||||
recipes = titanium_recipes
|
||||
..()
|
||||
|
||||
/obj/item/stack/sheet/mineral/titanium/fifty
|
||||
amount = 50
|
||||
|
||||
|
||||
/*
|
||||
* Plastitanium
|
||||
*/
|
||||
/obj/item/stack/sheet/mineral/plastitanium
|
||||
name = "plastitanium"
|
||||
icon_state = "sheet-plastitanium"
|
||||
singular_name = "plastitanium sheet"
|
||||
force = 5
|
||||
throwforce = 5
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
throw_speed = 1
|
||||
throw_range = 3
|
||||
sheettype = "plastitanium"
|
||||
materials = list(MAT_TITANIUM=2000, MAT_PLASMA=2000)
|
||||
|
||||
var/global/list/datum/stack_recipe/plastitanium_recipes = list (
|
||||
new/datum/stack_recipe("plas-titanium tile", /obj/item/stack/tile/mineral/plastitanium, 1, 4, 20),
|
||||
)
|
||||
|
||||
/obj/item/stack/sheet/mineral/plastitanium/New(loc, amount=null)
|
||||
recipes = plastitanium_recipes
|
||||
..()
|
||||
|
||||
/obj/item/stack/sheet/mineral/enruranium
|
||||
name = "enriched uranium"
|
||||
icon_state = "sheet-enruranium"
|
||||
|
||||
@@ -61,6 +61,7 @@ var/global/list/datum/stack_recipe/metal_recipes = list(
|
||||
null,
|
||||
new /datum/stack_recipe_list("airlock assemblies", list(
|
||||
new /datum/stack_recipe("standard airlock assembly", /obj/structure/door_assembly, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("public airlock assembly", /obj/structure/door_assembly/door_assembly_public, 4, time = 50, one_per_turf = 1, on_floor = 1), \
|
||||
new /datum/stack_recipe("command airlock assembly", /obj/structure/door_assembly/door_assembly_com, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("security airlock assembly", /obj/structure/door_assembly/door_assembly_sec, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("engineering airlock assembly", /obj/structure/door_assembly/door_assembly_eng, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
@@ -70,11 +71,12 @@ var/global/list/datum/stack_recipe/metal_recipes = list(
|
||||
new /datum/stack_recipe("science airlock assembly", /obj/structure/door_assembly/door_assembly_science, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("medical airlock assembly", /obj/structure/door_assembly/door_assembly_med, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("maintenance airlock assembly", /obj/structure/door_assembly/door_assembly_mai, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("external maintenance airlock assembly", /obj/structure/door_assembly/door_assembly_extmai, 4, time = 50, one_per_turf = 1, on_floor = 1), \
|
||||
new /datum/stack_recipe("external airlock assembly", /obj/structure/door_assembly/door_assembly_ext, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("freezer airlock assembly", /obj/structure/door_assembly/door_assembly_fre, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("airtight hatch assembly", /obj/structure/door_assembly/door_assembly_hatch, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("maintenance hatch assembly", /obj/structure/door_assembly/door_assembly_mhatch, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("multi-tile airlock assembly", /obj/structure/door_assembly/multi_tile, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("multi-tile airlock assembly", /obj/structure/door_assembly/multi_tile, 8, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
)),
|
||||
null,
|
||||
new /datum/stack_recipe("mass driver button frame", /obj/item/mounted/frame/driver_button, 1, time = 50, one_per_turf = 0, on_floor = 1),
|
||||
@@ -131,9 +133,9 @@ var/global/list/datum/stack_recipe/plasteel_recipes = list(
|
||||
new /datum/stack_recipe("Mass Driver frame", /obj/machinery/mass_driver_frame, 3, time = 50, one_per_turf = 1),
|
||||
null,
|
||||
new /datum/stack_recipe_list("airlock assemblies", list(
|
||||
new /datum/stack_recipe("vault door assembly", /obj/structure/door_assembly/door_assembly_vault, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("high security airlock assembly", /obj/structure/door_assembly/door_assembly_highsecurity, 4, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
), 4),
|
||||
new /datum/stack_recipe("high security airlock assembly", /obj/structure/door_assembly/door_assembly_highsecurity, 6, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
new /datum/stack_recipe("vault door assembly", /obj/structure/door_assembly/door_assembly_vault, 8, time = 50, one_per_turf = 1, on_floor = 1),
|
||||
)),
|
||||
)
|
||||
|
||||
/obj/item/stack/sheet/plasteel
|
||||
@@ -142,7 +144,7 @@ var/global/list/datum/stack_recipe/plasteel_recipes = list(
|
||||
desc = "This sheet is an alloy of iron and plasma."
|
||||
icon_state = "sheet-plasteel"
|
||||
item_state = "sheet-metal"
|
||||
materials = list(MAT_METAL=6000, MAT_PLASMA=6000)
|
||||
materials = list(MAT_METAL=2000, MAT_PLASMA=2000)
|
||||
throwforce = 10.0
|
||||
flags = CONDUCT
|
||||
origin_tech = "materials=2"
|
||||
@@ -368,6 +370,7 @@ var/global/list/datum/stack_recipe/plastic_recipes = list ( \
|
||||
new/datum/stack_recipe("plastic ashtray", /obj/item/ashtray/plastic, 2, one_per_turf = 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("plastic fork", /obj/item/weapon/kitchen/utensil/pfork, 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("plastic spoon", /obj/item/weapon/kitchen/utensil/pspoon, 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("plastic spork", /obj/item/weapon/kitchen/utensil/pspork, 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("plastic knife", /obj/item/weapon/kitchen/knife/plastic, 1, on_floor = 1), \
|
||||
new/datum/stack_recipe("plastic bag", /obj/item/weapon/storage/bag/plasticbag, 3, on_floor = 1), \
|
||||
new/datum/stack_recipe("bear mould", /obj/item/weapon/kitchen/mould/bear, 1, on_floor = 1), \
|
||||
|
||||
@@ -111,4 +111,22 @@ var/global/list/datum/stack_recipe/silverfancy_tile_recipes = list ( \
|
||||
icon_state = "tile_abductor"
|
||||
origin_tech = "materials=6;abductor=1"
|
||||
turf_type = /turf/simulated/floor/mineral/abductor
|
||||
mineralType = "abductor"
|
||||
mineralType = "abductor"
|
||||
|
||||
/obj/item/stack/tile/mineral/titanium
|
||||
name = "titanium tile"
|
||||
singular_name = "titanium floor tile"
|
||||
desc = "A tile made of titanium, used for shuttles."
|
||||
icon_state = "tile_shuttle"
|
||||
turf_type = /turf/simulated/floor/mineral/titanium
|
||||
mineralType = "titanium"
|
||||
materials = list(MAT_TITANIUM=500)
|
||||
|
||||
/obj/item/stack/tile/mineral/plastitanium
|
||||
name = "plas-titanium tile"
|
||||
singular_name = "plas-titanium floor tile"
|
||||
desc = "A tile made of plas-titanium, used for very evil shuttles."
|
||||
icon_state = "tile_darkshuttle"
|
||||
turf_type = /turf/simulated/floor/mineral/plastitanium
|
||||
mineralType = "plastitanium"
|
||||
materials = list(MAT_TITANIUM=250, MAT_PLASMA=250)
|
||||
@@ -151,21 +151,21 @@
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
icon_state = "sword0"
|
||||
item_state = "sword0"
|
||||
var/active = 0.0
|
||||
var/active = FALSE
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
attack_verb = list("attacked", "struck", "hit")
|
||||
|
||||
/obj/item/toy/sword/attack_self(mob/user as mob)
|
||||
active = !(active)
|
||||
/obj/item/toy/sword/attack_self(mob/user)
|
||||
active = !active
|
||||
if(active)
|
||||
to_chat(user, "<span class='notice'>You extend the plastic blade with a quick flick of your wrist.</span>")
|
||||
playsound(user, 'sound/weapons/saberon.ogg', 50, 1)
|
||||
playsound(user, 'sound/weapons/saberon.ogg', 20, 1)
|
||||
icon_state = "swordblue"
|
||||
item_state = "swordblue"
|
||||
w_class = WEIGHT_CLASS_BULKY
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You push the plastic blade back down into the handle.</span>")
|
||||
playsound(user, 'sound/weapons/saberoff.ogg', 50, 1)
|
||||
playsound(user, 'sound/weapons/saberoff.ogg', 20, 1)
|
||||
icon_state = "sword0"
|
||||
item_state = "sword0"
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
@@ -209,6 +209,7 @@
|
||||
force_wielded = 0
|
||||
origin_tech = null
|
||||
attack_verb = list("attacked", "struck", "hit")
|
||||
brightness_on = 0
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/toy/hit_reaction()
|
||||
return 0
|
||||
|
||||
@@ -34,18 +34,22 @@ RCD
|
||||
var/list/door_accesses_list = list()
|
||||
var/one_access
|
||||
var/locked = 1
|
||||
var/static/list/allowed_door_types = list(/obj/machinery/door/airlock = "Standard",
|
||||
/obj/machinery/door/airlock/command = "Command", /obj/machinery/door/airlock/security = "Security",
|
||||
/obj/machinery/door/airlock/engineering = "Engineering", /obj/machinery/door/airlock/medical = "Medical",
|
||||
/obj/machinery/door/airlock/maintenance = "Maintenance", /obj/machinery/door/airlock/external = "External",
|
||||
/obj/machinery/door/airlock/glass = "Standard (Glass)", /obj/machinery/door/airlock/freezer = "Freezer",
|
||||
/obj/machinery/door/airlock/glass_command = "Command (Glass)", /obj/machinery/door/airlock/glass_engineering = "Engineering (Glass)",
|
||||
/obj/machinery/door/airlock/glass_security = "Security (Glass)", /obj/machinery/door/airlock/glass_medical = "Medical (Glass)",
|
||||
/obj/machinery/door/airlock/mining = "Mining", /obj/machinery/door/airlock/atmos = "Atmospherics",
|
||||
/obj/machinery/door/airlock/research = "Research", /obj/machinery/door/airlock/glass_research = "Research (Glass)",
|
||||
/obj/machinery/door/airlock/glass_mining = "Mining (Glass)", /obj/machinery/door/airlock/glass_atmos = "Atmospherics (Glass)",
|
||||
/obj/machinery/door/airlock/science = "Science", /obj/machinery/door/airlock/glass_science = "Science (Glass)",
|
||||
/obj/machinery/door/airlock/hatch = "Airtight Hatch", /obj/machinery/door/airlock/maintenance_hatch = "Maintenance Hatch")
|
||||
var/static/list/allowed_door_types = list(
|
||||
/obj/machinery/door/airlock = "Standard", /obj/machinery/door/airlock/glass = "Standard (Glass)",
|
||||
/obj/machinery/door/airlock/command = "Command", /obj/machinery/door/airlock/command/glass = "Command (Glass)",
|
||||
/obj/machinery/door/airlock/security = "Security", /obj/machinery/door/airlock/security/glass = "Security (Glass)",
|
||||
/obj/machinery/door/airlock/engineering = "Engineering", /obj/machinery/door/airlock/engineering/glass = "Engineering (Glass)",
|
||||
/obj/machinery/door/airlock/medical = "Medical", /obj/machinery/door/airlock/medical/glass = "Medical (Glass)",
|
||||
/obj/machinery/door/airlock/maintenance = "Maintenance", /obj/machinery/door/airlock/maintenance/glass = "Maintenance (Glass)",
|
||||
/obj/machinery/door/airlock/external = "External", /obj/machinery/door/airlock/external/glass = "External (Glass)",
|
||||
/obj/machinery/door/airlock/maintenance/external = "External Maintenance", /obj/machinery/door/airlock/maintenance/external/glass = "External Maintenance (Glass)",
|
||||
/obj/machinery/door/airlock/freezer = "Freezer",
|
||||
/obj/machinery/door/airlock/mining = "Mining", /obj/machinery/door/airlock/mining/glass = "Mining (Glass)",
|
||||
/obj/machinery/door/airlock/research = "Research", /obj/machinery/door/airlock/research/glass = "Research (Glass)",
|
||||
/obj/machinery/door/airlock/atmos = "Atmospherics", /obj/machinery/door/airlock/atmos/glass = "Atmospherics (Glass)",
|
||||
/obj/machinery/door/airlock/science = "Science", /obj/machinery/door/airlock/science/glass = "Science (Glass)",
|
||||
/obj/machinery/door/airlock/hatch = "Airtight Hatch",
|
||||
/obj/machinery/door/airlock/maintenance_hatch = "Maintenance Hatch")
|
||||
|
||||
/obj/item/weapon/rcd/New()
|
||||
desc = "A RCD. It currently holds [matter]/[max_matter] matter-units."
|
||||
@@ -76,7 +80,7 @@ RCD
|
||||
playsound(loc, 'sound/machines/click.ogg', 50, 1)
|
||||
to_chat(user, "<span class='notice'>The RCD now holds [matter]/[max_matter] matter-units.</span>")
|
||||
desc = "A RCD. It currently holds [matter]/[max_matter] matter-units."
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
return
|
||||
|
||||
|
||||
@@ -88,7 +92,7 @@ RCD
|
||||
ui_interact(user)
|
||||
|
||||
/obj/item/weapon/rcd/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/datum/topic_state/state = inventory_state)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "rcd.tmpl", "[name]", 450, 400, state = state)
|
||||
ui.open()
|
||||
@@ -347,14 +351,14 @@ RCD
|
||||
to_chat(user, "ERROR: RCD in MODE: [mode] attempted use by [user]. Send this text #coderbus or an admin.")
|
||||
return 0
|
||||
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
/obj/item/weapon/rcd/proc/useResource(var/amount, var/mob/user)
|
||||
if(matter < amount)
|
||||
return 0
|
||||
matter -= amount
|
||||
desc = "A RCD. It currently holds [matter]/[max_matter] matter-units."
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/rcd/proc/checkResource(var/amount, var/mob/user)
|
||||
|
||||
@@ -22,8 +22,8 @@ LIGHTERS ARE IN LIGHTERS.DM
|
||||
slot_flags = SLOT_EARS|SLOT_MASK
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
body_parts_covered = null
|
||||
attack_verb = list("burnt", "singed")
|
||||
var/lit = 0
|
||||
attack_verb = null
|
||||
var/lit = FALSE
|
||||
var/icon_on = "cigon" //Note - these are in masks.dmi not in cigarette.dmi
|
||||
var/icon_off = "cigoff"
|
||||
var/type_butt = /obj/item/weapon/cigbutt
|
||||
@@ -128,7 +128,11 @@ LIGHTERS ARE IN LIGHTERS.DM
|
||||
/obj/item/clothing/mask/cigarette/proc/light(flavor_text = null)
|
||||
if(!src.lit)
|
||||
src.lit = 1
|
||||
name = "lit [name]"
|
||||
attack_verb = list("burnt", "singed")
|
||||
hitsound = 'sound/items/welder.ogg'
|
||||
damtype = "fire"
|
||||
force = 4
|
||||
if(reagents.get_reagent_amount("plasma")) // the plasma explodes when exposed to fire
|
||||
var/datum/effect_system/reagents_explosion/e = new()
|
||||
e.set_up(round(reagents.get_reagent_amount("plasma") / 2.5, 1), get_turf(src), 0, 0)
|
||||
|
||||
@@ -193,7 +193,7 @@
|
||||
//Burn it based on transfered gas
|
||||
target.hotspot_expose((ptank.air_contents.temperature*2) + 380,500) // -- More of my "how do I shot fire?" dickery. -- TLE
|
||||
//location.hotspot_expose(1000,500,1)
|
||||
air_master.add_to_active(target, 0)
|
||||
SSair.add_to_active(target, 0)
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -1,70 +1,6 @@
|
||||
//improvised explosives//
|
||||
|
||||
//iedcasing assembly crafting//
|
||||
/obj/item/weapon/reagent_containers/food/drinks/cans/attackby(var/obj/item/I, mob/user as mob)
|
||||
if(istype(I, /obj/item/device/assembly/igniter))
|
||||
var/obj/item/device/assembly/igniter/G = I
|
||||
var/obj/item/weapon/grenade/iedcasing/W = new /obj/item/weapon/grenade/iedcasing
|
||||
user.unEquip(G)
|
||||
user.unEquip(src)
|
||||
user.put_in_hands(W)
|
||||
to_chat(user, "<span class='notice'>You stuff the [I] in the [src], emptying the contents beforehand.</span>")
|
||||
W.underlays += image(src.icon, icon_state = src.icon_state)
|
||||
qdel(I)
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing
|
||||
name = "improvised explosive assembly"
|
||||
desc = "An igniter stuffed into an aluminum shell."
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
icon = 'icons/obj/grenade.dmi'
|
||||
icon_state = "improvised_grenade"
|
||||
item_state = "flashbang"
|
||||
throw_speed = 3
|
||||
throw_range = 7
|
||||
flags = CONDUCT
|
||||
slot_flags = SLOT_BELT
|
||||
var/assembled = 0
|
||||
active = 1
|
||||
det_time = 50
|
||||
display_timer = 0
|
||||
var/range = 3
|
||||
var/times = list()
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/afterattack(atom/target, mob/user , flag) //Filling up the can
|
||||
if(assembled == 0)
|
||||
if( istype(target, /obj/structure/reagent_dispensers/fueltank))
|
||||
if(target.reagents.total_volume < 50)
|
||||
to_chat(user, "<span class='notice'>There's not enough fuel left to work with.</span>")
|
||||
return
|
||||
var/obj/structure/reagent_dispensers/fueltank/F = target
|
||||
F.reagents.remove_reagent("fuel", 50, 1)//Deleting 50 fuel from the welding fuel tank,
|
||||
assembled = 1
|
||||
to_chat(user, "<span class='notice'>You've filled the makeshift explosive with welding fuel.</span>")
|
||||
playsound(src.loc, 'sound/effects/refill.ogg', 50, 1, -6)
|
||||
desc = "An improvised explosive assembly. Filled to the brim with 'Explosive flavor'"
|
||||
overlays += image('icons/obj/grenade.dmi', icon_state = "improvised_grenade_filled")
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/attackby(var/obj/item/I, mob/user as mob) //Wiring the can for ignition
|
||||
if(istype(I, /obj/item/stack/cable_coil))
|
||||
if(assembled == 1)
|
||||
var/obj/item/stack/cable_coil/C = I
|
||||
C.use(1)
|
||||
assembled = 2
|
||||
to_chat(user, "<span class='notice'>You wire the igniter to detonate the fuel.</span>")
|
||||
desc = "A weak, improvised explosive."
|
||||
overlays += image('icons/obj/grenade.dmi', icon_state = "improvised_grenade_wired")
|
||||
name = "improvised explosive"
|
||||
active = 0
|
||||
det_time = rand(30,80)
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/filled
|
||||
name = "improvised firebomb"
|
||||
desc = "A weak, improvised incendiary device."
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
@@ -77,53 +13,53 @@
|
||||
slot_flags = SLOT_BELT
|
||||
active = 0
|
||||
det_time = 50
|
||||
assembled = 2
|
||||
display_timer = 0
|
||||
var/list/times
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/filled/New(loc)
|
||||
/obj/item/weapon/grenade/iedcasing/New()
|
||||
..()
|
||||
overlays += image('icons/obj/grenade.dmi', icon_state = "improvised_grenade_filled")
|
||||
overlays += image('icons/obj/grenade.dmi', icon_state = "improvised_grenade_wired")
|
||||
times = list("5" = 10, "-1" = 20, "[rand(30,80)]" = 50, "[rand(65,180)]" = 20)// "Premature, Dud, Short Fuse, Long Fuse"=[weighting value]
|
||||
overlays += "improvised_grenade_filled"
|
||||
overlays += "improvised_grenade_wired"
|
||||
times = list("5" = 10, "-1" = 20, "[rand(30, 80)]" = 50, "[rand(65, 180)]" = 20)// "Premature, Dud, Short Fuse, Long Fuse"=[weighting value]
|
||||
det_time = text2num(pickweight(times))
|
||||
if(det_time < 0) //checking for 'duds'
|
||||
range = 1
|
||||
det_time = rand(30,80)
|
||||
else
|
||||
range = pick(2,2,2,3,3,3,4)
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/CheckParts(list/parts_list)
|
||||
..()
|
||||
var/obj/item/weapon/reagent_containers/food/drinks/cans/can = locate() in contents
|
||||
if(can)
|
||||
underlays += can
|
||||
can.pixel_x = 0 //Reset the sprite's position to make it consistent with the rest of the IED
|
||||
can.pixel_y = 0
|
||||
var/mutable_appearance/can_underlay = new(can)
|
||||
can_underlay.layer = FLOAT_LAYER
|
||||
can_underlay.plane = FLOAT_PLANE
|
||||
underlays += can_underlay
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/attack_self(mob/user as mob) //
|
||||
/obj/item/weapon/grenade/iedcasing/attack_self(mob/user) //
|
||||
if(!active)
|
||||
if(clown_check(user))
|
||||
to_chat(user, "<span class='warning'>You light the [name]!</span>")
|
||||
active = 1
|
||||
overlays -= image('icons/obj/grenade.dmi', icon_state = "improvised_grenade_filled")
|
||||
active = TRUE
|
||||
overlays -= "improvised_grenade_filled"
|
||||
icon_state = initial(icon_state) + "_active"
|
||||
add_fingerprint(user)
|
||||
var/turf/bombturf = get_turf(src)
|
||||
var/area/A = get_area(bombturf)
|
||||
|
||||
message_admins("[key_name_admin(usr)] has primed a [name] for detonation at <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[bombturf.x];Y=[bombturf.y];Z=[bombturf.z]'>[A.name] (JMP)</a>")
|
||||
log_game("[key_name(usr)] has primed a [name] for detonation at [A.name] ([bombturf.x],[bombturf.y],[bombturf.z])")
|
||||
message_admins("[ADMIN_LOOKUPFLW(user)] has primed a [name] for detonation at [ADMIN_COORDJMP(bombturf)].")
|
||||
log_game("[key_name(usr)] has primed a [name] for detonation at [A.name] [COORD(bombturf)].")
|
||||
if(iscarbon(user))
|
||||
var/mob/living/carbon/C = user
|
||||
C.throw_mode_on()
|
||||
spawn(det_time)
|
||||
prime()
|
||||
addtimer(src, "prime", det_time)
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/prime() //Blowing that can up
|
||||
update_mob()
|
||||
explosion(src.loc,-1,-1,-1, flame_range = range) // no explosive damage, only a large fireball.
|
||||
explosion(loc, -1, -1, 2, flame_range = 4) // small explosion, plus a very large fireball.
|
||||
qdel(src)
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/examine(mob/user)
|
||||
..(user)
|
||||
..()
|
||||
to_chat(user, "You can't tell when it will explode!")
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
if(ishuman(C))
|
||||
var/mob/living/carbon/human/H = C
|
||||
if(!(H.get_organ("l_hand") || H.get_organ("r_hand")))
|
||||
if(!H.has_left_hand() || !H.has_right_hand())
|
||||
to_chat(user, "<span class='warning'>How do you suggest handcuffing someone with no hands?</span>")
|
||||
return
|
||||
|
||||
|
||||
@@ -50,3 +50,4 @@
|
||||
icon = 'icons/obj/janitor.dmi'
|
||||
icon_state = "holosign"
|
||||
anchored = 1
|
||||
armor = list(melee = 0, bullet = 50, laser = 50, energy = 50, bomb = 0, bio = 0, rad = 0)
|
||||
|
||||
@@ -82,6 +82,18 @@
|
||||
icon_state = "pspoon"
|
||||
attack_verb = list("attacked", "poked")
|
||||
|
||||
/obj/item/weapon/kitchen/utensil/spork
|
||||
name = "spork"
|
||||
desc = "It's a spork. Marvel at its innovative design."
|
||||
icon_state = "spork"
|
||||
attack_verb = list("attacked", "sporked")
|
||||
|
||||
/obj/item/weapon/kitchen/utensil/pspork
|
||||
name = "plastic spork"
|
||||
desc = "It's a plastic spork. It's the fork side of the spoon!"
|
||||
icon_state = "pspork"
|
||||
attack_verb = list("attacked", "sporked")
|
||||
|
||||
/*
|
||||
* Knives
|
||||
*/
|
||||
|
||||
@@ -52,23 +52,12 @@
|
||||
if(sig)
|
||||
to_chat(user, "<span class='warning'>This beartrap already has a signaler hooked up to it!</span>")
|
||||
return
|
||||
IED = I
|
||||
switch(IED.assembled)
|
||||
if(0,1) //if it's not fueled/hooked up
|
||||
to_chat(user, "<span class='warning'>You haven't prepared this IED yet!</span>")
|
||||
IED = null
|
||||
return
|
||||
if(2,3)
|
||||
user.drop_item()
|
||||
I.forceMove(src)
|
||||
message_admins("[key_name_admin(user)] has rigged a beartrap with an IED.")
|
||||
log_game("[key_name(user)] has rigged a beartrap with an IED.")
|
||||
to_chat(user, "<span class='notice'>You sneak the [IED] underneath the pressure plate and connect the trigger wire.</span>")
|
||||
desc = "A trap used to catch bears and other legged creatures. <span class='warning'>There is an IED hooked up to it.</span>"
|
||||
else
|
||||
to_chat(user, "<span class='danger'>You shouldn't be reading this message! Contact a coder or someone, something broke!</span>")
|
||||
IED = null
|
||||
return
|
||||
user.drop_item()
|
||||
I.forceMove(src)
|
||||
message_admins("[key_name_admin(user)] has rigged a beartrap with an IED.")
|
||||
log_game("[key_name(user)] has rigged a beartrap with an IED.")
|
||||
to_chat(user, "<span class='notice'>You sneak [IED] underneath the pressure plate and connect the trigger wire.</span>")
|
||||
desc = "A trap used to catch bears and other legged creatures. <span class='warning'>There is an IED hooked up to it.</span>"
|
||||
if(istype(I, /obj/item/device/assembly/signaler))
|
||||
if(IED)
|
||||
to_chat(user, "<span class='warning'>This beartrap already has an IED hooked up to it!</span>")
|
||||
@@ -110,9 +99,6 @@
|
||||
|
||||
if(IED && isturf(src.loc))
|
||||
IED.active = 1
|
||||
IED.overlays -= image('icons/obj/grenade.dmi', icon_state = "improvised_grenade_filled")
|
||||
IED.icon_state = initial(icon_state) + "_active"
|
||||
IED.assembled = 3
|
||||
message_admins("[key_name_admin(usr)] has triggered an IED-rigged [name].")
|
||||
log_game("[key_name(usr)] has triggered an IED-rigged [name].")
|
||||
spawn(IED.det_time)
|
||||
@@ -127,7 +113,7 @@
|
||||
H.apply_damage(trap_damage, BRUTE,"chest")
|
||||
else
|
||||
H.apply_damage(trap_damage, BRUTE,(pick("l_leg", "r_leg")))
|
||||
if(!H.legcuffed) //beartrap can't cuff you leg if there's already a beartrap or legcuffs.
|
||||
if(!H.legcuffed && H.get_num_legs() >= 2) //beartrap can't cuff you leg if there's already a beartrap or legcuffs.
|
||||
H.legcuffed = src
|
||||
forceMove(H)
|
||||
H.update_inv_legcuffed()
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
throwforce = 4
|
||||
flags = CONDUCT
|
||||
slot_flags = SLOT_BELT
|
||||
attack_verb = list("burnt", "singed")
|
||||
attack_verb = null
|
||||
var/lit = 0
|
||||
|
||||
/obj/item/weapon/lighter/zippo
|
||||
@@ -38,6 +38,10 @@
|
||||
w_class = WEIGHT_CLASS_BULKY
|
||||
icon_state = icon_on
|
||||
item_state = icon_on
|
||||
force = 5
|
||||
damtype = "fire"
|
||||
hitsound = 'sound/items/welder.ogg'
|
||||
attack_verb = list("burnt", "singed")
|
||||
if(istype(src, /obj/item/weapon/lighter/zippo) )
|
||||
user.visible_message("<span class='rose'>Without even breaking stride, [user] flips open and lights [src] in one smooth movement.</span>")
|
||||
playsound(src.loc, 'sound/items/ZippoLight.ogg', 25, 1)
|
||||
@@ -62,6 +66,9 @@
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
icon_state = icon_off
|
||||
item_state = icon_off
|
||||
hitsound = "swing_hit"
|
||||
force = 0
|
||||
attack_verb = null //human_defense.dm takes care of it
|
||||
if(istype(src, /obj/item/weapon/lighter/zippo) )
|
||||
user.visible_message("<span class='rose'>You hear a quiet click, as [user] shuts off [src] without even looking at what they're doing. Wow.")
|
||||
playsound(src.loc, 'sound/items/ZippoClose.ogg', 25, 1)
|
||||
@@ -145,47 +152,74 @@
|
||||
desc = "A simple match stick, used for lighting fine smokables."
|
||||
icon = 'icons/obj/cigarettes.dmi'
|
||||
icon_state = "match_unlit"
|
||||
var/lit = 0
|
||||
var/lit = FALSE
|
||||
var/burnt = FALSE
|
||||
var/smoketime = 5
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
origin_tech = "materials=1"
|
||||
attack_verb = list("burnt", "singed")
|
||||
attack_verb = null
|
||||
|
||||
/obj/item/weapon/match/process()
|
||||
var/turf/location = get_turf(src)
|
||||
smoketime--
|
||||
if(smoketime < 1)
|
||||
icon_state = "match_burnt"
|
||||
lit = -1
|
||||
processing_objects.Remove(src)
|
||||
return
|
||||
matchburnout()
|
||||
if(location)
|
||||
location.hotspot_expose(700, 5)
|
||||
return
|
||||
|
||||
/obj/item/weapon/match/dropped(mob/user as mob)
|
||||
if(lit == 1)
|
||||
lit = -1
|
||||
/obj/item/weapon/match/fire_act()
|
||||
matchignite()
|
||||
|
||||
/obj/item/weapon/match/proc/matchignite()
|
||||
if(!lit && !burnt)
|
||||
lit = TRUE
|
||||
icon_state = "match_lit"
|
||||
damtype = "fire"
|
||||
force = 3
|
||||
hitsound = 'sound/items/welder.ogg'
|
||||
item_state = "cigon"
|
||||
name = "lit match"
|
||||
desc = "A match. This one is lit."
|
||||
attack_verb = list("burnt","singed")
|
||||
processing_objects.Add(src)
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/match/proc/matchburnout()
|
||||
if(lit)
|
||||
lit = FALSE
|
||||
burnt = TRUE
|
||||
damtype = "brute"
|
||||
force = initial(force)
|
||||
icon_state = "match_burnt"
|
||||
item_state = "cigoff"
|
||||
name = "burnt match"
|
||||
desc = "A match. This one has seen better days."
|
||||
attack_verb = list("flicked")
|
||||
processing_objects.Remove(src)
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/match/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob)
|
||||
/obj/item/weapon/match/dropped(mob/user)
|
||||
matchburnout()
|
||||
. = ..()
|
||||
|
||||
/obj/item/weapon/match/attack(mob/living/carbon/M, mob/living/carbon/user)
|
||||
if(!isliving(M))
|
||||
return ..()
|
||||
if(lit == 1) M.IgniteMob()
|
||||
if(!istype(M, /mob))
|
||||
return ..()
|
||||
|
||||
if(istype(M.wear_mask, /obj/item/clothing/mask/cigarette) && user.zone_sel.selecting == "mouth" && lit == 1)
|
||||
var/obj/item/clothing/mask/cigarette/cig = M.wear_mask
|
||||
if(lit && M.IgniteMob())
|
||||
message_admins("[key_name_admin(user)] set [key_name_admin(M)] on fire")
|
||||
log_game("[key_name(user)] set [key_name(M)] on fire")
|
||||
var/obj/item/clothing/mask/cigarette/cig = help_light_cig(M)
|
||||
if(lit && cig && user.a_intent == INTENT_HELP)
|
||||
if(cig.lit)
|
||||
to_chat(user, "<span class='notice'>[cig] is already lit.</span>")
|
||||
if(M == user)
|
||||
cig.attackby(src, user)
|
||||
else
|
||||
cig.light("<span class='notice'>[user] holds the [name] out for [M], and lights the [cig.name].</span>")
|
||||
cig.light("<span class='notice'>[user] holds [src] out for [M], and lights [cig].</span>")
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/item/proc/help_light_cig(mob/living/M)
|
||||
var/mask_item = M.get_item_by_slot(slot_wear_mask)
|
||||
if(istype(mask_item, /obj/item/clothing/mask/cigarette))
|
||||
return mask_item
|
||||
|
||||
@@ -12,18 +12,18 @@
|
||||
icon_state ="bookEngineering"
|
||||
author = "Engineering Encyclopedia" // Who wrote the thing, can be changed by pen or PC. It is not automatically assigned
|
||||
title = "Station Repairs and Construction"
|
||||
/*dat = {"
|
||||
dat = {"
|
||||
|
||||
<html><head>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<iframe width='100%' height='97%' src="http://wiki.nanotrasen.com/index.php?title=Guide_to_construction&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe>
|
||||
<iframe width='100%' height='97%' src="https://Nanotrasen.se/wiki/index.php?title=Guide_to_Construction&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/engineering_particle_accelerator
|
||||
name = "Particle Accelerator User's Guide"
|
||||
@@ -32,7 +32,7 @@
|
||||
title = "Particle Accelerator User's Guide"
|
||||
//big pile of shit below.
|
||||
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -65,7 +65,7 @@
|
||||
</ol>
|
||||
|
||||
</body>
|
||||
</html>"}*/
|
||||
</html>"}
|
||||
|
||||
|
||||
/obj/item/weapon/book/manual/supermatter_engine
|
||||
@@ -158,18 +158,18 @@
|
||||
title = "Hacking"
|
||||
//big pile of shit below.
|
||||
|
||||
/*dat = {"
|
||||
dat = {"
|
||||
|
||||
<html><head>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<iframe width='100%' height='97%' src="http://wiki.nanotrasen.com/index.php?title=Hacking&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe>
|
||||
<iframe width='100%' height='97%' src="https://Nanotrasen.se/wiki/index.php?title=Hacking&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/engineering_singularity_safety
|
||||
name = "Singularity Safety in Special Circumstances"
|
||||
@@ -178,7 +178,7 @@
|
||||
title = "Singularity Safety in Special Circumstances"
|
||||
//big pile of shit below.
|
||||
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -217,14 +217,14 @@
|
||||
Step one: <b>GET THE FUCK OUT OF THERE!!! FORGET THE WOMEN AND CHILDREN, SAVE YOURSELF!!!</b><br>
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/hydroponics_pod_people
|
||||
name = "The Human Harvest - From seed to market"
|
||||
icon_state ="bookHydroponicsPodPeople"
|
||||
author = "Farmer John"
|
||||
title = "The Human Harvest - From seed to market"
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -252,7 +252,7 @@
|
||||
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/medical_cloning
|
||||
name = "Cloning techniques of the 26th century"
|
||||
@@ -261,7 +261,7 @@
|
||||
title = "Cloning techniques of the 26th century"
|
||||
//big pile of shit below.
|
||||
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -329,7 +329,7 @@
|
||||
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
|
||||
/obj/item/weapon/book/manual/ripley_build_and_repair
|
||||
@@ -339,7 +339,7 @@
|
||||
title = "APLU \"Ripley\" Construction and Operation Manual"
|
||||
//big pile of shit below.
|
||||
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -405,7 +405,7 @@
|
||||
|
||||
<h2>Operation</h2>
|
||||
Coming soon...
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/experimentor
|
||||
name = "Mentoring your Experiments"
|
||||
@@ -544,7 +544,7 @@
|
||||
icon_state = "rdbook"
|
||||
author = "Dr. L. Ight"
|
||||
title = "Research and Development 101"
|
||||
/*dat = {"
|
||||
dat = {"
|
||||
<html>
|
||||
<head>
|
||||
<style>
|
||||
@@ -580,11 +580,14 @@
|
||||
<h2>Protolathe</h2>
|
||||
This machine is an advanced form of the Autolathe that produce non-circuit designs. Unlike the Autolathe, it can use processed metal, glass, solid plasma, silver, gold, and diamonds along with a variety of chemicals to produce devices. The downside is that, again, not all devices you make are 100% reliable when you first discover them.
|
||||
|
||||
<h1>Reliability and You</h1>
|
||||
As it has been stated, many devices when they're first discovered do not have a 100% reliablity when you first discover them. Instead, the reliablity of the device is dependent upon a base reliability value, whatever improvements to the design you've discovered through the Destructive Analyzer, and any advancements you've made with the device's source technologies. To be able to improve the reliability of a device, you have to use the device until it breaks beyond repair. Once that happens, you can analyze it in a Destructive Analyzer. Once the device reachs a certain minimum reliability, you'll gain tech advancements from it.
|
||||
|
||||
<h1>Building a Better Machine</h1>
|
||||
Many machines produces from circuit boards and inserted into a machine frame require a variety of parts to construct. These are parts like capacitors, batteries, matter bins, and so forth. As your knowledge of science improves, more advanced versions are unlocked. If you use these parts when constructing something, its attributes may be improved. For example, if you use an advanced matter bin when constructing an autolathe (rather then a regular one), it'll hold more materials. Experiment around with stock parts of various qualities to see how they affect the end results!
|
||||
Many machines produces from circuit boards and inserted into a machine frame require a variety of parts to construct. These are parts like capacitors, batteries, matter bins, and so forth. As your knowledge of science improves, more advanced versions are unlocked. If you use these parts when constructing something, its attributes may be improved. For example, if you use an advanced matter bin when constructing an autolathe (rather then a regular one), it'll hold more materials. Experiment around with stock parts of various qualities to see how they affect the end results! Be warned, however: Tier 3 and higher stock parts don't have 100% reliability and their low reliability may affect the reliability of the end machine.
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
|
||||
/obj/item/weapon/book/manual/robotics_cyborgs
|
||||
@@ -592,7 +595,7 @@
|
||||
icon_state = "borgbook"
|
||||
author = "XISC"
|
||||
title = "Cyborgs for Dummies"
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 21px; margin: 15px 0px 5px;}
|
||||
@@ -787,7 +790,7 @@
|
||||
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/security_space_law
|
||||
name = "Space Law"
|
||||
@@ -801,7 +804,7 @@
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<iframe width='100%' height='97%' src="http://nanotrasen.se/wiki/index.php?title=Space_law&printable=yes" frameborder="0" id="main_frame"></iframe> </body>
|
||||
<iframe width='100%' height='97%' src="https://Nanotrasen.se/wiki/index.php?title=Space_law&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe> </body>
|
||||
|
||||
</html>
|
||||
|
||||
@@ -818,17 +821,17 @@
|
||||
icon_state ="bookEngineering2"
|
||||
author = "Engineering Encyclopedia"
|
||||
title = "Engineering Textbook"
|
||||
/*dat = {"
|
||||
dat = {"
|
||||
|
||||
<html><head>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<iframe width='100%' height='97%' src="http://wiki.nanotrasen.com/index.php?title=Guide_to_engineering&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe> </body>
|
||||
<iframe width='100%' height='97%' src="https://Nanotrasen.se/wiki/index.php?title=Guide_to_Engineering&printable=yes&remove_links=1" frameborder="0" id="main_frame"></iframe> </body>
|
||||
|
||||
</html>
|
||||
|
||||
"}*/
|
||||
"}
|
||||
|
||||
|
||||
/obj/item/weapon/book/manual/chef_recipes
|
||||
@@ -836,7 +839,7 @@
|
||||
icon_state = "cooked_book"
|
||||
author = "Victoria Ponsonby"
|
||||
title = "Chef Recipes"
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -884,14 +887,14 @@
|
||||
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
/obj/item/weapon/book/manual/barman_recipes
|
||||
name = "Barman Recipes"
|
||||
icon_state = "barbook"
|
||||
author = "Sir John Rose"
|
||||
title = "Barman Recipes"
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -936,7 +939,7 @@
|
||||
|
||||
</body>
|
||||
</html>
|
||||
"}*/
|
||||
"}
|
||||
|
||||
|
||||
/obj/item/weapon/book/manual/detective
|
||||
@@ -944,7 +947,7 @@
|
||||
icon_state ="bookDetective"
|
||||
author = "Nanotrasen"
|
||||
title = "The Film Noir: Proper Procedures for Investigations"
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
@@ -978,14 +981,14 @@
|
||||
It really is that easy! Good luck!
|
||||
|
||||
</body>
|
||||
</html>"}*/
|
||||
</html>"}
|
||||
|
||||
/obj/item/weapon/book/manual/nuclear
|
||||
name = "Fission Mailed: Nuclear Sabotage 101"
|
||||
icon_state ="bookNuclear"
|
||||
author = "Syndicate"
|
||||
title = "Fission Mailed: Nuclear Sabotage 101"
|
||||
/*dat = {"<html>
|
||||
dat = {"<html>
|
||||
Nuclear Explosives 101:<br>
|
||||
Hello and thank you for choosing the Syndicate for your nuclear information needs.<br>
|
||||
Today's crash course will deal with the operation of a Fusion Class Nanotrasen made Nuclear Device.<br>
|
||||
@@ -1013,7 +1016,7 @@
|
||||
<b>Disk, Code, Safety, Timer, Disk, RUN!</b><br>
|
||||
Intelligence Analysts believe that normal Nanotrasen procedure is for the Captain to secure the nuclear authorisation disk.<br>
|
||||
Good luck!
|
||||
</html>"}*/
|
||||
</html>"}
|
||||
|
||||
/obj/item/weapon/book/manual/atmospipes
|
||||
name = "Pipes and You: Getting To Know Your Scary Tools"
|
||||
@@ -2557,4 +2560,4 @@
|
||||
</body>
|
||||
</html>
|
||||
|
||||
"}
|
||||
"}
|
||||
@@ -9,6 +9,9 @@
|
||||
hitsound = 'sound/weapons/blade1.ogg' // Probably more appropriate than the previous hitsound. -- Dave
|
||||
usesound = 'sound/weapons/blade1.ogg'
|
||||
toolspeed = 1
|
||||
light_power = 2
|
||||
var/brightness_on = 2
|
||||
var/colormap = list(red=LIGHT_COLOR_RED, blue=LIGHT_COLOR_LIGHTBLUE, green=LIGHT_COLOR_GREEN, purple=LIGHT_COLOR_PURPLE, rainbow=LIGHT_COLOR_WHITE)
|
||||
|
||||
/obj/item/weapon/melee/energy/suicide_act(mob/user)
|
||||
user.visible_message(pick("<span class='suicide'>[user] is slitting \his stomach open with the [src.name]! It looks like \he's trying to commit seppuku.</span>", \
|
||||
@@ -29,8 +32,10 @@
|
||||
attack_verb = attack_verb_on
|
||||
if(!item_color)
|
||||
icon_state = icon_state_on
|
||||
set_light(brightness_on)
|
||||
else
|
||||
icon_state = "sword[item_color]"
|
||||
set_light(brightness_on, l_color=colormap[item_color])
|
||||
w_class = w_class_on
|
||||
playsound(user, 'sound/weapons/saberon.ogg', 35, 1) //changed it from 50% volume to 35% because deafness
|
||||
to_chat(user, "<span class='notice'>[src] is now active.</span>")
|
||||
@@ -44,6 +49,7 @@
|
||||
icon_state = initial(icon_state)
|
||||
w_class = initial(w_class)
|
||||
playsound(user, 'sound/weapons/saberoff.ogg', 35, 1) //changed it from 50% volume to 35% because deafness
|
||||
set_light(0)
|
||||
to_chat(user, "<span class='notice'>[src] can now be concealed.</span>")
|
||||
if(istype(user,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
@@ -64,13 +70,14 @@
|
||||
throw_range = 5
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
w_class_on = WEIGHT_CLASS_HUGE
|
||||
hitsound = "swing_hit"
|
||||
hitsound = 'sound/weapons/bladeslice.ogg'
|
||||
flags = CONDUCT
|
||||
armour_penetration = 100
|
||||
origin_tech = "combat=4;magnets=3"
|
||||
attack_verb = list("attacked", "chopped", "cleaved", "torn", "cut")
|
||||
attack_verb_on = list()
|
||||
sharp = 1
|
||||
light_color = LIGHT_COLOR_WHITE
|
||||
|
||||
/obj/item/weapon/melee/energy/axe/suicide_act(mob/user)
|
||||
user.visible_message("<span class='suicide'>[user] swings the [src.name] towards /his head! It looks like \he's trying to commit suicide.</span>")
|
||||
@@ -92,7 +99,6 @@
|
||||
block_chance = 50
|
||||
sharp = 1
|
||||
var/hacked = 0
|
||||
var/blade_color
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/New()
|
||||
if(item_color == null)
|
||||
@@ -129,6 +135,7 @@
|
||||
hitcost = 75 //Costs more than a standard cyborg esword
|
||||
item_color = null
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
light_color = LIGHT_COLOR_WHITE
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/cyborg/saw/New()
|
||||
..()
|
||||
@@ -192,6 +199,7 @@
|
||||
desc = "Arrrr matey."
|
||||
icon_state = "cutlass0"
|
||||
icon_state_on = "cutlass1"
|
||||
light_color = LIGHT_COLOR_RED
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/pirate/New()
|
||||
return
|
||||
@@ -224,4 +232,4 @@
|
||||
name = "hardlight blade"
|
||||
desc = "An extremely sharp blade made out of hard light. Packs quite a punch."
|
||||
icon_state = "lightblade"
|
||||
item_state = "lightblade"
|
||||
item_state = "lightblade"
|
||||
|
||||
@@ -140,7 +140,7 @@ var/list/pipemenu = list(
|
||||
ui_interact(user)
|
||||
|
||||
/obj/item/weapon/rpd/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/datum/topic_state/state = inventory_state)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "rpd.tmpl", "[name]", 400, 650, state = state)
|
||||
ui.open()
|
||||
@@ -173,16 +173,19 @@ var/list/pipemenu = list(
|
||||
mode = text2num(sanitize(href_list["mode"]))
|
||||
else
|
||||
return
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
//What the RPD actually does
|
||||
|
||||
/obj/item/weapon/rpd/afterattack(atom/target, mob/user, proximity)
|
||||
..()
|
||||
var/turf/T = get_turf(target)
|
||||
if(src.loc != user || ismob(target) || istype(target, /obj/structure/window) || !proximity || world.time < lastused + spawndelay)
|
||||
if(loc != user || ismob(target) || istype(target, /obj/structure/window) || !proximity || world.time < lastused + spawndelay)
|
||||
return
|
||||
if(mode == ATMOS_MODE && !istype(T, /turf/simulated/shuttle)) //No pipes on shuttles nerds
|
||||
if(!(T.flags & RPD_ALLOWED_HERE))
|
||||
to_chat(user, "<span class='notice'>[src] beeps, \"Unable to interface with [T]. Please try again later.\"</span>")
|
||||
return
|
||||
if(mode == ATMOS_MODE)
|
||||
if(istype(T, /turf/simulated/wall)) //Drilling into walls takes time
|
||||
playsound(loc, "sound/weapons/circsawhit.ogg", 50, 1)
|
||||
user.visible_message("<span class = 'notice'>[user] starts drilling a hole in [T]...</span>", "<span class = 'notice'>You start drilling a hole in [T]...</span>", "<span class = 'warning'>You hear a drill.</span>")
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
materials = list(MAT_GLASS=MINERAL_MATERIAL_AMOUNT)
|
||||
attack_verb = list("stabbed", "slashed", "sliced", "cut")
|
||||
hitsound = 'sound/weapons/bladeslice.ogg'
|
||||
armor = list("melee" = 100, "bullet" = 0, "laser" = 0, "energy" = 100, "bomb" = 0, "bio" = 0, "rad" = 0)
|
||||
|
||||
/obj/item/weapon/shard/suicide_act(mob/user)
|
||||
to_chat(viewers(user), pick("<span class='danger'>[user] is slitting \his wrists with \the [src]! It looks like \he's trying to commit suicide.</span>",
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/obj/item/weapon/shield
|
||||
name = "shield"
|
||||
block_chance = 50
|
||||
armor = list(melee = 50, bullet = 50, laser = 50, energy = 0, bomb = 30, bio = 0, rad = 0)
|
||||
|
||||
/obj/item/weapon/shield/hit_reaction(mob/living/carbon/human/owner, attack_text, final_block_chance, damage, attack_type)
|
||||
if(attack_type == THROWN_PROJECTILE_ATTACK)
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
max_w_class = WEIGHT_CLASS_HUGE
|
||||
max_combined_w_class = 35
|
||||
burn_state = FIRE_PROOF
|
||||
cant_hold = list(/obj/item/weapon/storage/backpack/holding)
|
||||
|
||||
/obj/item/weapon/storage/backpack/holding/New()
|
||||
..()
|
||||
|
||||
@@ -25,14 +25,40 @@
|
||||
icon_state = "box"
|
||||
item_state = "syringe_kit"
|
||||
burn_state = FLAMMABLE
|
||||
foldable = /obj/item/stack/sheet/cardboard //BubbleWrap
|
||||
var/foldable = /obj/item/stack/sheet/cardboard
|
||||
|
||||
/obj/item/weapon/storage/box/attack_self(mob/user)
|
||||
..()
|
||||
|
||||
if(!foldable)
|
||||
return
|
||||
if(contents.len)
|
||||
to_chat(user, "<span class='warning'>You can't fold this box with items still inside!</span>")
|
||||
return
|
||||
if(!ispath(foldable))
|
||||
return
|
||||
|
||||
// Close any open UI windows first
|
||||
var/found = 0
|
||||
for(var/mob/M in range(1))
|
||||
if(M.s_active == src)
|
||||
close(M)
|
||||
if(M == user)
|
||||
found = 1
|
||||
if(!found) // User is too far away
|
||||
return
|
||||
|
||||
to_chat(user, "<span class='notice'>You fold [src] flat.</span>")
|
||||
var/obj/item/I = new foldable(get_turf(src))
|
||||
user.put_in_hands(I)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/weapon/storage/box/large
|
||||
name = "large box"
|
||||
desc = "You could build a fort with this."
|
||||
icon_state = "largebox"
|
||||
w_class = 42 // Big, bulky.
|
||||
foldable = /obj/item/stack/sheet/cardboard //BubbleWrap
|
||||
foldable = /obj/item/stack/sheet/cardboard
|
||||
storage_slots = 21
|
||||
max_combined_w_class = 42 // 21*2
|
||||
|
||||
@@ -639,19 +665,16 @@
|
||||
slot_flags = SLOT_BELT
|
||||
can_hold = list(/obj/item/weapon/match)
|
||||
|
||||
New()
|
||||
..()
|
||||
for(var/i=1; i <= storage_slots; i++)
|
||||
new /obj/item/weapon/match(src)
|
||||
/obj/item/weapon/storage/box/matches/New()
|
||||
..()
|
||||
for(var/i in 1 to storage_slots)
|
||||
new /obj/item/weapon/match(src)
|
||||
|
||||
attackby(obj/item/weapon/match/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/weapon/match) && W.lit == 0)
|
||||
W.lit = 1
|
||||
W.icon_state = "match_lit"
|
||||
processing_objects.Add(W)
|
||||
playsound(user.loc, 'sound/goonstation/misc/matchstick_light.ogg', 50, 1)
|
||||
W.update_icon()
|
||||
return
|
||||
/obj/item/weapon/storage/box/matches/attackby(obj/item/weapon/match/W, mob/user, params)
|
||||
if(istype(W, /obj/item/weapon/match) && !W.lit)
|
||||
W.matchignite()
|
||||
playsound(user.loc, 'sound/goonstation/misc/matchstick_light.ogg', 50, 1)
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/box/autoinjectors
|
||||
name = "box of injectors"
|
||||
@@ -681,7 +704,7 @@
|
||||
icon_state = "light"
|
||||
desc = "This box is shaped on the inside so that only light tubes and bulbs fit."
|
||||
item_state = "syringe_kit"
|
||||
foldable = /obj/item/stack/sheet/cardboard //BubbleWrap
|
||||
foldable = /obj/item/stack/sheet/cardboard
|
||||
storage_slots=21
|
||||
can_hold = list(/obj/item/weapon/light/tube, /obj/item/weapon/light/bulb)
|
||||
max_combined_w_class = 21
|
||||
|
||||
@@ -266,6 +266,13 @@
|
||||
item_state = "cigpacket"
|
||||
default_reagents = list("nicotine" = 15, "omnizine" = 15)
|
||||
|
||||
/obj/item/weapon/storage/fancy/cigarettes/cigpack_med
|
||||
name = "Medical Marijuana Packet"
|
||||
desc = "A prescription packet containing six marijuana cigarettes."
|
||||
icon_state = "medpacket"
|
||||
item_state = "cigpacket"
|
||||
default_reagents = list("thc" = 15)
|
||||
|
||||
/obj/item/weapon/storage/fancy/cigarettes/cigpack_uplift
|
||||
name = "\improper Uplift Smooth packet"
|
||||
desc = "Your favorite brand, now menthol flavored."
|
||||
|
||||
@@ -22,7 +22,6 @@
|
||||
var/allow_quick_empty //Set this variable to allow the object to have the 'empty' verb, which dumps all the contents on the floor.
|
||||
var/allow_quick_gather //Set this variable to allow the object to have the 'toggle mode' verb, which quickly collects all items from a tile.
|
||||
var/collection_mode = 1; //0 = pick one at a time, 1 = pick all on tile
|
||||
var/foldable = null // BubbleWrap - if set, can be folded (when empty) into a sheet of cardboard
|
||||
var/use_sound = "rustle" //sound played when used. null for no sound.
|
||||
|
||||
/obj/item/weapon/storage/MouseDrop(obj/over_object as obj)
|
||||
@@ -474,35 +473,12 @@
|
||||
for(var/obj/O in contents)
|
||||
O.hear_message(M, msg)
|
||||
|
||||
// BubbleWrap - A box can be folded up to make card
|
||||
/obj/item/weapon/storage/attack_self(mob/user as mob)
|
||||
/obj/item/weapon/storage/attack_self(mob/user)
|
||||
|
||||
//Clicking on itself will empty it, if it has the verb to do that.
|
||||
if(user.is_in_active_hand(src))
|
||||
if(src.verbs.Find(/obj/item/weapon/storage/verb/quick_empty))
|
||||
src.quick_empty()
|
||||
return
|
||||
|
||||
//Otherwise we'll try to fold it.
|
||||
if( contents.len )
|
||||
return
|
||||
|
||||
if( !ispath(src.foldable) )
|
||||
return
|
||||
var/found = 0
|
||||
// Close any open UI windows first
|
||||
for(var/mob/M in range(1))
|
||||
if(M.s_active == src)
|
||||
src.close(M)
|
||||
if( M == user )
|
||||
found = 1
|
||||
if( !found ) // User is too far away
|
||||
return
|
||||
// Now make the cardboard
|
||||
to_chat(user, "<span class='notice'>You fold [src] flat.</span>")
|
||||
new src.foldable(get_turf(src))
|
||||
qdel(src)
|
||||
//BubbleWrap END
|
||||
if(verbs.Find(/obj/item/weapon/storage/verb/quick_empty))
|
||||
quick_empty()
|
||||
|
||||
//Returns the storage depth of an atom. This is the number of storage items the atom is contained in before reaching toplevel (the area).
|
||||
//Returns -1 if the atom was not found on container.
|
||||
|
||||
@@ -241,4 +241,24 @@
|
||||
..()
|
||||
for(var/i in 1 to 3)
|
||||
new/obj/item/cardboard_cutout/adaptive(src)
|
||||
new/obj/item/toy/crayon/spraycan(src)
|
||||
new/obj/item/toy/crayon/spraycan(src)
|
||||
|
||||
/obj/item/weapon/storage/box/syndie_kit/bonerepair
|
||||
name = "bone repair kit"
|
||||
desc = "A box containing one prototype field bone repair kit."
|
||||
|
||||
/obj/item/weapon/storage/box/syndie_kit/bonerepair/New()
|
||||
..()
|
||||
new /obj/item/weapon/reagent_containers/hypospray/autoinjector/nanocalcium(src)
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(src)
|
||||
P.name = "Bone repair guide"
|
||||
P.desc = "For when you want to safely get off Mr Bones' Wild Ride."
|
||||
P.info = {"
|
||||
<font face="Verdana" color=black></font><font face="Verdana" color=black><center><B>Prototype Bone Repair Nanites</B><HR></center><BR><BR>
|
||||
|
||||
<B>Usage:</B> <BR><BR><BR>
|
||||
|
||||
<font size = "1">This is a highly experimental prototype chemical designed to repair damaged bones of soldiers in the field, use only as a last resort. The autoinjector contains prototype nanites bearing a calcium based payload. The nanites will simultaneously shut down body systems whilst aiding bone repair.<BR><BR><BR>Warning: Side effects can cause temporary paralysis, loss of co-ordination and sickness. <B>Do not use with any kind of stimulant or drugs. Serious damage can occur!</B><BR><BR><BR>
|
||||
|
||||
To apply, hold the injector a short distance away from the outer thigh before applying firmly to the skin surface. Bones should begin repair after a short time, during which you are advised to remain still. <BR><BR><BR><BR>After use you are advised to see a doctor at the next available opportunity. Mild scarring and tissue damage may occur after use. This is a prototype.</font><BR><HR></font>
|
||||
"}
|
||||
@@ -89,7 +89,7 @@
|
||||
return
|
||||
|
||||
/obj/item/weapon/melee/baton/attack_self(mob/user)
|
||||
if(bcell && bcell.charge > hitcost)
|
||||
if(bcell && bcell.charge >= hitcost)
|
||||
status = !status
|
||||
to_chat(user, "<span class='notice'>[src] is now [status ? "on" : "off"].</span>")
|
||||
playsound(loc, "sparks", 75, 1, -1)
|
||||
|
||||
@@ -7,9 +7,10 @@
|
||||
/*
|
||||
* Banhammer
|
||||
*/
|
||||
/obj/item/weapon/banhammer/attack(mob/M as mob, mob/user as mob)
|
||||
/obj/item/weapon/banhammer/attack(mob/M, mob/user)
|
||||
to_chat(M, "<font color='red'><b> You have been banned FOR NO REISIN by [user]<b></font>")
|
||||
to_chat(user, "<font color='red'> You have <b>BANNED</b> [M]</font>")
|
||||
playsound(loc, 'sound/effects/adminhelp.ogg', 15) //keep it at 15% volume so people don't jump out of their skin too much
|
||||
|
||||
/*
|
||||
* Classic Baton
|
||||
|
||||
@@ -8,14 +8,12 @@
|
||||
slot_flags = SLOT_BACK
|
||||
hitsound = 'sound/weapons/smash.ogg'
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
|
||||
pressure_resistance = ONE_ATMOSPHERE*5
|
||||
|
||||
force = 5.0
|
||||
throwforce = 10.0
|
||||
throw_speed = 1
|
||||
throw_range = 4
|
||||
|
||||
armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 10, bio = 0, rad = 0)
|
||||
actions_types = list(/datum/action/item_action/set_internals)
|
||||
var/datum/gas_mixture/air_contents = null
|
||||
var/distribute_pressure = ONE_ATMOSPHERE
|
||||
@@ -143,7 +141,7 @@
|
||||
|
||||
/obj/item/weapon/tank/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
// update the ui if it exists, returns null if no ui is passed/found
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
// the ui does not exist, so we'll create a new() one
|
||||
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
|
||||
|
||||
@@ -103,6 +103,7 @@ Frequency:
|
||||
throw_range = 5
|
||||
materials = list(MAT_METAL=10000)
|
||||
origin_tech = "magnets=3;bluespace=4"
|
||||
armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 30, bio = 0, rad = 0)
|
||||
var/active_portals = 0
|
||||
|
||||
/obj/item/weapon/hand_tele/attack_self(mob/user as mob)
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
icon_state = "drill_bolt"
|
||||
item_state = "drill"
|
||||
usesound = 'sound/items/drill_use.ogg'
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_GOLD=25)
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25)
|
||||
origin_tech = "materials=2;engineering=2" //done for balance reasons, making them high value for research, but harder to get
|
||||
force = 8 //might or might not be too high, subject to change
|
||||
throwforce = 8
|
||||
@@ -180,7 +180,7 @@
|
||||
desc = "A simple hand drill with a screwdriver bit attached."
|
||||
icon_state = "drill_screw"
|
||||
item_state = "drill"
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_GOLD=25)
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25)
|
||||
origin_tech = "materials=2;engineering=2" //done for balance reasons, making them high value for research, but harder to get
|
||||
force = 8 //might or might not be too high, subject to change
|
||||
throwforce = 8
|
||||
@@ -276,7 +276,7 @@
|
||||
icon_state = "jaws_cutter"
|
||||
item_state = "jawsoflife"
|
||||
origin_tech = "materials=2;engineering=2"
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_GOLD=25)
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25)
|
||||
usesound = 'sound/items/jaws_cut.ogg'
|
||||
toolspeed = 0.25
|
||||
|
||||
@@ -691,7 +691,7 @@ obj/item/weapon/weldingtool/experimental/process()
|
||||
desc = "A set of jaws of life, the magic of science has managed to fit it down into a device small enough to fit in a tool belt. It's fitted with a prying head."
|
||||
icon_state = "jaws_pry"
|
||||
item_state = "jawsoflife"
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_DIAMOND=25)
|
||||
materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25)
|
||||
origin_tech = "materials=2;engineering=2"
|
||||
usesound = 'sound/items/jaws_pry.ogg'
|
||||
force = 15
|
||||
|
||||
@@ -208,15 +208,21 @@
|
||||
attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")
|
||||
block_chance = 75
|
||||
sharp = 1
|
||||
light_power = 2
|
||||
var/brightness_on = 2
|
||||
var/colormap = list(red=LIGHT_COLOR_RED, blue=LIGHT_COLOR_LIGHTBLUE, green=LIGHT_COLOR_GREEN, purple=LIGHT_COLOR_PURPLE, rainbow=LIGHT_COLOR_WHITE)
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/New()
|
||||
blade_color = pick("red", "blue", "green", "purple")
|
||||
if(!blade_color)
|
||||
blade_color = pick("red", "blue", "green", "purple")
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/update_icon()
|
||||
if(wielded)
|
||||
icon_state = "dualsaber[blade_color][wielded]"
|
||||
set_light(brightness_on, l_color=colormap[blade_color])
|
||||
else
|
||||
icon_state = "dualsaber0"
|
||||
set_light(0)
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/attack(target as mob, mob/living/user as mob)
|
||||
if(HULK in user.mutations)
|
||||
@@ -239,16 +245,16 @@
|
||||
return ..()
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/green/New()
|
||||
/obj/item/weapon/twohanded/dualsaber/green
|
||||
blade_color = "green"
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/red/New()
|
||||
/obj/item/weapon/twohanded/dualsaber/red
|
||||
blade_color = "red"
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/purple/New()
|
||||
/obj/item/weapon/twohanded/dualsaber/purple
|
||||
blade_color = "purple"
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/blue/New()
|
||||
/obj/item/weapon/twohanded/dualsaber/blue
|
||||
blade_color = "blue"
|
||||
|
||||
/obj/item/weapon/twohanded/dualsaber/unwield()
|
||||
@@ -539,6 +545,7 @@
|
||||
throwforce = 15
|
||||
throw_range = 1
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
armor = list(melee = 50, bullet = 50, laser = 50, energy = 0, bomb = 50, bio = 0, rad = 0)
|
||||
var/charged = 5
|
||||
origin_tech = "combat=4;bluespace=4;plasmatech=7"
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
/obj/item/weapon/vending_refill/coffee
|
||||
machine_name = "hot drinks"
|
||||
icon_state = "refill_joe"
|
||||
charges = 28//of 85
|
||||
charges = 35//of 105
|
||||
|
||||
/obj/item/weapon/vending_refill/snack
|
||||
machine_name = "Getmore Chocolate Corp"
|
||||
|
||||
@@ -1,6 +1,32 @@
|
||||
//the essential proc to call when an obj must receive damage of any kind.
|
||||
/obj/proc/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir, armour_penetration = 0)
|
||||
if(sound_effect)
|
||||
play_attack_sound(damage_amount, damage_type, damage_flag)
|
||||
if(!(resistance_flags & INDESTRUCTIBLE) && obj_integrity > 0)
|
||||
damage_amount = run_obj_armor(damage_amount, damage_type, damage_flag, attack_dir, armour_penetration)
|
||||
if(damage_amount >= 0.1)
|
||||
. = damage_amount
|
||||
var/old_integ = obj_integrity
|
||||
obj_integrity = max(old_integ - damage_amount, 0)
|
||||
if(obj_integrity <= 0)
|
||||
var/int_fail = integrity_failure
|
||||
if(int_fail && old_integ > int_fail)
|
||||
obj_break(damage_flag)
|
||||
obj_destruction(damage_flag)
|
||||
else if(integrity_failure)
|
||||
if(obj_integrity <= integrity_failure)
|
||||
obj_break(damage_flag)
|
||||
|
||||
/obj/proc/take_damage()
|
||||
return
|
||||
//returns the damage value of the attack after processing the obj's various armor protections
|
||||
/obj/proc/run_obj_armor(damage_amount, damage_type, damage_flag = 0, attack_dir, armour_penetration = 0)
|
||||
if(!(damage_type in list(BRUTE, BURN)))
|
||||
return 0
|
||||
var/armor_protection = 0
|
||||
if(damage_flag)
|
||||
armor_protection = armor[damage_flag]
|
||||
if(armor_protection) //Only apply weak-against-armor/hollowpoint effects if there actually IS armor.
|
||||
armor_protection = Clamp(armor_protection - armour_penetration, 0, 100)
|
||||
return round(damage_amount * (100 - armor_protection) * 0.01, 0.1)
|
||||
|
||||
//the sound played when the obj is damaged.
|
||||
/obj/proc/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0)
|
||||
@@ -13,6 +39,95 @@
|
||||
if(BURN)
|
||||
playsound(src.loc, 'sound/items/welder.ogg', 100, 1)
|
||||
|
||||
/obj/hitby(atom/movable/AM)
|
||||
..()
|
||||
var/tforce = 0
|
||||
if(ismob(AM))
|
||||
tforce = 10
|
||||
else if(istype(AM, /obj))
|
||||
var/obj/O = AM
|
||||
tforce = O.throwforce
|
||||
take_damage(tforce, BRUTE, "melee", 1, get_dir(src, AM))
|
||||
|
||||
/obj/ex_act(severity, target)
|
||||
if(resistance_flags & INDESTRUCTIBLE)
|
||||
return
|
||||
if(target == src)
|
||||
obj_integrity = 0
|
||||
qdel(src)
|
||||
return
|
||||
switch(severity)
|
||||
if(1)
|
||||
obj_integrity = 0
|
||||
qdel(src)
|
||||
if(2)
|
||||
take_damage(rand(100, 250), BRUTE, "bomb", 0)
|
||||
if(3)
|
||||
take_damage(rand(10, 90), BRUTE, "bomb", 0)
|
||||
|
||||
/obj/bullet_act(obj/item/projectile/P)
|
||||
. = ..()
|
||||
playsound(src, P.hitsound, 50, 1)
|
||||
visible_message("<span class='danger'>[src] is hit by \a [P]!</span>")
|
||||
take_damage(P.damage, P.damage_type, P.flag, 0, turn(P.dir, 180), P.armour_penetration)
|
||||
|
||||
/obj/blob_act(obj/structure/blob/B)
|
||||
if(isturf(loc))
|
||||
var/turf/T = loc
|
||||
if(T.intact && level == 1) //the blob doesn't destroy thing below the floor
|
||||
return
|
||||
take_damage(400, BRUTE, "melee", 0, get_dir(src, B))
|
||||
|
||||
/obj/proc/attack_generic(mob/user, damage_amount = 0, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, armor_penetration = 0) //used by attack_alien, attack_animal, and attack_slime
|
||||
user.do_attack_animation(src)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
return take_damage(damage_amount, damage_type, damage_flag, sound_effect, get_dir(src, user), armor_penetration)
|
||||
|
||||
/obj/attack_alien(mob/living/carbon/alien/humanoid/user)
|
||||
if(attack_generic(user, 60, BRUTE, "melee", 0))
|
||||
playsound(loc, 'sound/weapons/slash.ogg', 100, 1)
|
||||
|
||||
/obj/attack_animal(mob/living/simple_animal/M)
|
||||
if(!M.melee_damage_upper && !M.obj_damage)
|
||||
M.custom_emote(1, "[M.friendly] [src]")
|
||||
return 0
|
||||
else
|
||||
var/play_soundeffect = 1
|
||||
if(M.environment_smash)
|
||||
play_soundeffect = 0
|
||||
if(M.obj_damage)
|
||||
. = attack_generic(M, M.obj_damage, M.melee_damage_type, "melee", play_soundeffect, M.armour_penetration)
|
||||
else
|
||||
. = attack_generic(M, rand(M.melee_damage_lower,M.melee_damage_upper), M.melee_damage_type, "melee", play_soundeffect, M.armour_penetration)
|
||||
if(. && !play_soundeffect)
|
||||
playsound(src, 'sound/effects/meteorimpact.ogg', 100, 1)
|
||||
|
||||
/obj/attack_slime(mob/living/carbon/slime/user)
|
||||
if(!user.is_adult)
|
||||
return
|
||||
attack_generic(user, rand(10, 15), "melee", 1)
|
||||
|
||||
/obj/mech_melee_attack(obj/mecha/M)
|
||||
M.do_attack_animation(src)
|
||||
var/play_soundeffect = 0
|
||||
var/mech_damtype = M.damtype
|
||||
if(M.selected)
|
||||
mech_damtype = M.selected.damtype
|
||||
play_soundeffect = 1
|
||||
else
|
||||
switch(M.damtype)
|
||||
if(BRUTE)
|
||||
playsound(src, 'sound/weapons/punch4.ogg', 50, 1)
|
||||
if(BURN)
|
||||
playsound(src, 'sound/items/welder.ogg', 50, 1)
|
||||
if(TOX)
|
||||
playsound(src, 'sound/effects/spray2.ogg', 50, 1)
|
||||
return 0
|
||||
else
|
||||
return 0
|
||||
visible_message("<span class='danger'>[M.name] has hit [src].</span>")
|
||||
return take_damage(M.force*3, mech_damtype, "melee", play_soundeffect, get_dir(src, M)) // multiplied by 3 so we can hit objs hard but not be overpowered against mobs.
|
||||
|
||||
/obj/singularity_act()
|
||||
ex_act(1)
|
||||
if(src && !qdeleted(src))
|
||||
@@ -24,7 +139,7 @@
|
||||
/obj/fire_act(global_overlay=1)
|
||||
if(!burn_state)
|
||||
burn_state = ON_FIRE
|
||||
fire_master.burning += src
|
||||
SSfires.processing[src] = src
|
||||
burn_world_time = world.time + burntime*rand(10,20)
|
||||
if(global_overlay)
|
||||
overlays += fire_overlay
|
||||
@@ -34,14 +149,14 @@
|
||||
empty_object_contents(1, loc)
|
||||
var/obj/effect/decal/cleanable/ash/A = new(loc)
|
||||
A.desc = "Looks like this used to be a [name] some time ago."
|
||||
fire_master.burning -= src
|
||||
SSfires.processing -= src
|
||||
qdel(src)
|
||||
|
||||
/obj/proc/extinguish()
|
||||
if(burn_state == ON_FIRE)
|
||||
burn_state = FLAMMABLE
|
||||
overlays -= fire_overlay
|
||||
fire_master.burning -= src
|
||||
SSfires.processing -= src
|
||||
|
||||
/obj/proc/tesla_act(power)
|
||||
being_shocked = TRUE
|
||||
@@ -54,4 +169,40 @@
|
||||
|
||||
//the obj is deconstructed into pieces, whether through careful disassembly or when destroyed.
|
||||
/obj/proc/deconstruct(disassembled = TRUE)
|
||||
qdel(src)
|
||||
qdel(src)
|
||||
|
||||
//what happens when the obj's health is below integrity_failure level.
|
||||
/obj/proc/obj_break(damage_flag)
|
||||
return
|
||||
|
||||
//what happens when the obj's integrity reaches zero.
|
||||
/obj/proc/obj_destruction(damage_flag)
|
||||
if(damage_flag == BURN)
|
||||
burn()
|
||||
else
|
||||
deconstruct(FALSE)
|
||||
|
||||
//changes max_integrity while retaining current health percentage
|
||||
//returns TRUE if the obj broke, FALSE otherwise
|
||||
/obj/proc/modify_max_integrity(new_max, can_break = TRUE, damage_type = BRUTE, new_failure_integrity = null)
|
||||
var/current_integrity = obj_integrity
|
||||
var/current_max = max_integrity
|
||||
|
||||
if(current_integrity != 0 && current_max != 0)
|
||||
var/percentage = current_integrity / current_max
|
||||
current_integrity = max(1, round(percentage * new_max)) //don't destroy it as a result
|
||||
obj_integrity = current_integrity
|
||||
|
||||
max_integrity = new_max
|
||||
|
||||
if(new_failure_integrity != null)
|
||||
integrity_failure = new_failure_integrity
|
||||
|
||||
if(can_break && integrity_failure && current_integrity <= integrity_failure)
|
||||
obj_break(damage_type)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
//returns how much the object blocks an explosion
|
||||
/obj/proc/GetExplosionBlock()
|
||||
CRASH("Unimplemented GetExplosionBlock()")
|
||||
|
||||
@@ -12,11 +12,13 @@
|
||||
var/can_deconstruct = TRUE
|
||||
var/damtype = "brute"
|
||||
var/force = 0
|
||||
|
||||
var/list/armor
|
||||
var/obj_integrity //defaults to max_integrity
|
||||
var/max_integrity = 500
|
||||
var/max_integrity = INFINITY
|
||||
var/integrity_failure = 0 //0 if we have no special broken behavior
|
||||
|
||||
var/resistance_flags = NONE // INDESTRUCTIBLE
|
||||
|
||||
var/Mtoollink = 0 // variable to decide if an object should show the multitool menu linking menu, not all objects use it
|
||||
|
||||
var/burn_state = FIRE_PROOF // LAVA_PROOF | FIRE_PROOF | FLAMMABLE | ON_FIRE
|
||||
@@ -28,7 +30,9 @@
|
||||
var/force_blueprints = FALSE //forces the obj to be on the blueprints, regardless of when it was created.
|
||||
|
||||
/obj/New()
|
||||
. = ..()
|
||||
..()
|
||||
if(!armor)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0)
|
||||
if(obj_integrity == null)
|
||||
obj_integrity = max_integrity
|
||||
if(on_blueprints && isturf(loc))
|
||||
@@ -62,7 +66,7 @@
|
||||
/obj/Destroy()
|
||||
machines -= src
|
||||
processing_objects -= src
|
||||
nanomanager.close_uis(src)
|
||||
SSnanoui.close_uis(src)
|
||||
return ..()
|
||||
|
||||
/obj/proc/process()
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
pressure_resistance = 8
|
||||
var/climbable
|
||||
var/mob/climber
|
||||
var/broken = FALSE
|
||||
|
||||
/obj/structure/blob_act()
|
||||
if(prob(50))
|
||||
@@ -164,3 +165,24 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/structure/examine(mob/user)
|
||||
..()
|
||||
if(!(resistance_flags & INDESTRUCTIBLE))
|
||||
if(burn_state == ON_FIRE)
|
||||
to_chat(user, "<span class='warning'>It's on fire!</span>")
|
||||
if(broken)
|
||||
to_chat(user, "<span class='notice'>It appears to be broken.</span>")
|
||||
var/examine_status = examine_status(user)
|
||||
if(examine_status)
|
||||
to_chat(user, examine_status)
|
||||
|
||||
/obj/structure/proc/examine_status(mob/user) //An overridable proc, mostly for falsewalls.
|
||||
var/healthpercent = (obj_integrity/max_integrity) * 100
|
||||
switch(healthpercent)
|
||||
if(50 to 99)
|
||||
return "It looks slightly damaged."
|
||||
if(25 to 50)
|
||||
return "It appears heavily damaged."
|
||||
if(0 to 25)
|
||||
if(!broken)
|
||||
return "<span class='warning'>It's falling apart!</span>"
|
||||
|
||||
@@ -4,17 +4,14 @@
|
||||
icon = 'icons/obj/barsigns.dmi'
|
||||
icon_state = "empty"
|
||||
req_access = list(access_bar)
|
||||
armor = list(melee = 20, bullet = 20, laser = 20, energy = 100, bomb = 0, bio = 0, rad = 0)
|
||||
var/list/barsigns=list()
|
||||
var/list/hiddensigns
|
||||
var/broken = 0
|
||||
var/emagged = 0
|
||||
var/state = 0
|
||||
var/prev_sign = ""
|
||||
var/panel_open = 0
|
||||
|
||||
|
||||
|
||||
|
||||
/obj/structure/sign/barsign/New()
|
||||
..()
|
||||
|
||||
|
||||
@@ -19,6 +19,11 @@ LINEN BINS
|
||||
burn_state = FLAMMABLE
|
||||
slot_flags = SLOT_BACK
|
||||
|
||||
var/list/dream_messages = list("white")
|
||||
var/list/nightmare_messages = list("black")
|
||||
var/comfort = 0.5
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/bedsheet/attack_self(mob/user as mob)
|
||||
user.drop_item()
|
||||
@@ -33,126 +38,174 @@ LINEN BINS
|
||||
/obj/item/weapon/bedsheet/blue
|
||||
icon_state = "sheetblue"
|
||||
item_color = "blue"
|
||||
dream_messages = list("blue")
|
||||
nightmare_messages = list("vox blood")
|
||||
|
||||
/obj/item/weapon/bedsheet/green
|
||||
icon_state = "sheetgreen"
|
||||
item_color = "green"
|
||||
dream_messages = list("green")
|
||||
nightmare_messages = list("unathi flesh")
|
||||
|
||||
/obj/item/weapon/bedsheet/orange
|
||||
icon_state = "sheetorange"
|
||||
item_color = "orange"
|
||||
dream_messages = list("orange")
|
||||
nightmare_messages = list("exploding fruit")
|
||||
|
||||
/obj/item/weapon/bedsheet/purple
|
||||
icon_state = "sheetpurple"
|
||||
item_color = "purple"
|
||||
dream_messages = list("purple")
|
||||
nightmare_messages = list("Grey blood")
|
||||
|
||||
/obj/item/weapon/bedsheet/patriot
|
||||
name = "patriotic bedsheet"
|
||||
desc = "You've never felt more free than when sleeping on this."
|
||||
icon_state = "sheetUSA"
|
||||
item_color = "sheetUSA"
|
||||
dream_messages = list("America", "freedom", "fireworks", "bald eagles")
|
||||
nightmare_messages = list("communism")
|
||||
|
||||
/obj/item/weapon/bedsheet/rainbow
|
||||
name = "rainbow bedsheet"
|
||||
desc = "A multi_colored blanket. It's actually several different sheets cut up and sewn together."
|
||||
icon_state = "sheetrainbow"
|
||||
item_color = "rainbow"
|
||||
dream_messages = list("red", "orange", "yellow", "green", "blue", "purple", "a rainbow")
|
||||
nightmare_messages = list("green", "a cluwne", "fLoOr ClUwNe")
|
||||
|
||||
/obj/item/weapon/bedsheet/red
|
||||
icon_state = "sheetred"
|
||||
item_color = "red"
|
||||
dream_messages = list("red")
|
||||
nightmare_messages = list("gibs")
|
||||
|
||||
/obj/item/weapon/bedsheet/yellow
|
||||
icon_state = "sheetyellow"
|
||||
item_color = "yellow"
|
||||
dream_messages = list("yellow")
|
||||
nightmare_messages = list("locker full of banana peels")
|
||||
|
||||
/obj/item/weapon/bedsheet/mime
|
||||
name = "mime's blanket"
|
||||
desc = "A very soothing striped blanket. All the noise just seems to fade out when you're under the covers in this."
|
||||
icon_state = "sheetmime"
|
||||
item_color = "mime"
|
||||
dream_messages = list("silence", "gestures", "a pale face", "a gaping mouth", "the mime")
|
||||
nightmare_messages = list("honk", "laughter", "a prank", "a joke", "a smiling face", "the clown")
|
||||
|
||||
/obj/item/weapon/bedsheet/clown
|
||||
name = "clown's blanket"
|
||||
desc = "A rainbow blanket with a clown mask woven in. It smells faintly of bananas."
|
||||
icon_state = "sheetclown"
|
||||
item_color = "clown"
|
||||
dream_messages = list("honk", "laughter", "a prank", "a joke", "a smiling face", "the clown")
|
||||
nightmare_messages = list("silence", "gestures", "a pale face", "a gaping mouth", "the mime")
|
||||
|
||||
/obj/item/weapon/bedsheet/captain
|
||||
name = "captain's bedsheet."
|
||||
desc = "It has a Nanotrasen symbol on it, and was woven with a revolutionary new kind of thread guaranteed to have 0.01% permeability for most non-chemical substances, popular among most modern captains."
|
||||
icon_state = "sheetcaptain"
|
||||
item_color = "captain"
|
||||
dream_messages = list("authority", "a golden ID", "sunglasses", "a green disc", "an antique gun", "the captain")
|
||||
nightmare_messages = list("comdom", "clown with all access", "the syndicate")
|
||||
|
||||
/obj/item/weapon/bedsheet/rd
|
||||
name = "research director's bedsheet"
|
||||
desc = "It appears to have a beaker emblem, and is made out of fire-resistant material, although it probably won't protect you in the event of fires you're familiar with every day."
|
||||
icon_state = "sheetrd"
|
||||
item_color = "director"
|
||||
dream_messages = list("authority", "a silvery ID", "a bomb", "a mech", "a facehugger", "maniacal laughter", "the research director")
|
||||
nightmare_messages = list("toxins full of plasma", "UPGRADE THE SLEEPERS", "rogue ai")
|
||||
|
||||
/obj/item/weapon/bedsheet/medical
|
||||
name = "medical blanket"
|
||||
desc = "It's a sterilized* blanket commonly used in the Medbay. *Sterilization is voided if a virologist is present onboard the station."
|
||||
icon_state = "sheetmedical"
|
||||
item_color = "medical"
|
||||
dream_messages = list("healing", "life", "surgery", "a doctor")
|
||||
nightmare_messages = list("death", "no cryox", "cryo is off")
|
||||
|
||||
/obj/item/weapon/bedsheet/cmo
|
||||
name = "chief medical officer's bedsheet"
|
||||
desc = "It's a sterilized blanket that has a cross emblem. There's some cat fur on it, likely from Runtime."
|
||||
icon_state = "sheetcmo"
|
||||
item_color = "cmo"
|
||||
dream_messages = list("authority", "a silvery ID", "healing", "life", "surgery", "a cat", "the chief medical officer")
|
||||
nightmare_messages = list("chemists making meth", "cryo it off", "where is the defib", "no biomass")
|
||||
|
||||
/obj/item/weapon/bedsheet/hos
|
||||
name = "head of security's bedsheet"
|
||||
desc = "It is decorated with a shield emblem. While crime doesn't sleep, you do, but you are still THE LAW!"
|
||||
icon_state = "sheethos"
|
||||
item_color = "hosred"
|
||||
dream_messages = list("authority", "a silvery ID", "handcuffs", "a baton", "a flashbang", "sunglasses", "the head of security")
|
||||
nightmare_messages = list("the clown", "a toolbox", "sHiTcUrItY", "why did you put them in for 50 minutes")
|
||||
|
||||
|
||||
/obj/item/weapon/bedsheet/hop
|
||||
name = "head of personnel's bedsheet"
|
||||
desc = "It is decorated with a key emblem. For those rare moments when you can rest and cuddle with Ian without someone screaming for you over the radio."
|
||||
icon_state = "sheethop"
|
||||
item_color = "hop"
|
||||
dream_messages = list("authority", "a silvery ID", "obligation", "a computer", "an ID", "a corgi", "the head of personnel")
|
||||
nightmare_messages = list("improper paperwork", "all access clown", "50 open clown slots", "dead ian")
|
||||
|
||||
/obj/item/weapon/bedsheet/ce
|
||||
name = "chief engineer's bedsheet"
|
||||
desc = "It is decorated with a wrench emblem. It's highly reflective and stain resistant, so you don't need to worry about ruining it with oil."
|
||||
icon_state = "sheetce"
|
||||
item_color = "chief"
|
||||
dream_messages = list("authority", "a silvery ID", "the engine", "power tools", "an APC", "a parrot", "the chief engineer")
|
||||
nightmare_messages = list("forced airlock", "syndicate bomb", "explosion in research chem", "iT's LoOsE")
|
||||
|
||||
/obj/item/weapon/bedsheet/qm
|
||||
name = "quartermaster's bedsheet"
|
||||
desc = "It is decorated with a crate emblem in silver lining. It's rather tough, and just the thing to lie on after a hard day of pushing paper."
|
||||
icon_state = "sheetqm"
|
||||
item_color = "qm"
|
||||
dream_messages = list("a grey ID", "a shuttle", "a crate", "a sloth", "the quartermaster")
|
||||
nightmare_messages = list("a bald person", "no points", "wheres the ore", "space carp")
|
||||
|
||||
/obj/item/weapon/bedsheet/brown
|
||||
icon_state = "sheetbrown"
|
||||
item_color = "cargo"
|
||||
dream_messages = list("brown")
|
||||
nightmare_messages = list("dead monkey")
|
||||
|
||||
/obj/item/weapon/bedsheet/centcom
|
||||
name = "centcom bedsheet"
|
||||
desc = "Woven with advanced nanothread for warmth as well as being very decorated, essential for all officials."
|
||||
icon_state = "sheetcentcom"
|
||||
item_color = "centcom"
|
||||
dream_messages = list("a unique ID", "authority", "artillery", "an ending")
|
||||
nightmare_messages = list("a butt fax")
|
||||
|
||||
/obj/item/weapon/bedsheet/syndie
|
||||
name = "syndicate bedsheet"
|
||||
desc = "It has a syndicate emblem and it has an aura of evil."
|
||||
icon_state = "sheetsyndie"
|
||||
item_color = "syndie"
|
||||
dream_messages = list("a green disc", "a red crystal", "a glowing blade", "a wire-covered ID")
|
||||
nightmare_messages = list("stunbaton", "taser", "lasers", "a toolbox")
|
||||
|
||||
/obj/item/weapon/bedsheet/cult
|
||||
name = "cultist's bedsheet"
|
||||
desc = "You might dream of Nar'Sie if you sleep with this. It seems rather tattered and glows of an eldritch presence."
|
||||
icon_state = "sheetcult"
|
||||
item_color = "cult"
|
||||
dream_messages = list("a tome", "a floating red crystal", "a glowing sword", "a bloody symbol", "a massive humanoid figure")
|
||||
nightmare_messages = list("a tome", "a floating red crystal", "a glowing sword", "a bloody symbol", "a massive humanoid figure")
|
||||
|
||||
|
||||
/obj/item/weapon/bedsheet/wiz
|
||||
name = "wizard's bedsheet"
|
||||
desc = "A special fabric enchanted with magic so you can have an enchanted night. It even glows!"
|
||||
icon_state = "sheetwiz"
|
||||
item_color = "wiz"
|
||||
dream_messages = list("a book", "an explosion", "lightning", "a staff", "a skeleton", "a robe", "magic")
|
||||
nightmare_messages = list("a toolbox", "solars")
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -4,12 +4,12 @@
|
||||
icon = 'icons/obj/closet.dmi'
|
||||
icon_state = "closed"
|
||||
density = 1
|
||||
armor = list(melee = 20, bullet = 10, laser = 10, energy = 0, bomb = 10, bio = 0, rad = 0)
|
||||
var/icon_closed = "closed"
|
||||
var/icon_opened = "open"
|
||||
var/opened = 0
|
||||
var/welded = 0
|
||||
var/locked = 0
|
||||
var/broken = 0
|
||||
var/wall_mounted = 0 //never solid (You can always pass over it)
|
||||
var/health = 100
|
||||
var/lastbang
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
icon_opened = "fireaxe1100"
|
||||
anchored = 1
|
||||
density = 0
|
||||
armor = list(melee = 50, bullet = 50, laser = 50, energy = 100, bomb = 10, bio = 100, rad = 100)
|
||||
var/localopened = 0 //Setting this to keep it from behaviouring like a normal closet and obstructing movement in the map. -Agouri
|
||||
opened = 1
|
||||
var/hitstaken = 0
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
new /obj/item/clothing/head/beret/eng(src)
|
||||
new /obj/item/weapon/door_remote/chief_engineer(src)
|
||||
new /obj/item/weapon/rpd(src)
|
||||
new /obj/item/weapon/reagent_containers/food/drinks/mug/ce(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/engineering_electrical
|
||||
|
||||
@@ -111,8 +111,15 @@
|
||||
..()
|
||||
new /obj/item/weapon/reagent_containers/food/pill/haloperidol(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/haloperidol(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/haloperidol(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/methamphetamine(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/methamphetamine(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/methamphetamine(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/patch/nicotine(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/patch/nicotine(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/patch/nicotine(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/hydrocodone(src)
|
||||
new /obj/item/weapon/reagent_containers/food/pill/hydrocodone(src)
|
||||
|
||||
/obj/structure/closet/secure_closet/psychiatrist
|
||||
name = "psychiatrist's locker"
|
||||
@@ -129,8 +136,14 @@
|
||||
new /obj/item/clothing/suit/straight_jacket(src)
|
||||
new /obj/item/weapon/reagent_containers/syringe(src)
|
||||
new /obj/item/weapon/reagent_containers/glass/bottle/ether(src)
|
||||
new /obj/item/weapon/storage/fancy/cigarettes/cigpack_med(src)
|
||||
new /obj/item/weapon/storage/fancy/cigarettes/cigpack_med(src)
|
||||
new /obj/item/weapon/storage/fancy/cigarettes/cigpack_med(src)
|
||||
new /obj/item/weapon/storage/pill_bottle/psychiatrist(src)
|
||||
|
||||
new /obj/random/plushie(src)
|
||||
for(var/i in 0 to 3)
|
||||
var/candy = pick(subtypesof(/obj/item/weapon/reagent_containers/food/snacks/candy/fudge))
|
||||
new candy(src)
|
||||
|
||||
/obj/structure/closet/secure_closet/CMO
|
||||
name = "chief medical officer's locker"
|
||||
@@ -173,6 +186,7 @@
|
||||
new /obj/item/weapon/reagent_containers/hypospray/CMO(src)
|
||||
new /obj/item/organ/internal/cyberimp/eyes/hud/medical(src)
|
||||
new /obj/item/weapon/door_remote/chief_medical_officer(src)
|
||||
new /obj/item/weapon/reagent_containers/food/drinks/mug/cmo(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/animal
|
||||
|
||||
@@ -71,6 +71,7 @@
|
||||
new /obj/item/device/flash(src)
|
||||
new /obj/item/device/laser_pointer(src)
|
||||
new /obj/item/weapon/door_remote/research_director(src)
|
||||
new /obj/item/weapon/reagent_containers/food/drinks/mug/rd(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/research_reagents
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
opened = 0
|
||||
locked = 1
|
||||
broken = 0
|
||||
armor = list(melee = 30, bullet = 50, laser = 50, energy = 100, bomb = 0, bio = 0, rad = 0)
|
||||
var/large = 1
|
||||
icon_closed = "secure"
|
||||
var/icon_locked = "secure1"
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
new /obj/item/weapon/storage/belt/rapier(src)
|
||||
new /obj/item/weapon/gun/energy/gun(src)
|
||||
new /obj/item/weapon/door_remote/captain(src)
|
||||
new /obj/item/weapon/reagent_containers/food/drinks/mug/cap(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/hop
|
||||
@@ -56,6 +57,7 @@
|
||||
new /obj/item/device/flash(src)
|
||||
new /obj/item/clothing/accessory/petcollar(src)
|
||||
new /obj/item/weapon/door_remote/civillian(src)
|
||||
new /obj/item/weapon/reagent_containers/food/drinks/mug/hop(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/hop2
|
||||
@@ -120,6 +122,7 @@
|
||||
new /obj/item/taperoll/police(src)
|
||||
new /obj/item/weapon/gun/energy/gun/hos(src)
|
||||
new /obj/item/weapon/door_remote/head_of_security(src)
|
||||
new /obj/item/weapon/reagent_containers/food/drinks/mug/hos(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/warden
|
||||
@@ -346,6 +349,8 @@
|
||||
new /obj/item/clothing/glasses/sunglasses/yeah(src)
|
||||
new /obj/item/device/flashlight/seclite(src)
|
||||
new /obj/item/clothing/accessory/black(src)
|
||||
new /obj/item/device/taperecorder(src)
|
||||
new /obj/item/weapon/storage/box/tapes(src)
|
||||
|
||||
/obj/structure/closet/secure_closet/detective/update_icon()
|
||||
if(broken)
|
||||
|
||||
@@ -100,6 +100,14 @@
|
||||
if(pickednum >= 40)
|
||||
new /obj/item/stack/sheet/mineral/uranium(src, rand(rare_min, rare_max))
|
||||
|
||||
//Titanium (rare ore)
|
||||
if(pickednum >= 40)
|
||||
new /obj/item/stack/sheet/mineral/titanium(src, rand(rare_min, rare_max))
|
||||
|
||||
//Plastitanium (rare ore)
|
||||
if(pickednum >= 40)
|
||||
new /obj/item/stack/sheet/mineral/plastitanium(src, rand(rare_min, rare_max))
|
||||
|
||||
//Diamond (rare HONK)
|
||||
if(pickednum >= 45)
|
||||
new /obj/item/stack/sheet/mineral/diamond(src, rand(rare_min, rare_max))
|
||||
@@ -122,6 +130,8 @@
|
||||
/obj/item/stack/sheet/mineral/uranium,
|
||||
/obj/item/stack/sheet/mineral/diamond,
|
||||
/obj/item/stack/sheet/mineral/bananium,
|
||||
/obj/item/stack/sheet/mineral/titanium,
|
||||
/obj/item/stack/sheet/mineral/plastitanium,
|
||||
/obj/item/stack/sheet/plasteel,
|
||||
/obj/item/stack/rods
|
||||
)
|
||||
|
||||
@@ -18,6 +18,7 @@ var/global/list/captain_display_cases = list()
|
||||
name = "display case frame"
|
||||
icon = 'icons/obj/stock_parts.dmi'
|
||||
icon_state = "box_glass"
|
||||
armor = list(melee = 30, bullet = 0, laser = 0, energy = 0, bomb = 10, bio = 0, rad = 0)
|
||||
var/obj/item/weapon/airlock_electronics/circuit = null
|
||||
var/obj/item/device/assembly/prox_sensor/sensor = null
|
||||
var/state = DISPLAYCASE_FRAME_CIRCUIT
|
||||
@@ -116,7 +117,7 @@ var/global/list/captain_display_cases = list()
|
||||
/obj/structure/displaycase/captains_laser
|
||||
name = "captain's display case"
|
||||
desc = "A display case for the captain's antique laser gun. Hooked up with an anti-theft system."
|
||||
burglar_alarm = 1
|
||||
burglar_alarm = 1
|
||||
locked = 1
|
||||
req_access = list(access_captain)
|
||||
start_showpiece_type = /obj/item/weapon/gun/energy/laser/captain
|
||||
|
||||
@@ -1,186 +1,57 @@
|
||||
/obj/structure/door_assembly
|
||||
icon = 'icons/obj/doors/door_assembly.dmi'
|
||||
name = "airlock assembly"
|
||||
icon_state = "door_as_0"
|
||||
anchored = 0
|
||||
density = 1
|
||||
var/state = 0
|
||||
var/base_icon_state = ""
|
||||
icon = 'icons/obj/doors/airlocks/station/public.dmi'
|
||||
icon_state = "construction"
|
||||
anchored = FALSE
|
||||
density = TRUE
|
||||
max_integrity = 200
|
||||
var/overlays_file = 'icons/obj/doors/airlocks/station/overlays.dmi'
|
||||
var/state = AIRLOCK_ASSEMBLY_NEEDS_WIRES
|
||||
var/mineral
|
||||
var/base_name = "airlock"
|
||||
var/obj/item/weapon/airlock_electronics/electronics = null
|
||||
var/airlock_type = "" //the type path of the airlock once completed
|
||||
var/glass_type = "/glass"
|
||||
var/glass = 0 // 0 = glass can be installed. -1 = glass can't be installed. 1 = glass is already installed. Text = mineral plating is installed instead.
|
||||
var/created_name = null
|
||||
var/obj/item/weapon/airlock_electronics/electronics
|
||||
var/airlock_type = /obj/machinery/door/airlock //the type path of the airlock once completed
|
||||
var/glass_type = /obj/machinery/door/airlock/glass
|
||||
var/glass = 0 // 0 = glass can be installed. 1 = glass is already installed.
|
||||
var/created_name
|
||||
var/heat_proof_finished = 0 //whether to heat-proof the finished airlock
|
||||
var/previous_assembly = /obj/structure/door_assembly
|
||||
var/noglass = FALSE //airlocks with no glass version, also cannot be modified with sheets
|
||||
var/material_type = /obj/item/stack/sheet/metal
|
||||
var/material_amt = 4
|
||||
|
||||
/obj/structure/door_assembly/New()
|
||||
update_state()
|
||||
update_icon()
|
||||
update_name()
|
||||
..()
|
||||
|
||||
/obj/structure/door_assembly/Destroy()
|
||||
QDEL_NULL(electronics)
|
||||
return ..()
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_com
|
||||
name = "command airlock assembly"
|
||||
base_icon_state = "com"
|
||||
base_name = "command airlock"
|
||||
glass_type = "/glass_command"
|
||||
airlock_type = "/command"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_sec
|
||||
name = "security airlock assembly"
|
||||
base_icon_state = "sec"
|
||||
base_name = "security airlock"
|
||||
glass_type = "/glass_security"
|
||||
airlock_type = "/security"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_eng
|
||||
name = "engineering airlock assembly"
|
||||
base_icon_state = "eng"
|
||||
base_name = "engineering airlock"
|
||||
glass_type = "/glass_engineering"
|
||||
airlock_type = "/engineering"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_min
|
||||
name = "mining airlock assembly"
|
||||
base_icon_state = "min"
|
||||
base_name = "mining airlock"
|
||||
glass_type = "/glass_mining"
|
||||
airlock_type = "/mining"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_atmo
|
||||
name = "atmospherics airlock assembly"
|
||||
base_icon_state = "atmo"
|
||||
base_name = "atmospherics airlock"
|
||||
glass_type = "/glass_atmos"
|
||||
airlock_type = "/atmos"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_research
|
||||
name = "research airlock assembly"
|
||||
base_icon_state = "res"
|
||||
base_name = "research airlock"
|
||||
glass_type = "/glass_research"
|
||||
airlock_type = "/research"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_science
|
||||
name = "science airlock assembly"
|
||||
base_icon_state = "sci"
|
||||
base_name = "science airlock"
|
||||
glass_type = "/glass_science"
|
||||
airlock_type = "/science"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_med
|
||||
name = "medical airlock assembly"
|
||||
base_icon_state = "med"
|
||||
base_name = "medical airlock"
|
||||
glass_type = "/glass_medical"
|
||||
airlock_type = "/medical"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_mai
|
||||
name = "maintenance airlock assembly"
|
||||
base_icon_state = "mai"
|
||||
base_name = "maintenance airlock"
|
||||
airlock_type = "/maintenance"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_ext
|
||||
name = "external airlock assembly"
|
||||
base_icon_state = "ext"
|
||||
base_name = "external airlock"
|
||||
airlock_type = "/external"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_fre
|
||||
name = "freezer airlock assembly"
|
||||
base_icon_state = "fre"
|
||||
base_name = "freezer airlock"
|
||||
airlock_type = "/freezer"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_hatch
|
||||
name = "airtight hatch assembly"
|
||||
base_icon_state = "hatch"
|
||||
base_name = "airtight hatch"
|
||||
airlock_type = "/hatch"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_mhatch
|
||||
name = "maintenance hatch assembly"
|
||||
base_icon_state = "mhatch"
|
||||
base_name = "maintenance hatch"
|
||||
airlock_type = "/maintenance_hatch"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_highsecurity
|
||||
name = "high security airlock assembly"
|
||||
base_icon_state = "highsec"
|
||||
base_name = "high security airlock"
|
||||
airlock_type = "/highsecurity"
|
||||
glass = -1
|
||||
material_type = /obj/item/stack/sheet/plasteel
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_vault
|
||||
name = "vault door assembly"
|
||||
base_icon_state = "vault"
|
||||
base_name = "vault door"
|
||||
airlock_type = "/vault"
|
||||
glass = -1
|
||||
material_type = /obj/item/stack/sheet/plasteel
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_shuttle
|
||||
name = "shuttle airlock assembly"
|
||||
base_icon_state = "shuttle"
|
||||
base_name = "shuttle airlock"
|
||||
airlock_type = "/shuttle"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/multi_tile
|
||||
icon = 'icons/obj/doors/door_assembly2x1.dmi'
|
||||
dir = EAST
|
||||
var/width = 1
|
||||
base_icon_state = "g" //Remember to delete this line when reverting "glass" var to 1.
|
||||
airlock_type = "/multi_tile/glass"
|
||||
glass = -1 //To prevent bugs in deconstruction process.
|
||||
|
||||
/obj/structure/door_assembly/multi_tile/New()
|
||||
if(dir in list(EAST, WEST))
|
||||
bound_width = width * world.icon_size
|
||||
bound_height = world.icon_size
|
||||
/obj/structure/door_assembly/examine(mob/user)
|
||||
..()
|
||||
var/doorname = ""
|
||||
if(created_name)
|
||||
doorname = ", written on it is '[created_name]'"
|
||||
switch(state)
|
||||
if(AIRLOCK_ASSEMBLY_NEEDS_WIRES)
|
||||
if(anchored)
|
||||
to_chat(user, "<span class='notice'>The anchoring bolts are <b>wrenched</b> in place, but the maintenance panel lacks <i>wiring</i>.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>The assembly is <b>welded together</b>, but the anchoring bolts are <i>unwrenched</i>.</span>")
|
||||
if(AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS)
|
||||
to_chat(user, "<span class='notice'>The maintenance panel is <b>wired</b>, but the circuit slot is <i>empty</i>.</span>")
|
||||
if(AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER)
|
||||
to_chat(user, "<span class='notice'>The circuit is <b>connected loosely</b> to its slot, but the maintenance panel is <i>unscrewed and open</i>.</span>")
|
||||
if(!mineral && !glass && !noglass)
|
||||
to_chat(user, "<span class='notice'>There is a small <i>paper</i> placard on the assembly[doorname]. There are <i>empty</i> slots for glass windows and mineral covers.</span>")
|
||||
else if(!mineral && glass && !noglass)
|
||||
to_chat(user, "<span class='notice'>There is a small <i>paper</i> placard on the assembly[doorname]. There are <i>empty</i> slots for mineral covers.</span>")
|
||||
else if(mineral && !glass && !noglass)
|
||||
to_chat(user, "<span class='notice'>There is a small <i>paper</i> placard on the assembly[doorname]. There are <i>empty</i> slots for glass windows.</span>")
|
||||
else
|
||||
bound_width = world.icon_size
|
||||
bound_height = width * world.icon_size
|
||||
update_state()
|
||||
|
||||
/obj/structure/door_assembly/multi_tile/Move()
|
||||
. = ..()
|
||||
if(dir in list(EAST, WEST))
|
||||
bound_width = width * world.icon_size
|
||||
bound_height = world.icon_size
|
||||
else
|
||||
bound_width = world.icon_size
|
||||
bound_height = width * world.icon_size
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_cult
|
||||
icon = 'icons/obj/doors/Doorcult.dmi'
|
||||
base_icon_state = "construction"
|
||||
base_name = "engraved airlock"
|
||||
airlock_type = "/cult"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_cultruned
|
||||
icon = 'icons/obj/doors/Doorcultruned.dmi'
|
||||
base_icon_state = "construction"
|
||||
base_name = "runed airlock"
|
||||
airlock_type = "/cult/runed"
|
||||
glass = -1
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_centcom
|
||||
base_icon_state = "ele"
|
||||
airlock_type = "/centcom"
|
||||
glass = -1
|
||||
to_chat(user, "<span class='notice'>There is a small <i>paper</i> placard on the assembly[doorname].</span>")
|
||||
|
||||
/obj/structure/door_assembly/attackby(obj/item/W, mob/user, params)
|
||||
if(istype(W, /obj/item/weapon/pen))
|
||||
@@ -192,20 +63,22 @@
|
||||
created_name = t
|
||||
return
|
||||
|
||||
if(iswelder(W) && ((istext(glass)) || (glass == 1) || !anchored ))
|
||||
else if(iswelder(W) && (mineral || glass || !anchored ))
|
||||
var/obj/item/weapon/weldingtool/WT = W
|
||||
if(WT.remove_fuel(0, user))
|
||||
playsound(loc, WT.usesound, 50, 1)
|
||||
if(istext(glass))
|
||||
user.visible_message("[user] welds the [glass] plating off the airlock assembly.", "You start to weld the [glass] plating off the airlock assembly...")
|
||||
if(mineral)
|
||||
var/obj/item/stack/sheet/mineral/mineral_path = text2path("/obj/item/stack/sheet/mineral/[mineral]")
|
||||
user.visible_message("[user] welds the [mineral] plating off the airlock assembly.", "You start to weld the [mineral] plating off the airlock assembly...")
|
||||
if(do_after(user, 40 * WT.toolspeed, target = src))
|
||||
if(!src || !WT.isOn())
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You weld the [glass] plating off.</span>")
|
||||
var/M = text2path("/obj/item/stack/sheet/mineral/[glass]")
|
||||
new M(loc, 2)
|
||||
glass = 0
|
||||
else if(glass == 1)
|
||||
to_chat(user, "<span class='notice'>You weld the [mineral] plating off.</span>")
|
||||
new mineral_path(loc, 2)
|
||||
var/obj/structure/door_assembly/PA = new previous_assembly(loc)
|
||||
transfer_assembly_vars(src, PA)
|
||||
|
||||
else if(glass)
|
||||
user.visible_message("[user] welds the glass panel out of the airlock assembly.", "You start to weld the glass panel out of the airlock assembly...")
|
||||
if(do_after(user, 40 * WT.toolspeed, target = src))
|
||||
if(!src || !WT.isOn())
|
||||
@@ -213,23 +86,23 @@
|
||||
to_chat(user, "<span class='notice'>You weld the glass panel out.</span>")
|
||||
if(heat_proof_finished)
|
||||
new /obj/item/stack/sheet/rglass(get_turf(src))
|
||||
heat_proof_finished = 0
|
||||
heat_proof_finished = FALSE
|
||||
else
|
||||
new /obj/item/stack/sheet/glass(get_turf(src))
|
||||
glass = 0
|
||||
glass = FALSE
|
||||
else if(!anchored)
|
||||
user.visible_message("[user] disassembles the airlock assembly.", "You start to disassemble the airlock assembly...")
|
||||
user.visible_message("<span class='warning'>[user] disassembles the airlock assembly.</span>", \
|
||||
"You start to disassemble the airlock assembly...")
|
||||
if(do_after(user, 40 * WT.toolspeed, target = src))
|
||||
if(!src || !WT.isOn())
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You disassemble the airlock assembly.</span>")
|
||||
new material_type(loc, material_amt)
|
||||
qdel(src)
|
||||
deconstruct(TRUE)
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You need more welding fuel.</span>")
|
||||
return
|
||||
|
||||
else if(iswrench(W) && state == 0)
|
||||
else if(iswrench(W) && state == AIRLOCK_ASSEMBLY_NEEDS_WIRES)
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
if(anchored)
|
||||
user.visible_message("[user] unsecures the airlock assembly from the floor.", "You start to unsecure the airlock assembly from the floor...")
|
||||
@@ -242,51 +115,53 @@
|
||||
to_chat(user, "<span class='notice'>You [anchored ? "un" : ""]secure the airlock assembly.</span>")
|
||||
anchored = !anchored
|
||||
|
||||
else if(iscoil(W) && state == 0 && anchored)
|
||||
else if(iscoil(W) && state == AIRLOCK_ASSEMBLY_NEEDS_WIRES && anchored)
|
||||
var/obj/item/stack/cable_coil/coil = W
|
||||
if(coil.get_amount() < 1)
|
||||
to_chat(user, "<span class='warning'>You need one length of cable to wire the airlock assembly!</span>")
|
||||
return
|
||||
user.visible_message("[user] wires the airlock assembly.", "You start to wire the airlock assembly...")
|
||||
if(do_after(user, 40 * coil.toolspeed, target = src))
|
||||
if(!src)
|
||||
if(coil.get_amount() < 1 || state != AIRLOCK_ASSEMBLY_NEEDS_WIRES)
|
||||
return
|
||||
coil.use(1)
|
||||
state = 1
|
||||
state = AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS
|
||||
to_chat(user, "<span class='notice'>You wire the airlock assembly.</span>")
|
||||
|
||||
else if(iswirecutter(W) && state == 1)
|
||||
else if(iswirecutter(W) && state == AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS)
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] cuts the wires from the airlock assembly.", "You start to cut the wires from airlock assembly...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src)
|
||||
if(state != AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You cut the wires from the airlock assembly.</span>")
|
||||
if(state == 1)
|
||||
new/obj/item/stack/cable_coil(loc, 1)
|
||||
state = 0
|
||||
new/obj/item/stack/cable_coil(get_turf(user), 1)
|
||||
state = AIRLOCK_ASSEMBLY_NEEDS_WIRES
|
||||
|
||||
else if(istype(W, /obj/item/weapon/airlock_electronics) && state == 1 && W.icon_state != "door_electronics_smoked")
|
||||
else if(istype(W, /obj/item/weapon/airlock_electronics) && state == AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS && W.icon_state != "door_electronics_smoked")
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] installs the electronics into the airlock assembly.", "You start to install electronics into the airlock assembly...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src)
|
||||
if(state != AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS)
|
||||
return
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
W.forceMove(src)
|
||||
to_chat(user, "<span class='notice'>You install the airlock electronics.</span>")
|
||||
state = 2
|
||||
state = AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER
|
||||
name = "near finished airlock assembly"
|
||||
electronics = W
|
||||
|
||||
else if(iscrowbar(W) && state == 2 )
|
||||
else if(iscrowbar(W) && state == AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER )
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] removes the electronics from the airlock assembly.", "You start to remove electronics from the airlock assembly...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src)
|
||||
if(state != AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You remove the airlock electronics.</span>")
|
||||
state = 1
|
||||
state = AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS
|
||||
name = "wired airlock assembly"
|
||||
var/obj/item/weapon/airlock_electronics/ae
|
||||
if(!electronics)
|
||||
@@ -294,78 +169,131 @@
|
||||
else
|
||||
ae = electronics
|
||||
electronics = null
|
||||
ae.loc = loc
|
||||
ae.forceMove(loc)
|
||||
|
||||
else if(istype(W, /obj/item/stack/sheet) && !glass)
|
||||
else if(istype(W, /obj/item/stack/sheet) && (!glass || !mineral))
|
||||
var/obj/item/stack/sheet/S = W
|
||||
if(S)
|
||||
if(S.amount>=1)
|
||||
if(istype(S, /obj/item/stack/sheet/rglass) || istype(S, /obj/item/stack/sheet/glass))
|
||||
playsound(loc, S.usesound, 100, 1)
|
||||
user.visible_message("[user] adds [S.name] to the airlock assembly.", "You start to install [S.name] into the airlock assembly...")
|
||||
if(do_after(user, 40 * S.toolspeed, target = src))
|
||||
if(S.type == /obj/item/stack/sheet/rglass)
|
||||
to_chat(user, "<span class='notice'>You install reinforced glass windows into the airlock assembly.</span>")
|
||||
heat_proof_finished = 1 //reinforced glass makes the airlock heat-proof
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You install regular glass windows into the airlock assembly.</span>")
|
||||
S.use(1)
|
||||
glass = 1
|
||||
else if(istype(S, /obj/item/stack/sheet/mineral) && S.sheettype)
|
||||
var/M = S.sheettype
|
||||
if(S.amount>=2)
|
||||
playsound(loc, S.usesound, 100, 1)
|
||||
user.visible_message("[user] adds [S.name] to the airlock assembly.", "You start to install [S.name] into the airlock assembly...")
|
||||
if(do_after(user, 40 * S.toolspeed, target = src))
|
||||
to_chat(user, "<span class='notice'>You install [M] plating into the airlock assembly.</span>")
|
||||
S.use(2)
|
||||
glass = "[M]"
|
||||
if(S.get_amount() >= 1)
|
||||
if(!noglass)
|
||||
if(!glass)
|
||||
if(istype(S, /obj/item/stack/sheet/rglass) || istype(S, /obj/item/stack/sheet/glass))
|
||||
playsound(loc, S.usesound, 100, 1)
|
||||
user.visible_message("[user] adds [S.name] to the airlock assembly.", "You start to install [S.name] into the airlock assembly...")
|
||||
if(do_after(user, 40 * S.toolspeed, target = src))
|
||||
if(S.get_amount() < 1 || glass)
|
||||
return
|
||||
if(S.type == /obj/item/stack/sheet/rglass)
|
||||
to_chat(user, "<span class='notice'>You install reinforced glass windows into the airlock assembly.</span>")
|
||||
heat_proof_finished = TRUE //reinforced glass makes the airlock heat-proof
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You install regular glass windows into the airlock assembly.</span>")
|
||||
S.use(1)
|
||||
glass = TRUE
|
||||
if(!mineral)
|
||||
if(istype(S, /obj/item/stack/sheet/mineral) && S.sheettype)
|
||||
var/M = S.sheettype
|
||||
if(S.get_amount() >= 2)
|
||||
playsound(loc, S.usesound, 100, 1)
|
||||
user.visible_message("[user] adds [S.name] to the airlock assembly.", "You start to install [S.name] into the airlock assembly...")
|
||||
if(do_after(user, 40 * S.toolspeed, target = src))
|
||||
if(S.get_amount() < 2 || mineral)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You install [M] plating into the airlock assembly.</span>")
|
||||
S.use(2)
|
||||
var/mineralassembly = text2path("/obj/structure/door_assembly/door_assembly_[M]")
|
||||
var/obj/structure/door_assembly/MA = new mineralassembly(loc)
|
||||
transfer_assembly_vars(src, MA, TRUE)
|
||||
else
|
||||
to_chat(user, "<span class='warning'>You need at least two sheets to add a mineral cover!</span>")
|
||||
else
|
||||
to_chat(user, "<span class='warning'>You cannot add [S] to [src]!</span>")
|
||||
else
|
||||
to_chat(user, "<span class='warning'>You cannot add [S] to [src]!</span>")
|
||||
|
||||
else if(isscrewdriver(W) && state == 2 )
|
||||
else if(isscrewdriver(W) && state == AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER )
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] finishes the airlock.", \
|
||||
"<span class='notice'>You start finishing the airlock...</span>")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You finish the airlock.</span>")
|
||||
var/path
|
||||
if(istext(glass))
|
||||
path = text2path("/obj/machinery/door/airlock/[glass]")
|
||||
else if(glass == 1)
|
||||
path = text2path("/obj/machinery/door/airlock[glass_type]")
|
||||
else
|
||||
path = text2path("/obj/machinery/door/airlock[airlock_type]")
|
||||
var/obj/machinery/door/airlock/door = new path(loc)
|
||||
door.setDir(dir)
|
||||
door.assemblytype = type
|
||||
door.electronics = electronics
|
||||
door.heat_proof = heat_proof_finished
|
||||
if(electronics.one_access)
|
||||
door.req_access = null
|
||||
door.req_one_access = electronics.conf_access
|
||||
else
|
||||
door.req_access = electronics.conf_access
|
||||
if(created_name)
|
||||
door.name = created_name
|
||||
else
|
||||
door.name = "[istext(glass) ? "[glass] airlock" : base_name]"
|
||||
electronics.loc = door
|
||||
qdel(src)
|
||||
if(loc && state == AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER)
|
||||
to_chat(user, "<span class='notice'>You finish the airlock.</span>")
|
||||
var/obj/machinery/door/airlock/door
|
||||
if(glass)
|
||||
door = new glass_type(loc)
|
||||
else
|
||||
door = new airlock_type(loc)
|
||||
door.setDir(dir)
|
||||
door.electronics = electronics
|
||||
door.heat_proof = heat_proof_finished
|
||||
if(electronics.one_access)
|
||||
door.req_access = null
|
||||
door.req_one_access = electronics.conf_access
|
||||
else
|
||||
door.req_access = electronics.conf_access
|
||||
if(created_name)
|
||||
door.name = created_name
|
||||
else
|
||||
door.name = base_name
|
||||
door.previous_airlock = previous_assembly
|
||||
electronics.forceMove(door)
|
||||
qdel(src)
|
||||
else
|
||||
..()
|
||||
update_state()
|
||||
return ..()
|
||||
update_name()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/door_assembly/proc/update_state()
|
||||
icon_state = "door_as_[glass == 1 ? "g" : ""][istext(glass) ? glass : base_icon_state][state]"
|
||||
/obj/structure/door_assembly/update_icon()
|
||||
overlays.Cut()
|
||||
if(!glass)
|
||||
overlays += get_airlock_overlay("fill_construction", icon)
|
||||
else if(glass)
|
||||
overlays += get_airlock_overlay("glass_construction", overlays_file)
|
||||
overlays += get_airlock_overlay("panel_c[state+1]", overlays_file)
|
||||
|
||||
/obj/structure/door_assembly/proc/update_name()
|
||||
name = ""
|
||||
switch(state)
|
||||
if(0)
|
||||
if(AIRLOCK_ASSEMBLY_NEEDS_WIRES)
|
||||
if(anchored)
|
||||
name = "secured "
|
||||
if(1)
|
||||
if(AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS)
|
||||
name = "wired "
|
||||
if(2)
|
||||
if(AIRLOCK_ASSEMBLY_NEEDS_SCREWDRIVER)
|
||||
name = "near finished "
|
||||
name += "[heat_proof_finished ? "heat-proofed " : ""][glass == 1 ? "window " : ""][istext(glass) ? "[glass] airlock" : base_name] assembly"
|
||||
name += "[heat_proof_finished ? "heat-proofed " : ""][glass ? "window " : ""][base_name] assembly"
|
||||
|
||||
/obj/structure/door_assembly/proc/transfer_assembly_vars(obj/structure/door_assembly/source, obj/structure/door_assembly/target, previous = FALSE)
|
||||
target.glass = source.glass
|
||||
target.heat_proof_finished = source.heat_proof_finished
|
||||
target.created_name = source.created_name
|
||||
target.state = source.state
|
||||
target.anchored = source.anchored
|
||||
if(previous)
|
||||
target.previous_assembly = source.type
|
||||
if(electronics)
|
||||
target.electronics = source.electronics
|
||||
source.electronics.forceMove(target)
|
||||
target.update_icon()
|
||||
target.update_name()
|
||||
qdel(source)
|
||||
|
||||
/obj/structure/door_assembly/deconstruct(disassembled = TRUE)
|
||||
if(can_deconstruct)
|
||||
var/turf/T = get_turf(src)
|
||||
if(!disassembled)
|
||||
material_amt = rand(2,4)
|
||||
new material_type(T, material_amt)
|
||||
if(glass)
|
||||
if(disassembled)
|
||||
if(heat_proof_finished)
|
||||
new /obj/item/stack/sheet/rglass(T)
|
||||
else
|
||||
new /obj/item/stack/sheet/glass(T)
|
||||
else
|
||||
new /obj/item/weapon/shard(T)
|
||||
if(mineral)
|
||||
var/obj/item/stack/sheet/mineral/mineral_path = text2path("/obj/item/stack/sheet/mineral/[mineral]")
|
||||
new mineral_path(T, 2)
|
||||
qdel(src)
|
||||
|
||||
@@ -0,0 +1,264 @@
|
||||
/obj/structure/door_assembly/door_assembly_public
|
||||
name = "public airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station2/glass.dmi'
|
||||
overlays_file = 'icons/obj/doors/airlocks/station2/overlays.dmi'
|
||||
glass_type = /obj/machinery/door/airlock/public/glass
|
||||
airlock_type = /obj/machinery/door/airlock/public
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_com
|
||||
name = "command airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/command.dmi'
|
||||
base_name = "command airlock"
|
||||
glass_type = /obj/machinery/door/airlock/command/glass
|
||||
airlock_type = /obj/machinery/door/airlock/command
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_sec
|
||||
name = "security airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/security.dmi'
|
||||
base_name = "security airlock"
|
||||
glass_type = /obj/machinery/door/airlock/security/glass
|
||||
airlock_type = /obj/machinery/door/airlock/security
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_eng
|
||||
name = "engineering airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/engineering.dmi'
|
||||
base_name = "engineering airlock"
|
||||
glass_type = /obj/machinery/door/airlock/engineering/glass
|
||||
airlock_type = /obj/machinery/door/airlock/engineering
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_min
|
||||
name = "mining airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/mining.dmi'
|
||||
base_name = "mining airlock"
|
||||
glass_type = /obj/machinery/door/airlock/mining/glass
|
||||
airlock_type = /obj/machinery/door/airlock/mining
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_atmo
|
||||
name = "atmospherics airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/atmos.dmi'
|
||||
base_name = "atmospherics airlock"
|
||||
glass_type = /obj/machinery/door/airlock/atmos/glass
|
||||
airlock_type = /obj/machinery/door/airlock/atmos
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_research
|
||||
name = "research airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/research.dmi'
|
||||
base_name = "research airlock"
|
||||
glass_type = /obj/machinery/door/airlock/research/glass
|
||||
airlock_type = /obj/machinery/door/airlock/research
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_science
|
||||
name = "science airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/science.dmi'
|
||||
base_name = "science airlock"
|
||||
glass_type = /obj/machinery/door/airlock/science/glass
|
||||
airlock_type = /obj/machinery/door/airlock/science
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_med
|
||||
name = "medical airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/medical.dmi'
|
||||
base_name = "medical airlock"
|
||||
glass_type = /obj/machinery/door/airlock/medical/glass
|
||||
airlock_type = /obj/machinery/door/airlock/medical
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_mai
|
||||
name = "maintenance airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/maintenance.dmi'
|
||||
base_name = "maintenance airlock"
|
||||
glass_type = /obj/machinery/door/airlock/maintenance/glass
|
||||
airlock_type = /obj/machinery/door/airlock/maintenance
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_extmai
|
||||
name = "external maintenance airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/maintenanceexternal.dmi'
|
||||
base_name = "external maintenance airlock"
|
||||
glass_type = /obj/machinery/door/airlock/maintenance/external/glass
|
||||
airlock_type = /obj/machinery/door/airlock/maintenance/external
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_ext
|
||||
name = "external airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/external/external.dmi'
|
||||
base_name = "external airlock"
|
||||
overlays_file = 'icons/obj/doors/airlocks/external/overlays.dmi'
|
||||
glass_type = /obj/machinery/door/airlock/external/glass
|
||||
airlock_type = /obj/machinery/door/airlock/external
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_fre
|
||||
name = "freezer airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/freezer.dmi'
|
||||
base_name = "freezer airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/freezer
|
||||
noglass = TRUE
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_hatch
|
||||
name = "airtight hatch assembly"
|
||||
icon = 'icons/obj/doors/airlocks/hatch/centcom.dmi'
|
||||
base_name = "airtight hatch"
|
||||
overlays_file = 'icons/obj/doors/airlocks/hatch/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/hatch
|
||||
noglass = TRUE
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_mhatch
|
||||
name = "maintenance hatch assembly"
|
||||
icon = 'icons/obj/doors/airlocks/hatch/maintenance.dmi'
|
||||
base_name = "maintenance hatch"
|
||||
overlays_file = 'icons/obj/doors/airlocks/hatch/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/maintenance_hatch
|
||||
noglass = TRUE
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_highsecurity
|
||||
name = "high security airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/highsec/highsec.dmi'
|
||||
base_name = "high security airlock"
|
||||
overlays_file = 'icons/obj/doors/airlocks/highsec/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/highsecurity
|
||||
noglass = TRUE
|
||||
material_type = /obj/item/stack/sheet/plasteel
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_vault
|
||||
name = "vault door assembly"
|
||||
icon = 'icons/obj/doors/airlocks/vault/vault.dmi'
|
||||
base_name = "vault door"
|
||||
overlays_file = 'icons/obj/doors/airlocks/vault/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/vault
|
||||
noglass = TRUE
|
||||
material_type = /obj/item/stack/sheet/plasteel
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_shuttle
|
||||
name = "shuttle airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/shuttle/shuttle.dmi'
|
||||
base_name = "shuttle airlock"
|
||||
overlays_file = 'icons/obj/doors/airlocks/shuttle/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/shuttle
|
||||
glass_type = /obj/machinery/door/airlock/shuttle/glass
|
||||
|
||||
/obj/structure/door_assembly/multi_tile
|
||||
name = "large airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/glass_large/glass_large.dmi'
|
||||
base_name = "large airlock"
|
||||
overlays_file = 'icons/obj/doors/airlocks/glass_large/overlays.dmi'
|
||||
dir = EAST
|
||||
var/width = 1
|
||||
airlock_type = /obj/machinery/door/airlock/multi_tile
|
||||
glass_type = /obj/machinery/door/airlock/multi_tile/glass
|
||||
material_amt = 8
|
||||
|
||||
/obj/structure/door_assembly/multi_tile/New()
|
||||
if(dir in list(EAST, WEST))
|
||||
bound_width = width * world.icon_size
|
||||
bound_height = world.icon_size
|
||||
else
|
||||
bound_width = world.icon_size
|
||||
bound_height = width * world.icon_size
|
||||
update_icon()
|
||||
|
||||
/obj/structure/door_assembly/multi_tile/Move()
|
||||
. = ..()
|
||||
if(dir in list(EAST, WEST))
|
||||
bound_width = width * world.icon_size
|
||||
bound_height = world.icon_size
|
||||
else
|
||||
bound_width = world.icon_size
|
||||
bound_height = width * world.icon_size
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_cult
|
||||
name = "cult airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/cult/runed/cult.dmi'
|
||||
base_name = "cult airlock"
|
||||
overlays_file = 'icons/obj/doors/airlocks/cult/runed/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/cult
|
||||
glass_type = /obj/machinery/door/airlock/cult/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_cult/unruned
|
||||
icon = 'icons/obj/doors/airlocks/cult/unruned/cult.dmi'
|
||||
overlays_file = 'icons/obj/doors/airlocks/cult/unruned/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/cult/unruned
|
||||
glass_type = /obj/machinery/door/airlock/cult/unruned/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_centcom
|
||||
icon = 'icons/obj/doors/airlocks/centcom/centcom.dmi'
|
||||
overlays_file = 'icons/obj/doors/airlocks/centcom/overlays.dmi'
|
||||
airlock_type = /obj/machinery/door/airlock/centcom
|
||||
noglass = TRUE
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_gold
|
||||
name = "gold airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/gold.dmi'
|
||||
base_name = "gold airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/gold
|
||||
mineral = "gold"
|
||||
glass_type = /obj/machinery/door/airlock/gold/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_silver
|
||||
name = "silver airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/silver.dmi'
|
||||
base_name = "silver airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/silver
|
||||
mineral = "silver"
|
||||
glass_type = /obj/machinery/door/airlock/silver/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_diamond
|
||||
name = "diamond airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/diamond.dmi'
|
||||
base_name = "diamond airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/diamond
|
||||
mineral = "diamond"
|
||||
glass_type = /obj/machinery/door/airlock/diamond/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_uranium
|
||||
name = "uranium airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/uranium.dmi'
|
||||
base_name = "uranium airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/uranium
|
||||
mineral = "uranium"
|
||||
glass_type = /obj/machinery/door/airlock/uranium/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_plasma
|
||||
name = "plasma airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/plasma.dmi'
|
||||
base_name = "plasma airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/plasma
|
||||
mineral = "plasma"
|
||||
glass_type = /obj/machinery/door/airlock/plasma/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_bananium
|
||||
name = "bananium airlock assembly"
|
||||
desc = "Honk."
|
||||
icon = 'icons/obj/doors/airlocks/station/bananium.dmi'
|
||||
base_name = "bananium airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/bananium
|
||||
mineral = "bananium"
|
||||
glass_type = /obj/machinery/door/airlock/bananium/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_tranquillite
|
||||
name = "tranquillite airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/freezer.dmi'
|
||||
base_name = "tranquillite airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/tranquillite
|
||||
mineral = "tranquillite"
|
||||
noglass = TRUE
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_sandstone
|
||||
name = "sandstone airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/sandstone.dmi'
|
||||
base_name = "sandstone airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/sandstone
|
||||
mineral = "sandstone"
|
||||
glass_type = /obj/machinery/door/airlock/sandstone/glass
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_titanium
|
||||
name = "titanium airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/shuttle/shuttle.dmi'
|
||||
base_name = "shuttle airlock"
|
||||
overlays_file = 'icons/obj/doors/airlocks/shuttle/overlays.dmi'
|
||||
glass_type = /obj/machinery/door/airlock/titanium/glass
|
||||
airlock_type = /obj/machinery/door/airlock/titanium
|
||||
mineral = "titanium"
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_wood
|
||||
name = "wooden airlock assembly"
|
||||
icon = 'icons/obj/doors/airlocks/station/wood.dmi'
|
||||
base_name = "wooden airlock"
|
||||
airlock_type = /obj/machinery/door/airlock/wood
|
||||
mineral = "wood"
|
||||
glass_type = /obj/machinery/door/airlock/wood/glass
|
||||
@@ -80,9 +80,9 @@
|
||||
|
||||
/obj/structure/falsewall/update_icon()
|
||||
if(density)
|
||||
icon_state = initial(icon_state)
|
||||
smooth = SMOOTH_TRUE
|
||||
smooth_icon(src)
|
||||
icon_state = ""
|
||||
else
|
||||
icon_state = "fwall_open"
|
||||
|
||||
@@ -304,4 +304,22 @@
|
||||
icon_state = "abductor"
|
||||
mineral = "abductor"
|
||||
walltype = "abductor"
|
||||
canSmoothWith = list(/obj/structure/falsewall/abductor, /turf/simulated/wall/mineral/abductor)
|
||||
canSmoothWith = list(/obj/structure/falsewall/abductor, /turf/simulated/wall/mineral/abductor)
|
||||
|
||||
/obj/structure/falsewall/titanium
|
||||
desc = "A light-weight titanium wall used in shuttles."
|
||||
icon = 'icons/turf/walls/shuttle_wall.dmi'
|
||||
icon_state = "shuttle"
|
||||
mineral = /obj/item/stack/sheet/mineral/titanium
|
||||
walltype = /turf/simulated/wall/mineral/titanium
|
||||
smooth = SMOOTH_MORE
|
||||
canSmoothWith = list(/turf/simulated/wall/mineral/titanium, /obj/machinery/door/airlock/shuttle, /obj/machinery/door/airlock, /obj/structure/window/full/shuttle, /obj/structure/shuttle/engine/heater)
|
||||
|
||||
/obj/structure/falsewall/plastitanium
|
||||
desc = "An evil wall of plasma and titanium."
|
||||
icon = 'icons/turf/walls/plastitanium_wall.dmi'
|
||||
icon_state = "shuttle"
|
||||
mineral = /obj/item/stack/sheet/mineral/plastitanium
|
||||
walltype = /turf/simulated/wall/mineral/plastitanium
|
||||
smooth = SMOOTH_MORE
|
||||
canSmoothWith = list(/turf/simulated/wall/mineral/plastitanium, /obj/machinery/door/airlock/shuttle, /obj/machinery/door/airlock, /obj/structure/window/full/shuttle, /obj/structure/shuttle/engine/heater)
|
||||
@@ -94,6 +94,8 @@
|
||||
basestate = "window"
|
||||
health = 160
|
||||
reinf = 1
|
||||
explosion_block = 3
|
||||
armor = list("melee" = 50, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 50, "bio" = 100, "rad" = 100)
|
||||
|
||||
/obj/structure/window/full/shuttle/New()
|
||||
..()
|
||||
|
||||
@@ -32,8 +32,8 @@
|
||||
/obj/structure/girder/attack_animal(mob/living/simple_animal/M)
|
||||
M.changeNext_move(CLICK_CD_MELEE)
|
||||
M.do_attack_animation(src)
|
||||
if(M.environment_smash >= 1)
|
||||
if(M.environment_smash == 3)
|
||||
if((M.environment_smash & ENVIRONMENT_SMASH_STRUCTURES) || (M.environment_smash & ENVIRONMENT_SMASH_WALLS) || (M.environment_smash & ENVIRONMENT_SMASH_RWALLS))
|
||||
if(M.environment_smash & ENVIRONMENT_SMASH_RWALLS)
|
||||
ex_act(2)
|
||||
M.visible_message("<span class='warning'>[M] smashes through \the [src].</span>", "<span class='warning'>You smash through \the [src].</span>")
|
||||
else
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/obj/structure/grille
|
||||
desc = "A flimsy lattice of metal rods, with screws to secure it to the floor."
|
||||
desc = "A flimsy framework of metal rods."
|
||||
name = "grille"
|
||||
icon = 'icons/obj/structures.dmi'
|
||||
icon_state = "grille"
|
||||
density = 1
|
||||
anchored = 1
|
||||
density = TRUE
|
||||
anchored = TRUE
|
||||
flags = CONDUCT
|
||||
pressure_resistance = 5*ONE_ATMOSPHERE
|
||||
layer = BELOW_OBJ_LAYER
|
||||
level = 3
|
||||
var/health = 10
|
||||
var/broken = 0
|
||||
armor = list(melee = 50, bullet = 70, laser = 70, energy = 100, bomb = 10, bio = 100, rad = 100)
|
||||
max_integrity = 50
|
||||
integrity_failure = 20
|
||||
var/rods_type = /obj/item/stack/rods
|
||||
var/rods_amount = 2
|
||||
var/rods_broken = 1
|
||||
var/grille_type = null
|
||||
var/grille_type
|
||||
var/broken_type = /obj/structure/grille/broken
|
||||
|
||||
/obj/structure/grille/fence/
|
||||
var/width = 3
|
||||
health = 50
|
||||
|
||||
/obj/structure/grille/fence/New()
|
||||
if(width > 1)
|
||||
@@ -51,6 +51,20 @@
|
||||
if(!broken)
|
||||
obj_break()
|
||||
|
||||
/obj/structure/grille/examine(mob/user)
|
||||
..()
|
||||
if(anchored)
|
||||
to_chat(user, "<span class='notice'>It's secured in place with <b>screws</b>. The rods look like they could be <b>cut</b> through.</span>")
|
||||
if(!anchored)
|
||||
to_chat(user, "<span class='notice'>The anchoring screws are <i>unscrewed</i>. The rods look like they could be <b>cut</b> through.</span>")
|
||||
|
||||
/obj/structure/grille/ratvar_act()
|
||||
if(broken)
|
||||
new /obj/structure/grille/ratvar/broken(loc)
|
||||
else
|
||||
new /obj/structure/grille/ratvar(loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/grille/Bumped(atom/user)
|
||||
if(ismob(user))
|
||||
shock(user, 70)
|
||||
@@ -65,9 +79,9 @@
|
||||
if(shock(user, 70))
|
||||
return
|
||||
if(HULK in user.mutations)
|
||||
take_damage(5)
|
||||
take_damage(60, BRUTE, "melee", 1)
|
||||
else
|
||||
take_damage(rand(1,2))
|
||||
take_damage(rand(5,10), BRUTE, "melee", 1)
|
||||
|
||||
/obj/structure/grille/attack_alien(mob/living/user)
|
||||
if(istype(user, /mob/living/carbon/alien/larva))
|
||||
@@ -79,37 +93,7 @@
|
||||
"You hear twisting metal.")
|
||||
|
||||
if(!shock(user, 70))
|
||||
take_damage(5)
|
||||
|
||||
/obj/structure/grille/attack_slime(mob/living/user)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
var/mob/living/carbon/slime/S = user
|
||||
if(!S.is_adult)
|
||||
return
|
||||
|
||||
playsound(loc, 'sound/effects/grillehit.ogg', 80, 1)
|
||||
user.visible_message("<span class='warning'>[user] smashes against [src].</span>", \
|
||||
"<span class='warning'>You smash against [src].</span>", \
|
||||
"You hear twisting metal.")
|
||||
|
||||
take_damage(rand(1,2))
|
||||
|
||||
/obj/structure/grille/attack_animal(mob/living/simple_animal/M)
|
||||
if(M.melee_damage_upper == 0 || (M.melee_damage_type != BRUTE && M.melee_damage_type != BURN))
|
||||
return
|
||||
M.changeNext_move(CLICK_CD_MELEE)
|
||||
M.do_attack_animation(src)
|
||||
playsound(loc, 'sound/effects/grillehit.ogg', 80, 1)
|
||||
M.visible_message("<span class='warning'>[M] smashes against [src].</span>", \
|
||||
"<span class='warning'>You smash against [src].</span>", \
|
||||
"You hear twisting metal.")
|
||||
|
||||
take_damage(rand(M.melee_damage_lower,M.melee_damage_upper), M.melee_damage_type)
|
||||
|
||||
/obj/structure/grille/mech_melee_attack(obj/mecha/M)
|
||||
if(..())
|
||||
take_damage(M.force * 0.5, M.damtype)
|
||||
take_damage(20, BRUTE, "melee", 1)
|
||||
|
||||
/obj/structure/grille/CanPass(atom/movable/mover, turf/target, height=0)
|
||||
if(height==0)
|
||||
@@ -128,10 +112,6 @@
|
||||
var/atom/movable/mover = caller
|
||||
. = . || mover.checkpass(PASSGRILLE)
|
||||
|
||||
/obj/structure/grille/bullet_act(obj/item/projectile/Proj)
|
||||
. = ..()
|
||||
take_damage(Proj.damage*0.3, Proj.damage_type)
|
||||
|
||||
/obj/structure/grille/attackby(obj/item/weapon/W, mob/user, params)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
add_fingerprint(user)
|
||||
@@ -141,7 +121,7 @@
|
||||
deconstruct()
|
||||
else if((isscrewdriver(W)) && (istype(loc, /turf/simulated) || anchored))
|
||||
if(!shock(user, 90))
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
playsound(src, W.usesound, 100, 1)
|
||||
anchored = !anchored
|
||||
user.visible_message("<span class='notice'>[user] [anchored ? "fastens" : "unfastens"] [src].</span>", \
|
||||
"<span class='notice'>You [anchored ? "fasten [src] to" : "unfasten [src] from"] the floor.</span>")
|
||||
@@ -163,7 +143,7 @@
|
||||
//window placing end
|
||||
|
||||
else if(istype(W, /obj/item/weapon/shard) || !shock(user, 70))
|
||||
return attacked_by(W, user)
|
||||
return ..()
|
||||
|
||||
/obj/structure/grille/proc/build_window(obj/item/stack/sheet/S, mob/user)
|
||||
if(!istype(S) || !user)
|
||||
@@ -234,7 +214,7 @@
|
||||
W.update_icon()
|
||||
return
|
||||
|
||||
/obj/structure/grille/proc/attacked_by(obj/item/I, mob/living/user)
|
||||
/obj/structure/grille/attacked_by(obj/item/I, mob/living/user)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
if(!(I.flags&NOBLUDGEON))
|
||||
@@ -259,25 +239,15 @@
|
||||
var/obj/R = new rods_type(loc, rods_amount)
|
||||
transfer_fingerprints_to(R)
|
||||
qdel(src)
|
||||
..()
|
||||
|
||||
/obj/structure/grille/proc/obj_break()
|
||||
/obj/structure/grille/obj_break()
|
||||
if(!broken && can_deconstruct)
|
||||
new broken_type(loc)
|
||||
var/obj/R = new rods_type(loc, rods_broken)
|
||||
transfer_fingerprints_to(R)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/grille/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir)
|
||||
if(sound_effect)
|
||||
play_attack_sound(damage_amount, damage_type, damage_flag)
|
||||
health -= damage_amount
|
||||
if(health <= 0)
|
||||
if(!broken)
|
||||
obj_break()
|
||||
else
|
||||
if(health <= -6)
|
||||
deconstruct()
|
||||
|
||||
// shock user with probability prb (if all connections & power are working)
|
||||
// returns 1 if shocked, 0 otherwise
|
||||
|
||||
@@ -303,33 +273,60 @@
|
||||
/obj/structure/grille/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
if(!broken)
|
||||
if(exposed_temperature > T0C + 1500)
|
||||
take_damage(1)
|
||||
take_damage(1, BURN, 0, 0)
|
||||
..()
|
||||
|
||||
/obj/structure/grille/hitby(atom/movable/AM)
|
||||
..()
|
||||
var/tforce = 0
|
||||
if(ismob(AM))
|
||||
tforce = 5
|
||||
else if(isobj(AM))
|
||||
if(prob(50))
|
||||
var/obj/O = AM
|
||||
tforce = max(0, O.throwforce * 0.5)
|
||||
else if(anchored && !broken)
|
||||
if(istype(AM, /obj))
|
||||
if(prob(50) && anchored && !broken)
|
||||
var/turf/T = get_turf(src)
|
||||
var/obj/structure/cable/C = T.get_cable_node()
|
||||
if(C)
|
||||
playsound(loc, 'sound/magic/LightningShock.ogg', 100, 1, extrarange = 5)
|
||||
tesla_zap(src, 3, C.powernet.avail * 0.01) //Zap for 1/100 of the amount of power. At a million watts in the grid, it will be as powerful as a tesla revolver shot.
|
||||
C.powernet.load += C.powernet.avail * 0.0375 // you can gain up to 3.5 via the 4x upgrades power is halved by the pole so thats 2x then 1X then .5X for 3.5x the 3 bounces shock.
|
||||
take_damage(tforce)
|
||||
return ..()
|
||||
|
||||
/obj/structure/grille/broken // Pre-broken grilles for map placement
|
||||
icon_state = "brokengrille"
|
||||
density = 0
|
||||
health = 0
|
||||
obj_integrity = 20
|
||||
broken = 1
|
||||
rods_amount = 1
|
||||
rods_broken = 0
|
||||
grille_type = /obj/structure/grille
|
||||
broken_type = null
|
||||
|
||||
/obj/structure/grille/ratvar
|
||||
icon_state = "ratvargrille"
|
||||
name = "cog grille"
|
||||
desc = "A strangely-shaped grille."
|
||||
broken_type = /obj/structure/grille/ratvar/broken
|
||||
|
||||
/obj/structure/grille/ratvar/New()
|
||||
..()
|
||||
if(broken)
|
||||
new /obj/effect/temp_visual/ratvar/grille/broken(get_turf(src))
|
||||
else
|
||||
new /obj/effect/temp_visual/ratvar/grille(get_turf(src))
|
||||
new /obj/effect/temp_visual/ratvar/beam/grille(get_turf(src))
|
||||
|
||||
/obj/structure/grille/ratvar/narsie_act()
|
||||
take_damage(rand(1, 3), BRUTE)
|
||||
if(src)
|
||||
var/previouscolor = color
|
||||
color = "#960000"
|
||||
animate(src, color = previouscolor, time = 8)
|
||||
|
||||
/obj/structure/grille/ratvar/ratvar_act()
|
||||
return
|
||||
|
||||
/obj/structure/grille/ratvar/broken
|
||||
icon_state = "brokenratvargrille"
|
||||
density = FALSE
|
||||
obj_integrity = 20
|
||||
broken = TRUE
|
||||
rods_amount = 1
|
||||
rods_broken = 0
|
||||
grille_type = /obj/structure/grille/ratvar
|
||||
broken_type = null
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
add_fingerprint(user)
|
||||
return
|
||||
|
||||
/obj/structure/inflatable/proc/attack_generic(mob/user as mob, damage = 0) //used by attack_alien, attack_animal, and attack_slime
|
||||
/obj/structure/inflatable/attack_generic(mob/user, damage = 0) //used by attack_alien, attack_animal, and attack_slime
|
||||
health -= damage
|
||||
if(health <= 0)
|
||||
user.visible_message("<span class='danger'>[user] tears open [src]!</span>")
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
icon_state = "latticefull"
|
||||
density = 0
|
||||
anchored = 1.0
|
||||
armor = list(melee = 50, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0)
|
||||
layer = 2.3 //under pipes
|
||||
// flags = CONDUCT
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
icon = 'icons/obj/doors/mineral_doors.dmi'
|
||||
icon_state = "metal"
|
||||
|
||||
armor = list(melee = 10, bullet = 0, laser = 0, energy = 100, bomb = 10, bio = 100, rad = 100)
|
||||
var/initial_state
|
||||
var/state = 0 //closed, 1 == open
|
||||
var/isSwitchingStates = 0
|
||||
@@ -141,7 +141,7 @@
|
||||
else
|
||||
attacked_by(W, user)
|
||||
|
||||
/obj/structure/mineral_door/proc/attacked_by(obj/item/I, mob/user)
|
||||
/obj/structure/mineral_door/attacked_by(obj/item/I, mob/user)
|
||||
if(I.damtype != STAMINA)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
|
||||
@@ -115,7 +115,7 @@
|
||||
if(!instrumentObj)
|
||||
return
|
||||
|
||||
ui = nanomanager.try_update_ui(user, instrumentObj, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, instrumentObj, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, instrumentObj, ui_key, "song.tmpl", instrumentObj.name, 700, 500)
|
||||
ui.open()
|
||||
@@ -149,7 +149,7 @@
|
||||
lines = new()
|
||||
tempo = sanitize_tempo(5) // default 120 BPM
|
||||
name = ""
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["import"])
|
||||
playing = 0
|
||||
@@ -185,11 +185,11 @@
|
||||
lines.Remove(l)
|
||||
else
|
||||
linenum++
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["help"])
|
||||
help = !help
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
if(href_list["repeat"]) //Changing this from a toggle to a number of repeats to avoid infinite loops.
|
||||
if(playing)
|
||||
@@ -199,11 +199,11 @@
|
||||
repeat = 0
|
||||
if(repeat > max_repeat)
|
||||
repeat = max_repeat
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["tempo"])
|
||||
tempo = sanitize_tempo(tempo + text2num(href_list["tempo"]) * world.tick_lag)
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["play"])
|
||||
if(playing)
|
||||
@@ -211,7 +211,7 @@
|
||||
playing = 1
|
||||
spawn()
|
||||
playsong(usr)
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["insertline"])
|
||||
var/num = round(text2num(href_list["insertline"]))
|
||||
@@ -227,14 +227,14 @@
|
||||
newline = copytext(newline, 1, 200)
|
||||
|
||||
lines.Insert(num, newline)
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["deleteline"])
|
||||
var/num = round(text2num(href_list["deleteline"]))
|
||||
if(num > lines.len || num < 1)
|
||||
return
|
||||
lines.Cut(num, num + 1)
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["modifyline"])
|
||||
var/num = round(text2num(href_list["modifyline"]))
|
||||
@@ -246,11 +246,11 @@
|
||||
if(num > lines.len || num < 1)
|
||||
return
|
||||
lines[num] = content
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
else if(href_list["stop"])
|
||||
playing = 0
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
/datum/song/proc/sanitize_tempo(new_tempo)
|
||||
new_tempo = abs(new_tempo)
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
density = 0
|
||||
anchored = 1
|
||||
layer = 4
|
||||
armor = list(melee = 100, bullet = 80, laser = 80, energy = 100, bomb = 50, bio = 100, rad = 100)
|
||||
var/list/mobs_can_pass = list(
|
||||
/mob/living/carbon/slime,
|
||||
/mob/living/simple_animal/mouse,
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
opacity = 0
|
||||
density = 0
|
||||
layer = 3.5
|
||||
armor = list(melee = 50, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0)
|
||||
|
||||
/obj/structure/sign/ex_act(severity)
|
||||
switch(severity)
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
icon_state = "nest"
|
||||
var/health = 100
|
||||
var/image/nest_overlay
|
||||
comfort = 0
|
||||
|
||||
/obj/structure/stool/bed/nest/New()
|
||||
nest_overlay = image('icons/mob/alien.dmi', "nestoverlay", layer=MOB_LAYER - 0.2)
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
buildstackamount = 2
|
||||
var/movable = 0 // For mobility checks
|
||||
buckle_offset = -6
|
||||
var/comfort = 2 //defualt comfort
|
||||
|
||||
/obj/structure/stool/bed/MouseDrop(atom/over_object)
|
||||
..(over_object, skip_fucking_stool_shit = 1)
|
||||
@@ -38,6 +39,7 @@
|
||||
buildstackamount = 10
|
||||
buildstacktype = /obj/item/stack/sheet/wood
|
||||
buckle_offset = 0
|
||||
comfort = 0.5
|
||||
|
||||
/obj/structure/stool/bed/dogbed/ian
|
||||
name = "Ian's bed"
|
||||
@@ -48,7 +50,7 @@
|
||||
name = "resting contraption"
|
||||
desc = "This looks similar to contraptions from Earth. Could aliens be stealing our technology?"
|
||||
icon_state = "abed"
|
||||
|
||||
comfort = 0.3
|
||||
/obj/structure/stool/bed/proc/handle_rotation()
|
||||
return
|
||||
|
||||
@@ -68,6 +70,7 @@
|
||||
icon_state = "down"
|
||||
burn_state = FIRE_PROOF
|
||||
anchored = 0
|
||||
comfort = 1
|
||||
|
||||
/obj/structure/stool/bed/roller/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/roller_holder))
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
buildstackamount = 1
|
||||
buckle_offset = 0
|
||||
var/propelled = 0 // Check for fire-extinguisher-driven chairs
|
||||
comfort = 0
|
||||
|
||||
/obj/structure/stool/bed/chair/New()
|
||||
..()
|
||||
|
||||
@@ -39,9 +39,7 @@
|
||||
|
||||
if(ishuman(buckled_mob))
|
||||
var/mob/living/carbon/human/driver = user
|
||||
var/obj/item/organ/external/l_hand = driver.get_organ("l_hand")
|
||||
var/obj/item/organ/external/r_hand = driver.get_organ("r_hand")
|
||||
if(!l_hand && !r_hand)
|
||||
if(!driver.has_left_hand() && !driver.has_right_hand())
|
||||
return 0 // No hands to drive your chair? Tough luck!
|
||||
|
||||
for(var/organ_name in list("l_hand","r_hand","l_arm","r_arm"))
|
||||
|
||||
@@ -128,6 +128,7 @@
|
||||
desc = "Four pieces of brass arranged in a square. It's slightly warm to the touch."
|
||||
icon_state = "brass_frame"
|
||||
burn_state = FIRE_PROOF
|
||||
unacidable = 1
|
||||
framestack = /obj/item/stack/tile/brass
|
||||
framestackamount = 1
|
||||
|
||||
|
||||
@@ -82,42 +82,6 @@
|
||||
new /obj/structure/table/reinforced/brass(loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/table/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1)
|
||||
qdel(src)
|
||||
return
|
||||
if(2)
|
||||
if(prob(50))
|
||||
qdel(src)
|
||||
return
|
||||
if(3)
|
||||
if(prob(25))
|
||||
deconstruct(FALSE)
|
||||
else
|
||||
return
|
||||
|
||||
/obj/structure/table/blob_act()
|
||||
if(prob(75))
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/table/attack_alien(mob/living/user)
|
||||
user.do_attack_animation(src)
|
||||
playsound(loc, 'sound/weapons/bladeslice.ogg', 50, 1)
|
||||
visible_message("<span class='danger'>[user] slices [src] apart!</span>")
|
||||
deconstruct(FALSE)
|
||||
|
||||
/obj/structure/table/mech_melee_attack(obj/mecha/M)
|
||||
visible_message("<span class='danger'>[M] smashes [src] apart!</span>")
|
||||
deconstruct(FALSE)
|
||||
|
||||
/obj/structure/table/attack_animal(mob/living/simple_animal/user)
|
||||
if(user.environment_smash)
|
||||
user.do_attack_animation(src)
|
||||
playsound(loc, 'sound/weapons/Genhit.ogg', 50, 1)
|
||||
visible_message("<span class='danger'>[user] smashes [src] apart!</span>")
|
||||
deconstruct(FALSE)
|
||||
|
||||
/obj/structure/table/attack_hand(mob/living/user)
|
||||
if(HULK in user.mutations)
|
||||
user.do_attack_animation(src)
|
||||
@@ -254,18 +218,7 @@
|
||||
if(isrobot(user))
|
||||
return
|
||||
|
||||
if(istype(I, /obj/item/weapon/melee/energy/blade))
|
||||
var/datum/effect_system/spark_spread/spark_system = new /datum/effect_system/spark_spread()
|
||||
spark_system.set_up(5, 0, loc)
|
||||
spark_system.start()
|
||||
playsound(loc, I.usesound, 50, 1)
|
||||
playsound(loc, "sparks", 50, 1)
|
||||
for(var/mob/O in viewers(user, 4))
|
||||
O.show_message("<span class='notice'>The [src] was sliced apart by [user]!</span>", 1, "<span class='warning'>You hear [src] coming apart.</span>", 2)
|
||||
deconstruct(FALSE)
|
||||
return
|
||||
|
||||
if(!(I.flags & ABSTRACT))
|
||||
if(user.a_intent != INTENT_HARM && !(I.flags & ABSTRACT))
|
||||
if(user.drop_item())
|
||||
I.Move(loc)
|
||||
var/list/click_params = params2list(params)
|
||||
@@ -275,8 +228,8 @@
|
||||
//Clamp it so that the icon never moves more than 16 pixels in either direction (thus leaving the table turf)
|
||||
I.pixel_x = Clamp(text2num(click_params["icon-x"]) - 16, -(world.icon_size/2), world.icon_size/2)
|
||||
I.pixel_y = Clamp(text2num(click_params["icon-y"]) - 16, -(world.icon_size/2), world.icon_size/2)
|
||||
|
||||
return
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/structure/table/deconstruct(disassembled = TRUE, wrench_disassembly = 0)
|
||||
if(can_deconstruct)
|
||||
@@ -401,6 +354,7 @@
|
||||
icon_state = "glass_table"
|
||||
buildstack = /obj/item/stack/sheet/glass
|
||||
max_integrity = 70
|
||||
unacidable = 1
|
||||
canSmoothWith = null
|
||||
var/list/debris = list()
|
||||
|
||||
@@ -465,6 +419,11 @@
|
||||
debris -= AM
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/table/glass/narsie_act()
|
||||
color = NARSIE_WINDOW_COLOUR
|
||||
for(var/obj/item/weapon/shard/S in debris)
|
||||
S.color = NARSIE_WINDOW_COLOUR
|
||||
|
||||
/*
|
||||
* Wooden tables
|
||||
*/
|
||||
@@ -534,6 +493,7 @@
|
||||
canSmoothWith = list(/obj/structure/table/reinforced, /obj/structure/table)
|
||||
max_integrity = 200
|
||||
integrity_failure = 50
|
||||
armor = list(melee = 10, bullet = 30, laser = 30, energy = 100, bomb = 20, bio = 0, rad = 0)
|
||||
|
||||
/obj/structure/table/reinforced/deconstruction_hints(mob/user)
|
||||
if(deconstruction_ready)
|
||||
@@ -601,8 +561,8 @@
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "rack"
|
||||
layer = TABLE_LAYER
|
||||
density = 1
|
||||
anchored = 1
|
||||
density = TRUE
|
||||
anchored = TRUE
|
||||
pass_flags = LETPASSTHROW
|
||||
max_integrity = 20
|
||||
|
||||
@@ -610,28 +570,6 @@
|
||||
..()
|
||||
to_chat(user, "<span class='notice'>It's held together by a couple of <b>bolts</b>.</span>")
|
||||
|
||||
/obj/structure/rack/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1)
|
||||
qdel(src)
|
||||
if(2)
|
||||
qdel(src)
|
||||
if(prob(50))
|
||||
new /obj/item/weapon/rack_parts(loc)
|
||||
if(3)
|
||||
if(prob(25))
|
||||
qdel(src)
|
||||
new /obj/item/weapon/rack_parts(loc)
|
||||
|
||||
/obj/structure/rack/blob_act()
|
||||
if(prob(75))
|
||||
qdel(src)
|
||||
return
|
||||
else if(prob(50))
|
||||
new /obj/item/weapon/rack_parts(loc)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/structure/rack/CanPass(atom/movable/mover, turf/target, height=0)
|
||||
if(height==0)
|
||||
return 1
|
||||
@@ -667,46 +605,21 @@
|
||||
return
|
||||
if(isrobot(user))
|
||||
return
|
||||
if(user.a_intent == INTENT_HARM)
|
||||
return ..()
|
||||
if(!(W.flags & ABSTRACT))
|
||||
if(user.drop_item())
|
||||
W.Move(loc)
|
||||
return
|
||||
|
||||
/obj/structure/rack/attack_hand(mob/user)
|
||||
if(HULK in user.mutations)
|
||||
visible_message("<span class='danger'>[user] smashes [src] apart!</span>")
|
||||
user.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ))
|
||||
deconstruct()
|
||||
else
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
playsound(loc, 'sound/items/dodgeball.ogg', 80, 1)
|
||||
user.visible_message("<span class='warning'>[user] kicks [src].</span>", \
|
||||
"<span class='danger'>You kick [src].</span>")
|
||||
obj_integrity -= rand(1,2)
|
||||
healthcheck()
|
||||
|
||||
/obj/structure/rack/mech_melee_attack(obj/mecha/M)
|
||||
visible_message("<span class='danger'>[M] smashes [src] apart!</span>")
|
||||
deconstruct()
|
||||
|
||||
/obj/structure/rack/attack_alien(mob/living/user)
|
||||
/obj/structure/rack/attack_hand(mob/living/user)
|
||||
if(user.weakened || user.resting || user.lying)
|
||||
return
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
visible_message("<span class='danger'>[user] slices [src] apart!</span>")
|
||||
deconstruct()
|
||||
|
||||
/obj/structure/rack/attack_animal(mob/living/simple_animal/user)
|
||||
if(user.environment_smash)
|
||||
user.do_attack_animation(src)
|
||||
visible_message("<span class='danger'>[user] smashes [src] apart!</span>")
|
||||
deconstruct()
|
||||
|
||||
/obj/structure/rack/attack_tk() // no telehulk sorry
|
||||
return
|
||||
|
||||
/obj/structure/rack/proc/healthcheck()
|
||||
if(obj_integrity <= 0)
|
||||
deconstruct()
|
||||
user.visible_message("<span class='warning'>[user] kicks [src].</span>", \
|
||||
"<span class='danger'>You kick [src].</span>")
|
||||
take_damage(rand(4,8), BRUTE, "melee", 1)
|
||||
|
||||
/obj/structure/rack/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0)
|
||||
switch(damage_type)
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
/obj/structure/dispenser/ui_interact(mob/user, ui_key = "main", datum/nanoui/ui = null, force_open = 1, var/master_ui = null, var/datum/topic_state/state = default_state)
|
||||
user.set_machine(src)
|
||||
ui = nanomanager.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "tank_dispenser.tmpl", name, 275, 100, state = state)
|
||||
ui.open()
|
||||
@@ -62,7 +62,7 @@
|
||||
to_chat(user, "<span class='notice'>You put [I] in [src].</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>[src] is full.</span>")
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
if(istype(I, /obj/item/weapon/tank/plasma))
|
||||
if(plasmatanks < 10)
|
||||
user.drop_item()
|
||||
@@ -73,7 +73,7 @@
|
||||
to_chat(user, "<span class='notice'>You put [I] in [src].</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>[src] is full.</span>")
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
if(istype(I, /obj/item/weapon/wrench))
|
||||
if(anchored)
|
||||
to_chat(user, "<span class='notice'>You lean down and unwrench [src].</span>")
|
||||
@@ -114,7 +114,7 @@
|
||||
update_icon()
|
||||
add_fingerprint(usr)
|
||||
updateUsrDialog()
|
||||
nanomanager.update_uis(src)
|
||||
SSnanoui.update_uis(src)
|
||||
else
|
||||
nanomanager.close_user_uis(usr,src)
|
||||
SSnanoui.close_user_uis(usr,src)
|
||||
return 1
|
||||
|
||||
@@ -9,38 +9,41 @@
|
||||
*/
|
||||
|
||||
|
||||
obj/structure/windoor_assembly
|
||||
/obj/structure/windoor_assembly
|
||||
icon = 'icons/obj/doors/windoor.dmi'
|
||||
|
||||
name = "windoor Assembly"
|
||||
name = "windoor assembly"
|
||||
icon_state = "l_windoor_assembly01"
|
||||
anchored = 0
|
||||
density = 0
|
||||
desc = "A small glass and wire assembly for windoors."
|
||||
anchored = FALSE
|
||||
density = FALSE
|
||||
dir = NORTH
|
||||
|
||||
max_integrity = 300
|
||||
var/ini_dir
|
||||
var/obj/item/weapon/airlock_electronics/electronics = null
|
||||
var/created_name = null
|
||||
var/obj/item/weapon/airlock_electronics/electronics
|
||||
var/created_name
|
||||
|
||||
//Vars to help with the icon's name
|
||||
var/facing = "l" //Does the windoor open to the left or right?
|
||||
var/secure = 0 //Whether or not this creates a secure windoor
|
||||
var/secure = FALSE //Whether or not this creates a secure windoor
|
||||
var/state = "01" //How far the door assembly has progressed
|
||||
|
||||
obj/structure/windoor_assembly/New(dir=NORTH)
|
||||
obj/structure/windoor_assembly/New(loc, set_dir)
|
||||
..()
|
||||
src.ini_dir = src.dir
|
||||
if(set_dir)
|
||||
dir = set_dir
|
||||
ini_dir = dir
|
||||
air_update_turf(1)
|
||||
|
||||
obj/structure/windoor_assembly/Destroy()
|
||||
density = 0
|
||||
density = FALSE
|
||||
QDEL_NULL(electronics)
|
||||
air_update_turf(1)
|
||||
return ..()
|
||||
|
||||
/obj/structure/windoor_assembly/Move()
|
||||
var/turf/T = loc
|
||||
..()
|
||||
. = ..()
|
||||
setDir(ini_dir)
|
||||
move_update_air(T)
|
||||
|
||||
/obj/structure/windoor_assembly/update_icon()
|
||||
@@ -54,13 +57,13 @@ obj/structure/windoor_assembly/Destroy()
|
||||
else
|
||||
return 1
|
||||
|
||||
/obj/structure/windoor_assembly/CanAtmosPass(var/turf/T)
|
||||
/obj/structure/windoor_assembly/CanAtmosPass(turf/T)
|
||||
if(get_dir(loc, T) == dir)
|
||||
return !density
|
||||
else
|
||||
return 1
|
||||
|
||||
/obj/structure/windoor_assembly/CheckExit(atom/movable/mover as mob|obj, turf/target as turf)
|
||||
/obj/structure/windoor_assembly/CheckExit(atom/movable/mover, turf/target)
|
||||
if(istype(mover) && mover.checkpass(PASSGLASS))
|
||||
return 1
|
||||
if(get_dir(loc, target) == dir)
|
||||
@@ -69,166 +72,166 @@ obj/structure/windoor_assembly/Destroy()
|
||||
return 1
|
||||
|
||||
|
||||
/obj/structure/windoor_assembly/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
/obj/structure/windoor_assembly/attackby(obj/item/W, mob/user, params)
|
||||
//I really should have spread this out across more states but thin little windoors are hard to sprite.
|
||||
add_fingerprint(user)
|
||||
switch(state)
|
||||
if("01")
|
||||
if(istype(W, /obj/item/weapon/weldingtool) && !anchored )
|
||||
if(iswelder(W) && !anchored)
|
||||
var/obj/item/weapon/weldingtool/WT = W
|
||||
if(WT.remove_fuel(0,user))
|
||||
user.visible_message("<span class='warning'>[user] dissassembles the windoor assembly.</span>", "<span class='notice'>You start to dissassemble the windoor assembly.</span>")
|
||||
playsound(src.loc, WT.usesound, 50, 1)
|
||||
user.visible_message("<span class='warning'>[user] disassembles the windoor assembly.</span>", "<span class='notice'>You start to disassemble the windoor assembly...</span>")
|
||||
playsound(loc, 'sound/items/welder2.ogg', 50, 1)
|
||||
|
||||
if(do_after(user, 40 * WT.toolspeed, target = src))
|
||||
if(!src || !WT.isOn()) return
|
||||
to_chat(user, "<span class='notice'>You dissasembled the windoor assembly!</span>")
|
||||
if(!src || !WT.isOn())
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You disassemble the windoor assembly.</span>")
|
||||
var/obj/item/stack/sheet/rglass/RG = new (get_turf(src), 5)
|
||||
RG.add_fingerprint(user)
|
||||
if(secure)
|
||||
var/obj/item/stack/rods/R = new (get_turf(src), 4)
|
||||
R.add_fingerprint(user)
|
||||
qdel(src)
|
||||
else
|
||||
return
|
||||
|
||||
//Wrenching an unsecure assembly anchors it in place. Step 4 complete
|
||||
if(istype(W, /obj/item/weapon/wrench) && !anchored)
|
||||
for(var/obj/machinery/door/window/WD in src.loc)
|
||||
if(WD.dir == src.dir)
|
||||
to_chat(user, "<span class='warning'>There is already a windoor in that location.</span>")
|
||||
if(iswrench(W) && !anchored)
|
||||
for(var/obj/machinery/door/window/WD in loc)
|
||||
if(WD.dir == dir)
|
||||
to_chat(user, "<span class='warning'>There is already a windoor in that location!</span>")
|
||||
return
|
||||
playsound(src.loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] secures the windoor assembly to the floor.", "You start to secure the windoor assembly to the floor.")
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] secures the windoor assembly to the floor.", "You start to secure the windoor assembly to the floor...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src || src.anchored)
|
||||
if(!src || anchored)
|
||||
return
|
||||
for(var/obj/machinery/door/window/WD in src.loc)
|
||||
if(WD.dir == src.dir)
|
||||
to_chat(user, "<span class='warning'>There is already a windoor in that location.</span>")
|
||||
for(var/obj/machinery/door/window/WD in loc)
|
||||
if(WD.dir == dir)
|
||||
to_chat(user, "<span class='warning'>There is already a windoor in that location!</span>")
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You've secured the windoor assembly!</span>")
|
||||
src.anchored = 1
|
||||
if(src.secure)
|
||||
src.name = "secure anchored windoor assembly"
|
||||
to_chat(user, "<span class='notice'>You secure the windoor assembly.</span>")
|
||||
anchored = TRUE
|
||||
if(secure)
|
||||
name = "secure anchored windoor assembly"
|
||||
else
|
||||
src.name = "anchored windoor assembly"
|
||||
name = "anchored windoor assembly"
|
||||
|
||||
//Unwrenching an unsecure assembly un-anchors it. Step 4 undone
|
||||
else if(istype(W, /obj/item/weapon/wrench) && anchored)
|
||||
else if(iswrench(W) && anchored)
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] unsecures the windoor assembly to the floor.", "You start to unsecure the windoor assembly to the floor.")
|
||||
user.visible_message("[user] unsecures the windoor assembly from the floor.", "You start to unsecure the windoor assembly from the floor...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src || !src.anchored)
|
||||
if(!src || !anchored)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You've unsecured the windoor assembly!</span>")
|
||||
src.anchored = 0
|
||||
if(src.secure)
|
||||
src.name = "secure windoor assembly"
|
||||
to_chat(user, "<span class='notice'>You unsecure the windoor assembly.</span>")
|
||||
anchored = FALSE
|
||||
if(secure)
|
||||
name = "secure windoor assembly"
|
||||
else
|
||||
src.name = "windoor assembly"
|
||||
name = "windoor assembly"
|
||||
|
||||
//Adding plasteel makes the assembly a secure windoor assembly. Step 2 (optional) complete.
|
||||
else if(istype(W, /obj/item/stack/sheet/plasteel) && !secure)
|
||||
var/obj/item/stack/sheet/plasteel/P = W
|
||||
if(P.amount < 2)
|
||||
to_chat(user, "<span class='danger'>You need more plasteel to do this.</span>")
|
||||
if(P.get_amount() < 2)
|
||||
to_chat(user, "<span class='warning'>You need more plasteel to do this!</span>")
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You start to reinforce the windoor with plasteel.</span>")
|
||||
to_chat(user, "<span class='notice'>You start to reinforce the windoor with plasteel...</span>")
|
||||
|
||||
if(do_after(user, 40 * P.toolspeed, target = src))
|
||||
if(!src || secure)
|
||||
if(!src || secure || P.get_amount() < 2)
|
||||
return
|
||||
playsound(loc, P.usesound, 100, 1)
|
||||
|
||||
P.use(2)
|
||||
to_chat(user, "<span class='notice'>You reinforce the windoor.</span>")
|
||||
src.secure = 1
|
||||
if(src.anchored)
|
||||
src.name = "secure anchored windoor assembly"
|
||||
secure = TRUE
|
||||
if(anchored)
|
||||
name = "secure anchored windoor assembly"
|
||||
else
|
||||
src.name = "secure windoor assembly"
|
||||
name = "secure windoor assembly"
|
||||
|
||||
//Adding cable to the assembly. Step 5 complete.
|
||||
else if(istype(W, /obj/item/stack/cable_coil) && anchored)
|
||||
user.visible_message("[user] wires the windoor assembly.", "You start to wire the windoor assembly.")
|
||||
else if(iscoil(W) && anchored)
|
||||
user.visible_message("[user] wires the windoor assembly.", "You start to wire the windoor assembly...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src || !src.anchored || src.state != "01")
|
||||
if(!src || !anchored || state != "01")
|
||||
return
|
||||
var/obj/item/stack/cable_coil/CC = W
|
||||
CC.use(1)
|
||||
to_chat(user, "<span class='notice'>You wire the windoor!</span>")
|
||||
to_chat(user, "<span class='notice'>You wire the windoor.</span>")
|
||||
playsound(loc, CC.usesound, 100, 1)
|
||||
src.state = "02"
|
||||
if(src.secure)
|
||||
src.name = "secure wired windoor assembly"
|
||||
state = "02"
|
||||
if(secure)
|
||||
name = "secure wired windoor assembly"
|
||||
else
|
||||
src.name = "wired windoor assembly"
|
||||
name = "wired windoor assembly"
|
||||
else
|
||||
..()
|
||||
return ..()
|
||||
|
||||
if("02")
|
||||
|
||||
//Removing wire from the assembly. Step 5 undone.
|
||||
if(istype(W, /obj/item/weapon/wirecutters))
|
||||
playsound(src.loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] cuts the wires from the airlock assembly.", "You start to cut the wires from airlock assembly.")
|
||||
if(iswirecutter(W))
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] cuts the wires from the airlock assembly.", "You start to cut the wires from airlock assembly...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src || src.state != "02")
|
||||
if(!src || state != "02")
|
||||
return
|
||||
|
||||
to_chat(user, "<span class='notice'>You cut the windoor wires!</span>")
|
||||
to_chat(user, "<span class='notice'>You cut the windoor wires.</span>")
|
||||
new/obj/item/stack/cable_coil(get_turf(user), 1)
|
||||
src.state = "01"
|
||||
if(src.secure)
|
||||
src.name = "secure anchored windoor assembly"
|
||||
state = "01"
|
||||
if(secure)
|
||||
name = "secure anchored windoor assembly"
|
||||
else
|
||||
src.name = "anchored windoor assembly"
|
||||
name = "anchored windoor assembly"
|
||||
|
||||
//Adding airlock electronics for access. Step 6 complete.
|
||||
else if(istype(W, /obj/item/weapon/airlock_electronics))
|
||||
playsound(src.loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] installs the electronics into the airlock assembly.", "You start to install electronics into the airlock assembly.")
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] installs the electronics into the airlock assembly.", "You start to install electronics into the airlock assembly...")
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
W.forceMove(src)
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src || src.electronics)
|
||||
W.loc = src.loc
|
||||
if(!src || electronics)
|
||||
W.forceMove(loc)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You've installed the airlock electronics!</span>")
|
||||
src.name = "near finished windoor assembly"
|
||||
src.electronics = W
|
||||
to_chat(user, "<span class='notice'>You install the airlock electronics.</span>")
|
||||
name = "near finished windoor assembly"
|
||||
electronics = W
|
||||
else
|
||||
W.loc = src.loc
|
||||
W.forceMove(loc)
|
||||
|
||||
//Screwdriver to remove airlock electronics. Step 6 undone.
|
||||
else if(istype(W, /obj/item/weapon/screwdriver))
|
||||
else if(isscrewdriver(W))
|
||||
if(!electronics)
|
||||
return
|
||||
|
||||
playsound(src.loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] removes the electronics from the airlock assembly.", "You start to uninstall electronics from the airlock assembly.")
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] removes the electronics from the airlock assembly.", "You start to uninstall electronics from the airlock assembly...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
if(!src || !electronics)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You've removed the airlock electronics!</span>")
|
||||
src.name = "wired windoor assembly"
|
||||
to_chat(user, "<span class='notice'>You remove the airlock electronics.</span>")
|
||||
name = "wired windoor assembly"
|
||||
var/obj/item/weapon/airlock_electronics/ae
|
||||
ae = electronics
|
||||
electronics = null
|
||||
ae.loc = src.loc
|
||||
ae.forceMove(loc)
|
||||
|
||||
else if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = stripped_input(user, "Enter the name for the door.", src.name, src.created_name,MAX_NAME_LEN)
|
||||
var/t = stripped_input(user, "Enter the name for the door.", name, created_name,MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, usr) && src.loc != usr)
|
||||
if(!in_range(src, usr) && loc != usr)
|
||||
return
|
||||
created_name = t
|
||||
return
|
||||
@@ -236,70 +239,71 @@ obj/structure/windoor_assembly/Destroy()
|
||||
|
||||
|
||||
//Crowbar to complete the assembly, Step 7 complete.
|
||||
else if(istype(W, /obj/item/weapon/crowbar))
|
||||
if(!src.electronics)
|
||||
to_chat(usr, "<span class='danger'>The assembly is missing electronics.</span>")
|
||||
else if(iscrowbar(W))
|
||||
if(!electronics)
|
||||
to_chat(usr, "<span class='warning'>The assembly is missing electronics!</span>")
|
||||
return
|
||||
usr << browse(null, "window=windoor_access")
|
||||
playsound(src.loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] pries the windoor into the frame.", "You start prying the windoor into the frame.")
|
||||
playsound(loc, W.usesound, 100, 1)
|
||||
user.visible_message("[user] pries the windoor into the frame.", "You start prying the windoor into the frame...")
|
||||
|
||||
if(do_after(user, 40 * W.toolspeed, target = src))
|
||||
|
||||
if(src.loc && src.electronics)
|
||||
if(loc && electronics)
|
||||
for(var/obj/machinery/door/window/WD in loc)
|
||||
if(WD.dir == dir)
|
||||
return
|
||||
|
||||
density = 1 //Shouldn't matter but just incase
|
||||
to_chat(user, "<span class='notice'>You finish the windoor!</span>")
|
||||
density = TRUE //Shouldn't matter but just incase
|
||||
to_chat(user, "<span class='notice'>You finish the windoor.</span>")
|
||||
|
||||
if(secure)
|
||||
var/obj/machinery/door/window/brigdoor/windoor = new /obj/machinery/door/window/brigdoor(src.loc)
|
||||
if(src.facing == "l")
|
||||
if(facing == "l")
|
||||
windoor.icon_state = "leftsecureopen"
|
||||
windoor.base_state = "leftsecure"
|
||||
else
|
||||
windoor.icon_state = "rightsecureopen"
|
||||
windoor.base_state = "rightsecure"
|
||||
windoor.dir = src.dir
|
||||
windoor.density = 0
|
||||
windoor.setDir(dir)
|
||||
windoor.density = FALSE
|
||||
|
||||
if(src.electronics.one_access)
|
||||
windoor.req_one_access = src.electronics.conf_access
|
||||
if(electronics.one_access)
|
||||
windoor.req_one_access = electronics.conf_access
|
||||
else
|
||||
windoor.req_access = src.electronics.conf_access
|
||||
windoor.req_access = electronics.conf_access
|
||||
windoor.electronics = src.electronics
|
||||
src.electronics.loc = windoor
|
||||
electronics.forceMove(windoor)
|
||||
if(created_name)
|
||||
windoor.name = created_name
|
||||
qdel(src)
|
||||
windoor.close()
|
||||
|
||||
|
||||
else
|
||||
var/obj/machinery/door/window/windoor = new /obj/machinery/door/window(src.loc)
|
||||
if(src.facing == "l")
|
||||
var/obj/machinery/door/window/windoor = new /obj/machinery/door/window(loc)
|
||||
if(facing == "l")
|
||||
windoor.icon_state = "leftopen"
|
||||
windoor.base_state = "left"
|
||||
else
|
||||
windoor.icon_state = "rightopen"
|
||||
windoor.base_state = "right"
|
||||
windoor.dir = src.dir
|
||||
windoor.density = 0
|
||||
windoor.setDir(dir)
|
||||
windoor.density = FALSE
|
||||
|
||||
windoor.req_access = src.electronics.conf_access
|
||||
if(electronics.one_access)
|
||||
windoor.req_one_access = electronics.conf_access
|
||||
else
|
||||
windoor.req_access = electronics.conf_access
|
||||
windoor.electronics = src.electronics
|
||||
src.electronics.loc = windoor
|
||||
electronics.forceMove(windoor)
|
||||
if(created_name)
|
||||
windoor.name = created_name
|
||||
qdel(src)
|
||||
windoor.close()
|
||||
|
||||
|
||||
qdel(src)
|
||||
|
||||
|
||||
else
|
||||
..()
|
||||
return ..()
|
||||
|
||||
//Update to reflect changes(if applicable)
|
||||
update_icon()
|
||||
@@ -312,28 +316,23 @@ obj/structure/windoor_assembly/Destroy()
|
||||
set src in oview(1)
|
||||
if(usr.stat || !usr.canmove || usr.restrained())
|
||||
return
|
||||
if(src.anchored)
|
||||
if(anchored)
|
||||
to_chat(usr, "It is fastened to the floor; therefore, you can't rotate it!")
|
||||
return 0
|
||||
//if(src.state != "01")
|
||||
//update_nearby_tiles(need_rebuild=1) //Compel updates before
|
||||
|
||||
src.dir = turn(src.dir, 270)
|
||||
|
||||
//if(src.state != "01")
|
||||
//update_nearby_tiles(need_rebuild=1)
|
||||
|
||||
src.ini_dir = src.dir
|
||||
setDir(turn(dir, 270))
|
||||
ini_dir = dir
|
||||
update_icon()
|
||||
return
|
||||
return TRUE
|
||||
|
||||
/obj/structure/windoor_assembly/AltClick(mob/user)
|
||||
..()
|
||||
if(user.incapacitated())
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
if(!Adjacent(user))
|
||||
if(!in_range(src, user))
|
||||
return
|
||||
revrotate()
|
||||
else
|
||||
revrotate()
|
||||
|
||||
//Flips the windoor assembly, determines whather the door opens to the left or the right
|
||||
/obj/structure/windoor_assembly/verb/flip()
|
||||
@@ -343,11 +342,11 @@ obj/structure/windoor_assembly/Destroy()
|
||||
if(usr.stat || !usr.canmove || usr.restrained())
|
||||
return
|
||||
|
||||
if(src.facing == "l")
|
||||
if(facing == "l")
|
||||
to_chat(usr, "The windoor will now slide to the right.")
|
||||
src.facing = "r"
|
||||
facing = "r"
|
||||
else
|
||||
src.facing = "l"
|
||||
facing = "l"
|
||||
to_chat(usr, "The windoor will now slide to the left.")
|
||||
|
||||
update_icon()
|
||||
|
||||
@@ -148,7 +148,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
return
|
||||
|
||||
|
||||
/obj/structure/window/proc/attack_generic(mob/living/user as mob, damage = 0) //used by attack_alien, attack_animal, and attack_slime
|
||||
/obj/structure/window/attack_generic(mob/living/user, damage = 0) //used by attack_alien, attack_animal, and attack_slime
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
health -= damage
|
||||
@@ -446,6 +446,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
shardtype = /obj/item/weapon/shard/plasma
|
||||
glasstype = /obj/item/stack/sheet/plasmaglass
|
||||
health = 120
|
||||
armor = list("melee" = 75, "bullet" = 5, "laser" = 0, "energy" = 0, "bomb" = 45, "bio" = 100, "rad" = 100)
|
||||
|
||||
/obj/structure/window/plasmabasic/New(Loc,re=0)
|
||||
..()
|
||||
@@ -474,7 +475,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
glasstype = /obj/item/stack/sheet/plasmaglass
|
||||
reinf = 1
|
||||
health = 160
|
||||
|
||||
armor = list("melee" = 85, "bullet" = 20, "laser" = 0, "energy" = 0, "bomb" = 60, "bio" = 100, "rad" = 100)
|
||||
|
||||
/obj/structure/window/plasmareinforced/New(Loc,re=0)
|
||||
..()
|
||||
@@ -499,6 +500,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
reinf = 1
|
||||
basestate = "rwindow"
|
||||
health = 40
|
||||
armor = list("melee" = 50, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 25, "bio" = 100, "rad" = 100)
|
||||
|
||||
/obj/structure/window/reinforced/tinted
|
||||
name = "tinted window"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon
|
||||
name = "weapon"
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
hitsound = "swing_hit"
|
||||
hitsound = "swing_hit"
|
||||
Reference in New Issue
Block a user