mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 03:25:49 +01:00
Converts Most Destroys to use QDEL_NULL
This commit is contained in:
@@ -20,9 +20,7 @@
|
||||
var/obj/item/weapon/canvas/painting = null
|
||||
|
||||
/obj/structure/easel/Destroy()
|
||||
if(painting)
|
||||
qdel(painting)
|
||||
painting = null
|
||||
QDEL_NULL(painting)
|
||||
return ..()
|
||||
|
||||
//Adding canvases
|
||||
|
||||
@@ -23,12 +23,8 @@ var/global/list/captain_display_cases = list()
|
||||
var/state = DISPLAYCASE_FRAME_CIRCUIT
|
||||
|
||||
/obj/structure/displaycase_frame/Destroy()
|
||||
if(circuit)
|
||||
qdel(circuit)
|
||||
circuit = null
|
||||
if(sensor)
|
||||
qdel(sensor)
|
||||
sensor = null
|
||||
QDEL_NULL(circuit)
|
||||
QDEL_NULL(sensor)
|
||||
return ..()
|
||||
|
||||
/obj/structure/displaycase_frame/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
|
||||
@@ -125,8 +121,7 @@ var/global/list/captain_display_cases = list()
|
||||
|
||||
/obj/structure/displaycase/Destroy()
|
||||
dump()
|
||||
qdel(circuit)
|
||||
circuit = null
|
||||
QDEL_NULL(circuit)
|
||||
return ..()
|
||||
|
||||
/obj/structure/displaycase/captains_laser/Destroy()
|
||||
|
||||
@@ -18,9 +18,7 @@
|
||||
update_state()
|
||||
|
||||
/obj/structure/door_assembly/Destroy()
|
||||
if(electronics)
|
||||
qdel(electronics)
|
||||
electronics = null
|
||||
QDEL_NULL(electronics)
|
||||
return ..()
|
||||
|
||||
/obj/structure/door_assembly/door_assembly_com
|
||||
|
||||
@@ -15,30 +15,14 @@
|
||||
var/obj/item/taperoll/engineering/myengitape = null
|
||||
|
||||
/obj/structure/engineeringcart/Destroy()
|
||||
if(myglass)
|
||||
qdel(myglass)
|
||||
myglass = null
|
||||
if(mymetal)
|
||||
qdel(mymetal)
|
||||
mymetal = null
|
||||
if(myplasteel)
|
||||
qdel(myplasteel)
|
||||
myplasteel = null
|
||||
if(myflashlight)
|
||||
qdel(myflashlight)
|
||||
myflashlight = null
|
||||
if(mybluetoolbox)
|
||||
qdel(mybluetoolbox)
|
||||
mybluetoolbox = null
|
||||
if(myyellowtoolbox)
|
||||
qdel(myyellowtoolbox)
|
||||
myyellowtoolbox = null
|
||||
if(myredtoolbox)
|
||||
qdel(myredtoolbox)
|
||||
myredtoolbox = null
|
||||
if(myengitape)
|
||||
qdel(myengitape)
|
||||
myengitape = null
|
||||
QDEL_NULL(myglass)
|
||||
QDEL_NULL(mymetal)
|
||||
QDEL_NULL(myplasteel)
|
||||
QDEL_NULL(myflashlight)
|
||||
QDEL_NULL(mybluetoolbox)
|
||||
QDEL_NULL(myyellowtoolbox)
|
||||
QDEL_NULL(myredtoolbox)
|
||||
QDEL_NULL(myengitape)
|
||||
return ..()
|
||||
|
||||
/obj/structure/engineeringcart/proc/put_in_cart(obj/item/I, mob/user)
|
||||
|
||||
@@ -9,9 +9,7 @@
|
||||
var/opened = 0
|
||||
|
||||
/obj/structure/extinguisher_cabinet/Destroy()
|
||||
if(has_extinguisher)
|
||||
qdel(has_extinguisher)
|
||||
has_extinguisher = null
|
||||
QDEL_NULL(has_extinguisher)
|
||||
return ..()
|
||||
|
||||
/obj/structure/extinguisher_cabinet/attackby(obj/item/O, mob/user, params)
|
||||
|
||||
@@ -25,18 +25,10 @@
|
||||
|
||||
/obj/structure/janitorialcart/Destroy()
|
||||
janitorial_equipment -= src
|
||||
if(mybag)
|
||||
qdel(mybag)
|
||||
mybag = null
|
||||
if(mymop)
|
||||
qdel(mymop)
|
||||
mymop = null
|
||||
if(myspray)
|
||||
qdel(myspray)
|
||||
myspray = null
|
||||
if(myreplacer)
|
||||
qdel(myreplacer)
|
||||
myreplacer = null
|
||||
QDEL_NULL(mybag)
|
||||
QDEL_NULL(mymop)
|
||||
QDEL_NULL(myspray)
|
||||
QDEL_NULL(myreplacer)
|
||||
return ..()
|
||||
|
||||
/obj/structure/janitorialcart/proc/wet_mop(obj/item/weapon/mop, mob/user)
|
||||
|
||||
@@ -160,9 +160,7 @@
|
||||
return
|
||||
|
||||
/obj/structure/morgue/Destroy()
|
||||
if(connected)
|
||||
qdel(connected)
|
||||
connected = null
|
||||
QDEL_NULL(connected)
|
||||
return ..()
|
||||
|
||||
/obj/structure/morgue/container_resist(var/mob/living/L)
|
||||
@@ -405,9 +403,7 @@
|
||||
return
|
||||
|
||||
/obj/structure/crematorium/Destroy()
|
||||
if(connected)
|
||||
qdel(connected)
|
||||
connected = null
|
||||
QDEL_NULL(connected)
|
||||
return ..()
|
||||
|
||||
/obj/structure/crematorium/container_resist(var/mob/living/L)
|
||||
@@ -471,7 +467,7 @@
|
||||
connected.connected = null
|
||||
connected = null
|
||||
return ..()
|
||||
|
||||
|
||||
// Crematorium switch
|
||||
/obj/machinery/crema_switch
|
||||
desc = "Burn baby burn!"
|
||||
@@ -484,7 +480,7 @@
|
||||
var/area/area = null
|
||||
var/otherarea = null
|
||||
var/id = 1
|
||||
|
||||
|
||||
/obj/machinery/crema_switch/attack_ghost(mob/user)
|
||||
if(user.can_advanced_admin_interact())
|
||||
return attack_hand(user)
|
||||
|
||||
@@ -281,8 +281,7 @@
|
||||
icon_state = "piano"
|
||||
|
||||
/obj/structure/piano/Destroy()
|
||||
qdel(song)
|
||||
song = null
|
||||
QDEL_NULL(song)
|
||||
return ..()
|
||||
|
||||
/obj/structure/piano/initialize()
|
||||
|
||||
@@ -9,9 +9,7 @@
|
||||
var/obj/item/target/pinned_target // the current pinned target
|
||||
|
||||
/obj/structure/target_stake/Destroy()
|
||||
if(pinned_target)
|
||||
qdel(pinned_target)
|
||||
pinned_target = null
|
||||
QDEL_NULL(pinned_target)
|
||||
return ..()
|
||||
|
||||
/obj/structure/target_stake/Move()
|
||||
|
||||
@@ -34,9 +34,7 @@ obj/structure/windoor_assembly/New(dir=NORTH)
|
||||
|
||||
obj/structure/windoor_assembly/Destroy()
|
||||
density = 0
|
||||
if(electronics)
|
||||
qdel(electronics)
|
||||
electronics = null
|
||||
QDEL_NULL(electronics)
|
||||
air_update_turf(1)
|
||||
return ..()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user