Upload files

This commit is contained in:
SandPoot
2022-02-25 16:58:09 -03:00
parent 87d30e1a4f
commit 5029af901b
206 changed files with 782 additions and 818 deletions

View File

@@ -158,7 +158,7 @@
#define ORGAN_SLOT_STOMACH "stomach"
#define ORGAN_SLOT_STOMACH_AID "stomach_aid"
#define ORGAN_SLOT_BREATHING_TUBE "breathing_tube"
#define ORGAN_SLOT_EARS "ears"
#define ORGAN_ITEM_SLOT_EARS "ears"
#define ORGAN_SLOT_EYES "eye_sight"
#define ORGAN_SLOT_LUNGS "lungs"
#define ORGAN_SLOT_HEART "heart"

View File

@@ -6,87 +6,52 @@
#define STORAGE_VIEW_DEPTH 2
//ITEM INVENTORY SLOT BITMASKS
#define ITEM_SLOT_OCLOTHING (1<<0)
#define ITEM_SLOT_ICLOTHING (1<<1)
#define ITEM_SLOT_GLOVES (1<<2)
#define ITEM_SLOT_EYES (1<<3)
#define ITEM_SLOT_EARS (1<<4)
#define ITEM_SLOT_MASK (1<<5)
#define ITEM_SLOT_HEAD (1<<6)
#define ITEM_SLOT_FEET (1<<7)
#define ITEM_SLOT_ID (1<<8)
#define ITEM_SLOT_BELT (1<<9)
#define ITEM_SLOT_BACK (1<<10)
#define ITEM_SLOT_POCKET (1<<11) // this is to allow items with a w_class of WEIGHT_CLASS_NORMAL or WEIGHT_CLASS_BULKY to fit in pockets.
#define ITEM_SLOT_DENYPOCKET (1<<12) // this is to deny items with a w_class of WEIGHT_CLASS_SMALL or WEIGHT_CLASS_TINY to fit in pockets.
#define ITEM_SLOT_NECK (1<<13)
#define ITEM_SLOT_HANDS (1<<14)
#define ITEM_SLOT_BACKPACK (1<<15)
#define ITEM_SLOT_SUITSTORE (1<<16)
/// Suit slot (armors, costumes, space suits, etc.)
#define ITEM_SLOT_OCLOTHING (1<<0)
/// Jumpsuit slot
#define ITEM_SLOT_ICLOTHING (1<<1)
/// Glove slot
#define ITEM_SLOT_GLOVES (1<<2)
/// Glasses slot
#define ITEM_SLOT_EYES (1<<3)
/// Ear slot (radios, earmuffs)
#define ITEM_SLOT_EARS (1<<4)
/// Mask slot
#define ITEM_SLOT_MASK (1<<5)
/// Head slot (helmets, hats, etc.)
#define ITEM_SLOT_HEAD (1<<6)
/// Shoe slot
#define ITEM_SLOT_FEET (1<<7)
/// ID slot
#define ITEM_SLOT_ID (1<<8)
/// Belt slot
#define ITEM_SLOT_BELT (1<<9)
/// Back slot
#define ITEM_SLOT_BACK (1<<10)
/// Dextrous simplemob "hands" (used for Drones and Dextrous Guardians)
#define ITEM_SLOT_DEX_STORAGE (1<<11)
/// Neck slot (ties, bedsheets, scarves)
#define ITEM_SLOT_NECK (1<<12)
/// A character's hand slots
#define ITEM_SLOT_HANDS (1<<13)
/// Inside of a character's backpack
#define ITEM_SLOT_BACKPACK (1<<14)
/// Suit Storage slot
#define ITEM_SLOT_SUITSTORE (1<<15)
/// Left Pocket slot
#define ITEM_SLOT_LPOCKET (1<<16)
/// Right Pocket slot
#define ITEM_SLOT_RPOCKET (1<<17)
/// Handcuff slot
#define ITEM_SLOT_HANDCUFFED (1<<18)
/// Legcuff slot (bolas, beartraps)
#define ITEM_SLOT_LEGCUFFED (1<<19)
//SLOTS
#define SLOT_BACK 1
#define SLOT_WEAR_MASK 2
#define SLOT_HANDCUFFED 3
#define SLOT_HANDS 4 //wherever you provide a slot for hands you provide SLOT_HANDS
//SLOT_HANDS as a slot will pick ANY available hand
#define SLOT_BELT 5
#define SLOT_WEAR_ID 6
#define SLOT_EARS 7
#define SLOT_GLASSES 8
#define SLOT_GLOVES 9
#define SLOT_NECK 10
#define SLOT_HEAD 11
#define SLOT_SHOES 12
#define SLOT_WEAR_SUIT 13
#define SLOT_W_UNIFORM 14
#define SLOT_L_STORE 15
#define SLOT_R_STORE 16
#define SLOT_S_STORE 17
#define SLOT_IN_BACKPACK 18
#define SLOT_LEGCUFFED 19
#define SLOT_GENERC_DEXTROUS_STORAGE 20
#define SLOTS_AMT 20 // Keep this up to date!
//I hate that this has to exist
/proc/slotdefine2slotbit(slotdefine) //Keep this up to date with the value of SLOT BITMASKS and SLOTS (the two define sections above)
. = 0
switch(slotdefine)
if(SLOT_BACK)
. = ITEM_SLOT_BACK
if(SLOT_WEAR_MASK)
. = ITEM_SLOT_MASK
if(SLOT_NECK)
. = ITEM_SLOT_NECK
if(SLOT_BELT)
. = ITEM_SLOT_BELT
if(SLOT_WEAR_ID)
. = ITEM_SLOT_ID
if(SLOT_EARS)
. = ITEM_SLOT_EARS
if(SLOT_GLASSES)
. = ITEM_SLOT_EYES
if(SLOT_GLOVES)
. = ITEM_SLOT_GLOVES
if(SLOT_HEAD)
. = ITEM_SLOT_HEAD
if(SLOT_SHOES)
. = ITEM_SLOT_FEET
if(SLOT_WEAR_SUIT)
. = ITEM_SLOT_OCLOTHING
if(SLOT_W_UNIFORM)
. = ITEM_SLOT_ICLOTHING
if(SLOT_L_STORE, SLOT_R_STORE)
. = ITEM_SLOT_POCKET
if(SLOT_HANDS)
. = ITEM_SLOT_HANDS
if(SLOT_IN_BACKPACK)
. = ITEM_SLOT_BACKPACK
if(SLOT_S_STORE)
. = ITEM_SLOT_SUITSTORE
/// Total amount of slots
#define SLOTS_AMT 20 // Keep this up to date!
//SLOT GROUP HELPERS
#define ITEM_SLOT_POCKETS (ITEM_SLOT_LPOCKET|ITEM_SLOT_RPOCKET)
//Bit flags for the flags_inv variable, which determine when a piece of clothing hides another. IE a helmet hiding glasses.
#define HIDEGLOVES (1<<0)
@@ -245,4 +210,4 @@ GLOBAL_LIST_INIT(security_wintercoat_allowed, typecacheof(list(
#define GET_INTERNAL_SLOTS(C) list(C.head, C.wear_mask)
//Slots that won't trigger humans' update_genitals() on equip().
GLOBAL_LIST_INIT(no_genitals_update_slots, list(SLOT_L_STORE, SLOT_R_STORE, SLOT_S_STORE, SLOT_IN_BACKPACK, SLOT_LEGCUFFED, SLOT_HANDCUFFED, SLOT_HANDS, SLOT_GENERC_DEXTROUS_STORAGE))
GLOBAL_LIST_INIT(no_genitals_update_slots, list(ITEM_SLOT_LPOCKET, ITEM_SLOT_RPOCKET, ITEM_SLOT_SUITSTORE, ITEM_SLOT_BACKPACK, ITEM_SLOT_LEGCUFFED, ITEM_SLOT_HANDCUFFED, ITEM_SLOT_HANDS, ITEM_SLOT_DEX_STORAGE))

View File

@@ -105,6 +105,9 @@
#define TORADIANS(degrees) ((degrees) * 0.0174532925)
/// Gets shift x that would be required the bitflag (1<<x)
#define TOBITSHIFT(bit) ( log(2, bit) )
// Will filter out extra rotations and negative rotations
// E.g: 540 becomes 180. -180 becomes 180.
#define SIMPLIFY_DEGREES(degrees) (MODULUS((degrees), 360))

View File

@@ -18,7 +18,7 @@
if(length(inhand_equipment))
for(var/path in inhand_equipment)
var/obj/item/I = new path
mannequin.equip_to_slot_if_possible(I, SLOT_HANDS, TRUE, TRUE, TRUE, TRUE)
mannequin.equip_to_slot_if_possible(I, ITEM_SLOT_HANDS, TRUE, TRUE, TRUE, TRUE)
var/icon/combined = new

View File

@@ -203,62 +203,62 @@
/mob/living/carbon/human/p_they(capitalized, temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_their(capitalized, temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_them(capitalized, temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_have(temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_are(temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_were(temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_do(temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_s(temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()
/mob/living/carbon/human/p_es(temp_gender)
var/list/obscured = check_obscured_slots()
var/skipface = (wear_mask && (wear_mask.flags_inv & HIDEFACE)) || (head && (head.flags_inv & HIDEFACE))
if((SLOT_W_UNIFORM in obscured) && skipface)
if((ITEM_SLOT_ICLOTHING in obscured) && skipface)
temp_gender = PLURAL
return ..()

View File

@@ -412,25 +412,25 @@
/proc/slot2body_zone(slot)
switch(slot)
if(SLOT_BACK, SLOT_WEAR_SUIT, SLOT_W_UNIFORM, SLOT_BELT, SLOT_WEAR_ID)
if(ITEM_SLOT_BACK, ITEM_SLOT_OCLOTHING, ITEM_SLOT_ICLOTHING, ITEM_SLOT_BELT, ITEM_SLOT_ID)
return BODY_ZONE_CHEST
if(SLOT_GLOVES, SLOT_HANDS, SLOT_HANDCUFFED)
if(ITEM_SLOT_GLOVES, ITEM_SLOT_HANDS, ITEM_SLOT_HANDCUFFED)
return pick(BODY_ZONE_PRECISE_L_HAND, BODY_ZONE_PRECISE_R_HAND)
if(SLOT_HEAD, SLOT_NECK, SLOT_NECK, SLOT_EARS)
if(ITEM_SLOT_HEAD, ITEM_SLOT_NECK, ITEM_SLOT_NECK, ITEM_SLOT_EARS)
return BODY_ZONE_HEAD
if(SLOT_WEAR_MASK)
if(ITEM_SLOT_MASK)
return BODY_ZONE_PRECISE_MOUTH
if(SLOT_GLASSES)
if(ITEM_SLOT_EYES)
return BODY_ZONE_PRECISE_EYES
if(SLOT_SHOES)
if(ITEM_SLOT_FEET)
return pick(BODY_ZONE_PRECISE_R_FOOT, BODY_ZONE_PRECISE_L_FOOT)
if(SLOT_LEGCUFFED)
if(ITEM_SLOT_LEGCUFFED)
return pick(BODY_ZONE_L_LEG, BODY_ZONE_R_LEG)
//adapted from http://www.tannerhelland.com/4435/convert-temperature-rgb-algorithm-code/
@@ -652,31 +652,31 @@
/proc/slot_to_string(slot)
switch(slot)
if(SLOT_BACK)
if(ITEM_SLOT_BACK)
return "Backpack"
if(SLOT_WEAR_MASK)
if(ITEM_SLOT_MASK)
return "Mask"
if(SLOT_HANDS)
if(ITEM_SLOT_HANDS)
return "Hands"
if(SLOT_BELT)
if(ITEM_SLOT_BELT)
return "Belt"
if(SLOT_EARS)
if(ITEM_SLOT_EARS)
return "Ears"
if(SLOT_GLASSES)
if(ITEM_SLOT_EYES)
return "Glasses"
if(SLOT_GLOVES)
if(ITEM_SLOT_GLOVES)
return "Gloves"
if(SLOT_NECK)
if(ITEM_SLOT_NECK)
return "Neck"
if(SLOT_HEAD)
if(ITEM_SLOT_HEAD)
return "Head"
if(SLOT_SHOES)
if(ITEM_SLOT_FEET)
return "Shoes"
if(SLOT_WEAR_SUIT)
if(ITEM_SLOT_OCLOTHING)
return "Suit"
if(SLOT_W_UNIFORM)
if(ITEM_SLOT_ICLOTHING)
return "Uniform"
if(SLOT_IN_BACKPACK)
if(ITEM_SLOT_BACKPACK)
return "In backpack"
/proc/tg_ui_icon_to_cit_ui(ui_style)

View File

@@ -1600,7 +1600,7 @@ GLOBAL_DATUM_INIT(dview_mob, /mob/dview, new)
if(!iscarbon(target))
return TRUE
if(check_neck)
if(istype(target.get_item_by_slot(SLOT_NECK), /obj/item/clothing/neck/garlic_necklace))
if(istype(target.get_item_by_slot(ITEM_SLOT_NECK), /obj/item/clothing/neck/garlic_necklace))
return FALSE
if(check_blood)
if(target.reagents.has_reagent(/datum/reagent/consumable/garlic))

View File

@@ -117,7 +117,7 @@
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
inv_slots[inv.slot_id] = inv
inv_slots[TOBITSHIFT(inv.slot_id) + 1] = inv
inv.update_icon()
/datum/hud/alien/persistent_inventory_update()

View File

@@ -8,7 +8,7 @@
inv_box.icon_state = "suit_storage"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_drone_storage
inv_box.slot_id = SLOT_GENERC_DEXTROUS_STORAGE
inv_box.slot_id = ITEM_SLOT_DEX_STORAGE
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -17,13 +17,13 @@
inv_box.icon_state = "mask"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_drone_head
inv_box.slot_id = SLOT_HEAD
inv_box.slot_id = ITEM_SLOT_HEAD
static_inventory += inv_box
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
inv_slots[inv.slot_id] = inv
inv_slots[TOBITSHIFT(inv.slot_id) + 1] = inv
inv.update_icon()

View File

@@ -60,7 +60,7 @@
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
inv_slots[inv.slot_id] = inv
inv_slots[TOBITSHIFT(inv.slot_id) + 1] = inv
inv.update_icon()
/datum/hud/dextrous/persistent_inventory_update()

View File

@@ -43,7 +43,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "suit_storage"
inv_box.screen_loc = ui_id
inv_box.slot_id = SLOT_GENERC_DEXTROUS_STORAGE
inv_box.slot_id = ITEM_SLOT_DEX_STORAGE
static_inventory += inv_box
using = new /atom/movable/screen/guardian/Communicate()

View File

@@ -233,7 +233,7 @@
inv_box = new /atom/movable/screen/inventory()
inv_box.name = "i_clothing"
inv_box.icon = ui_style
inv_box.slot_id = SLOT_W_UNIFORM
inv_box.slot_id = ITEM_SLOT_ICLOTHING
inv_box.icon_state = "uniform"
inv_box.screen_loc = ui_iclothing
toggleable_inventory += inv_box
@@ -241,7 +241,7 @@
inv_box = new /atom/movable/screen/inventory()
inv_box.name = "o_clothing"
inv_box.icon = ui_style
inv_box.slot_id = SLOT_WEAR_SUIT
inv_box.slot_id = ITEM_SLOT_OCLOTHING
inv_box.icon_state = "suit"
inv_box.screen_loc = ui_oclothing
toggleable_inventory += inv_box
@@ -267,7 +267,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 = ITEM_SLOT_ID
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -275,7 +275,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 = ITEM_SLOT_MASK
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -283,7 +283,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "neck"
inv_box.screen_loc = ui_neck
inv_box.slot_id = SLOT_NECK
inv_box.slot_id = ITEM_SLOT_NECK
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -291,7 +291,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 = ITEM_SLOT_BACK
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -299,7 +299,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 = ITEM_SLOT_LPOCKET
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -307,7 +307,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 = ITEM_SLOT_RPOCKET
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -315,7 +315,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "suit_storage"
inv_box.screen_loc = ui_sstore1
inv_box.slot_id = SLOT_S_STORE
inv_box.slot_id = ITEM_SLOT_SUITSTORE
static_inventory += inv_box
using = new /atom/movable/screen/resist()
@@ -348,7 +348,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 = ITEM_SLOT_GLOVES
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -356,7 +356,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 = ITEM_SLOT_EYES
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -364,7 +364,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "ears"
inv_box.screen_loc = ui_ears
inv_box.slot_id = SLOT_EARS
inv_box.slot_id = ITEM_SLOT_EARS
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -372,7 +372,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 = ITEM_SLOT_HEAD
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -380,7 +380,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 = ITEM_SLOT_FEET
toggleable_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -389,7 +389,7 @@
inv_box.icon_state = "belt"
// inv_box.icon_full = "template_small"
inv_box.screen_loc = ui_belt
inv_box.slot_id = SLOT_BELT
inv_box.slot_id = ITEM_SLOT_BELT
static_inventory += inv_box
throw_icon = new /atom/movable/screen/throw_catch()
@@ -464,7 +464,7 @@
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
inv_slots[inv.slot_id] = inv
inv_slots[TOBITSHIFT(inv.slot_id) + 1] = inv
inv.update_icon()
update_locked_slots()

View File

@@ -50,7 +50,7 @@
inv_box.icon_state = "mask"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_monkey_mask
inv_box.slot_id = SLOT_WEAR_MASK
inv_box.slot_id = ITEM_SLOT_MASK
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -59,7 +59,7 @@
inv_box.icon_state = "neck"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_monkey_neck
inv_box.slot_id = SLOT_NECK
inv_box.slot_id = ITEM_SLOT_NECK
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -68,7 +68,7 @@
inv_box.icon_state = "head"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_monkey_head
inv_box.slot_id = SLOT_HEAD
inv_box.slot_id = ITEM_SLOT_HEAD
static_inventory += inv_box
inv_box = new /atom/movable/screen/inventory()
@@ -76,7 +76,7 @@
inv_box.icon = ui_style
inv_box.icon_state = "back"
inv_box.screen_loc = ui_monkey_back
inv_box.slot_id = SLOT_BACK
inv_box.slot_id = ITEM_SLOT_BACK
static_inventory += inv_box
throw_icon = new /atom/movable/screen/throw_catch()
@@ -126,7 +126,7 @@
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
inv_slots[inv.slot_id] = inv
inv_slots[TOBITSHIFT(inv.slot_id) + 1] = inv
inv.update_icon()
/datum/hud/monkey/persistent_inventory_update()

View File

@@ -101,7 +101,7 @@
//stops TK grabs being equipped anywhere but into hands
/obj/item/tk_grab/equipped(mob/user, slot)
if(slot == SLOT_HANDS)
if(slot == ITEM_SLOT_HANDS)
return ..()
qdel(src)

View File

@@ -500,7 +500,7 @@ SUBSYSTEM_DEF(job)
tcg_cards = N.client.prefs.tcg_cards
if(tcg_cards)
var/obj/item/tcgcard_binder/binder = new(get_turf(H))
H.equip_to_slot_if_possible(binder, SLOT_IN_BACKPACK, disable_warning = TRUE, bypass_equip_delay_self = TRUE)
H.equip_to_slot_if_possible(binder, ITEM_SLOT_BACKPACK, disable_warning = TRUE, bypass_equip_delay_self = TRUE)
for(var/card_type in N.client.prefs.tcg_cards)
if(card_type)
if(islist(H.client.prefs.tcg_cards[card_type]))
@@ -710,9 +710,9 @@ SUBSYSTEM_DEF(job)
permitted = FALSE
if(G.donoritem && !G.donator_ckey_check(the_mob.client.ckey))
permitted = FALSE
if(!equipbackpackstuff && G.slot == SLOT_IN_BACKPACK)//snowflake check since plopping stuff in the backpack doesnt work for pre-job equip loadout stuffs
if(!equipbackpackstuff && G.slot == ITEM_SLOT_BACKPACK)//snowflake check since plopping stuff in the backpack doesnt work for pre-job equip loadout stuffs
permitted = FALSE
if(equipbackpackstuff && G.slot != SLOT_IN_BACKPACK)//ditto
if(equipbackpackstuff && G.slot != ITEM_SLOT_BACKPACK)//ditto
permitted = FALSE
if(!permitted)
continue
@@ -749,7 +749,7 @@ SUBSYSTEM_DEF(job)
I.forceMove(get_turf(C))
else
qdel(I)
else if(!M.equip_to_slot_if_possible(I, SLOT_IN_BACKPACK, disable_warning = TRUE, bypass_equip_delay_self = TRUE)) // Otherwise, try to put it in the backpack
else if(!M.equip_to_slot_if_possible(I, ITEM_SLOT_BACKPACK, disable_warning = TRUE, bypass_equip_delay_self = TRUE)) // Otherwise, try to put it in the backpack
if(can_drop)
I.forceMove(get_turf(M)) // If everything fails, just put it on the floor under the mob.
else

View File

@@ -516,7 +516,7 @@
H.attack_self(owner)
return
var/obj/item/I = target
if(owner.can_equip(I, SLOT_HANDS))
if(owner.can_equip(I, ITEM_SLOT_HANDS))
owner.temporarilyRemoveItemFromInventory(I)
owner.put_in_hands(I)
I.attack_self(owner)

View File

@@ -29,7 +29,7 @@
expire = _expire
/datum/component/anti_magic/proc/on_equip(datum/source, mob/equipper, slot)
if(!(allowed_slots & slotdefine2slotbit(slot))) //Check that the slot is valid for antimagic
if(!(allowed_slots & slot)) //Check that the slot is valid for antimagic
UnregisterSignal(equipper, COMSIG_MOB_RECEIVE_MAGIC)
return
RegisterSignal(equipper, COMSIG_MOB_RECEIVE_MAGIC, .proc/protect, TRUE)

View File

@@ -317,7 +317,7 @@
host_mob.Paralyze(120)
if(iscarbon(host_mob))
var/mob/living/carbon/C = host_mob
var/obj/item/organ/ears/ears = C.getorganslot(ORGAN_SLOT_EARS)
var/obj/item/organ/ears/ears = C.getorganslot(ORGAN_ITEM_SLOT_EARS)
if(ears)
ears.adjustEarDamage(0, 30) //nanites coming out of your ears
C.vomit(0, FALSE, TRUE, 2, FALSE, VOMIT_NANITE, FALSE, TRUE, 0) //nanites coming out of your mouth

View File

@@ -9,7 +9,7 @@
var/filter_size
var/filter_color
/datum/component/wearertargeting/phantomthief/Initialize(_x = -2, _y = 0, _size = 0, _color = "#E62111", list/_valid_slots = list(SLOT_GLASSES))
/datum/component/wearertargeting/phantomthief/Initialize(_x = -2, _y = 0, _size = 0, _color = "#E62111", list/_valid_slots = list(ITEM_SLOT_EYES))
. = ..()
if(. == COMPONENT_INCOMPATIBLE)
return

View File

@@ -108,7 +108,7 @@
SSvis_overlays.add_vis_overlay(holder, 'icons/effects/effects.dmi', to_add, layer, GAME_PLANE, holder.dir)
/datum/component/shielded/proc/on_equip(obj/item/source, mob/living/equipper, slot)
if(!(accepted_slots & slotdefine2slotbit(slot)))
if(!(accepted_slots & slot))
return
holder = equipper
RegisterSignal(parent, COMSIG_ITEM_RUN_BLOCK, .proc/on_run_block)

View File

@@ -89,7 +89,7 @@
/// Triggered on equip of the item containing the component
/datum/component/two_handed/proc/on_equip(datum/source, mob/user, slot)
if(require_twohands && slot == SLOT_HANDS) // force equip the item
if(require_twohands && slot == ITEM_SLOT_HANDS) // force equip the item
wield(user)
if(!user.is_holding(parent) && wielded && !require_twohands)
unwield(user)

View File

@@ -75,8 +75,8 @@
if(isobj(H.wear_suit))
Cl = H.wear_suit
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(SLOT_W_UNIFORM))
Cl = SLOT_W_UNIFORM
if(passed && isobj(ITEM_SLOT_ICLOTHING))
Cl = ITEM_SLOT_ICLOTHING
passed = prob((Cl.permeability_coefficient*100) - 1)
if(BODY_ZONE_L_ARM, BODY_ZONE_R_ARM)
if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered&HANDS)

View File

@@ -51,7 +51,7 @@ Bonus
to_chat(M, "<span class='warning'>[pick("You hear a ringing in your ear.", "Your ears pop.")]</span>")
if(5)
if(power > 2)
var/obj/item/organ/ears/ears = M.getorganslot(ORGAN_SLOT_EARS)
var/obj/item/organ/ears/ears = M.getorganslot(ORGAN_ITEM_SLOT_EARS)
if(istype(ears) && ears.damage < ears.maxHealth)
to_chat(M, "<span class='userdanger'>Your ears pop painfully and start bleeding!</span>")
ears.damage = max(ears.damage, ears.maxHealth)

View File

@@ -61,19 +61,19 @@ STI KALY - blind
if(!istype(H.head, /obj/item/clothing/head/wizard))
if(!H.dropItemToGround(H.head))
qdel(H.head)
H.equip_to_slot_or_del(new /obj/item/clothing/head/wizard(H), SLOT_HEAD)
H.equip_to_slot_or_del(new /obj/item/clothing/head/wizard(H), ITEM_SLOT_HEAD)
return
if(prob(chance))
if(!istype(H.wear_suit, /obj/item/clothing/suit/wizrobe))
if(!H.dropItemToGround(H.wear_suit))
qdel(H.wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe(H), SLOT_WEAR_SUIT)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe(H), ITEM_SLOT_OCLOTHING)
return
if(prob(chance))
if(!istype(H.shoes, /obj/item/clothing/shoes/sandal/magic))
if(!H.dropItemToGround(H.shoes))
qdel(H.shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/sandal/magic(H), SLOT_SHOES)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/sandal/magic(H), ITEM_SLOT_FEET)
return
else
var/mob/living/carbon/H = affected_mob

View File

@@ -19,7 +19,7 @@
user_by_item -= target
/datum/element/earhealing/proc/equippedChanged(datum/source, mob/living/carbon/user, slot)
if(slot == SLOT_EARS && istype(user))
if(slot == ITEM_SLOT_EARS && istype(user))
user_by_item[source] = user
else
user_by_item -= source
@@ -30,7 +30,7 @@
var/mob/living/carbon/user = user_by_item[i]
if(HAS_TRAIT(user, TRAIT_DEAF))
continue
var/obj/item/organ/ears/ears = user.getorganslot(ORGAN_SLOT_EARS)
var/obj/item/organ/ears/ears = user.getorganslot(ORGAN_ITEM_SLOT_EARS)
if(!ears)
continue
ears.deaf = max(ears.deaf - 0.25, (ears.damage < ears.maxHealth ? 0 : 1)) // Do not clear deafness if our ears are too damaged

View File

@@ -144,7 +144,7 @@
return TRUE
/datum/element/polychromic/proc/grant_user_action(atom/source, mob/user, slot)
if(slot == SLOT_IN_BACKPACK || slot == SLOT_LEGCUFFED || slot == SLOT_HANDCUFFED || slot == SLOT_GENERC_DEXTROUS_STORAGE)
if(slot == ITEM_SLOT_BACKPACK || slot == ITEM_SLOT_LEGCUFFED || slot == ITEM_SLOT_HANDCUFFED || slot == ITEM_SLOT_DEX_STORAGE)
return
var/datum/action/polychromic/P = actions_by_atom[source]
if(!P)

View File

@@ -34,7 +34,7 @@
stacked_spellcasting_by_user -= target
/datum/element/spellcasting/proc/on_equip(datum/source, mob/equipper, slot)
if(!(cast_slots & slotdefine2slotbit(slot)))
if(!(cast_slots & slot))
return
users_by_item[source] = equipper
if(!stacked_spellcasting_by_user[equipper])

View File

@@ -59,7 +59,7 @@
/obj/item/clothing/gloves/boxing/equipped(mob/user, slot)
. = ..()
if(ishuman(user) && slot == SLOT_GLOVES)
if(ishuman(user) && slot == ITEM_SLOT_GLOVES)
var/mob/living/carbon/human/H = user
style.teach(H,TRUE)
@@ -68,5 +68,5 @@
if(!ishuman(user))
return
var/mob/living/carbon/human/H = user
if(H.get_item_by_slot(SLOT_GLOVES) == src)
if(H.get_item_by_slot(ITEM_SLOT_GLOVES) == src)
style.remove(H)

View File

@@ -197,7 +197,7 @@
/obj/item/clothing/gloves/krav_maga/equipped(mob/user, slot)
. = ..()
if(ishuman(user) && slot == SLOT_GLOVES)
if(ishuman(user) && slot == ITEM_SLOT_GLOVES)
var/mob/living/carbon/human/H = user
style.teach(H,1)
@@ -206,7 +206,7 @@
if(!ishuman(user))
return
var/mob/living/carbon/human/H = user
if(H.get_item_by_slot(SLOT_GLOVES) == src)
if(H.get_item_by_slot(ITEM_SLOT_GLOVES) == src)
style.remove(H)
/obj/item/clothing/gloves/krav_maga/sec//more obviously named, given to sec

View File

@@ -485,7 +485,7 @@
/obj/item/storage/belt/champion/wrestling/equipped(mob/user, slot)
. = ..()
if(ishuman(user) && slot == SLOT_BELT)
if(ishuman(user) && slot == ITEM_SLOT_BELT)
var/mob/living/carbon/human/H = user
style.teach(H,1)
@@ -494,7 +494,7 @@
if(!ishuman(user))
return
var/mob/living/carbon/human/H = user
if(H.get_item_by_slot(SLOT_BELT) == src)
if(H.get_item_by_slot(ITEM_SLOT_BELT) == src)
style.remove(H)
//Subtype of wrestling, reserved for the wrestling belts found in the holodeck

View File

@@ -17,18 +17,18 @@
if(!istype(H.wear_mask, /obj/item/clothing/mask/gas/cluwne))
if(!H.dropItemToGround(H.wear_mask))
qdel(H.wear_mask)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/cluwne(H), SLOT_WEAR_MASK)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/cluwne(H), ITEM_SLOT_MASK)
if(!istype(H.w_uniform, /obj/item/clothing/under/cluwne))
if(!H.dropItemToGround(H.w_uniform))
qdel(H.w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/under/cluwne(H), SLOT_W_UNIFORM)
H.equip_to_slot_or_del(new /obj/item/clothing/under/cluwne(H), ITEM_SLOT_ICLOTHING)
if(!istype(H.shoes, /obj/item/clothing/shoes/clown_shoes/cluwne))
if(!H.dropItemToGround(H.shoes))
qdel(H.shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/clown_shoes/cluwne(H), SLOT_SHOES)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/clown_shoes/cluwne(H), ITEM_SLOT_FEET)
owner.equip_to_slot_or_del(new /obj/item/clothing/gloves/color/white(owner), SLOT_GLOVES) // this is purely for cosmetic purposes incase they aren't wearing anything in that slot
owner.equip_to_slot_or_del(new /obj/item/storage/backpack/clown(owner), SLOT_BACK) // ditto
owner.equip_to_slot_or_del(new /obj/item/clothing/gloves/color/white(owner), ITEM_SLOT_GLOVES) // this is purely for cosmetic purposes incase they aren't wearing anything in that slot
owner.equip_to_slot_or_del(new /obj/item/storage/backpack/clown(owner), ITEM_SLOT_BACK) // ditto
/datum/mutation/human/cluwne/on_life(mob/living/carbon/human/owner)
if((prob(15) && owner.IsUnconscious()))

View File

@@ -153,31 +153,31 @@
//Start with uniform,suit,backpack for additional slots
if(uniform)
H.equip_to_slot_or_del(new uniform(H), SLOT_W_UNIFORM, TRUE)
H.equip_to_slot_or_del(new uniform(H), ITEM_SLOT_ICLOTHING, TRUE)
if(suit)
H.equip_to_slot_or_del(new suit(H), SLOT_WEAR_SUIT, TRUE)
H.equip_to_slot_or_del(new suit(H), ITEM_SLOT_OCLOTHING, TRUE)
if(back)
H.equip_to_slot_or_del(new back(H), SLOT_BACK, TRUE)
H.equip_to_slot_or_del(new back(H), ITEM_SLOT_BACK, TRUE)
if(belt)
H.equip_to_slot_or_del(new belt(H), SLOT_BELT, TRUE)
H.equip_to_slot_or_del(new belt(H), ITEM_SLOT_BELT, TRUE)
if(gloves)
H.equip_to_slot_or_del(new gloves(H), SLOT_GLOVES, TRUE)
H.equip_to_slot_or_del(new gloves(H), ITEM_SLOT_GLOVES, TRUE)
if(shoes)
H.equip_to_slot_or_del(new shoes(H), SLOT_SHOES, TRUE)
H.equip_to_slot_or_del(new shoes(H), ITEM_SLOT_FEET, TRUE)
if(head)
H.equip_to_slot_or_del(new head(H), SLOT_HEAD, TRUE)
H.equip_to_slot_or_del(new head(H), ITEM_SLOT_HEAD, TRUE)
if(mask)
H.equip_to_slot_or_del(new mask(H), SLOT_WEAR_MASK, TRUE)
H.equip_to_slot_or_del(new mask(H), ITEM_SLOT_MASK, TRUE)
if(neck)
H.equip_to_slot_or_del(new neck(H), SLOT_NECK, TRUE)
H.equip_to_slot_or_del(new neck(H), ITEM_SLOT_NECK, TRUE)
if(ears)
H.equip_to_slot_or_del(new ears(H), SLOT_EARS, TRUE)
H.equip_to_slot_or_del(new ears(H), ITEM_SLOT_EARS, TRUE)
if(glasses)
H.equip_to_slot_or_del(new glasses(H), SLOT_GLASSES, TRUE)
H.equip_to_slot_or_del(new glasses(H), ITEM_SLOT_EYES, TRUE)
if(id)
H.equip_to_slot_or_del(new id(H), SLOT_WEAR_ID, TRUE)
H.equip_to_slot_or_del(new id(H), ITEM_SLOT_ID, TRUE)
if(suit_store)
H.equip_to_slot_or_del(new suit_store(H), SLOT_S_STORE, TRUE)
H.equip_to_slot_or_del(new suit_store(H), ITEM_SLOT_SUITSTORE, TRUE)
if(undershirt)
H.undershirt = initial(undershirt.name)
@@ -195,9 +195,9 @@
if(!visualsOnly) // Items in pockets or backpack don't show up on mob's icon.
if(l_pocket)
H.equip_to_slot_or_del(new l_pocket(H), SLOT_L_STORE, TRUE)
H.equip_to_slot_or_del(new l_pocket(H), ITEM_SLOT_LPOCKET, TRUE)
if(r_pocket)
H.equip_to_slot_or_del(new r_pocket(H), SLOT_R_STORE, TRUE)
H.equip_to_slot_or_del(new r_pocket(H), ITEM_SLOT_RPOCKET, TRUE)
if(box)
if(!backpack_contents)
@@ -211,7 +211,7 @@
if(!isnum(number))//Default to 1
number = 1
for(var/i in 1 to number)
H.equip_to_slot_or_del(new path(H), SLOT_IN_BACKPACK, TRUE)
H.equip_to_slot_or_del(new path(H), ITEM_SLOT_BACKPACK, TRUE)
if(!H.head && toggle_helmet && istype(H.wear_suit, /obj/item/clothing/suit/space/hardsuit))
var/obj/item/clothing/suit/space/hardsuit/HS = H.wear_suit

View File

@@ -578,7 +578,7 @@
if(60 to 69)
H.adjustOrganLoss(ORGAN_SLOT_EYES,10)
if(70 to 79)
H.adjustOrganLoss(ORGAN_SLOT_EARS,10)
H.adjustOrganLoss(ORGAN_ITEM_SLOT_EARS,10)
if(80 to 89)
H.adjustOrganLoss(ORGAN_SLOT_LUNGS,10)
if(90 to 99)
@@ -610,7 +610,7 @@
if(60 to 69)
H.adjustOrganLoss(ORGAN_SLOT_EYES,5)
if(70 to 79)
H.adjustOrganLoss(ORGAN_SLOT_EARS,5)
H.adjustOrganLoss(ORGAN_ITEM_SLOT_EARS,5)
if(80 to 89)
H.adjustOrganLoss(ORGAN_SLOT_LUNGS,5)
if(90 to 99)

View File

@@ -129,7 +129,7 @@ Use this as a guideline
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/clothing/glasses/regular/glasses = new(get_turf(H))
H.put_in_hands(glasses)
H.equip_to_slot(glasses, SLOT_GLASSES)
H.equip_to_slot(glasses, ITEM_SLOT_EYES)
H.regenerate_icons()
//This whole proc is called automatically

View File

@@ -108,10 +108,10 @@
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/choice_beacon/music/B = new(get_turf(H))
H.put_in_hands(B)
H.equip_to_slot_if_possible(B, SLOT_IN_BACKPACK)
H.equip_to_slot_if_possible(B, ITEM_SLOT_BACKPACK)
var/obj/item/musicaltuner/musicaltuner = new(get_turf(H))
H.put_in_hands(musicaltuner)
H.equip_to_slot_if_possible(musicaltuner, SLOT_IN_BACKPACK)
H.equip_to_slot_if_possible(musicaltuner, ITEM_SLOT_BACKPACK)
H.regenerate_icons()
/datum/quirk/photographer
@@ -127,7 +127,7 @@
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/camera/camera = new(get_turf(H))
H.put_in_hands(camera)
H.equip_to_slot(camera, SLOT_NECK)
H.equip_to_slot(camera, ITEM_SLOT_NECK)
H.regenerate_icons()
/datum/quirk/selfaware
@@ -166,7 +166,7 @@
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/toy/crayon/spraycan/spraycan = new(get_turf(H))
H.put_in_hands(spraycan)
H.equip_to_slot(spraycan, SLOT_IN_BACKPACK)
H.equip_to_slot(spraycan, ITEM_SLOT_BACKPACK)
H.regenerate_icons()
/datum/quirk/voracious
@@ -188,7 +188,7 @@
/datum/quirk/trandening/on_spawn()
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/autosurgeon/gloweyes/gloweyes = new(get_turf(H))
H.equip_to_slot(gloweyes, SLOT_IN_BACKPACK)
H.equip_to_slot(gloweyes, ITEM_SLOT_BACKPACK)
H.regenerate_icons()
/datum/quirk/bloodpressure

View File

@@ -57,9 +57,9 @@ GLOBAL_LIST_EMPTY(family_heirlooms)
heirloom = new heirloom_type(get_turf(quirk_holder))
GLOB.family_heirlooms += heirloom
var/list/slots = list(
"in your left pocket" = SLOT_L_STORE,
"in your right pocket" = SLOT_R_STORE,
"in your backpack" = SLOT_IN_BACKPACK
"in your left pocket" = ITEM_SLOT_LPOCKET,
"in your right pocket" = ITEM_SLOT_RPOCKET,
"in your backpack" = ITEM_SLOT_BACKPACK
)
where = H.equip_in_one_of_slots(heirloom, slots, FALSE) || "at your feet"
@@ -120,7 +120,7 @@ GLOBAL_LIST_EMPTY(family_heirlooms)
/datum/quirk/nearsighted/on_spawn()
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/clothing/glasses/regular/glasses = new(get_turf(H))
if(!H.equip_to_slot_if_possible(glasses, SLOT_GLASSES))
if(!H.equip_to_slot_if_possible(glasses, ITEM_SLOT_EYES))
H.put_in_hands(glasses)
/datum/quirk/nyctophobia
@@ -383,7 +383,7 @@ GLOBAL_LIST_EMPTY(family_heirlooms)
/datum/quirk/blindness/on_spawn()
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/clothing/glasses/sunglasses/blindfold/white/glasses = new(get_turf(H))
if(!H.equip_to_slot_if_possible(glasses, SLOT_GLASSES, bypass_equip_delay_self = TRUE)) //if you can't put it on the user's eyes, put it in their hands, otherwise put it on their eyes eyes
if(!H.equip_to_slot_if_possible(glasses, ITEM_SLOT_EYES, bypass_equip_delay_self = TRUE)) //if you can't put it on the user's eyes, put it in their hands, otherwise put it on their eyes eyes
H.put_in_hands(glasses)
H.regenerate_icons()

View File

@@ -172,7 +172,7 @@
/datum/quirk/colorist/on_spawn()
var/mob/living/carbon/human/H = quirk_holder
var/obj/item/dyespray/spraycan = new(get_turf(quirk_holder))
H.equip_to_slot(spraycan, SLOT_IN_BACKPACK)
H.equip_to_slot(spraycan, ITEM_SLOT_BACKPACK)
H.regenerate_icons()
/datum/quirk/colorist/post_add()

View File

@@ -1,6 +1,6 @@
GLOBAL_LIST_INIT(possible_changeling_IDs, list("Alpha","Beta","Gamma","Delta","Epsilon","Zeta","Eta","Theta","Iota","Kappa","Lambda","Mu","Nu","Xi","Omicron","Pi","Rho","Sigma","Tau","Upsilon","Phi","Chi","Psi","Omega"))
GLOBAL_LIST_INIT(slots, list("head", "wear_mask", "back", "wear_suit", "w_uniform", "shoes", "belt", "gloves", "glasses", "ears", "wear_id", "s_store"))
GLOBAL_LIST_INIT(slot2slot, list("head" = SLOT_HEAD, "wear_mask" = SLOT_WEAR_MASK, "neck" = SLOT_NECK, "back" = SLOT_BACK, "wear_suit" = SLOT_WEAR_SUIT, "w_uniform" = SLOT_W_UNIFORM, "shoes" = SLOT_SHOES, "belt" = SLOT_BELT, "gloves" = SLOT_GLOVES, "glasses" = SLOT_GLASSES, "ears" = SLOT_EARS, "wear_id" = SLOT_WEAR_ID, "s_store" = SLOT_S_STORE))
GLOBAL_LIST_INIT(slot2slot, list("head" = ITEM_SLOT_HEAD, "wear_mask" = ITEM_SLOT_MASK, "neck" = ITEM_SLOT_NECK, "back" = ITEM_SLOT_BACK, "wear_suit" = ITEM_SLOT_OCLOTHING, "w_uniform" = ITEM_SLOT_ICLOTHING, "shoes" = ITEM_SLOT_FEET, "belt" = ITEM_SLOT_BELT, "gloves" = ITEM_SLOT_GLOVES, "glasses" = ITEM_SLOT_EYES, "ears" = ITEM_SLOT_EARS, "wear_id" = ITEM_SLOT_ID, "s_store" = ITEM_SLOT_SUITSTORE))
GLOBAL_LIST_INIT(slot2type, list("head" = /obj/item/clothing/head/changeling, "wear_mask" = /obj/item/clothing/mask/changeling, "back" = /obj/item/changeling, "wear_suit" = /obj/item/clothing/suit/changeling, "w_uniform" = /obj/item/clothing/under/changeling, "shoes" = /obj/item/clothing/shoes/changeling, "belt" = /obj/item/changeling, "gloves" = /obj/item/clothing/gloves/changeling, "glasses" = /obj/item/clothing/glasses/changeling, "ears" = /obj/item/changeling, "wear_id" = /obj/item/changeling, "s_store" = /obj/item/changeling))
GLOBAL_VAR(changeling_team_objective_type) //If this is not null, we hand our this objective to all lings

View File

@@ -205,11 +205,11 @@ Credit where due:
var/mob/living/carbon/human/L = M
var/obj/item/clockwork/slab/S = new
var/slot = "At your feet"
var/list/slots = list("In your left pocket" = SLOT_L_STORE, "In your right pocket" = SLOT_R_STORE, "In your backpack" = SLOT_IN_BACKPACK)
var/list/slots = list("In your left pocket" = ITEM_SLOT_LPOCKET, "In your right pocket" = ITEM_SLOT_RPOCKET, "In your backpack" = ITEM_SLOT_BACKPACK)
if(ishuman(L))
var/mob/living/carbon/human/H = L
var/obj/item/clockwork/replica_fabricator/F = new
if(H.equip_to_slot_or_del(F, SLOT_IN_BACKPACK))
if(H.equip_to_slot_or_del(F, ITEM_SLOT_BACKPACK))
to_chat(H, "<span class='brass'>You have been equipped with a replica fabricator, an advanced tool that can convert objects like doors, tables or even coats into clockwork equivalents.</span>")
slot = H.equip_in_one_of_slots(S, slots)
if(slot == "In your backpack")

View File

@@ -37,17 +37,17 @@
if(!H.w_uniform || H.dropItemToGround(H.w_uniform))
C = new /obj/item/clothing/under/rank/civilian/clown(H)
ADD_TRAIT(C, TRAIT_NODROP, CLOWN_NUKE_TRAIT)
H.equip_to_slot_or_del(C, SLOT_W_UNIFORM)
H.equip_to_slot_or_del(C, ITEM_SLOT_ICLOTHING)
if(!H.shoes || H.dropItemToGround(H.shoes))
C = new /obj/item/clothing/shoes/clown_shoes(H)
ADD_TRAIT(C, TRAIT_NODROP, CLOWN_NUKE_TRAIT)
H.equip_to_slot_or_del(C, SLOT_SHOES)
H.equip_to_slot_or_del(C, ITEM_SLOT_FEET)
if(!H.wear_mask || H.dropItemToGround(H.wear_mask))
C = new /obj/item/clothing/mask/gas/clown_hat(H)
ADD_TRAIT(C, TRAIT_NODROP, CLOWN_NUKE_TRAIT)
H.equip_to_slot_or_del(C, SLOT_WEAR_MASK)
H.equip_to_slot_or_del(C, ITEM_SLOT_MASK)
H.dna.add_mutation(CLOWNMUT)
H.dna.add_mutation(SMILE)

View File

@@ -214,7 +214,7 @@
if(!istype(C.wear_mask, /obj/item/clothing/mask/gas/clown_hat) && !istype(C.wear_mask, /obj/item/clothing/mask/gas/mime))
if(!C.wear_mask || C.dropItemToGround(C.wear_mask))
var/obj/item/clothing/mask/fakemoustache/sticky/the_stash = new /obj/item/clothing/mask/fakemoustache/sticky()
C.equip_to_slot_or_del(the_stash, SLOT_WEAR_MASK, TRUE, TRUE, TRUE, TRUE)
C.equip_to_slot_or_del(the_stash, ITEM_SLOT_MASK, TRUE, TRUE, TRUE, TRUE)
/obj/item/clothing/mask/fakemoustache/sticky
var/unstick_time = 2 MINUTES
@@ -226,7 +226,7 @@
/obj/item/clothing/mask/fakemoustache/sticky/equipped(mob/user, slot)
. = ..()
if(slot == SLOT_WEAR_MASK)
if(slot == ITEM_SLOT_MASK)
ADD_TRAIT(user, TRAIT_NO_INTERNALS, STICKY_MOUSTACHE_TRAIT)
/obj/item/clothing/mask/fakemoustache/sticky/dropped(mob/user)

View File

@@ -154,7 +154,7 @@
if(tc)
var/obj/item/U = new uplink_type(H, H.key, tc)
H.equip_to_slot_or_del(U, SLOT_IN_BACKPACK)
H.equip_to_slot_or_del(U, ITEM_SLOT_BACKPACK)
var/obj/item/implant/weapons_auth/W = new
W.implant(H)
@@ -170,7 +170,7 @@
mask = /obj/item/clothing/mask/gas/syndicate
suit = /obj/item/clothing/suit/space/hardsuit/syndi
r_pocket = /obj/item/tank/internals/emergency_oxygen/engi
internals_slot = SLOT_R_STORE
internals_slot = ITEM_SLOT_RPOCKET
belt = /obj/item/storage/belt/military
r_hand = /obj/item/gun/ballistic/automatic/shotgun/bulldog
backpack_contents = list(/obj/item/storage/box/survival/syndie=1,\
@@ -186,7 +186,7 @@
suit = /obj/item/clothing/suit/space/syndicate/black/red
head = /obj/item/clothing/head/helmet/space/syndicate/black/red
r_pocket = /obj/item/tank/internals/emergency_oxygen/engi
internals_slot = SLOT_R_STORE
internals_slot = ITEM_SLOT_RPOCKET
belt = /obj/item/storage/belt/military
backpack_contents = list(/obj/item/storage/box/survival/syndie=1,\
/obj/item/tank/jetpack/oxygen/harness=1,\

View File

@@ -165,7 +165,7 @@ If not set, defaults to check_completion instead. Set it. It's used by cryo.
if(receiver && receiver.current)
if(ishuman(receiver.current))
var/mob/living/carbon/human/H = receiver.current
var/list/slots = list("backpack" = SLOT_IN_BACKPACK)
var/list/slots = list("backpack" = ITEM_SLOT_BACKPACK)
for(var/eq_path in special_equipment)
var/obj/O = new eq_path
. += O
@@ -1197,7 +1197,7 @@ GLOBAL_LIST_EMPTY(cult_contraband)
I.forceMove(get_turf(owner))
if(ishuman(owner))
var/mob/living/carbon/human/H = owner
H.equip_in_one_of_slots(I, list("backpack" = SLOT_IN_BACKPACK), critical = TRUE)
H.equip_in_one_of_slots(I, list("backpack" = ITEM_SLOT_BACKPACK), critical = TRUE)
hoarded_item = I

View File

@@ -351,7 +351,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
return
if(anchored)
return
if(loc == user && current_equipped_slot && current_equipped_slot != SLOT_HANDS)
if(loc == user && current_equipped_slot && current_equipped_slot != ITEM_SLOT_HANDS)
if(current_equipped_slot in user.check_obscured_slots())
to_chat(user, "<span class='warning'>You are unable to unequip that while wearing other garments over it!</span>")
return FALSE
@@ -416,7 +416,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
return
if(anchored)
return
if(loc == user && current_equipped_slot && current_equipped_slot != SLOT_HANDS)
if(loc == user && current_equipped_slot && current_equipped_slot != ITEM_SLOT_HANDS)
if(current_equipped_slot in user.check_obscured_slots())
to_chat(user, "<span class='warning'>You are unable to unequip that while wearing other garments over it!</span>")
return FALSE
@@ -568,7 +568,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
//sometimes we only want to grant the item's action if it's equipped in a specific slot.
/obj/item/proc/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot == SLOT_IN_BACKPACK || slot == SLOT_LEGCUFFED) //these aren't true slots, so avoid granting actions there
if(slot == ITEM_SLOT_BACKPACK || slot == ITEM_SLOT_LEGCUFFED) //these aren't true slots, so avoid granting actions there
return FALSE
return TRUE
@@ -817,7 +817,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
if(ismob(location))
var/mob/M = location
var/success = FALSE
if(src == M.get_item_by_slot(SLOT_WEAR_MASK))
if(src == M.get_item_by_slot(ITEM_SLOT_MASK))
success = TRUE
if(success)
location = get_turf(M)

View File

@@ -34,7 +34,7 @@
user.put_in_hands(PA)
/obj/item/chrono_eraser/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot == SLOT_BACK)
if(slot == ITEM_SLOT_BACK)
return 1
/obj/item/gun/energy/chrono_gun

View File

@@ -89,7 +89,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
..()
/obj/item/proc/help_light_cig(mob/living/M)
var/mask_item = M.get_item_by_slot(SLOT_WEAR_MASK)
var/mask_item = M.get_item_by_slot(ITEM_SLOT_MASK)
if(istype(mask_item, /obj/item/clothing/mask/cigarette))
return mask_item
@@ -130,7 +130,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
reagents.add_reagent_list(list_reagents)
if(starts_lit)
light()
AddComponent(/datum/component/knockoff,90,list(BODY_ZONE_PRECISE_MOUTH),list(SLOT_WEAR_MASK))//90% to knock off when wearing a mask
AddComponent(/datum/component/knockoff,90,list(BODY_ZONE_PRECISE_MOUTH),list(ITEM_SLOT_MASK))//90% to knock off when wearing a mask
/obj/item/clothing/mask/cigarette/Destroy()
STOP_PROCESSING(SSobj, src)
@@ -819,7 +819,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/clothing/mask/vape/equipped(mob/user, slot)
. = ..()
if(slot == SLOT_WEAR_MASK)
if(slot == ITEM_SLOT_MASK)
if(!screw)
to_chat(user, "<span class='notice'>You start puffing on the vape.</span>")
reagents.reagents_holder_flags &= ~(NO_REACT)
@@ -830,7 +830,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
/obj/item/clothing/mask/vape/dropped(mob/user)
. = ..()
var/mob/living/carbon/C = user
if(C.get_item_by_slot(SLOT_WEAR_MASK) == src)
if(C.get_item_by_slot(ITEM_SLOT_MASK) == src)
reagents.reagents_holder_flags |= NO_REACT
STOP_PROCESSING(SSobj, src)

View File

@@ -80,13 +80,13 @@
/obj/item/defibrillator/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(loc == user)
if(slot_flags == ITEM_SLOT_BACK)
if(user.get_item_by_slot(SLOT_BACK) == src)
if(user.get_item_by_slot(ITEM_SLOT_BACK) == src)
ui_action_click()
else
to_chat(user, "<span class='warning'>Put the defibrillator on your back first!</span>")
else if(slot_flags == ITEM_SLOT_BELT)
if(user.get_item_by_slot(SLOT_BELT) == src)
if(user.get_item_by_slot(ITEM_SLOT_BELT) == src)
ui_action_click()
else
to_chat(user, "<span class='warning'>Strap the defibrillator's belt on first!</span>")
@@ -182,7 +182,7 @@
/obj/item/defibrillator/equipped(mob/user, slot)
..()
if((slot_flags == ITEM_SLOT_BACK && slot != SLOT_BACK) || (slot_flags == ITEM_SLOT_BELT && slot != SLOT_BELT))
if((slot_flags == ITEM_SLOT_BACK && slot != ITEM_SLOT_BACK) || (slot_flags == ITEM_SLOT_BELT && slot != ITEM_SLOT_BELT))
remove_paddles(user)
update_power()

View File

@@ -19,7 +19,7 @@
/obj/item/megaphone/equipped(mob/M, slot)
. = ..()
if (slot == SLOT_HANDS)
if (slot == ITEM_SLOT_HANDS)
RegisterSignal(M, COMSIG_MOB_SAY, .proc/handle_speech)
else
UnregisterSignal(M, COMSIG_MOB_SAY)

View File

@@ -156,7 +156,7 @@
category = list("hacked", "Misc")
/obj/item/electropack/shockcollar/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(loc == user && user.get_item_by_slot(SLOT_NECK))
if(loc == user && user.get_item_by_slot(ITEM_SLOT_NECK))
to_chat(user, "<span class='warning'>The collar is fastened tight! You'll need help taking this off!</span>")
return
return ..()
@@ -167,7 +167,7 @@
if(isliving(loc) && on) //the "on" arg is currently useless
var/mob/living/L = loc
if(!L.get_item_by_slot(SLOT_NECK)) //**properly** stops pocket shockers
if(!L.get_item_by_slot(ITEM_SLOT_NECK)) //**properly** stops pocket shockers
return
if(shock_cooldown == TRUE)
return

View File

@@ -56,7 +56,7 @@ GLOBAL_LIST_INIT(channel_tokens, list(
/obj/item/radio/headset/ComponentInitialize()
. = ..()
if (bowman)
AddComponent(/datum/component/wearertargeting/earprotection, list(SLOT_EARS))
AddComponent(/datum/component/wearertargeting/earprotection, list(ITEM_SLOT_EARS))
/obj/item/radio/headset/Initialize()
. = ..()
@@ -373,4 +373,4 @@ GLOBAL_LIST_INIT(channel_tokens, list(
name = replacetext(name,"headset", "bowman headset")
desc = "[desc] Protects ears from flashbangs."
bowman = TRUE
AddComponent(/datum/component/wearertargeting/earprotection, list(SLOT_EARS))
AddComponent(/datum/component/wearertargeting/earprotection, list(ITEM_SLOT_EARS))

View File

@@ -48,7 +48,7 @@
/obj/item/reverse_bear_trap/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(iscarbon(user))
var/mob/living/carbon/C = user
if(C.get_item_by_slot(SLOT_HEAD) == src)
if(C.get_item_by_slot(ITEM_SLOT_HEAD) == src)
if(HAS_TRAIT_FROM(src, TRAIT_NODROP, REVERSE_BEAR_TRAP_TRAIT) && !struggling)
struggling = TRUE
var/fear_string
@@ -82,26 +82,26 @@
..()
/obj/item/reverse_bear_trap/attack(mob/living/target, mob/living/user)
if(target.get_item_by_slot(SLOT_HEAD))
if(target.get_item_by_slot(ITEM_SLOT_HEAD))
to_chat(user, "<span class='warning'>Remove [target.p_their()] headgear first!</span>")
return
target.visible_message("<span class='warning'>[user] starts forcing [src] onto [target]'s head!</span>", \
"<span class='userdanger'>[target] starts forcing [src] onto your head!</span>", "<i>You hear clanking.</i>")
to_chat(user, "<span class='danger'>You start forcing [src] onto [target]'s head...</span>")
if(!do_after(user, 30, target = target) || target.get_item_by_slot(SLOT_HEAD))
if(!do_after(user, 30, target = target) || target.get_item_by_slot(ITEM_SLOT_HEAD))
return
target.visible_message("<span class='warning'>[user] forces and locks [src] onto [target]'s head!</span>", \
"<span class='userdanger'>[target] locks [src] onto your head!</span>", "<i>You hear a click, and then a timer ticking down.</i>")
to_chat(user, "<span class='danger'>You force [src] onto [target]'s head and click the padlock shut.</span>")
user.dropItemToGround(src)
target.equip_to_slot_if_possible(src, SLOT_HEAD)
target.equip_to_slot_if_possible(src, ITEM_SLOT_HEAD)
arm()
notify_ghosts("[user] put a reverse bear trap on [target]!", source = src, action = NOTIFY_ORBIT, ghost_sound = 'sound/machines/beep.ogg')
/obj/item/reverse_bear_trap/proc/snap()
reset()
var/mob/living/carbon/human/H = loc
if(!istype(H) || H.get_item_by_slot(SLOT_HEAD) != src)
if(!istype(H) || H.get_item_by_slot(ITEM_SLOT_HEAD) != src)
visible_message("<span class='warning'>[src]'s jaws snap open with an ear-piercing crack!</span>")
playsound(src, 'sound/effects/snap.ogg', 75, TRUE)
else

View File

@@ -333,7 +333,7 @@ GENETICS SCANNER
var/has_stomach = C.dna && !(NOSTOMACH in C.dna.species.species_traits)
if(!M.getorganslot(ORGAN_SLOT_EYES))
msg += "\t<span class='alert'><b>Subject does not have eyes.</b></span>\n"
if(!M.getorganslot(ORGAN_SLOT_EARS))
if(!M.getorganslot(ORGAN_ITEM_SLOT_EARS))
msg += "\t<span class='alert'><b>Subject does not have ears.</b></span>\n"
if(!M.getorganslot(ORGAN_SLOT_BRAIN))
msg += "\t<span class='alert'><b>Subject's brain function is non-existent!</b></span>\n"

View File

@@ -208,7 +208,7 @@ effective or pretty fucking useless.
actions_types = list(/datum/action/item_action/toggle)
/obj/item/shadowcloak/ui_action_click(mob/user)
if(user.get_item_by_slot(SLOT_BELT) == src)
if(user.get_item_by_slot(ITEM_SLOT_BELT) == src)
if(!on)
Activate(usr)
else
@@ -216,7 +216,7 @@ effective or pretty fucking useless.
return
/obj/item/shadowcloak/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot == SLOT_BELT)
if(slot == ITEM_SLOT_BELT)
return 1
/obj/item/shadowcloak/proc/Activate(mob/living/carbon/human/user)
@@ -238,11 +238,11 @@ effective or pretty fucking useless.
/obj/item/shadowcloak/dropped(mob/user)
..()
if(user && user.get_item_by_slot(SLOT_BELT) != src)
if(user && user.get_item_by_slot(ITEM_SLOT_BELT) != src)
Deactivate()
/obj/item/shadowcloak/process()
if(user.get_item_by_slot(SLOT_BELT) != src)
if(user.get_item_by_slot(ITEM_SLOT_BELT) != src)
Deactivate()
return
var/turf/T = get_turf(src)

View File

@@ -336,7 +336,7 @@
var/obj/item/clothing/magichead = new /obj/item/clothing/mask/horsehead/cursed(user.drop_location())
if(!user.dropItemToGround(user.wear_mask))
qdel(user.wear_mask)
user.equip_to_slot_if_possible(magichead, SLOT_WEAR_MASK, TRUE, TRUE)
user.equip_to_slot_if_possible(magichead, ITEM_SLOT_MASK, TRUE, TRUE)
qdel(src)
else
to_chat(user,"<span class='notice'>I say thee neigh</span>") //It still lives here

View File

@@ -188,7 +188,7 @@
icon_state = "inducer-combat"
item_state = "inducer-combat"
w_class = WEIGHT_CLASS_BULKY
slot_flags = SLOT_BELT
slot_flags = ITEM_SLOT_BELT
desc = "A tool for inductively charging internal power cells. This one has been modified and upgraded to be able to charge into guns as well as normal electronics."
cell_type = /obj/item/stock_parts/cell/hyper
powertransfer = 1300

View File

@@ -108,7 +108,7 @@
desc = "This little bugger can be used to store and transport ores."
icon = 'icons/obj/mining.dmi'
icon_state = "satchel"
slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_POCKET
slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_POCKETS
w_class = WEIGHT_CLASS_NORMAL
component_type = /datum/component/storage/concrete/stack
var/spam_protection = FALSE //If this is TRUE, the holder won't receive any messages when they fail to pick up ore through crossing it
@@ -400,7 +400,7 @@
icon = 'icons/obj/chemical.dmi'
icon_state = "bag"
desc = "A bag for storing pills, patches, and bottles."
slot_flags = ITEM_SLOT_BELT|ITEM_SLOT_POCKET
slot_flags = ITEM_SLOT_BELT|ITEM_SLOT_POCKETS
resistance_flags = FLAMMABLE
/obj/item/storage/bag/chemistry/ComponentInitialize()
@@ -420,7 +420,7 @@
icon = 'icons/obj/chemical.dmi'
icon_state = "biobag"
desc = "A bag for the safe transportation and disposal of biowaste and other biological materials."
slot_flags = ITEM_SLOT_BELT|ITEM_SLOT_POCKET
slot_flags = ITEM_SLOT_BELT|ITEM_SLOT_POCKETS
resistance_flags = FLAMMABLE
/obj/item/storage/bag/bio/ComponentInitialize()
@@ -451,7 +451,7 @@
desc = "A pouch for your ammo that goes in your pocket."
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "ammopouch"
slot_flags = ITEM_SLOT_POCKET
slot_flags = ITEM_SLOT_POCKETS
w_class = WEIGHT_CLASS_BULKY
resistance_flags = FLAMMABLE
@@ -472,7 +472,7 @@ Bag for holding materials
desc = "A pouch for sheets and RCD ammunition that manages to hang where you would normally put things in your pocket."
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "materialpouch"
slot_flags = ITEM_SLOT_POCKET
slot_flags = ITEM_SLOT_POCKETS
w_class = WEIGHT_CLASS_BULKY
resistance_flags = FLAMMABLE

View File

@@ -73,7 +73,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible",
var/mob/living/carbon/human/H = usr
H.dna.add_mutation(CLOWNMUT)
H.dna.add_mutation(SMILE)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/clown_hat(H), SLOT_WEAR_MASK)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/clown_hat(H), ITEM_SLOT_MASK)
GLOB.bible_icon_state = icon_state
GLOB.bibleitemstates = item_state

View File

@@ -248,10 +248,10 @@
return ..()
var/obj/item/clothing/mask/cigarette/cig = locate(/obj/item/clothing/mask/cigarette) in contents
if(cig)
if(!user.wear_mask && !(SLOT_WEAR_MASK in M.check_obscured_slots()))
if(!user.wear_mask && !(ITEM_SLOT_MASK in M.check_obscured_slots()))
var/obj/item/clothing/mask/cigarette/W = cig
SEND_SIGNAL(src, COMSIG_TRY_STORAGE_TAKE, W, M)
M.equip_to_slot_if_possible(W, SLOT_WEAR_MASK)
M.equip_to_slot_if_possible(W, ITEM_SLOT_MASK)
contents -= W
to_chat(user, "<span class='notice'>You take \a [W] out of the pack.</span>")
else

View File

@@ -58,7 +58,7 @@
/obj/item/watertank/equipped(mob/user, slot)
..()
if(slot != SLOT_BACK)
if(slot != ITEM_SLOT_BACK)
remove_noz()
/obj/item/watertank/proc/remove_noz()
@@ -348,14 +348,14 @@
toggle_injection()
/obj/item/reagent_containers/chemtank/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot == SLOT_BACK)
if(slot == ITEM_SLOT_BACK)
return 1
/obj/item/reagent_containers/chemtank/proc/toggle_injection()
var/mob/living/carbon/human/user = usr
if(!istype(user))
return
if (user.get_item_by_slot(SLOT_BACK) != src)
if (user.get_item_by_slot(ITEM_SLOT_BACK) != src)
to_chat(user, "<span class='warning'>The chemtank needs to be on your back before you can activate it!</span>")
return
if(on)

View File

@@ -153,8 +153,8 @@
continue
if(iscarbon(L))
var/mob/living/carbon/C = L
var/obj/item/clothing/S = C.get_item_by_slot(SLOT_WEAR_SUIT)
var/obj/item/clothing/H = C.get_item_by_slot(SLOT_HEAD)
var/obj/item/clothing/S = C.get_item_by_slot(ITEM_SLOT_OCLOTHING)
var/obj/item/clothing/H = C.get_item_by_slot(ITEM_SLOT_HEAD)
if(S && H && S.clothing_flags & LAVAPROTECT && H.clothing_flags & LAVAPROTECT)
return

View File

@@ -1686,8 +1686,8 @@
if(ishuman(L))
var/mob/living/carbon/human/observer = L
observer.equip_to_slot_or_del(new /obj/item/clothing/under/suit/black(observer), SLOT_W_UNIFORM)
observer.equip_to_slot_or_del(new /obj/item/clothing/shoes/sneakers/black(observer), SLOT_SHOES)
observer.equip_to_slot_or_del(new /obj/item/clothing/under/suit/black(observer), ITEM_SLOT_ICLOTHING)
observer.equip_to_slot_or_del(new /obj/item/clothing/shoes/sneakers/black(observer), ITEM_SLOT_FEET)
L.Unconscious(100)
sleep(5)
L.forceMove(pick(GLOB.tdomeobserve))

View File

@@ -202,7 +202,7 @@
id.forceMove(W)
W.update_icon()
else
H.equip_to_slot(id,SLOT_WEAR_ID)
H.equip_to_slot(id,ITEM_SLOT_ID)
else
alert("Invalid mob")

View File

@@ -62,7 +62,7 @@
A.UpdateButtonIcon()
/obj/item/clothing/suit/armor/abductor/vest/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot == SLOT_WEAR_SUIT) //we only give the mob the ability to activate the vest if he's actually wearing it.
if(slot == ITEM_SLOT_OCLOTHING) //we only give the mob the ability to activate the vest if he's actually wearing it.
return TRUE
/obj/item/clothing/suit/armor/abductor/vest/proc/SetDisguise(datum/icon_snapshot/entry)

View File

@@ -84,7 +84,7 @@
return FALSE
if(owner.current.reagents.has_reagent(/datum/reagent/consumable/garlic))
return FALSE
if(istype(owner.current.get_item_by_slot(SLOT_NECK), /obj/item/clothing/neck/garlic_necklace))
if(istype(owner.current.get_item_by_slot(ITEM_SLOT_NECK), /obj/item/clothing/neck/garlic_necklace))
return FALSE
owner.current.adjustStaminaLoss(-1.5 + (actual_regen * -7) * mult, 0) // Humans lose stamina damage really quickly. Vamps should heal more.
owner.current.adjustCloneLoss(-0.1 * (actual_regen * 2) * mult, 0)

View File

@@ -94,7 +94,7 @@
if(display_error)
to_chat(owner, "<span class='warning'>You have a stake in your chest! Your powers are useless.</span>")
return FALSE
if(istype(owner.get_item_by_slot(SLOT_NECK), /obj/item/clothing/neck/garlic_necklace))
if(istype(owner.get_item_by_slot(ITEM_SLOT_NECK), /obj/item/clothing/neck/garlic_necklace))
if(display_error)
to_chat(owner, "<span class='warning'The necklace on your neck is interfering with your powers!</span>")
return FALSE

View File

@@ -105,7 +105,7 @@
var/mob/living/carbon/user_C = owner
//message_admins("DEBUG3: attempt_cast() [name] / [user_C.handcuffed] ")
if(user_C.handcuffed)
var/obj/O = user_C.get_item_by_slot(SLOT_HANDCUFFED)
var/obj/O = user_C.get_item_by_slot(ITEM_SLOT_HANDCUFFED)
if(istype(O))
user_C.clear_cuffs(O,TRUE)
playsound(get_turf(usr), 'sound/effects/grillehit.ogg', 80, 1, -1)
@@ -124,7 +124,7 @@
return TRUE */
// Destroy Leg Cuffs
if(user_C.legcuffed)
var/obj/O = user_C.get_item_by_slot(SLOT_LEGCUFFED)
var/obj/O = user_C.get_item_by_slot(ITEM_SLOT_LEGCUFFED)
if(istype(O))
user_C.clear_cuffs(O,TRUE)
playsound(get_turf(usr), 'sound/effects/grillehit.ogg', 80, 1, -1)

View File

@@ -17,7 +17,7 @@
return FALSE
if(user.handcuffed)
var/obj/O = user.get_item_by_slot(SLOT_HANDCUFFED)
var/obj/O = user.get_item_by_slot(ITEM_SLOT_HANDCUFFED)
if(!istype(O))
return FALSE
user.visible_message("<span class='warning'>[user] vomits a glob of acid on [user.p_their()] [O]!</span>", \
@@ -27,7 +27,7 @@
used = TRUE
if(user.legcuffed)
var/obj/O = user.get_item_by_slot(SLOT_LEGCUFFED)
var/obj/O = user.get_item_by_slot(ITEM_SLOT_LEGCUFFED)
if(!istype(O))
return FALSE
user.visible_message("<span class='warning'>[user] vomits a glob of acid on [user.p_their()] [O]!</span>", \
@@ -37,7 +37,7 @@
used = TRUE
if(user.wear_suit && user.wear_suit.breakouttime && !used)
var/obj/item/clothing/suit/S = user.get_item_by_slot(SLOT_WEAR_SUIT)
var/obj/item/clothing/suit/S = user.get_item_by_slot(ITEM_SLOT_OCLOTHING)
if(!istype(S))
return FALSE
user.visible_message("<span class='warning'>[user] vomits a glob of acid across the front of [user.p_their()] [S]!</span>", \

View File

@@ -130,8 +130,8 @@
user.dropItemToGround(user.head)
user.dropItemToGround(user.wear_suit)
user.equip_to_slot_if_possible(new suit_type(user), SLOT_WEAR_SUIT, 1, 1, 1)
user.equip_to_slot_if_possible(new helmet_type(user), SLOT_HEAD, 1, 1, 1)
user.equip_to_slot_if_possible(new suit_type(user), ITEM_SLOT_OCLOTHING, 1, 1, 1)
user.equip_to_slot_if_possible(new helmet_type(user), ITEM_SLOT_HEAD, 1, 1, 1)
var/datum/antagonist/changeling/changeling = user.mind.has_antag_datum(/datum/antagonist/changeling)
changeling.chem_recharge_slowdown += recharge_slowdown
@@ -637,7 +637,7 @@
user.dropItemToGround(user.gloves)
user.equip_to_slot_if_possible(new glove_type(user), SLOT_GLOVES, 1, 1, 1)
user.equip_to_slot_if_possible(new glove_type(user), ITEM_SLOT_GLOVES, 1, 1, 1)
playsound(user, 'sound/effects/blobattack.ogg', 30, 1)
var/datum/antagonist/changeling/changeling = user.mind.has_antag_datum(/datum/antagonist/changeling)
changeling.chem_recharge_slowdown += recharge_slowdown
@@ -733,7 +733,7 @@
/obj/item/clothing/gloves/fingerless/pugilist/cling/equipped(mob/user, slot)
. = ..()
if(current_equipped_slot == SLOT_GLOVES)
if(current_equipped_slot == ITEM_SLOT_GLOVES)
to_chat(user, "<span class='notice'>With [src] formed around our arms, we are ready to fight.</span>")
/obj/item/clothing/gloves/fingerless/pugilist/cling/dropped(mob/user)

View File

@@ -38,7 +38,7 @@
/obj/item/clothing/head/helmet/clockwork/equipped(mob/living/user, slot)
..()
if(slot == SLOT_HEAD && !is_servant_of_ratvar(user))
if(slot == ITEM_SLOT_HEAD && !is_servant_of_ratvar(user))
if(!iscultist(user))
to_chat(user, "<span class='heavy_brass'>\"Now now, this is for my servants, not you.\"</span>")
user.visible_message("<span class='warning'>As [user] puts [src] on, it flickers off [user.p_their()] head!</span>", "<span class='warning'>The helmet flickers off your head, leaving only nausea!</span>")
@@ -105,7 +105,7 @@
/obj/item/clothing/suit/armor/clockwork/equipped(mob/living/user, slot)
..()
if(slot == SLOT_WEAR_SUIT && !is_servant_of_ratvar(user))
if(slot == ITEM_SLOT_OCLOTHING && !is_servant_of_ratvar(user))
if(!iscultist(user))
to_chat(user, "<span class='heavy_brass'>\"Now now, this is for my servants, not you.\"</span>")
user.visible_message("<span class='warning'>As [user] puts [src] on, it flickers off [user.p_their()] body!</span>", "<span class='warning'>The cuirass flickers off your body, leaving only nausea!</span>")
@@ -165,7 +165,7 @@
/obj/item/clothing/gloves/clockwork/equipped(mob/living/user, slot)
..()
if(slot == SLOT_GLOVES && !is_servant_of_ratvar(user))
if(slot == ITEM_SLOT_GLOVES && !is_servant_of_ratvar(user))
if(!iscultist(user))
to_chat(user, "<span class='heavy_brass'>\"Now now, this is for my servants, not you.\"</span>")
user.visible_message("<span class='warning'>As [user] puts [src] on, it flickers off [user.p_their()] arms!</span>", "<span class='warning'>The gauntlets flicker off your arms, leaving only nausea!</span>")
@@ -215,7 +215,7 @@
/obj/item/clothing/shoes/clockwork/equipped(mob/living/user, slot)
..()
if(slot == SLOT_SHOES && !is_servant_of_ratvar(user))
if(slot == ITEM_SLOT_FEET && !is_servant_of_ratvar(user))
if(!iscultist(user))
to_chat(user, "<span class='heavy_brass'>\"Now now, this is for my servants, not you.\"</span>")
user.visible_message("<span class='warning'>As [user] puts [src] on, it flickers off [user.p_their()] feet!</span>", "<span class='warning'>The treads flicker off your feet, leaving only nausea!</span>")

View File

@@ -117,4 +117,4 @@
S.no_cost = TRUE
if(seasonal_hat && seasonal_hat != "none")
var/obj/item/hat = new seasonal_hat(construct)
construct.equip_to_slot_or_del(hat, SLOT_HEAD)
construct.equip_to_slot_or_del(hat, ITEM_SLOT_HEAD)

View File

@@ -28,13 +28,13 @@
return ..()
/obj/item/clothing/glasses/judicial_visor/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot != SLOT_GLASSES)
if(slot != ITEM_SLOT_EYES)
return 0
return ..()
/obj/item/clothing/glasses/judicial_visor/equipped(mob/living/user, slot)
..()
if(slot != SLOT_GLASSES)
if(slot != ITEM_SLOT_EYES)
update_status(FALSE)
if(blaster.ranged_ability_user)
blaster.remove_ranged_ability()
@@ -55,13 +55,13 @@
addtimer(CALLBACK(src, .proc/check_on_mob, user), 1) //dropped is called before the item is out of the slot, so we need to check slightly later
/obj/item/clothing/glasses/judicial_visor/proc/check_on_mob(mob/user)
if(user && src != user.get_item_by_slot(SLOT_GLASSES)) //if we happen to check and we AREN'T in the slot, we need to remove our shit from whoever we got dropped from
if(user && src != user.get_item_by_slot(ITEM_SLOT_EYES)) //if we happen to check and we AREN'T in the slot, we need to remove our shit from whoever we got dropped from
update_status(FALSE)
if(blaster.ranged_ability_user)
blaster.remove_ranged_ability()
/obj/item/clothing/glasses/judicial_visor/attack_self(mob/user)
if(is_servant_of_ratvar(user) && src == user.get_item_by_slot(SLOT_GLASSES))
if(is_servant_of_ratvar(user) && src == user.get_item_by_slot(ITEM_SLOT_EYES))
blaster.toggle(user)
/obj/item/clothing/glasses/judicial_visor/proc/update_status(change_to)
@@ -89,7 +89,7 @@
if(!src)
return 0
recharging = FALSE
if(user && src == user.get_item_by_slot(SLOT_GLASSES))
if(user && src == user.get_item_by_slot(ITEM_SLOT_EYES))
to_chat(user, "<span class='brass'>Your [name] hums. It is ready.</span>")
else
active = FALSE
@@ -115,7 +115,7 @@
/obj/effect/proc_holder/judicial_visor/InterceptClickOn(mob/living/caller, params, atom/target)
if(..())
return
if(ranged_ability_user.incapacitated() || !visor || visor != ranged_ability_user.get_item_by_slot(SLOT_GLASSES))
if(ranged_ability_user.incapacitated() || !visor || visor != ranged_ability_user.get_item_by_slot(ITEM_SLOT_EYES))
remove_ranged_ability()
return

View File

@@ -75,7 +75,7 @@
/obj/item/clothing/glasses/wraith_spectacles/equipped(mob/living/user, slot)
..()
if(slot != SLOT_GLASSES || up)
if(slot != ITEM_SLOT_EYES || up)
return
if(HAS_TRAIT(user, TRAIT_BLIND))
to_chat(user, "<span class='heavy_brass'>\"You're blind, idiot. Stop embarrassing yourself.\"</span>" )

View File

@@ -200,18 +200,18 @@
/datum/action/innate/clockwork_armaments/Activate()
var/do_message = 0
var/obj/item/I = owner.get_item_by_slot(SLOT_WEAR_SUIT)
var/obj/item/I = owner.get_item_by_slot(ITEM_SLOT_OCLOTHING)
if(remove_item_if_better(I, owner))
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/suit/armor/clockwork(null), SLOT_WEAR_SUIT)
I = owner.get_item_by_slot(SLOT_HEAD)
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/suit/armor/clockwork(null), ITEM_SLOT_OCLOTHING)
I = owner.get_item_by_slot(ITEM_SLOT_HEAD)
if(remove_item_if_better(I, owner))
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/head/helmet/clockwork(null), SLOT_HEAD)
I = owner.get_item_by_slot(SLOT_GLOVES)
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/head/helmet/clockwork(null), ITEM_SLOT_HEAD)
I = owner.get_item_by_slot(ITEM_SLOT_GLOVES)
if(remove_item_if_better(I, owner))
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/gloves/clockwork(null), SLOT_GLOVES)
I = owner.get_item_by_slot(SLOT_SHOES)
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/gloves/clockwork(null), ITEM_SLOT_GLOVES)
I = owner.get_item_by_slot(ITEM_SLOT_FEET)
if(remove_item_if_better(I, owner))
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/shoes/clockwork(null), SLOT_SHOES)
do_message += owner.equip_to_slot_or_del(new/obj/item/clothing/shoes/clockwork(null), ITEM_SLOT_FEET)
if(do_message)
owner.visible_message("<span class='warning'>Strange armor appears on [owner]!</span>", "<span class='heavy_brass'>A bright shimmer runs down your body, equipping you with Ratvarian armor.</span>")
playsound(owner, 'sound/magic/clockwork/fellowship_armory.ogg', 15 * do_message, TRUE) //get sound loudness based on how much we equipped
@@ -309,16 +309,16 @@
continue
T = get_turf(M)
var/heal_ticks = 0 //one heal tick for each piece of ratvarian armor worn
var/obj/item/I = H.get_item_by_slot(SLOT_WEAR_SUIT)
var/obj/item/I = H.get_item_by_slot(ITEM_SLOT_OCLOTHING)
if(is_type_in_typecache(I, ratvarian_armor_typecache))
heal_ticks++
I = H.get_item_by_slot(SLOT_HEAD)
I = H.get_item_by_slot(ITEM_SLOT_HEAD)
if(is_type_in_typecache(I, ratvarian_armor_typecache))
heal_ticks++
I = H.get_item_by_slot(SLOT_GLOVES)
I = H.get_item_by_slot(ITEM_SLOT_GLOVES)
if(is_type_in_typecache(I, ratvarian_armor_typecache))
heal_ticks++
I = H.get_item_by_slot(SLOT_SHOES)
I = H.get_item_by_slot(ITEM_SLOT_FEET)
if(is_type_in_typecache(I, ratvarian_armor_typecache))
heal_ticks++
if(heal_ticks)

