mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-23 12:08:28 +01:00
Adds Destroys.
This commit is contained in:
@@ -115,7 +115,9 @@
|
||||
spawn(5)
|
||||
radio = new /obj/item/radio/integrated/signal(src)
|
||||
|
||||
|
||||
/obj/item/weapon/cartridge/signal/Destroy()
|
||||
qdel(radio)
|
||||
..()
|
||||
|
||||
/obj/item/weapon/cartridge/quartermaster
|
||||
name = "\improper Space Parts & Space Vendors cartridge"
|
||||
|
||||
@@ -99,6 +99,12 @@
|
||||
post_signal(control_freq, "command", "summon", "active", active, "target", get_turf(PDA) , s_filter = RADIO_SECBOT)
|
||||
post_signal(control_freq, "command", "bot_status", "active", active, s_filter = RADIO_SECBOT)
|
||||
|
||||
|
||||
/obj/item/radio/integrated/beepsky/Destroy()
|
||||
if(radio_controller)
|
||||
radio_controller.remove_object(src, control_freq)
|
||||
..()
|
||||
|
||||
/obj/item/radio/integrated/mule
|
||||
var/list/botlist = null // list of bots
|
||||
var/obj/machinery/bot/mulebot/active // the active bot; if null, show bot list
|
||||
@@ -245,3 +251,8 @@
|
||||
radio_connection.post_signal(src, signal)
|
||||
|
||||
return
|
||||
|
||||
/obj/item/radio/integrated/signal/Destroy()
|
||||
if(radio_controller)
|
||||
radio_controller.remove_object(src, frequency)
|
||||
..()
|
||||
|
||||
@@ -29,6 +29,8 @@
|
||||
/obj/item/device/radio/headset/Destroy()
|
||||
qdel(keyslot1)
|
||||
qdel(keyslot2)
|
||||
keyslot1 = null
|
||||
keyslot2 = null
|
||||
..()
|
||||
|
||||
/obj/item/device/radio/headset/examine(mob/user)
|
||||
|
||||
@@ -45,6 +45,15 @@
|
||||
if(radio_controller)
|
||||
initialize()
|
||||
|
||||
/obj/item/device/radio/Destroy()
|
||||
qdel(wires)
|
||||
wires = null
|
||||
if(radio_controller)
|
||||
radio_controller.remove_object(src, frequency)
|
||||
for (var/ch_name in channels)
|
||||
radio_controller.remove_object(src, radiochannels[ch_name])
|
||||
..()
|
||||
|
||||
|
||||
/obj/item/device/radio/initialize()
|
||||
|
||||
@@ -625,7 +634,6 @@
|
||||
onclose(user, "radio")
|
||||
return
|
||||
|
||||
|
||||
/obj/item/device/radio/proc/config(op)
|
||||
if(radio_controller)
|
||||
for (var/ch_name in channels)
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
var/icon/virtualIcon
|
||||
var/list/bulletholes = list()
|
||||
|
||||
Del()
|
||||
Destroy()
|
||||
// if a target is deleted and associated with a stake, force stake to forget
|
||||
for(var/obj/structure/target_stake/T in view(3,src))
|
||||
if(T.pinned_target == src)
|
||||
|
||||
@@ -31,10 +31,10 @@
|
||||
|
||||
/obj/item/stack/Destroy()
|
||||
if(uses_charge)
|
||||
return
|
||||
return 1
|
||||
if (src && usr && usr.machine == src)
|
||||
usr << browse(null, "window=stack")
|
||||
..()
|
||||
return ..()
|
||||
|
||||
/obj/item/stack/examine(mob/user)
|
||||
if(..(user, 1))
|
||||
|
||||
@@ -40,6 +40,11 @@
|
||||
spark_system.set_up(5, 0, src)
|
||||
spark_system.attach(src)
|
||||
|
||||
/obj/item/weapon/rcd/Destroy()
|
||||
qdel(spark_system)
|
||||
spark_system = null
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/rcd/attackby(obj/item/weapon/W, mob/user)
|
||||
|
||||
if(istype(W, /obj/item/weapon/rcd_ammo))
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
icon_state = "implant_melted"
|
||||
malfunction = MALFUNCTION_PERMANENT
|
||||
|
||||
Del()
|
||||
Destroy()
|
||||
if(part)
|
||||
part.implants.Remove(src)
|
||||
..()
|
||||
|
||||
@@ -9,6 +9,10 @@
|
||||
name = master_item.name
|
||||
verbs -= /obj/item/verb/verb_pickup //make sure this is never picked up.
|
||||
..()
|
||||
|
||||
/obj/item/weapon/storage/internal/Destroy()
|
||||
master_item = null
|
||||
..()
|
||||
|
||||
/obj/item/weapon/storage/internal/attack_hand()
|
||||
return //make sure this is never picked up
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
w_class = 3
|
||||
var/list/can_hold = new/list() //List of objects which this item can store (if set, it can't store anything else)
|
||||
var/list/cant_hold = new/list() //List of objects which this item can't store (in effect only if can_hold isn't set)
|
||||
var/list/is_seeing = new/list() //List of mobs which are currently seeing the contents of this item's storage
|
||||
var/max_w_class = 2 //Max size of objects that this object can store (in effect only if can_hold isn't set)
|
||||
var/max_storage_space = 14 //The sum of the storage costs of all the items in this storage item.
|
||||
var/storage_slots = 7 //The number of storage slots in this container.
|
||||
@@ -23,6 +24,12 @@
|
||||
var/collection_mode = 1; //0 = pick one at a time, 1 = pick all on tile
|
||||
var/use_sound = "rustle" //sound played when used. null for no sound.
|
||||
|
||||
/obj/item/weapon/storage/Destroy()
|
||||
close_all()
|
||||
qdel(boxes)
|
||||
qdel(closer)
|
||||
..()
|
||||
|
||||
/obj/item/weapon/storage/MouseDrop(obj/over_object as obj)
|
||||
|
||||
if(!canremove)
|
||||
@@ -86,6 +93,7 @@
|
||||
user.client.screen += src.closer
|
||||
user.client.screen += src.contents
|
||||
user.s_active = src
|
||||
is_seeing |= user
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/proc/hide_from(mob/user as mob)
|
||||
@@ -97,7 +105,7 @@
|
||||
user.client.screen -= src.contents
|
||||
if(user.s_active == src)
|
||||
user.s_active = null
|
||||
return
|
||||
is_seeing -= user
|
||||
|
||||
/obj/item/weapon/storage/proc/open(mob/user as mob)
|
||||
if (src.use_sound)
|
||||
@@ -109,11 +117,24 @@
|
||||
show_to(user)
|
||||
|
||||
/obj/item/weapon/storage/proc/close(mob/user as mob)
|
||||
|
||||
src.hide_from(user)
|
||||
user.s_active = null
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/proc/close_all()
|
||||
for(var/mob/M in can_see_contents())
|
||||
close(M)
|
||||
. = 1
|
||||
|
||||
/obj/item/weapon/storage/proc/can_see_contents()
|
||||
var/list/cansee = list()
|
||||
for(var/mob/M in is_seeing)
|
||||
if(M.s_active == src && M.client)
|
||||
cansee |= M
|
||||
else
|
||||
is_seeing -= M
|
||||
return cansee
|
||||
|
||||
//This proc draws out the inventory and places the items on it. tx and ty are the upper left tile and mx, my are the bottm right.
|
||||
//The numbers are calculated from the bottom-left The bottom-left slot being 1,1.
|
||||
/obj/item/weapon/storage/proc/orient_objs(tx, ty, mx, my)
|
||||
@@ -463,4 +484,4 @@
|
||||
return depth
|
||||
|
||||
/obj/item/proc/get_storage_cost()
|
||||
return 2**(w_class-1) //1,2,4,8,16,...
|
||||
return 2**(w_class-1) //1,2,4,8,16,...
|
||||
|
||||
Reference in New Issue
Block a user