mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
Halligan Improvements (#33503)
* uses default crowbar behavior for unpowered airlocks * shutter cutting * halligan sound * a * sprites * fix * fix * CE buffs * adjustment * fixes * REEEE * finally * Review update * ok
This commit is contained in:
@@ -1218,8 +1218,10 @@ About the new airlock wires panel:
|
||||
return
|
||||
if(istype(I, /obj/item/tool/crowbar/halligan))
|
||||
var/breaktime = 10 SECONDS
|
||||
if(!operating && density && src.arePowerSystemsOn() && !((stat) & NOPOWER) && !welded)
|
||||
if(locked && !lifted)
|
||||
to_chat(user, "<span class='notice'>You begin to lift \the [src] out of its track, exposing the bolts.</span>")
|
||||
playsound(src, 'sound/effects/rustle-metal.ogg', 50, 1)
|
||||
if(do_after(user,src,breaktime))
|
||||
to_chat(user, "<span class='notice'>You begin to lift the airlock out of its track, exposing the bolts.</span>")
|
||||
playsound(src, 'sound/items/Deconstruct.ogg', 50, 1)
|
||||
|
||||
@@ -6,6 +6,8 @@
|
||||
var/sound_open = 'sound/machines/shutter_open.ogg'
|
||||
var/sound_close = 'sound/machines/shutter_close.ogg'
|
||||
animation_delay = 7
|
||||
var/cut_open = FALSE
|
||||
var/pried_open = FALSE
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/preopen
|
||||
icon_state = "shutter0"
|
||||
@@ -13,8 +15,44 @@
|
||||
opacity = 0
|
||||
layer = BELOW_TABLE_LAYER
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/attackby(var/obj/item/weapon/C, var/mob/user)
|
||||
/obj/machinery/door/poddoor/shutters/attackby(var/obj/item/I, var/mob/user)
|
||||
add_fingerprint(user)
|
||||
if(istype(I,/obj/item/tool/crowbar/halligan))
|
||||
var/obj/item/tool/crowbar/halligan/H = I
|
||||
if(density && !pried_open) //can't cut an open door open
|
||||
if(cut_open)
|
||||
pry(user)
|
||||
return
|
||||
else
|
||||
cut(H,user)
|
||||
return
|
||||
if(istype(I,/obj/item/stack/sheet/metal))
|
||||
var/obj/item/stack/sheet/metal/S = I
|
||||
if(pried_open)
|
||||
if(S.use(2))
|
||||
to_chat(user, "<span class='notice'>You begin mending the damage to the [src].</span>")
|
||||
if(do_after(user,src,3 SECONDS))
|
||||
playsound(src, 'sound/items/Deconstruct.ogg', 50, 1)
|
||||
to_chat(user, "<span class='notice'>You finish mending the damage to the [src].</span>")
|
||||
icon_state = "shutter2"
|
||||
setDensity(TRUE)
|
||||
set_opacity(1)
|
||||
pried_open = FALSE
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You need at least 2 sheets to mend the damage to the [src].</span>")
|
||||
if(iswelder(I))
|
||||
var/obj/item/tool/weldingtool/WT = I
|
||||
if(cut_open || pried_open)
|
||||
if(!pried_open)
|
||||
weld(WT,user)
|
||||
to_chat(user, "<span class='notice'>You finish welding the [src].</span>")
|
||||
icon_state = "shutter1"
|
||||
cut_open = FALSE
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You need to add metal sheets first.</span>")
|
||||
|
||||
if(istype(I,/obj/item/weapon))
|
||||
var/obj/item/weapon/C = I
|
||||
if(!(iscrowbar(C) || (istype(C, /obj/item/weapon/fireaxe) && C.wielded == 1) ))
|
||||
return
|
||||
if(density && (stat & (FORCEDISABLE|NOPOWER)) && !operating)
|
||||
@@ -30,6 +68,16 @@
|
||||
operating = 0
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/open()
|
||||
if(cut_open && !pried_open)
|
||||
icon_state = "shutter2"
|
||||
setDensity(TRUE)
|
||||
set_opacity(1)
|
||||
return FALSE
|
||||
if(pried_open)
|
||||
icon_state = "shutter3"
|
||||
setDensity(FALSE)
|
||||
set_opacity(0)
|
||||
return FALSE
|
||||
if(!density) //it's already open bro
|
||||
return FALSE
|
||||
if(operating == 1) //doors can still open when emag-disabled
|
||||
@@ -56,13 +104,24 @@
|
||||
return 1
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/close()
|
||||
if(cut_open && !pried_open)
|
||||
icon_state = "shutter2"
|
||||
setDensity(TRUE)
|
||||
set_opacity(1)
|
||||
return FALSE
|
||||
if(pried_open)
|
||||
icon_state = "shutter3"
|
||||
setDensity(FALSE)
|
||||
set_opacity(0)
|
||||
return FALSE
|
||||
if(operating)
|
||||
return
|
||||
operating = 1
|
||||
plane = closed_plane
|
||||
layer = closed_layer
|
||||
flick("shutterc1", src)
|
||||
icon_state = "shutter1"
|
||||
if(!cut_open && !pried_open)
|
||||
flick("shutterc1", src)
|
||||
playsound(src.loc, sound_close, 100, 1)
|
||||
density = 1
|
||||
if(visible)
|
||||
@@ -71,3 +130,52 @@
|
||||
|
||||
sleep(animation_delay)
|
||||
operating = 0
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/examine(mob/user)
|
||||
..()
|
||||
if(cut_open && !pried_open)
|
||||
to_chat(user, "<span class='info'>A hole has been cut into \the [src]. It still needs to be pried open with a Halligan bar.</span>")
|
||||
return
|
||||
else if(pried_open)
|
||||
to_chat(user, "<span class='info'>A hole has been cut into \the [src]. It can be repaired with metal and a welding tool.</span>")
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/proc/cut(var/obj/item/tool/crowbar/halligan/T, mob/user as mob)
|
||||
if(istype(user,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
var/breaktime = 30 SECONDS
|
||||
if(H.get_strength() >= 2)
|
||||
breaktime = 15 SECONDS
|
||||
to_chat(user, "<span class='notice'>You begin cutting through \the [src].</span>")
|
||||
if(!do_after(user, src, breaktime, 10, custom_checks = new /callback(T, /obj/item/weapon/fireaxe/proc/on_do_after)))
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You finish cutting through \the [src].</span>")
|
||||
cut_open = TRUE
|
||||
icon_state = "shutter2"
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/proc/pry(mob/user as mob)
|
||||
if(istype(user,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
var/breaktime = 10 SECONDS
|
||||
if(H.get_strength() >= 2)
|
||||
breaktime = 5 SECONDS
|
||||
to_chat(user, "<span class='notice'>You begin prying \the [src] open.</span>")
|
||||
if(!do_after(user,src,breaktime))
|
||||
return
|
||||
playsound(src, 'sound/effects/grillehit.ogg', 50, 1)
|
||||
to_chat(user, "<span class='notice'>You finish prying \the [src] open.</span>")
|
||||
pried_open = TRUE
|
||||
icon_state = "shutter3"
|
||||
setDensity(FALSE)
|
||||
set_opacity(0)
|
||||
|
||||
/obj/machinery/door/poddoor/shutters/proc/weld(var/obj/item/tool/weldingtool/WT, var/mob/user)
|
||||
if(!WT.isOn())
|
||||
return 0
|
||||
to_chat(user, "<span class='notice'>You start to weld the [src]...</span>")
|
||||
WT.playtoolsound(src, 50)
|
||||
WT.eyecheck(user)
|
||||
if(do_after(user, src, 20))
|
||||
if(!WT.isOn())
|
||||
return 0
|
||||
return 1
|
||||
return 0
|
||||
|
||||
@@ -762,6 +762,11 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/tool/crowbar/halligan/proc/on_do_after(mob/user, use_user_turf, user_original_location, atom/target, target_original_location, needhand, obj/item/originally_held_item)
|
||||
. = do_after_default_checks(arglist(args))
|
||||
if(.)
|
||||
playsound(src,"sound/items/metal_impact.ogg",50,1)
|
||||
|
||||
/obj/item/tool/irons
|
||||
name = "set of irons"
|
||||
desc = "Fireaxe and Halligan bar used for forcible entry."
|
||||
|
||||
@@ -38,7 +38,8 @@
|
||||
/obj/item/clothing/glasses/scanner/material,
|
||||
/obj/item/weapon/card/debit/preferred/department/engineering,
|
||||
/obj/item/weapon/reagent_containers/food/snacks/monkeycube/gourmonger,
|
||||
/obj/item/tool/solder/screw
|
||||
/obj/item/tool/solder/screw,
|
||||
/obj/item/tool/crowbar/halligan
|
||||
)
|
||||
|
||||
/obj/structure/closet/secure_closet/engineering_electrical
|
||||
|
||||
@@ -43,6 +43,7 @@
|
||||
species_restricted = list("exclude",VOX_SHAPED)
|
||||
max_heat_protection_temperature = FIRESUIT_MAX_HEAT_PROTECTION_TEMPERATURE
|
||||
clothing_flags = PLASMAGUARD
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/weapon/storage/bag/ore,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/device/rcd, /obj/item/tool/wrench/socket, /obj/item/tool/irons)
|
||||
cell_type = /obj/item/weapon/cell/super
|
||||
head_type = /obj/item/clothing/head/helmet/space/rig/engineer/elite
|
||||
|
||||
@@ -388,7 +389,7 @@
|
||||
slowdown = HARDSUIT_SLOWDOWN_HIGH
|
||||
species_fit = list(GREY_SHAPED,INSECT_SHAPED)
|
||||
armor = list(melee = 30, bullet = 5, laser = 40,energy = 5, bomb = 35, bio = 100, rad = 60)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/weapon/storage/backpack/satchel_norm,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/device/rcd, /obj/item/weapon/extinguisher, /obj/item/weapon/extinguisher/foam, /obj/item/weapon/storage/toolbox, /obj/item/tool/wrench/socket)
|
||||
allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank,/obj/item/weapon/storage/backpack/satchel_norm,/obj/item/device/t_scanner,/obj/item/weapon/pickaxe, /obj/item/device/rcd, /obj/item/weapon/extinguisher, /obj/item/weapon/extinguisher/foam, /obj/item/weapon/storage/toolbox, /obj/item/tool/wrench/socket, /obj/item/tool/irons)
|
||||
head_type = /obj/item/clothing/head/helmet/space/rig/atmos/gold
|
||||
|
||||
//ADMINBUS RIGS. SOVIET + NAZI
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 32 KiB |
Reference in New Issue
Block a user