View File

@@ -678,12 +678,12 @@
uses--
var/mob/living/carbon/C = target
C.visible_message("<span class='warning'>Otherworldly armor suddenly appears on [C]!</span>")
C.equip_to_slot_or_del(new /obj/item/clothing/under/color/black,SLOT_W_UNIFORM)
C.equip_to_slot_or_del(new /obj/item/clothing/head/culthood/alt(user), SLOT_HEAD)
C.equip_to_slot_or_del(new /obj/item/clothing/suit/cultrobes/alt(user), SLOT_WEAR_SUIT)
C.equip_to_slot_or_del(new /obj/item/clothing/shoes/cult/alt(user), SLOT_SHOES)
C.equip_to_slot_or_del(new /obj/item/storage/backpack/cultpack(user), SLOT_BACK)
C.equip_to_slot_or_del(new /obj/item/clothing/gloves/fingerless/pugilist/hungryghost(user), SLOT_GLOVES)
C.equip_to_slot_or_del(new /obj/item/clothing/under/color/black,ITEM_SLOT_ICLOTHING)
C.equip_to_slot_or_del(new /obj/item/clothing/head/culthood/alt(user), ITEM_SLOT_HEAD)
C.equip_to_slot_or_del(new /obj/item/clothing/suit/cultrobes/alt(user), ITEM_SLOT_OCLOTHING)
C.equip_to_slot_or_del(new /obj/item/clothing/shoes/cult/alt(user), ITEM_SLOT_FEET)
C.equip_to_slot_or_del(new /obj/item/storage/backpack/cultpack(user), ITEM_SLOT_BACK)
C.equip_to_slot_or_del(new /obj/item/clothing/gloves/fingerless/pugilist/hungryghost(user), ITEM_SLOT_GLOVES)
if(C == user)
qdel(src) //Clears the hands
C.put_in_hands(new /obj/item/melee/cultblade(user))

