From 2d2bedc7a8a6fb7c58f6f4d296000c0d7925942f Mon Sep 17 00:00:00 2001 From: Killian <49700375+KillianKirilenko@users.noreply.github.com> Date: Wed, 27 Sep 2023 01:33:58 +0100 Subject: [PATCH] laserdome updates makes it so you can't pass through the gate whilst holding an object that has a new var set to false --- code/game/objects/objs.dm | 2 ++ code/modules/awaymissions/redgate.dm | 17 +++++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/code/game/objects/objs.dm b/code/game/objects/objs.dm index b9a0f53c7d0..c36782c0693 100644 --- a/code/game/objects/objs.dm +++ b/code/game/objects/objs.dm @@ -21,6 +21,8 @@ var/show_examine = TRUE // Does this pop up on a mob when the mob is examined? + var/redgate_allowed = TRUE //can we be taken through the redgate, in either direction? + /obj/Destroy() STOP_PROCESSING(SSobj, src) diff --git a/code/modules/awaymissions/redgate.dm b/code/modules/awaymissions/redgate.dm index 1671cafe04e..df61cc955bf 100644 --- a/code/modules/awaymissions/redgate.dm +++ b/code/modules/awaymissions/redgate.dm @@ -11,8 +11,7 @@ var/obj/structure/redgate/target var/secret = FALSE //If either end of the redgate has this enabled, ghosts will not be able to click to teleport var/list/exceptions = list( - /obj/structure/ore_box, - /obj/item/weapon/laserdome_flag + /obj/structure/ore_box ) //made it a var so that GMs or map makers can selectively allow things to pass through var/list/restrictions = list( /mob/living/simple_mob/vore/overmap/stardog, @@ -39,6 +38,11 @@ if(M.type in restrictions) //Some stuff we don't want to bring EVEN IF it has a key. return + for(var/obj/O in M.contents) + if(O.redgate_allowed == FALSE) + to_chat(M, "The redgate refuses to allow you to pass whilst you possess \the [O].") + return + if(keycheck) //exceptions probably won't have a ckey if(!M.ckey) //We only want players, no bringing the weird stuff on the other side back return @@ -1075,12 +1079,13 @@ /obj/item/weapon/laserdome_flag name = "Flag" desc = "Steal the enemy flag and take it to your base in order to score! First team to three captures wins! Or was it five? Eh, check with the referee I guess." - description_info = "When you're carrying your flag, use it on your team's flag base to return it; if you're carrying the enemy flag, use it on your team's flag base to score a point!" + description_info = "Simply pick up your team's flag to return it to your base. If you're carrying the enemy flag, use it on your team's flag base to score a point!" slowdown = 1 //big flag is harder to run with, encourages teamwork icon = 'icons/obj/flags.dmi' icon_state = "flag" var/laser_team = "neutral" w_class = ITEMSIZE_NO_CONTAINER //no stashing the flag in a bag for you, bucko! + redgate_allowed = FALSE //no running off the map with the flags either var/start_pos /obj/item/weapon/laserdome_flag/Initialize() @@ -1123,17 +1128,17 @@ global_announcer.autosay("[src] [flag_verbed] by [grabbing_team] team!","Laserdome Announcer","Entertainment") /obj/item/weapon/laserdome_flag/red - name = "Red flag" + name = "\improper Red flag" icon_state = "red_flag" laser_team = "red" /obj/item/weapon/laserdome_flag/blue - name = "Blue flag" + name = "\improper Blue flag" icon_state = "blue_flag" laser_team = "blue" /obj/structure/flag_base - name = "Flag base" + name = "\improper Flag base" icon = 'icons/obj/flags.dmi' icon_state = "flag_base" var/base_team