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