View File

@@ -95,9 +95,9 @@
/datum/antagonist/cult/proc/cult_give_item(obj/item/item_path, mob/living/carbon/human/mob)
var/list/slots = list(
"backpack" = SLOT_IN_BACKPACK,
"left pocket" = SLOT_L_STORE,
"right pocket" = SLOT_R_STORE
"backpack" = ITEM_SLOT_BACKPACK,
"left pocket" = ITEM_SLOT_LPOCKET,
"right pocket" = ITEM_SLOT_RPOCKET
)
var/T = new item_path(mob)

View File

@@ -1090,7 +1090,7 @@ structure_check() searches for nearby cultist structures required for the invoca
/proc/hudFix(mob/living/carbon/human/target)
if(!target || !target.client)
return
var/obj/O = target.get_item_by_slot(SLOT_GLASSES)
var/obj/O = target.get_item_by_slot(ITEM_SLOT_EYES)
if(istype(O, /obj/item/clothing/glasses/hud/security))
var/datum/atom_hud/AH = GLOB.huds[DATA_HUD_SECURITY_ADVANCED]
AH.add_hud_to(target)

View File

@@ -460,10 +460,10 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
return -1
currentMob.change_mob_type( /mob/living/carbon/human, targetturf, null, 1)
var/mob/living/carbon/human/H = owner.current
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/civilian/lawyer/black(H), SLOT_W_UNIFORM)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/laceup(H), SLOT_SHOES)
H.equip_to_slot_or_del(new /obj/item/storage/briefcase(H), SLOT_HANDS)
H.equip_to_slot_or_del(new /obj/item/pen(H), SLOT_L_STORE)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/civilian/lawyer/black(H), ITEM_SLOT_ICLOTHING)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/laceup(H), ITEM_SLOT_FEET)
H.equip_to_slot_or_del(new /obj/item/storage/briefcase(H), ITEM_SLOT_HANDS)
H.equip_to_slot_or_del(new /obj/item/pen(H), ITEM_SLOT_LPOCKET)
if(SOULVALUE >= BLOOD_THRESHOLD)
H.set_species(/datum/species/lizard, 1)
H.underwear = "Nude"

