mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 23:27:34 +01:00
[MIRROR] RCD directional window qol & wall mount patch. Code improvements [MDB IGNORE] (#23400)
* RCD directional window qol & wall mount patch. Code improvements (#77858) ## About The Pull Request Fixes #77852 RCD can build wall mounts on reinforced walls Closes #77848 Not a fix so labelling this as a qol cause it was always intentional but now RCD can build directional windows without building a grill first. Saving some matter units from building a grill is a plus Added auto doc for some procs & made the extra delay when building multiple structures into a define ## Changelog 🆑 fix: rcd can build wallmounts on reinforced walls qol: rcd can build directional windows without requiring/building a grill /🆑 * RCD directional window qol & wall mount patch. Code improvements --------- Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com>
This commit is contained in:
@@ -64,13 +64,7 @@
|
||||
if(RCD_WINDOWGRILLE)
|
||||
var/cost = 0
|
||||
var/delay = 0
|
||||
if(the_rcd.window_type == /obj/structure/window)
|
||||
cost = 4
|
||||
delay = 2 SECONDS
|
||||
else if(the_rcd.window_type == /obj/structure/window/reinforced)
|
||||
cost = 6
|
||||
delay = 2.5 SECONDS
|
||||
else if(the_rcd.window_type == /obj/structure/window/fulltile)
|
||||
if(the_rcd.window_type == /obj/structure/window/fulltile)
|
||||
cost = 8
|
||||
delay = 3 SECONDS
|
||||
else if(the_rcd.window_type == /obj/structure/window/reinforced/fulltile)
|
||||
@@ -98,15 +92,13 @@
|
||||
|
||||
if(repair_grille())
|
||||
balloon_alert(user, "grille rebuilt")
|
||||
|
||||
if(!clear_tile(user))
|
||||
return FALSE
|
||||
|
||||
var/obj/structure/window/window_path = the_rcd.window_type
|
||||
if(!ispath(window_path))
|
||||
CRASH("Invalid window path type in RCD: [window_path]")
|
||||
if(!valid_build_direction(T, user.dir, is_fulltile = initial(window_path.fulltile)))
|
||||
balloon_alert(user, "window already here!")
|
||||
if(!initial(window_path.fulltile)) //only fulltile windows can be built here
|
||||
return FALSE
|
||||
var/obj/structure/window/WD = new the_rcd.window_type(T, user.dir)
|
||||
WD.set_anchored(TRUE)
|
||||
|
||||
Reference in New Issue
Block a user