objective items being destroyed are now logged (#20485)

* objective items being destroyed is now logged

* signal time

* oop

* Update code/modules/projectiles/guns/energy/laser.dm

Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>

* Update code/game/objects/items/documents.dm

Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>

* mira review

---------

Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com>
This commit is contained in:
GDN
2023-03-08 20:15:16 +01:00
committed by GitHub
co-authored by S34N
parent 157c92c758
commit 626d2754d5
14 changed files with 46 additions and 0 deletions
+5
View File
@@ -177,6 +177,11 @@ GLOBAL_DATUM_INIT(welding_sparks, /mutable_appearance, mutable_appearance('icons
master = null
return ..()
/obj/item/proc/alert_admins_on_destroy()
SIGNAL_HANDLER
message_admins("[src] has been destroyed at [ADMIN_COORDJMP(src)].")
log_game("[src] has been destroyed at ([x],[y],[z]) in the location [loc].")
/obj/item/proc/check_allowed_items(atom/target, not_inside, target_self)
if(((src in target) && !target_self) || (!isturf(target.loc) && !isturf(target) && not_inside))
return FALSE
+1
View File
@@ -345,3 +345,4 @@
/obj/item/areaeditor/blueprints/ce/Initialize(mapload)
. = ..()
ADD_TRAIT(src, TRAIT_SHOW_WIRE_INFO, ROUNDSTART_TRAIT)
RegisterSignal(src, COMSIG_PARENT_QDELETING, PROC_REF(alert_admins_on_destroy))
+4
View File
@@ -11,6 +11,10 @@
pressure_resistance = 2
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF
/obj/item/documents/Initialize(mapload)
. = ..()
RegisterSignal(src, COMSIG_PARENT_QDELETING, PROC_REF(alert_admins_on_destroy))
/obj/item/documents/nanotrasen
desc = "\"Top Secret\" Nanotrasen documents printed on special copy-protected paper. It is filled with complex diagrams and lists of names, dates and coordinates."
icon_state = "docs_verified"
+1
View File
@@ -259,6 +259,7 @@
. = ..()
cell = new /obj/item/stock_parts/cell/bluespace/charging(src)
update_icon(UPDATE_OVERLAYS)
RegisterSignal(src, COMSIG_PARENT_QDELETING, PROC_REF(alert_admins_on_destroy))
/obj/item/defibrillator/compact/advanced/emp_act(severity)
if(world.time > next_emp_message)
@@ -40,6 +40,7 @@
/obj/item/melee/rapier/Initialize(mapload)
. = ..()
AddComponent(/datum/component/parry, _stamina_constant = 2, _stamina_coefficient = 0.5, _parryable_attack_types = NON_PROJECTILE_ATTACKS)
RegisterSignal(src, COMSIG_PARENT_QDELETING, PROC_REF(alert_admins_on_destroy))
/obj/item/melee/icepick
name = "ice pick"
@@ -133,6 +133,10 @@
w_class = WEIGHT_CLASS_NORMAL
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF //steal objective items are hard to destroy.
/obj/item/tank/jetpack/oxygen/captain/Initialize(mapload)
. = ..()
RegisterSignal(src, COMSIG_PARENT_QDELETING, PROC_REF(alert_admins_on_destroy))
/obj/item/tank/jetpack/oxygen/security
name = "security jetpack (oxygen)"
desc = "A tank of compressed oxygen for use as propulsion in zero-gravity areas by security forces."
@@ -109,6 +109,10 @@ Frequency:
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF
var/active_portals = 0
/obj/item/hand_tele/Initialize(mapload)
. = ..()
RegisterSignal(src, COMSIG_PARENT_QDELETING, PROC_REF(alert_admins_on_destroy))
/obj/item/hand_tele/attack_self(mob/user)
var/turf/current_location = get_turf(user)//What turf is the user on?
if(!current_location||!is_teleport_allowed(current_location.z))//If turf was not found or they're somewhere teleproof