View File

@@ -72,9 +72,9 @@
/datum/antagonist/heretic/proc/ecult_give_item(obj/item/item_path, mob/living/carbon/human/H)
var/list/slots = list(
"backpack" = SLOT_IN_BACKPACK,
"left pocket" = SLOT_L_STORE,
"right pocket" = SLOT_R_STORE
"backpack" = ITEM_SLOT_BACKPACK,
"left pocket" = ITEM_SLOT_LPOCKET,
"right pocket" = ITEM_SLOT_RPOCKET
)
var/T = new item_path(H)

View File

@@ -145,7 +145,7 @@
/obj/item/clothing/neck/eldritch_amulet/equipped(mob/user, slot)
. = ..()
if(ishuman(user) && user.mind && slot == SLOT_NECK && (IS_HERETIC(user) || IS_HERETIC_MONSTER(user)))
if(ishuman(user) && user.mind && slot == ITEM_SLOT_NECK && (IS_HERETIC(user) || IS_HERETIC_MONSTER(user)))
ADD_TRAIT(user, trait, CLOTHING_TRAIT)
user.update_sight()
@@ -239,7 +239,7 @@
/obj/item/clothing/mask/void_mask/equipped(mob/user, slot)
. = ..()
if(ishuman(user) && user.mind && slot == SLOT_WEAR_MASK)
if(ishuman(user) && user.mind && slot == ITEM_SLOT_MASK)
local_user = user
START_PROCESSING(SSobj, src)

