Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes teslas in fiorina #6900

Merged
merged 2 commits into from
Aug 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions code/modules/defenses/tesla_coil.dm
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
var/last_fired = 0
var/tesla_range = TESLA_COIL_RANGE
var/fire_delay = TESLA_COIL_FIREDELAY
var/attack_defenses = TRUE
handheld_type = /obj/item/defenses/handheld/tesla_coil
disassemble_time = 10
health = 150
Expand Down Expand Up @@ -83,6 +84,9 @@
targets += M
FOR_DOVIEW_END

if(!attack_defenses)
return

FOR_DOVIEW(var/obj/structure/machinery/defenses/D, tesla_range, src, HIDE_INVISIBLE_OBSERVER)
if(D.turned_on)
targets += D
Expand Down Expand Up @@ -159,6 +163,17 @@

. = ..()

// For mapping
/obj/structure/machinery/defenses/tesla_coil/premade
turned_on = TRUE
static = TRUE

/obj/structure/machinery/defenses/tesla_coil/premade/attackby(obj/item/O, mob/user)
return

/obj/structure/machinery/defenses/tesla_coil/premade/smart
attack_defenses = FALSE

#define TESLA_COIL_STUN_FIRE_DELAY 3 SECONDS
#define TESLA_COIL_STUN_EFFECT 1
/obj/structure/machinery/defenses/tesla_coil/stun
Expand Down
4 changes: 2 additions & 2 deletions maps/map_files/FOP_v3_Sciannex/Fiorina_SciAnnex.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -845,7 +845,7 @@
/turf/open/floor/prison/floor_plate,
/area/fiorina/station/telecomm/lz1_cargo)
"aFp" = (
/obj/structure/machinery/defenses/tesla_coil{
/obj/structure/machinery/defenses/tesla_coil/premade/smart{
faction_group = list("CLF")
},
/turf/open/floor/plating/plating_catwalk,
Expand Down Expand Up @@ -30182,7 +30182,7 @@
/turf/open/floor/corsat/squares,
/area/fiorina/station/medbay)
"xgx" = (
/obj/structure/machinery/defenses/tesla_coil{
/obj/structure/machinery/defenses/tesla_coil/premade{
faction_group = list("USCM")
},
/turf/open/organic/grass/astroturf,
Expand Down
Loading