mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-09 16:07:40 +00:00
Merge remote-tracking branch 'upstream/master'
This commit is contained in:
@@ -112,11 +112,6 @@ GLOBAL_LIST_EMPTY(living_heart_cache) //A list of all living hearts in existance
|
||||
#define BLOB_ATTACK_REFUND 2 //blob refunds this much if it attacks and doesn't spread
|
||||
#define BLOB_REFLECTOR_COST 15
|
||||
|
||||
//Objectives-Ambitions Panel
|
||||
#define REQUEST_NEW_OBJECTIVE "new_objective"
|
||||
#define REQUEST_DEL_OBJECTIVE "del_objective"
|
||||
#define REQUEST_WIN_OBJECTIVE "win_objective"
|
||||
#define REQUEST_LOSE_OBJECTIVE "lose_objective"
|
||||
/// How many telecrystals a normal traitor starts with
|
||||
#define TELECRYSTALS_DEFAULT 20
|
||||
/// How many telecrystals mapper/admin only "precharged" uplink implant
|
||||
@@ -128,3 +123,9 @@ GLOBAL_LIST_EMPTY(living_heart_cache) //A list of all living hearts in existance
|
||||
|
||||
/// The dimensions of the antagonist preview icon. Will be scaled to this size.
|
||||
#define ANTAGONIST_PREVIEW_ICON_SIZE 96
|
||||
|
||||
//Objectives-Ambitions Panel
|
||||
#define REQUEST_NEW_OBJECTIVE "new_objective"
|
||||
#define REQUEST_DEL_OBJECTIVE "del_objective"
|
||||
#define REQUEST_WIN_OBJECTIVE "win_objective"
|
||||
#define REQUEST_LOSE_OBJECTIVE "lose_objective"
|
||||
|
||||
@@ -116,6 +116,7 @@
|
||||
#define GLOVES_MAX_TEMP_PROTECT 1500 //For some gloves
|
||||
#define SHOES_MIN_TEMP_PROTECT 2.0 //For gloves
|
||||
#define SHOES_MAX_TEMP_PROTECT 1500 //For gloves
|
||||
#define COAT_MAX_TEMP_PROTECT 330 //For winter coats (if they can stop you from getting cold why can't they do it the other way to a lesser extent)
|
||||
|
||||
#define PRESSURE_DAMAGE_COEFFICIENT 4 //The amount of pressure damage someone takes is equal to (pressure / HAZARD_HIGH_PRESSURE)*PRESSURE_DAMAGE_COEFFICIENT, with the maximum of MAX_PRESSURE_DAMAGE
|
||||
#define MAX_HIGH_PRESSURE_DAMAGE 16 // CITADEL CHANGES Max to 16, low to 8.
|
||||
|
||||
@@ -6,116 +6,67 @@
|
||||
#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)
|
||||
//skyrat edit
|
||||
#define ITEM_SLOT_UNDERWEAR (1<<17)
|
||||
#define ITEM_SLOT_SOCKS (1<<18)
|
||||
#define ITEM_SLOT_SHIRT (1<<19)
|
||||
#define ITEM_SLOT_WRISTS (1<<20)
|
||||
//
|
||||
/// 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_LEFT (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)
|
||||
// -- Sandstorm edit --
|
||||
/// Underwear slot
|
||||
#define ITEM_SLOT_UNDERWEAR (1<<17)
|
||||
/// Socks slot
|
||||
#define ITEM_SLOT_SOCKS (1<<18)
|
||||
/// Shirt slot
|
||||
#define ITEM_SLOT_SHIRT (1<<19)
|
||||
/// Right ear slot
|
||||
#define ITEM_SLOT_EARS_RIGHT (1<<20)
|
||||
/// Wrist slot
|
||||
#define ITEM_SLOT_WRISTS (1<<21)
|
||||
// -- End edit --
|
||||
/// Handcuff slot
|
||||
#define ITEM_SLOT_HANDCUFFED (1<<22)
|
||||
/// Legcuff slot (bolas, beartraps)
|
||||
#define ITEM_SLOT_LEGCUFFED (1<<23)
|
||||
|
||||
//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_LEFT 7 //skyrat edit
|
||||
#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
|
||||
//skyrat edit
|
||||
#define SLOT_W_UNDERWEAR 21
|
||||
#define SLOT_W_SOCKS 22
|
||||
#define SLOT_W_SHIRT 23
|
||||
#define SLOT_EARS_RIGHT 24
|
||||
#define SLOT_WRISTS 25
|
||||
//
|
||||
/// Total amount of slots
|
||||
#define SLOTS_AMT 25 // Keep this up to date!
|
||||
|
||||
//SLOT GROUP HELPERS
|
||||
#define ITEM_SLOT_POCKETS (ITEM_SLOT_LPOCKET|ITEM_SLOT_RPOCKET)
|
||||
|
||||
#define SLOTS_AMT 25 // Keep this up to date! //skyrat edit - extra slots
|
||||
|
||||
//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
|
||||
//skyrat edit
|
||||
if(SLOT_EARS_RIGHT)
|
||||
. = ITEM_SLOT_EARS
|
||||
if(SLOT_EARS_LEFT)
|
||||
. = ITEM_SLOT_EARS
|
||||
//
|
||||
if(SLOT_GLASSES)
|
||||
. = ITEM_SLOT_EYES
|
||||
if(SLOT_GLOVES)
|
||||
. = ITEM_SLOT_GLOVES
|
||||
//skyrat edit
|
||||
if(SLOT_WRISTS)
|
||||
. = ITEM_SLOT_WRISTS
|
||||
//
|
||||
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
|
||||
//skyrat edit
|
||||
if(SLOT_W_UNDERWEAR)
|
||||
. = ITEM_SLOT_UNDERWEAR
|
||||
if(SLOT_W_SOCKS)
|
||||
. = ITEM_SLOT_SOCKS
|
||||
if(SLOT_W_SHIRT)
|
||||
. = ITEM_SLOT_SHIRT
|
||||
//
|
||||
|
||||
//EARS HELPER
|
||||
#define ITEM_SLOT_EARS (ITEM_SLOT_EARS_LEFT|ITEM_SLOT_EARS_RIGHT)
|
||||
|
||||
//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)
|
||||
@@ -278,4 +229,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))
|
||||
|
||||
@@ -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))
|
||||
|
||||
@@ -74,5 +74,5 @@
|
||||
)
|
||||
|
||||
#define BOMB_TARGET_POINTS 50000 //Adjust as needed. Actual hard cap is double this, but will never be reached due to hyperbolic curve.
|
||||
#define BOMB_TARGET_SIZE 200 // The shockwave radius required for a bomb to get TECHWEB_BOMB_MIDPOINT points.
|
||||
#define BOMB_SUB_TARGET_EXPONENT 2 // The power of the points curve below the target size. Higher = less points for worse bombs, below target.
|
||||
#define BOMB_TARGET_SIZE 175 // The shockwave radius required for a bomb to get TECHWEB_BOMB_MIDPOINT points.
|
||||
#define BOMB_SUB_TARGET_EXPONENT 3 // The power of the points curve below the target size. Higher = less points for worse bombs, below target.
|
||||
|
||||
@@ -140,3 +140,6 @@ GLOBAL_VAR_INIT(cmp_field, "name")
|
||||
|
||||
/proc/cmp_typepaths_asc(A, B)
|
||||
return sorttext("[B]","[A]")
|
||||
|
||||
/proc/cmp_playtime(list/A, list/B)
|
||||
return A["playtime"] - B["playtime"]
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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 ..()
|
||||
|
||||
@@ -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, SLOT_WRISTS) //SKYRAT EDIT
|
||||
if(ITEM_SLOT_GLOVES, ITEM_SLOT_HANDS, ITEM_SLOT_HANDCUFFED, ITEM_SLOT_WRISTS) // Sandstorm edit
|
||||
return pick(BODY_ZONE_PRECISE_L_HAND, BODY_ZONE_PRECISE_R_HAND)
|
||||
|
||||
if(SLOT_HEAD, SLOT_NECK, SLOT_NECK, SLOT_EARS_LEFT, SLOT_EARS_RIGHT) //skyrat edit
|
||||
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,43 +652,43 @@
|
||||
|
||||
/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"
|
||||
//skyrat edit
|
||||
if(SLOT_EARS_LEFT)
|
||||
// Sandstorm edit
|
||||
if(ITEM_SLOT_EARS_LEFT)
|
||||
return "Left ear"
|
||||
if(SLOT_EARS_RIGHT)
|
||||
if(ITEM_SLOT_EARS_RIGHT)
|
||||
return "Right ear"
|
||||
if(SLOT_W_UNDERWEAR)
|
||||
if(ITEM_SLOT_UNDERWEAR)
|
||||
return "Underwear"
|
||||
if(SLOT_W_SOCKS)
|
||||
if(ITEM_SLOT_SOCKS)
|
||||
return "Socks"
|
||||
if(SLOT_W_SHIRT)
|
||||
if(ITEM_SLOT_SHIRT)
|
||||
return "Shirt"
|
||||
if(SLOT_WRISTS)
|
||||
if(ITEM_SLOT_WRISTS)
|
||||
return "Wrist"
|
||||
//
|
||||
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)
|
||||
|
||||
@@ -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))
|
||||
|
||||
@@ -16,6 +16,8 @@ GLOBAL_LIST_EMPTY(singularities) //list of all singularities on the stati
|
||||
GLOBAL_LIST_EMPTY(grounding_rods) //list of all grounding rods on the station
|
||||
|
||||
GLOBAL_LIST(chemical_reactions_list) //list of all /datum/chemical_reaction datums. Used during chemical reactions
|
||||
GLOBAL_LIST(drink_reactions_list) //list of all /datum/chemical_reaction datums where the output is of type /datum/reagent/consumable for bartender PDA
|
||||
GLOBAL_LIST(normalized_chemical_reactions_list) //list of all /datum/chemical_reaction datums with actual sane indexing for chemistry PDA
|
||||
GLOBAL_LIST(chemical_reagents_list) //list of all /datum/reagent datums indexed by reagent id. Used by chemistry stuff
|
||||
GLOBAL_LIST_EMPTY(tech_list) //list of all /datum/tech datums indexed by id.
|
||||
GLOBAL_LIST_EMPTY(surgeries_list) //list of all surgeries by name, associated with their path.
|
||||
|
||||
@@ -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()
|
||||
|
||||
@@ -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()
|
||||
|
||||
|
||||
|
||||
@@ -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()
|
||||
|
||||
@@ -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()
|
||||
|
||||
@@ -17,23 +17,23 @@
|
||||
if(usr.hud_used.inventory_shown && targetmob.hud_used)
|
||||
usr.hud_used.inventory_shown = FALSE
|
||||
usr.client.screen -= targetmob.hud_used.toggleable_inventory
|
||||
//SKYRAT EDIT
|
||||
// Sandstorm edit
|
||||
usr.client.screen -= targetmob.hud_used.extra_inventory
|
||||
//SKYRAT EDIT END
|
||||
// Sandstorm edit END
|
||||
else
|
||||
usr.hud_used.inventory_shown = TRUE
|
||||
usr.client.screen += targetmob.hud_used.toggleable_inventory
|
||||
//SKYRAT EDIT
|
||||
// Sandstorm edit
|
||||
if(usr.hud_used.extra_shown)
|
||||
usr.client.screen += targetmob.hud_used.extra_inventory
|
||||
//SKYRAT EDIT END
|
||||
// Sandstorm edit END
|
||||
|
||||
targetmob.hud_used.hidden_inventory_update(usr)
|
||||
//SKYRAT EDIT
|
||||
// Sandstorm edit
|
||||
targetmob.hud_used.extra_inventory_update(usr)
|
||||
//SKYRAT EDIT END
|
||||
// Sandstorm edit END
|
||||
|
||||
//skyrat edit
|
||||
// Sandstorm edit
|
||||
/atom/movable/screen/human/toggle/extra
|
||||
name = "toggle extra"
|
||||
icon_state = "toggle_extra"
|
||||
@@ -267,7 +267,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
|
||||
@@ -275,7 +275,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
|
||||
@@ -301,7 +301,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()
|
||||
@@ -309,7 +309,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()
|
||||
@@ -317,7 +317,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()
|
||||
@@ -325,7 +325,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()
|
||||
@@ -333,7 +333,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()
|
||||
@@ -341,7 +341,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()
|
||||
@@ -349,7 +349,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()
|
||||
@@ -382,7 +382,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()
|
||||
@@ -390,15 +390,15 @@
|
||||
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()
|
||||
inv_box.name = "left ear" //sandstorm edit
|
||||
inv_box.name = "left ear" // Sandstorm edit
|
||||
inv_box.icon = ui_style
|
||||
inv_box.icon_state = "ears"
|
||||
inv_box.screen_loc = ui_ears
|
||||
inv_box.slot_id = SLOT_EARS_LEFT //skyrat edit
|
||||
inv_box.slot_id = ITEM_SLOT_EARS_LEFT // Sandstorm Edit
|
||||
toggleable_inventory += inv_box
|
||||
|
||||
inv_box = new /atom/movable/screen/inventory()
|
||||
@@ -406,7 +406,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()
|
||||
@@ -414,10 +414,10 @@
|
||||
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
|
||||
|
||||
//skyrat edit
|
||||
// Sandstorm edit
|
||||
using = new /atom/movable/screen/human/toggle/extra()
|
||||
using.icon = ui_style_modular(ui_style)
|
||||
using.screen_loc = ui_inventory_extra
|
||||
@@ -429,7 +429,7 @@
|
||||
inv_box.icon = ui_style_modular(ui_style)
|
||||
inv_box.icon_state = "underwear"
|
||||
inv_box.screen_loc = ui_boxers
|
||||
inv_box.slot_id = SLOT_W_UNDERWEAR //skyrat edit
|
||||
inv_box.slot_id = ITEM_SLOT_UNDERWEAR // Sandstorm edit
|
||||
extra_inventory += inv_box
|
||||
|
||||
inv_box = new /atom/movable/screen/inventory()
|
||||
@@ -437,7 +437,7 @@
|
||||
inv_box.icon = ui_style_modular(ui_style)
|
||||
inv_box.icon_state = "socks"
|
||||
inv_box.screen_loc = ui_socks
|
||||
inv_box.slot_id = SLOT_W_SOCKS //skyrat edit
|
||||
inv_box.slot_id = ITEM_SLOT_SOCKS // Sandstorm edit
|
||||
extra_inventory += inv_box
|
||||
|
||||
inv_box = new /atom/movable/screen/inventory()
|
||||
@@ -445,7 +445,7 @@
|
||||
inv_box.icon = ui_style_modular(ui_style)
|
||||
inv_box.icon_state = "shirt"
|
||||
inv_box.screen_loc = ui_shirt
|
||||
inv_box.slot_id = SLOT_W_SHIRT //skyrat edit
|
||||
inv_box.slot_id = ITEM_SLOT_SHIRT // Sandstorm edit
|
||||
extra_inventory += inv_box
|
||||
|
||||
inv_box = new /atom/movable/screen/inventory()
|
||||
@@ -453,7 +453,7 @@
|
||||
inv_box.icon = ui_style_modular(ui_style)
|
||||
inv_box.icon_state = "ears_extra"
|
||||
inv_box.screen_loc = ui_ears_extra
|
||||
inv_box.slot_id = SLOT_EARS_RIGHT //skyrat edit
|
||||
inv_box.slot_id = ITEM_SLOT_EARS_RIGHT // Sandstorm edit
|
||||
extra_inventory += inv_box
|
||||
|
||||
inv_box = new /atom/movable/screen/inventory()
|
||||
@@ -461,7 +461,7 @@
|
||||
inv_box.icon = ui_style_modular(ui_style)
|
||||
inv_box.icon_state = "wrists"
|
||||
inv_box.screen_loc = ui_wrists
|
||||
inv_box.slot_id = SLOT_WRISTS
|
||||
inv_box.slot_id = ITEM_SLOT_WRISTS
|
||||
extra_inventory += inv_box
|
||||
//
|
||||
|
||||
@@ -471,7 +471,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()
|
||||
@@ -551,10 +551,10 @@
|
||||
zone_select.update_icon()
|
||||
static_inventory += zone_select
|
||||
|
||||
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory + extra_inventory)) //skyrat edit
|
||||
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory + extra_inventory)) // Sandstorm edit
|
||||
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()
|
||||
@@ -611,7 +611,7 @@
|
||||
if(!istype(H) || !H.dna.species)
|
||||
return
|
||||
var/datum/species/S = H.dna.species
|
||||
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory + extra_inventory)) //skyrat edit
|
||||
for(var/atom/movable/screen/inventory/inv in (static_inventory + toggleable_inventory + extra_inventory)) // Sandstorm edit
|
||||
if(inv.slot_id)
|
||||
if(inv.slot_id in S.no_equip)
|
||||
inv.alpha = 128
|
||||
@@ -665,7 +665,7 @@
|
||||
if(H.head) screenmob.client.screen -= H.head
|
||||
|
||||
|
||||
//skyrat edit
|
||||
// Sandstorm edit
|
||||
/datum/hud/human/extra_inventory_update(mob/viewer)
|
||||
if(!mymob)
|
||||
return
|
||||
|
||||
@@ -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()
|
||||
|
||||
@@ -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)
|
||||
|
||||
|
||||
@@ -94,6 +94,10 @@
|
||||
config_entry_value = 10
|
||||
min_val = 0
|
||||
|
||||
/datum/config_entry/keyed_list/dynamic_mode_days
|
||||
key_mode = KEY_MODE_TEXT
|
||||
value_mode = VALUE_MODE_FLAG
|
||||
|
||||
/datum/config_entry/keyed_list/storyteller_weight
|
||||
key_mode = KEY_MODE_TEXT
|
||||
value_mode = VALUE_MODE_NUM
|
||||
|
||||
@@ -348,9 +348,10 @@
|
||||
|
||||
/datum/config_entry/flag/dynamic_config_enabled
|
||||
|
||||
/datum/config_entry/flag/station_name_needs_approval
|
||||
|
||||
//ambition start
|
||||
/datum/config_entry/number/max_ambitions // Maximum number of ambitions a mind can store.
|
||||
config_entry_value = 5
|
||||
//ambition end
|
||||
|
||||
/datum/config_entry/flag/station_name_needs_approval
|
||||
|
||||
@@ -505,7 +505,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]))
|
||||
@@ -715,9 +715,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
|
||||
@@ -754,7 +754,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
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
user_by_item -= target
|
||||
|
||||
/datum/element/earhealing/proc/equippedChanged(datum/source, mob/living/carbon/user, slot)
|
||||
if(((slot == SLOT_EARS_LEFT) || (slot == SLOT_EARS_RIGHT)) && istype(user)) //skyrat edit
|
||||
if(((slot == ITEM_SLOT_EARS_LEFT) || slot == ITEM_SLOT_EARS_RIGHT) && istype(user))
|
||||
user_by_item[source] = user
|
||||
else
|
||||
user_by_item -= source
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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])
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -205,7 +205,7 @@
|
||||
. = LAZYLEN(antag_datums)
|
||||
LAZYADD(antag_datums, instanced_datum)
|
||||
if(!.)
|
||||
current.verbs += /mob/proc/edit_objectives_and_ambitions
|
||||
add_verb(current, /mob/proc/edit_objectives_and_ambitions)
|
||||
//ambition end
|
||||
|
||||
/datum/mind/proc/remove_antag_datum(datum_type)
|
||||
@@ -222,7 +222,7 @@
|
||||
LAZYREMOVE(antag_datums, instanced_datum)
|
||||
if(. && !LAZYLEN(antag_datums))
|
||||
ambitions = null
|
||||
current.verbs -= /mob/proc/edit_objectives_and_ambitions
|
||||
remove_verb(current, /mob/proc/edit_objectives_and_ambitions)
|
||||
//ambition end
|
||||
|
||||
/datum/mind/proc/remove_all_antag_datums() //For the Lazy amongst us.
|
||||
|
||||
@@ -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()))
|
||||
|
||||
@@ -163,42 +163,42 @@
|
||||
|
||||
//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_LEFT, TRUE) //sandstorm edit
|
||||
H.equip_to_slot_or_del(new ears(H), ITEM_SLOT_EARS_LEFT, TRUE) // Sandstorm edit
|
||||
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)
|
||||
//skyrat edit
|
||||
H.equip_to_slot_or_del(new suit_store(H), ITEM_SLOT_SUITSTORE, TRUE)
|
||||
// Sandstorm edit
|
||||
if(ears_extra)
|
||||
H.equip_to_slot_or_del(new ears_extra(H), SLOT_EARS_RIGHT, TRUE)
|
||||
H.equip_to_slot_or_del(new ears_extra(H), ITEM_SLOT_EARS_RIGHT, TRUE)
|
||||
if(underwear)
|
||||
H.equip_to_slot_or_del(new underwear(H), SLOT_W_UNDERWEAR, TRUE)
|
||||
H.equip_to_slot_or_del(new underwear(H), ITEM_SLOT_UNDERWEAR, TRUE)
|
||||
if(socks)
|
||||
H.equip_to_slot_or_del(new socks(H), SLOT_W_SOCKS, TRUE)
|
||||
H.equip_to_slot_or_del(new socks(H), ITEM_SLOT_SOCKS, TRUE)
|
||||
if(shirt)
|
||||
H.equip_to_slot_or_del(new shirt(H), SLOT_W_SHIRT, TRUE)
|
||||
H.equip_to_slot_or_del(new shirt(H), ITEM_SLOT_SHIRT, TRUE)
|
||||
if(wrists)
|
||||
H.equip_to_slot_or_del(new wrists(H), SLOT_WRISTS, TRUE)
|
||||
H.equip_to_slot_or_del(new wrists(H), ITEM_SLOT_WRISTS, TRUE)
|
||||
//
|
||||
|
||||
if(accessory)
|
||||
@@ -215,9 +215,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)
|
||||
@@ -231,7 +231,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
|
||||
|
||||
@@ -130,7 +130,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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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()
|
||||
|
||||
|
||||
@@ -174,7 +174,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()
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
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", "w_underwear", "w_socks", "w_shirt", "shoes", "belt", "gloves", "glasses", "ears", "ears_extra", "wear_id", "s_store")) //skyrat edit
|
||||
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, "w_underwear" = SLOT_W_UNDERWEAR, "w_socks" = SLOT_W_SOCKS, "w_shirt" = SLOT_W_SHIRT, "ears_extra" = SLOT_EARS_RIGHT, "shoes" = SLOT_SHOES, "belt" = SLOT_BELT, "gloves" = SLOT_GLOVES, "glasses" = SLOT_GLASSES, "ears" = SLOT_EARS_LEFT, "wear_id" = SLOT_WEAR_ID, "s_store" = SLOT_S_STORE, "wrists" = SLOT_WRISTS)) //skyrat edit
|
||||
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, "w_underwear" = /obj/item/changeling, "w_socks" = /obj/item/changeling, "w_shirt" = /obj/item/changeling, "ears_extra" = /obj/item/changeling, "wrists" = /obj/item/changeling)) //skyrat edit
|
||||
GLOBAL_LIST_INIT(slots, list("head", "wear_mask", "back", "wear_suit", "w_uniform", "w_underwear", "w_socks", "w_shirt", "shoes", "belt", "gloves", "glasses", "ears", "ears_extra", "wear_id", "s_store")) // Sandstorm edit
|
||||
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, "w_underwear" = ITEM_SLOT_UNDERWEAR, "w_socks" = ITEM_SLOT_SOCKS, "w_shirt" = ITEM_SLOT_SHIRT, "ears_extra" = ITEM_SLOT_EARS_RIGHT, "shoes" = ITEM_SLOT_FEET, "belt" = ITEM_SLOT_BELT, "gloves" = ITEM_SLOT_GLOVES, "glasses" = ITEM_SLOT_EYES, "ears" = ITEM_SLOT_EARS_LEFT, "wear_id" = ITEM_SLOT_ID, "s_store" = ITEM_SLOT_SUITSTORE, "wrists" = ITEM_SLOT_WRISTS)) // Sandstorm edit
|
||||
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
|
||||
|
||||
|
||||
|
||||
@@ -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")
|
||||
|
||||
@@ -37,24 +37,24 @@
|
||||
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)
|
||||
|
||||
//skyrat edit
|
||||
if(!H.w_shirt || H.dropItemToGround(H.w_shirt))
|
||||
C = new /obj/item/clothing/underwear/shirt/clown(H)
|
||||
ADD_TRAIT(C, TRAIT_NODROP, CLOWN_NUKE_TRAIT)
|
||||
H.equip_to_slot_or_del(C, SLOT_W_SHIRT)
|
||||
H.equip_to_slot_or_del(C, ITEM_SLOT_SHIRT)
|
||||
//
|
||||
|
||||
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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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,\
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
|
||||
@@ -52,23 +52,30 @@
|
||||
|
||||
/obj/machinery/limbgrower/ui_data(mob/user)
|
||||
var/list/data = list()
|
||||
|
||||
for(var/datum/reagent/reagent_id in reagents.reagent_list)
|
||||
var/list/reagent_data = list(
|
||||
reagent_name = reagent_id.name,
|
||||
reagent_amount = reagent_id.volume,
|
||||
reagent_type = reagent_id.type
|
||||
)
|
||||
data["reagents"] += list(reagent_data)
|
||||
|
||||
if(reagents.reagent_list.len)
|
||||
for(var/datum/reagent/reagent_id in reagents.reagent_list)
|
||||
var/list/reagent_data = list(
|
||||
reagent_name = reagent_id.name,
|
||||
reagent_amount = reagent_id.volume,
|
||||
reagent_type = reagent_id.type
|
||||
)
|
||||
data["reagents"] += list(reagent_data)
|
||||
else
|
||||
data["reagents"] = list()
|
||||
data["total_reagents"] = reagents.total_volume
|
||||
data["max_reagents"] = reagents.maximum_volume
|
||||
data["busy"] = busy
|
||||
var/list/disk_data = list()
|
||||
disk_data["disk"] = dna_disk //Do i, the machine, have a disk?
|
||||
disk_data["name"] = dna_disk?.fields["name"] //Name for the human saved if there is one
|
||||
if(dna_disk)
|
||||
if(dna_disk.fields["name"])
|
||||
disk_data["name"] = dna_disk.fields["name"]
|
||||
else if(dna_disk.genetic_makeup_buffer["name"])
|
||||
disk_data["name"] = dna_disk.genetic_makeup_buffer["name"]
|
||||
else
|
||||
disk_data["name"] = "No name"
|
||||
//Name for the human saved if there is one
|
||||
data["disk"] = disk_data
|
||||
|
||||
return data
|
||||
|
||||
/obj/machinery/limbgrower/ui_static_data(mob/user)
|
||||
@@ -119,6 +126,18 @@
|
||||
if (busy)
|
||||
to_chat(user, "<span class=\"alert\">\The [src] is busy. Please wait for completion of previous operation.</span>")
|
||||
return
|
||||
if(ispath(user_item.type, /obj/item/reagent_containers/blood) && user.a_intent != INTENT_HARM)
|
||||
var/obj/item/reagent_containers/blood/B = user_item
|
||||
if(!B.reagents.get_reagents())
|
||||
to_chat(user, "<span class=\"alert\">You can't fill [src] with an empty [B.name]!</span>")
|
||||
return
|
||||
if(reagents.total_volume == reagents.maximum_volume)
|
||||
to_chat(user, "<span class=\"alert\">\The [src] can't hold more blood!</span>")
|
||||
return
|
||||
user.visible_message("<span class='notice'>[user] drains the [user_item] into [src] using the blood bag port on [src].</span>",
|
||||
"You drain the [user_item] into [src] using the blood bag port.")
|
||||
B.reagents.trans_to(src, B.amount_per_transfer_from_this)
|
||||
return
|
||||
|
||||
if(default_deconstruction_screwdriver(user, "limbgrower_panelopen", "limbgrower_idleoff", user_item))
|
||||
ui_close(user)
|
||||
@@ -180,7 +199,7 @@
|
||||
for(var/reagent_id in consumed_reagents_list)
|
||||
consumed_reagents_list[reagent_id] *= production_coefficient
|
||||
if(!reagents.has_reagent(reagent_id, consumed_reagents_list[reagent_id]))
|
||||
audible_message("<span class='notice'>\The [src] buzzes.</span>")
|
||||
audible_message("<span class='warning'>\The [src] buzzes and states \"INSUFFICENT REAGENTS\"</span>")
|
||||
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, FALSE)
|
||||
return
|
||||
|
||||
@@ -206,17 +225,13 @@
|
||||
* modified_consumed_reagents_list - the list of reagents we will consume on build, modified by the production coefficient.
|
||||
*/
|
||||
/obj/machinery/limbgrower/proc/build_item(list/modified_consumed_reagents_list)
|
||||
for(var/reagent_id in modified_consumed_reagents_list)
|
||||
if(!reagents.has_reagent(reagent_id, modified_consumed_reagents_list[reagent_id]))
|
||||
audible_message("<span class='notice'>\The [src] buzzes.</span>")
|
||||
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, FALSE)
|
||||
break
|
||||
|
||||
reagents.remove_reagent(reagent_id, modified_consumed_reagents_list[reagent_id])
|
||||
|
||||
reagent_usage(modified_consumed_reagents_list)
|
||||
var/built_typepath = being_built.build_path
|
||||
// If we have a bodypart, we need to initialize the limb on its own. Otherwise we can build it here.
|
||||
if(ispath(built_typepath, /obj/item/bodypart))
|
||||
if(ispath(built_typepath, /mob/living/carbon/human/chestonly))
|
||||
if(!build_mob_chest(built_typepath, FALSE))
|
||||
reagent_usage(modified_consumed_reagents_list, FALSE)
|
||||
else if(ispath(built_typepath, /obj/item/bodypart))
|
||||
build_limb(built_typepath)
|
||||
else if(ispath(built_typepath, /obj/item/organ/genital)) //genitals are uhh... customizable
|
||||
build_genital(built_typepath)
|
||||
@@ -227,6 +242,25 @@
|
||||
flick("limbgrower_unfill", src)
|
||||
icon_state = "limbgrower_idleoff"
|
||||
|
||||
/obj/machinery/limbgrower/proc/reagent_usage(modified_consumed_reagents_list, remove = TRUE)
|
||||
// Apparently, having a boolean in a loop is worse than doing it twice
|
||||
if(remove)
|
||||
for(var/reagent_id in modified_consumed_reagents_list)
|
||||
if(reagent_sanity_check(reagent_id, modified_consumed_reagents_list[reagent_id]))
|
||||
reagents.remove_reagent(reagent_id, modified_consumed_reagents_list[reagent_id])
|
||||
else
|
||||
for(var/reagent_id in modified_consumed_reagents_list)
|
||||
if(reagent_sanity_check(reagent_id, modified_consumed_reagents_list[reagent_id]))
|
||||
reagents.add_reagent(reagent_id, modified_consumed_reagents_list[reagent_id])
|
||||
|
||||
|
||||
/obj/machinery/limbgrower/proc/reagent_sanity_check(reagent_id, amount)
|
||||
if(reagents.has_reagent(reagent_id, amount))
|
||||
return TRUE
|
||||
audible_message("<span class='warning'>\The [src] buzzes, with a screen showing: INSUFFICENT REAGENTS</span>")
|
||||
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, FALSE)
|
||||
return FALSE
|
||||
|
||||
/*
|
||||
* The process of putting together a limb.
|
||||
* This is called from after we remove the reagents, so this proc is just initializing the limb type.
|
||||
@@ -318,6 +352,53 @@
|
||||
else
|
||||
new built_typepath(loc)
|
||||
|
||||
/obj/machinery/limbgrower/proc/build_mob_chest(built_typepath)
|
||||
// Create a mob with a chest, but nothing else
|
||||
if(!ispath(built_typepath, /mob/living/carbon/human/chestonly))
|
||||
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, FALSE)
|
||||
visible_message(src, "Buzzes, an error screen appearing on its display.")
|
||||
return FALSE
|
||||
// Fields is from cloning, a much fuller scan, genetic_makeup_buffer is less so
|
||||
var/dna_genetics = dna_disk?.genetic_makeup_buffer
|
||||
var/dna_cloning = dna_disk?.fields
|
||||
var/datum/species/selected = GLOB.species_datums[selected_category]
|
||||
var/mob/living/carbon/human/chestonly/C = new(loc)
|
||||
C.real_name = length(dna_genetics) ? dna_genetics["name"] : "Synthetic Humanoid #[rand(10000, 99999)]"
|
||||
if(length(dna_cloning))
|
||||
C.hardset_dna(dna_cloning["UI"], dna_cloning["SE"], dna_cloning["name"], dna_cloning["blood_type"], dna_cloning["mrace"], dna_cloning["features"])
|
||||
else if(length(dna_genetics))
|
||||
C.hardset_dna(dna_genetics["UI"], null, dna_genetics["name"], dna_genetics["blood_type"])
|
||||
else
|
||||
C.real_name = "Synthetic Humanoid #[rand(10000, 99999)]"
|
||||
C.hair_style = "bald"
|
||||
C.skin_tone = "albino"
|
||||
C.set_species(selected)
|
||||
C.set_resting(TRUE, TRUE)
|
||||
// Don't want to cause it to deathgasp..
|
||||
C.stat = DEAD
|
||||
C.adjustOxyLoss(200)
|
||||
// Limb replacement causes toxloss, which can cause too much suffering for the doctor that I don't want
|
||||
C.adjustCloneLoss(45)
|
||||
C.med_hud_set_status()
|
||||
C.med_hud_set_health()
|
||||
C.underwear = "Nude"
|
||||
C.undershirt = "Nude"
|
||||
C.saved_underwear = ""
|
||||
C.saved_undershirt = ""
|
||||
|
||||
// Just enough to start reviving them, I hope
|
||||
C.blood_volume = BLOOD_VOLUME_SURVIVE
|
||||
// At some point, make a way to deal with species regenerate_organs
|
||||
// Remove all the organs
|
||||
for(var/organ in C.internal_organs)
|
||||
var/obj/item/organ/O = organ
|
||||
O.Remove(organ)
|
||||
C.update_body(TRUE)
|
||||
C.update_hair()
|
||||
C.update_body_parts()
|
||||
C.update_appearance()
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/limbgrower/RefreshParts()
|
||||
reagents.maximum_volume = 0
|
||||
for(var/obj/item/reagent_containers/glass/our_beaker in component_parts)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -829,7 +829,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)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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)
|
||||
|
||||
|
||||
@@ -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()
|
||||
|
||||
|
||||
@@ -369,6 +369,10 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=Toggle Door'>[PDAIMG(rdoor)]Toggle Remote Door</a></li>"
|
||||
if (cartridge.access & CART_DRONEPHONE)
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=Drone Phone'>[PDAIMG(dronephone)]Drone Phone</a></li>"
|
||||
if (cartridge.access & CART_BARTENDER)
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=Drink Recipe Browser'>[PDAIMG(bucket)]Drink Recipe Browser</a></li>"
|
||||
if (cartridge.access & CART_CHEMISTRY)
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=Chemistry Recipe Browser'>[PDAIMG(bucket)]Chemistry Recipe Browser</a></li>"
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=3'>[PDAIMG(atmos)]Atmospheric Scan</a></li>"
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=Light'>[PDAIMG(flashlight)][fon ? "Disable" : "Enable"] Flashlight</a></li>"
|
||||
if (pai)
|
||||
@@ -705,6 +709,16 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
if(T)
|
||||
pai.forceMove(T)
|
||||
|
||||
//DRINK RECIPE BROWSER=============================
|
||||
if("Drink Recipe Browser")
|
||||
if(cartridge && cartridge.access & CART_BARTENDER)
|
||||
recipe_search(U, GLOB.drink_reactions_list)
|
||||
|
||||
//CHEMISTRY RECIPE BROWSER
|
||||
if("Chemistry Recipe Browser")
|
||||
if(cartridge && cartridge.access & CART_CHEMISTRY)
|
||||
recipe_search(U, GLOB.normalized_chemical_reactions_list)
|
||||
|
||||
//LINK FUNCTIONS===================================
|
||||
|
||||
else//Cartridge menu linking
|
||||
|
||||
@@ -222,6 +222,7 @@
|
||||
/obj/item/pda/bar
|
||||
name = "bartender PDA"
|
||||
icon_state = "pda-bartender"
|
||||
default_cartridge = /obj/item/cartridge/bartender
|
||||
inserted_item = /obj/item/pen/fountain
|
||||
|
||||
/obj/item/pda/atmos
|
||||
|
||||
@@ -13,6 +13,8 @@
|
||||
#define CART_QUARTERMASTER (1<<12)
|
||||
#define CART_HYDROPONICS (1<<13)
|
||||
#define CART_DRONEPHONE (1<<14)
|
||||
#define CART_BARTENDER (1<<15)
|
||||
#define CART_CHEMISTRY (1<<16)
|
||||
|
||||
|
||||
/obj/item/cartridge
|
||||
@@ -77,7 +79,7 @@
|
||||
/obj/item/cartridge/chemistry
|
||||
name = "\improper ChemWhiz cartridge"
|
||||
icon_state = "cart-chem"
|
||||
access = CART_REAGENT_SCANNER
|
||||
access = CART_REAGENT_SCANNER | CART_CHEMISTRY
|
||||
bot_access_flags = MED_BOT
|
||||
|
||||
/obj/item/cartridge/security
|
||||
@@ -190,6 +192,12 @@
|
||||
bot_access_flags = SEC_BOT | MULE_BOT | FLOOR_BOT | CLEAN_BOT | MED_BOT | FIRE_BOT
|
||||
spam_enabled = 1
|
||||
|
||||
/obj/item/cartridge/bartender
|
||||
name = "\improper B.O.O.Z.E cartridge"
|
||||
desc = "Now with 12% alcohol!"
|
||||
icon_state = "cart-bar"
|
||||
access = CART_BARTENDER
|
||||
|
||||
/obj/item/cartridge/captain/New()
|
||||
..()
|
||||
radio = new(src)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -158,7 +158,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 ..()
|
||||
@@ -169,7 +169,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
|
||||
|
||||
@@ -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_LEFT, SLOT_EARS_RIGHT)) //skyrat edit
|
||||
AddComponent(/datum/component/wearertargeting/earprotection, list(ITEM_SLOT_EARS_LEFT, ITEM_SLOT_EARS_RIGHT))
|
||||
|
||||
/obj/item/radio/headset/Initialize()
|
||||
. = ..()
|
||||
@@ -377,4 +377,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_LEFT, SLOT_EARS_RIGHT)) //skyrat edit
|
||||
AddComponent(/datum/component/wearertargeting/earprotection, list(ITEM_SLOT_EARS_LEFT, ITEM_SLOT_EARS_RIGHT))
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -434,7 +434,7 @@ GENETICS SCANNER
|
||||
if(R)
|
||||
blood_type = R.name
|
||||
|
||||
|
||||
|
||||
if((C.scan_blood_volume() + C.integrating_blood) <= (BLOOD_VOLUME_SAFE * C.blood_ratio) && (C.scan_blood_volume() + C.integrating_blood) > (BLOOD_VOLUME_OKAY*C.blood_ratio))
|
||||
msg += "<span class='danger'>LOW [HAS_TRAIT(C, TRAIT_ROBOTIC_ORGANISM) ? "coolant" : "blood"] level [blood_percent] %, [C.scan_blood_volume()] cl[C.integrating_blood? ", with [integrated_blood_percent] % of it integrating, [C.integrating_blood] cl " : ""].</span> <span class='info'>type: [blood_type]</span>\n"
|
||||
else if((C.scan_blood_volume() + C.integrating_blood) <= (BLOOD_VOLUME_OKAY * C.blood_ratio))
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
// 1) Tennis balls, lines 39 - 99
|
||||
// 2) Chew bones, lines 101 - 138
|
||||
// 3) Frisbee, lines 140 - 166
|
||||
*/
|
||||
*/
|
||||
|
||||
/obj/item/toy/fluff
|
||||
name = "Fluff Item"
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -1232,7 +1232,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301
|
||||
|
||||
/obj/item/slapper/on_offered(mob/living/carbon/offerer)
|
||||
. = TRUE
|
||||
|
||||
|
||||
if(!(locate(/mob/living/carbon) in orange(1, offerer)))
|
||||
visible_message(span_danger("[offerer] raises [offerer.p_their()] arm, looking around for a high-five, but there's no one around!"), \
|
||||
span_warning("You post up, looking for a high-five, but finding no one within range!"), null, 2)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -25,10 +25,9 @@
|
||||
to_chat(usr, "<span class='warning'>You seem to be selecting a mob that doesn't exist anymore.</span>", confidential = TRUE)
|
||||
return
|
||||
|
||||
//SKYRAT CHANGES BEGIN
|
||||
//ambition start
|
||||
var/list/body = list("<html><head><meta http-equiv='Content-Type' content='text/html; charset=UTF-8'><title>Options for [M.key]</title></head>")
|
||||
//SKYRAT CHANGES END
|
||||
|
||||
//ambition end
|
||||
body += "<body>Options panel for <b>[M]</b>"
|
||||
if(M.client)
|
||||
body += " played by <b>[M.client]</b> "
|
||||
@@ -218,12 +217,11 @@
|
||||
body += "<br>"
|
||||
body += "</body></html>"
|
||||
|
||||
//SKYRAT CHANGES BEGIN
|
||||
//ambition start
|
||||
var/datum/browser/popup = new(usr, "adminplayeropts-[REF(M)]", "Player Panel", nwidth = 550, nheight = 515)
|
||||
popup.set_content(body.Join())
|
||||
popup.open()
|
||||
//SKYRAT CHANGES END
|
||||
|
||||
//ambition end
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "Player Panel") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
|
||||
|
||||
68
code/modules/admin/playtimes.dm
Normal file
68
code/modules/admin/playtimes.dm
Normal file
@@ -0,0 +1,68 @@
|
||||
/datum/player_playtime/New(mob/viewer)
|
||||
ui_interact(viewer)
|
||||
|
||||
/datum/player_playtime/ui_interact(mob/user, datum/tgui/ui)
|
||||
ui = SStgui.try_update_ui(user, src, ui)
|
||||
if(!ui)
|
||||
ui = new(user, src, "PlayerPlaytimes", "Player Playtimes")
|
||||
ui.open()
|
||||
|
||||
/datum/player_playtime/ui_state(mob/user)
|
||||
return GLOB.admin_state
|
||||
|
||||
/datum/player_playtime/ui_data(mob/user)
|
||||
var/list/data = list()
|
||||
|
||||
var/list/clients = list()
|
||||
for(var/client/C in GLOB.clients)
|
||||
var/list/client = list()
|
||||
|
||||
client["ckey"] = C.ckey
|
||||
client["playtime"] = C.get_exp_living(TRUE)
|
||||
client["playtime_hours"] = C.get_exp_living()
|
||||
|
||||
var/mob/M = C.mob
|
||||
client["observer"] = isobserver(M)
|
||||
client["ingame"] = !isnewplayer(M)
|
||||
client["name"] = M.real_name
|
||||
var/nnpa = CONFIG_GET(number/notify_new_player_age)
|
||||
if(nnpa >= 0)
|
||||
if(C.account_age >= 0 && (C.account_age < CONFIG_GET(number/notify_new_player_age)))
|
||||
client["new_account"] = "New BYOND account [C.account_age] day[(C.account_age==1?"":"s")] old, created on [C.account_join_date]"
|
||||
|
||||
clients += list(client)
|
||||
|
||||
clients = sortList(clients, /proc/cmp_playtime)
|
||||
data["clients"] = clients
|
||||
return data
|
||||
|
||||
/datum/player_playtime/ui_act(action, params)
|
||||
if(..())
|
||||
return
|
||||
|
||||
switch(action)
|
||||
if("view_playtime")
|
||||
var/mob/target = get_mob_by_ckey(params["ckey"])
|
||||
usr.client.holder.cmd_show_exp_panel(target.client)
|
||||
if("admin_pm")
|
||||
usr.client.cmd_admin_pm(params["ckey"])
|
||||
if("player_panel")
|
||||
var/mob/target = get_mob_by_ckey(params["ckey"])
|
||||
usr.client.holder.show_player_panel(target)
|
||||
if("view_variables")
|
||||
var/mob/target = get_mob_by_ckey(params["ckey"])
|
||||
usr.client.debug_variables(target)
|
||||
if("observe")
|
||||
if(!isobserver(usr) && !check_rights(R_ADMIN))
|
||||
return
|
||||
|
||||
var/mob/target = get_mob_by_key(params["ckey"])
|
||||
if(!target)
|
||||
to_chat(usr, "<span class='notice'>Player not found.</span>")
|
||||
return
|
||||
|
||||
var/client/C = usr.client
|
||||
if(!isobserver(usr) && !C.admin_ghost())
|
||||
return
|
||||
var/mob/dead/observer/A = C.mob
|
||||
A.ManualFollow(target)
|
||||
@@ -1704,8 +1704,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))
|
||||
|
||||
@@ -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")
|
||||
|
||||
@@ -1633,6 +1633,19 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
log_game("[key_name(usr)] triggered a CentCom recall, with the message of: [message]")
|
||||
SSshuttle.centcom_recall(SSshuttle.emergency.timer, message)
|
||||
|
||||
/client/proc/cmd_admin_check_player_exp() //Allows admins to determine who the newer players are.
|
||||
set category = "Admin"
|
||||
set name = "Player Playtime"
|
||||
|
||||
if(!check_rights(R_ADMIN))
|
||||
return
|
||||
|
||||
if(!CONFIG_GET(flag/use_exp_tracking))
|
||||
to_chat(usr, "<span class='warning'>Tracking is disabled in the server configuration file.</span>")
|
||||
return
|
||||
|
||||
new /datum/player_playtime(usr)
|
||||
|
||||
/obj/effect/temp_visual/fireball
|
||||
icon = 'icons/obj/wizard.dmi'
|
||||
icon_state = "fireball"
|
||||
|
||||
@@ -50,6 +50,10 @@ GLOBAL_LIST_EMPTY(antagonists)
|
||||
var/show_name_in_check_antagonists = FALSE
|
||||
/// Should this antagonist be shown as antag to ghosts? Shouldn't be used for stealthy antagonists like traitors
|
||||
var/show_to_ghosts = FALSE
|
||||
//ambition start
|
||||
/// Lazy list for antagonists to request the admins objectives.
|
||||
var/list/requested_objective_changes
|
||||
//ambition end
|
||||
|
||||
/* CIT SPECIFIC */
|
||||
/// Quirks that will be removed upon gaining this antag. Pacifist and mute are default.
|
||||
@@ -59,11 +63,6 @@ GLOBAL_LIST_EMPTY(antagonists)
|
||||
|
||||
var/delete_on_mind_deletion = TRUE
|
||||
|
||||
//ambition start
|
||||
/// Lazy list for antagonists to request the admins objectives.
|
||||
var/list/requested_objective_changes
|
||||
//ambition end
|
||||
|
||||
var/list/skill_modifiers
|
||||
/* CIT SPECIFIC end */
|
||||
|
||||
@@ -83,7 +82,9 @@ GLOBAL_LIST_EMPTY(antagonists)
|
||||
if(!owner)
|
||||
stack_trace("Destroy()ing antagonist datum when it has no owner.")
|
||||
else
|
||||
//ambition start
|
||||
owner?.do_remove_antag_datum(src)
|
||||
//ambition end
|
||||
owner = null
|
||||
return ..()
|
||||
|
||||
@@ -486,35 +487,6 @@ GLOBAL_LIST_EMPTY(antagonists)
|
||||
return
|
||||
..()
|
||||
|
||||
///Clears change requests from deleted objectives to avoid broken references.
|
||||
/datum/antagonist/proc/clean_request_from_del_objective(datum/objective/source, force)
|
||||
var/objective_reference = REF(source)
|
||||
for(var/uid in requested_objective_changes)
|
||||
var/list/change_request = requested_objective_changes[uid]
|
||||
if(change_request["target"] != objective_reference)
|
||||
continue
|
||||
LAZYREMOVE(requested_objective_changes, uid)
|
||||
|
||||
|
||||
/datum/antagonist/proc/add_objective_change(uid, list/additions)
|
||||
LAZYADD(requested_objective_changes, uid)
|
||||
var/datum/objective/request_target = additions["target"]
|
||||
if(!ispath(request_target))
|
||||
request_target = locate(request_target) in objectives
|
||||
if(istype(request_target))
|
||||
RegisterSignal(request_target, COMSIG_PARENT_QDELETING, .proc/clean_request_from_del_objective)
|
||||
requested_objective_changes[uid] = additions
|
||||
|
||||
|
||||
/datum/antagonist/proc/remove_objective_change(uid)
|
||||
if(!LAZYACCESS(requested_objective_changes, uid))
|
||||
return
|
||||
var/datum/objective/request_target = requested_objective_changes[uid]["target"]
|
||||
if(!ispath(request_target))
|
||||
request_target = locate(request_target) in objectives
|
||||
if(istype(request_target))
|
||||
UnregisterSignal(request_target, COMSIG_PARENT_QDELETING)
|
||||
LAZYREMOVE(requested_objective_changes, uid)
|
||||
///ANTAGONIST UI STUFF
|
||||
|
||||
/datum/antagonist/ui_interact(mob/user, datum/tgui/ui)
|
||||
@@ -559,3 +531,33 @@ GLOBAL_LIST_EMPTY(antagonists)
|
||||
|
||||
/datum/action/antag_info/IsAvailable()
|
||||
return TRUE
|
||||
|
||||
///Clears change requests from deleted objectives to avoid broken references.
|
||||
/datum/antagonist/proc/clean_request_from_del_objective(datum/objective/source, force)
|
||||
var/objective_reference = REF(source)
|
||||
for(var/uid in requested_objective_changes)
|
||||
var/list/change_request = requested_objective_changes[uid]
|
||||
if(change_request["target"] != objective_reference)
|
||||
continue
|
||||
LAZYREMOVE(requested_objective_changes, uid)
|
||||
|
||||
|
||||
/datum/antagonist/proc/add_objective_change(uid, list/additions)
|
||||
LAZYADD(requested_objective_changes, uid)
|
||||
var/datum/objective/request_target = additions["target"]
|
||||
if(!ispath(request_target))
|
||||
request_target = locate(request_target) in objectives
|
||||
if(istype(request_target))
|
||||
RegisterSignal(request_target, COMSIG_PARENT_QDELETING, .proc/clean_request_from_del_objective)
|
||||
requested_objective_changes[uid] = additions
|
||||
|
||||
|
||||
/datum/antagonist/proc/remove_objective_change(uid)
|
||||
if(!LAZYACCESS(requested_objective_changes, uid))
|
||||
return
|
||||
var/datum/objective/request_target = requested_objective_changes[uid]["target"]
|
||||
if(!ispath(request_target))
|
||||
request_target = locate(request_target) in objectives
|
||||
if(istype(request_target))
|
||||
UnregisterSignal(request_target, COMSIG_PARENT_QDELETING)
|
||||
LAZYREMOVE(requested_objective_changes, uid)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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>", \
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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>")
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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
|
||||
|
||||
|
||||
@@ -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>" )
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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))
|
||||
|
||||
@@ -98,9 +98,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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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"
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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_LEFT) //skyrat edit
|
||||
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_LEFT) // Sandstorm edit
|
||||
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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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"
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -211,17 +211,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_LEFT) //skyrat edit
|
||||
H.equip_to_slot_or_del(new master_mob.ears.type, ITEM_SLOT_EARS_LEFT) // Sandstorm edit
|
||||
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))
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user