View File

@@ -39,7 +39,7 @@
var/datum/status_effect/eldritch/E = H.has_status_effect(/datum/status_effect/eldritch/rust) || H.has_status_effect(/datum/status_effect/eldritch/ash) || H.has_status_effect(/datum/status_effect/eldritch/flesh) || H.has_status_effect(/datum/status_effect/eldritch/void)
if(E)
E.on_effect()
H.adjustOrganLoss(pick(ORGAN_SLOT_BRAIN,ORGAN_SLOT_EARS,ORGAN_SLOT_EYES,ORGAN_SLOT_LIVER,ORGAN_SLOT_LUNGS,ORGAN_SLOT_STOMACH,ORGAN_SLOT_HEART),25)
H.adjustOrganLoss(pick(ORGAN_SLOT_BRAIN,ORGAN_ITEM_SLOT_EARS,ORGAN_SLOT_EYES,ORGAN_SLOT_LIVER,ORGAN_SLOT_LUNGS,ORGAN_SLOT_STOMACH,ORGAN_SLOT_HEART),25)
/datum/eldritch_knowledge/spell/area_conversion
name = "Aggressive Spread"

View File

@@ -234,8 +234,8 @@
var/obj/O = new C(owner.current)
var/list/slots = list (
"backpack" = ITEM_SLOT_BACKPACK,
"left pocket" = SLOT_L_STORE,
"right pocket" = SLOT_R_STORE
"left pocket" = ITEM_SLOT_LPOCKET,
"right pocket" = ITEM_SLOT_RPOCKET
)
var/mob/living/carbon/human/H = owner.current
var/equipped = H.equip_in_one_of_slots(O, slots)

