Changes slot number defines from lowercase to all uppercase (#22297)

* undo all of it

* flags

* back

* head/mask

* left

* right

* Cuffs

* other name changes

* ID and PDA

* idk about calling them SLOT_HUD now

* glasses, gloves, and shoes, oh my!

* the rest

* comment
This commit is contained in:
Contrabang
2023-10-03 18:27:51 +01:00
committed by GitHub
parent a6a34c2592
commit f3f9bd442a
219 changed files with 1114 additions and 1113 deletions
+2 -2
View File
@@ -65,7 +65,7 @@
inv_box.icon = 'icons/mob/screen_alien.dmi'
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
inv_box.slot_id = SLOT_HUD_RIGHT_HAND
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
@@ -73,7 +73,7 @@
inv_box.icon = 'icons/mob/screen_alien.dmi'
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
inv_box.slot_id = SLOT_HUD_LEFT_HAND
static_inventory += inv_box
using = new /obj/screen/swap_hand()
+5 -5
View File
@@ -32,7 +32,7 @@
var/list/toggleable_inventory = list() //the screen objects which can be hidden
var/list/hotkeybuttons = list() //the buttons that can be used via hotkeys
var/list/infodisplay = list() //the screen objects that display mob info (health, alien plasma, etc...)
var/list/inv_slots[slots_amt] // /obj/screen/inventory objects, ordered by their slot ID.
var/list/inv_slots[SLOT_HUD_AMOUNT] // /obj/screen/inventory objects, ordered by their slot ID.
var/obj/screen/movable/action_button/hide_toggle/hide_actions_toggle
var/action_buttons_hidden = FALSE
@@ -151,10 +151,10 @@
mymob.client.screen += infodisplay
//These ones are a part of 'static_inventory', 'toggleable_inventory' or 'hotkeybuttons' but we want them to stay
if(inv_slots[slot_l_hand])
mymob.client.screen += inv_slots[slot_l_hand] //we want the hands to be visible
if(inv_slots[slot_r_hand])
mymob.client.screen += inv_slots[slot_r_hand] //we want the hands to be visible
if(inv_slots[SLOT_HUD_LEFT_HAND])
mymob.client.screen += inv_slots[SLOT_HUD_LEFT_HAND] //we want the hands to be visible
if(inv_slots[SLOT_HUD_RIGHT_HAND])
mymob.client.screen += inv_slots[SLOT_HUD_RIGHT_HAND] //we want the hands to be visible
if(action_intent)
mymob.client.screen += action_intent //we want the intent switcher visible
action_intent.screen_loc = ui_acti_alt //move this to the alternative position, where zone_select usually is.
+18 -18
View File
@@ -102,7 +102,7 @@
inv_box = new /obj/screen/inventory()
inv_box.name = "i_clothing"
inv_box.icon = ui_style
inv_box.slot_id = slot_w_uniform
inv_box.slot_id = SLOT_HUD_JUMPSUIT
inv_box.icon_state = "uniform"
inv_box.screen_loc = ui_iclothing
inv_box.color = ui_color
@@ -112,7 +112,7 @@
inv_box = new /obj/screen/inventory()
inv_box.name = "o_clothing"
inv_box.icon = ui_style
inv_box.slot_id = slot_wear_suit
inv_box.slot_id = SLOT_HUD_OUTER_SUIT
inv_box.icon_state = "suit"
inv_box.screen_loc = ui_oclothing
inv_box.color = ui_color
@@ -126,7 +126,7 @@
inv_box.color = ui_color
inv_box.alpha = ui_alpha
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
inv_box.slot_id = SLOT_HUD_RIGHT_HAND
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
@@ -136,7 +136,7 @@
inv_box.color = ui_color
inv_box.alpha = ui_alpha
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
inv_box.slot_id = SLOT_HUD_LEFT_HAND
static_inventory += inv_box
using = new /obj/screen/swap_hand()
@@ -162,7 +162,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "id"
inv_box.screen_loc = ui_id
inv_box.slot_id = slot_wear_id
inv_box.slot_id = SLOT_HUD_WEAR_ID
inv_box.color = ui_color
inv_box.alpha = ui_alpha
static_inventory += inv_box
@@ -172,7 +172,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "pda"
inv_box.screen_loc = ui_pda
inv_box.slot_id = slot_wear_pda
inv_box.slot_id = SLOT_HUD_WEAR_PDA
inv_box.color = ui_color
inv_box.alpha = ui_alpha
static_inventory += inv_box
@@ -182,7 +182,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "mask"
inv_box.screen_loc = ui_mask
inv_box.slot_id = slot_wear_mask
inv_box.slot_id = SLOT_HUD_WEAR_MASK
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -192,7 +192,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "back"
inv_box.screen_loc = ui_back
inv_box.slot_id = slot_back
inv_box.slot_id = SLOT_HUD_BACK
inv_box.color = ui_color
inv_box.alpha = ui_alpha
static_inventory += inv_box
@@ -202,7 +202,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "pocket"
inv_box.screen_loc = ui_storage1
inv_box.slot_id = slot_l_store
inv_box.slot_id = SLOT_HUD_LEFT_STORE
inv_box.color = ui_color
inv_box.alpha = ui_alpha
static_inventory += inv_box
@@ -212,7 +212,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "pocket"
inv_box.screen_loc = ui_storage2
inv_box.slot_id = slot_r_store
inv_box.slot_id = SLOT_HUD_RIGHT_STORE
inv_box.color = ui_color
inv_box.alpha = ui_alpha
static_inventory += inv_box
@@ -224,7 +224,7 @@
inv_box.color = ui_color
inv_box.alpha = ui_alpha
inv_box.screen_loc = ui_sstore1
inv_box.slot_id = slot_s_store
inv_box.slot_id = SLOT_HUD_SUIT_STORE
static_inventory += inv_box
using = new /obj/screen/resist()
@@ -253,7 +253,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "gloves"
inv_box.screen_loc = ui_gloves
inv_box.slot_id = slot_gloves
inv_box.slot_id = SLOT_HUD_GLOVES
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -263,7 +263,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "glasses"
inv_box.screen_loc = ui_glasses
inv_box.slot_id = slot_glasses
inv_box.slot_id = SLOT_HUD_GLASSES
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -273,7 +273,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "ears"
inv_box.screen_loc = ui_l_ear
inv_box.slot_id = slot_l_ear
inv_box.slot_id = SLOT_HUD_LEFT_EAR
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -283,7 +283,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "ears"
inv_box.screen_loc = ui_r_ear
inv_box.slot_id = slot_r_ear
inv_box.slot_id = SLOT_HUD_RIGHT_EAR
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -293,7 +293,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "head"
inv_box.screen_loc = ui_head
inv_box.slot_id = slot_head
inv_box.slot_id = SLOT_HUD_HEAD
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -303,7 +303,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "shoes"
inv_box.screen_loc = ui_shoes
inv_box.slot_id = slot_shoes
inv_box.slot_id = SLOT_HUD_SHOES
inv_box.color = ui_color
inv_box.alpha = ui_alpha
toggleable_inventory += inv_box
@@ -313,7 +313,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "belt"
inv_box.screen_loc = ui_belt
inv_box.slot_id = slot_belt
inv_box.slot_id = SLOT_HUD_BELT
inv_box.color = ui_color
inv_box.alpha = ui_alpha
static_inventory += inv_box
+4 -4
View File
@@ -443,7 +443,7 @@
if(!active_overlay)
active_overlay = image("icon"=icon, "icon_state"="hand_active")
if(!handcuff_overlay)
var/state = (slot_id == slot_r_hand) ? "markus" : "gabrielle"
var/state = (slot_id == SLOT_HUD_RIGHT_HAND) ? "markus" : "gabrielle"
handcuff_overlay = image("icon"='icons/mob/screen_gen.dmi', "icon_state"=state)
if(hud && hud.mymob)
@@ -452,13 +452,13 @@
if(C.handcuffed)
. += handcuff_overlay
var/obj/item/organ/external/hand = C.get_organ("[slot_id == slot_l_hand ? "l" : "r"]_hand")
var/obj/item/organ/external/hand = C.get_organ("[slot_id == SLOT_HUD_LEFT_HAND ? "l" : "r"]_hand")
if(!isalien(C) && (!hand || !hand.is_usable()))
. += blocked_overlay
if(slot_id == slot_l_hand && hud.mymob.hand)
if(slot_id == SLOT_HUD_LEFT_HAND && hud.mymob.hand)
. += active_overlay
else if(slot_id == slot_r_hand && !hud.mymob.hand)
else if(slot_id == SLOT_HUD_RIGHT_HAND && !hud.mymob.hand)
. += active_overlay
/obj/screen/inventory/hand/Click()
+1 -1
View File
@@ -89,7 +89,7 @@
//stops TK grabs being equipped anywhere but into hands
/obj/item/tk_grab/equipped(mob/user, slot)
if( (slot == slot_l_hand) || (slot== slot_r_hand) )
if( (slot == SLOT_HUD_LEFT_HAND) || (slot== SLOT_HUD_RIGHT_HAND) )
return
qdel(src)