mirror of
https://github.com/KabKebab/GS13.git
synced 2026-07-12 16:38:18 +01:00
Update with master
This commit is contained in:
@@ -66,6 +66,7 @@
|
||||
#define ACCESS_CLONING 68 //Cloning room and clone pod ejection
|
||||
#define ACCESS_ENTER_GENPOP 69
|
||||
#define ACCESS_LEAVE_GENPOP 70
|
||||
#define ACCESS_PSYCH 71
|
||||
|
||||
//BEGIN CENTCOM ACCESS
|
||||
/*Should leave plenty of room if we need to add more access levels.
|
||||
|
||||
@@ -63,6 +63,7 @@
|
||||
#define ADMIN_VERBOSEJMP(src) "[src ? "[AREACOORD(src)] [ADMIN_JMP(src)]" : "nonexistent location"]"
|
||||
#define ADMIN_INDIVIDUALLOG(user) "(<a href='?_src_=holder;[HrefToken(TRUE)];individuallog=[REF(user)]'>LOGS</a>)"
|
||||
|
||||
#define ADMIN_PUNISHMENT_ROLEPLAY "Roleplay Warning"
|
||||
#define ADMIN_PUNISHMENT_LIGHTNING "Lightning bolt"
|
||||
#define ADMIN_PUNISHMENT_BRAINDAMAGE "Brain damage"
|
||||
#define ADMIN_PUNISHMENT_GIB "Gib"
|
||||
@@ -70,6 +71,7 @@
|
||||
#define ADMIN_PUNISHMENT_FIREBALL "Fireball"
|
||||
#define ADMIN_PUNISHMENT_CLUWNE "Floor Cluwne"
|
||||
#define ADMIN_PUNISHMENT_ROD "Immovable Rod"
|
||||
#define ADMIN_PUNISHMENT_SUPPLYPOD_QUICK "Supply Pod (Quick)"
|
||||
#define ADMIN_PUNISHMENT_SUPPLYPOD "Supply Pod"
|
||||
#define ADMIN_PUNISHMENT_MAZING "Puzzle"
|
||||
#define ADMIN_PUNISHMENT_PIE "Cream Pie"
|
||||
@@ -77,6 +79,7 @@
|
||||
#define ADMIN_PUNISHMENT_FAKEBWOINK "Fake Bwoink"
|
||||
#define ADMIN_PUNISHMENT_NUGGET "Nugget"
|
||||
#define ADMIN_PUNISHMENT_BREADIFY ":b:read"
|
||||
#define ADMIN_PUNISHMENT_BOOKIFY "Bookify"
|
||||
|
||||
#define AHELP_ACTIVE 1
|
||||
#define AHELP_CLOSED 2
|
||||
@@ -93,3 +96,4 @@
|
||||
#define MAX_KEYPRESS_AUTOKICK 100
|
||||
///Length of held key rolling buffer
|
||||
#define HELD_KEY_BUFFER_LENGTH 15
|
||||
|
||||
|
||||
+316
-309
@@ -1,309 +1,316 @@
|
||||
//LISTMOS
|
||||
//indices of values in gas lists.
|
||||
#define META_GAS_SPECIFIC_HEAT 1
|
||||
#define META_GAS_NAME 2
|
||||
#define META_GAS_MOLES_VISIBLE 3
|
||||
#define META_GAS_OVERLAY 4
|
||||
#define META_GAS_DANGER 5
|
||||
#define META_GAS_ID 6
|
||||
#define META_GAS_FUSION_POWER 7
|
||||
//ATMOS
|
||||
//stuff you should probably leave well alone!
|
||||
#define R_IDEAL_GAS_EQUATION 8.31 //kPa*L/(K*mol)
|
||||
#define ONE_ATMOSPHERE 101.325 //kPa
|
||||
#define TCMB 2.7 // -270.3degC
|
||||
#define TCRYO 225 // -48.15degC
|
||||
#define T0C 273.15 // 0degC
|
||||
#define T20C 293.15 // 20degC
|
||||
|
||||
#define MOLES_CELLSTANDARD (ONE_ATMOSPHERE*CELL_VOLUME/(T20C*R_IDEAL_GAS_EQUATION)) //moles in a 2.5 m^3 cell at 101.325 Pa and 20 degC
|
||||
#define M_CELL_WITH_RATIO (MOLES_CELLSTANDARD * 0.005) //compared against for superconductivity
|
||||
#define O2STANDARD 0.21 //percentage of oxygen in a normal mixture of air
|
||||
#define N2STANDARD 0.79 //same but for nitrogen
|
||||
#define MOLES_O2STANDARD (MOLES_CELLSTANDARD*O2STANDARD) // O2 standard value (21%)
|
||||
#define MOLES_N2STANDARD (MOLES_CELLSTANDARD*N2STANDARD) // N2 standard value (79%)
|
||||
#define CELL_VOLUME 2500 //liters in a cell
|
||||
#define BREATH_VOLUME 0.5 //liters in a normal breath
|
||||
#define BREATH_PERCENTAGE (BREATH_VOLUME/CELL_VOLUME) //Amount of air to take a from a tile
|
||||
|
||||
//EXCITED GROUPS
|
||||
#define EXCITED_GROUP_BREAKDOWN_CYCLES 4 //number of FULL air controller ticks before an excited group breaks down (averages gas contents across turfs)
|
||||
#define EXCITED_GROUP_DISMANTLE_CYCLES 16 //number of FULL air controller ticks before an excited group dismantles and removes its turfs from active
|
||||
#define MINIMUM_AIR_RATIO_TO_SUSPEND 0.1 //Ratio of air that must move to/from a tile to reset group processing
|
||||
#define MINIMUM_AIR_RATIO_TO_MOVE 0.001 //Minimum ratio of air that must move to/from a tile
|
||||
#define MINIMUM_AIR_TO_SUSPEND (MOLES_CELLSTANDARD*MINIMUM_AIR_RATIO_TO_SUSPEND) //Minimum amount of air that has to move before a group processing can be suspended
|
||||
#define MINIMUM_MOLES_DELTA_TO_MOVE (MOLES_CELLSTANDARD*MINIMUM_AIR_RATIO_TO_MOVE) //Either this must be active
|
||||
#define MINIMUM_TEMPERATURE_TO_MOVE (T20C+100) //or this (or both, obviously)
|
||||
#define MINIMUM_TEMPERATURE_DELTA_TO_SUSPEND 4 //Minimum temperature difference before group processing is suspended
|
||||
#define MINIMUM_TEMPERATURE_DELTA_TO_CONSIDER 0.5 //Minimum temperature difference before the gas temperatures are just set to be equal
|
||||
#define MINIMUM_TEMPERATURE_FOR_SUPERCONDUCTION (T20C+10)
|
||||
#define MINIMUM_TEMPERATURE_START_SUPERCONDUCTION (T20C+200)
|
||||
|
||||
//HEAT TRANSFER COEFFICIENTS
|
||||
//Must be between 0 and 1. Values closer to 1 equalize temperature faster
|
||||
//Should not exceed 0.4 else strange heat flow occur
|
||||
#define WALL_HEAT_TRANSFER_COEFFICIENT 0.0
|
||||
#define OPEN_HEAT_TRANSFER_COEFFICIENT 0.4
|
||||
#define WINDOW_HEAT_TRANSFER_COEFFICIENT 0.1 //a hack for now
|
||||
#define HEAT_CAPACITY_VACUUM 7000 //a hack to help make vacuums "cold", sacrificing realism for gameplay
|
||||
|
||||
//FIRE
|
||||
#define FIRE_MINIMUM_TEMPERATURE_TO_SPREAD (150+T0C)
|
||||
#define FIRE_MINIMUM_TEMPERATURE_TO_EXIST (100+T0C)
|
||||
#define FIRE_SPREAD_RADIOSITY_SCALE 0.85
|
||||
#define FIRE_GROWTH_RATE 40000 //For small fires
|
||||
#define PLASMA_MINIMUM_BURN_TEMPERATURE (100+T0C)
|
||||
#define PLASMA_UPPER_TEMPERATURE (1370+T0C)
|
||||
#define PLASMA_OXYGEN_FULLBURN 10
|
||||
|
||||
//GASES
|
||||
#define MIN_TOXIC_GAS_DAMAGE 1
|
||||
#define MAX_TOXIC_GAS_DAMAGE 10
|
||||
#define MOLES_GAS_VISIBLE 0.25 //Moles in a standard cell after which gases are visible
|
||||
#define FACTOR_GAS_VISIBLE_MAX 20 //moles_visible * FACTOR_GAS_VISIBLE_MAX = Moles after which gas is at maximum visibility
|
||||
#define MOLES_GAS_VISIBLE_STEP 0.25 //Mole step for alpha updates. This means alpha can update at 0.25, 0.5, 0.75 and so on
|
||||
|
||||
//REACTIONS
|
||||
//return values for reactions (bitflags)
|
||||
#define NO_REACTION 0
|
||||
#define REACTING 1
|
||||
#define STOP_REACTIONS 2
|
||||
|
||||
// Pressure limits.
|
||||
#define HAZARD_HIGH_PRESSURE 550 //This determins at what pressure the ultra-high pressure red icon is displayed. (This one is set as a constant)
|
||||
#define WARNING_HIGH_PRESSURE 325 //This determins when the orange pressure icon is displayed (it is 0.7 * HAZARD_HIGH_PRESSURE)
|
||||
#define WARNING_LOW_PRESSURE 50 //This is when the gray low pressure icon is displayed. (it is 2.5 * HAZARD_LOW_PRESSURE)
|
||||
#define HAZARD_LOW_PRESSURE 20 //This is when the black ultra-low pressure icon is displayed. (This one is set as a constant)
|
||||
|
||||
#define TEMPERATURE_DAMAGE_COEFFICIENT 1.5 //This is used in handle_temperature_damage() for humans, and in reagents that affect body temperature. Temperature damage is multiplied by this amount.
|
||||
|
||||
#define BODYTEMP_NORMAL 310.15 //The natural temperature for a body
|
||||
#define BODYTEMP_AUTORECOVERY_DIVISOR 11 //This is the divisor which handles how much of the temperature difference between the current body temperature and 310.15K (optimal temperature) humans auto-regenerate each tick. The higher the number, the slower the recovery. This is applied each tick, so long as the mob is alive.
|
||||
#define BODYTEMP_AUTORECOVERY_MINIMUM 12 //Minimum amount of kelvin moved toward 310K per tick. So long as abs(310.15 - bodytemp) is more than 50.
|
||||
#define BODYTEMP_COLD_DIVISOR 6 //Similar to the BODYTEMP_AUTORECOVERY_DIVISOR, but this is the divisor which is applied at the stage that follows autorecovery. This is the divisor which comes into play when the human's loc temperature is lower than their body temperature. Make it lower to lose bodytemp faster.
|
||||
#define BODYTEMP_HEAT_DIVISOR 15 //Similar to the BODYTEMP_AUTORECOVERY_DIVISOR, but this is the divisor which is applied at the stage that follows autorecovery. This is the divisor which comes into play when the human's loc temperature is higher than their body temperature. Make it lower to gain bodytemp faster.
|
||||
#define BODYTEMP_COOLING_MAX -100 //The maximum number of degrees that your body can cool in 1 tick, due to the environment, when in a cold area.
|
||||
#define BODYTEMP_HEATING_MAX 30 //The maximum number of degrees that your body can heat up in 1 tick, due to the environment, when in a hot area.
|
||||
|
||||
#define BODYTEMP_HEAT_DAMAGE_LIMIT (BODYTEMP_NORMAL + 20) // The limit the human body can take before it starts taking damage from heat. //CITADEL EDIT to 20
|
||||
#define BODYTEMP_COLD_DAMAGE_LIMIT (BODYTEMP_NORMAL - 50) // The limit the human body can take before it starts taking damage from coldness.
|
||||
|
||||
|
||||
#define SPACE_HELM_MIN_TEMP_PROTECT 2.0 //what min_cold_protection_temperature is set to for space-helmet quality headwear. MUST NOT BE 0.
|
||||
#define SPACE_HELM_MAX_TEMP_PROTECT 1500 //Thermal insulation works both ways /Malkevin
|
||||
#define SPACE_SUIT_MIN_TEMP_PROTECT 2.0 //what min_cold_protection_temperature is set to for space-suit quality jumpsuits or suits. MUST NOT BE 0.
|
||||
#define SPACE_SUIT_MAX_TEMP_PROTECT 1500
|
||||
|
||||
#define FIRE_SUIT_MIN_TEMP_PROTECT 60 //Cold protection for firesuits
|
||||
#define FIRE_SUIT_MAX_TEMP_PROTECT 30000 //what max_heat_protection_temperature is set to for firesuit quality suits. MUST NOT BE 0.
|
||||
#define FIRE_HELM_MIN_TEMP_PROTECT 60 //Cold protection for fire helmets
|
||||
#define FIRE_HELM_MAX_TEMP_PROTECT 30000 //for fire helmet quality items (red and white hardhats)
|
||||
|
||||
#define FIRE_IMMUNITY_MAX_TEMP_PROTECT 35000 //what max_heat_protection_temperature is set to for firesuit quality suits and helmets. MUST NOT BE 0.
|
||||
|
||||
#define HELMET_MIN_TEMP_PROTECT 160 //For normal helmets
|
||||
#define HELMET_MAX_TEMP_PROTECT 600 //For normal helmets
|
||||
#define ARMOR_MIN_TEMP_PROTECT 160 //For armor
|
||||
#define ARMOR_MAX_TEMP_PROTECT 600 //For armor
|
||||
|
||||
#define GLOVES_MIN_TEMP_PROTECT 2.0 //For some gloves (black and)
|
||||
#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 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.
|
||||
#define LOW_PRESSURE_DAMAGE 8 //The amount of damage someone takes when in a low pressure area (The pressure threshold is so low that it doesn't make sense to do any calculations, so it just applies this flat value).
|
||||
|
||||
#define COLD_SLOWDOWN_FACTOR 20 //Humans are slowed by the difference between bodytemp and BODYTEMP_COLD_DAMAGE_LIMIT divided by this
|
||||
|
||||
//PIPES
|
||||
//Atmos pipe limits
|
||||
#define MAX_OUTPUT_PRESSURE 4500 // (kPa) What pressure pumps and powered equipment max out at.
|
||||
#define MAX_TRANSFER_RATE 200 // (L/s) Maximum speed powered equipment can work at.
|
||||
#define VOLUME_PUMP_LEAK_AMOUNT 0.05 //5% of an overclocked volume pump leaks into the air
|
||||
#define VOLUME_PUMP_THRESHOLD_LEAK_AMOUNT 0.10 //10% of an overclocked volume pump leaks into the air if it goes beyond normal threshold
|
||||
|
||||
//used for device_type vars
|
||||
#define UNARY 1
|
||||
#define BINARY 2
|
||||
#define TRINARY 3
|
||||
#define QUATERNARY 4
|
||||
|
||||
//TANKS
|
||||
#define TANK_MELT_TEMPERATURE 1000000 //temperature in kelvins at which a tank will start to melt
|
||||
#define TANK_LEAK_PRESSURE (30.*ONE_ATMOSPHERE) //Tank starts leaking
|
||||
#define TANK_RUPTURE_PRESSURE (35.*ONE_ATMOSPHERE) //Tank spills all contents into atmosphere
|
||||
#define TANK_FRAGMENT_PRESSURE (40.*ONE_ATMOSPHERE) //Boom 3x3 base explosion
|
||||
#define TANK_FRAGMENT_SCALE (6.*ONE_ATMOSPHERE) //+1 for each SCALE kPa aboe threshold
|
||||
#define TANK_MAX_RELEASE_PRESSURE (ONE_ATMOSPHERE*3)
|
||||
#define TANK_MIN_RELEASE_PRESSURE 0
|
||||
#define TANK_DEFAULT_RELEASE_PRESSURE 16
|
||||
|
||||
//CANATMOSPASS
|
||||
#define ATMOS_PASS_YES 1
|
||||
#define ATMOS_PASS_NO 0
|
||||
#define ATMOS_PASS_PROC -1 //ask CanAtmosPass()
|
||||
#define ATMOS_PASS_DENSITY -2 //just check density
|
||||
|
||||
#define CANATMOSPASS(A, O) ( A.CanAtmosPass == ATMOS_PASS_PROC ? A.CanAtmosPass(O) : ( A.CanAtmosPass == ATMOS_PASS_DENSITY ? !A.density : A.CanAtmosPass ) )
|
||||
#define CANVERTICALATMOSPASS(A, O) ( A.CanAtmosPassVertical == ATMOS_PASS_PROC ? A.CanAtmosPass(O, TRUE) : ( A.CanAtmosPassVertical == ATMOS_PASS_DENSITY ? !A.density : A.CanAtmosPassVertical ) )
|
||||
|
||||
//OPEN TURF ATMOS
|
||||
#define OPENTURF_DEFAULT_ATMOS "o2=22;n2=82;TEMP=293.15" //the default air mix that open turfs spawn
|
||||
#define TCOMMS_ATMOS "n2=100;TEMP=80" //-193,15degC telecommunications. also used for xenobiology slime killrooms
|
||||
#define AIRLESS_ATMOS "TEMP=2.7" //space
|
||||
#define FROZEN_ATMOS "o2=22;n2=82;TEMP=180" //-93.15degC snow and ice turfs
|
||||
#define BURNMIX_ATMOS "o2=2500;plasma=5000;TEMP=370" //used in the holodeck burn test program
|
||||
|
||||
//LAVALAND
|
||||
#define LAVALAND_EQUIPMENT_EFFECT_PRESSURE 50 //what pressure you have to be under to increase the effect of equipment meant for lavaland
|
||||
#define LAVALAND_DEFAULT_ATMOS "o2=14;n2=23;TEMP=300"
|
||||
|
||||
//ATMOSIA GAS MONITOR TAGS
|
||||
#define ATMOS_GAS_MONITOR_INPUT_O2 "o2_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_O2 "o2_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_O2 "o2_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_TOX "tox_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_TOX "tox_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_TOX "tox_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_AIR "air_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_AIR "air_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_AIR "air_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_MIX "mix_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_MIX "mix_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_MIX "mix_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_N2O "n2o_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_N2O "n2o_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_N2O "n2o_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_N2 "n2_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_N2 "n2_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_N2 "n2_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_CO2 "co2_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_CO2 "co2_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_CO2 "co2_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_INCINERATOR "incinerator_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_INCINERATOR "incinerator_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_INCINERATOR "incinerator_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_TOXINS_LAB "toxinslab_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_TOXINS_LAB "toxinslab_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_TOXINS_LAB "toxinslab_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_LOOP_DISTRIBUTION "distro-loop_meter"
|
||||
#define ATMOS_GAS_MONITOR_LOOP_ATMOS_WASTE "atmos-waste_loop_meter"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_WASTE_ENGINE "engine-waste_out"
|
||||
#define ATMOS_GAS_MONITOR_WASTE_ATMOS "atmos-waste_out"
|
||||
|
||||
//AIRLOCK CONTROLLER TAGS
|
||||
|
||||
//RnD toxins burn chamber
|
||||
#define INCINERATOR_TOXMIX_IGNITER "toxmix_igniter"
|
||||
#define INCINERATOR_TOXMIX_VENT "toxmix_vent"
|
||||
#define INCINERATOR_TOXMIX_DP_VENTPUMP "toxmix_airlock_pump"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_SENSOR "toxmix_airlock_sensor"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_CONTROLLER "toxmix_airlock_controller"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_INTERIOR "toxmix_airlock_interior"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_EXTERIOR "toxmix_airlock_exterior"
|
||||
|
||||
//Atmospherics/maintenance incinerator
|
||||
#define INCINERATOR_ATMOS_IGNITER "atmos_incinerator_igniter"
|
||||
#define INCINERATOR_ATMOS_MAINVENT "atmos_incinerator_mainvent"
|
||||
#define INCINERATOR_ATMOS_AUXVENT "atmos_incinerator_auxvent"
|
||||
#define INCINERATOR_ATMOS_DP_VENTPUMP "atmos_incinerator_airlock_pump"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_SENSOR "atmos_incinerator_airlock_sensor"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_CONTROLLER "atmos_incinerator_airlock_controller"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_INTERIOR "atmos_incinerator_airlock_interior"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_EXTERIOR "atmos_incinerator_airlock_exterior"
|
||||
|
||||
//Syndicate lavaland base incinerator (lavaland_surface_syndicate_base1.dmm)
|
||||
#define INCINERATOR_SYNDICATELAVA_IGNITER "syndicatelava_igniter"
|
||||
#define INCINERATOR_SYNDICATELAVA_MAINVENT "syndicatelava_mainvent"
|
||||
#define INCINERATOR_SYNDICATELAVA_AUXVENT "syndicatelava_auxvent"
|
||||
#define INCINERATOR_SYNDICATELAVA_DP_VENTPUMP "syndicatelava_airlock_pump"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_SENSOR "syndicatelava_airlock_sensor"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_CONTROLLER "syndicatelava_airlock_controller"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_INTERIOR "syndicatelava_airlock_interior"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_EXTERIOR "syndicatelava_airlock_exterior"
|
||||
|
||||
//MULTIPIPES
|
||||
//IF YOU EVER CHANGE THESE CHANGE SPRITES TO MATCH.
|
||||
#define PIPING_LAYER_MIN 1
|
||||
#define PIPING_LAYER_MAX 3
|
||||
#define PIPING_LAYER_DEFAULT 2
|
||||
#define PIPING_LAYER_P_X 5
|
||||
#define PIPING_LAYER_P_Y 5
|
||||
#define PIPING_LAYER_LCHANGE 0.05
|
||||
|
||||
#define PIPING_ALL_LAYER (1<<0) //intended to connect with all layers, check for all instead of just one.
|
||||
#define PIPING_ONE_PER_TURF (1<<1) //can only be built if nothing else with this flag is on the tile already.
|
||||
#define PIPING_DEFAULT_LAYER_ONLY (1<<2) //can only exist at PIPING_LAYER_DEFAULT
|
||||
#define PIPING_CARDINAL_AUTONORMALIZE (1<<3) //north/south east/west doesn't matter, auto normalize on build.
|
||||
|
||||
//HELPERS
|
||||
#define PIPING_LAYER_SHIFT(T, PipingLayer) \
|
||||
if(T.dir & NORTH || T.dir & SOUTH) { \
|
||||
T.pixel_x = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_X;\
|
||||
} \
|
||||
if(T.dir & WEST || T.dir & EAST) { \
|
||||
T.pixel_y = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_Y;\
|
||||
}
|
||||
|
||||
#define PIPING_LAYER_DOUBLE_SHIFT(T, PipingLayer) \
|
||||
T.pixel_x = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_X;\
|
||||
T.pixel_y = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_Y;
|
||||
|
||||
#define THERMAL_ENERGY(gas) (gas.temperature * gas.heat_capacity())
|
||||
|
||||
#define QUANTIZE(variable) (round(variable,0.0000001))/*I feel the need to document what happens here. Basically this is used to catch most rounding errors, however it's previous value made it so that
|
||||
once gases got hot enough, most procedures wouldnt occur due to the fact that the mole counts would get rounded away. Thus, we lowered it a few orders of magnititude */
|
||||
|
||||
//prefer this to gas_mixture/total_moles in performance critical areas
|
||||
#define TOTAL_MOLES(cached_gases, out_var)\
|
||||
out_var = 0;\
|
||||
for(var/total_moles_id in cached_gases){\
|
||||
out_var += cached_gases[total_moles_id];\
|
||||
}
|
||||
|
||||
#ifdef TESTING
|
||||
GLOBAL_LIST_INIT(atmos_adjacent_savings, list(0,0))
|
||||
#define CALCULATE_ADJACENT_TURFS(T) if (SSadjacent_air.queue[T]) { GLOB.atmos_adjacent_savings[1] += 1 } else { GLOB.atmos_adjacent_savings[2] += 1; SSadjacent_air.queue[T] = 1 }
|
||||
#else
|
||||
#define CALCULATE_ADJACENT_TURFS(T) SSadjacent_air.queue[T] = 1
|
||||
#endif
|
||||
|
||||
//Unomos - So for whatever reason, garbage collection actually drastically decreases the cost of atmos later in the round. Turning this into a define yields massively improved performance.
|
||||
#define GAS_GARBAGE_COLLECT(GASGASGAS)\
|
||||
var/list/CACHE_GAS = GASGASGAS;\
|
||||
for(var/id in CACHE_GAS){\
|
||||
if(QUANTIZE(CACHE_GAS[id]) <= 0)\
|
||||
CACHE_GAS -= id;\
|
||||
}
|
||||
|
||||
#define ARCHIVE_TEMPERATURE(gas) gas.temperature_archived = gas.temperature
|
||||
|
||||
GLOBAL_LIST_INIT(pipe_paint_colors, list(
|
||||
"amethyst" = rgb(130,43,255), //supplymain
|
||||
"blue" = rgb(0,0,255),
|
||||
"brown" = rgb(178,100,56),
|
||||
"cyan" = rgb(0,255,249),
|
||||
"dark" = rgb(69,69,69),
|
||||
"green" = rgb(30,255,0),
|
||||
"grey" = rgb(255,255,255),
|
||||
"orange" = rgb(255,129,25),
|
||||
"purple" = rgb(128,0,182),
|
||||
"red" = rgb(255,0,0),
|
||||
"violet" = rgb(64,0,128),
|
||||
"yellow" = rgb(255,198,0)
|
||||
))
|
||||
|
||||
#define MIASMA_CORPSE_MOLES 0.02
|
||||
#define MIASMA_GIBS_MOLES 0.005
|
||||
//LISTMOS
|
||||
//indices of values in gas lists.
|
||||
#define META_GAS_SPECIFIC_HEAT 1
|
||||
#define META_GAS_NAME 2
|
||||
#define META_GAS_MOLES_VISIBLE 3
|
||||
#define META_GAS_OVERLAY 4
|
||||
#define META_GAS_DANGER 5
|
||||
#define META_GAS_ID 6
|
||||
#define META_GAS_FUSION_POWER 7
|
||||
//ATMOS
|
||||
//stuff you should probably leave well alone!
|
||||
#define R_IDEAL_GAS_EQUATION 8.31 //kPa*L/(K*mol)
|
||||
#define ONE_ATMOSPHERE 101.325 //kPa
|
||||
#define TCMB 2.7 // -270.3degC
|
||||
#define TCRYO 225 // -48.15degC
|
||||
#define T0C 273.15 // 0degC
|
||||
#define T20C 293.15 // 20degC
|
||||
|
||||
#define MOLES_CELLSTANDARD (ONE_ATMOSPHERE*CELL_VOLUME/(T20C*R_IDEAL_GAS_EQUATION)) //moles in a 2.5 m^3 cell at 101.325 Pa and 20 degC
|
||||
#define M_CELL_WITH_RATIO (MOLES_CELLSTANDARD * 0.005) //compared against for superconductivity
|
||||
#define O2STANDARD 0.21 //percentage of oxygen in a normal mixture of air
|
||||
#define N2STANDARD 0.79 //same but for nitrogen
|
||||
#define MOLES_O2STANDARD (MOLES_CELLSTANDARD*O2STANDARD) // O2 standard value (21%)
|
||||
#define MOLES_N2STANDARD (MOLES_CELLSTANDARD*N2STANDARD) // N2 standard value (79%)
|
||||
#define CELL_VOLUME 2500 //liters in a cell
|
||||
#define BREATH_VOLUME 0.5 //liters in a normal breath
|
||||
#define BREATH_PERCENTAGE (BREATH_VOLUME/CELL_VOLUME) //Amount of air to take a from a tile
|
||||
|
||||
//EXCITED GROUPS
|
||||
#define EXCITED_GROUP_BREAKDOWN_CYCLES 4 //number of FULL air controller ticks before an excited group breaks down (averages gas contents across turfs)
|
||||
#define EXCITED_GROUP_DISMANTLE_CYCLES 16 //number of FULL air controller ticks before an excited group dismantles and removes its turfs from active
|
||||
#define MINIMUM_AIR_RATIO_TO_SUSPEND 0.1 //Ratio of air that must move to/from a tile to reset group processing
|
||||
#define MINIMUM_AIR_RATIO_TO_MOVE 0.001 //Minimum ratio of air that must move to/from a tile
|
||||
#define MINIMUM_AIR_TO_SUSPEND (MOLES_CELLSTANDARD*MINIMUM_AIR_RATIO_TO_SUSPEND) //Minimum amount of air that has to move before a group processing can be suspended
|
||||
#define MINIMUM_MOLES_DELTA_TO_MOVE (MOLES_CELLSTANDARD*MINIMUM_AIR_RATIO_TO_MOVE) //Either this must be active
|
||||
#define MINIMUM_TEMPERATURE_TO_MOVE (T20C+100) //or this (or both, obviously)
|
||||
#define MINIMUM_TEMPERATURE_DELTA_TO_SUSPEND 4 //Minimum temperature difference before group processing is suspended
|
||||
#define MINIMUM_TEMPERATURE_DELTA_TO_CONSIDER 0.5 //Minimum temperature difference before the gas temperatures are just set to be equal
|
||||
#define MINIMUM_TEMPERATURE_FOR_SUPERCONDUCTION (T20C+10)
|
||||
#define MINIMUM_TEMPERATURE_START_SUPERCONDUCTION (T20C+200)
|
||||
|
||||
//HEAT TRANSFER COEFFICIENTS
|
||||
//Must be between 0 and 1. Values closer to 1 equalize temperature faster
|
||||
//Should not exceed 0.4 else strange heat flow occur
|
||||
#define WALL_HEAT_TRANSFER_COEFFICIENT 0.0
|
||||
#define OPEN_HEAT_TRANSFER_COEFFICIENT 0.4
|
||||
#define WINDOW_HEAT_TRANSFER_COEFFICIENT 0.1 //a hack for now
|
||||
#define HEAT_CAPACITY_VACUUM 7000 //a hack to help make vacuums "cold", sacrificing realism for gameplay
|
||||
|
||||
//FIRE
|
||||
#define FIRE_MINIMUM_TEMPERATURE_TO_SPREAD (150+T0C)
|
||||
#define FIRE_MINIMUM_TEMPERATURE_TO_EXIST (100+T0C)
|
||||
#define FIRE_SPREAD_RADIOSITY_SCALE 0.85
|
||||
#define FIRE_GROWTH_RATE 40000 //For small fires
|
||||
#define PLASMA_MINIMUM_BURN_TEMPERATURE (100+T0C)
|
||||
#define PLASMA_UPPER_TEMPERATURE (1370+T0C)
|
||||
#define PLASMA_OXYGEN_FULLBURN 10
|
||||
|
||||
//GASES
|
||||
#define MIN_TOXIC_GAS_DAMAGE 1
|
||||
#define MAX_TOXIC_GAS_DAMAGE 10
|
||||
#define MOLES_GAS_VISIBLE 0.25 //Moles in a standard cell after which gases are visible
|
||||
#define FACTOR_GAS_VISIBLE_MAX 20 //moles_visible * FACTOR_GAS_VISIBLE_MAX = Moles after which gas is at maximum visibility
|
||||
#define MOLES_GAS_VISIBLE_STEP 0.25 //Mole step for alpha updates. This means alpha can update at 0.25, 0.5, 0.75 and so on
|
||||
|
||||
//REACTIONS
|
||||
//return values for reactions (bitflags)
|
||||
#define NO_REACTION 0
|
||||
#define REACTING 1
|
||||
#define STOP_REACTIONS 2
|
||||
|
||||
// Pressure limits.
|
||||
#define HAZARD_HIGH_PRESSURE 550 //This determins at what pressure the ultra-high pressure red icon is displayed. (This one is set as a constant)
|
||||
#define WARNING_HIGH_PRESSURE 325 //This determins when the orange pressure icon is displayed (it is 0.7 * HAZARD_HIGH_PRESSURE)
|
||||
#define WARNING_LOW_PRESSURE 50 //This is when the gray low pressure icon is displayed. (it is 2.5 * HAZARD_LOW_PRESSURE)
|
||||
#define HAZARD_LOW_PRESSURE 20 //This is when the black ultra-low pressure icon is displayed. (This one is set as a constant)
|
||||
|
||||
#define TEMPERATURE_DAMAGE_COEFFICIENT 1.5 //This is used in handle_temperature_damage() for humans, and in reagents that affect body temperature. Temperature damage is multiplied by this amount.
|
||||
|
||||
#define BODYTEMP_NORMAL 310.15 //The natural temperature for a body
|
||||
#define BODYTEMP_AUTORECOVERY_DIVISOR 11 //This is the divisor which handles how much of the temperature difference between the current body temperature and 310.15K (optimal temperature) humans auto-regenerate each tick. The higher the number, the slower the recovery. This is applied each tick, so long as the mob is alive.
|
||||
#define BODYTEMP_AUTORECOVERY_MINIMUM 12 //Minimum amount of kelvin moved toward 310K per tick. So long as abs(310.15 - bodytemp) is more than 50.
|
||||
#define BODYTEMP_COLD_DIVISOR 6 //Similar to the BODYTEMP_AUTORECOVERY_DIVISOR, but this is the divisor which is applied at the stage that follows autorecovery. This is the divisor which comes into play when the human's loc temperature is lower than their body temperature. Make it lower to lose bodytemp faster.
|
||||
#define BODYTEMP_HEAT_DIVISOR 15 //Similar to the BODYTEMP_AUTORECOVERY_DIVISOR, but this is the divisor which is applied at the stage that follows autorecovery. This is the divisor which comes into play when the human's loc temperature is higher than their body temperature. Make it lower to gain bodytemp faster.
|
||||
#define BODYTEMP_COOLING_MAX -100 //The maximum number of degrees that your body can cool in 1 tick, due to the environment, when in a cold area.
|
||||
#define BODYTEMP_HEATING_MAX 30 //The maximum number of degrees that your body can heat up in 1 tick, due to the environment, when in a hot area.
|
||||
|
||||
#define BODYTEMP_HEAT_DAMAGE_LIMIT (BODYTEMP_NORMAL + 20) // The limit the human body can take before it starts taking damage from heat. //CITADEL EDIT to 20
|
||||
#define BODYTEMP_COLD_DAMAGE_LIMIT (BODYTEMP_NORMAL - 50) // The limit the human body can take before it starts taking damage from coldness.
|
||||
|
||||
|
||||
#define SPACE_HELM_MIN_TEMP_PROTECT 2.0 //what min_cold_protection_temperature is set to for space-helmet quality headwear. MUST NOT BE 0.
|
||||
#define SPACE_HELM_MAX_TEMP_PROTECT 1500 //Thermal insulation works both ways /Malkevin
|
||||
#define SPACE_SUIT_MIN_TEMP_PROTECT 2.0 //what min_cold_protection_temperature is set to for space-suit quality jumpsuits or suits. MUST NOT BE 0.
|
||||
#define SPACE_SUIT_MAX_TEMP_PROTECT 1500
|
||||
|
||||
#define FIRE_SUIT_MIN_TEMP_PROTECT 60 //Cold protection for firesuits
|
||||
#define FIRE_SUIT_MAX_TEMP_PROTECT 30000 //what max_heat_protection_temperature is set to for firesuit quality suits. MUST NOT BE 0.
|
||||
#define FIRE_HELM_MIN_TEMP_PROTECT 60 //Cold protection for fire helmets
|
||||
#define FIRE_HELM_MAX_TEMP_PROTECT 30000 //for fire helmet quality items (red and white hardhats)
|
||||
|
||||
#define FIRE_IMMUNITY_MAX_TEMP_PROTECT 35000 //what max_heat_protection_temperature is set to for firesuit quality suits and helmets. MUST NOT BE 0.
|
||||
|
||||
#define HELMET_MIN_TEMP_PROTECT 160 //For normal helmets
|
||||
#define HELMET_MAX_TEMP_PROTECT 600 //For normal helmets
|
||||
#define ARMOR_MIN_TEMP_PROTECT 160 //For armor
|
||||
#define ARMOR_MAX_TEMP_PROTECT 600 //For armor
|
||||
|
||||
#define GLOVES_MIN_TEMP_PROTECT 2.0 //For some gloves (black and)
|
||||
#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 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.
|
||||
#define LOW_PRESSURE_DAMAGE 8 //The amount of damage someone takes when in a low pressure area (The pressure threshold is so low that it doesn't make sense to do any calculations, so it just applies this flat value).
|
||||
|
||||
#define COLD_SLOWDOWN_FACTOR 20 //Humans are slowed by the difference between bodytemp and BODYTEMP_COLD_DAMAGE_LIMIT divided by this
|
||||
|
||||
//PIPES
|
||||
//Atmos pipe limits
|
||||
#define MAX_OUTPUT_PRESSURE 4500 // (kPa) What pressure pumps and powered equipment max out at.
|
||||
#define MAX_TRANSFER_RATE 200 // (L/s) Maximum speed powered equipment can work at.
|
||||
#define VOLUME_PUMP_LEAK_AMOUNT 0.05 //5% of an overclocked volume pump leaks into the air
|
||||
#define VOLUME_PUMP_THRESHOLD_LEAK_AMOUNT 0.10 //10% of an overclocked volume pump leaks into the air if it goes beyond normal threshold
|
||||
|
||||
//used for device_type vars
|
||||
#define UNARY 1
|
||||
#define BINARY 2
|
||||
#define TRINARY 3
|
||||
#define QUATERNARY 4
|
||||
|
||||
//TANKS
|
||||
#define TANK_MELT_TEMPERATURE 1000000 //temperature in kelvins at which a tank will start to melt
|
||||
#define TANK_LEAK_PRESSURE (30.*ONE_ATMOSPHERE) //Tank starts leaking
|
||||
#define TANK_RUPTURE_PRESSURE (35.*ONE_ATMOSPHERE) //Tank spills all contents into atmosphere
|
||||
#define TANK_FRAGMENT_PRESSURE (40.*ONE_ATMOSPHERE) //Boom 3x3 base explosion
|
||||
#define TANK_FRAGMENT_SCALE (6.*ONE_ATMOSPHERE) //+1 for each SCALE kPa aboe threshold
|
||||
#define TANK_MAX_RELEASE_PRESSURE (ONE_ATMOSPHERE*3)
|
||||
#define TANK_MIN_RELEASE_PRESSURE 0
|
||||
#define TANK_DEFAULT_RELEASE_PRESSURE 16
|
||||
|
||||
//CANATMOSPASS
|
||||
#define ATMOS_PASS_YES 1
|
||||
#define ATMOS_PASS_NO 0
|
||||
#define ATMOS_PASS_PROC -1 //ask CanAtmosPass()
|
||||
#define ATMOS_PASS_DENSITY -2 //just check density
|
||||
|
||||
#define CANATMOSPASS(A, O) ( A.CanAtmosPass == ATMOS_PASS_PROC ? A.CanAtmosPass(O) : ( A.CanAtmosPass == ATMOS_PASS_DENSITY ? !A.density : A.CanAtmosPass ) )
|
||||
#define CANVERTICALATMOSPASS(A, O) ( A.CanAtmosPassVertical == ATMOS_PASS_PROC ? A.CanAtmosPass(O, TRUE) : ( A.CanAtmosPassVertical == ATMOS_PASS_DENSITY ? !A.density : A.CanAtmosPassVertical ) )
|
||||
|
||||
//OPEN TURF ATMOS
|
||||
#define OPENTURF_DEFAULT_ATMOS "o2=22;n2=82;TEMP=293.15" //the default air mix that open turfs spawn
|
||||
#define TCOMMS_ATMOS "n2=100;TEMP=80" //-193,15degC telecommunications. also used for xenobiology slime killrooms
|
||||
#define AIRLESS_ATMOS "TEMP=2.7" //space
|
||||
#define FROZEN_ATMOS "o2=22;n2=82;TEMP=180" //-93.15degC snow and ice turfs
|
||||
#define BURNMIX_ATMOS "o2=2500;plasma=5000;TEMP=370" //used in the holodeck burn test program
|
||||
|
||||
//ATMOSPHERICS DEPARTMENT GAS TANK TURFS
|
||||
#define ATMOS_TANK_N2O "n2o=6000;TEMP=293.15"
|
||||
#define ATMOS_TANK_CO2 "co2=50000;TEMP=293.15"
|
||||
#define ATMOS_TANK_PLASMA "plasma=70000;TEMP=293.15"
|
||||
#define ATMOS_TANK_O2 "o2=100000;TEMP=293.15"
|
||||
#define ATMOS_TANK_N2 "n2=100000;TEMP=293.15"
|
||||
#define ATMOS_TANK_AIRMIX "o2=2644;n2=10580;TEMP=293.15"
|
||||
//LAVALAND
|
||||
#define LAVALAND_EQUIPMENT_EFFECT_PRESSURE 50 //what pressure you have to be under to increase the effect of equipment meant for lavaland
|
||||
#define LAVALAND_DEFAULT_ATMOS "o2=14;n2=23;TEMP=300"
|
||||
|
||||
//ATMOSIA GAS MONITOR TAGS
|
||||
#define ATMOS_GAS_MONITOR_INPUT_O2 "o2_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_O2 "o2_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_O2 "o2_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_TOX "tox_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_TOX "tox_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_TOX "tox_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_AIR "air_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_AIR "air_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_AIR "air_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_MIX "mix_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_MIX "mix_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_MIX "mix_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_N2O "n2o_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_N2O "n2o_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_N2O "n2o_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_N2 "n2_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_N2 "n2_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_N2 "n2_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_CO2 "co2_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_CO2 "co2_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_CO2 "co2_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_INCINERATOR "incinerator_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_INCINERATOR "incinerator_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_INCINERATOR "incinerator_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_INPUT_TOXINS_LAB "toxinslab_in"
|
||||
#define ATMOS_GAS_MONITOR_OUTPUT_TOXINS_LAB "toxinslab_out"
|
||||
#define ATMOS_GAS_MONITOR_SENSOR_TOXINS_LAB "toxinslab_sensor"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_LOOP_DISTRIBUTION "distro-loop_meter"
|
||||
#define ATMOS_GAS_MONITOR_LOOP_ATMOS_WASTE "atmos-waste_loop_meter"
|
||||
|
||||
#define ATMOS_GAS_MONITOR_WASTE_ENGINE "engine-waste_out"
|
||||
#define ATMOS_GAS_MONITOR_WASTE_ATMOS "atmos-waste_out"
|
||||
|
||||
//AIRLOCK CONTROLLER TAGS
|
||||
|
||||
//RnD toxins burn chamber
|
||||
#define INCINERATOR_TOXMIX_IGNITER "toxmix_igniter"
|
||||
#define INCINERATOR_TOXMIX_VENT "toxmix_vent"
|
||||
#define INCINERATOR_TOXMIX_DP_VENTPUMP "toxmix_airlock_pump"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_SENSOR "toxmix_airlock_sensor"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_CONTROLLER "toxmix_airlock_controller"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_INTERIOR "toxmix_airlock_interior"
|
||||
#define INCINERATOR_TOXMIX_AIRLOCK_EXTERIOR "toxmix_airlock_exterior"
|
||||
|
||||
//Atmospherics/maintenance incinerator
|
||||
#define INCINERATOR_ATMOS_IGNITER "atmos_incinerator_igniter"
|
||||
#define INCINERATOR_ATMOS_MAINVENT "atmos_incinerator_mainvent"
|
||||
#define INCINERATOR_ATMOS_AUXVENT "atmos_incinerator_auxvent"
|
||||
#define INCINERATOR_ATMOS_DP_VENTPUMP "atmos_incinerator_airlock_pump"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_SENSOR "atmos_incinerator_airlock_sensor"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_CONTROLLER "atmos_incinerator_airlock_controller"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_INTERIOR "atmos_incinerator_airlock_interior"
|
||||
#define INCINERATOR_ATMOS_AIRLOCK_EXTERIOR "atmos_incinerator_airlock_exterior"
|
||||
|
||||
//Syndicate lavaland base incinerator (lavaland_surface_syndicate_base1.dmm)
|
||||
#define INCINERATOR_SYNDICATELAVA_IGNITER "syndicatelava_igniter"
|
||||
#define INCINERATOR_SYNDICATELAVA_MAINVENT "syndicatelava_mainvent"
|
||||
#define INCINERATOR_SYNDICATELAVA_AUXVENT "syndicatelava_auxvent"
|
||||
#define INCINERATOR_SYNDICATELAVA_DP_VENTPUMP "syndicatelava_airlock_pump"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_SENSOR "syndicatelava_airlock_sensor"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_CONTROLLER "syndicatelava_airlock_controller"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_INTERIOR "syndicatelava_airlock_interior"
|
||||
#define INCINERATOR_SYNDICATELAVA_AIRLOCK_EXTERIOR "syndicatelava_airlock_exterior"
|
||||
|
||||
//MULTIPIPES
|
||||
//IF YOU EVER CHANGE THESE CHANGE SPRITES TO MATCH.
|
||||
#define PIPING_LAYER_MIN 1
|
||||
#define PIPING_LAYER_MAX 3
|
||||
#define PIPING_LAYER_DEFAULT 2
|
||||
#define PIPING_LAYER_P_X 5
|
||||
#define PIPING_LAYER_P_Y 5
|
||||
#define PIPING_LAYER_LCHANGE 0.05
|
||||
|
||||
#define PIPING_ALL_LAYER (1<<0) //intended to connect with all layers, check for all instead of just one.
|
||||
#define PIPING_ONE_PER_TURF (1<<1) //can only be built if nothing else with this flag is on the tile already.
|
||||
#define PIPING_DEFAULT_LAYER_ONLY (1<<2) //can only exist at PIPING_LAYER_DEFAULT
|
||||
#define PIPING_CARDINAL_AUTONORMALIZE (1<<3) //north/south east/west doesn't matter, auto normalize on build.
|
||||
|
||||
//HELPERS
|
||||
#define PIPING_LAYER_SHIFT(T, PipingLayer) \
|
||||
if(T.dir & NORTH || T.dir & SOUTH) { \
|
||||
T.pixel_x = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_X;\
|
||||
} \
|
||||
if(T.dir & WEST || T.dir & EAST) { \
|
||||
T.pixel_y = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_Y;\
|
||||
}
|
||||
|
||||
#define PIPING_LAYER_DOUBLE_SHIFT(T, PipingLayer) \
|
||||
T.pixel_x = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_X;\
|
||||
T.pixel_y = (PipingLayer - PIPING_LAYER_DEFAULT) * PIPING_LAYER_P_Y;
|
||||
|
||||
#define THERMAL_ENERGY(gas) (gas.temperature * gas.heat_capacity())
|
||||
|
||||
#define QUANTIZE(variable) (round(variable,0.0000001))/*I feel the need to document what happens here. Basically this is used to catch most rounding errors, however it's previous value made it so that
|
||||
once gases got hot enough, most procedures wouldnt occur due to the fact that the mole counts would get rounded away. Thus, we lowered it a few orders of magnititude */
|
||||
|
||||
//prefer this to gas_mixture/total_moles in performance critical areas
|
||||
#define TOTAL_MOLES(cached_gases, out_var)\
|
||||
out_var = 0;\
|
||||
for(var/total_moles_id in cached_gases){\
|
||||
out_var += cached_gases[total_moles_id];\
|
||||
}
|
||||
|
||||
#ifdef TESTING
|
||||
GLOBAL_LIST_INIT(atmos_adjacent_savings, list(0,0))
|
||||
#define CALCULATE_ADJACENT_TURFS(T) if (SSadjacent_air.queue[T]) { GLOB.atmos_adjacent_savings[1] += 1 } else { GLOB.atmos_adjacent_savings[2] += 1; SSadjacent_air.queue[T] = 1 }
|
||||
#else
|
||||
#define CALCULATE_ADJACENT_TURFS(T) SSadjacent_air.queue[T] = 1
|
||||
#endif
|
||||
|
||||
//Unomos - So for whatever reason, garbage collection actually drastically decreases the cost of atmos later in the round. Turning this into a define yields massively improved performance.
|
||||
#define GAS_GARBAGE_COLLECT(GASGASGAS)\
|
||||
var/list/CACHE_GAS = GASGASGAS;\
|
||||
for(var/id in CACHE_GAS){\
|
||||
if(QUANTIZE(CACHE_GAS[id]) <= 0)\
|
||||
CACHE_GAS -= id;\
|
||||
}
|
||||
|
||||
#define ARCHIVE_TEMPERATURE(gas) gas.temperature_archived = gas.temperature
|
||||
|
||||
GLOBAL_LIST_INIT(pipe_paint_colors, list(
|
||||
"amethyst" = rgb(130,43,255), //supplymain
|
||||
"blue" = rgb(0,0,255),
|
||||
"brown" = rgb(178,100,56),
|
||||
"cyan" = rgb(0,255,249),
|
||||
"dark" = rgb(69,69,69),
|
||||
"green" = rgb(30,255,0),
|
||||
"grey" = rgb(255,255,255),
|
||||
"orange" = rgb(255,129,25),
|
||||
"purple" = rgb(128,0,182),
|
||||
"red" = rgb(255,0,0),
|
||||
"violet" = rgb(64,0,128),
|
||||
"yellow" = rgb(255,198,0)
|
||||
))
|
||||
|
||||
#define MIASMA_CORPSE_MOLES 0.02
|
||||
#define MIASMA_GIBS_MOLES 0.005
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#define STYLE_FRUIT 11
|
||||
#define STYLE_INVISIBLE 12
|
||||
#define STYLE_GONDOLA 13
|
||||
#define STYLE_SEETHROUGH 14
|
||||
|
||||
#define POD_ICON_STATE 1
|
||||
#define POD_NAME 2
|
||||
@@ -29,5 +30,6 @@
|
||||
list("honkpod", "\improper HONK pod", "A brightly-colored supply pod. It likely originated from the Clown Federation."),\
|
||||
list("fruitpod", "\improper Orange", "An angry orange."),\
|
||||
list("", "\improper S.T.E.A.L.T.H. pod MKVII", "A supply pod that, under normal circumstances, is completely invisible to conventional methods of detection. How are you even seeing this?"),\
|
||||
list("gondolapod", "gondola", "The silent walker. This one seems to be part of a delivery agency.")\
|
||||
list("gondolapod", "gondola", "The silent walker. This one seems to be part of a delivery agency."),\
|
||||
list("", "", "")\
|
||||
)
|
||||
@@ -17,6 +17,7 @@
|
||||
|
||||
#define COLOR_FLOORTILE_GRAY "#8D8B8B"
|
||||
#define COLOR_ALMOST_BLACK "#333333"
|
||||
#define COLOR_SILVER "#C0C0C0"
|
||||
#define COLOR_BLACK "#000000"
|
||||
#define COLOR_RED "#FF0000"
|
||||
#define COLOR_RED_LIGHT "#FF3333"
|
||||
@@ -63,4 +64,4 @@
|
||||
#define COLOR_ASSEMBLY_LBLUE "#5D99BE"
|
||||
#define COLOR_ASSEMBLY_BLUE "#38559E"
|
||||
#define COLOR_ASSEMBLY_PURPLE "#6F6192"
|
||||
#define COLOR_ASSEMBLY_PINK "#ff4adc"
|
||||
#define COLOR_ASSEMBLY_PINK "#ff4adc"
|
||||
|
||||
@@ -87,6 +87,7 @@
|
||||
#define CAT_ROBOT "Robots"
|
||||
#define CAT_MISC "Misc"
|
||||
#define CAT_PRIMAL "Tribal"
|
||||
//#define CAT_CARPENTRY "Carpentry" need to get this to work
|
||||
#define CAT_CLOTHING "Clothing"
|
||||
#define CAT_FOOD "Foods"
|
||||
#define CAT_BREAD "Breads"
|
||||
|
||||
@@ -152,18 +152,15 @@
|
||||
#define COMPONENT_BLOCK_TELEPORT (1<<0)
|
||||
///called when an atom is added to the hearers on get_hearers_in_view(): (list/processing_list, list/hearers)
|
||||
#define COMSIG_ATOM_HEARER_IN_VIEW "atom_hearer_in_view"
|
||||
///called when an atom starts orbiting another atom: (atom)
|
||||
#define COMSIG_ATOM_ORBIT_BEGIN "atom_orbit_begin"
|
||||
///called when an atom stops orbiting another atom: (atom)
|
||||
#define COMSIG_ATOM_ORBIT_STOP "atom_orbit_stop"
|
||||
/////////////////
|
||||
///from base of atom/attack_ghost(): (mob/dead/observer/ghost)
|
||||
#define COMSIG_ATOM_ATTACK_GHOST "atom_attack_ghost"
|
||||
///from base of atom/attack_hand(): (mob/user)
|
||||
#define COMSIG_ATOM_ATTACK_HAND "atom_attack_hand"
|
||||
///from base of atom/attack_paw(): (mob/user)
|
||||
#define COMSIG_ATOM_ATTACK_PAW "atom_attack_paw"
|
||||
#define COMPONENT_NO_ATTACK_HAND (1<<0) //works on all 3.
|
||||
#define COMSIG_ATOM_ATTACK_GHOST "atom_attack_ghost" //from base of atom/attack_ghost(): (mob/dead/observer/ghost)
|
||||
#define COMSIG_ATOM_ATTACK_HAND "atom_attack_hand" //from base of atom/attack_hand(): (mob/user)
|
||||
#define COMSIG_ATOM_ATTACK_PAW "atom_attack_paw" //from base of atom/attack_paw(): (mob/user)
|
||||
#define COMPONENT_NO_ATTACK_HAND 1 //works on all 3.
|
||||
/////////////////
|
||||
|
||||
//This signal return value bitflags can be found in __DEFINES/misc.dm
|
||||
|
||||
///called for each movable in a turf contents on /turf/zImpact(): (atom/movable/A, levels)
|
||||
@@ -174,6 +171,10 @@
|
||||
#define COMSIG_LIVING_START_PULL "living_start_pull"
|
||||
|
||||
/////////////////
|
||||
/// Called from orbit component: (atom/movable/orbiter, radius, clockwise, rotation_speed, rotation_segments, pre_rotation)
|
||||
#define COMSIG_ATOM_ORBIT_BEGIN "atom_orbit_begin"
|
||||
/// Called from orbit component: (atom/movable/orbiter, refreshing)
|
||||
#define COMSIG_ATOM_ORBIT_END "atom_orbit_end"
|
||||
|
||||
///from base of area/Entered(): (/area)
|
||||
#define COMSIG_ENTER_AREA "enter_area"
|
||||
@@ -293,6 +294,7 @@
|
||||
#define SPEECH_LANGUAGE 5
|
||||
#define SPEECH_IGNORE_SPAM 6
|
||||
#define SPEECH_FORCED 7 */
|
||||
#define COMSIG_MOB_ANTAG_ON_GAIN "mob_antag_on_gain" //from base of /datum/antagonist/on_gain(): (antag_datum)
|
||||
|
||||
///from base of /mob/Login(): ()
|
||||
#define COMSIG_MOB_LOGIN "mob_login"
|
||||
@@ -377,6 +379,7 @@
|
||||
|
||||
///from base of mob/living/carbon/soundbang_act(): (list(intensity))
|
||||
#define COMSIG_CARBON_SOUNDBANG "carbon_soundbang"
|
||||
#define COMSIG_CARBON_IDENTITY_TRANSFERRED_TO "carbon_id_transferred_to" //from datum/dna/transfer_identity(): (datum/dna, transfer_SE)
|
||||
///from /item/organ/proc/Insert() (/obj/item/organ/)
|
||||
#define COMSIG_CARBON_GAIN_ORGAN "carbon_gain_organ"
|
||||
///from /item/organ/proc/Remove() (/obj/item/organ/)
|
||||
@@ -565,6 +568,9 @@
|
||||
#define COMSIG_HUMAN_MELEE_UNARMED_ATTACKBY "human_melee_unarmed_attackby"
|
||||
///Hit by successful disarm attack (mob/living/carbon/human/attacker,zone_targeted)
|
||||
#define COMSIG_HUMAN_DISARM_HIT "human_disarm_hit"
|
||||
#define COMSIG_HUMAN_PREFS_COPIED_TO "human_prefs_copied_to" //from datum/preferences/copy_to(): (datum/preferences, icon_updates, roundstart_checks)
|
||||
#define COMSIG_HUMAN_HARDSET_DNA "human_hardset_dna" //from mob/living/carbon/human/hardset_dna(): (ui, se, newreal_name, newblood_type, datum/species, newfeatures)
|
||||
#define COMSIG_HUMAN_ON_RANDOMIZE "humman_on_randomize" //from base of proc/randomize_human()
|
||||
///Whenever EquipRanked is called, called after job is set
|
||||
#define COMSIG_JOB_RECEIVED "job_received"
|
||||
|
||||
@@ -708,16 +714,13 @@
|
||||
#define COMPONENT_ACTION_BLOCK_TRIGGER (1<<0)
|
||||
|
||||
//Xenobio hotkeys
|
||||
#define COMSIG_XENO_SLIME_CLICK_CTRL "xeno_slime_click_ctrl" //from slime CtrlClickOn(): (/mob)
|
||||
#define COMSIG_XENO_SLIME_CLICK_ALT "xeno_slime_click_alt" //from slime AltClickOn(): (/mob)
|
||||
#define COMSIG_XENO_SLIME_CLICK_SHIFT "xeno_slime_click_shift" //from slime ShiftClickOn(): (/mob)
|
||||
#define COMSIG_XENO_TURF_CLICK_SHIFT "xeno_turf_click_shift" //from turf ShiftClickOn(): (/mob)
|
||||
#define COMSIG_XENO_TURF_CLICK_CTRL "xeno_turf_click_alt" //from turf AltClickOn(): (/mob)
|
||||
#define COMSIG_XENO_MONKEY_CLICK_CTRL "xeno_monkey_click_ctrl" //from monkey CtrlClickOn(): (/mob)
|
||||
|
||||
///from slime CtrlClickOn(): (/mob)
|
||||
#define COMSIG_XENO_SLIME_CLICK_CTRL "xeno_slime_click_ctrl"
|
||||
///from slime AltClickOn(): (/mob)
|
||||
#define COMSIG_XENO_SLIME_CLICK_ALT "xeno_slime_click_alt"
|
||||
///from slime ShiftClickOn(): (/mob)
|
||||
#define COMSIG_XENO_SLIME_CLICK_SHIFT "xeno_slime_click_shift"
|
||||
///from turf ShiftClickOn(): (/mob)
|
||||
#define COMSIG_XENO_TURF_CLICK_SHIFT "xeno_turf_click_shift"
|
||||
///from turf AltClickOn(): (/mob)
|
||||
#define COMSIG_XENO_TURF_CLICK_CTRL "xeno_turf_click_alt"
|
||||
///from monkey CtrlClickOn(): (/mob)
|
||||
#define COMSIG_XENO_MONKEY_CLICK_CTRL "xeno_monkey_click_ctrl"
|
||||
// twitch plays
|
||||
/// Returns direction: (wipe_votes)
|
||||
#define COMSIG_TWITCH_PLAYS_MOVEMENT_DATA "twitch_plays_movement_data"
|
||||
|
||||
@@ -32,6 +32,7 @@ GLOBAL_LIST_INIT(bitflags, list(1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 204
|
||||
#define TESLA_IGNORE_1 (1<<13) // TESLA_IGNORE grants immunity from being targeted by tesla-style electricity
|
||||
#define INITIALIZED_1 (1<<14) //Whether /atom/Initialize() has already run for the object
|
||||
#define ADMIN_SPAWNED_1 (1<<15) //was this spawned by an admin? used for stat tracking stuff.
|
||||
#define PREVENT_CONTENTS_EXPLOSION_1 (1<<16) /// should not get harmed if this gets caught by an explosion?
|
||||
|
||||
//turf-only flags
|
||||
#define NOJAUNT_1 (1<<0)
|
||||
@@ -91,3 +92,4 @@ GLOBAL_LIST_INIT(bitflags, list(1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 204
|
||||
// radiation
|
||||
#define RAD_PROTECT_CONTENTS (1<<0)
|
||||
#define RAD_NO_CONTAMINATE (1<<1)
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#define PINEAPPLE (1<<12)
|
||||
#define BREAKFAST (1<<13)
|
||||
#define CLOTH (1<<14)
|
||||
#define ANTITOXIC (1<<15)
|
||||
|
||||
#define DRINK_NICE 1
|
||||
#define DRINK_GOOD 2
|
||||
|
||||
@@ -89,6 +89,9 @@ GLOBAL_LIST_INIT(turfs_without_ground, typecacheof(list(
|
||||
#define isxenoperson(A) (is_species(A, /datum/species/xeno))
|
||||
#define isstartjelly(A) (is_species(A, /datum/species/jelly/roundstartslime))
|
||||
|
||||
// Hyperstation Carbon Stuff
|
||||
#define iswendigo(A) (istype(A, /mob/living/carbon/wendigo))
|
||||
|
||||
//more carbon mobs
|
||||
#define ismonkey(A) (istype(A, /mob/living/carbon/monkey))
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#define VIROLOGIST (1<<6)
|
||||
#define JR_DOCTOR (1<<7)
|
||||
#define JR_SCIENTIST (1<<9)
|
||||
#define MED_PSYCH (1<<14)
|
||||
|
||||
|
||||
#define CIVILIAN (1<<2)
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
#define PLANE_SPACE -95
|
||||
#define PLANE_SPACE_PARALLAX -90
|
||||
|
||||
#define OPENSPACE_LAYER 17 //Openspace layer over all
|
||||
#define OPENSPACE_PLANE -4 //Openspace plane below all turfs
|
||||
#define OPENSPACE_BACKDROP_PLANE -3 //Black square just over openspace plane to guaranteed cover all in openspace turf
|
||||
|
||||
#define FLOOR_PLANE -2
|
||||
#define GAME_PLANE -1
|
||||
#define BLACKNESS_PLANE 0 //To keep from conflicts with SEE_BLACKNESS internals
|
||||
@@ -87,9 +91,6 @@
|
||||
#define ABOVE_LIGHTING_PLANE 16
|
||||
#define ABOVE_LIGHTING_LAYER 16
|
||||
|
||||
#define FLOOR_OPENSPACE_PLANE 17
|
||||
#define OPENSPACE_LAYER 17
|
||||
|
||||
#define BYOND_LIGHTING_PLANE 18
|
||||
#define BYOND_LIGHTING_LAYER 18
|
||||
|
||||
|
||||
@@ -217,3 +217,12 @@
|
||||
|
||||
#define RULE_OF_THREE(a, b, x) ((a*x)/b)
|
||||
// )
|
||||
|
||||
#define MANHATTAN_DISTANCE(a, b) (abs(a.x - b.x) + abs(a.y - b.y))
|
||||
|
||||
#define LOGISTIC_FUNCTION(L,k,x,x_0) (L/(1+(NUM_E**(-k*(x-x_0)))))
|
||||
|
||||
/// Make sure something is a boolean TRUE/FALSE 1/0 value, since things like bitfield & bitflag doesn't always give 1s and 0s.
|
||||
#define FORCE_BOOLEAN(x) ((x)? TRUE : FALSE)
|
||||
|
||||
#define TILES_TO_PIXELS(tiles) (tiles * PIXELS)
|
||||
|
||||
+40
-24
@@ -27,29 +27,30 @@ Will print: "/mob/living/carbon/human/death" (you can optionally embed it in a s
|
||||
|
||||
//Human Overlays Indexes/////////
|
||||
//LOTS OF CIT CHANGES HERE. BE CAREFUL WHEN UPSTREAM ADDS MORE LAYERS
|
||||
#define MUTATIONS_LAYER 31 //mutations. Tk headglows, cold resistance glow, etc
|
||||
#define GENITALS_BEHIND_LAYER 30 //Some genitalia needs to be behind everything, such as with taurs (Taurs use body_behind_layer
|
||||
#define BODY_BEHIND_LAYER 29 //certain mutantrace features (tail when looking south) that must appear behind the body parts
|
||||
#define BODYPARTS_LAYER 28 //Initially "AUGMENTS", this was repurposed to be a catch-all bodyparts flag
|
||||
#define MARKING_LAYER 27 //Matrixed body markings because clashing with snouts?
|
||||
#define BODY_ADJ_LAYER 26 //certain mutantrace features (snout, body markings) that must appear above the body parts
|
||||
#define BODY_LAYER 25 //underwear, undershirts, socks, eyes, lips(makeup)
|
||||
#define FRONT_MUTATIONS_LAYER 24 //mutations that should appear above body, body_adj and bodyparts layer (e.g. laser eyes)
|
||||
#define DAMAGE_LAYER 23 //damage indicators (cuts and burns)
|
||||
#define UNIFORM_LAYER 22
|
||||
#define ID_LAYER 21
|
||||
#define HANDS_PART_LAYER 20
|
||||
#define SHOES_LAYER 19
|
||||
#define GLOVES_LAYER 18
|
||||
#define EARS_LAYER 17
|
||||
#define BODY_TAUR_LAYER 16
|
||||
#define GENITALS_FRONT_LAYER 15
|
||||
#define SUIT_LAYER 14
|
||||
#define GLASSES_LAYER 13
|
||||
#define BELT_LAYER 12 //Possible make this an overlay of somethign required to wear a belt?
|
||||
#define SUIT_STORE_LAYER 11
|
||||
#define NECK_LAYER 10
|
||||
#define BACK_LAYER 9
|
||||
#define MUTATIONS_LAYER 32 //mutations. Tk headglows, cold resistance glow, etc
|
||||
#define GENITALS_BEHIND_LAYER 31 //Some genitalia needs to be behind everything, such as with taurs (Taurs use body_behind_layer
|
||||
#define BODY_BEHIND_LAYER 30 //certain mutantrace features (tail when looking south) that must appear behind the body parts
|
||||
#define BODYPARTS_LAYER 29 //Initially "AUGMENTS", this was repurposed to be a catch-all bodyparts flag
|
||||
#define MARKING_LAYER 28 //Matrixed body markings because clashing with snouts?
|
||||
#define BODY_ADJ_LAYER 27 //certain mutantrace features (snout, body markings) that must appear above the body parts
|
||||
#define BODY_LAYER 26 //underwear, undershirts, socks, eyes, lips(makeup)
|
||||
#define FRONT_MUTATIONS_LAYER 25 //mutations that should appear above body, body_adj and bodyparts layer (e.g. laser eyes)
|
||||
#define DAMAGE_LAYER 24 //damage indicators (cuts and burns)
|
||||
#define UNIFORM_LAYER 23
|
||||
#define ID_LAYER 22
|
||||
#define HANDS_PART_LAYER 21
|
||||
#define SHOES_LAYER 20
|
||||
#define GLOVES_LAYER 19
|
||||
#define EARS_LAYER 18
|
||||
#define BODY_TAUR_LAYER 17
|
||||
#define GENITALS_UNDER_LAYER 16
|
||||
#define SUIT_LAYER 15
|
||||
#define GLASSES_LAYER 14
|
||||
#define BELT_LAYER 13 //Possible make this an overlay of somethign required to wear a belt?
|
||||
#define SUIT_STORE_LAYER 12
|
||||
#define NECK_LAYER 11
|
||||
#define BACK_LAYER 10
|
||||
#define GENITALS_FRONT_LAYER 9
|
||||
#define HAIR_LAYER 8 //TODO: make part of head layer?
|
||||
#define FACEMASK_LAYER 7
|
||||
#define HEAD_LAYER 6
|
||||
@@ -58,7 +59,7 @@ Will print: "/mob/living/carbon/human/death" (you can optionally embed it in a s
|
||||
#define HANDS_LAYER 3
|
||||
#define BODY_FRONT_LAYER 2
|
||||
#define FIRE_LAYER 1 //If you're on fire
|
||||
#define TOTAL_LAYERS 31 //KEEP THIS UP-TO-DATE OR SHIT WILL BREAK ;_;
|
||||
#define TOTAL_LAYERS 32 //KEEP THIS UP-TO-DATE OR SHIT WILL BREAK ;_;
|
||||
|
||||
//Human Overlay Index Shortcuts for alternate_worn_layer, layers
|
||||
//Because I *KNOW* somebody will think layer+1 means "above"
|
||||
@@ -260,6 +261,16 @@ GLOBAL_LIST_INIT(pda_styles, list(MONO, VT, ORBITRON, SHARE))
|
||||
GLOBAL_LIST_INIT(pda_reskins, list(PDA_SKIN_CLASSIC = 'icons/obj/pda.dmi', PDA_SKIN_ALT = 'icons/obj/pda_alt.dmi',
|
||||
PDA_SKIN_RUGGED = 'icons/obj/pda_rugged.dmi', PDA_SKIN_MODERN = 'icons/obj/pda_modern.dmi'))
|
||||
|
||||
//zippo icon reskins
|
||||
#define ZIPPO_SKIN_PLAIN "Plain"
|
||||
#define ZIPPO_SKIN_DAME "Dame"
|
||||
#define ZIPPO_SKIN_THIRTEEN "Thirteen"
|
||||
#define ZIPPO_SKIN_SNAKE "Snake"
|
||||
|
||||
GLOBAL_LIST_INIT(lighter_reskins, list(ZIPPO_SKIN_PLAIN = "plain", ZIPPO_SKIN_DAME = "dame",
|
||||
ZIPPO_SKIN_THIRTEEN = "thirteen", ZIPPO_SKIN_SNAKE = "snake"))
|
||||
|
||||
|
||||
/////////////////////////////////////
|
||||
// atom.appearence_flags shortcuts //
|
||||
/////////////////////////////////////
|
||||
@@ -478,6 +489,11 @@ GLOBAL_LIST_INIT(pda_reskins, list(PDA_SKIN_CLASSIC = 'icons/obj/pda.dmi', PDA_S
|
||||
#define AREASELECT_CORNERA "corner A"
|
||||
#define AREASELECT_CORNERB "corner B"
|
||||
|
||||
#define VARSET_FROM_LIST(L, V) if(L && L[#V]) V = L[#V]
|
||||
#define VARSET_FROM_LIST_IF(L, V, C...) if(L && L[#V] && (C)) V = L[#V]
|
||||
#define VARSET_TO_LIST(L, V) if(L) L[#V] = V
|
||||
#define VARSET_TO_LIST_IF(L, V, C...) if(L && (C)) L[#V] = V
|
||||
|
||||
#define PREF_SAVELOAD_COOLDOWN 5
|
||||
|
||||
#define VOMIT_TOXIC 1
|
||||
|
||||
+23
-12
@@ -36,17 +36,17 @@
|
||||
#define BLOODCRAWL_EAT 2
|
||||
|
||||
//Mob bio-types
|
||||
#define MOB_ORGANIC "organic"
|
||||
#define MOB_INORGANIC "inorganic"
|
||||
#define MOB_ROBOTIC "robotic"
|
||||
#define MOB_SILICON "silicon"
|
||||
#define MOB_UNDEAD "undead"
|
||||
#define MOB_HUMANOID "humanoid"
|
||||
#define MOB_BUG "bug"
|
||||
#define MOB_BEAST "beast"
|
||||
#define MOB_EPIC "epic" //megafauna
|
||||
#define MOB_REPTILE "reptile"
|
||||
#define MOB_SPIRIT "spirit"
|
||||
#define MOB_ORGANIC (1 << 0)
|
||||
#define MOB_INORGANIC (1 << 1)
|
||||
#define MOB_ROBOTIC (1 << 2)
|
||||
#define MOB_SILICON (1 << 3)
|
||||
#define MOB_UNDEAD (1 << 4)
|
||||
#define MOB_HUMANOID (1 << 5)
|
||||
#define MOB_BUG (1 << 6)
|
||||
#define MOB_BEAST (1 << 7)
|
||||
#define MOB_EPIC (1 << 8) //megafauna
|
||||
#define MOB_REPTILE (1 << 9)
|
||||
#define MOB_SPIRIT (1 << 10)
|
||||
|
||||
//Organ defines for carbon mobs
|
||||
#define ORGAN_ORGANIC 1
|
||||
@@ -69,6 +69,7 @@
|
||||
#define ALIEN_BODYPART "alien"
|
||||
#define LARVA_BODYPART "larva"
|
||||
#define DEVIL_BODYPART "devil"
|
||||
#define WENDIGO_BODYPART "wendigo"
|
||||
/*see __DEFINES/inventory.dm for bodypart bitflag defines*/
|
||||
|
||||
// Health/damage defines for carbon mobs
|
||||
@@ -158,6 +159,15 @@
|
||||
#define NUTRITION_LEVEL_START_MIN 250
|
||||
#define NUTRITION_LEVEL_START_MAX 400
|
||||
|
||||
//Hyperstation Thirst
|
||||
#define THIRST_LEVEL_THRESHOLD 800 //Set to 0 to stop clamping
|
||||
#define THIRST_LEVEL_QUENCHED 450
|
||||
#define THIRST_LEVEL_THIRSTY 250
|
||||
#define THIRST_LEVEL_PARCHED 150
|
||||
|
||||
#define THIRST_LEVEL_START_MIN 250
|
||||
#define THIRST_LEVEL_START_MAX 400
|
||||
|
||||
//Disgust levels for humans
|
||||
#define DISGUST_LEVEL_MAXEDOUT 150
|
||||
#define DISGUST_LEVEL_DISGUSTED 75
|
||||
@@ -250,7 +260,8 @@
|
||||
#define POCKET_STRIP_DELAY 40 //time taken (in deciseconds) to search somebody's pockets
|
||||
#define DOOR_CRUSH_DAMAGE 15 //the amount of damage that airlocks deal when they crush you
|
||||
|
||||
#define HUNGER_FACTOR 0.1 //factor at which mob nutrition decreases
|
||||
#define HUNGER_FACTOR 0.08 //factor at which mob nutrition decreases
|
||||
#define THIRST_FACTOR 0.08 //factor at which mob thirst decreases
|
||||
#define REAGENTS_METABOLISM 0.4 //How many units of reagent are consumed per tick, by default.
|
||||
#define REAGENTS_EFFECT_MULTIPLIER (REAGENTS_METABOLISM / 0.4) // By defining the effect multiplier this way, it'll exactly adjust all effects according to how they originally were with the 0.4 metabolism
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#define DISABLE_DEATHRATTLE (1<<12)
|
||||
#define DISABLE_ARRIVALRATTLE (1<<13)
|
||||
#define COMBOHUD_LIGHTING (1<<14)
|
||||
#define ANTAG_SYNC_WITH_CHARS (1<<15)
|
||||
|
||||
#define TOGGLES_DEFAULT (SOUND_ADMINHELP|SOUND_MIDI|SOUND_AMBIENCE|SOUND_LOBBY|MEMBER_PUBLIC|INTENT_STYLE|MIDROUND_ANTAG|SOUND_INSTRUMENTS|SOUND_SHIP_AMBIENCE|SOUND_PRAYERS|SOUND_ANNOUNCEMENTS)
|
||||
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
/// Represents a proc or verb path.
|
||||
///
|
||||
/// Despite having no DM-defined static type, proc paths have some variables,
|
||||
/// listed below. These are not modifiable, but for a given procpath P,
|
||||
/// `new P(null, "Name", "Desc")` can be used to create a new procpath with the
|
||||
/// same code but new `name` and `desc` values. The other variables cannot be
|
||||
/// changed in this way.
|
||||
///
|
||||
/// This type exists only to act as an annotation, providing reasonable static
|
||||
/// typing for procpaths. Previously, types like `/atom/verb` were used, with
|
||||
/// the `name` and `desc` vars of `/atom` thus being accessible. Proc and verb
|
||||
/// paths will fail `istype` and `ispath` checks against `/procpath`.
|
||||
/procpath
|
||||
// Although these variables are effectively const, if they are marked const
|
||||
// below, their accesses are optimized away.
|
||||
|
||||
/// A text string of the verb's name.
|
||||
var/name as text
|
||||
/// The verb's help text or description.
|
||||
var/desc as text
|
||||
/// The category or tab the verb will appear in.
|
||||
var/category as text
|
||||
/// Only clients/mobs with `see_invisibility` higher can use the verb.
|
||||
var/invisibility as num
|
||||
/// Whether or not the verb appears in statpanel and commandbar when you press space
|
||||
var/hidden as num
|
||||
@@ -0,0 +1,12 @@
|
||||
//Hyperstation, used to help categorize traits
|
||||
#define CATEGORY_UNCATEGORIZED "Uncategorized" //Uncategorized quirks always appear last
|
||||
#define CATEGORY_ALCOHOL "Alcohol"
|
||||
#define CATEGORY_MOODS "Moods"
|
||||
#define CATEGORY_MOVEMENT "Movement"
|
||||
#define CATEGORY_ITEMS "Items"
|
||||
#define CATEGORY_HEALTH "Health"
|
||||
#define CATEGORY_FOOD "Food"
|
||||
#define CATEGORY_LANGUAGES "Languages"
|
||||
#define CATEGORY_BODY "Body Modification"
|
||||
#define CATEGORY_GAMEPLAY "Gameplay-Affecting"
|
||||
#define CATEGORY_SEXUAL "Sexual" //Can't come up with something less vulgar
|
||||
@@ -26,7 +26,8 @@
|
||||
//Research point amounts
|
||||
#define NOBLIUM_RESEARCH_AMOUNT 100
|
||||
#define BZ_RESEARCH_AMOUNT 15
|
||||
#define MIASMA_RESEARCH_AMOUNT 6 //lolno, fart gas 2 ez
|
||||
#define MIASMA_RESEARCH_AMOUNT 6
|
||||
#define PHEROMONE_RESEARCH_AMOUNT 6
|
||||
#define STIMULUM_RESEARCH_AMOUNT 50
|
||||
//Plasma fusion properties
|
||||
#define FUSION_ENERGY_THRESHOLD 3e9 //Amount of energy it takes to start a fusion reaction
|
||||
|
||||
+58
-4
@@ -5,10 +5,11 @@
|
||||
#define CHANNEL_JUKEBOX 1021
|
||||
#define CHANNEL_JUKEBOX_START 1016 //The gap between this and CHANNEL_JUKEBOX determines the amount of free jukebox channels. This currently allows 6 jukebox channels to exist.
|
||||
#define CHANNEL_JUSTICAR_ARK 1015
|
||||
#define CHANNEL_HEARTBEAT 1014 //sound channel for heartbeats
|
||||
#define CHANNEL_AMBIENCE 1013
|
||||
#define CHANNEL_BUZZ 1012
|
||||
#define CHANNEL_BICYCLE 1011
|
||||
#define CHANNEL_HEARTBEAT 1020 //sound channel for heartbeats
|
||||
#define CHANNEL_AMBIENCE 1019
|
||||
#define CHANNEL_BUZZ 1018
|
||||
#define CHANNEL_BICYCLE 1017
|
||||
|
||||
|
||||
//CIT CHANNELS - TRY NOT TO REGRESS
|
||||
#define CHANNEL_PRED 1010
|
||||
@@ -83,3 +84,56 @@
|
||||
'sound/hallucinations/growl3.ogg', 'sound/hallucinations/im_here1.ogg', 'sound/hallucinations/im_here2.ogg', 'sound/hallucinations/i_see_you1.ogg', 'sound/hallucinations/i_see_you2.ogg',\
|
||||
'sound/hallucinations/look_up1.ogg', 'sound/hallucinations/look_up2.ogg', 'sound/hallucinations/over_here1.ogg', 'sound/hallucinations/over_here2.ogg', 'sound/hallucinations/over_here3.ogg',\
|
||||
'sound/hallucinations/turn_around1.ogg', 'sound/hallucinations/turn_around2.ogg', 'sound/hallucinations/veryfar_noise.ogg', 'sound/hallucinations/wail.ogg')
|
||||
|
||||
|
||||
//default byond sound environments
|
||||
#define SOUND_ENVIRONMENT_NONE -1
|
||||
#define SOUND_ENVIRONMENT_GENERIC 0
|
||||
#define SOUND_ENVIRONMENT_PADDED_CELL 1
|
||||
#define SOUND_ENVIRONMENT_ROOM 2
|
||||
#define SOUND_ENVIRONMENT_BATHROOM 3
|
||||
#define SOUND_ENVIRONMENT_LIVINGROOM 4
|
||||
#define SOUND_ENVIRONMENT_STONEROOM 5
|
||||
#define SOUND_ENVIRONMENT_AUDITORIUM 6
|
||||
#define SOUND_ENVIRONMENT_CONCERT_HALL 7
|
||||
#define SOUND_ENVIRONMENT_CAVE 8
|
||||
#define SOUND_ENVIRONMENT_ARENA 9
|
||||
#define SOUND_ENVIRONMENT_HANGAR 10
|
||||
#define SOUND_ENVIRONMENT_CARPETED_HALLWAY 11
|
||||
#define SOUND_ENVIRONMENT_HALLWAY 12
|
||||
#define SOUND_ENVIRONMENT_STONE_CORRIDOR 13
|
||||
#define SOUND_ENVIRONMENT_ALLEY 14
|
||||
#define SOUND_ENVIRONMENT_FOREST 15
|
||||
#define SOUND_ENVIRONMENT_CITY 16
|
||||
#define SOUND_ENVIRONMENT_MOUNTAINS 17
|
||||
#define SOUND_ENVIRONMENT_QUARRY 18
|
||||
#define SOUND_ENVIRONMENT_PLAIN 19
|
||||
#define SOUND_ENVIRONMENT_PARKING_LOT 20
|
||||
#define SOUND_ENVIRONMENT_SEWER_PIPE 21
|
||||
#define SOUND_ENVIRONMENT_UNDERWATER 22
|
||||
#define SOUND_ENVIRONMENT_DRUGGED 23
|
||||
#define SOUND_ENVIRONMENT_DIZZY 24
|
||||
#define SOUND_ENVIRONMENT_PSYCHOTIC 25
|
||||
//If we ever make custom ones add them here
|
||||
|
||||
//"sound areas": easy way of keeping different types of areas consistent.
|
||||
#define SOUND_AREA_STANDARD_STATION SOUND_ENVIRONMENT_PARKING_LOT
|
||||
#define SOUND_AREA_LARGE_ENCLOSED SOUND_ENVIRONMENT_QUARRY
|
||||
#define SOUND_AREA_SMALL_ENCLOSED SOUND_ENVIRONMENT_BATHROOM
|
||||
#define SOUND_AREA_TUNNEL_ENCLOSED SOUND_ENVIRONMENT_STONEROOM
|
||||
#define SOUND_AREA_LARGE_SOFTFLOOR SOUND_ENVIRONMENT_CARPETED_HALLWAY
|
||||
#define SOUND_AREA_MEDIUM_SOFTFLOOR SOUND_ENVIRONMENT_LIVINGROOM
|
||||
#define SOUND_AREA_SMALL_SOFTFLOOR SOUND_ENVIRONMENT_ROOM
|
||||
#define SOUND_AREA_ASTEROID SOUND_ENVIRONMENT_CAVE
|
||||
#define SOUND_AREA_SPACE SOUND_ENVIRONMENT_UNDERWATER
|
||||
#define SOUND_AREA_LAVALAND SOUND_ENVIRONMENT_MOUNTAINS
|
||||
#define SOUND_AREA_ICEMOON SOUND_ENVIRONMENT_CAVE
|
||||
#define SOUND_AREA_WOODFLOOR SOUND_ENVIRONMENT_CITY
|
||||
|
||||
#define INTERACTION_SOUND_RANGE_MODIFIER -3
|
||||
#define EQUIP_SOUND_VOLUME 30
|
||||
|
||||
|
||||
#define PICKUP_SOUND_VOLUME 40
|
||||
#define DROP_SOUND_VOLUME 50
|
||||
#define YEET_SOUND_VOLUME 90
|
||||
@@ -6,10 +6,14 @@
|
||||
#define RETURN_TYPE(X) set SpacemanDMM_return_type = X
|
||||
#define SHOULD_CALL_PARENT(X) set SpacemanDMM_should_call_parent = X
|
||||
#define UNLINT(X) SpacemanDMM_unlint(X)
|
||||
#define SHOULD_NOT_OVERRIDE(X) set SpacemanDMM_should_not_override = X
|
||||
#define SHOULD_NOT_SLEEP(X) set SpacemanDMM_should_not_sleep = X
|
||||
#else
|
||||
#define RETURN_TYPE(X)
|
||||
#define SHOULD_CALL_PARENT(X)
|
||||
#define UNLINT(X) X
|
||||
#define SHOULD_NOT_OVERRIDE(X)
|
||||
#define SHOULD_NOT_SLEEP(X)
|
||||
#endif
|
||||
|
||||
/world/proc/enable_debugger()
|
||||
|
||||
@@ -64,6 +64,7 @@
|
||||
#define INIT_ORDER_TICKER 9
|
||||
#define INIT_ORDER_MAPPING 8
|
||||
#define INIT_ORDER_NETWORKS 7
|
||||
#define INIT_ORDER_ECONOMY 21
|
||||
#define INIT_ORDER_ATOMS 6
|
||||
#define INIT_ORDER_LANGUAGE 5
|
||||
#define INIT_ORDER_MACHINES 4
|
||||
@@ -83,6 +84,7 @@
|
||||
#define INIT_ORDER_MINOR_MAPPING -40
|
||||
#define INIT_ORDER_PATH -50
|
||||
#define INIT_ORDER_PERSISTENCE -95
|
||||
#define INIT_ORDER_STATPANELS -98
|
||||
#define INIT_ORDER_CHAT -100 //Should be last to ensure chat remains smooth during init.
|
||||
|
||||
// Subsystem fire priority, from lowest to highest priority
|
||||
|
||||
@@ -94,6 +94,7 @@
|
||||
#define TRAIT_NOFIRE "nonflammable"
|
||||
#define TRAIT_NOGUNS "no_guns"
|
||||
#define TRAIT_NOHUNGER "no_hunger"
|
||||
#define TRAIT_NOTHIRST "no_thirst"
|
||||
#define TRAIT_EASYDISMEMBER "easy_dismember"
|
||||
#define TRAIT_LIMBATTACHMENT "limb_attach"
|
||||
#define TRAIT_NOLIMBDISABLE "no_limb_disable"
|
||||
@@ -169,6 +170,7 @@
|
||||
#define TRAIT_MUSICIAN "musician"
|
||||
#define TRAIT_CROCRIN_IMMUNE "crocin_immune"
|
||||
#define TRAIT_NYMPHO "nymphomania"
|
||||
#define TRAIT_DISTANT "headpat_hater"
|
||||
//#define TRAIT_FLUID_LEAK "leaky_fluids" removed because milk snail trails are not okay
|
||||
#define TRAIT_MASO "masochism"
|
||||
#define TRAIT_CHOKE_SLUT "choke_slut"
|
||||
@@ -185,6 +187,13 @@
|
||||
#define TRAIT_NEVER_CLONE "donotclone"
|
||||
#define TRAIT_COLDBLOODED "coldblooded" // Your body is literal room temperature. Does not make you immune to the temp.
|
||||
#define TRAIT_FLIMSY "flimsy" //you have 20% less maxhealth
|
||||
|
||||
|
||||
//Hyper
|
||||
#define TRAIT_VIRILE "virile" //you have 20% more chance of impreg
|
||||
#define TRAIT_MACROPHILE "macrophile" //likes the big
|
||||
#define TRAIT_MICROPHILE "microphile" //likes the small
|
||||
|
||||
#define TRAIT_TOUGH "tough" //you have 10% more maxhealth
|
||||
#define TRAIT_AUTO_CATCH_ITEM "auto_catch_item"
|
||||
#define TRAIT_CLOWN_MENTALITY "clown_mentality" // The future is now, clownman.
|
||||
|
||||
@@ -104,17 +104,6 @@ GLOBAL_VAR_INIT(miscreants_allowed, FALSE)
|
||||
if(!src.holder) return
|
||||
message_admins("[key_name_admin(usr)] manually reloaded mentors")
|
||||
|
||||
//Flavor Text
|
||||
/mob/living/carbon/human/verb/set_flavor()
|
||||
set name = "Set Flavor Text"
|
||||
set desc = "Sets an extended description of your character's features."
|
||||
set category = "IC"
|
||||
|
||||
var/new_flavor = input(src, "Enter your new flavor text:", "Flavor text", null) as message|null
|
||||
if(!isnull(new_flavor))
|
||||
flavor_text = sanitize(new_flavor)
|
||||
to_chat(src, "Your flavor text has been updated.")
|
||||
|
||||
//LOOC toggles
|
||||
/client/verb/listen_looc()
|
||||
set name = "Show/Hide LOOC"
|
||||
|
||||
@@ -522,10 +522,8 @@
|
||||
used_key_list[input_key] = 1
|
||||
return input_key
|
||||
|
||||
#if DM_VERSION > 513
|
||||
#error Remie said that lummox was adding a way to get a lists
|
||||
#error contents via list.values, if that is true remove this
|
||||
#error otherwise, update the version and bug lummox
|
||||
#if DM_VERSION < 513
|
||||
#error For the love of god do not compile the server below 513
|
||||
#endif
|
||||
//Flattens a keyed list into a list of it's contents
|
||||
/proc/flatten_list(list/key_list)
|
||||
@@ -573,3 +571,9 @@
|
||||
L1[key] += other_value
|
||||
else
|
||||
L1[key] = other_value
|
||||
|
||||
/proc/assoc_list_strip_value(list/input)
|
||||
var/list/ret = list()
|
||||
for(var/key in input)
|
||||
ret += key
|
||||
return ret
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/vagina, GLOB.vagina_shapes_list)
|
||||
init_sprite_accessory_subtypes(/datum/sprite_accessory/breasts, GLOB.breasts_shapes_list)
|
||||
GLOB.breasts_size_list = list ("a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o") //We need the list to choose from initialized, but it's no longer a sprite_accessory thing.
|
||||
GLOB.genital_fluids_list = list ("Milk", "Water", "Semen", "Femcum")
|
||||
GLOB.genital_fluids_list = list ("Milk", "Water", "Semen", "Femcum", "Honey")
|
||||
GLOB.gentlemans_organ_names = list("phallus", "willy", "dick", "prick", "member", "tool", "gentleman's organ", "cock", "wang", "knob", "dong", "joystick", "pecker", "johnson", "weenie", "tadger", "schlong", "thirsty ferret", "baloney pony", "schlanger")
|
||||
for(var/K in GLOB.breasts_shapes_list)
|
||||
var/datum/sprite_accessory/breasts/value = GLOB.breasts_shapes_list[K]
|
||||
|
||||
@@ -186,6 +186,9 @@
|
||||
"cock_color" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"has_sheath" = FALSE,
|
||||
"sheath_color" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"has_belly" = FALSE,
|
||||
"hide_belly" = FALSE,
|
||||
"belly_color" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
"has_balls" = FALSE,
|
||||
"balls_internal" = FALSE,
|
||||
"balls_color" = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F"),
|
||||
@@ -227,7 +230,9 @@
|
||||
"womb_fluid" = "femcum",
|
||||
"ipc_screen" = snowflake_ipc_antenna_list ? pick(snowflake_ipc_antenna_list) : "None",
|
||||
"ipc_antenna" = "None",
|
||||
"flavor_text" = ""))
|
||||
"flavor_text" = "",
|
||||
"silicon_flavor_text" = "",
|
||||
"ooc_text" = ""))
|
||||
|
||||
/proc/random_hair_style(gender)
|
||||
switch(gender)
|
||||
@@ -546,6 +551,8 @@ GLOBAL_LIST_EMPTY(species_list)
|
||||
override = TRUE
|
||||
if(isnewplayer(M) && !override)
|
||||
continue
|
||||
if(SSticker.current_state == GAME_STATE_FINISHED)
|
||||
override = TRUE
|
||||
if(M.stat != DEAD && !override)
|
||||
continue
|
||||
if(speaker_key && speaker_key in prefs.ignoring)
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
announcement += "<br><h2 class='alert'>[html_encode(title)]</h2>"
|
||||
else if(type == "Captain")
|
||||
announcement += "<h1 class='alert'>Captain Announces</h1>"
|
||||
GLOB.news_network.SubmitArticle(text, "Captain's Announcement", "Station Announcements", null)
|
||||
GLOB.news_network.SubmitArticle(html_encode(text), "Captain's Announcement", "Station Announcements", null)
|
||||
|
||||
else
|
||||
if(!sender_override)
|
||||
|
||||
@@ -163,6 +163,7 @@
|
||||
set waitfor = FALSE
|
||||
|
||||
to_chat(world, "<BR><BR><BR><span class='big bold'>The round has ended.</span>")
|
||||
var/botmsg = "**The Round has ended!**```Round ID: [GLOB.round_id]\nRound Time: [DisplayTimeText(world.time - SSticker.round_start_time)]\nTotal Population: [GLOB.joined_player_list.len]```"
|
||||
if(LAZYLEN(GLOB.round_end_notifiees))
|
||||
send2irc("Notice", "[GLOB.round_end_notifiees.Join(", ")] the round has ended.")
|
||||
|
||||
@@ -179,6 +180,20 @@
|
||||
var/popcount = gather_roundend_feedback()
|
||||
display_report(popcount)
|
||||
|
||||
|
||||
CHECK_TICK
|
||||
|
||||
//Hyper bot list players
|
||||
botmsg += "\n**The Crew!** ```"
|
||||
for(var/p in GLOB.player_list)
|
||||
var/mob/living/P = p //the living crew members
|
||||
if(P)
|
||||
botmsg += "[P.real_name]"
|
||||
if(P.job)
|
||||
botmsg += " ([P.job])"
|
||||
botmsg += "\n"
|
||||
botmsg += "```"
|
||||
|
||||
CHECK_TICK
|
||||
|
||||
// Add AntagHUD to everyone, see who was really evil the whole time!
|
||||
@@ -189,6 +204,15 @@
|
||||
|
||||
CHECK_TICK
|
||||
|
||||
set_observer_default_invisibility(0, "<span class='warning'>The round is over! You are now visible to the living.</span>")
|
||||
|
||||
CHECK_TICK
|
||||
// Stop eorg mech prepping.
|
||||
for(var/obj/mecha/combat/Obj in world)
|
||||
qdel(Obj)
|
||||
|
||||
CHECK_TICK
|
||||
|
||||
//Set news report and mode result
|
||||
mode.set_round_result()
|
||||
|
||||
@@ -199,10 +223,6 @@
|
||||
if(length(CONFIG_GET(keyed_list/cross_server)))
|
||||
send_news_report()
|
||||
|
||||
//tell the nice people on discord what went on before the salt cannon happens.
|
||||
world.TgsTargetedChatBroadcast("The current round has ended. Please standby for your shift interlude Kinaris News Network's report!", FALSE)
|
||||
world.TgsTargetedChatBroadcast(send_news_report(),FALSE)
|
||||
|
||||
CHECK_TICK
|
||||
|
||||
//These need update to actually reflect the real antagonists
|
||||
@@ -217,7 +237,6 @@
|
||||
total_antagonists[A.name] += "[key_name(A.owner)]"
|
||||
|
||||
CHECK_TICK
|
||||
|
||||
//Now print them all into the log!
|
||||
log_game("Antagonists at round end were...")
|
||||
for(var/antag_name in total_antagonists)
|
||||
@@ -234,6 +253,7 @@
|
||||
SSblackbox.Seal()
|
||||
|
||||
sleep(50)
|
||||
world.hypermessage(botmsg)
|
||||
ready_for_reboot = TRUE
|
||||
standard_reboot()
|
||||
|
||||
@@ -331,7 +351,7 @@
|
||||
if(!previous)
|
||||
var/list/report_parts = list(personal_report(C), GLOB.common_report)
|
||||
content = report_parts.Join()
|
||||
C.verbs -= /client/proc/show_previous_roundend_report
|
||||
remove_verb(C, /client/proc/show_previous_roundend_report)
|
||||
fdel(filename)
|
||||
text2file(content, filename)
|
||||
else
|
||||
@@ -510,7 +530,7 @@
|
||||
var/jobtext = ""
|
||||
if(ply.assigned_role)
|
||||
jobtext = " the <b>[ply.assigned_role]</b>"
|
||||
var/text = "<b>[ply.key]</b> was <b>[ply.name]</b>[jobtext] and"
|
||||
var/text = "<b>[ply.hide_ckey ? "<b>[ply.name]</b>[jobtext] " : "[ply.key]</b> was <b>[ply.name]</b>[jobtext] and "]"
|
||||
if(ply.current)
|
||||
if(ply.current.stat == DEAD)
|
||||
text += " <span class='redtext'>died</span>"
|
||||
|
||||
+49
-1
@@ -44,6 +44,12 @@
|
||||
index = findtext(t, char, index + length(char))
|
||||
return t
|
||||
|
||||
/proc/sanitize_name(t,list/repl_chars = null)
|
||||
if(t == "space" || t == "floor" || t == "wall" || t == "r-wall" || t == "monkey" || t == "unknown" || t == "inactive ai") //prevents these common metagamey names
|
||||
alert("Invalid name.")
|
||||
return ""
|
||||
return sanitize(t)
|
||||
|
||||
/proc/sanitize_filename(t)
|
||||
return sanitize_simple(t, list("\n"="", "\t"="", "/"="", "\\"="", "?"="", "%"="", "*"="", ":"="", "|"="", "\""="", "<"="", ">"=""))
|
||||
|
||||
@@ -773,6 +779,48 @@ GLOBAL_LIST_INIT(binary, list("0","1"))
|
||||
shuffle_inplace(rearranged)
|
||||
return "[prefix][jointext(rearranged, " ")]"
|
||||
|
||||
/proc/autocorrect(var/input as text) // syntax is "stringtoreplace"="stringtoreplacewith"
|
||||
return input = replace_characters(input, list(
|
||||
" i "=" I ",
|
||||
"i'm"="I'm",
|
||||
"s's"="s'",
|
||||
"isnt"="isn't",
|
||||
"dont"="don't",
|
||||
"shouldnt"="shouldn't",
|
||||
" ive "=" I've ",
|
||||
"whos"="who's",
|
||||
"whove"="who've",
|
||||
"whod"="who’d",
|
||||
"whats"="what’s",
|
||||
"whatd"="what’d",
|
||||
"thats"="that’s",
|
||||
"thatll"="that’ll",
|
||||
"thatd"="that’d",
|
||||
" nows "=" now’s ",
|
||||
"isnt"="isn’t",
|
||||
"arent"="aren’t",
|
||||
"wasnt"="wasn’t",
|
||||
"werent"="weren’t",
|
||||
"havent"="haven’t",
|
||||
"hasnt"="hasn’t",
|
||||
"hadnt"="hadn’t",
|
||||
"doesnt"="doesn’t",
|
||||
"didnt"="didn’t",
|
||||
"couldnt"="couldn’t",
|
||||
"wouldnt"="wouldn’t",
|
||||
"mustnt"="mustn’t",
|
||||
" alot "=" a lot ",
|
||||
" allthough"=" although",
|
||||
"shouldnt"="shouldn’t"
|
||||
))
|
||||
|
||||
/*
|
||||
* Text modification
|
||||
*/
|
||||
/proc/replace_characters(var/t,var/list/repl_chars)
|
||||
for(var/char in repl_chars)
|
||||
t = replacetext(t, char, repl_chars[char])
|
||||
return t
|
||||
|
||||
#define is_alpha(X) ((text2ascii(X) <= 122) && (text2ascii(X) >= 97))
|
||||
#define is_digit(X) ((length(X) == 1) && (length(text2num(X)) == 1))
|
||||
#define is_digit(X) ((length(X) == 1) && (length(text2num(X)) == 1))
|
||||
|
||||
@@ -444,11 +444,8 @@ Turf and target are separate in case you want to teleport some distance from a t
|
||||
var/y = min(world.maxy, max(1, A.y + dy))
|
||||
return locate(x,y,A.z)
|
||||
|
||||
#if DM_VERSION > 513
|
||||
#warn if you're getting this warning it means 513 is stable
|
||||
#warn and you should remove this tidbit
|
||||
#endif
|
||||
#if DM_VERSION < 513
|
||||
#warn what the fuck are you doing? Compile on 513+ not below.
|
||||
/proc/arctan(x)
|
||||
var/y=arcsin(x/sqrt(1+x*x))
|
||||
return y
|
||||
@@ -1505,6 +1502,10 @@ GLOBAL_DATUM_INIT(dview_mob, /mob/dview, new)
|
||||
var/list/blocked = list(/obj/item/reagent_containers/food/drinks/soda_cans,
|
||||
/obj/item/reagent_containers/food/drinks/bottle
|
||||
)
|
||||
blocked |= typesof(/obj/item/reagent_containers/food/drinks/prospacillin,
|
||||
/obj/item/reagent_containers/food/drinks/diminicillin
|
||||
)
|
||||
|
||||
return pick(subtypesof(/obj/item/reagent_containers/food/drinks) - blocked)
|
||||
|
||||
//For these two procs refs MUST be ref = TRUE format like typecaches!
|
||||
@@ -1612,4 +1613,4 @@ GLOBAL_DATUM_INIT(dview_mob, /mob/dview, new)
|
||||
if(190)
|
||||
return "."
|
||||
if(189)
|
||||
return "-"
|
||||
return "-"
|
||||
|
||||
@@ -0,0 +1,96 @@
|
||||
/**
|
||||
* handles adding verbs and updating the stat panel browser
|
||||
*
|
||||
* pass the verb type path to this instead of adding it directly to verbs so the statpanel can update
|
||||
* Arguments:
|
||||
* * target - Who the verb is being added to, client or mob typepath
|
||||
* * verb - typepath to a verb, or a list of verbs, supports lists of lists
|
||||
*/
|
||||
/proc/add_verb(client/target, verb_or_list_to_add)
|
||||
if(!target)
|
||||
CRASH("add_verb called without a target")
|
||||
if(IsAdminAdvancedProcCall())
|
||||
return
|
||||
var/mob/mob_target = null
|
||||
|
||||
if(ismob(target))
|
||||
mob_target = target
|
||||
target = mob_target.client
|
||||
else if(!istype(target, /client))
|
||||
CRASH("add_verb called on a non-mob and non-client")
|
||||
var/list/verbs_list = list()
|
||||
if(!islist(verb_or_list_to_add))
|
||||
verbs_list += verb_or_list_to_add
|
||||
else
|
||||
var/list/verb_listref = verb_or_list_to_add
|
||||
var/list/elements_to_process = verb_listref.Copy()
|
||||
while(length(elements_to_process))
|
||||
var/element_or_list = elements_to_process[length(elements_to_process)] //Last element
|
||||
elements_to_process.len--
|
||||
if(islist(element_or_list))
|
||||
elements_to_process += element_or_list //list/a += list/b adds the contents of b into a, not the reference to the list itself
|
||||
else
|
||||
verbs_list += element_or_list
|
||||
|
||||
if(mob_target)
|
||||
mob_target.verbs += verbs_list
|
||||
if(!target)
|
||||
return //Our work is done.
|
||||
else
|
||||
target.verbs += verbs_list
|
||||
|
||||
var/list/output_list = list()
|
||||
for(var/thing in verbs_list)
|
||||
var/procpath/verb_to_add = thing
|
||||
output_list[++output_list.len] = list(verb_to_add.category, verb_to_add.name)
|
||||
output_list = url_encode(json_encode(output_list))
|
||||
|
||||
target << output("[output_list];", "statbrowser:add_verb_list")
|
||||
|
||||
/**
|
||||
* handles removing verb and sending it to browser to update, use this for removing verbs
|
||||
*
|
||||
* pass the verb type path to this instead of removing it from verbs so the statpanel can update
|
||||
* Arguments:
|
||||
* * target - Who the verb is being removed from, client or mob typepath
|
||||
* * verb - typepath to a verb, or a list of verbs, supports lists of lists
|
||||
*/
|
||||
/proc/remove_verb(client/target, verb_or_list_to_remove)
|
||||
if(IsAdminAdvancedProcCall())
|
||||
return
|
||||
|
||||
var/mob/mob_target = null
|
||||
if(ismob(target))
|
||||
mob_target = target
|
||||
target = mob_target.client
|
||||
else if(!istype(target, /client))
|
||||
CRASH("remove_verb called on a non-mob and non-client")
|
||||
|
||||
var/list/verbs_list = list()
|
||||
if(!islist(verb_or_list_to_remove))
|
||||
verbs_list += verb_or_list_to_remove
|
||||
else
|
||||
var/list/verb_listref = verb_or_list_to_remove
|
||||
var/list/elements_to_process = verb_listref.Copy()
|
||||
while(length(elements_to_process))
|
||||
var/element_or_list = elements_to_process[length(elements_to_process)] //Last element
|
||||
elements_to_process.len--
|
||||
if(islist(element_or_list))
|
||||
elements_to_process += element_or_list //list/a += list/b adds the contents of b into a, not the reference to the list itself
|
||||
else
|
||||
verbs_list += element_or_list
|
||||
|
||||
if(mob_target)
|
||||
mob_target.verbs -= verbs_list
|
||||
if(!target)
|
||||
return //Our work is done.
|
||||
else
|
||||
target.verbs -= verbs_list
|
||||
|
||||
var/list/output_list = list()
|
||||
for(var/thing in verbs_list)
|
||||
var/procpath/verb_to_remove = thing
|
||||
output_list[++output_list.len] = list(verb_to_remove.category, verb_to_remove.name)
|
||||
output_list = url_encode(json_encode(output_list))
|
||||
|
||||
target << output("[output_list];", "statbrowser:remove_verb_list")
|
||||
@@ -145,7 +145,7 @@ GLOBAL_LIST_INIT(bitfields, list(
|
||||
"VOICEBOX_TOGGLABLE" = VOICEBOX_TOGGLABLE,
|
||||
"VOICEBOX_DISABLED" = VOICEBOX_DISABLED,
|
||||
"IGNORE_HAT_TOSS" = IGNORE_HAT_TOSS,
|
||||
"SCAN_REAGENTS" = SCAN_REAGENTS
|
||||
"SCAN_REAGENTS" = SCAN_REAGENTS,
|
||||
),
|
||||
"tesla_flags" = list(
|
||||
"TESLA_MOB_DAMAGE" = TESLA_MOB_DAMAGE,
|
||||
|
||||
@@ -199,6 +199,6 @@ GLOBAL_LIST_INIT(station_numerals, greek_letters + phonetic_alphabet + numbers_a
|
||||
|
||||
GLOBAL_LIST_INIT(admiral_messages, list("Do you know how expensive these stations are?","Stop wasting my time.","I was sleeping, thanks a lot.","Stand and fight you cowards!","You knew the risks coming in.","Stop being paranoid.","Whatever's broken just build a new one.","No.", "<i>null</i>","<i>Error: No comment given.</i>", "It's a good day to die!"))
|
||||
|
||||
GLOBAL_LIST_INIT(speech_verbs, list("default", "says", "gibbers", "gekkers", "states", "chitters", "declares", "bellows", "buzzes" ,"beeps", "chirps" ,"hisses" ,"poofs" ,"rattles", "mewls", "barks", "blorbles", "squeaks", "squawks", "flutters"))
|
||||
GLOBAL_LIST_INIT(speech_verbs, list("default", "says", "gibbers", "gekkers", "states", "chitters", "declares", "bellows", "buzzes" ,"beeps", "chirps" ,"hisses" ,"poofs" ,"rattles", "mewls", "barks", "blorbles", "squeaks", "squawks", "flutters", "mrowls"))
|
||||
|
||||
GLOBAL_LIST_INIT(roundstart_tongues, list("default","human tongue" = /obj/item/organ/tongue, "lizard tongue" = /obj/item/organ/tongue/lizard, "skeleton tongue" = /obj/item/organ/tongue/bone, "fly tongue" = /obj/item/organ/tongue/fly, "ipc tongue" = /obj/item/organ/tongue/robot/ipc))
|
||||
GLOBAL_LIST_INIT(roundstart_tongues, list("default","human tongue" = /obj/item/organ/tongue, "lizard tongue" = /obj/item/organ/tongue/lizard, "skeleton tongue" = /obj/item/organ/tongue/bone, "fly tongue" = /obj/item/organ/tongue/fly, "ipc tongue" = /obj/item/organ/tongue/robot/ipc, "kitty tongue" = /obj/item/organ/tongue/kitty))
|
||||
|
||||
@@ -118,5 +118,24 @@ GLOBAL_LIST_INIT(maintenance_loot, list(
|
||||
/obj/item/autosurgeon/vagina = 1,
|
||||
/obj/item/autosurgeon/breasts = 1,
|
||||
/obj/item/autosurgeon/womb = 1,
|
||||
/obj/item/toy/plush/random = 1
|
||||
/obj/item/toy/plush/random = 1,
|
||||
/obj/item/grenade/spawnergrenade/clustaur = 1
|
||||
))
|
||||
|
||||
GLOBAL_LIST_INIT(ratking_trash, list(//Garbage: used by the regal rat mob when spawning garbage.
|
||||
/obj/item/cigbutt,
|
||||
/obj/item/trash/cheesie,
|
||||
/obj/item/trash/candy,
|
||||
/obj/item/trash/chips,
|
||||
/obj/item/trash/pistachios,
|
||||
/obj/item/trash/plate,
|
||||
/obj/item/trash/popcorn,
|
||||
/obj/item/trash/raisins,
|
||||
/obj/item/trash/sosjerky,
|
||||
/obj/item/trash/syndi_cakes))
|
||||
|
||||
GLOBAL_LIST_INIT(ratking_coins, list(//Coins: Used by the regal rat mob when spawning coins.
|
||||
/obj/item/coin/iron,
|
||||
/obj/item/coin/silver,
|
||||
/obj/item/coin/gold,
|
||||
/obj/item/coin/plasma))
|
||||
|
||||
+22
-4
@@ -75,6 +75,9 @@
|
||||
if(notransform)
|
||||
return
|
||||
|
||||
if(SEND_SIGNAL(src, COMSIG_MOB_CLICKON, A, params) & COMSIG_MOB_CANCEL_CLICKON)
|
||||
return
|
||||
|
||||
var/list/modifiers = params2list(params)
|
||||
if(modifiers["shift"] && modifiers["middle"])
|
||||
ShiftMiddleClickOn(A)
|
||||
@@ -351,8 +354,10 @@
|
||||
Unused except for AI
|
||||
*/
|
||||
/mob/proc/AltClickOn(atom/A)
|
||||
if(!A.AltClick(src))
|
||||
altclick_listed_turf(A)
|
||||
. = SEND_SIGNAL(src, COMSIG_MOB_ALTCLICKON, A)
|
||||
if(. & COMSIG_MOB_CANCEL_CLICKON)
|
||||
return
|
||||
A.AltClick(src)
|
||||
|
||||
/mob/proc/altclick_listed_turf(atom/A)
|
||||
var/turf/T = get_turf(A)
|
||||
@@ -361,7 +366,9 @@
|
||||
listed_turf = null
|
||||
else if(TurfAdjacent(T))
|
||||
listed_turf = T
|
||||
client.statpanel = T.name
|
||||
client << output("[url_encode(json_encode(T.name))];", "statbrowser:create_listedturf")
|
||||
|
||||
|
||||
|
||||
/mob/living/carbon/AltClickOn(atom/A)
|
||||
if(!stat && mind && iscarbon(A) && A != src)
|
||||
@@ -373,7 +380,18 @@
|
||||
..()
|
||||
|
||||
/atom/proc/AltClick(mob/user)
|
||||
. = SEND_SIGNAL(src, COMSIG_CLICK_ALT, user)
|
||||
SEND_SIGNAL(src, COMSIG_CLICK_ALT, user)
|
||||
var/turf/T = get_turf(src)
|
||||
if(T && (isturf(loc) || isturf(src)) && user.TurfAdjacent(T))
|
||||
user.listed_turf = T
|
||||
user.client << output("[url_encode(json_encode(T.name))];", "statbrowser:create_listedturf")
|
||||
|
||||
/atom/proc/AltClickNoInteract(mob/user, atom/A)
|
||||
var/turf/T = get_turf(A)
|
||||
if(T && user.TurfAdjacent(T))
|
||||
user.listed_turf = T
|
||||
user.client << output("[url_encode(json_encode(T.name))];", "statbrowser:create_listedturf")
|
||||
|
||||
|
||||
/mob/proc/TurfAdjacent(turf/T)
|
||||
return T.Adjacent(src)
|
||||
|
||||
@@ -162,11 +162,21 @@
|
||||
desc = "Some food would be good right about now."
|
||||
icon_state = "hungry"
|
||||
|
||||
/obj/screen/alert/thirsty
|
||||
name = "Thirsty"
|
||||
desc = "Some water would be good right about now."
|
||||
icon_state = "thirsty"
|
||||
|
||||
/obj/screen/alert/starving
|
||||
name = "Starving"
|
||||
desc = "You're severely malnourished. The hunger pains make moving around a chore."
|
||||
icon_state = "starving"
|
||||
|
||||
/obj/screen/alert/dehydrated
|
||||
name = "Dehydrated"
|
||||
desc = "You're severely dehydrated."
|
||||
icon_state = "dehydrated"
|
||||
|
||||
/obj/screen/alert/gross
|
||||
name = "Grossed out."
|
||||
desc = "That was kind of gross..."
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
var/icon/credits_icon = new(CREDITS_PATH)
|
||||
LAZYINITLIST(credits)
|
||||
var/list/_credits = credits
|
||||
verbs += /client/proc/ClearCredits
|
||||
add_verb(src, /client/proc/ClearCredits)
|
||||
var/static/list/credit_order_for_this_round
|
||||
if(isnull(credit_order_for_this_round))
|
||||
credit_order_for_this_round = list("Thanks for playing!") + (shuffle(icon_states(credits_icon)) - "Thanks for playing!")
|
||||
@@ -21,13 +21,13 @@
|
||||
_credits += new /obj/screen/credit(null, I, src, credits_icon)
|
||||
sleep(CREDIT_SPAWN_SPEED)
|
||||
sleep(CREDIT_ROLL_SPEED - CREDIT_SPAWN_SPEED)
|
||||
verbs -= /client/proc/ClearCredits
|
||||
remove_verb(src, /client/proc/ClearCredits)
|
||||
qdel(credits_icon)
|
||||
|
||||
/client/proc/ClearCredits()
|
||||
set name = "Hide Credits"
|
||||
set category = "OOC"
|
||||
verbs -= /client/proc/ClearCredits
|
||||
remove_verb(src, /client/proc/ClearCredits)
|
||||
QDEL_LIST(credits)
|
||||
credits = null
|
||||
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
using.screen_loc = ui_movi
|
||||
static_inventory += using
|
||||
|
||||
//CITADEL CHANGES - sprint button
|
||||
/* //CITADEL CHANGES - sprint button
|
||||
using = new /obj/screen/sprintbutton
|
||||
using.icon = tg_ui_icon_to_cit_ui(ui_style)
|
||||
using.icon_state = (owner.sprinting ? "act_sprint_on" : "act_sprint")
|
||||
@@ -139,7 +139,7 @@
|
||||
using.screen_loc = ui_sprintbufferloc
|
||||
sprint_buffer = using
|
||||
static_inventory += using
|
||||
|
||||
*/
|
||||
|
||||
using = new /obj/screen/drop()
|
||||
using.icon = ui_style
|
||||
@@ -323,12 +323,12 @@
|
||||
arousal.icon_state = (owner.canbearoused == 1 ? "arousal0" : "")
|
||||
infodisplay += arousal
|
||||
|
||||
staminas = new /obj/screen/staminas()
|
||||
infodisplay += staminas
|
||||
// staminas = new /obj/screen/staminas()
|
||||
// infodisplay += staminas
|
||||
|
||||
if(!CONFIG_GET(flag/disable_stambuffer))
|
||||
staminabuffer = new /obj/screen/staminabuffer()
|
||||
infodisplay += staminabuffer
|
||||
// if(!CONFIG_GET(flag/disable_stambuffer))
|
||||
// staminabuffer = new /obj/screen/staminabuffer()
|
||||
// infodisplay += staminabuffer
|
||||
//END OF CIT CHANGES
|
||||
|
||||
healthdoll = new /obj/screen/healthdoll()
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
var/last_parallax_shift //world.time of last update
|
||||
var/parallax_throttle = 0 //ds between updates
|
||||
var/parallax_movedir = 0
|
||||
var/parallax_layers_max = 3
|
||||
var/parallax_layers_max = 4
|
||||
var/parallax_animate_timer
|
||||
|
||||
/datum/hud/proc/create_parallax(mob/viewmob)
|
||||
@@ -22,7 +22,15 @@
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layer_1(null, C.view)
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layer_2(null, C.view)
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/planet(null, C.view)
|
||||
if(SSparallax.random_layer)
|
||||
C.parallax_layers_cached += new SSparallax.random_layer
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layer_3(null, C.view)
|
||||
if(SSmapping.config?.map_name == "Layenia Station")
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layenia/horizon(null, C.view)
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layenia/clouds1(null, C.view)
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layenia/clouds2(null, C.view)
|
||||
C.parallax_layers_cached += new /obj/screen/parallax_layer/layenia/clouds3(null, C.view)
|
||||
|
||||
|
||||
C.parallax_layers = C.parallax_layers_cached.Copy()
|
||||
|
||||
@@ -64,24 +72,24 @@
|
||||
switch(C.prefs.parallax)
|
||||
if (PARALLAX_INSANE)
|
||||
C.parallax_throttle = FALSE
|
||||
C.parallax_layers_max = 4
|
||||
C.parallax_layers_max = 10
|
||||
return TRUE
|
||||
|
||||
if (PARALLAX_MED)
|
||||
C.parallax_throttle = PARALLAX_DELAY_MED
|
||||
C.parallax_layers_max = 2
|
||||
C.parallax_layers_max = 8
|
||||
return TRUE
|
||||
|
||||
if (PARALLAX_LOW)
|
||||
C.parallax_throttle = PARALLAX_DELAY_LOW
|
||||
C.parallax_layers_max = 1
|
||||
C.parallax_layers_max = 7
|
||||
return TRUE
|
||||
|
||||
if (PARALLAX_DISABLE)
|
||||
return FALSE
|
||||
|
||||
C.parallax_throttle = PARALLAX_DELAY_DEFAULT
|
||||
C.parallax_layers_max = 3
|
||||
C.parallax_layers_max = 10
|
||||
return TRUE
|
||||
|
||||
/datum/hud/proc/update_parallax_pref(mob/viewmob)
|
||||
@@ -167,7 +175,7 @@
|
||||
/datum/hud/proc/update_parallax()
|
||||
var/client/C = mymob.client
|
||||
var/turf/posobj = get_turf(C.eye)
|
||||
if(!posobj)
|
||||
if(!posobj)
|
||||
return
|
||||
var/area/areaobj = posobj.loc
|
||||
|
||||
@@ -296,19 +304,77 @@
|
||||
speed = 1.4
|
||||
layer = 3
|
||||
|
||||
/obj/screen/parallax_layer/random
|
||||
blend_mode = BLEND_OVERLAY
|
||||
speed = 3
|
||||
layer = 3
|
||||
|
||||
/obj/screen/parallax_layer/random/space_gas
|
||||
icon_state = "space_gas"
|
||||
|
||||
/obj/screen/parallax_layer/random/space_gas/Initialize(mapload, view)
|
||||
src.add_atom_colour(SSparallax.random_parallax_color, ADMIN_COLOUR_PRIORITY)
|
||||
|
||||
/obj/screen/parallax_layer/random/asteroids
|
||||
icon_state = "asteroids"
|
||||
|
||||
/obj/screen/parallax_layer/random/nebula
|
||||
icon_state = "nebula1"
|
||||
|
||||
/obj/screen/parallax_layer/planet
|
||||
icon_state = "planet"
|
||||
blend_mode = BLEND_OVERLAY
|
||||
absolute = TRUE //Status of seperation
|
||||
speed = 3
|
||||
layer = 30
|
||||
layer = 4
|
||||
|
||||
/obj/screen/parallax_layer/planet/update_status(mob/M)
|
||||
var/turf/T = get_turf(M)
|
||||
if(is_station_level(T.z))
|
||||
invisibility = 0
|
||||
else
|
||||
invisibility = INVISIBILITY_ABSTRACT
|
||||
var/client/C = M.client
|
||||
var/turf/posobj = get_turf(C.eye)
|
||||
if(!posobj)
|
||||
return
|
||||
invisibility = is_station_level(posobj.z) ? 0 : INVISIBILITY_ABSTRACT
|
||||
|
||||
/obj/screen/parallax_layer/planet/update_o()
|
||||
return //Shit wont move
|
||||
|
||||
//Layenia parallaxes
|
||||
|
||||
/obj/screen/parallax_layer/layenia
|
||||
icon_state = null
|
||||
blend_mode = BLEND_OVERLAY
|
||||
absolute = TRUE
|
||||
speed = 0.6
|
||||
layer = 5
|
||||
|
||||
/obj/screen/parallax_layer/layenia/horizon
|
||||
icon_state = "layeniahorizon"
|
||||
speed = 0.3
|
||||
absolute = FALSE
|
||||
|
||||
/obj/screen/parallax_layer/layenia/clouds1
|
||||
icon_state = "layenia1"
|
||||
speed = 0.6
|
||||
layer = 6
|
||||
|
||||
/obj/screen/parallax_layer/layenia/clouds2
|
||||
icon_state = "layenia2"
|
||||
speed = 1
|
||||
layer = 7
|
||||
|
||||
/obj/screen/parallax_layer/layenia/clouds3
|
||||
icon_state = "layenia3"
|
||||
speed = 1.4
|
||||
layer = 8
|
||||
|
||||
/obj/screen/parallax_layer/layenia/update_status(mob/M)
|
||||
var/client/C = M.client
|
||||
var/turf/posobj = get_turf(C.eye)
|
||||
if(!posobj)
|
||||
return
|
||||
invisibility = is_station_level(posobj.z) ? 0 : INVISIBILITY_ABSTRACT
|
||||
|
||||
/*
|
||||
/obj/screen/parallax_layer/tparallax1/update_status(mob/M)
|
||||
if(SSmapping.config?.map_name != "Layenia Station")
|
||||
*/
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
/obj/screen/plane_master/openspace
|
||||
name = "open space plane master"
|
||||
plane = FLOOR_OPENSPACE_PLANE
|
||||
plane = OPENSPACE_BACKDROP_PLANE
|
||||
appearance_flags = PLANE_MASTER
|
||||
blend_mode = BLEND_MULTIPLY
|
||||
alpha = 255
|
||||
|
||||
@@ -178,10 +178,10 @@
|
||||
var/list/banned_edits = list(NAMEOF(src, entries_by_type), NAMEOF(src, entries), NAMEOF(src, directory))
|
||||
return !(var_name in banned_edits) && ..()
|
||||
|
||||
/datum/controller/configuration/stat_entry()
|
||||
if(!statclick)
|
||||
statclick = new/obj/effect/statclick/debug(null, "Edit", src)
|
||||
stat("[name]:", statclick)
|
||||
|
||||
/datum/controller/configuration/stat_entry(msg)
|
||||
msg = "Edit"
|
||||
return msg
|
||||
|
||||
/datum/controller/configuration/proc/Get(entry_type)
|
||||
var/datum/config_entry/E = entry_type
|
||||
|
||||
@@ -367,6 +367,10 @@
|
||||
config_entry_value = 64
|
||||
min_val = 0
|
||||
|
||||
/datum/config_entry/number/ratcap
|
||||
config_entry_value = 64
|
||||
min_val = 0
|
||||
|
||||
/datum/config_entry/flag/disable_stambuffer
|
||||
|
||||
/datum/config_entry/keyed_list/box_random_engine
|
||||
|
||||
@@ -16,4 +16,4 @@
|
||||
|
||||
/datum/controller/proc/Recover()
|
||||
|
||||
/datum/controller/proc/stat_entry()
|
||||
/datum/controller/proc/stat_entry(msg)
|
||||
@@ -95,8 +95,6 @@ GLOBAL_REAL(Failsafe, /datum/controller/failsafe)
|
||||
/datum/controller/failsafe/proc/defcon_pretty()
|
||||
return defcon
|
||||
|
||||
/datum/controller/failsafe/stat_entry()
|
||||
if(!statclick)
|
||||
statclick = new/obj/effect/statclick/debug(null, "Initializing...", src)
|
||||
|
||||
stat("Failsafe Controller:", statclick.update("Defcon: [defcon_pretty()] (Interval: [Failsafe.processing_interval] | Iteration: [Failsafe.master_iteration])"))
|
||||
/datum/controller/failsafe/stat_entry(msg)
|
||||
msg = "Defcon: [defcon_pretty()] (Interval: [Failsafe.processing_interval] | Iteration: [Failsafe.master_iteration])"
|
||||
return msg
|
||||
@@ -24,11 +24,9 @@ GLOBAL_REAL(GLOB, /datum/controller/global_vars)
|
||||
//fuck off kevinz
|
||||
return QDEL_HINT_IWILLGC
|
||||
|
||||
/datum/controller/global_vars/stat_entry()
|
||||
if(!statclick)
|
||||
statclick = new/obj/effect/statclick/debug(null, "Initializing...", src)
|
||||
|
||||
stat("Globals:", statclick.update("Edit"))
|
||||
/datum/controller/global_vars/stat_entry(msg)
|
||||
msg = "Edit"
|
||||
return msg
|
||||
|
||||
/datum/controller/global_vars/vv_edit_var(var_name, var_value)
|
||||
if(gvars_datum_protected_varlist[var_name])
|
||||
|
||||
@@ -54,7 +54,7 @@ GLOBAL_REAL(Master, /datum/controller/master) = new
|
||||
var/static/restart_clear = 0
|
||||
var/static/restart_timeout = 0
|
||||
var/static/restart_count = 0
|
||||
|
||||
|
||||
var/static/random_seed
|
||||
|
||||
//current tick limit, assigned before running a subsystem.
|
||||
@@ -69,7 +69,7 @@ GLOBAL_REAL(Master, /datum/controller/master) = new
|
||||
if(!random_seed)
|
||||
random_seed = (TEST_RUN_PARAMETER in world.params) ? 29051994 : rand(1, 1e9)
|
||||
rand_seed(random_seed)
|
||||
|
||||
|
||||
var/list/_subsystems = list()
|
||||
subsystems = _subsystems
|
||||
if (Master != src)
|
||||
@@ -584,12 +584,9 @@ GLOBAL_REAL(Master, /datum/controller/master) = new
|
||||
|
||||
|
||||
|
||||
/datum/controller/master/stat_entry()
|
||||
if(!statclick)
|
||||
statclick = new/obj/effect/statclick/debug(null, "Initializing...", src)
|
||||
|
||||
stat("Byond:", "(FPS:[world.fps]) (TickCount:[world.time/world.tick_lag]) (TickDrift:[round(Master.tickdrift,1)]([round((Master.tickdrift/(world.time/world.tick_lag))*100,0.1)]%))")
|
||||
stat("Master Controller:", statclick.update("(TickRate:[Master.processing]) (Iteration:[Master.iteration])"))
|
||||
/datum/controller/master/stat_entry(msg)
|
||||
msg = "(TickRate:[Master.processing]) (Iteration:[Master.iteration]) (TickLimit: [round(Master.current_ticklimit, 0.1)])"
|
||||
return msg
|
||||
|
||||
/datum/controller/master/StartLoadingMap()
|
||||
//disallow more than one map to load at once, multithreading it will just cause race conditions
|
||||
|
||||
@@ -165,10 +165,9 @@
|
||||
log_world(msg)
|
||||
return time
|
||||
|
||||
//hook for printing stats to the "MC" statuspanel for admins to see performance and related stats etc.
|
||||
|
||||
/datum/controller/subsystem/stat_entry(msg)
|
||||
if(!statclick)
|
||||
statclick = new/obj/effect/statclick/debug(null, "Initializing...", src)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -177,11 +176,7 @@
|
||||
else
|
||||
msg = "OFFLINE\t[msg]"
|
||||
|
||||
var/title = name
|
||||
if (can_fire)
|
||||
title = "\[[state_letter()]][title]"
|
||||
|
||||
stat(title, statclick.update(msg))
|
||||
return msg
|
||||
|
||||
/datum/controller/subsystem/proc/state_letter()
|
||||
switch (state)
|
||||
|
||||
@@ -7,9 +7,9 @@ SUBSYSTEM_DEF(acid)
|
||||
var/list/currentrun = list()
|
||||
var/list/processing = list()
|
||||
|
||||
/datum/controller/subsystem/acid/stat_entry()
|
||||
..("P:[processing.len]")
|
||||
|
||||
/datum/controller/subsystem/acid/stat_entry(msg)
|
||||
msg = "P:[length(processing)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/acid/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
|
||||
@@ -6,12 +6,13 @@ SUBSYSTEM_DEF(adjacent_air)
|
||||
priority = FIRE_PRIORITY_ATMOS_ADJACENCY
|
||||
var/list/queue = list()
|
||||
|
||||
/datum/controller/subsystem/adjacent_air/stat_entry()
|
||||
/datum/controller/subsystem/adjacent_air/stat_entry(msg)
|
||||
#ifdef TESTING
|
||||
..("P:[length(queue)], S:[GLOB.atmos_adjacent_savings[1]], T:[GLOB.atmos_adjacent_savings[2]]")
|
||||
msg = "P:[length(queue)], S:[GLOB.atmos_adjacent_savings[1]], T:[GLOB.atmos_adjacent_savings[2]]"
|
||||
#else
|
||||
..("P:[length(queue)]")
|
||||
msg = "P:[length(queue)]"
|
||||
#endif
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/adjacent_air/Initialize()
|
||||
while(length(queue))
|
||||
|
||||
@@ -257,9 +257,8 @@ SUBSYSTEM_DEF(air)
|
||||
#ifdef VISUALIZE_ACTIVE_TURFS
|
||||
T.add_atom_colour("#00ff00", TEMPORARY_COLOUR_PRIORITY)
|
||||
#endif
|
||||
T.excited = 1
|
||||
active_turfs |= T
|
||||
SSair_turfs.currentrun |= T
|
||||
T.excited = TRUE
|
||||
active_turfs[T] = SSair_turfs.currentrun[T] = TRUE
|
||||
if(blockchanges && T.excited_group)
|
||||
T.excited_group.garbage_collect()
|
||||
add_to_react_queue(T)
|
||||
@@ -275,10 +274,9 @@ SUBSYSTEM_DEF(air)
|
||||
|
||||
/datum/controller/subsystem/air/proc/add_to_react_queue(turf/open/T)
|
||||
if(istype(T) && T.air)
|
||||
turf_react_queue |= T
|
||||
turf_react_queue[T] = TRUE
|
||||
if(currentpart == SSAIR_REACTQUEUE)
|
||||
currentrun |= T
|
||||
return
|
||||
currentrun[T] = TRUE
|
||||
|
||||
/datum/controller/subsystem/air/proc/remove_from_react_queue(turf/open/T)
|
||||
turf_react_queue -= T
|
||||
|
||||
@@ -9,7 +9,8 @@ SUBSYSTEM_DEF(augury)
|
||||
var/list/observers_given_action = list()
|
||||
|
||||
/datum/controller/subsystem/augury/stat_entry(msg)
|
||||
..("W:[watchers.len]|D:[doombringers.len]")
|
||||
msg = "W:[watchers.len]|D:[length(doombringers)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/augury/proc/register_doom(atom/A, severity)
|
||||
doombringers[A] = severity
|
||||
|
||||
@@ -20,7 +20,8 @@ SUBSYSTEM_DEF(disease)
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/disease/stat_entry(msg)
|
||||
..("P:[active_diseases.len]")
|
||||
msg = "P:[length(active_diseases)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/disease/proc/get_disease_name(id)
|
||||
var/datum/disease/advance/A = archive_diseases[id]
|
||||
|
||||
@@ -7,9 +7,9 @@ SUBSYSTEM_DEF(fire_burning)
|
||||
var/list/currentrun = list()
|
||||
var/list/processing = list()
|
||||
|
||||
/datum/controller/subsystem/fire_burning/stat_entry()
|
||||
..("P:[processing.len]")
|
||||
|
||||
/datum/controller/subsystem/fire_burning/stat_entry(msg)
|
||||
msg = "P:[length(processing)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/fire_burning/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
|
||||
@@ -57,7 +57,7 @@ SUBSYSTEM_DEF(garbage)
|
||||
msg += "TGR:[round((totalgcs/(totaldels+totalgcs))*100, 0.01)]%"
|
||||
msg += " P:[pass_counts.Join(",")]"
|
||||
msg += "|F:[fail_counts.Join(",")]"
|
||||
..(msg)
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/garbage/Shutdown()
|
||||
//Adds the del() log to the qdel log file
|
||||
|
||||
@@ -8,10 +8,11 @@ SUBSYSTEM_DEF(idlenpcpool)
|
||||
var/list/currentrun = list()
|
||||
var/static/list/idle_mobs_by_zlevel[][]
|
||||
|
||||
/datum/controller/subsystem/idlenpcpool/stat_entry()
|
||||
/datum/controller/subsystem/idlenpcpool/stat_entry(msg)
|
||||
var/list/idlelist = GLOB.simple_animals[AI_IDLE]
|
||||
var/list/zlist = GLOB.simple_animals[AI_Z_OFF]
|
||||
..("IdleNPCS:[idlelist.len]|Z:[zlist.len]")
|
||||
msg = "IdleNPCS:[length(idlelist)]|Z:[length(zlist)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/idlenpcpool/proc/MaxZChanged()
|
||||
if (!islist(idle_mobs_by_zlevel))
|
||||
|
||||
@@ -33,10 +33,10 @@ SUBSYSTEM_DEF(input)
|
||||
"Tab" = "\".winset \\\"input.focus=true?map.focus=true input.background-color=[COLOR_INPUT_DISABLED]:input.focus=true input.background-color=[COLOR_INPUT_ENABLED]\\\"\"",
|
||||
"O" = "ooc",
|
||||
"Ctrl+O" = "looc",
|
||||
"Ctrl+T" = "say",
|
||||
"Ctrl+T" = "say_indicator",
|
||||
"T" = "say_indicator",
|
||||
"Y" = "whisper",
|
||||
"Ctrl+M" = "me",
|
||||
"Ctrl+M" = "me_indicato",
|
||||
"M" = "me_indicator",
|
||||
"Back" = "\".winset \\\"input.text=\\\"\\\"\\\"\"", // This makes it so backspace can remove default inputs
|
||||
"Any" = "\"KeyDown \[\[*\]\]\"",
|
||||
@@ -50,9 +50,9 @@ SUBSYSTEM_DEF(input)
|
||||
"old_hotkeys" = list(
|
||||
"Tab" = "\".winset \\\"mainwindow.macro=old_default input.focus=true input.background-color=[COLOR_INPUT_ENABLED]\\\"\"",
|
||||
"O" = "ooc",
|
||||
"T" = "say",
|
||||
"T" = "say_indicator",
|
||||
"Ctrl+T" = "say_indicator",
|
||||
"M" = "me",
|
||||
"M" = "me_indicator",
|
||||
"Ctrl+M" = "me_indicator",
|
||||
"Back" = "\".winset \\\"input.text=\\\"\\\"\\\"\"", // This makes it so backspace can remove default inputs
|
||||
"Any" = "\"KeyDown \[\[*\]\]\"",
|
||||
|
||||
@@ -14,6 +14,7 @@ SUBSYSTEM_DEF(job)
|
||||
|
||||
var/overflow_role = "Assistant"
|
||||
|
||||
|
||||
/datum/controller/subsystem/job/Initialize(timeofday)
|
||||
SSmapping.HACK_LoadMapConfig()
|
||||
if(!occupations.len)
|
||||
@@ -395,7 +396,7 @@ SUBSYSTEM_DEF(job)
|
||||
if(!joined_late)
|
||||
var/obj/S = null
|
||||
for(var/obj/effect/landmark/start/sloc in GLOB.start_landmarks_list)
|
||||
if(sloc.name != rank)
|
||||
if(sloc.name != rank && sloc.type != job.override_roundstart_spawn)
|
||||
S = sloc //so we can revert to spawning them on top of eachother if something goes wrong
|
||||
continue
|
||||
if(locate(/mob/living) in sloc.loc)
|
||||
@@ -415,24 +416,36 @@ SUBSYSTEM_DEF(job)
|
||||
if(H.mind)
|
||||
H.mind.assigned_role = rank
|
||||
|
||||
//Job loadout, equipping, and flavortext when spawning
|
||||
if(job)
|
||||
if(!job.dresscodecompliant)// CIT CHANGE - dress code compliance
|
||||
equip_loadout(N, H) // CIT CHANGE - allows players to spawn with loadout items
|
||||
var/new_mob = job.equip(H, null, null, joined_late)
|
||||
if(ismob(new_mob))
|
||||
var/list/handle_storage = equip_loadout(N, H) //Loadout gear
|
||||
var/new_mob = job.equip(H, null, null, joined_late) //Job gear
|
||||
|
||||
if(ismob(new_mob)) //The above doesnt return a value, but we check this anyways or else everything breaks!
|
||||
H = new_mob
|
||||
if(!joined_late)
|
||||
N.new_character = H
|
||||
else
|
||||
M = H
|
||||
|
||||
SSpersistence.antag_rep_change[M.client.ckey] += job.GetAntagRep()
|
||||
if(LAZYLEN(handle_storage)) //equip_loadout returned a list. This list is backpack contents we should store, as by now we should have a backpack and a single reference mob
|
||||
if(ishuman(H))
|
||||
var/mob/living/carbon/human/_H = H
|
||||
if(_H.back)
|
||||
for(var/atom/movable/A in handle_storage)
|
||||
if(!SEND_SIGNAL(_H.back, COMSIG_TRY_STORAGE_INSERT, A, null, TRUE, TRUE))
|
||||
A.forceMove(get_turf(H)) //Try and store into the backpack. If the backpack is full, drop it to the ground
|
||||
else //No backpack
|
||||
for(var/atom/movable/A in handle_storage)
|
||||
A.forceMove(get_turf(H))
|
||||
|
||||
//Flavortext
|
||||
var/display_rank = rank
|
||||
if(M.client && M.client.prefs && M.client.prefs.alt_titles_preferences[rank])
|
||||
display_rank = M.client.prefs.alt_titles_preferences[rank]
|
||||
|
||||
to_chat(M, "<b>You are the [display_rank].</b>")
|
||||
|
||||
var/display_rank = rank
|
||||
if(M.client && M.client.prefs && M.client.prefs.alt_titles_preferences[rank])
|
||||
display_rank = M.client.prefs.alt_titles_preferences[rank]
|
||||
to_chat(M, "<b>You are the [display_rank].</b>")
|
||||
if(job)
|
||||
to_chat(M, "<b>As the [display_rank] you answer directly to [job.supervisors]. Special circumstances may change this.</b>")
|
||||
to_chat(M, "<b>To speak on your departments radio, use the :h button. To see others, look closely at your headset.</b>")
|
||||
if(job.req_admin_notify)
|
||||
@@ -442,11 +455,15 @@ SUBSYSTEM_DEF(job)
|
||||
if(CONFIG_GET(number/minimal_access_threshold))
|
||||
to_chat(M, "<span class='notice'><B>As this station was initially staffed with a [CONFIG_GET(flag/jobs_have_minimal_access) ? "full crew, only your job's necessities" : "skeleton crew, additional access may"] have been added to your ID card.</B></span>")
|
||||
|
||||
if(job && H)
|
||||
if(job.dresscodecompliant)// CIT CHANGE - dress code compliance
|
||||
equip_loadout(N, H) // CIT CHANGE - allows players to spawn with loadout items
|
||||
job.after_spawn(H, M, joined_late) // note: this happens before the mob has a key! M will always have a client, H might not.
|
||||
equip_loadout(N, H, TRUE)//CIT CHANGE - makes players spawn with in-backpack loadout items properly. A little hacky but it works
|
||||
job.after_spawn(H, M, joined_late)
|
||||
|
||||
//Account ID. ID is handled by human initialization
|
||||
if(ishuman(H))
|
||||
var/mob/living/carbon/human/wageslave = H
|
||||
to_chat(M, "<b><span class='big'>Your account ID is [wageslave.account_id]</span></b>")
|
||||
to_chat(M, "<b><span class='notice'>You do not have a pin, can set your pin at an ATM.</b>")
|
||||
if(H.mind)
|
||||
H.mind.memory += "Your account ID is [wageslave.account_id].<BR>"
|
||||
|
||||
return H
|
||||
|
||||
@@ -640,4 +657,4 @@ SUBSYSTEM_DEF(job)
|
||||
. |= player.mind
|
||||
|
||||
/datum/controller/subsystem/job/proc/JobDebug(message)
|
||||
log_job_debug(message)
|
||||
log_job_debug(message)
|
||||
|
||||
@@ -7,10 +7,13 @@ SUBSYSTEM_DEF(lighting)
|
||||
wait = 2
|
||||
init_order = INIT_ORDER_LIGHTING
|
||||
flags = SS_TICKER
|
||||
var/static/list/sources_queue = list() // List of lighting sources queued for update.
|
||||
var/static/list/corners_queue = list() // List of lighting corners queued for update.
|
||||
var/static/list/objects_queue = list() // List of lighting objects queued for update.
|
||||
|
||||
/datum/controller/subsystem/lighting/stat_entry()
|
||||
..("L:[GLOB.lighting_update_lights.len]|C:[GLOB.lighting_update_corners.len]|O:[GLOB.lighting_update_objects.len]")
|
||||
|
||||
/datum/controller/subsystem/lighting/stat_entry(msg)
|
||||
msg = "L:[length(sources_queue)]|C:[length(corners_queue)]|O:[length(objects_queue)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/lighting/Initialize(timeofday)
|
||||
if(!initialized)
|
||||
|
||||
@@ -22,9 +22,10 @@ SUBSYSTEM_DEF(machines)
|
||||
NewPN.add_cable(PC)
|
||||
propagate_network(PC,PC.powernet)
|
||||
|
||||
/datum/controller/subsystem/machines/stat_entry()
|
||||
..("M:[processing.len]|PN:[powernets.len]")
|
||||
|
||||
/datum/controller/subsystem/machines/stat_entry(msg)
|
||||
msg = "M:[length(processing)]|PN:[length(powernets)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/machines/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
|
||||
@@ -8,9 +8,11 @@ SUBSYSTEM_DEF(mobs)
|
||||
var/static/list/clients_by_zlevel[][]
|
||||
var/static/list/dead_players_by_zlevel[][] = list(list()) // Needs to support zlevel 1 here, MaxZChanged only happens when z2 is created and new_players can login before that.
|
||||
var/static/list/cubemonkeys = list()
|
||||
var/static/list/cheeserats = list()
|
||||
|
||||
/datum/controller/subsystem/mobs/stat_entry()
|
||||
..("P:[GLOB.mob_living_list.len]")
|
||||
/datum/controller/subsystem/mobs/stat_entry(msg)
|
||||
msg = "P:[length(GLOB.mob_living_list)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/mobs/proc/MaxZChanged()
|
||||
if (!islist(clients_by_zlevel))
|
||||
|
||||
@@ -6,9 +6,10 @@ SUBSYSTEM_DEF(npcpool)
|
||||
|
||||
var/list/currentrun = list()
|
||||
|
||||
/datum/controller/subsystem/npcpool/stat_entry()
|
||||
/datum/controller/subsystem/npcpool/stat_entry(msg)
|
||||
var/list/activelist = GLOB.simple_animals[AI_ON]
|
||||
..("NPCS:[activelist.len]")
|
||||
msg = "NPCS:[length(activelist)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/npcpool/fire(resumed = FALSE)
|
||||
|
||||
|
||||
@@ -21,10 +21,9 @@ SUBSYSTEM_DEF(overlays)
|
||||
fire(mc_check = FALSE)
|
||||
return ..()
|
||||
|
||||
|
||||
/datum/controller/subsystem/overlays/stat_entry()
|
||||
..("Ov:[length(queue)]")
|
||||
|
||||
/datum/controller/subsystem/overlays/stat_entry(msg)
|
||||
msg = "Ov:[length(queue)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/overlays/Shutdown()
|
||||
text2file(render_stats(stats), "[GLOB.log_directory]/overlay.log")
|
||||
|
||||
@@ -7,9 +7,15 @@ SUBSYSTEM_DEF(parallax)
|
||||
var/list/currentrun
|
||||
var/planet_x_offset = 128
|
||||
var/planet_y_offset = 128
|
||||
var/random_layer
|
||||
var/random_parallax_color
|
||||
|
||||
/datum/controller/subsystem/parallax/Initialize(timeofday)
|
||||
//These are cached per client so needs to be done asap so people joining at roundstart do not miss these.
|
||||
/datum/controller/subsystem/parallax/PreInit()
|
||||
. = ..()
|
||||
if(prob(70)) //70% chance to pick a special extra layer
|
||||
random_layer = pick(/obj/screen/parallax_layer/random/space_gas, /obj/screen/parallax_layer/random/asteroids, /obj/screen/parallax_layer/random/nebula)
|
||||
random_parallax_color = pick(COLOR_TEAL, COLOR_GREEN, COLOR_SILVER, COLOR_YELLOW, COLOR_CYAN, COLOR_ORANGE, COLOR_PURPLE)//Special color for random_layer1. Has to be done here so everyone sees the same color.
|
||||
planet_y_offset = rand(100, 160)
|
||||
planet_x_offset = rand(100, 160)
|
||||
|
||||
|
||||
@@ -10,8 +10,9 @@ SUBSYSTEM_DEF(processing)
|
||||
var/list/processing = list()
|
||||
var/list/currentrun = list()
|
||||
|
||||
/datum/controller/subsystem/processing/stat_entry()
|
||||
..("[stat_tag]:[processing.len]")
|
||||
/datum/controller/subsystem/processing/stat_entry(msg)
|
||||
msg = "[stat_tag]:[length(processing)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/processing/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
|
||||
@@ -10,6 +10,8 @@ PROCESSING_SUBSYSTEM_DEF(quirks)
|
||||
|
||||
var/list/quirks = list() //Assoc. list of all roundstart quirk datum types; "name" = /path/
|
||||
var/list/quirk_names_by_path = list()
|
||||
var/list/quirk_categories = list() //Hyper edit: Quirks are sorted by different categories
|
||||
var/list/quirks_sorted = list() //Hyper edit: Sort quirks by category then cost
|
||||
var/list/quirk_points = list() //Assoc. list of quirk names and their "point cost"; positive numbers are good traits, and negative ones are bad
|
||||
var/list/quirk_objects = list() //A list of all quirk objects in the game, since some may process
|
||||
var/list/quirk_blacklist = list() //A list a list of quirks that can not be used with each other. Format: list(quirk1,quirk2),list(quirk3,quirk4)
|
||||
@@ -17,7 +19,15 @@ PROCESSING_SUBSYSTEM_DEF(quirks)
|
||||
/datum/controller/subsystem/processing/quirks/Initialize(timeofday)
|
||||
if(!quirks.len)
|
||||
SetupQuirks()
|
||||
quirk_blacklist = list(list("Blind","Nearsighted"),list("Jolly","Depression","Hypersensitive"),list("Ageusia","Vegetarian","Deviant Tastes"),list("Ananas Affinity","Ananas Aversion"),list("Alcohol Tolerance","Light Drinker"),list("Prosthetic Limb (Left Arm)","Prosthetic Limb (Right Arm)","Prosthetic Limb (Left Leg)","Prosthetic Limb (Right Leg)","Prosthetic Limb"),list("Social Anxiety","Mute"))
|
||||
quirk_blacklist = list(
|
||||
list("Blind","Nearsighted"),
|
||||
list("Jolly","Depression","Hypersensitive"),
|
||||
list("Ageusia","Vegetarian","Deviant Tastes"),
|
||||
list("Ananas Affinity","Ananas Aversion"),
|
||||
list("Alcohol Tolerance","Light Drinker"),
|
||||
list("Social Anxiety","Mute"),
|
||||
list("Prosthetic Limb (Left Arm)","Prosthetic Limb (Right Arm)","Prosthetic Limb (Left Leg)","Prosthetic Limb (Right Leg)","Prosthetic Limb")
|
||||
)
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/processing/quirks/proc/SetupQuirks()
|
||||
@@ -29,6 +39,24 @@ PROCESSING_SUBSYSTEM_DEF(quirks)
|
||||
quirks[initial(T.name)] = T
|
||||
quirk_points[initial(T.name)] = initial(T.value)
|
||||
quirk_names_by_path[T] = initial(T.name)
|
||||
if(initial(T.category) != CATEGORY_UNCATEGORIZED) //Hyperstation Edit: Categorized quirks
|
||||
quirk_categories[initial(T.category)] = 1
|
||||
SortQuirks()
|
||||
|
||||
/datum/controller/subsystem/processing/quirks/proc/SortQuirks() //Hyperstation edit: Categorized quirks
|
||||
quirks_sorted = list()
|
||||
quirk_categories = sortList(quirk_categories)
|
||||
var/list/uncategorized = list()
|
||||
for(var/C in quirk_categories)
|
||||
quirks_sorted[C] = list()
|
||||
for(var/V in quirks) //These are already sorted by name and cost
|
||||
var/datum/quirk/Q = quirks[V]
|
||||
if(initial(Q.category) == C)
|
||||
quirks_sorted[C] += initial(Q.name)
|
||||
else if (initial(Q.category) == CATEGORY_UNCATEGORIZED)
|
||||
uncategorized += initial(Q.name)
|
||||
for(var/C in uncategorized)
|
||||
quirks_sorted[CATEGORY_UNCATEGORIZED] += C
|
||||
|
||||
/datum/controller/subsystem/processing/quirks/proc/AssignQuirks(mob/living/user, client/cli, spawn_effects, roundstart = FALSE, datum/job/job, silent = FALSE, mob/to_chat_target)
|
||||
var/badquirk = FALSE
|
||||
|
||||
@@ -1,27 +1,34 @@
|
||||
|
||||
SUBSYSTEM_DEF(research)
|
||||
name = "Research"
|
||||
priority = FIRE_PRIORITY_RESEARCH
|
||||
wait = 10
|
||||
init_order = INIT_ORDER_RESEARCH
|
||||
//TECHWEB STATIC
|
||||
var/list/techweb_nodes = list() //associative id = node datum
|
||||
var/list/techweb_designs = list() //associative id = node datum
|
||||
var/list/datum/techweb/techwebs = list()
|
||||
var/datum/techweb/science/science_tech
|
||||
var/datum/techweb/admin/admin_tech
|
||||
var/datum/techweb_node/error_node/error_node //These two are what you get if a node/design is deleted and somehow still stored in a console.
|
||||
var/datum/design/error_design/error_design
|
||||
|
||||
//ERROR LOGGING
|
||||
var/list/invalid_design_ids = list() //associative id = number of times
|
||||
var/list/invalid_node_ids = list() //associative id = number of times
|
||||
var/list/invalid_node_boost = list() //associative id = error message
|
||||
|
||||
var/list/obj/machinery/rnd/server/servers = list()
|
||||
var/datum/techweb/science/science_tech
|
||||
var/datum/techweb/admin/admin_tech
|
||||
var/list/techweb_nodes = list() //associative id = node datum
|
||||
var/list/techweb_categories = list() //category name = list(node.id = node)
|
||||
var/list/techweb_designs = list() //associative id = node datum
|
||||
var/list/techweb_nodes_starting = list() //associative id = node datum
|
||||
|
||||
var/list/techweb_nodes_starting = list() //associative id = TRUE
|
||||
var/list/techweb_categories = list() //category name = list(node.id = TRUE)
|
||||
var/list/techweb_boost_items = list() //associative double-layer path = list(id = list(point_type = point_discount))
|
||||
var/list/techweb_nodes_hidden = list() //Nodes that should be hidden by default.
|
||||
var/list/techweb_nodes_hidden = list() //Node ids that should be hidden by default.
|
||||
var/list/techweb_point_items = list( //path = list(point type = value)
|
||||
/obj/item/assembly/signaler/anomaly = list(TECHWEB_POINT_TYPE_GENERIC = 2500),
|
||||
/obj/item/assembly/signaler/anomaly = list(TECHWEB_POINT_TYPE_GENERIC = 5000), // Cit three more anomalys anomalys
|
||||
/obj/item/assembly/signaler/anomaly = list(TECHWEB_POINT_TYPE_GENERIC = 7500),
|
||||
/obj/item/assembly/signaler/anomaly = list(TECHWEB_POINT_TYPE_GENERIC = 10000),
|
||||
// - Slime Extracts! -
|
||||
// - Slime Extracts! -
|
||||
/obj/item/slime_extract/grey = list(TECHWEB_POINT_TYPE_GENERIC = 500), // Adds in slime core deconing
|
||||
/obj/item/slime_extract/metal = list(TECHWEB_POINT_TYPE_GENERIC = 750),
|
||||
/obj/item/slime_extract/purple = list(TECHWEB_POINT_TYPE_GENERIC = 750),
|
||||
@@ -294,6 +301,8 @@ SUBSYSTEM_DEF(research)
|
||||
science_tech = new /datum/techweb/science
|
||||
admin_tech = new /datum/techweb/admin
|
||||
autosort_categories()
|
||||
error_design = new
|
||||
error_node = new
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/research/fire()
|
||||
@@ -330,6 +339,191 @@ SUBSYSTEM_DEF(research)
|
||||
for(var/i in techweb_nodes)
|
||||
var/datum/techweb_node/I = techweb_nodes[i]
|
||||
if(techweb_categories[I.category])
|
||||
techweb_categories[I.category][I.id] = I
|
||||
techweb_categories[I.category][I.id] = TRUE
|
||||
else
|
||||
techweb_categories[I.category] = list(I.id = I)
|
||||
techweb_categories[I.category] = list(I.id = TRUE)
|
||||
|
||||
/datum/controller/subsystem/research/proc/techweb_node_by_id(id)
|
||||
return techweb_nodes[id] || error_node
|
||||
|
||||
/datum/controller/subsystem/research/proc/techweb_design_by_id(id)
|
||||
return techweb_designs[id] || error_design
|
||||
|
||||
/datum/controller/subsystem/research/proc/on_design_deletion(datum/design/D)
|
||||
for(var/i in techweb_nodes)
|
||||
var/datum/techweb_node/TN = techwebs[i]
|
||||
TN.on_design_deletion(TN)
|
||||
for(var/i in techwebs)
|
||||
var/datum/techweb/T = i
|
||||
T.recalculate_nodes(TRUE)
|
||||
|
||||
/datum/controller/subsystem/research/proc/on_node_deletion(datum/techweb_node/TN)
|
||||
for(var/i in techweb_nodes)
|
||||
var/datum/techweb_node/TN2 = techwebs[i]
|
||||
TN2.on_node_deletion(TN)
|
||||
for(var/i in techwebs)
|
||||
var/datum/techweb/T = i
|
||||
T.recalculate_nodes(TRUE)
|
||||
|
||||
/datum/controller/subsystem/research/proc/initialize_all_techweb_nodes(clearall = FALSE)
|
||||
if(islist(techweb_nodes) && clearall)
|
||||
QDEL_LIST(techweb_nodes)
|
||||
if(islist(techweb_nodes_starting && clearall))
|
||||
techweb_nodes_starting.Cut()
|
||||
var/list/returned = list()
|
||||
for(var/path in subtypesof(/datum/techweb_node))
|
||||
var/datum/techweb_node/TN = path
|
||||
if(isnull(initial(TN.id)))
|
||||
continue
|
||||
TN = new path
|
||||
if(returned[initial(TN.id)])
|
||||
stack_trace("WARNING: Techweb node ID clash with ID [initial(TN.id)] detected! Path: [path]")
|
||||
errored_datums[TN] = initial(TN.id)
|
||||
continue
|
||||
returned[initial(TN.id)] = TN
|
||||
if(TN.starting_node)
|
||||
techweb_nodes_starting[TN.id] = TRUE
|
||||
for(var/id in techweb_nodes)
|
||||
var/datum/techweb_node/TN = techweb_nodes[id]
|
||||
TN.Initialize()
|
||||
techweb_nodes = returned
|
||||
if (!verify_techweb_nodes()) //Verify all nodes have ids and such.
|
||||
stack_trace("Invalid techweb nodes detected")
|
||||
calculate_techweb_nodes()
|
||||
calculate_techweb_boost_list()
|
||||
if (!verify_techweb_nodes()) //Verify nodes and designs have been crosslinked properly.
|
||||
CRASH("Invalid techweb nodes detected")
|
||||
|
||||
/datum/controller/subsystem/research/proc/initialize_all_techweb_designs(clearall = FALSE)
|
||||
if(islist(techweb_designs) && clearall)
|
||||
QDEL_LIST(techweb_designs)
|
||||
var/list/returned = list()
|
||||
for(var/path in subtypesof(/datum/design))
|
||||
var/datum/design/DN = path
|
||||
if(isnull(initial(DN.id)))
|
||||
stack_trace("WARNING: Design with null ID detected. Build path: [initial(DN.build_path)]")
|
||||
continue
|
||||
else if(initial(DN.id) == DESIGN_ID_IGNORE)
|
||||
continue
|
||||
DN = new path
|
||||
if(returned[initial(DN.id)])
|
||||
stack_trace("WARNING: Design ID clash with ID [initial(DN.id)] detected! Path: [path]")
|
||||
errored_datums[DN] = initial(DN.id)
|
||||
continue
|
||||
returned[initial(DN.id)] = DN
|
||||
techweb_designs = returned
|
||||
verify_techweb_designs()
|
||||
|
||||
/datum/controller/subsystem/research/proc/verify_techweb_nodes()
|
||||
. = TRUE
|
||||
for(var/n in techweb_nodes)
|
||||
var/datum/techweb_node/N = techweb_nodes[n]
|
||||
if(!istype(N))
|
||||
WARNING("Invalid research node with ID [n] detected and removed.")
|
||||
techweb_nodes -= n
|
||||
research_node_id_error(n)
|
||||
. = FALSE
|
||||
for(var/p in N.prereq_ids)
|
||||
var/datum/techweb_node/P = techweb_nodes[p]
|
||||
if(!istype(P))
|
||||
WARNING("Invalid research prerequisite node with ID [p] detected in node [N.display_name]\[[N.id]\] removed.")
|
||||
N.prereq_ids -= p
|
||||
research_node_id_error(p)
|
||||
. = FALSE
|
||||
for(var/d in N.design_ids)
|
||||
var/datum/design/D = techweb_designs[d]
|
||||
if(!istype(D))
|
||||
WARNING("Invalid research design with ID [d] detected in node [N.display_name]\[[N.id]\] removed.")
|
||||
N.design_ids -= d
|
||||
design_id_error(d)
|
||||
. = FALSE
|
||||
for(var/u in N.unlock_ids)
|
||||
var/datum/techweb_node/U = techweb_nodes[u]
|
||||
if(!istype(U))
|
||||
WARNING("Invalid research unlock node with ID [u] detected in node [N.display_name]\[[N.id]\] removed.")
|
||||
N.unlock_ids -= u
|
||||
research_node_id_error(u)
|
||||
. = FALSE
|
||||
for(var/p in N.boost_item_paths)
|
||||
if(!ispath(p))
|
||||
N.boost_item_paths -= p
|
||||
WARNING("[p] is not a valid path.")
|
||||
node_boost_error(N.id, "[p] is not a valid path.")
|
||||
. = FALSE
|
||||
var/list/points = N.boost_item_paths[p]
|
||||
if(islist(points))
|
||||
for(var/i in points)
|
||||
if(!isnum(points[i]))
|
||||
WARNING("[points[i]] is not a valid number.")
|
||||
node_boost_error(N.id, "[points[i]] is not a valid number.")
|
||||
. = FALSE
|
||||
else if(!point_types[i])
|
||||
WARNING("[i] is not a valid point type.")
|
||||
node_boost_error(N.id, "[i] is not a valid point type.")
|
||||
. = FALSE
|
||||
else if(!isnull(points))
|
||||
N.boost_item_paths -= p
|
||||
node_boost_error(N.id, "No valid list.")
|
||||
WARNING("No valid list.")
|
||||
. = FALSE
|
||||
CHECK_TICK
|
||||
|
||||
/datum/controller/subsystem/research/proc/verify_techweb_designs()
|
||||
for(var/d in techweb_designs)
|
||||
var/datum/design/D = techweb_designs[d]
|
||||
if(!istype(D))
|
||||
stack_trace("WARNING: Invalid research design with ID [d] detected and removed.")
|
||||
techweb_designs -= d
|
||||
CHECK_TICK
|
||||
|
||||
/datum/controller/subsystem/research/proc/research_node_id_error(id)
|
||||
if(invalid_node_ids[id])
|
||||
invalid_node_ids[id]++
|
||||
else
|
||||
invalid_node_ids[id] = 1
|
||||
|
||||
/datum/controller/subsystem/research/proc/design_id_error(id)
|
||||
if(invalid_design_ids[id])
|
||||
invalid_design_ids[id]++
|
||||
else
|
||||
invalid_design_ids[id] = 1
|
||||
|
||||
/datum/controller/subsystem/research/proc/calculate_techweb_nodes()
|
||||
for(var/design_id in techweb_designs)
|
||||
var/datum/design/D = techweb_designs[design_id]
|
||||
D.unlocked_by.Cut()
|
||||
for(var/node_id in techweb_nodes)
|
||||
var/datum/techweb_node/node = techweb_nodes[node_id]
|
||||
node.unlock_ids = list()
|
||||
for(var/i in node.design_ids)
|
||||
var/datum/design/D = techweb_designs[i]
|
||||
node.design_ids[i] = TRUE
|
||||
D.unlocked_by += node.id
|
||||
if(node.hidden)
|
||||
techweb_nodes_hidden[node.id] = TRUE
|
||||
CHECK_TICK
|
||||
generate_techweb_unlock_linking()
|
||||
|
||||
/datum/controller/subsystem/research/proc/generate_techweb_unlock_linking()
|
||||
for(var/node_id in techweb_nodes) //Clear all unlock links to avoid duplication.
|
||||
var/datum/techweb_node/node = techweb_nodes[node_id]
|
||||
node.unlock_ids = list()
|
||||
for(var/node_id in techweb_nodes)
|
||||
var/datum/techweb_node/node = techweb_nodes[node_id]
|
||||
for(var/prereq_id in node.prereq_ids)
|
||||
var/datum/techweb_node/prereq_node = techweb_node_by_id(prereq_id)
|
||||
prereq_node.unlock_ids[node.id] = node
|
||||
|
||||
/datum/controller/subsystem/research/proc/calculate_techweb_boost_list(clearall = FALSE)
|
||||
if(clearall)
|
||||
techweb_boost_items = list()
|
||||
for(var/node_id in techweb_nodes)
|
||||
var/datum/techweb_node/node = techweb_nodes[node_id]
|
||||
for(var/path in node.boost_item_paths)
|
||||
if(!ispath(path))
|
||||
continue
|
||||
if(length(techweb_boost_items[path]))
|
||||
techweb_boost_items[path][node.id] = node.boost_item_paths[path]
|
||||
else
|
||||
techweb_boost_items[path] = list(node.id = node.boost_item_paths[path])
|
||||
CHECK_TICK
|
||||
@@ -8,9 +8,9 @@ SUBSYSTEM_DEF(spacedrift)
|
||||
var/list/currentrun = list()
|
||||
var/list/processing = list()
|
||||
|
||||
/datum/controller/subsystem/spacedrift/stat_entry()
|
||||
..("P:[processing.len]")
|
||||
|
||||
/datum/controller/subsystem/spacedrift/stat_entry(msg)
|
||||
msg = "P:[length(processing)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/spacedrift/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
|
||||
@@ -0,0 +1,118 @@
|
||||
SUBSYSTEM_DEF(statpanels)
|
||||
name = "Stat Panels"
|
||||
wait = 4
|
||||
init_order = INIT_ORDER_STATPANELS
|
||||
runlevels = RUNLEVELS_DEFAULT | RUNLEVEL_LOBBY
|
||||
var/list/currentrun = list()
|
||||
var/encoded_global_data
|
||||
var/mc_data_encoded
|
||||
var/list/cached_images = list()
|
||||
|
||||
/datum/controller/subsystem/statpanels/fire(resumed = FALSE)
|
||||
if (!resumed)
|
||||
var/datum/map_config/cached = SSmapping.next_map_config
|
||||
var/round_time = world.time - SSticker.round_start_time
|
||||
var/list/global_data = list(
|
||||
"Map: [SSmapping.config?.map_name || "Loading..."]",
|
||||
cached ? "Next Map: [cached.map_name]" : null,
|
||||
"Round ID: [GLOB.round_id ? GLOB.round_id : "NULL"]",
|
||||
"Server Time: [time2text(world.timeofday, "YYYY-MM-DD hh:mm:ss")]",
|
||||
"Round Time: [round_time > MIDNIGHT_ROLLOVER ? "[round(round_time/MIDNIGHT_ROLLOVER)]:[worldtime2text()]" : worldtime2text()]",
|
||||
"Station Time: [station_time_timestamp()]",
|
||||
"Time Dilation: [round(SStime_track.time_dilation_current,1)]% AVG:([round(SStime_track.time_dilation_avg_fast,1)]%, [round(SStime_track.time_dilation_avg,1)]%, [round(SStime_track.time_dilation_avg_slow,1)]%)"
|
||||
)
|
||||
|
||||
if(SSshuttle.emergency)
|
||||
var/ETA = SSshuttle.emergency.getModeStr()
|
||||
if(ETA)
|
||||
global_data += "[ETA] [SSshuttle.emergency.getTimerStr()]"
|
||||
encoded_global_data = url_encode(json_encode(global_data))
|
||||
|
||||
var/list/mc_data = list(
|
||||
list("CPU:", world.cpu),
|
||||
list("Instances:", "[num2text(world.contents.len, 10)]"),
|
||||
list("World Time:", "[world.time]"),
|
||||
list("Globals:", GLOB.stat_entry(), "\ref[GLOB]"),
|
||||
list("[config]:", config.stat_entry(), "\ref[config]"),
|
||||
list("Byond:", "(FPS:[world.fps]) (TickCount:[world.time/world.tick_lag]) (TickDrift:[round(Master.tickdrift,1)]([round((Master.tickdrift/(world.time/world.tick_lag))*100,0.1)]%))"),
|
||||
list("Master Controller:", Master.stat_entry(), "\ref[Master]"),
|
||||
list("Failsafe Controller:", Failsafe.stat_entry(), "\ref[Failsafe]"),
|
||||
list("","")
|
||||
)
|
||||
for(var/ss in Master.subsystems)
|
||||
var/datum/controller/subsystem/sub_system = ss
|
||||
mc_data[++mc_data.len] = list("\[[sub_system.state_letter()]][sub_system.name]", sub_system.stat_entry(), "\ref[sub_system]")
|
||||
mc_data[++mc_data.len] = list("Camera Net", "Cameras: [GLOB.cameranet.cameras.len] | Chunks: [GLOB.cameranet.chunks.len]", "\ref[GLOB.cameranet]")
|
||||
mc_data_encoded = url_encode(json_encode(mc_data))
|
||||
src.currentrun = GLOB.clients.Copy()
|
||||
|
||||
var/list/currentrun = src.currentrun
|
||||
while(length(currentrun))
|
||||
var/client/target = currentrun[length(currentrun)]
|
||||
currentrun.len--
|
||||
var/ping_str = url_encode("Ping: [round(target.lastping, 1)]ms (Average: [round(target.avgping, 1)]ms)")
|
||||
var/other_str = url_encode(json_encode(target.mob.get_status_tab_items()))
|
||||
target << output("[encoded_global_data];[ping_str];[other_str]", "statbrowser:update")
|
||||
if(!target.holder)
|
||||
target << output("", "statbrowser:remove_admin_tabs")
|
||||
else
|
||||
var/turf/eye_turf = get_turf(target.eye)
|
||||
var/coord_entry = url_encode(COORD(eye_turf))
|
||||
target << output("[mc_data_encoded];[coord_entry];[url_encode(target.holder.href_token)]", "statbrowser:update_mc")
|
||||
var/list/ahelp_tickets = GLOB.ahelp_tickets.stat_entry()
|
||||
target << output("[url_encode(json_encode(ahelp_tickets))];", "statbrowser:update_tickets")
|
||||
if(!length(GLOB.sdql2_queries))
|
||||
target << output("", "statbrowser:remove_sqdl2")
|
||||
else
|
||||
var/list/sqdl2A = list()
|
||||
sqdl2A[++sqdl2A.len] = list("", "Access Global SDQL2 List", REF(GLOB.sdql2_vv_statobj))
|
||||
var/list/sqdl2B = list()
|
||||
sqdl2A += sqdl2B
|
||||
target << output(url_encode(json_encode(sqdl2A)), "statbrowser:update_sqdl2")
|
||||
var/list/proc_holders = target.mob.get_proc_holders()
|
||||
target.spell_tabs.Cut()
|
||||
for(var/phl in proc_holders)
|
||||
var/list/proc_holder_list = phl
|
||||
target.spell_tabs |= proc_holder_list[1]
|
||||
var/proc_holders_encoded = ""
|
||||
if(length(proc_holders))
|
||||
proc_holders_encoded = url_encode(json_encode(proc_holders))
|
||||
target << output("[url_encode(json_encode(target.spell_tabs))];[proc_holders_encoded]", "statbrowser:update_spells")
|
||||
if(target.mob?.listed_turf)
|
||||
var/mob/target_mob = target.mob
|
||||
if(!target_mob.TurfAdjacent(target_mob.listed_turf))
|
||||
target << output("", "statbrowser:remove_listedturf")
|
||||
target_mob.listed_turf = null
|
||||
else
|
||||
var/list/overrides = list()
|
||||
var/list/turfitems = list()
|
||||
for(var/img in target.images)
|
||||
var/image/target_image = img
|
||||
if(!target_image.loc || target_image.loc.loc != target_mob.listed_turf || !target_image.override)
|
||||
continue
|
||||
overrides += target_image.loc
|
||||
if(!(REF(target_mob.listed_turf) in cached_images))
|
||||
target << browse_rsc(getFlatIcon(target_mob.listed_turf, no_anim = TRUE), "[REF(target_mob.listed_turf)].png")
|
||||
cached_images += REF(target_mob.listed_turf)
|
||||
turfitems[++turfitems.len] = list("[target_mob.listed_turf]", REF(target_mob.listed_turf), "[REF(target_mob.listed_turf)].png")
|
||||
for(var/tc in target_mob.listed_turf)
|
||||
var/atom/movable/turf_content = tc
|
||||
if(turf_content.mouse_opacity == MOUSE_OPACITY_TRANSPARENT)
|
||||
continue
|
||||
if(turf_content.invisibility > target_mob.see_invisible)
|
||||
continue
|
||||
if(turf_content in overrides)
|
||||
continue
|
||||
if(turf_content.IsObscured())
|
||||
continue
|
||||
if(length(turfitems) < 30) // only create images for the first 30 items on the turf, for performance reasons
|
||||
if(!(REF(turf_content) in cached_images))
|
||||
target << browse_rsc(getFlatIcon(turf_content, no_anim = TRUE), "[REF(turf_content)].png")
|
||||
cached_images += REF(turf_content)
|
||||
turfitems[++turfitems.len] = list("[turf_content.name]", REF(turf_content), "[REF(turf_content)].png")
|
||||
else
|
||||
turfitems[++turfitems.len] = list("[turf_content.name]", REF(turf_content))
|
||||
turfitems = url_encode(json_encode(turfitems))
|
||||
target << output("[turfitems];", "statbrowser:update_listedturf")
|
||||
if(MC_TICK_CHECK)
|
||||
return
|
||||
@@ -16,8 +16,9 @@ SUBSYSTEM_DEF(tgui)
|
||||
/datum/controller/subsystem/tgui/Shutdown()
|
||||
close_all_uis()
|
||||
|
||||
/datum/controller/subsystem/tgui/stat_entry()
|
||||
..("P:[processing_uis.len]")
|
||||
/datum/controller/subsystem/tgui/stat_entry(msg)
|
||||
msg = "P:[length(open_uis)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/tgui/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
|
||||
@@ -11,9 +11,9 @@ SUBSYSTEM_DEF(throwing)
|
||||
var/list/currentrun
|
||||
var/list/processing = list()
|
||||
|
||||
/datum/controller/subsystem/throwing/stat_entry()
|
||||
..("P:[processing.len]")
|
||||
|
||||
/datum/controller/subsystem/throwing/stat_entry(msg)
|
||||
msg = "P:[length(processing)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/throwing/fire(resumed = 0)
|
||||
if (!resumed)
|
||||
@@ -43,6 +43,7 @@ SUBSYSTEM_DEF(throwing)
|
||||
var/atom/movable/thrownthing
|
||||
var/atom/target
|
||||
var/turf/target_turf
|
||||
var/target_zone
|
||||
var/init_dir
|
||||
var/maxrange
|
||||
var/speed
|
||||
|
||||
@@ -402,6 +402,7 @@ SUBSYSTEM_DEF(ticker)
|
||||
if(living.client)
|
||||
var/obj/screen/splash/S = new(living.client, TRUE)
|
||||
S.Fade(TRUE)
|
||||
living.client.init_verbs()
|
||||
livings += living
|
||||
if(livings.len)
|
||||
addtimer(CALLBACK(src, .proc/release_characters, livings), 30, TIMER_CLIENT_TIME)
|
||||
@@ -677,7 +678,7 @@ SUBSYSTEM_DEF(ticker)
|
||||
if(!round_end_sound)
|
||||
round_end_sound = pick(\
|
||||
'sound/roundend/iwishtherewassomethingmore.ogg',
|
||||
'sound/roundend/likeisaid.ogg',
|
||||
'sound/roundend/likeisaid.ogg',
|
||||
'sound/roundend/whatarottenwaytodie.ogg',
|
||||
'sound/roundend/whatashame.ogg',
|
||||
'sound/roundend/newroundsexy.ogg',
|
||||
|
||||
@@ -34,7 +34,8 @@ SUBSYSTEM_DEF(timer)
|
||||
bucket_resolution = world.tick_lag
|
||||
|
||||
/datum/controller/subsystem/timer/stat_entry(msg)
|
||||
..("B:[bucket_count] P:[length(second_queue)] H:[length(hashes)] C:[length(clienttime_timers)] S:[length(timer_id_dict)]")
|
||||
msg = "B:[bucket_count] P:[length(second_queue)] H:[length(hashes)] C:[length(clienttime_timers)] S:[length(timer_id_dict)]"
|
||||
return ..()
|
||||
|
||||
/datum/controller/subsystem/timer/fire(resumed = FALSE)
|
||||
var/lit = last_invoke_tick
|
||||
|
||||
@@ -149,9 +149,14 @@ SUBSYSTEM_DEF(vote)
|
||||
if("5")
|
||||
v += winners[option] //Add the number votes to the pool
|
||||
numbers += (winners[option]*5) //Add the value of the vote to numbers
|
||||
while (v < DYNAMIC_VOTE_NORMALIZATION) //For low low pop, low vote rounds.
|
||||
numbers += DYNAMIC_DEFAULT_CHAOS //stops the one person voting from setting the chaos to five and flooding the station with anomalies
|
||||
v += 1
|
||||
if(v < DYNAMIC_VOTE_NORMALIZATION)
|
||||
while (v < DYNAMIC_VOTE_NORMALIZATION) //For low low pop, low vote rounds.
|
||||
numbers += DYNAMIC_DEFAULT_CHAOS //stops the one person voting from setting the chaos to five and flooding the station with anomalies
|
||||
v += 1
|
||||
else if (voted.len < GLOB.clients.len) //Have non-voters "vote" 2, if we're not lowpop
|
||||
for(var/I in 1 to (GLOB.clients.len - voted.len))
|
||||
v += 1
|
||||
numbers += 2
|
||||
var/total = 0
|
||||
for (var/i in numbers)
|
||||
total += i
|
||||
|
||||
@@ -1,26 +1,42 @@
|
||||
/datum/component/anti_magic
|
||||
var/magic = FALSE
|
||||
var/holy = FALSE
|
||||
var/psychic = FALSE
|
||||
var/charges = INFINITY
|
||||
var/blocks_self = TRUE
|
||||
var/datum/callback/reaction
|
||||
var/datum/callback/expire
|
||||
|
||||
/datum/component/anti_magic/Initialize(_magic = FALSE, _holy = FALSE)
|
||||
/datum/component/anti_magic/Initialize(_magic = FALSE, _holy = FALSE, _psychic = FALSE, _charges, _blocks_self = TRUE, datum/callback/_reaction, datum/callback/_expire)
|
||||
if(isitem(parent))
|
||||
RegisterSignal(parent, COMSIG_ITEM_EQUIPPED, .proc/on_equip)
|
||||
RegisterSignal(parent, COMSIG_ITEM_DROPPED, .proc/on_drop)
|
||||
else if(ismob(parent))
|
||||
RegisterSignal(parent, COMSIG_MOB_RECEIVE_MAGIC, .proc/can_protect)
|
||||
RegisterSignal(parent, COMSIG_MOB_RECEIVE_MAGIC, .proc/protect)
|
||||
else
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
|
||||
magic = _magic
|
||||
holy = _holy
|
||||
psychic = _psychic
|
||||
if(!isnull(_charges))
|
||||
charges = _charges
|
||||
blocks_self = _blocks_self
|
||||
reaction = _reaction
|
||||
expire = _expire
|
||||
|
||||
/datum/component/anti_magic/proc/on_equip(datum/source, mob/equipper, slot)
|
||||
RegisterSignal(equipper, COMSIG_MOB_RECEIVE_MAGIC, .proc/can_protect, TRUE)
|
||||
RegisterSignal(equipper, COMSIG_MOB_RECEIVE_MAGIC, .proc/protect, TRUE)
|
||||
|
||||
/datum/component/anti_magic/proc/on_drop(datum/source, mob/user)
|
||||
UnregisterSignal(user, COMSIG_MOB_RECEIVE_MAGIC)
|
||||
|
||||
/datum/component/anti_magic/proc/can_protect(datum/source, _magic, _holy, list/protection_sources)
|
||||
if((_magic && magic) || (_holy && holy))
|
||||
/datum/component/anti_magic/proc/protect(datum/source, mob/user, _magic, _holy, _psychic, chargecost = 1, self, list/protection_sources)
|
||||
if(((_magic && magic) || (_holy && holy) || (_psychic && psychic)) && (!self || blocks_self))
|
||||
protection_sources += parent
|
||||
reaction?.Invoke(user, chargecost)
|
||||
charges -= chargecost
|
||||
if(charges <= 0)
|
||||
expire?.Invoke(user)
|
||||
qdel(src)
|
||||
return COMPONENT_BLOCK_MAGIC
|
||||
|
||||
@@ -20,7 +20,8 @@
|
||||
/obj/effect/light_emitter/tendril,
|
||||
/obj/effect/collapse,
|
||||
/obj/effect/particle_effect/ion_trails,
|
||||
/obj/effect/dummy/phased_mob
|
||||
/obj/effect/dummy/phased_mob,
|
||||
/obj/effect/immovablerod
|
||||
))
|
||||
|
||||
/datum/component/chasm/Initialize(turf/target)
|
||||
@@ -38,7 +39,7 @@
|
||||
|
||||
/datum/component/chasm/proc/is_safe()
|
||||
//if anything matching this typecache is found in the chasm, we don't drop things
|
||||
var/static/list/chasm_safeties_typecache = typecacheof(list(/obj/structure/lattice/catwalk, /obj/structure/stone_tile))
|
||||
var/static/list/chasm_safeties_typecache = typecacheof(list(/obj/structure/lattice/catwalk, /obj/structure/lattice, /obj/structure/stone_tile))
|
||||
|
||||
var/atom/parent = src.parent
|
||||
var/list/found_safeties = typecache_filter_list(parent.contents, chasm_safeties_typecache)
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
e -= 5
|
||||
steps++
|
||||
|
||||
if(steps >= 3)
|
||||
if(steps >= 2)
|
||||
steps = 0
|
||||
|
||||
else
|
||||
@@ -46,6 +46,12 @@
|
||||
|
||||
//begin playsound shenanigans//
|
||||
|
||||
//for big characters, add alittle boom
|
||||
if(LM.size_multiplier > 1.5)
|
||||
var/stompsound = pick( 'sound/effects/footstep/giant1.ogg','sound/effects/footstep/giant2.ogg')
|
||||
var/giantvolume = LM.size_multiplier * 9
|
||||
playsound(T, stompsound, giantvolume)
|
||||
|
||||
//for barefooted non-clawed mobs like monkeys
|
||||
if(isbarefoot(LM))
|
||||
playsound(T, pick(GLOB.barefootstep[T.barefootstep][1]),
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
var/insanity_effect = 0 //is the owner being punished for low mood? If so, how much?
|
||||
var/holdmyinsanityeffect = 0 //before we edit our sanity lets take a look
|
||||
var/obj/screen/mood/screen_obj
|
||||
var/lastupdate = 0
|
||||
|
||||
/datum/component/mood/Initialize()
|
||||
if(!isliving(parent))
|
||||
@@ -91,6 +92,7 @@
|
||||
mood += event.mood_change
|
||||
if(!event.hidden)
|
||||
shown_mood += event.mood_change
|
||||
|
||||
mood *= mood_modifier
|
||||
shown_mood *= mood_modifier
|
||||
|
||||
@@ -161,6 +163,7 @@
|
||||
holdmyinsanityeffect = insanity_effect
|
||||
|
||||
HandleNutrition(owner)
|
||||
HandleThirst(owner)
|
||||
|
||||
/datum/component/mood/proc/setSanity(amount, minimum=SANITY_INSANE, maximum=SANITY_NEUTRAL)//I'm sure bunging this in here will have no negative repercussions.
|
||||
var/mob/living/master = parent
|
||||
@@ -183,15 +186,15 @@
|
||||
switch(sanity)
|
||||
if(SANITY_INSANE to SANITY_CRAZY)
|
||||
setInsanityEffect(MAJOR_INSANITY_PEN)
|
||||
master.add_movespeed_modifier(MOVESPEED_ID_SANITY, TRUE, 100, override=TRUE, multiplicative_slowdown=1.5) //Did we change something ? movetypes is runtiming, movetypes=(~FLYING))
|
||||
master.add_movespeed_modifier(MOVESPEED_ID_SANITY, TRUE, 100, override=TRUE, multiplicative_slowdown=1) //Did we change something ? movetypes is runtiming, movetypes=(~FLYING))
|
||||
sanity_level = 6
|
||||
if(SANITY_CRAZY to SANITY_UNSTABLE)
|
||||
setInsanityEffect(MINOR_INSANITY_PEN)
|
||||
master.add_movespeed_modifier(MOVESPEED_ID_SANITY, TRUE, 100, override=TRUE, multiplicative_slowdown=1)//, movetypes=(~FLYING))
|
||||
master.add_movespeed_modifier(MOVESPEED_ID_SANITY, TRUE, 100, override=TRUE, multiplicative_slowdown=0.5)//, movetypes=(~FLYING))
|
||||
sanity_level = 5
|
||||
if(SANITY_UNSTABLE to SANITY_DISTURBED)
|
||||
setInsanityEffect(0)
|
||||
master.add_movespeed_modifier(MOVESPEED_ID_SANITY, TRUE, 100, override=TRUE, multiplicative_slowdown=0.5)//, movetypes=(~FLYING))
|
||||
master.add_movespeed_modifier(MOVESPEED_ID_SANITY, TRUE, 100, override=TRUE, multiplicative_slowdown=0.25)//, movetypes=(~FLYING))
|
||||
sanity_level = 4
|
||||
if(SANITY_DISTURBED to SANITY_NEUTRAL)
|
||||
setInsanityEffect(0)
|
||||
@@ -289,7 +292,6 @@
|
||||
/datum/component/mood/proc/hud_click(datum/source, location, control, params, mob/user)
|
||||
print_mood(user)
|
||||
|
||||
|
||||
/datum/component/mood/proc/HandleNutrition(mob/living/L)
|
||||
switch(L.nutrition)
|
||||
if(NUTRITION_LEVEL_FULL to INFINITY)
|
||||
@@ -305,5 +307,18 @@
|
||||
if(0 to NUTRITION_LEVEL_STARVING)
|
||||
add_event(null, "nutrition", /datum/mood_event/starving)
|
||||
|
||||
/datum/component/mood/proc/HandleThirst(mob/living/L)
|
||||
if(THIRST_LEVEL_THRESHOLD)
|
||||
L.thirst = clamp(L.thirst, 0, THIRST_LEVEL_THRESHOLD)
|
||||
switch(L.thirst)
|
||||
if(THIRST_LEVEL_QUENCHED to INFINITY)
|
||||
add_event(null, "thirst", /datum/mood_event/quenched)
|
||||
if(THIRST_LEVEL_THIRSTY to THIRST_LEVEL_QUENCHED)
|
||||
clear_event(null, "thirst")
|
||||
if(THIRST_LEVEL_PARCHED to THIRST_LEVEL_THIRSTY)
|
||||
add_event(null, "thirst", /datum/mood_event/thirsty)
|
||||
if(0 to THIRST_LEVEL_PARCHED)
|
||||
add_event(null, "thirst", /datum/mood_event/dehydrated)
|
||||
|
||||
#undef MINOR_INSANITY_PEN
|
||||
#undef MAJOR_INSANITY_PEN
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
if(isliving(parent))
|
||||
host_mob = parent
|
||||
|
||||
if(MOB_SILICON in host_mob.mob_biotypes) //Shouldn't happen, but this avoids HUD runtimes in case a silicon gets them somehow.
|
||||
if((MOB_SILICON & host_mob.mob_biotypes)) //Shouldn't happen, but this avoids HUD runtimes in case a silicon gets them somehow.
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
|
||||
host_mob.hud_set_nanite_indicator()
|
||||
@@ -196,7 +196,7 @@
|
||||
NP.receive_signal(code, source)
|
||||
|
||||
/datum/component/nanites/proc/check_viable_biotype()
|
||||
if((MOB_SILICON in host_mob.mob_biotypes))
|
||||
if((MOB_SILICON & host_mob.mob_biotypes))
|
||||
qdel(src) //bodytype no longer sustains nanites
|
||||
|
||||
/datum/component/nanites/proc/check_access(datum/source, obj/O)
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_UPDATE_GLIDE_SIZE, .proc/orbiter_glide_size_update)
|
||||
|
||||
|
||||
/datum/component/orbiter/UnregisterFromParent()
|
||||
var/atom/target = parent
|
||||
while(ismovableatom(target))
|
||||
@@ -60,6 +61,7 @@
|
||||
move_react()
|
||||
|
||||
/datum/component/orbiter/proc/begin_orbit(atom/movable/orbiter, radius, clockwise, rotation_speed, rotation_segments, pre_rotation)
|
||||
SEND_SIGNAL(parent, COMSIG_ATOM_ORBIT_BEGIN, orbiter, radius, clockwise, rotation_speed, rotation_segments, pre_rotation)
|
||||
if(orbiter.orbiting)
|
||||
if(orbiter.orbiting == src)
|
||||
orbiter.orbiting.end_orbit(orbiter, TRUE)
|
||||
@@ -69,6 +71,7 @@
|
||||
orbiter.orbiting = src
|
||||
RegisterSignal(orbiter, COMSIG_MOVABLE_MOVED, orbiter_spy)
|
||||
var/matrix/initial_transform = matrix(orbiter.transform)
|
||||
orbiters[orbiter] = initial_transform
|
||||
|
||||
// Head first!
|
||||
if(pre_rotation)
|
||||
@@ -91,16 +94,17 @@
|
||||
var/atom/movable/AM = parent
|
||||
orbiter.glide_size = AM.glide_size
|
||||
|
||||
//we stack the orbits up client side, so we can assign this back to normal server side without it breaking the orbit
|
||||
orbiter.transform = initial_transform
|
||||
orbiter.forceMove(get_turf(parent))
|
||||
to_chat(orbiter, "<span class='notice'>Now orbiting [parent].</span>")
|
||||
|
||||
/datum/component/orbiter/proc/end_orbit(atom/movable/orbiter, refreshing=FALSE)
|
||||
if(!orbiters[orbiter])
|
||||
return
|
||||
SEND_SIGNAL(parent, COMSIG_ATOM_ORBIT_END, orbiter, refreshing)
|
||||
UnregisterSignal(orbiter, COMSIG_MOVABLE_MOVED)
|
||||
orbiter.SpinAnimation(0, 0)
|
||||
if(istype(orbiters[orbiter],/matrix)) //This is ugly.
|
||||
orbiter.transform = orbiters[orbiter]
|
||||
orbiters -= orbiter
|
||||
orbiter.stop_orbit(src)
|
||||
orbiter.orbiting = null
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
|
||||
//KEYS
|
||||
/datum/component/riding/proc/keycheck(mob/user)
|
||||
return !keytype || user.is_holding_item_of_type(keytype)
|
||||
return !keytype || user?.is_holding_item_of_type(keytype)
|
||||
|
||||
//BUCKLE HOOKS
|
||||
/datum/component/riding/proc/restore_position(mob/living/buckled_mob)
|
||||
@@ -150,7 +150,7 @@
|
||||
|
||||
/datum/component/riding/proc/handle_ride(mob/user, direction)
|
||||
var/atom/movable/AM = parent
|
||||
if(user.incapacitated())
|
||||
if(user && user.incapacitated())
|
||||
Unbuckle(user)
|
||||
return
|
||||
|
||||
|
||||
@@ -12,6 +12,48 @@
|
||||
|
||||
var/rotation_flags = NONE
|
||||
var/default_rotation_direction = ROTATION_CLOCKWISE
|
||||
/*
|
||||
/proc/add_verb(client/target, verb_or_list_to_add)
|
||||
if(!target)
|
||||
CRASH("add_verb called without a target")
|
||||
if(IsAdminAdvancedProcCall())
|
||||
return
|
||||
var/mob/mob_target = null
|
||||
|
||||
if(ismob(target))
|
||||
mob_target = target
|
||||
target = mob_target.client
|
||||
else if(!istype(target, /client))
|
||||
CRASH("add_verb called on a non-mob and non-client")
|
||||
var/list/verbs_list = list()
|
||||
if(!islist(verb_or_list_to_add))
|
||||
verbs_list += verb_or_list_to_add
|
||||
else
|
||||
var/list/verb_listref = verb_or_list_to_add
|
||||
var/list/elements_to_process = verb_listref.Copy()
|
||||
while(length(elements_to_process))
|
||||
var/element_or_list = elements_to_process[length(elements_to_process)] //Last element
|
||||
elements_to_process.len--
|
||||
if(islist(element_or_list))
|
||||
elements_to_process += element_or_list //list/a += list/b adds the contents of b into a, not the reference to the list itself
|
||||
else
|
||||
verbs_list += element_or_list
|
||||
|
||||
if(mob_target)
|
||||
mob_target.verbs += verbs_list
|
||||
if(!target)
|
||||
return //Our work is done.
|
||||
else
|
||||
target.verbs += verbs_list
|
||||
|
||||
var/list/output_list = list()
|
||||
for(var/thing in verbs_list)
|
||||
var/procpath/verb_to_add = thing
|
||||
//output_list[++output_list.len] = list(verb_to_add.category, verb_to_add.name)
|
||||
output_list = url_encode(json_encode(output_list))
|
||||
|
||||
target << output("[output_list];", "statbrowser:add_verb_list")
|
||||
*/
|
||||
|
||||
/datum/component/simple_rotation/Initialize(rotation_flags = NONE ,can_user_rotate,can_be_rotated,after_rotation)
|
||||
if(!ismovableatom(parent))
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
if(ismob(parent.loc) && isitem(AM))
|
||||
var/obj/item/I = AM
|
||||
var/mob/M = parent.loc
|
||||
I.dropped(M)
|
||||
I.dropped(M, TRUE)
|
||||
if(new_location)
|
||||
//Reset the items values
|
||||
_removal_reset(AM)
|
||||
|
||||
@@ -43,6 +43,26 @@
|
||||
/datum/component/storage/concrete/pockets/small/detective
|
||||
attack_hand_interact = TRUE // so the detectives would discover pockets in their hats
|
||||
|
||||
/datum/component/storage/concrete/pockets/chefhat
|
||||
attack_hand_interact = TRUE
|
||||
max_items = 1
|
||||
max_w_class = WEIGHT_CLASS_NORMAL
|
||||
|
||||
/datum/component/storage/concrete/pockets/chefhat/Initialize()
|
||||
. = ..()
|
||||
can_hold = typecacheof(list(
|
||||
/obj/item/clothing/head/mob_holder,
|
||||
/obj/item/reagent_containers/food/snacks/deadmouse
|
||||
))
|
||||
|
||||
/datum/component/storage/concrete/pockets/chefhat/can_be_inserted(obj/item/I, stop_messages, mob/M)
|
||||
. = ..()
|
||||
if(istype(I,/obj/item/clothing/head/mob_holder))
|
||||
var/obj/item/clothing/head/mob_holder/mausholder = I
|
||||
if(locate(/mob/living/simple_animal/mouse) in mausholder.contents)
|
||||
return
|
||||
return FALSE
|
||||
|
||||
/datum/component/storage/concrete/pockets/shoes
|
||||
attack_hand_interact = FALSE
|
||||
quickdraw = TRUE
|
||||
|
||||
@@ -0,0 +1,104 @@
|
||||
/**
|
||||
* Observers voting on things through orbiting
|
||||
*/
|
||||
/datum/component/twitch_plays
|
||||
/// Observers
|
||||
var/list/mob/players = list()
|
||||
|
||||
/datum/component/twitch_plays/Initialize(...)
|
||||
. = ..()
|
||||
if(!isatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(parent, COMSIG_ATOM_ORBIT_BEGIN, .proc/on_start_orbit)
|
||||
RegisterSignal(parent, COMSIG_ATOM_ORBIT_END, .proc/on_end_orbit)
|
||||
|
||||
/datum/component/twitch_plays/Destroy(force, silent)
|
||||
for(var/i in players)
|
||||
DetachPlayer(i)
|
||||
return ..()
|
||||
|
||||
/datum/component/twitch_plays/proc/on_start_orbit(datum/source, atom/movable/orbiter)
|
||||
if(!isobserver(orbiter))
|
||||
return
|
||||
AttachPlayer(orbiter)
|
||||
|
||||
/datum/component/twitch_plays/proc/on_end_orbit(datum/source, atom/movable/orbiter)
|
||||
if(!(orbiter in players))
|
||||
return
|
||||
DetachPlayer(orbiter)
|
||||
|
||||
/datum/component/twitch_plays/proc/AttachPlayer(mob/dead/observer)
|
||||
players |= observer
|
||||
RegisterSignal(observer, COMSIG_PARENT_QDELETING, .proc/on_end_orbit)
|
||||
|
||||
/datum/component/twitch_plays/proc/DetachPlayer(mob/dead/observer)
|
||||
players -= observer
|
||||
UnregisterSignal(observer, COMSIG_PARENT_QDELETING)
|
||||
|
||||
/// Simple movement one
|
||||
/datum/component/twitch_plays/simple_movement
|
||||
/// Movement votes by observer
|
||||
var/list/votes = list()
|
||||
/// Allow diagonals
|
||||
var/allow_diagonal = FALSE
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/Initialize(...)
|
||||
. = ..()
|
||||
if(. & COMPONENT_INCOMPATIBLE)
|
||||
return
|
||||
RegisterSignal(parent, COMSIG_TWITCH_PLAYS_MOVEMENT_DATA, .proc/fetch_data)
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/AttachPlayer(mob/dead/observer)
|
||||
. = ..()
|
||||
RegisterSignal(observer, COMSIG_MOVABLE_PRE_MOVE, .proc/pre_move)
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/DetachPlayer(mob/dead/observer)
|
||||
. = ..()
|
||||
UnregisterSignal(observer, COMSIG_MOVABLE_PRE_MOVE)
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/proc/pre_move(datum/source, turf/newLoc)
|
||||
if(get_dist(newLoc, parent) > 1) // they're trying to escape orbit
|
||||
return
|
||||
. = COMPONENT_MOVABLE_BLOCK_PRE_MOVE
|
||||
var/dir = get_dir(parent, newLoc)
|
||||
if(!dir)
|
||||
return
|
||||
if(allow_diagonal || !((dir - 1) & dir))
|
||||
votes[source] = dir
|
||||
else // pick one or the other
|
||||
votes[source] = prob(50)? (dir & ~(dir - 1)) : (dir & (dir - 1))
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/proc/fetch_data(datum/source, wipe_votes)
|
||||
if(!votes.len)
|
||||
return
|
||||
var/list/total = list(TEXT_NORTH, TEXT_SOUTH, TEXT_EAST, TEXT_WEST)
|
||||
for(var/i in votes)
|
||||
total[num2text(votes[i])] += 1
|
||||
. = text2num(pickweight(total, 0))
|
||||
if(wipe_votes)
|
||||
votes.len = 0
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/auto
|
||||
var/move_delay = 2
|
||||
var/last_move = 0
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/auto/Initialize(...)
|
||||
if(!ismovable(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
. = ..()
|
||||
if(. & COMPONENT_INCOMPATIBLE)
|
||||
return
|
||||
START_PROCESSING(SSfastprocess, src)
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/auto/Destroy(force, silent)
|
||||
STOP_PROCESSING(SSfastprocess, src)
|
||||
return ..()
|
||||
|
||||
/datum/component/twitch_plays/simple_movement/auto/process()
|
||||
var/dir = fetch_data(null, TRUE)
|
||||
if(!dir)
|
||||
return
|
||||
if(world.time < (last_move + move_delay))
|
||||
return
|
||||
last_move = world.time
|
||||
step(parent, dir)
|
||||
@@ -25,6 +25,8 @@ GLOBAL_LIST_EMPTY(uplinks)
|
||||
var/unlock_code
|
||||
var/failsafe_code
|
||||
var/datum/ui_state/checkstate
|
||||
var/compact_mode = FALSE
|
||||
var/debug = FALSE
|
||||
|
||||
/datum/component/uplink/Initialize(_owner, _lockable = TRUE, _enabled = FALSE, datum/game_mode/_gamemode, starting_tc = 20, datum/ui_state/_checkstate)
|
||||
if(!isitem(parent))
|
||||
@@ -121,7 +123,7 @@ GLOBAL_LIST_EMPTY(uplinks)
|
||||
active = TRUE
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "uplink", name, 450, 750, master_ui, state)
|
||||
ui = new(user, src, ui_key, "uplink", name, 620, 580, master_ui, state)
|
||||
ui.set_autoupdate(FALSE) // This UI is only ever opened by one person, and never is updated outside of user input.
|
||||
ui.set_style("syndicate")
|
||||
ui.open()
|
||||
@@ -138,29 +140,35 @@ GLOBAL_LIST_EMPTY(uplinks)
|
||||
var/list/data = list()
|
||||
data["telecrystals"] = telecrystals
|
||||
data["lockable"] = lockable
|
||||
data["compact_mode"] = compact_mode
|
||||
|
||||
return data
|
||||
|
||||
/datum/component/uplink/ui_static_data(mob/user)
|
||||
var/list/data = list()
|
||||
data["categories"] = list()
|
||||
for(var/category in uplink_items)
|
||||
var/list/cat = list(
|
||||
"name" = category,
|
||||
"items" = (category == selected_cat ? list() : null))
|
||||
if(category == selected_cat)
|
||||
for(var/item in uplink_items[category])
|
||||
var/datum/uplink_item/I = uplink_items[category][item]
|
||||
if(I.limited_stock == 0)
|
||||
for(var/item in uplink_items[category])
|
||||
var/datum/uplink_item/I = uplink_items[category][item]
|
||||
if(I.limited_stock == 0)
|
||||
continue
|
||||
if(I.restricted_roles.len)
|
||||
var/is_inaccessible = TRUE
|
||||
for(var/R in I.restricted_roles)
|
||||
if(R == user.mind.assigned_role || debug)
|
||||
is_inaccessible = FALSE
|
||||
if(is_inaccessible)
|
||||
continue
|
||||
if(I.restricted_roles.len)
|
||||
var/is_inaccessible = 1
|
||||
for(var/R in I.restricted_roles)
|
||||
if(R == user.mind.assigned_role)
|
||||
is_inaccessible = 0
|
||||
if(is_inaccessible)
|
||||
continue
|
||||
cat["items"] += list(list(
|
||||
"name" = I.name,
|
||||
"cost" = I.cost,
|
||||
"desc" = I.desc,
|
||||
))
|
||||
cat["items"] += list(list(
|
||||
"name" = I.name,
|
||||
"cost" = I.cost,
|
||||
"desc" = I.desc,
|
||||
))
|
||||
data["categories"] += list(cat)
|
||||
return data
|
||||
|
||||
@@ -188,6 +196,8 @@ GLOBAL_LIST_EMPTY(uplinks)
|
||||
SStgui.close_uis(src)
|
||||
if("select")
|
||||
selected_cat = params["category"]
|
||||
if("compact_toggle")
|
||||
compact_mode = !compact_mode
|
||||
return TRUE
|
||||
|
||||
/datum/component/uplink/proc/MakePurchase(mob/user, datum/uplink_item/U)
|
||||
@@ -294,4 +304,4 @@ GLOBAL_LIST_EMPTY(uplinks)
|
||||
if(!T)
|
||||
return
|
||||
explosion(T,1,2,3)
|
||||
qdel(parent) //Alternatively could brick the uplink.
|
||||
qdel(parent) //Alternatively could brick the uplink.
|
||||
|
||||
@@ -17,12 +17,7 @@
|
||||
if(HasDisease(D))
|
||||
return FALSE
|
||||
|
||||
var/can_infect = FALSE
|
||||
for(var/host_type in D.infectable_biotypes)
|
||||
if(host_type in mob_biotypes)
|
||||
can_infect = TRUE
|
||||
break
|
||||
if(!can_infect)
|
||||
if(!(D.infectable_biotypes & mob_biotypes))
|
||||
return FALSE
|
||||
|
||||
if(!(type in D.viable_mobtypes))
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
var/list/required_organs = list()
|
||||
var/needs_all_cures = TRUE
|
||||
var/list/strain_data = list() //dna_spread special bullshit
|
||||
var/list/infectable_biotypes = list(MOB_ORGANIC) //if the disease can spread on organics, synthetics, or undead
|
||||
var/infectable_biotypes = MOB_ORGANIC //if the disease can spread on organics, synthetics, or undead
|
||||
var/process_dead = FALSE //if this ticks while the host is dead
|
||||
var/copy_type = null //if this is null, copies will use the type of the instance being copied
|
||||
|
||||
|
||||
@@ -448,8 +448,10 @@
|
||||
symptom_delay_max = 1
|
||||
passive_message = "<span class='notice'>Your skin glows faintly for a moment.</span>"
|
||||
var/cellular_damage = FALSE
|
||||
threshold_desc = "<b>Transmission 6:</b> Additionally heals cellular damage.<br>\
|
||||
<b>Resistance 7:</b> Increases healing speed."
|
||||
threshold_desc = list(
|
||||
"Transmission 6" = "Additionally heals cellular damage and toxin lovers.",
|
||||
"Resistance 7" = "Increases healing speed.",
|
||||
)
|
||||
|
||||
/datum/symptom/heal/radiation/Start(datum/disease/advance/A)
|
||||
if(!..())
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
/datum/symptom/undead_adaptation/OnRemove(datum/disease/advance/A)
|
||||
A.process_dead = FALSE
|
||||
A.infectable_biotypes -= MOB_UNDEAD
|
||||
A.infectable_biotypes &= ~MOB_UNDEAD
|
||||
|
||||
/datum/symptom/inorganic_adaptation
|
||||
name = "Inorganic Biology"
|
||||
@@ -30,4 +30,4 @@
|
||||
A.infectable_biotypes |= MOB_INORGANIC
|
||||
|
||||
/datum/symptom/inorganic_adaptation/OnRemove(datum/disease/advance/A)
|
||||
A.infectable_biotypes -= MOB_INORGANIC
|
||||
A.infectable_biotypes &= ~MOB_INORGANIC
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
|
||||
desc = "If left untreated subject will regurgitate bees."
|
||||
severity = DISEASE_SEVERITY_MEDIUM
|
||||
infectable_biotypes = list(MOB_ORGANIC, MOB_UNDEAD) //bees nesting in corpses
|
||||
infectable_biotypes = MOB_ORGANIC|MOB_UNDEAD //bees nesting in corpses
|
||||
|
||||
/datum/disease/beesease/stage_act()
|
||||
..()
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
permeability_mod = 0.75
|
||||
desc = "This disease disrupts the magnetic field of your body, making it act as if a powerful magnet. Injections of iron help stabilize the field."
|
||||
severity = DISEASE_SEVERITY_MEDIUM
|
||||
infectable_biotypes = list(MOB_ORGANIC, MOB_ROBOTIC)
|
||||
infectable_biotypes = MOB_ORGANIC|MOB_ROBOTIC
|
||||
process_dead = TRUE
|
||||
|
||||
/datum/disease/magnitis/stage_act()
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
viable_mobtypes = list(/mob/living/carbon/human)
|
||||
desc = "Subject is possessed by the vengeful spirit of a parrot. Call the priest."
|
||||
severity = DISEASE_SEVERITY_MEDIUM
|
||||
infectable_biotypes = list(MOB_ORGANIC, MOB_UNDEAD, MOB_INORGANIC, MOB_ROBOTIC)
|
||||
infectable_biotypes = MOB_ORGANIC|MOB_UNDEAD|MOB_INORGANIC|MOB_ROBOTIC
|
||||
bypasses_immunity = TRUE //2spook
|
||||
var/mob/living/simple_animal/parrot/Poly/ghost/parrot
|
||||
|
||||
|
||||
@@ -168,7 +168,7 @@
|
||||
stage4 = list("<span class='danger'>Your skin feels very loose.</span>", "<span class='danger'>You can feel... something...inside you.</span>")
|
||||
stage5 = list("<span class='danger'>Your skin feels as if it's about to burst off!</span>")
|
||||
new_form = /mob/living/silicon/robot
|
||||
infectable_biotypes = list(MOB_ORGANIC, MOB_UNDEAD, MOB_ROBOTIC)
|
||||
infectable_biotypes = MOB_ORGANIC|MOB_UNDEAD|MOB_ROBOTIC
|
||||
bantype = "Cyborg"
|
||||
|
||||
/datum/disease/transformation/robot/stage_act()
|
||||
@@ -200,7 +200,7 @@
|
||||
stage3 = list("<span class='danger'>Your throat feels very scratchy.</span>", "Your skin feels tight.", "<span class='danger'>You can feel something move...inside.</span>")
|
||||
stage4 = list("<span class='danger'>Your skin feels very tight.</span>", "<span class='danger'>Your blood boils!</span>", "<span class='danger'>You can feel... something...inside you.</span>")
|
||||
stage5 = list("<span class='danger'>Your skin feels as if it's about to burst off!</span>")
|
||||
new_form = /mob/living/carbon/alien/humanoid/hunter
|
||||
new_form = /mob/living/carbon/alien/humanoid/sentinel
|
||||
bantype = ROLE_ALIEN
|
||||
|
||||
/datum/disease/transformation/xeno/stage_act()
|
||||
@@ -284,7 +284,7 @@
|
||||
stage4 = list("<span class='danger'>You're ravenous.</span>")
|
||||
stage5 = list("<span class='danger'>You have become a morph.</span>")
|
||||
new_form = /mob/living/simple_animal/hostile/morph
|
||||
infectable_biotypes = list(MOB_ORGANIC, MOB_INORGANIC, MOB_UNDEAD) //magic!
|
||||
infectable_biotypes = MOB_ORGANIC|MOB_INORGANIC|MOB_UNDEAD //magic!
|
||||
|
||||
/datum/disease/transformation/gondola
|
||||
name = "Gondola Transformation"
|
||||
|
||||
+7
-2
@@ -54,10 +54,12 @@
|
||||
if(ishuman(destination))
|
||||
var/mob/living/carbon/human/H = destination
|
||||
H.give_genitals(TRUE)//This gives the body the genitals of this DNA. Used for any transformations based on DNA
|
||||
destination.flavor_text = destination.dna.features["flavor_text"] //Update the flavor_text to use new dna text
|
||||
destination.ooc_text = destination.dna.features["ooc_text"] //Update the flavor_text to use new dna text
|
||||
if(transfer_SE)
|
||||
destination.dna.mutation_index = mutation_index
|
||||
|
||||
SEND_SIGNAL(destination, COMSIG_CARBON_IDENTITY_TRANSFERRED_TO, src, transfer_SE)
|
||||
|
||||
/datum/dna/proc/copy_dna(datum/dna/new_dna)
|
||||
new_dna.unique_enzymes = unique_enzymes
|
||||
new_dna.mutation_index = mutation_index
|
||||
@@ -355,7 +357,7 @@
|
||||
|
||||
if(newfeatures)
|
||||
dna.features = newfeatures
|
||||
flavor_text = dna.features["flavor_text"] //Update the flavor_text to use new dna text
|
||||
ooc_text = dna.features["ooc_text"] //Update the flavor_text to use new dna text
|
||||
|
||||
if(mrace)
|
||||
var/datum/species/newrace = new mrace.type
|
||||
@@ -377,6 +379,9 @@
|
||||
dna.mutation_index = mutation_index
|
||||
domutcheck()
|
||||
|
||||
SEND_SIGNAL(src, COMSIG_HUMAN_HARDSET_DNA, ui, newreal_name, newblood_type, mrace, newfeatures)
|
||||
// change to SEND_SIGNAL(src, COMSIG_HUMAN_HARDSET_DNA, ui, se, newreal_name, newblood_type, mrace, newfeatures) if we add structural enzymes.
|
||||
|
||||
if(mrace || newfeatures || ui)
|
||||
update_body()
|
||||
update_hair()
|
||||
|
||||
@@ -0,0 +1,188 @@
|
||||
GLOBAL_LIST_EMPTY(mobs_with_editable_flavor_text) //et tu, hacky code
|
||||
|
||||
/datum/element/flavor_text
|
||||
element_flags = ELEMENT_BESPOKE|ELEMENT_DETACH
|
||||
id_arg_index = 3
|
||||
var/flavor_name = "Flavor Text"
|
||||
var/list/texts_by_atom = list()
|
||||
var/addendum = ""
|
||||
var/always_show = FALSE
|
||||
var/max_len = MAX_FLAVOR_LEN
|
||||
var/can_edit = TRUE
|
||||
/// For preference/DNA saving/loading. Null to prevent. Prefs are only loaded from obviously if it exists in preferences.features.
|
||||
var/save_key
|
||||
/// Do not attempt to render a preview on examine. If this is on, it will display as \[flavor_name\]
|
||||
var/examine_no_preview = FALSE
|
||||
var/examineTabOutput = ""
|
||||
|
||||
/datum/element/flavor_text/Attach(datum/target, text = "", _name = "Flavor Text", _addendum, _max_len = MAX_FLAVOR_LEN, _always_show = FALSE, _edit = TRUE, _save_key, _examine_no_preview = FALSE)
|
||||
. = ..()
|
||||
|
||||
if(. == ELEMENT_INCOMPATIBLE || !isatom(target)) //no reason why this shouldn't work on atoms too.
|
||||
return ELEMENT_INCOMPATIBLE
|
||||
|
||||
if(_max_len)
|
||||
max_len = _max_len
|
||||
texts_by_atom[target] = copytext(text, 1, max_len)
|
||||
if(_name)
|
||||
flavor_name = _name
|
||||
if(!isnull(addendum))
|
||||
addendum = _addendum
|
||||
always_show = _always_show
|
||||
can_edit = _edit
|
||||
save_key = _save_key
|
||||
examine_no_preview = _examine_no_preview
|
||||
|
||||
RegisterSignal(target, COMSIG_PARENT_EXAMINE, .proc/show_flavor)
|
||||
|
||||
if(can_edit && ismob(target)) //but only mobs receive the proc/verb for the time being
|
||||
var/mob/M = target
|
||||
LAZYOR(GLOB.mobs_with_editable_flavor_text[M], src)
|
||||
M.verbs |= /mob/proc/manage_flavor_tests
|
||||
|
||||
if(save_key && ishuman(target))
|
||||
RegisterSignal(target, COMSIG_HUMAN_PREFS_COPIED_TO, .proc/update_prefs_flavor_text)
|
||||
|
||||
/datum/element/flavor_text/Detach(atom/A)
|
||||
. = ..()
|
||||
UnregisterSignal(A, list(COMSIG_PARENT_EXAMINE, COMSIG_HUMAN_PREFS_COPIED_TO))
|
||||
texts_by_atom -= A
|
||||
if(can_edit && ismob(A))
|
||||
var/mob/M = A
|
||||
LAZYREMOVE(GLOB.mobs_with_editable_flavor_text[M], src)
|
||||
if(!GLOB.mobs_with_editable_flavor_text[M])
|
||||
GLOB.mobs_with_editable_flavor_text -= M
|
||||
M.verbs -= /mob/proc/manage_flavor_tests
|
||||
|
||||
/datum/element/flavor_text/proc/show_flavor(atom/target, mob/user, list/examine_list)
|
||||
if(!always_show && isliving(target))
|
||||
var/mob/living/L = target
|
||||
var/unknown = L.get_visible_name() == "Unknown"
|
||||
if(!unknown && iscarbon(target))
|
||||
var/mob/living/carbon/C = L
|
||||
unknown = (C.wear_mask && (C.wear_mask.flags_inv & HIDEFACE)) || (C.head && (C.head.flags_inv & HIDEFACE))
|
||||
if(unknown)
|
||||
if(!("...?" in examine_list)) //can't think of anything better in case of multiple flavor texts.
|
||||
examine_list += "...?"
|
||||
return
|
||||
var/text = texts_by_atom[target]
|
||||
if(!text)
|
||||
return
|
||||
if(examine_no_preview)
|
||||
examine_list += "<span class='notice'><a href='?src=[REF(src)];show_flavor=[REF(target)]'>\[[flavor_name]\]</a></span>"
|
||||
return
|
||||
var/msg = replacetext(text, "\n", " ")
|
||||
if(length_char(msg) <= 40)
|
||||
examine_list += "<span class='notice'>[msg]</span>"
|
||||
else
|
||||
examine_list += "<span class='notice'>[copytext_char(msg, 1, 37)]... <a href='?src=[REF(src)];show_flavor=[REF(target)]'>More...</span></a>"
|
||||
|
||||
//Examine Tab stuff - Hyperstation
|
||||
examineTabOutput = "<center>"
|
||||
if(ishuman(target)) //user just returned, y'know, the user's own species. dumb.
|
||||
var/mob/living/carbon/human/L = target
|
||||
if(L.gender)
|
||||
examineTabOutput += "[icon2html('hyperstation/icons/chat/gender.dmi', world, L.gender)]"
|
||||
examineTabOutput += "[L.name] "
|
||||
examineTabOutput += "([L.dna.custom_species ? L.dna.custom_species : L.dna.species.name])"
|
||||
examineTabOutput += "</center>"
|
||||
examineTabOutput += "<br>[url_encode(msg)]"
|
||||
if(ismob(target))
|
||||
var/mob/M = target
|
||||
if(M.ooc_text)
|
||||
examineTabOutput += "<br><br><i><b>OOC</b>"
|
||||
examineTabOutput += "<br>[url_encode(M.ooc_text)]"
|
||||
user.client << output(examineTabOutput, "statbrowser:update_examine") //open the examine window
|
||||
user.client << output(null, "statbrowser:create_mobexamine") //open the examine window
|
||||
|
||||
/datum/element/flavor_text/Topic(href, href_list)
|
||||
. = ..()
|
||||
if(.)
|
||||
return
|
||||
if(href_list["show_flavor"])
|
||||
var/atom/target = locate(href_list["show_flavor"])
|
||||
var/text = texts_by_atom[target]
|
||||
if(text)
|
||||
usr << browse("<HTML><HEAD><meta http-equiv='Content-Type' content='text/html; charset=UTF-8'><TITLE>[target.name]</TITLE></HEAD><BODY><TT>[replacetext(texts_by_atom[target], "\n", "<BR>")]</TT></BODY></HTML>", "window=[target.name];size=500x200")
|
||||
onclose(usr, "[target.name]")
|
||||
return TRUE
|
||||
|
||||
/mob/proc/manage_flavor_tests()
|
||||
set name = "Manage Flavor Texts"
|
||||
set desc = "Used to manage your various flavor texts."
|
||||
set category = "IC"
|
||||
|
||||
var/list/L = GLOB.mobs_with_editable_flavor_text[src]
|
||||
|
||||
if(length(L) == 1)
|
||||
var/datum/element/flavor_text/F = L[1]
|
||||
F.set_flavor(src)
|
||||
return
|
||||
|
||||
var/list/choices = list()
|
||||
|
||||
for(var/i in L)
|
||||
var/datum/element/flavor_text/F = i
|
||||
choices[F.flavor_name] = F
|
||||
|
||||
var/chosen = input(src, "Which flavor text would you like to modify?") as null|anything in choices
|
||||
if(!chosen)
|
||||
return
|
||||
var/datum/element/flavor_text/F = choices[chosen]
|
||||
F.set_flavor(src)
|
||||
|
||||
/datum/element/flavor_text/proc/set_flavor(mob/user)
|
||||
if(!(user in texts_by_atom))
|
||||
return FALSE
|
||||
|
||||
var/lower_name = lowertext(flavor_name)
|
||||
var/new_text = stripped_multiline_input(user, "Set the [lower_name] displayed on 'examine'. [addendum]", flavor_name, html_decode(texts_by_atom[usr]), max_len, TRUE)
|
||||
if(!isnull(new_text) && (user in texts_by_atom))
|
||||
texts_by_atom[user] = new_text
|
||||
to_chat(src, "Your [lower_name] has been updated.")
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/datum/element/flavor_text/proc/update_prefs_flavor_text(mob/living/carbon/human/H, datum/preferences/P, icon_updates = TRUE, roundstart_checks = TRUE)
|
||||
if(P.features.Find(save_key))
|
||||
texts_by_atom[H] = P.features[save_key]
|
||||
|
||||
//subtypes with additional hooks for DNA and preferences.
|
||||
/datum/element/flavor_text/carbon
|
||||
//list of antagonists etcetera that should have nothing to do with people's snowflakes.
|
||||
var/static/list/i_dont_even_know_who_you_are = typecacheof(list(/datum/antagonist/abductor, /datum/antagonist/ert,
|
||||
/datum/antagonist/nukeop, /datum/antagonist/wizard))
|
||||
|
||||
/datum/element/flavor_text/carbon/Attach(datum/target, text = "", _name = "Flavor Text", _addendum, _max_len = MAX_FLAVOR_LEN, _always_show = FALSE, _edit = TRUE, _save_key = "flavor_text", _examine_no_preview = FALSE)
|
||||
if(!iscarbon(target))
|
||||
return ELEMENT_INCOMPATIBLE
|
||||
. = ..()
|
||||
if(. == ELEMENT_INCOMPATIBLE)
|
||||
return
|
||||
RegisterSignal(target, COMSIG_CARBON_IDENTITY_TRANSFERRED_TO, .proc/update_dna_flavor_text)
|
||||
RegisterSignal(target, COMSIG_MOB_ANTAG_ON_GAIN, .proc/on_antag_gain)
|
||||
if(ishuman(target))
|
||||
RegisterSignal(target, COMSIG_HUMAN_HARDSET_DNA, .proc/update_dna_flavor_text)
|
||||
RegisterSignal(target, COMSIG_HUMAN_ON_RANDOMIZE, .proc/unset_flavor)
|
||||
|
||||
/datum/element/flavor_text/carbon/Detach(mob/living/carbon/C)
|
||||
. = ..()
|
||||
UnregisterSignal(C, list(COMSIG_CARBON_IDENTITY_TRANSFERRED_TO, COMSIG_MOB_ANTAG_ON_GAIN, COMSIG_HUMAN_PREFS_COPIED_TO, COMSIG_HUMAN_HARDSET_DNA, COMSIG_HUMAN_ON_RANDOMIZE))
|
||||
|
||||
/datum/element/flavor_text/carbon/proc/update_dna_flavor_text(mob/living/carbon/C)
|
||||
texts_by_atom[C] = C.dna.features[save_key]
|
||||
|
||||
/datum/element/flavor_text/carbon/set_flavor(mob/living/carbon/user)
|
||||
. = ..()
|
||||
if(. && user.dna)
|
||||
user.dna.features[save_key] = texts_by_atom[user]
|
||||
|
||||
/datum/element/flavor_text/carbon/proc/unset_flavor(mob/living/carbon/user)
|
||||
texts_by_atom[user] = ""
|
||||
|
||||
|
||||
/datum/element/flavor_text/carbon/proc/on_antag_gain(mob/living/carbon/user, datum/antagonist/antag)
|
||||
if(is_type_in_typecache(antag, i_dont_even_know_who_you_are))
|
||||
texts_by_atom[user] = ""
|
||||
if(user.dna)
|
||||
user.dna.features[save_key] = ""
|
||||
@@ -198,7 +198,7 @@ GLOBAL_LIST_EMPTY(explosions)
|
||||
var/list/items = list()
|
||||
for(var/I in T)
|
||||
var/atom/A = I
|
||||
if (!A.prevent_content_explosion()) //The atom/contents_explosion() proc returns null if the contents ex_acting has been handled by the atom, and TRUE if it hasn't.
|
||||
if (!(A.flags_1 & PREVENT_CONTENTS_EXPLOSION_1)) //The atom/contents_explosion() proc returns null if the contents ex_acting has been handled by the atom, and TRUE if it hasn't.
|
||||
items += A.GetAllContents()
|
||||
for(var/O in items)
|
||||
var/atom/A = O
|
||||
|
||||
@@ -85,6 +85,15 @@
|
||||
var/mob/M = teleatom
|
||||
M.cancel_camera()
|
||||
|
||||
var/static/list/bread_cache = typecacheof(/obj/item/reagent_containers/food/snacks/store/bread)
|
||||
var/list/breadlist = typecache_filter_list(teleatom.GetAllContents(), bread_cache)
|
||||
if(breadlist.len && (channel == TELEPORT_CHANNEL_BLUESPACE || channel == TELEPORT_CHANNEL_QUANTUM))
|
||||
for(var/obj/item/reagent_containers/food/snacks/store/bread/bread in breadlist)
|
||||
bread.bread_teleport()
|
||||
else if(istype(teleatom, /obj/item/reagent_containers/food/snacks/store/bread))
|
||||
var/obj/item/reagent_containers/food/snacks/store/bread/bread = teleatom
|
||||
bread.bread_teleport()
|
||||
|
||||
return TRUE
|
||||
|
||||
/proc/tele_play_specials(atom/movable/teleatom, atom/location, datum/effect_system/effect, sound)
|
||||
|
||||
@@ -196,8 +196,8 @@
|
||||
/obj/item/clothing/gloves/krav_maga/combatglovesplus
|
||||
name = "combat gloves plus"
|
||||
desc = "These tactical gloves are fireproof and shock resistant, and using nanochip technology it teaches you the powers of krav maga."
|
||||
icon_state = "combat"
|
||||
item_state = "blackgloves"
|
||||
icon_state = "fightglovesblack"
|
||||
item_state = "fightglovesblack"
|
||||
siemens_coefficient = 0
|
||||
permeability_coefficient = 0.05
|
||||
strip_delay = 80
|
||||
|
||||
@@ -41,6 +41,8 @@
|
||||
var/special_role
|
||||
var/list/restricted_roles = list()
|
||||
|
||||
var/hide_ckey = FALSE
|
||||
|
||||
var/list/datum/objective/objectives = list()
|
||||
|
||||
var/list/spell_list = list() // Wizard mode & "Give Spell" badmin button.
|
||||
@@ -126,6 +128,9 @@
|
||||
transfer_martial_arts(new_character)
|
||||
if(active || force_key_move)
|
||||
new_character.key = key //now transfer the key to link the client to our new body
|
||||
if(new_character.client)
|
||||
//LAZYCLEARLIST(new_character.client.recent_examines)
|
||||
new_character.client.init_verbs() // re-initialize character specific verbs
|
||||
|
||||
//CIT CHANGE - makes arousal update when transfering bodies
|
||||
if(isliving(new_character)) //New humans and such are by default enabled arousal. Let's always use the new mind's prefs.
|
||||
@@ -134,6 +139,8 @@
|
||||
L.canbearoused = L.client.prefs.arousable //Technically this should make taking over a character mean the body gain the new minds setting...
|
||||
L.update_arousal_hud() //Removes the old icon
|
||||
|
||||
hide_ckey = current.client?.prefs?.hide_ckey
|
||||
|
||||
/datum/mind/proc/store_memory(new_text)
|
||||
if((length_char(memory) + length_char(new_text)) <= MAX_MESSAGE_LEN)
|
||||
memory += "[new_text]<BR>"
|
||||
@@ -767,6 +774,7 @@
|
||||
if(istype(S, spell))
|
||||
spell_list -= S
|
||||
qdel(S)
|
||||
current?.client << output(null, "statbrowser:check_spells")
|
||||
|
||||
/datum/mind/proc/RemoveAllSpells()
|
||||
for(var/obj/effect/proc_holder/S in spell_list)
|
||||
@@ -853,6 +861,7 @@
|
||||
if(!mind.name)
|
||||
mind.name = real_name
|
||||
mind.current = src
|
||||
mind.hide_ckey = client?.prefs?.hide_ckey
|
||||
|
||||
/mob/living/carbon/mind_initialize()
|
||||
..()
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user