View File

@@ -45,11 +45,11 @@
qdel(I)
for(var/obj/item/I in H.held_items)
qdel(I)
H.equip_to_slot_or_del(new /obj/item/clothing/under/costume/kilt/highlander(H), SLOT_W_UNIFORM)
H.equip_to_slot_or_del(new /obj/item/radio/headset/heads/captain(H), SLOT_EARS)
H.equip_to_slot_or_del(new /obj/item/clothing/head/beret/highlander(H), SLOT_HEAD)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(H), SLOT_SHOES)
H.equip_to_slot_or_del(new /obj/item/pinpointer/nuke(H), SLOT_L_STORE)
H.equip_to_slot_or_del(new /obj/item/clothing/under/costume/kilt/highlander(H), ITEM_SLOT_ICLOTHING)
H.equip_to_slot_or_del(new /obj/item/radio/headset/heads/captain(H), ITEM_SLOT_EARS)
H.equip_to_slot_or_del(new /obj/item/clothing/head/beret/highlander(H), ITEM_SLOT_HEAD)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(H), ITEM_SLOT_FEET)
H.equip_to_slot_or_del(new /obj/item/pinpointer/nuke(H), ITEM_SLOT_LPOCKET)
for(var/obj/item/pinpointer/nuke/P in H)
P.attack_self(H)
var/obj/item/card/id/W = new(H)
@@ -60,7 +60,7 @@
W.registered_name = H.real_name
ADD_TRAIT(W, TRAIT_NODROP, HIGHLANDER)
W.update_label(H.real_name)
H.equip_to_slot_or_del(W, SLOT_WEAR_ID)
H.equip_to_slot_or_del(W, ITEM_SLOT_ID)
sword = new(H)
if(!GLOB.highlander)

