mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 16:47:13 +01:00
Makes Destroy() a protected proc to safeguard against improper calls (#96331)
This commit is contained in:
@@ -374,7 +374,7 @@ SUBSYSTEM_DEF(garbage)
|
||||
var/start_time = world.time
|
||||
var/start_tick = world.tick_usage
|
||||
SEND_SIGNAL(to_delete, COMSIG_QDELETING, force) // Let the (remaining) components know about the result of Destroy
|
||||
var/hint = to_delete.Destroy(force) // Let our friend know they're about to get fucked up.
|
||||
var/hint = UNLINT(to_delete.Destroy(force)) // Let our friend know they're about to get fucked up.
|
||||
|
||||
if(world.time != start_time)
|
||||
trash.slept_destroy++
|
||||
|
||||
@@ -87,7 +87,7 @@
|
||||
|
||||
/**
|
||||
* Parent types.
|
||||
*
|
||||
*
|
||||
* Abstract-ness is a meta-property of a class that is used to indicate
|
||||
* that the class is intended to be used as a base class for others, and
|
||||
* should not (or cannot) be instantiated.
|
||||
@@ -123,6 +123,7 @@
|
||||
* Returns [QDEL_HINT_QUEUE]
|
||||
*/
|
||||
/datum/proc/Destroy(force = FALSE)
|
||||
PROTECTED_PROC(TRUE)
|
||||
SHOULD_CALL_PARENT(TRUE)
|
||||
SHOULD_NOT_SLEEP(TRUE)
|
||||
tag = null
|
||||
|
||||
Reference in New Issue
Block a user