mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-28 06:28:01 +01:00
Merge pull request #5092 from VOREStation/upstream-merge-6106
[MIRROR] ore bags will now automatically pick up ore and dump them into a box if one is being pulled.
This commit is contained in:
@@ -118,6 +118,27 @@
|
||||
to_chat(user, "<span class='notice'>You fill the [src].</span>")
|
||||
else if(!silent)
|
||||
to_chat(user, "<span class='notice'>You fail to pick anything up with \the [src].</span>")
|
||||
if(istype(user.pulling, /obj/structure/ore_box/)) //Bit of a crappy way to do this, as it doubles spam for the user, but it works.
|
||||
var/obj/structure/ore_box/O = user.pulling
|
||||
O.attackby(src, user)
|
||||
|
||||
/obj/item/weapon/storage/bag/ore/equipped(mob/user)
|
||||
..()
|
||||
if(user.get_inventory_slot(src) == slot_wear_suit || slot_l_hand || slot_l_hand || slot_belt) //Basically every place they can go. Makes sure it doesn't unregister if moved to other slots.
|
||||
GLOB.moved_event.register(user, src, /obj/item/weapon/storage/bag/ore/proc/autoload, user)
|
||||
|
||||
/obj/item/weapon/storage/bag/ore/dropped(mob/user)
|
||||
..()
|
||||
if(user.get_inventory_slot(src) == slot_wear_suit || slot_l_hand || slot_l_hand || slot_belt) //See above. This should really be a define.
|
||||
GLOB.moved_event.register(user, src, /obj/item/weapon/storage/bag/ore/proc/autoload, user)
|
||||
else
|
||||
GLOB.moved_event.unregister(user, src)
|
||||
|
||||
/obj/item/weapon/storage/bag/ore/proc/autoload(mob/user)
|
||||
var/obj/item/weapon/ore/O = locate() in get_turf(src)
|
||||
if(O)
|
||||
gather_all(get_turf(src), user)
|
||||
|
||||
|
||||
/obj/item/weapon/storage/bag/ore/examine(mob/user)
|
||||
..()
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
################################
|
||||
# Example Changelog File
|
||||
#
|
||||
# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb.
|
||||
#
|
||||
# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.)
|
||||
# When it is, any changes listed below will disappear.
|
||||
#
|
||||
# Valid Prefixes:
|
||||
# bugfix
|
||||
# wip (For works in progress)
|
||||
# tweak
|
||||
# soundadd
|
||||
# sounddel
|
||||
# rscadd (general adding of nice things)
|
||||
# rscdel (general deleting of nice things)
|
||||
# imageadd
|
||||
# imagedel
|
||||
# maptweak
|
||||
# spellcheck (typo fixes)
|
||||
# experiment
|
||||
#################################
|
||||
|
||||
# Your name.
|
||||
author: chaoko99
|
||||
|
||||
# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again.
|
||||
delete-after: True
|
||||
|
||||
# Any changes you've made. See valid prefix list above.
|
||||
# INDENT WITH TWO SPACES. NOT TABS. SPACES.
|
||||
# SCREW THIS UP AND IT WON'T WORK.
|
||||
# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries.
|
||||
# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog.
|
||||
changes:
|
||||
- rscadd: "Ore bags will automatically pick up items when held, belted, or pocketed, and automatically deposit ore in boxes if one is being pulled."
|
||||
|
||||
Reference in New Issue
Block a user