mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-22 20:43:10 +01:00
Sleek Wristbound Radio (#15918)
This commit is contained in:
@@ -70,7 +70,7 @@ var/global/list/exclude_jobs = list(/datum/job/ai, /datum/job/cyborg, /datum/job
|
||||
var/global/list/pdalist = list("Nothing", "Standard PDA", "Classic PDA", "Rugged PDA", "Slate PDA", "Smart PDA", "Tablet", "Wristbound")
|
||||
|
||||
//Headset choice
|
||||
var/global/list/headsetlist = list("Nothing", "Headset", "Bowman Headset", "Double Headset", "Wristbound Radio")
|
||||
var/global/list/headsetlist = list("Nothing", "Headset", "Bowman Headset", "Double Headset", "Wristbound Radio", "Sleek Wristbound Radio")
|
||||
|
||||
// Primary Radio Slot choice
|
||||
var/global/list/primary_radio_slot_choice = list("Left Ear", "Right Ear", "Wrist")
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
#define OUTFIT_BOWMAN 3
|
||||
#define OUTFIT_DOUBLE 4
|
||||
#define OUTFIT_WRISTRAD 5
|
||||
#define OUTFIT_THIN_WRISTRAD 6
|
||||
|
||||
/datum/outfit
|
||||
var/name = "Naked"
|
||||
@@ -229,6 +230,7 @@
|
||||
else
|
||||
H.equip_or_collect(B, slot_back)
|
||||
|
||||
var/datum/callback/radio_callback
|
||||
if(allow_headset_choice)
|
||||
switch(H.headset_choice)
|
||||
if (OUTFIT_NOTHING)
|
||||
@@ -237,21 +239,26 @@
|
||||
l_ear = bowman
|
||||
if (OUTFIT_DOUBLE)
|
||||
l_ear = double_headset
|
||||
if (OUTFIT_WRISTRAD)
|
||||
if (OUTFIT_WRISTRAD, OUTFIT_THIN_WRISTRAD)
|
||||
l_ear = null
|
||||
wrist = wrist_radio
|
||||
if(H.headset_choice == OUTFIT_THIN_WRISTRAD)
|
||||
radio_callback = CALLBACK(src, PROC_REF(turn_into_thinset))
|
||||
else
|
||||
l_ear = headset //Department headset
|
||||
if(l_ear)
|
||||
equip_item(H, l_ear, slot_l_ear)
|
||||
equip_item(H, l_ear, slot_l_ear, callback = radio_callback)
|
||||
else if (wrist)
|
||||
equip_item(H, wrist, slot_wrists)
|
||||
equip_item(H, wrist, slot_wrists, callback = radio_callback)
|
||||
|
||||
return
|
||||
/datum/outfit/proc/turn_into_thinset(var/obj/item/device/radio/headset/wrist/radio)
|
||||
if(istype(radio))
|
||||
radio.icon_state = replacetext(radio.icon_state, "wrist", "thin")
|
||||
radio.item_state = replacetext(radio.item_state, "wrist", "thin")
|
||||
|
||||
// Used to equip an item to the mob. Mainly to prevent copypasta for collect_not_del.
|
||||
//override_collect temporarily allows equip_or_collect without enabling it for the job. Mostly used to prevent weirdness with hand equips when the player is missing one
|
||||
/datum/outfit/proc/equip_item(mob/living/carbon/human/H, path, slot, var/override_collect = FALSE, var/item_color)
|
||||
/datum/outfit/proc/equip_item(mob/living/carbon/human/H, path, slot, var/override_collect = FALSE, var/item_color, var/datum/callback/callback)
|
||||
var/obj/item/I
|
||||
|
||||
if(isnum(path)) //Check if parameter is not numeric. Must be a path, list of paths or name of a gear datum
|
||||
@@ -266,6 +273,9 @@
|
||||
else
|
||||
I = new path(H) //As fallback treat it as a path
|
||||
|
||||
if(I && callback)
|
||||
callback.Invoke(I)
|
||||
|
||||
if(collect_not_del || override_collect)
|
||||
H.equip_or_collect(I, slot)
|
||||
else
|
||||
|
||||
@@ -446,7 +446,7 @@ datum/preferences
|
||||
|
||||
character.pda_choice = pda_choice
|
||||
|
||||
if(headset_choice > OUTFIT_WRISTRAD || headset_choice < OUTFIT_NOTHING)
|
||||
if(headset_choice > OUTFIT_THIN_WRISTRAD || headset_choice < OUTFIT_NOTHING)
|
||||
headset_choice = OUTFIT_HEADSET
|
||||
|
||||
character.headset_choice = headset_choice
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
author: Geeves
|
||||
|
||||
delete-after: True
|
||||
|
||||
changes:
|
||||
- rscadd: "Added a thin variant of the wristbound radio, it's selectable in the character creation menu as a Sleek Wristbound Radio."
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 7.4 KiB After Width: | Height: | Size: 9.0 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 37 KiB After Width: | Height: | Size: 37 KiB |
Reference in New Issue
Block a user