View File

@@ -127,9 +127,9 @@
// Give AI hacking board
var/obj/item/aiModule/core/full/overthrow/O = new(H)
var/list/slots = list (
"backpack" = SLOT_IN_BACKPACK,
"left pocket" = SLOT_L_STORE,
"right pocket" = SLOT_R_STORE
"backpack" = ITEM_SLOT_BACKPACK,
"left pocket" = ITEM_SLOT_LPOCKET,
"right pocket" = ITEM_SLOT_RPOCKET
)
var/where = H.equip_in_one_of_slots(O, slots, critical = TRUE)
if (!where)

View File

@@ -272,9 +272,9 @@
if(give_flash)
var/obj/item/assembly/flash/T = new(H)
var/list/slots = list (
"backpack" = SLOT_IN_BACKPACK,
"left pocket" = SLOT_L_STORE,
"right pocket" = SLOT_R_STORE
"backpack" = ITEM_SLOT_BACKPACK,
"left pocket" = ITEM_SLOT_LPOCKET,
"right pocket" = ITEM_SLOT_RPOCKET
)
var/where = H.equip_in_one_of_slots(T, slots, critical = TRUE)
if (!where)

View File

@@ -240,9 +240,9 @@
folder = new/obj/item/folder/syndicate/blue(mob.loc)
var/list/slots = list (
"backpack" = SLOT_IN_BACKPACK,
"left pocket" = SLOT_L_STORE,
"right pocket" = SLOT_R_STORE
"backpack" = ITEM_SLOT_BACKPACK,
"left pocket" = ITEM_SLOT_LPOCKET,
"right pocket" = ITEM_SLOT_RPOCKET
)
var/where = "At your feet"

