mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-02-09 07:49:09 +00:00
* Reworks Duffel Bags (Zippers) * Update backpack.dm * Duiffel Spotfix * error fixes * Update backpack.dm * Update code/modules/antagonists/cult/cult.dm * Update backpack.dm --------- Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com> Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com>
20 lines
702 B
Plaintext
20 lines
702 B
Plaintext
/datum/action/item_action/zipper
|
|
name = "Unzip Duffel"
|
|
desc = "Unzip your equipped duffelbag so you can access its contents."
|
|
|
|
/datum/action/item_action/zipper/New(Target)
|
|
. = ..()
|
|
RegisterSignal(target, COMSIG_DUFFEL_ZIP_CHANGE, PROC_REF(on_zip_change))
|
|
var/obj/item/storage/backpack/duffelbag/duffle_target = target
|
|
on_zip_change(target, duffle_target.zipped_up)
|
|
|
|
/datum/action/item_action/zipper/proc/on_zip_change(datum/source, new_zip)
|
|
SIGNAL_HANDLER
|
|
if(new_zip)
|
|
name = "Unzip"
|
|
desc = "Unzip your equipped duffelbag so you can access its contents."
|
|
else
|
|
name = "Zip"
|
|
desc = "Zip your equipped duffelbag so you can move around faster."
|
|
build_all_button_icons(UPDATE_BUTTON_NAME)
|