View File

@@ -229,12 +229,12 @@
H.dropItemToGround(I)
var/hat = pick(/obj/item/clothing/head/helmet/roman, /obj/item/clothing/head/helmet/roman/legionnaire)
H.equip_to_slot_or_del(new hat(H), SLOT_HEAD)
H.equip_to_slot_or_del(new /obj/item/clothing/under/costume/roman(H), SLOT_W_UNIFORM)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/roman(H), SLOT_SHOES)
H.equip_to_slot_or_del(new hat(H), ITEM_SLOT_HEAD)
H.equip_to_slot_or_del(new /obj/item/clothing/under/costume/roman(H), ITEM_SLOT_ICLOTHING)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/roman(H), ITEM_SLOT_FEET)
H.put_in_hands(new /obj/item/shield/riot/roman(H), TRUE)
H.put_in_hands(new /obj/item/claymore(H), TRUE)
H.equip_to_slot_or_del(new /obj/item/spear(H), SLOT_BACK)
H.equip_to_slot_or_del(new /obj/item/spear(H), ITEM_SLOT_BACK)
/obj/item/voodoo

View File

@@ -208,17 +208,17 @@
if(!istype(master_mob) || !istype(H))
return
if(master_mob.ears)
H.equip_to_slot_or_del(new master_mob.ears.type, SLOT_EARS)
H.equip_to_slot_or_del(new master_mob.ears.type, ITEM_SLOT_EARS)
if(master_mob.w_uniform)
H.equip_to_slot_or_del(new master_mob.w_uniform.type, SLOT_W_UNIFORM)
H.equip_to_slot_or_del(new master_mob.w_uniform.type, ITEM_SLOT_ICLOTHING)
if(master_mob.shoes)
H.equip_to_slot_or_del(new master_mob.shoes.type, SLOT_SHOES)
H.equip_to_slot_or_del(new master_mob.shoes.type, ITEM_SLOT_FEET)
if(master_mob.wear_suit)
H.equip_to_slot_or_del(new master_mob.wear_suit.type, SLOT_WEAR_SUIT)
H.equip_to_slot_or_del(new master_mob.wear_suit.type, ITEM_SLOT_OCLOTHING)
if(master_mob.head)
H.equip_to_slot_or_del(new master_mob.head.type, SLOT_HEAD)
H.equip_to_slot_or_del(new master_mob.head.type, ITEM_SLOT_HEAD)
if(master_mob.back)
H.equip_to_slot_or_del(new master_mob.back.type, SLOT_BACK)
H.equip_to_slot_or_del(new master_mob.back.type, ITEM_SLOT_BACK)
//Operation: Fuck off and scare people
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/area_teleport/teleport(null))

View File

@@ -27,7 +27,7 @@
/obj/item/clothing/head/rice_hat/cursed/equipped(mob/M, slot)
. = ..()
if (slot == SLOT_HEAD)
if (slot == ITEM_SLOT_HEAD)
RegisterSignal(M, COMSIG_MOB_SAY, .proc/handle_speech)
else
UnregisterSignal(M, COMSIG_MOB_SAY)

View File

@@ -589,7 +589,7 @@
back = /obj/item/storage/backpack
mask = /obj/item/clothing/mask/breath
r_pocket = /obj/item/tank/internals/emergency_oxygen/engi
internals_slot = SLOT_R_STORE
internals_slot = ITEM_SLOT_RPOCKET
/obj/effect/mob_spawn/human/syndicatesoldier/coldres/alive/female
mob_gender = FEMALE

View File

@@ -3225,10 +3225,10 @@ GLOBAL_LIST_EMPTY(preferences_datums)
var/occupied_slots = L[initial(G.category)] ? L[initial(G.category)] + 1 : 1
LAZYSET(L, initial(G.category), occupied_slots)
switch(slot)
if(SLOT_IN_BACKPACK)
if(ITEM_SLOT_BACKPACK)
if(L[LOADOUT_CATEGORY_BACKPACK] < BACKPACK_SLOT_AMT)
return TRUE
if(SLOT_HANDS)
if(ITEM_SLOT_HANDS)
if(L[LOADOUT_CATEGORY_HANDS] < HANDS_SLOT_AMT)
return TRUE
else

View File

@@ -63,8 +63,8 @@
// it's TRAIT_NODROP
D.dropItemToGround(target, TRUE)
qdel(old_headgear)
// where is `SLOT_HEAD` defined? WHO KNOWS
D.equip_to_slot(new_headgear, SLOT_HEAD)
// where is `ITEM_SLOT_HEAD` defined? WHO KNOWS
D.equip_to_slot(new_headgear, ITEM_SLOT_HEAD)
return 1

View File

@@ -219,7 +219,7 @@
..()
if (!istype(user))
return
if(slot_flags & slotdefine2slotbit(slot)) //Was equipped to a valid slot for this item?
if(slot_flags & slot) //Was equipped to a valid slot for this item?
if(iscarbon(user) && LAZYLEN(zones_disabled))
RegisterSignal(user, COMSIG_MOVABLE_MOVED, .proc/bristle)
if(LAZYLEN(user_vars_to_edit))
@@ -450,7 +450,7 @@ BLIND // can't see anything
return FALSE
// Skip species restriction checks on non-equipment slots
if(slot in list(SLOT_IN_BACKPACK, SLOT_L_STORE, SLOT_R_STORE))
if(slot in list(ITEM_SLOT_BACKPACK, ITEM_SLOT_LPOCKET, ITEM_SLOT_RPOCKET))
return TRUE
if(species_restricted && ishuman(M))

View File

@@ -20,7 +20,7 @@
/obj/item/clothing/ears/earmuffs/ComponentInitialize()
. = ..()
AddElement(/datum/element/earhealing)
AddComponent(/datum/component/wearertargeting/earprotection, list(SLOT_EARS))
AddComponent(/datum/component/wearertargeting/earprotection, list(ITEM_SLOT_EARS))
/obj/item/clothing/ears/headphones
name = "headphones"

View File

@@ -115,7 +115,7 @@
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 80, "acid" = 100)
/obj/item/clothing/glasses/science/item_action_slot_check(slot, mob/user, datum/action/A)
if(slot == SLOT_GLASSES)
if(slot == ITEM_SLOT_EYES)
return 1
/obj/item/clothing/glasses/night
@@ -158,7 +158,7 @@
/obj/item/clothing/glasses/eyepatch/syndicate/equipped(mob/living/carbon/human/user, slot)
. = ..()
if(slot == SLOT_GLASSES)
if(slot == ITEM_SLOT_EYES)
user.visible_message("<span class='warning'>Circuitry from the eyepatch links itself to your brain as you put on the eyepatch.")
if(HAS_TRAIT(user, TRAIT_POOR_AIM))
user.visible_message("<span class='warning'>You hear a fizzing noise from the circuit. That can't be good.")
@@ -351,7 +351,7 @@
/obj/item/clothing/glasses/sunglasses/blindfold/equipped(mob/living/carbon/human/user, slot)
. = ..()
if(slot == SLOT_GLASSES)
if(slot == ITEM_SLOT_EYES)
user.become_blind("blindfold_[REF(src)]")
/obj/item/clothing/glasses/sunglasses/blindfold/dropped(mob/living/carbon/human/user)
@@ -372,7 +372,7 @@
var/colored_before = FALSE
/obj/item/clothing/glasses/sunglasses/blindfold/white/equipped(mob/living/carbon/human/user, slot)
if(ishuman(user) && slot == SLOT_GLASSES)
if(ishuman(user) && slot == ITEM_SLOT_EYES)
update_icon(user)
user.update_inv_glasses() //Color might have been changed by update_icon.
..()

View File

@@ -18,7 +18,7 @@
/obj/item/clothing/glasses/hud/equipped(mob/living/carbon/human/user, slot)
..()
if(hud_type && slot == SLOT_GLASSES)
if(hud_type && slot == ITEM_SLOT_EYES)
var/datum/atom_hud/H = GLOB.huds[hud_type]
H.add_hud_to(user)

View File

@@ -17,7 +17,7 @@
/obj/item/clothing/glasses/phantomthief/syndicate/examine(mob/user)
. = ..()
if(user.get_item_by_slot(SLOT_GLASSES) == src)
if(user.get_item_by_slot(ITEM_SLOT_EYES) == src)
if(world.time >= nextadrenalinepop)
. += "<span class='notice'>The built-in adrenaline injector is ready for use.</span>"
else
@@ -33,7 +33,7 @@
. = ..()
if(!istype(user))
return
if(slot != SLOT_GLASSES)
if(slot != ITEM_SLOT_EYES)
return
RegisterSignal(user, COMSIG_LIVING_COMBAT_ENABLED, .proc/injectadrenaline)

View File

@@ -31,7 +31,7 @@
C.visible_message("<span class='warning'>[U] sprays glittery rubber on the hands of [C]!</span>")
else
user.visible_message("<span class='warning'>The rubber fails to stick to [C]'s hands!</span>",
"<span class='warning'>The rubber fails to stick to [C]'s [(SLOT_GLOVES in C.check_obscured_slots()) ? "unexposed" : ""] hands!</span>")
"<span class='warning'>The rubber fails to stick to [C]'s [(ITEM_SLOT_GLOVES in C.check_obscured_slots()) ? "unexposed" : ""] hands!</span>")
qdel(src)
@@ -226,7 +226,7 @@
/obj/item/clothing/gloves/color/latex/equipped(mob/user, slot)
..()
if(slot == SLOT_GLOVES)
if(slot == ITEM_SLOT_GLOVES)
ADD_TRAIT(user, carrytrait, GLOVE_TRAIT)
/obj/item/clothing/gloves/color/latex/dropped(mob/user)

View File

@@ -36,7 +36,7 @@
/obj/item/clothing/gloves/fingerless/pugilist/equipped(mob/user, slot)
. = ..()
if(slot == SLOT_GLOVES)
if(slot == ITEM_SLOT_GLOVES)
wornonce = TRUE
if((HAS_TRAIT(user, TRAIT_NOPUGILIST)))
to_chat(user, "<span class='danger'>What purpose is there to don the weapons of pugilism if you're already well-practiced in martial arts? Mixing arts is blasphemous!</span>")
@@ -195,7 +195,7 @@
/obj/item/clothing/gloves/fingerless/ablative/equipped(mob/user, slot)
. = ..()
if(current_equipped_slot == SLOT_GLOVES)
if(current_equipped_slot == ITEM_SLOT_GLOVES)
RegisterSignal(user, COMSIG_LIVING_ACTIVE_PARRY_START, .proc/get_component_parry_data)
wornonce = TRUE
@@ -262,7 +262,7 @@
/obj/item/clothing/gloves/fingerless/pugilist/mauler/equipped(mob/user, slot)
. = ..()
if(slot == SLOT_GLOVES)
if(slot == ITEM_SLOT_GLOVES)
wornonce = TRUE
if((HAS_TRAIT(user, TRAIT_NOPUGILIST)))
return

View File

@@ -28,7 +28,7 @@
if(!ishuman(user))
return
switch(slot) // I didn't like how it looked
if(SLOT_GLOVES)
if(ITEM_SLOT_GLOVES)
var/mob/living/carbon/human/H = user
tackler = H.AddComponent(/datum/component/tackler, stamina_cost=tackle_stam_cost, base_knockdown = base_knockdown, range = tackle_range, speed = tackle_speed, skill_mod = skill_mod, min_distance = min_distance)
else
@@ -103,7 +103,7 @@
/obj/item/clothing/gloves/tackler/combat/insulated/infiltrator/equipped(mob/user, slot)
. = ..()
if(slot == SLOT_GLOVES)
if(slot == ITEM_SLOT_GLOVES)
ADD_TRAIT(user, carrytrait, GLOVE_TRAIT)
/obj/item/clothing/gloves/tackler/combat/insulated/infiltrator/dropped(mob/user)

View File

@@ -34,7 +34,7 @@
var/obj/item/WH = H.head
H.visible_message("<span class='warning'>[src] bounces off [H]'s [WH.name]!", "<span class='warning'>[src] bounces off your [WH.name], falling to the floor.</span>")
return
if(H.equip_to_slot_if_possible(src, SLOT_HEAD, FALSE, TRUE))
if(H.equip_to_slot_if_possible(src, ITEM_SLOT_HEAD, FALSE, TRUE))
H.visible_message("<span class='notice'>[src] lands neatly on [H]'s head!", "<span class='notice'>[src] lands perfectly onto your head!</span>")
return
if(iscyborg(hit_atom))

Some files were not shown because too many files have changed in this diff Show More