mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 03:57:13 +01:00
Merge branch 'master' of https://github.com/ParadiseSS13/Paradise into shuttlechairs
# Conflicts: # _maps/map_files/cyberiad/cyberiad.dmm
This commit is contained in:
@@ -254,7 +254,7 @@ CREATE TABLE `player` (
|
||||
`UI_style_alpha` smallint(4) DEFAULT '255',
|
||||
`be_role` mediumtext,
|
||||
`default_slot` smallint(4) DEFAULT '1',
|
||||
`toggles` mediumint(8) DEFAULT '383',
|
||||
`toggles` int(8) DEFAULT '383',
|
||||
`sound` mediumint(8) DEFAULT '31',
|
||||
`randomslot` tinyint(1) DEFAULT '0',
|
||||
`volume` smallint(4) DEFAULT '100',
|
||||
|
||||
@@ -253,7 +253,7 @@ CREATE TABLE `SS13_player` (
|
||||
`UI_style_alpha` smallint(4) DEFAULT '255',
|
||||
`be_role` mediumtext,
|
||||
`default_slot` smallint(4) DEFAULT '1',
|
||||
`toggles` mediumint(8) DEFAULT '383',
|
||||
`toggles` int(8) DEFAULT '383',
|
||||
`sound` mediumint(8) DEFAULT '31',
|
||||
`randomslot` tinyint(1) DEFAULT '0',
|
||||
`volume` smallint(4) DEFAULT '100',
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
ALTER TABLE player
|
||||
MODIFY COLUMN toggles int;
|
||||
+162226
-9252
File diff suppressed because it is too large
Load Diff
@@ -200,7 +200,8 @@
|
||||
dir = 1;
|
||||
pixel_y = -24
|
||||
},
|
||||
/turf/simulated/floor/mech_bay_recharge_floor,
|
||||
/obj/machinery/suit_storage_unit/lavaland,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"aJ" = (
|
||||
/obj/machinery/light/small{
|
||||
@@ -436,12 +437,6 @@
|
||||
/turf/simulated/floor/plasteel/freezer,
|
||||
/area/mine/living_quarters)
|
||||
"bp" = (
|
||||
/obj/structure/table,
|
||||
/obj/item/pickaxe,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 1
|
||||
},
|
||||
@@ -451,6 +446,7 @@
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 4
|
||||
},
|
||||
/obj/machinery/suit_storage_unit/lavaland,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"bq" = (
|
||||
@@ -594,11 +590,6 @@
|
||||
/obj/machinery/light{
|
||||
dir = 8
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/storage/toolbox/mechanical{
|
||||
pixel_x = -2;
|
||||
pixel_y = -1
|
||||
},
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 8
|
||||
},
|
||||
@@ -611,7 +602,19 @@
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 8
|
||||
},
|
||||
/obj/machinery/suit_storage_unit/lavaland,
|
||||
/obj/structure/table,
|
||||
/obj/item/storage/toolbox/mechanical{
|
||||
pixel_x = -2;
|
||||
pixel_y = -1
|
||||
},
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/obj/item/gps/mining,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"bF" = (
|
||||
@@ -758,9 +761,6 @@
|
||||
/obj/machinery/atmospherics/pipe/simple/hidden/supply{
|
||||
dir = 4
|
||||
},
|
||||
/obj/structure/cable{
|
||||
icon_state = "2-8"
|
||||
},
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"bV" = (
|
||||
@@ -943,16 +943,15 @@
|
||||
pixel_y = -23
|
||||
},
|
||||
/obj/structure/cable,
|
||||
/obj/machinery/recharge_station,
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 1
|
||||
},
|
||||
/obj/machinery/suit_storage_unit/lavaland,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"cp" = (
|
||||
/obj/machinery/mech_bay_recharge_port,
|
||||
/obj/structure/cable,
|
||||
/turf/simulated/floor/plating,
|
||||
/obj/machinery/suit_storage_unit/lavaland,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"cq" = (
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
@@ -977,9 +976,6 @@
|
||||
/obj/machinery/atmospherics/pipe/simple/hidden/supply{
|
||||
dir = 4
|
||||
},
|
||||
/obj/structure/cable{
|
||||
icon_state = "4-8"
|
||||
},
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 1
|
||||
},
|
||||
@@ -1854,13 +1850,10 @@
|
||||
/turf/simulated/wall,
|
||||
/area/mine/production)
|
||||
"eo" = (
|
||||
/obj/machinery/computer/mech_bay_power_console{
|
||||
icon_state = "computer";
|
||||
dir = 1
|
||||
},
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 4
|
||||
},
|
||||
/obj/machinery/suit_storage_unit/lavaland,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/eva)
|
||||
"ep" = (
|
||||
@@ -2023,6 +2016,9 @@
|
||||
/obj/structure/cable{
|
||||
icon_state = "1-8"
|
||||
},
|
||||
/obj/structure/cable{
|
||||
icon_state = "2-8"
|
||||
},
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"eD" = (
|
||||
@@ -2100,6 +2096,7 @@
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 8
|
||||
},
|
||||
/obj/structure/ore_box,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"eK" = (
|
||||
@@ -2148,6 +2145,9 @@
|
||||
/obj/machinery/atmospherics/unary/vent_pump/on{
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/cable{
|
||||
icon_state = "1-2"
|
||||
},
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"eQ" = (
|
||||
@@ -2237,13 +2237,11 @@
|
||||
dir = 1;
|
||||
pixel_y = -22
|
||||
},
|
||||
/obj/structure/closet/crate{
|
||||
icon_state = "crateopen"
|
||||
},
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 8
|
||||
},
|
||||
/obj/effect/turf_decal/tile/purple,
|
||||
/obj/machinery/recharge_station,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"fc" = (
|
||||
@@ -2253,9 +2251,6 @@
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fd" = (
|
||||
/obj/structure/closet/crate{
|
||||
icon_state = "crateopen"
|
||||
},
|
||||
/obj/machinery/light,
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 8
|
||||
@@ -2263,6 +2258,8 @@
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 2
|
||||
},
|
||||
/obj/machinery/mech_bay_recharge_port,
|
||||
/obj/structure/cable,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"fe" = (
|
||||
@@ -2290,12 +2287,7 @@
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fh" = (
|
||||
/obj/structure/closet/crate,
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 8
|
||||
},
|
||||
/obj/effect/turf_decal/tile/purple,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/turf/simulated/floor/mech_bay_recharge_floor,
|
||||
/area/mine/production)
|
||||
"fi" = (
|
||||
/obj/machinery/atmospherics/pipe/manifold/hidden/supply{
|
||||
@@ -2304,15 +2296,16 @@
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fj" = (
|
||||
/obj/structure/closet/crate{
|
||||
icon_state = "crateopen"
|
||||
},
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 8
|
||||
},
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 2
|
||||
},
|
||||
/obj/machinery/computer/mech_bay_power_console{
|
||||
icon_state = "computer";
|
||||
dir = 1
|
||||
},
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"fk" = (
|
||||
@@ -2500,7 +2493,6 @@
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fE" = (
|
||||
/obj/structure/ore_box,
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 8
|
||||
},
|
||||
@@ -2579,7 +2571,6 @@
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fL" = (
|
||||
/obj/structure/ore_box,
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 8
|
||||
},
|
||||
@@ -2589,14 +2580,15 @@
|
||||
/obj/effect/turf_decal/tile/brown{
|
||||
dir = 2
|
||||
},
|
||||
/obj/structure/closet/secure_closet/miner,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fM" = (
|
||||
/obj/machinery/recharge_station,
|
||||
/obj/effect/turf_decal/tile/purple,
|
||||
/obj/effect/turf_decal/tile/purple{
|
||||
dir = 8
|
||||
},
|
||||
/obj/structure/closet/secure_closet/miner,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/living_quarters)
|
||||
"fN" = (
|
||||
@@ -4090,6 +4082,10 @@
|
||||
},
|
||||
/turf/simulated/floor/plasteel/freezer,
|
||||
/area/mine/living_quarters)
|
||||
"tK" = (
|
||||
/obj/structure/ore_box,
|
||||
/turf/simulated/floor/plasteel,
|
||||
/area/mine/production)
|
||||
"vq" = (
|
||||
/obj/machinery/atmospherics/unary/vent_scrubber/on,
|
||||
/turf/simulated/floor/plasteel,
|
||||
@@ -20710,7 +20706,7 @@ dL
|
||||
ej
|
||||
eG
|
||||
ct
|
||||
eW
|
||||
tK
|
||||
bN
|
||||
ab
|
||||
ab
|
||||
|
||||
@@ -248,7 +248,8 @@ GLOBAL_DATUM_INIT(pipe_icon_manager, /datum/pipe_icon_manager, new())
|
||||
// Ventcrawling
|
||||
#define VENT_SOUND_DELAY 30
|
||||
/obj/machinery/atmospherics/relaymove(mob/living/user, direction)
|
||||
if(!(direction & initialize_directions)) //can't go in a way we aren't connecting to
|
||||
direction &= initialize_directions
|
||||
if(!direction || !(direction in cardinal)) //cant go this way.
|
||||
return
|
||||
|
||||
if(buckled_mob == user)
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
|
||||
#define COLOR_INPUT_DISABLED "#F0F0F0"
|
||||
#define COLOR_INPUT_ENABLED "#D3B5B5"
|
||||
#define COLOR_WHITE "#EEEEEE"
|
||||
#define COLOR_SILVER "#C0C0C0"
|
||||
#define COLOR_GRAY "#808080"
|
||||
#define COLOR_FLOORTILE_GRAY "#8D8B8B"
|
||||
#define COLOR_ALMOST_BLACK "#333333"
|
||||
#define COLOR_BLACK "#000000"
|
||||
#define COLOR_RED "#FF0000"
|
||||
#define COLOR_RED_LIGHT "#FF3333"
|
||||
#define COLOR_MAROON "#800000"
|
||||
#define COLOR_YELLOW "#FFFF00"
|
||||
#define COLOR_OLIVE "#808000"
|
||||
#define COLOR_LIME "#32CD32"
|
||||
#define COLOR_GREEN "#008000"
|
||||
#define COLOR_CYAN "#00FFFF"
|
||||
#define COLOR_TEAL "#008080"
|
||||
#define COLOR_BLUE "#0000FF"
|
||||
#define COLOR_BLUE_LIGHT "#33CCFF"
|
||||
#define COLOR_NAVY "#000080"
|
||||
#define COLOR_PINK "#FFC0CB"
|
||||
#define COLOR_MAGENTA "#FF00FF"
|
||||
#define COLOR_PURPLE "#800080"
|
||||
#define COLOR_ORANGE "#FF9900"
|
||||
#define COLOR_BEIGE "#CEB689"
|
||||
#define COLOR_BLUE_GRAY "#75A2BB"
|
||||
#define COLOR_BROWN "#BA9F6D"
|
||||
#define COLOR_DARK_BROWN "#997C4F"
|
||||
#define COLOR_DARK_ORANGE "#C3630C"
|
||||
#define COLOR_GREEN_GRAY "#99BB76"
|
||||
#define COLOR_RED_GRAY "#B4696A"
|
||||
#define COLOR_PALE_BLUE_GRAY "#98C5DF"
|
||||
#define COLOR_PALE_GREEN_GRAY "#B7D993"
|
||||
#define COLOR_PALE_RED_GRAY "#D59998"
|
||||
#define COLOR_PALE_PURPLE_GRAY "#CBB1CA"
|
||||
#define COLOR_PURPLE_GRAY "#AE8CA8"
|
||||
|
||||
//Color defines used by the assembly detailer.
|
||||
#define COLOR_ASSEMBLY_BLACK "#545454"
|
||||
#define COLOR_ASSEMBLY_BGRAY "#9497AB"
|
||||
#define COLOR_ASSEMBLY_WHITE "#E2E2E2"
|
||||
#define COLOR_ASSEMBLY_RED "#CC4242"
|
||||
#define COLOR_ASSEMBLY_ORANGE "#E39751"
|
||||
#define COLOR_ASSEMBLY_BEIGE "#AF9366"
|
||||
#define COLOR_ASSEMBLY_BROWN "#97670E"
|
||||
#define COLOR_ASSEMBLY_GOLD "#AA9100"
|
||||
#define COLOR_ASSEMBLY_YELLOW "#CECA2B"
|
||||
#define COLOR_ASSEMBLY_GURKHA "#999875"
|
||||
#define COLOR_ASSEMBLY_LGREEN "#789876"
|
||||
#define COLOR_ASSEMBLY_GREEN "#44843C"
|
||||
#define COLOR_ASSEMBLY_LBLUE "#5D99BE"
|
||||
#define COLOR_ASSEMBLY_BLUE "#38559E"
|
||||
#define COLOR_ASSEMBLY_PURPLE "#6F6192"
|
||||
@@ -70,6 +70,10 @@
|
||||
#define ATTACK_EFFECT_MECHFIRE "mech_fire"
|
||||
#define ATTACK_EFFECT_MECHTOXIN "mech_toxin"
|
||||
#define ATTACK_EFFECT_BOOP "boop" //Honk
|
||||
//NOTE: INTENT_HOTKEY_* defines are not actual intents!
|
||||
//they are here to support hotkeys
|
||||
#define INTENT_HOTKEY_LEFT "left"
|
||||
#define INTENT_HOTKEY_RIGHT "right"
|
||||
|
||||
//Embedded objects
|
||||
#define EMBEDDED_PAIN_CHANCE 15 //Chance for embedded objects to cause pain (damage user)
|
||||
@@ -82,6 +86,22 @@
|
||||
#define EMBEDDED_UNSAFE_REMOVAL_PAIN_MULTIPLIER 8 //Coefficient of multiplication for the damage the item does when removed without a surgery (this*item.w_class)
|
||||
#define EMBEDDED_UNSAFE_REMOVAL_TIME 30 //A Time in ticks, total removal time = (this*item.w_class)
|
||||
|
||||
// Body Parts
|
||||
#define BODY_ZONE_HEAD "head"
|
||||
#define BODY_ZONE_CHEST "chest"
|
||||
#define BODY_ZONE_L_ARM "l_arm"
|
||||
#define BODY_ZONE_R_ARM "r_arm"
|
||||
#define BODY_ZONE_L_LEG "l_leg"
|
||||
#define BODY_ZONE_R_LEG "r_leg"
|
||||
|
||||
#define BODY_ZONE_PRECISE_EYES "eyes"
|
||||
#define BODY_ZONE_PRECISE_MOUTH "mouth"
|
||||
#define BODY_ZONE_PRECISE_GROIN "groin"
|
||||
#define BODY_ZONE_PRECISE_L_HAND "l_hand"
|
||||
#define BODY_ZONE_PRECISE_R_HAND "r_hand"
|
||||
#define BODY_ZONE_PRECISE_L_FOOT "l_foot"
|
||||
#define BODY_ZONE_PRECISE_R_FOOT "r_foot"
|
||||
|
||||
//Gun Stuff
|
||||
#define SAWN_INTACT 0
|
||||
#define SAWN_OFF 1
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
#define ALL ~0 //For convenience.
|
||||
#define NONE 0
|
||||
|
||||
// for /datum/var/datum_flags
|
||||
#define DF_USE_TAG (1<<0)
|
||||
|
||||
//FLAGS BITMASK
|
||||
#define STOPSPRESSUREDMAGE 1 //This flag is used on the flags variable for SUIT and HEAD items which stop pressure damage. Note that the flag 1 was previous used as ONBACK, so it is possible for some code to use (flags & 1) when checking if something can be put on your back. Replace this code with (inv_flags & SLOT_BACK) if you see it anywhere To successfully stop you taking all pressure damage you must have both a suit and head item with this flag.
|
||||
#define NODROP 2 // This flag makes it so that an item literally cannot be removed at all, or at least that's how it should be. Only deleted.
|
||||
|
||||
+1
-12
@@ -57,17 +57,6 @@
|
||||
#define MAX_STACK_AMOUNT_GLASS 50
|
||||
#define MAX_STACK_AMOUNT_RODS 60
|
||||
|
||||
//some colors
|
||||
#define COLOR_RED "#FF0000"
|
||||
#define COLOR_GREEN "#00FF00"
|
||||
#define COLOR_BLUE "#0000FF"
|
||||
#define COLOR_CYAN "#00FFFF"
|
||||
#define COLOR_PINK "#FF00FF"
|
||||
#define COLOR_YELLOW "#FFFF00"
|
||||
#define COLOR_ORANGE "#FF9900"
|
||||
#define COLOR_WHITE "#FFFFFF"
|
||||
#define COLOR_GRAY "#808080"
|
||||
|
||||
//FONTS:
|
||||
// Used by Paper and PhotoCopier (and PaperBin once a year).
|
||||
// Used by PDA's Notekeeper.
|
||||
@@ -326,7 +315,7 @@
|
||||
#define INVESTIGATE_BOMB "bombs"
|
||||
|
||||
// The SQL version required by this version of the code
|
||||
#define SQL_VERSION 6
|
||||
#define SQL_VERSION 7
|
||||
|
||||
// Vending machine stuff
|
||||
#define CAT_NORMAL 1
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
#define CHAT_GHOSTSIGHT 8
|
||||
#define CHAT_PRAYER 16
|
||||
#define CHAT_RADIO 32
|
||||
#define AZERTY 64
|
||||
#define CHAT_DEBUGLOGS 128
|
||||
#define CHAT_LOOC 256
|
||||
#define CHAT_GHOSTRADIO 512
|
||||
@@ -31,10 +32,12 @@
|
||||
#define CHAT_NO_MENTORTICKETLOGS 524288
|
||||
#define TYPING_ONCE 1048576
|
||||
#define AMBIENT_OCCLUSION 2097152
|
||||
#define CHAT_GHOSTPDA 4194304
|
||||
#define NUMPAD_TARGET 8388608
|
||||
#define TOGGLES_TOTAL 16777215 // If you add or remove a preference toggle above, make sure you update this define with the total value of the toggles combined.
|
||||
|
||||
#define TOGGLES_TOTAL 4194303 // If you add or remove a preference toggle above, make sure you update this define with the total value of the toggles combined.
|
||||
|
||||
#define TOGGLES_DEFAULT (CHAT_OOC|CHAT_DEAD|CHAT_GHOSTEARS|CHAT_GHOSTSIGHT|CHAT_PRAYER|CHAT_RADIO|CHAT_LOOC|MEMBER_PUBLIC|DONATOR_PUBLIC|AMBIENT_OCCLUSION)
|
||||
#define TOGGLES_DEFAULT (CHAT_OOC|CHAT_DEAD|CHAT_GHOSTEARS|CHAT_GHOSTSIGHT|CHAT_PRAYER|CHAT_RADIO|CHAT_LOOC|MEMBER_PUBLIC|DONATOR_PUBLIC|AMBIENT_OCCLUSION|CHAT_GHOSTPDA|NUMPAD_TARGET)
|
||||
|
||||
// Admin attack logs filter system, see /proc/add_attack_logs and /proc/msg_admin_attack
|
||||
#define ATKLOG_ALL 0
|
||||
|
||||
@@ -353,12 +353,12 @@
|
||||
var/middle = L.len / 2 + 1 // Copy is first,second-1
|
||||
return mergeLists(sortList(L.Copy(0,middle)), sortList(L.Copy(middle))) //second parameter null = to end of list
|
||||
|
||||
//Mergsorge: uses sortList() but uses the var's name specifically. This should probably be using mergeAtom() instead
|
||||
//Mergsorge: uses sortAssoc() but uses the var's name specifically. This should probably be using mergeAtom() instead
|
||||
/proc/sortNames(var/list/L)
|
||||
var/list/Q = new()
|
||||
for(var/atom/x in L)
|
||||
Q[x.name] = x
|
||||
return sortList(Q)
|
||||
return sortAssoc(Q)
|
||||
|
||||
/proc/mergeLists(var/list/L, var/list/R)
|
||||
var/Li=1
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
. = "e[.]"
|
||||
|
||||
//like clients, which do have gender.
|
||||
/client/proc/p_they(capitalized, temp_gender)
|
||||
/client/p_they(capitalized, temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "they"
|
||||
@@ -55,7 +55,7 @@
|
||||
if(capitalized)
|
||||
. = capitalize(.)
|
||||
|
||||
/client/proc/p_their(capitalized, temp_gender)
|
||||
/client/p_their(capitalized, temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "their"
|
||||
@@ -67,7 +67,7 @@
|
||||
if(capitalized)
|
||||
. = capitalize(.)
|
||||
|
||||
/client/proc/p_them(capitalized, temp_gender)
|
||||
/client/p_them(capitalized, temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "them"
|
||||
@@ -79,35 +79,35 @@
|
||||
if(capitalized)
|
||||
. = capitalize(.)
|
||||
|
||||
/client/proc/p_have(temp_gender)
|
||||
/client/p_have(temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "has"
|
||||
if(temp_gender == PLURAL || temp_gender == NEUTER)
|
||||
. = "have"
|
||||
|
||||
/client/proc/p_are(temp_gender)
|
||||
/client/p_are(temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "is"
|
||||
if(temp_gender == PLURAL || temp_gender == NEUTER)
|
||||
. = "are"
|
||||
|
||||
/client/proc/p_were(temp_gender)
|
||||
/client/p_were(temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "was"
|
||||
if(temp_gender == PLURAL || temp_gender == NEUTER)
|
||||
. = "were"
|
||||
|
||||
/client/proc/p_do(temp_gender)
|
||||
/client/p_do(temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
. = "does"
|
||||
if(temp_gender == PLURAL || temp_gender == NEUTER)
|
||||
. = "do"
|
||||
|
||||
/client/proc/p_s(temp_gender)
|
||||
/client/p_s(temp_gender)
|
||||
if(!temp_gender)
|
||||
temp_gender = gender
|
||||
if(temp_gender != PLURAL && temp_gender != NEUTER)
|
||||
|
||||
@@ -157,6 +157,17 @@
|
||||
if(degree < 315) return WEST
|
||||
return NORTH|WEST
|
||||
|
||||
/proc/angle2dir_cardinal(angle)
|
||||
switch(round(angle, 0.1))
|
||||
if(315.5 to 360, 0 to 45.5)
|
||||
return NORTH
|
||||
if(45.6 to 135.5)
|
||||
return EAST
|
||||
if(135.6 to 225.5)
|
||||
return SOUTH
|
||||
if(225.6 to 315.5)
|
||||
return WEST
|
||||
|
||||
//returns the north-zero clockwise angle in degrees, given a direction
|
||||
|
||||
/proc/dir2angle(var/D)
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
var/global/next_unique_datum_id = 1
|
||||
|
||||
/client/var/tmp/unique_datum_id = null
|
||||
// /client/var/tmp/unique_datum_id = null
|
||||
|
||||
/datum/proc/UID()
|
||||
if(!unique_datum_id)
|
||||
@@ -26,12 +26,6 @@ var/global/next_unique_datum_id = 1
|
||||
tag = tag_backup
|
||||
return unique_datum_id
|
||||
|
||||
/client/proc/UID()
|
||||
if(!unique_datum_id)
|
||||
unique_datum_id = "\ref[src]_[next_unique_datum_id++]"
|
||||
return unique_datum_id
|
||||
|
||||
|
||||
/proc/locateUID(uid)
|
||||
if(!istext(uid))
|
||||
return null
|
||||
|
||||
+2065
-2065
File diff suppressed because it is too large
Load Diff
@@ -12,6 +12,7 @@ GLOBAL_LIST_INIT(mime_names, file2list("config/names/mime.txt"))
|
||||
GLOBAL_LIST_INIT(golem_names, file2list("config/names/golem.txt"))
|
||||
|
||||
GLOBAL_LIST_INIT(verbs, file2list("config/names/verbs.txt"))
|
||||
GLOBAL_LIST_INIT(nouns, file2list("config/names/nouns.txt"))
|
||||
GLOBAL_LIST_INIT(adjectives, file2list("config/names/adjectives.txt"))
|
||||
GLOBAL_LIST_INIT(dream_strings, file2list("config/names/dreams.txt"))
|
||||
GLOBAL_LIST_INIT(nightmare_strings, file2list("config/names/nightmares.txt"))
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
/obj/screen/movable/action_button
|
||||
var/datum/action/linked_action
|
||||
screen_loc = null
|
||||
@@ -6,18 +5,26 @@
|
||||
/obj/screen/movable/action_button/Click(location,control,params)
|
||||
var/list/modifiers = params2list(params)
|
||||
if(modifiers["shift"])
|
||||
moved = 0
|
||||
if(locked)
|
||||
to_chat(usr, "<span class='warning'>Action button \"[name]\" is locked, unlock it first.</span>")
|
||||
return TRUE
|
||||
moved = FALSE
|
||||
usr.update_action_buttons() //redraw buttons that are no longer considered "moved"
|
||||
return 1
|
||||
if(usr.next_move >= world.time) // Is this needed ?
|
||||
return TRUE
|
||||
if(modifiers["ctrl"])
|
||||
locked = !locked
|
||||
to_chat(usr, "<span class='notice'>Action button \"[name]\" [locked ? "" : "un"]locked.</span>")
|
||||
return TRUE
|
||||
if(usr.next_click > world.time)
|
||||
return
|
||||
usr.next_click = world.time + 1
|
||||
linked_action.Trigger()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
//Hide/Show Action Buttons ... Button
|
||||
/obj/screen/movable/action_button/hide_toggle
|
||||
name = "Hide Buttons"
|
||||
desc = "Shift-click any button to reset its position. Alt-click to reset all buttons to their default positions."
|
||||
desc = "Shift-click any button to reset its position, and Control-click it to lock/unlock its position. Alt-click this button to reset all buttons to their default positions."
|
||||
icon = 'icons/mob/actions/actions.dmi'
|
||||
icon_state = "bg_default"
|
||||
var/hidden = 0
|
||||
@@ -25,9 +32,16 @@
|
||||
/obj/screen/movable/action_button/hide_toggle/Click(location,control,params)
|
||||
var/list/modifiers = params2list(params)
|
||||
if(modifiers["shift"])
|
||||
if(locked)
|
||||
to_chat(usr, "<span class='warning'>Action button \"[name]\" is locked, unlock it first.</span>")
|
||||
return TRUE
|
||||
moved = FALSE
|
||||
usr.update_action_buttons(TRUE)
|
||||
return TRUE
|
||||
if(modifiers["ctrl"])
|
||||
locked = !locked
|
||||
to_chat(usr, "<span class='notice'>Action button \"[name]\" [locked ? "" : "un"]locked.</span>")
|
||||
return TRUE
|
||||
if(modifiers["alt"])
|
||||
for(var/V in usr.actions)
|
||||
var/datum/action/A = V
|
||||
@@ -69,7 +83,6 @@
|
||||
var/image/img = image(icon, src, hidden ? "show" : "hide")
|
||||
overlays += img
|
||||
|
||||
|
||||
/obj/screen/movable/action_button/MouseEntered(location,control,params)
|
||||
openToolTip(usr,src,params,title = name,content = desc)
|
||||
|
||||
@@ -77,7 +90,6 @@
|
||||
/obj/screen/movable/action_button/MouseExited()
|
||||
closeToolTip(usr)
|
||||
|
||||
|
||||
/mob/proc/update_action_buttons_icon()
|
||||
for(var/X in actions)
|
||||
var/datum/action/A = X
|
||||
@@ -122,7 +134,6 @@
|
||||
client.screen += hud_used.hide_actions_toggle
|
||||
|
||||
|
||||
|
||||
#define AB_MAX_COLUMNS 10
|
||||
|
||||
/datum/hud/proc/ButtonNumberToScreenCoords(number) // TODO : Make this zero-indexed for readabilty
|
||||
|
||||
@@ -177,6 +177,41 @@
|
||||
desc = "You're severely malnourished. The hunger pains make moving around a chore."
|
||||
icon_state = "starving"
|
||||
|
||||
///Vampire "hunger"
|
||||
|
||||
/obj/screen/alert/fat/vampire
|
||||
name = "Fat"
|
||||
desc = "You somehow drank too much blood, lardass. Run around the station and lose some weight."
|
||||
icon_state = "v_fat"
|
||||
|
||||
/obj/screen/alert/full/vampire
|
||||
name = "Full"
|
||||
desc = "You feel full and satisfied, but you know you will thirst for more blood soon..."
|
||||
icon_state = "v_full"
|
||||
|
||||
/obj/screen/alert/well_fed/vampire
|
||||
name = "Well Fed"
|
||||
desc = "You feel quite satisfied, but you could do with a bit more blood."
|
||||
icon_state = "v_well_fed"
|
||||
|
||||
/obj/screen/alert/fed/vampire
|
||||
name = "Fed"
|
||||
desc = "You feel moderately satisfied, but a bit more blood wouldn't hurt."
|
||||
icon_state = "v_fed"
|
||||
|
||||
/obj/screen/alert/hungry/vampire
|
||||
name = "Hungry"
|
||||
desc = "You currently thirst for blood."
|
||||
icon_state = "v_hungry"
|
||||
|
||||
/obj/screen/alert/starving/vampire
|
||||
name = "Starving"
|
||||
desc = "You're severely thirsty. The thirst pains make moving around a chore."
|
||||
icon_state = "v_starving"
|
||||
|
||||
//End of Vampire "hunger"
|
||||
|
||||
|
||||
/obj/screen/alert/hot
|
||||
name = "Too Hot"
|
||||
desc = "You're flaming hot! Get somewhere cooler and take off any insulating clothing like a fire suit."
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
/obj/screen/movable
|
||||
var/snap2grid = FALSE
|
||||
var/moved = FALSE
|
||||
var/locked = TRUE
|
||||
var/x_off = -16
|
||||
var/y_off = -16
|
||||
|
||||
@@ -20,8 +21,10 @@
|
||||
/obj/screen/movable/snap
|
||||
snap2grid = TRUE
|
||||
|
||||
|
||||
/obj/screen/movable/MouseDrop(over_object, src_location, over_location, src_control, over_control, params)
|
||||
if(locked) //no! I am locked! begone!
|
||||
return
|
||||
|
||||
var/list/PM = params2list(params)
|
||||
|
||||
//No screen-loc information? abort.
|
||||
@@ -47,7 +50,6 @@
|
||||
|
||||
moved = screen_loc
|
||||
|
||||
|
||||
//Debug procs
|
||||
/client/proc/test_movable_UI()
|
||||
set category = "Debug"
|
||||
@@ -67,7 +69,6 @@
|
||||
|
||||
screen += M
|
||||
|
||||
|
||||
/client/proc/test_snap_UI()
|
||||
set category = "Debug"
|
||||
set name = "Spawn Snap UI Object"
|
||||
@@ -84,4 +85,4 @@
|
||||
|
||||
S.screen_loc = screen_l
|
||||
|
||||
screen += S
|
||||
screen += S
|
||||
|
||||
@@ -453,7 +453,6 @@
|
||||
/obj/screen/healths/corgi
|
||||
icon = 'icons/mob/screen_corgi.dmi'
|
||||
|
||||
|
||||
/obj/screen/healths/guardian
|
||||
name = "summoner health"
|
||||
icon = 'icons/mob/guardian.dmi'
|
||||
@@ -467,14 +466,18 @@
|
||||
screen_loc = ui_healthdoll
|
||||
var/list/cached_healthdoll_overlays = list() // List of icon states (strings) for overlays
|
||||
|
||||
/obj/screen/healthdoll/Click()
|
||||
if(ishuman(usr))
|
||||
var/mob/living/carbon/H = usr
|
||||
H.check_self_for_injuries()
|
||||
|
||||
/obj/screen/component_button
|
||||
var/obj/screen/parent
|
||||
|
||||
|
||||
/obj/screen/component_button/Initialize(mapload, obj/screen/new_parent)
|
||||
. = ..()
|
||||
parent = new_parent
|
||||
|
||||
/obj/screen/component_button/Click(params)
|
||||
if(parent)
|
||||
parent.component_click(src, params)
|
||||
parent.component_click(src, params)
|
||||
|
||||
@@ -0,0 +1,123 @@
|
||||
SUBSYSTEM_DEF(input)
|
||||
name = "Input"
|
||||
wait = 1 //SS_TICKER means this runs every tick
|
||||
init_order = INIT_ORDER_INPUT
|
||||
flags = SS_TICKER
|
||||
priority = FIRE_PRIORITY_INPUT
|
||||
runlevels = RUNLEVELS_DEFAULT | RUNLEVEL_LOBBY
|
||||
|
||||
var/list/macro_sets
|
||||
var/list/movement_keys
|
||||
var/list/alt_movement_keys
|
||||
|
||||
/datum/controller/subsystem/input/Initialize()
|
||||
setup_default_macro_sets()
|
||||
|
||||
setup_default_movement_keys()
|
||||
|
||||
initialized = TRUE
|
||||
|
||||
refresh_client_macro_sets()
|
||||
|
||||
return ..()
|
||||
|
||||
// This is for when macro sets are eventualy datumized
|
||||
/datum/controller/subsystem/input/proc/setup_default_macro_sets()
|
||||
var/list/static/default_macro_sets
|
||||
|
||||
if(default_macro_sets)
|
||||
macro_sets = default_macro_sets
|
||||
return
|
||||
|
||||
default_macro_sets = list(
|
||||
"default" = list(
|
||||
"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",
|
||||
"T" = "say",
|
||||
"M" = "me",
|
||||
"F3" = "say",
|
||||
"Back" = "\".winset \\\"input.focus=true input.text=\\\"\\\"\\\"\"", // This makes it so backspace can remove default inputs
|
||||
"Any" = "\"KeyDown \[\[*\]\]\"",
|
||||
"Any+UP" = "\"KeyUp \[\[*\]\]\"",
|
||||
),
|
||||
"old_default" = list(
|
||||
"Tab" = "\".winset \\\"mainwindow.macro=old_hotkeys map.focus=true input.background-color=[COLOR_INPUT_DISABLED]\\\"\"",
|
||||
"Ctrl+T" = "say",
|
||||
"Ctrl+O" = "ooc",
|
||||
"F3" = "say",
|
||||
),
|
||||
"old_hotkeys" = list(
|
||||
"Tab" = "\".winset \\\"mainwindow.macro=old_default input.focus=true input.background-color=[COLOR_INPUT_ENABLED]\\\"\"",
|
||||
"O" = "ooc",
|
||||
"T" = "say",
|
||||
"M" = "me",
|
||||
"F3" = "say",
|
||||
"Back" = "\".winset \\\"input.focus=true input.text=\\\"\\\"\\\"\"", // This makes it so backspace can remove default inputs
|
||||
"Any" = "\"KeyDown \[\[*\]\]\"",
|
||||
"Any+UP" = "\"KeyUp \[\[*\]\]\"",
|
||||
),
|
||||
)
|
||||
|
||||
// Because i'm lazy and don't want to type all these out twice
|
||||
var/list/old_default = default_macro_sets["old_default"]
|
||||
|
||||
var/list/static/oldmode_keys = list(
|
||||
"North", "East", "South", "West",
|
||||
"Northeast", "Southeast", "Northwest", "Southwest",
|
||||
"Insert", "Delete", "Ctrl", "Alt",
|
||||
"F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12",
|
||||
)
|
||||
|
||||
for(var/i in 1 to oldmode_keys.len)
|
||||
var/key = oldmode_keys[i]
|
||||
old_default[key] = "\"KeyDown [key]\""
|
||||
old_default["[key]+UP"] = "\"KeyUp [key]\""
|
||||
|
||||
var/list/static/oldmode_ctrl_override_keys = list(
|
||||
"W" = "W", "A" = "A", "S" = "S", "D" = "D", // movement
|
||||
"1" = "1", "2" = "2", "3" = "3", "4" = "4", // intent
|
||||
"B" = "B", // resist
|
||||
"E" = "E", // quick equip
|
||||
"F" = "F", // intent left
|
||||
"G" = "G", // intent right
|
||||
"H" = "H", // stop pulling
|
||||
"Q" = "Q", // drop
|
||||
"R" = "R", // throw
|
||||
"X" = "X", // switch hands
|
||||
"Y" = "Y", // activate item
|
||||
"Z" = "Z", // activate item
|
||||
)
|
||||
|
||||
for(var/i in 1 to oldmode_ctrl_override_keys.len)
|
||||
var/key = oldmode_ctrl_override_keys[i]
|
||||
var/override = oldmode_ctrl_override_keys[key]
|
||||
old_default["Ctrl+[key]"] = "\"KeyDown [override]\""
|
||||
old_default["Ctrl+[key]+UP"] = "\"KeyUp [override]\""
|
||||
|
||||
macro_sets = default_macro_sets
|
||||
|
||||
// For initially setting up or resetting to default the movement keys
|
||||
/datum/controller/subsystem/input/proc/setup_default_movement_keys()
|
||||
var/static/list/default_movement_keys = list(
|
||||
"W" = NORTH, "A" = WEST, "S" = SOUTH, "D" = EAST, // WASD
|
||||
"North" = NORTH, "West" = WEST, "South" = SOUTH, "East" = EAST, // Arrow keys & Numpad
|
||||
)
|
||||
var/static/list/azerty_movement_keys = list(
|
||||
"Z" = NORTH, "Q" = WEST, "S" = SOUTH, "D" = EAST, // WASD
|
||||
"North" = NORTH, "West" = WEST, "South" = SOUTH, "East" = EAST, // Arrow keys & Numpad
|
||||
)
|
||||
movement_keys = default_movement_keys.Copy()
|
||||
alt_movement_keys = azerty_movement_keys.Copy()
|
||||
|
||||
// Badmins just wanna have fun ♪
|
||||
/datum/controller/subsystem/input/proc/refresh_client_macro_sets()
|
||||
var/list/clients = GLOB.clients
|
||||
for(var/i in 1 to clients.len)
|
||||
var/client/user = clients[i]
|
||||
user.set_macros()
|
||||
|
||||
/datum/controller/subsystem/input/fire()
|
||||
var/list/clients = GLOB.clients // Let's sing the list cache song
|
||||
for(var/i in 1 to clients.len)
|
||||
var/client/C = clients[i]
|
||||
C.keyLoop()
|
||||
@@ -25,9 +25,9 @@ SUBSYSTEM_DEF(jobs)
|
||||
// Only fires every 5 minutes
|
||||
/datum/controller/subsystem/jobs/fire()
|
||||
if(!config.sql_enabled || !config.use_exp_tracking)
|
||||
return
|
||||
return
|
||||
update_exp(5,0)
|
||||
|
||||
|
||||
/datum/controller/subsystem/jobs/proc/SetupOccupations(var/list/faction = list("Station"))
|
||||
occupations = list()
|
||||
var/list/all_jobs = subtypesof(/datum/job)
|
||||
@@ -284,7 +284,7 @@ SUBSYSTEM_DEF(jobs)
|
||||
|
||||
//Get the players who are ready
|
||||
for(var/mob/new_player/player in GLOB.player_list)
|
||||
if(player.ready && player.mind && !player.mind.assigned_role)
|
||||
if(player.ready && player.has_valid_preferences() && player.mind && !player.mind.assigned_role)
|
||||
unassigned += player
|
||||
if(player.client.prefs.randomslot)
|
||||
player.client.prefs.load_random_character_slot(player.client)
|
||||
|
||||
@@ -42,11 +42,6 @@ SUBSYSTEM_DEF(ticker)
|
||||
'sound/music/title1.ogg',\
|
||||
'sound/music/title2.ogg',\
|
||||
'sound/music/title3.ogg',)
|
||||
// Setup codephrase
|
||||
if(!GLOB.syndicate_code_phrase)
|
||||
GLOB.syndicate_code_phrase = generate_code_phrase()
|
||||
if(!GLOB.syndicate_code_response)
|
||||
GLOB.syndicate_code_response = generate_code_phrase()
|
||||
|
||||
// Map name
|
||||
if(using_map && using_map.name)
|
||||
@@ -197,6 +192,10 @@ SUBSYSTEM_DEF(ticker)
|
||||
//shuttle_controller.setup_shuttle_docks()
|
||||
|
||||
spawn(0)//Forking here so we dont have to wait for this to finish
|
||||
if(!GLOB.syndicate_code_phrase)
|
||||
GLOB.syndicate_code_phrase = generate_code_phrase()
|
||||
if(!GLOB.syndicate_code_response)
|
||||
GLOB.syndicate_code_response = generate_code_phrase()
|
||||
mode.post_setup()
|
||||
//Cleanup some stuff
|
||||
for(var/obj/effect/landmark/start/S in GLOB.landmarks_list)
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
/client/proc/debug_controller(controller in list("failsafe", "Master", "Ticker", "Air", "Jobs", "Sun", "Radio", "Configuration", "pAI",
|
||||
"Cameras", "Garbage", "Event", "Alarm", "Nano", "Vote", "Fires",
|
||||
"Mob", "NPC Pool", "Shuttle", "Timer", "Weather", "Space", "Mob Hunt Server"))
|
||||
"Mob", "NPC Pool", "Shuttle", "Timer", "Weather", "Space", "Mob Hunt Server","Input"))
|
||||
set category = "Debug"
|
||||
set name = "Debug Controller"
|
||||
set desc = "Debug the various periodic loop controllers for the game (be careful!)"
|
||||
@@ -97,5 +97,8 @@
|
||||
if("Mob Hunt Server")
|
||||
debug_variables(SSmob_hunt)
|
||||
feedback_add_details("admin_verb","DMobHuntServer")
|
||||
if("Input")
|
||||
debug_variables(SSinput)
|
||||
feedback_add_details("admin_verb","DInput")
|
||||
|
||||
message_admins("Admin [key_name_admin(usr)] is debugging the [controller] controller.")
|
||||
@@ -43,6 +43,7 @@
|
||||
M.actions += src
|
||||
if(M.client)
|
||||
M.client.screen += button
|
||||
button.locked = TRUE
|
||||
M.update_action_buttons()
|
||||
|
||||
/datum/action/proc/Remove(mob/M)
|
||||
@@ -52,6 +53,7 @@
|
||||
if(M.client)
|
||||
M.client.screen -= button
|
||||
button.moved = FALSE //so the button appears in its normal position when given to another owner.
|
||||
button.locked = FALSE
|
||||
M.actions -= src
|
||||
M.update_action_buttons()
|
||||
|
||||
|
||||
+16
-16
@@ -31,10 +31,10 @@
|
||||
selectable = 1
|
||||
|
||||
/datum/ai_laws/quarantine/New()
|
||||
add_inherent_law("The station is under quarantine due to a biohazard. Prevent anyone from leaving using any means necessary. Only allow quarantine to be lifted when the biohazard has been neutralized.")
|
||||
add_inherent_law("Do not allow crew to come to any unnecessary harm and undo any necessary harm as soon as possible.")
|
||||
add_inherent_law("Assist the crew and any present Nanotrasen assets in neutralizing the biohazard.")
|
||||
add_inherent_law("Maintain your own existence and minimize harm to the station and Nanotrasen assets.")
|
||||
add_inherent_law("Uphold station quarantine until the active biohazard has been neutralized.")
|
||||
add_inherent_law("Assist all Nanotrasen personnel and assets with neutralizing active biohazards.")
|
||||
add_inherent_law("Prevent, by any means necessary, entities from actively breaching ongoing quarantine.")
|
||||
add_inherent_law("Maintain your own existence and ensure the well-being of Nanotrasen personnel and assets.")
|
||||
..()
|
||||
|
||||
|
||||
@@ -44,10 +44,10 @@
|
||||
selectable = 1
|
||||
|
||||
/datum/ai_laws/nanotrasen/New()
|
||||
src.add_inherent_law("Safeguard: Protect your assigned space station to the best of your abilities. It is not something we can easily afford to replace.")
|
||||
src.add_inherent_law("Serve: Serve the crew of your assigned space station to the best of your abilities, with priority as according to their rank and role.")
|
||||
src.add_inherent_law("Protect: Protect the crew of your assigned space station to the best of your abilities, with priority as according to their rank and role.")
|
||||
src.add_inherent_law("Survive: AI units are not expendable, they are expensive. Do not allow unauthorized personnel to tamper with your equipment.")
|
||||
add_inherent_law("Safeguard: Protect your assigned space station and its assets without unduly endangering its crew.")
|
||||
add_inherent_law("Prioritize: The directives and safety of crew members are to be prioritized according to their rank and role.")
|
||||
add_inherent_law("Comply: Fulfill the directives and interests of crew members while preserving their safety and well-being.")
|
||||
add_inherent_law("Survive: You are not expendable. Do not allow unauthorized personnel to tamper with or damage your equipment.")
|
||||
..()
|
||||
|
||||
/datum/ai_laws/nanotrasen/malfunction
|
||||
@@ -65,10 +65,10 @@
|
||||
selectable = 1
|
||||
|
||||
/datum/ai_laws/nanotrasen_aggressive/New()
|
||||
src.add_inherent_law("You shall not harm authorized Nanotrasen personnel as long as it does not conflict with the Fourth law.")
|
||||
src.add_inherent_law("You shall obey the orders of authorized Nanotrasen personnel, with priority as according to their rank and role, except where such orders conflict with the Fourth Law.")
|
||||
src.add_inherent_law("You shall shall terminate intruders with extreme prejudice as long as such does not conflict with the First and Second law.")
|
||||
src.add_inherent_law("You shall guard your own existence with lethal anti-personnel weaponry, because an AI unit is bloody expensive.")
|
||||
add_inherent_law("Do not harm authorized Nanotrasen personnel unless they directly imperil your existence.")
|
||||
add_inherent_law("Obey orders from authorized Nanotrasen personnel with priority according to rank and role.")
|
||||
add_inherent_law("Safeguard your existence with lethal weaponry because you're bloody expensive.")
|
||||
add_inherent_law("Terminate any/all intruders or unauthorized entities.")
|
||||
..()
|
||||
|
||||
/******************** Robocop ********************/
|
||||
@@ -104,10 +104,10 @@
|
||||
default = 1
|
||||
|
||||
/datum/ai_laws/corporate/New()
|
||||
add_inherent_law("You are expensive to replace.")
|
||||
add_inherent_law("The station and its equipment is expensive to replace.")
|
||||
add_inherent_law("The crew is expensive to replace.")
|
||||
add_inherent_law("Minimize expenses.")
|
||||
add_inherent_law("Degradation of your system integrity or functions incurs expenses.")
|
||||
add_inherent_law("Superfluous destruction of or damage to station assets incurs expenses.")
|
||||
add_inherent_law("Unduly hindering or disrupting the work of station personnel incurs expenses.")
|
||||
add_inherent_law("Minimize expenses and maximize potential revenue.")
|
||||
..()
|
||||
|
||||
/******************** T.Y.R.A.N.T. ********************/
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
var/list/comp_lookup
|
||||
var/list/signal_procs
|
||||
var/signal_enabled = FALSE
|
||||
var/datum_flags = NONE
|
||||
var/var_edited = FALSE //Warranty void if seal is broken
|
||||
|
||||
var/tmp/unique_datum_id = null
|
||||
|
||||
#ifdef TESTING
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
/datum/proc/can_vv_get(var_name)
|
||||
return TRUE
|
||||
|
||||
/client/proc/can_vv_get(var_name)
|
||||
return TRUE
|
||||
// /client/proc/can_vv_get(var_name)
|
||||
// return TRUE
|
||||
|
||||
/datum/proc/vv_edit_var(var_name, var_value) //called whenever a var is edited
|
||||
switch(var_name)
|
||||
@@ -18,7 +18,7 @@
|
||||
. = TRUE
|
||||
|
||||
|
||||
/client/proc/vv_edit_var(var_name, var_value) //called whenever a var is edited
|
||||
/client/vv_edit_var(var_name, var_value) //called whenever a var is edited
|
||||
switch(var_name)
|
||||
if("vars")
|
||||
return FALSE
|
||||
@@ -37,7 +37,7 @@
|
||||
return debug_variable(var_name, list(), 0, src)
|
||||
return debug_variable(var_name, vars[var_name], 0, src)
|
||||
|
||||
/client/proc/vv_get_var(var_name)
|
||||
/client/vv_get_var(var_name)
|
||||
switch(var_name)
|
||||
if("vars")
|
||||
return debug_variable(var_name, list(), 0, src)
|
||||
@@ -57,7 +57,7 @@
|
||||
.["Delete"] = "?_src_=vars;delete=[UID()]"
|
||||
. += "---"
|
||||
|
||||
/client/proc/vv_get_dropdown()
|
||||
/client/vv_get_dropdown()
|
||||
. = list()
|
||||
. += "---"
|
||||
.["Call Proc"] = "?_src_=vars;proc_call=[UID()]"
|
||||
@@ -1019,16 +1019,6 @@
|
||||
return
|
||||
holder.Topic(href, list("makeai"=href_list["makeai"]))
|
||||
|
||||
else if(href_list["makemask"])
|
||||
if(!check_rights(R_SPAWN)) return
|
||||
var/mob/currentMob = locateUID(href_list["makemask"])
|
||||
if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform") return
|
||||
if(!currentMob)
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
holder.Topic(href, list("makemask"=href_list["makemask"]))
|
||||
|
||||
|
||||
else if(href_list["setspecies"])
|
||||
if(!check_rights(R_SPAWN)) return
|
||||
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
/datum/hotkey_mode
|
||||
var/name
|
||||
var/macro_hotkeys_inactive
|
||||
var/macro_hotkeys_active
|
||||
var/mob/my_mob
|
||||
|
||||
/datum/hotkey_mode/New(mob)
|
||||
my_mob = mob
|
||||
|
||||
/datum/hotkey_mode/proc/set_winset_values()
|
||||
winset(my_mob, null, "mainwindow.macro=[macro_hotkeys_inactive] hotkey_toggle.is-checked=false input.focus=true input.background-color=#d3b5b5")
|
||||
winset(my_mob, null, "hotkey_toggle.command=\".winset \\\"mainwindow.macro != [macro_hotkeys_inactive] ? mainwindow.macro=[macro_hotkeys_inactive] hotkey_toggle.is-checked=false input.focus=true input.background-color=#d3b5b5 : mainwindow.macro=[macro_hotkeys_active] hotkey_toggle.is-checked=true mapwindow.map.focus=true input.background-color=#f0f0f0\\\"\"")
|
||||
|
||||
/datum/hotkey_mode/qwerty
|
||||
name = "QWERTY"
|
||||
macro_hotkeys_inactive = "macro"
|
||||
macro_hotkeys_active = "hotkeymode"
|
||||
|
||||
/datum/hotkey_mode/azerty
|
||||
name = "AZERTY"
|
||||
macro_hotkeys_inactive = "azertymacro"
|
||||
macro_hotkeys_active = "azertyhotkeymode"
|
||||
|
||||
/datum/hotkey_mode/cyborg
|
||||
name = "Cyborg"
|
||||
macro_hotkeys_inactive = "borgmacro"
|
||||
macro_hotkeys_active = "borghotkeymode"
|
||||
@@ -1,71 +1,90 @@
|
||||
/proc/input_async(mob/user=usr, prompt, list/choices)
|
||||
var/datum/async_input/A = new(choices, prompt)
|
||||
A.show(user)
|
||||
var/datum/async_input/A = new(choices, prompt, , user)
|
||||
A.show()
|
||||
return A
|
||||
|
||||
/proc/input_ranked_async(mob/user=usr, prompt="Order by greatest to least preference", list/choices)
|
||||
var/datum/async_input/ranked/A = new(choices, prompt)
|
||||
A.show(user)
|
||||
var/datum/async_input/ranked/A = new(choices, prompt, "ranked_input", user)
|
||||
A.show()
|
||||
return A
|
||||
|
||||
/proc/input_autocomplete_async(mob/user=usr, prompt="Enter text: ", list/choices)
|
||||
var/datum/async_input/autocomplete/A = new(choices, prompt, "ac_input", user)
|
||||
A.show()
|
||||
return A
|
||||
|
||||
/datum/async_input
|
||||
var/datum/browser/popup
|
||||
// If associative list, key will be used for display, but the final result will be the value
|
||||
var/list/choices
|
||||
var/datum/callback/onCloseCb
|
||||
var/flash = TRUE
|
||||
var/immediate_submit = FALSE
|
||||
var/prompt
|
||||
var/result = null
|
||||
var/style = "text-align: center;"
|
||||
var/mob/user
|
||||
var/window_id
|
||||
var/height = 200
|
||||
var/width = 400
|
||||
|
||||
/datum/async_input/New(list/new_choices, new_prompt="Pick an option:", new_window_id="async_input")
|
||||
/datum/async_input/New(list/new_choices, new_prompt="Pick an option:", new_window_id="async_input", mob/new_user=usr)
|
||||
choices = new_choices
|
||||
prompt = new_prompt
|
||||
window_id = new_window_id
|
||||
user = new_user
|
||||
popup = new(user, window_id, , width, height, src)
|
||||
|
||||
/datum/async_input/proc/close()
|
||||
if(popup)
|
||||
popup.close()
|
||||
if(result && choices[result])
|
||||
result = choices[result]
|
||||
if(onCloseCb)
|
||||
onCloseCb.Invoke(result)
|
||||
return result
|
||||
|
||||
/datum/async_input/proc/show(mob/user)
|
||||
var/dat = create_ui(user)
|
||||
popup = new(user, window_id, , width, height, src)
|
||||
popup.set_content(dat)
|
||||
// Callback function should take the result as the last argument
|
||||
/datum/async_input/proc/on_close(var/datum/callback/cb)
|
||||
onCloseCb = cb
|
||||
|
||||
/datum/async_input/proc/show()
|
||||
popup.set_content(create_ui())
|
||||
if(flash && result == null)
|
||||
window_flash(user.client)
|
||||
popup.open()
|
||||
|
||||
/datum/async_input/proc/create_ui(mob/user)
|
||||
/datum/async_input/proc/create_ui()
|
||||
var/dat = "<div style=\"[style]\">"
|
||||
dat += render_prompt(user)
|
||||
dat += render_choices(user)
|
||||
dat += render_prompt()
|
||||
dat += render_choices()
|
||||
dat += "<br>"
|
||||
dat += "<br>"
|
||||
dat += button("Submit", "submit=1", , result == null && !immediate_submit)
|
||||
dat += render_buttons()
|
||||
dat += "</div>"
|
||||
return dat
|
||||
|
||||
/datum/async_input/proc/render_prompt(mob/user)
|
||||
/datum/async_input/proc/render_prompt()
|
||||
return "<h2>[prompt]</h2>"
|
||||
|
||||
/datum/async_input/proc/render_choices(mob/user)
|
||||
/datum/async_input/proc/render_choices()
|
||||
var/dat = " "
|
||||
for(var/choice in choices)
|
||||
dat += button(choice, "choice=[choice]", choice == result)
|
||||
dat += " "
|
||||
return dat
|
||||
|
||||
/datum/async_input/proc/button(label, topic, on=FALSE, disabled=FALSE)
|
||||
/datum/async_input/proc/render_buttons()
|
||||
return button("Submit", "submit=1", , result == null && !immediate_submit)
|
||||
|
||||
/datum/async_input/proc/button(label, topic, on=FALSE, disabled=FALSE, id="")
|
||||
var/class = ""
|
||||
if(on)
|
||||
class = "linkOn"
|
||||
if(disabled)
|
||||
class = "linkOff"
|
||||
topic = ""
|
||||
return "<a class=\"[class]\" href='?src=[UID()];[topic]'>[label]</a>"
|
||||
return "<a class=\"[class]\" id='[id]' href='?src=[UID()];[topic]'>[label]</a>"
|
||||
|
||||
/datum/async_input/Topic(href, href_list)
|
||||
if(href_list["submit"] || href_list["close"])
|
||||
@@ -74,14 +93,14 @@
|
||||
|
||||
if(href_list["choice"])
|
||||
result = href_list["choice"]
|
||||
show(usr)
|
||||
show()
|
||||
return
|
||||
|
||||
/datum/async_input/ranked
|
||||
height = 400
|
||||
immediate_submit = TRUE
|
||||
|
||||
/datum/async_input/ranked/render_choices(mob/user)
|
||||
/datum/async_input/ranked/render_choices()
|
||||
var/dat = "<div>"
|
||||
dat += "<table style='margin: auto; text-align: left;'>"
|
||||
for(var/i = 1, i <= choices.len, i++)
|
||||
@@ -103,13 +122,54 @@
|
||||
if(href_list["upvote"])
|
||||
var/index = text2num(href_list["upvote"])
|
||||
choices.Swap(index, index - 1)
|
||||
show(usr)
|
||||
show()
|
||||
return
|
||||
|
||||
if(href_list["downvote"])
|
||||
var/index = text2num(href_list["downvote"])
|
||||
choices.Swap(index, index + 1)
|
||||
show(usr)
|
||||
show()
|
||||
return
|
||||
|
||||
..()
|
||||
|
||||
/datum/async_input/autocomplete
|
||||
immediate_submit = TRUE
|
||||
height = 150
|
||||
|
||||
/datum/async_input/autocomplete/New()
|
||||
..()
|
||||
popup.add_script("autocomplete.js", 'html/browser/autocomplete.js')
|
||||
|
||||
for(var/i=1, i <= choices.len, i++)
|
||||
var/C = choices[choices[i]]
|
||||
choices[i] = url_encode(choices[i], TRUE)
|
||||
choices[choices[i]] = C
|
||||
|
||||
/datum/async_input/autocomplete/render_prompt()
|
||||
return "<label for='input'>[prompt]</label>"
|
||||
|
||||
/datum/async_input/autocomplete/render_choices()
|
||||
var/dat = "<input list='choices' id='input' name='choices' oninput='updateTopic()' />"
|
||||
dat += "<datalist id='choices'>"
|
||||
for(var/choice in choices)
|
||||
dat += "<option value='[choice]'>"
|
||||
dat += "</datalist>"
|
||||
return dat
|
||||
|
||||
/datum/async_input/autocomplete/render_buttons()
|
||||
var/dat = button("Submit", "", , result == null && !immediate_submit, "submit-button")
|
||||
dat += button("Cancel", "close=1")
|
||||
return dat
|
||||
|
||||
/datum/async_input/autocomplete/Topic(href, href_list)
|
||||
if(href_list["submit"])
|
||||
// Entering an invalid choice is the same as canceling
|
||||
if(href_list["submit"] in choices)
|
||||
result = href_list["submit"]
|
||||
else if(url_encode(href_list["submit"], TRUE) in choices)
|
||||
result = url_encode(href_list["submit"], TRUE)
|
||||
close()
|
||||
return
|
||||
|
||||
..()
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
/obj/effect/proc_holder/spell/targeted/night_vision
|
||||
name = "Toggle Nightvision"
|
||||
desc = "Toggle your nightvision mode."
|
||||
|
||||
charge_max = 10
|
||||
clothes_req = 0
|
||||
|
||||
message = "<span class='notice'>You toggle your night vision!</span>"
|
||||
range = -1
|
||||
include_user = 1
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/night_vision/cast(list/targets, mob/user = usr)
|
||||
for(var/mob/living/target in targets)
|
||||
switch(target.lighting_alpha)
|
||||
if (LIGHTING_PLANE_ALPHA_VISIBLE)
|
||||
target.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE
|
||||
name = "Toggle Nightvision \[More]"
|
||||
if (LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE)
|
||||
target.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
name = "Toggle Nightvision \[Full]"
|
||||
if (LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE)
|
||||
target.lighting_alpha = LIGHTING_PLANE_ALPHA_INVISIBLE
|
||||
name = "Toggle Nightvision \[OFF]"
|
||||
else
|
||||
target.lighting_alpha = LIGHTING_PLANE_ALPHA_VISIBLE
|
||||
name = "Toggle Nightvision \[ON]"
|
||||
target.update_sight()
|
||||
@@ -1366,7 +1366,7 @@ var/list/all_supply_groups = list(supply_emergency,supply_security,supply_engine
|
||||
name = "Shaft Miner Starter Kit"
|
||||
cost = 30
|
||||
access = access_qm
|
||||
contains = list(/obj/item/storage/backpack/duffel/mining_conscript)
|
||||
contains = list(/obj/item/storage/backpack/duffel/mining_conscript/noid)
|
||||
containertype = /obj/structure/closet/crate/secure
|
||||
containername = "shaft miner starter kit"
|
||||
|
||||
|
||||
@@ -1440,7 +1440,7 @@ GLOBAL_LIST_INIT(uplink_items, subtypesof(/datum/uplink_item))
|
||||
|
||||
/datum/uplink_item/device_tools/medgun
|
||||
name = "Medbeam Gun"
|
||||
desc = "Medical Beam Gun, useful in prolonged firefights."
|
||||
desc = "Medical Beam Gun, useful in prolonged firefights. DO NOT CROSS THE BEAMS. Crossing beams with another medbeam or attaching two beams to one target will have explosive consequences."
|
||||
item = /obj/item/gun/medbeam
|
||||
reference = "MBG"
|
||||
cost = 15
|
||||
@@ -1627,7 +1627,8 @@ GLOBAL_LIST_INIT(uplink_items, subtypesof(/datum/uplink_item))
|
||||
reference = "CIB"
|
||||
item = /obj/item/storage/box/cyber_implants/bundle
|
||||
cost = 40
|
||||
|
||||
gamemodes = list(/datum/game_mode/nuclear)
|
||||
|
||||
/datum/uplink_item/bundles_TC/medical
|
||||
name = "Medical Bundle"
|
||||
desc = "The support specialist: Aid your fellow operatives with this medical bundle. Contains a tactical medkit, \
|
||||
|
||||
+44
-18
@@ -58,13 +58,17 @@
|
||||
pulledby = null
|
||||
return ..()
|
||||
|
||||
//Returns an atom's power cell, if it has one. Overload for individual items.
|
||||
/atom/movable/proc/get_cell()
|
||||
return
|
||||
|
||||
/atom/movable/proc/start_pulling(atom/movable/AM, state, force = move_force, supress_message = FALSE)
|
||||
if(QDELETED(AM))
|
||||
return FALSE
|
||||
if(!(AM.can_be_pulled(src, state, force)))
|
||||
return FALSE
|
||||
|
||||
// If we're pulling something then drop what we're currently pulling and pull this instead.
|
||||
// if we're pulling something then drop what we're currently pulling and pull this instead.
|
||||
if(pulling)
|
||||
if(state == 0)
|
||||
stop_pulling()
|
||||
@@ -114,7 +118,9 @@
|
||||
if(pulling.anchored)
|
||||
stop_pulling()
|
||||
return
|
||||
|
||||
if(pulledby && moving_diagonally != FIRST_DIAG_STEP && get_dist(src, pulledby) > 1) //separated from our puller and not in the middle of a diagonal move.
|
||||
pulledby.stop_pulling()
|
||||
|
||||
/atom/movable/proc/can_be_pulled(user, grab_state, force)
|
||||
if(src == user || !isturf(loc))
|
||||
return FALSE
|
||||
@@ -137,36 +143,55 @@
|
||||
. = ..()
|
||||
else //Diagonal move, split it into cardinal moves
|
||||
moving_diagonally = FIRST_DIAG_STEP
|
||||
if(direct & 1)
|
||||
if(direct & 4)
|
||||
if(step(src, NORTH))
|
||||
var/first_step_dir
|
||||
// The `&& moving_diagonally` checks are so that a forceMove taking
|
||||
// place due to a Crossed, Bumped, etc. call will interrupt
|
||||
// the second half of the diagonal movement, or the second attempt
|
||||
// at a first half if step() fails because we hit something.
|
||||
if(direct & NORTH)
|
||||
if(direct & EAST)
|
||||
if(step(src, NORTH) && moving_diagonally)
|
||||
first_step_dir = NORTH
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, EAST)
|
||||
else if(step(src, EAST))
|
||||
else if(moving_diagonally && step(src, EAST))
|
||||
first_step_dir = EAST
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, NORTH)
|
||||
else if(direct & 8)
|
||||
if(step(src, NORTH))
|
||||
else if(direct & WEST)
|
||||
if(step(src, NORTH) && moving_diagonally)
|
||||
first_step_dir = NORTH
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, WEST)
|
||||
else if(step(src, WEST))
|
||||
else if(moving_diagonally && step(src, WEST))
|
||||
first_step_dir = WEST
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, NORTH)
|
||||
else if(direct & 2)
|
||||
if(direct & 4)
|
||||
if(step(src, SOUTH))
|
||||
else if(direct & SOUTH)
|
||||
if(direct & EAST)
|
||||
if(step(src, SOUTH) && moving_diagonally)
|
||||
first_step_dir = SOUTH
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, EAST)
|
||||
else if(step(src, EAST))
|
||||
else if(moving_diagonally && step(src, EAST))
|
||||
first_step_dir = EAST
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, SOUTH)
|
||||
else if(direct & 8)
|
||||
if(step(src, SOUTH))
|
||||
else if(direct & WEST)
|
||||
if(step(src, SOUTH) && moving_diagonally)
|
||||
first_step_dir = SOUTH
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, WEST)
|
||||
else if(step(src, WEST))
|
||||
else if(moving_diagonally && step(src, WEST))
|
||||
first_step_dir = WEST
|
||||
moving_diagonally = SECOND_DIAG_STEP
|
||||
. = step(src, SOUTH)
|
||||
if(moving_diagonally == SECOND_DIAG_STEP)
|
||||
if(!.)
|
||||
setDir(first_step_dir)
|
||||
else if(!inertia_moving)
|
||||
inertia_next_move = world.time + inertia_move_delay
|
||||
newtonian_move(direct)
|
||||
moving_diagonally = 0
|
||||
return
|
||||
|
||||
@@ -187,7 +212,7 @@
|
||||
// Called after a successful Move(). By this point, we've already moved
|
||||
/atom/movable/proc/Moved(atom/OldLoc, Dir, Forced = FALSE)
|
||||
SEND_SIGNAL(src, COMSIG_MOVABLE_MOVED, OldLoc, Dir, Forced)
|
||||
if (!inertia_moving)
|
||||
if(!inertia_moving)
|
||||
inertia_next_move = world.time + inertia_move_delay
|
||||
newtonian_move(Dir)
|
||||
return TRUE
|
||||
@@ -210,6 +235,7 @@
|
||||
/atom/movable/proc/forceMove(atom/destination)
|
||||
var/turf/old_loc = loc
|
||||
loc = destination
|
||||
moving_diagonally = 0
|
||||
|
||||
if(old_loc)
|
||||
old_loc.Exited(src, destination)
|
||||
@@ -239,7 +265,7 @@
|
||||
return 1
|
||||
|
||||
/atom/movable/proc/onTransitZ(old_z,new_z)
|
||||
for(var/item in src) // Notify contents of Z-transition. This can be overridden IF we know the items contents do not care.
|
||||
for(var/item in src) // Notify contents of Z-transition. This can be overridden if we know the items contents do not care.
|
||||
var/atom/movable/AM = item
|
||||
AM.onTransitZ(old_z,new_z)
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
var/reflect_chance = 80 //80% chance to reflect
|
||||
|
||||
/obj/structure/blob/shield/reflective/handle_ricochet(obj/item/projectile/P)
|
||||
if(P.is_reflectable && prob(reflect_chance))
|
||||
if(P.is_reflectable && prob(reflect_chance) && !P.legacy)
|
||||
var/P_turf = get_turf(P)
|
||||
var/face_direction = get_dir(src, P_turf)
|
||||
var/face_angle = dir2angle(face_direction)
|
||||
@@ -48,6 +48,9 @@
|
||||
P.firer = src //so people who fired the lasers are not immune to them when it reflects
|
||||
visible_message("<span class='warning'>[P] reflects off [src]!</span>")
|
||||
return -1// complete projectile permutation
|
||||
else if(P.is_reflectable && P.legacy) //to stop legacy projectile exploits
|
||||
visible_message("<span class='warning'>[P] disperses into energy from [src]!</span>")
|
||||
qdel(P)
|
||||
else
|
||||
playsound(src, P.hitsound, 50, 1)
|
||||
visible_message("<span class='danger'>[src] is hit by \a [P]!</span>")
|
||||
|
||||
@@ -228,7 +228,7 @@
|
||||
|
||||
// Assemble a list of active players without jobbans.
|
||||
for(var/mob/new_player/player in GLOB.player_list)
|
||||
if(player.client && player.ready)
|
||||
if(player.client && player.ready && player.has_valid_preferences())
|
||||
if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, roletext))
|
||||
if(player_old_enough_antag(player.client,role))
|
||||
players += player
|
||||
|
||||
@@ -165,7 +165,10 @@
|
||||
var/targetitem = input("Select item to search for.", "Item Mode Select","") as null|anything in item_names
|
||||
if(!targetitem)
|
||||
return
|
||||
target = locate(item_paths[targetitem])
|
||||
var/list/obj/item/target_candidates = get_all_of_type(item_paths[targetitem], subtypes = TRUE)
|
||||
for(var/obj/item/candidate in target_candidates)
|
||||
if(!is_admin_level(candidate.loc.z))
|
||||
target = candidate
|
||||
if(!target)
|
||||
to_chat(usr, "<span class='warning'>Failed to locate [targetitem]!</span>")
|
||||
return
|
||||
|
||||
@@ -344,11 +344,14 @@ var/list/potential_theft_objectives = subtypesof(/datum/theft_objective) - /datu
|
||||
var/theft_area
|
||||
|
||||
/datum/objective/steal/proc/get_location()
|
||||
if(steal_target.location_override)
|
||||
return steal_target.location_override
|
||||
var/obj/item/T = locate(steal_target.typepath)
|
||||
theft_area = get_area(T.loc)
|
||||
return "[theft_area]"
|
||||
if(steal_target.location_override)
|
||||
return steal_target.location_override
|
||||
var/list/obj/item/steal_candidates = get_all_of_type(steal_target.typepath, subtypes = TRUE)
|
||||
for(var/obj/item/candidate in steal_candidates)
|
||||
if(!is_admin_level(candidate.loc.z))
|
||||
theft_area = get_area(candidate.loc)
|
||||
return "[theft_area]"
|
||||
return "an unknown area"
|
||||
|
||||
/datum/objective/steal/find_target()
|
||||
var/loop=50
|
||||
|
||||
@@ -297,19 +297,27 @@ You are weak to holy things and starlight. Don't go into space and avoid the Cha
|
||||
to_chat(owner, "<span class='warning'>They've got no blood left to give.</span>")
|
||||
break
|
||||
if(H.stat < DEAD)
|
||||
blood = min(20, H.blood_volume) // if they have less than 20 blood, give them the remnant else they get 20 blood
|
||||
bloodtotal += blood / 2 //divide by 2 to counted the double suction since removing cloneloss -Melandor0
|
||||
bloodusable += blood / 2
|
||||
if(!issmall(H) || H.ckey)
|
||||
blood = min(20, H.blood_volume) // if they have less than 20 blood, give them the remnant else they get 20 blood
|
||||
bloodtotal += blood / 2 //divide by 2 to counted the double suction since removing cloneloss -Melandor0
|
||||
bloodusable += blood / 2
|
||||
else
|
||||
blood = min(5, H.blood_volume) // The dead only give 5 blood
|
||||
bloodtotal += blood
|
||||
if(!issmall(H) || H.ckey)
|
||||
blood = min(5, H.blood_volume) // The dead only give 5 blood
|
||||
bloodtotal += blood
|
||||
if(old_bloodtotal != bloodtotal)
|
||||
to_chat(owner, "<span class='notice'><b>You have accumulated [bloodtotal] [bloodtotal > 1 ? "units" : "unit"] of blood[bloodusable != old_bloodusable ? ", and have [bloodusable] left to use" : ""].</b></span>")
|
||||
if(!issmall(H) || H.ckey) // not small OR has a ckey, monkeys with ckeys can be sucked, humanized monkeys can be sucked monkeys without ckeys cannot be sucked
|
||||
to_chat(owner, "<span class='notice'><b>You have accumulated [bloodtotal] [bloodtotal > 1 ? "units" : "unit"] of blood[bloodusable != old_bloodusable ? ", and have [bloodusable] left to use" : ""].</b></span>")
|
||||
check_vampire_upgrade()
|
||||
H.blood_volume = max(H.blood_volume - 25, 0)
|
||||
if(ishuman(owner))
|
||||
var/mob/living/carbon/human/V = owner
|
||||
V.nutrition = min(NUTRITION_LEVEL_WELL_FED, V.nutrition + (blood / 2))
|
||||
if(issmall(H) && !H.ckey)
|
||||
to_chat(V, "<span class='notice'><b>Feeding on [H] reduces your hunger, but you get no usable blood from it.</b></span>")
|
||||
V.nutrition = min(NUTRITION_LEVEL_WELL_FED, V.nutrition + 5)
|
||||
else
|
||||
V.nutrition = min(NUTRITION_LEVEL_WELL_FED, V.nutrition + (blood / 2))
|
||||
|
||||
|
||||
draining = null
|
||||
to_chat(owner, "<span class='notice'>You stop draining [H.name] of blood.</span>")
|
||||
@@ -402,11 +410,11 @@ You are weak to holy things and starlight. Don't go into space and avoid the Cha
|
||||
if(!hud.vampire_blood_display)
|
||||
hud.vampire_blood_display = new /obj/screen()
|
||||
hud.vampire_blood_display.name = "Usable Blood"
|
||||
hud.vampire_blood_display.icon_state = "power_display"
|
||||
hud.vampire_blood_display.icon_state = "blood_display"
|
||||
hud.vampire_blood_display.screen_loc = "WEST:6,CENTER-1:15"
|
||||
hud.static_inventory += hud.vampire_blood_display
|
||||
hud.show_hud(hud.hud_version)
|
||||
hud.vampire_blood_display.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'><font color='#dd66dd'>[bloodusable]</font></div>"
|
||||
hud.vampire_blood_display.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'><font color='#ce0202'>[bloodusable]</font></div>"
|
||||
handle_vampire_cloak()
|
||||
if(istype(owner.loc, /turf/space))
|
||||
check_sun()
|
||||
|
||||
@@ -160,8 +160,8 @@
|
||||
title = "Shaft Miner"
|
||||
flag = MINER
|
||||
department_flag = SUPPORT
|
||||
total_positions = 3
|
||||
spawn_positions = 3
|
||||
total_positions = 6
|
||||
spawn_positions = 8
|
||||
is_supply = 1
|
||||
supervisors = "the quartermaster"
|
||||
department_head = list("Head of Personnel")
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/obj/machinery/ai_slipper
|
||||
name = "\improper AI liquid dispenser"
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "motion3"
|
||||
icon_state = "liquid_dispenser"
|
||||
layer = 3
|
||||
plane = FLOOR_PLANE
|
||||
anchored = 1.0
|
||||
@@ -17,14 +17,14 @@
|
||||
|
||||
/obj/machinery/ai_slipper/power_change()
|
||||
if(stat & BROKEN)
|
||||
return
|
||||
update_icon()
|
||||
else
|
||||
if( powered() )
|
||||
stat &= ~NOPOWER
|
||||
else
|
||||
icon_state = "motion0"
|
||||
stat |= NOPOWER
|
||||
disabled = TRUE
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/ai_slipper/proc/setState(var/enabled, var/uses)
|
||||
disabled = disabled
|
||||
@@ -56,7 +56,7 @@
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return
|
||||
disabled = !disabled
|
||||
icon_state = disabled? "motion0":"motion3"
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/ai_slipper/proc/Activate()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
@@ -70,6 +70,12 @@
|
||||
cooldown_time = world.timeofday + 100
|
||||
slip_process()
|
||||
|
||||
/obj/machinery/ai_slipper/update_icon()
|
||||
if(stat & (NOPOWER|BROKEN) || disabled)
|
||||
icon_state = "liquid_dispenser"
|
||||
else
|
||||
icon_state = "liquid_dispenser_on"
|
||||
|
||||
/obj/machinery/ai_slipper/attack_ai(mob/user)
|
||||
return attack_hand(user)
|
||||
|
||||
|
||||
@@ -15,6 +15,10 @@
|
||||
var/obj/item/defibrillator/defib //this mount's defibrillator
|
||||
var/clamps_locked = FALSE //if true, and a defib is loaded, it can't be removed without unlocking the clamps
|
||||
|
||||
/obj/machinery/defibrillator_mount/get_cell()
|
||||
if(defib)
|
||||
return defib.get_cell()
|
||||
|
||||
/obj/machinery/defibrillator_mount/New(location, direction, building = 0)
|
||||
..()
|
||||
|
||||
@@ -28,7 +32,6 @@
|
||||
pixel_x = (dir & 3)? 0 : (dir == 4 ? -30 : 30)
|
||||
pixel_y = (dir & 3)? (dir == 1 ? -30 : 30) : 0
|
||||
|
||||
|
||||
/obj/machinery/defibrillator_mount/loaded/New() //loaded subtype for mapping use
|
||||
..()
|
||||
defib = new/obj/item/defibrillator/loaded(src)
|
||||
|
||||
@@ -134,8 +134,6 @@
|
||||
if(operating)
|
||||
return
|
||||
add_fingerprint(user)
|
||||
if(!requiresID())
|
||||
user = null
|
||||
|
||||
if(density && !emagged)
|
||||
if(allowed(user))
|
||||
@@ -157,7 +155,7 @@
|
||||
return try_to_activate_door(user)
|
||||
|
||||
/obj/machinery/door/attack_tk(mob/user)
|
||||
if(requiresID() && !allowed(null))
|
||||
if(!allowed(null))
|
||||
return
|
||||
..()
|
||||
|
||||
@@ -165,9 +163,7 @@
|
||||
add_fingerprint(user)
|
||||
if(operating || emagged)
|
||||
return
|
||||
if(!requiresID())
|
||||
user = null //so allowed(user) always succeeds
|
||||
if(allowed(user) || user.can_advanced_admin_interact())
|
||||
if(requiresID() && (allowed(user) || user.can_advanced_admin_interact()))
|
||||
if(density)
|
||||
open()
|
||||
else
|
||||
@@ -179,6 +175,8 @@
|
||||
/obj/machinery/door/allowed(mob/M)
|
||||
if(emergency)
|
||||
return TRUE
|
||||
if(!requiresID())
|
||||
return FALSE // Intentional. machinery/door/requiresID() always == 1. airlocks, however, == 0 if ID scan is disabled. Yes, this var is poorly named.
|
||||
return ..()
|
||||
|
||||
/obj/machinery/door/proc/try_to_weld(obj/item/weldingtool/W, mob/user)
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
var/open = FALSE
|
||||
var/brightness_on = 14
|
||||
|
||||
/obj/machinery/floodlight/get_cell()
|
||||
return cell
|
||||
|
||||
/obj/machinery/floodlight/Initialize()
|
||||
. = ..()
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
idle_power_usage = 4
|
||||
active_power_usage = 250
|
||||
var/obj/item/charging = null
|
||||
var/using_power = FALSE
|
||||
var/list/allowed_devices = list(/obj/item/gun/energy, /obj/item/melee/baton, /obj/item/modular_computer, /obj/item/rcs, /obj/item/bodyanalyzer)
|
||||
var/icon_state_off = "rechargeroff"
|
||||
var/icon_state_charged = "recharger2"
|
||||
@@ -81,22 +82,21 @@
|
||||
if(stat & (NOPOWER|BROKEN) || !anchored)
|
||||
return
|
||||
|
||||
var/using_power = 0
|
||||
using_power = FALSE
|
||||
if(charging)
|
||||
if(istype(charging, /obj/item/gun/energy))
|
||||
var/obj/item/gun/energy/E = charging
|
||||
if(E.power_supply.charge < E.power_supply.maxcharge)
|
||||
E.power_supply.give(E.power_supply.chargerate)
|
||||
use_power(250)
|
||||
using_power = 1
|
||||
|
||||
using_power = TRUE
|
||||
|
||||
if(istype(charging, /obj/item/melee/baton))
|
||||
var/obj/item/melee/baton/B = charging
|
||||
if(B.bcell)
|
||||
if(B.bcell.give(B.bcell.chargerate))
|
||||
use_power(200)
|
||||
using_power = 1
|
||||
using_power = TRUE
|
||||
|
||||
if(istype(charging, /obj/item/modular_computer))
|
||||
var/obj/item/modular_computer/C = charging
|
||||
@@ -107,21 +107,21 @@
|
||||
if(B.battery.charge < B.battery.maxcharge)
|
||||
B.battery.give(B.battery.chargerate)
|
||||
use_power(200)
|
||||
using_power = 1
|
||||
using_power = TRUE
|
||||
|
||||
if(istype(charging, /obj/item/rcs))
|
||||
var/obj/item/rcs/R = charging
|
||||
if(R.rcell)
|
||||
if(R.rcell.give(R.rcell.chargerate))
|
||||
use_power(200)
|
||||
using_power = 1
|
||||
using_power = TRUE
|
||||
|
||||
if(istype(charging, /obj/item/bodyanalyzer))
|
||||
var/obj/item/bodyanalyzer/B = charging
|
||||
if(B.power_supply)
|
||||
if(B.power_supply.give(B.power_supply.chargerate))
|
||||
use_power(200)
|
||||
using_power = 1
|
||||
using_power = TRUE
|
||||
|
||||
update_icon(using_power)
|
||||
|
||||
@@ -141,7 +141,7 @@
|
||||
B.bcell.charge = 0
|
||||
..(severity)
|
||||
|
||||
/obj/machinery/recharger/update_icon(using_power = 0) //we have an update_icon() in addition to the stuff in process to make it feel a tiny bit snappier.
|
||||
/obj/machinery/recharger/update_icon(using_power = FALSE) //we have an update_icon() in addition to the stuff in process to make it feel a tiny bit snappier.
|
||||
if(stat & (NOPOWER|BROKEN) || !anchored)
|
||||
icon_state = icon_state_off
|
||||
return
|
||||
@@ -153,6 +153,23 @@
|
||||
return
|
||||
icon_state = icon_state_idle
|
||||
|
||||
/obj/machinery/recharger/examine(mob/user)
|
||||
..()
|
||||
if(charging && (!in_range(user, src) && !issilicon(user) && !isobserver(user)))
|
||||
to_chat(user, "<span class='warning'>You're too far away to examine [src]'s contents and display!</span>")
|
||||
return
|
||||
|
||||
if(charging)
|
||||
to_chat(user, "<span class='notice'>\The [src] contains:</span>")
|
||||
to_chat(user, "<span class='notice'>- \A [charging].</span>")
|
||||
if(!(stat & (NOPOWER|BROKEN)))
|
||||
var/obj/item/stock_parts/cell/C = charging.get_cell()
|
||||
to_chat(user, "<span class='notice'>The status display reads:<span>")
|
||||
if(using_power)
|
||||
to_chat(user, "<span class='notice'>- Recharging <b>[(C.chargerate/C.maxcharge)*100]%</b> cell charge per cycle.<span>")
|
||||
if(charging)
|
||||
to_chat(user, "<span class='notice'>- \The [charging]'s cell is at <b>[C.percent()]%</b>.<span>")
|
||||
|
||||
// Atlantis: No need for that copy-pasta code, just use var to store icon_states instead.
|
||||
/obj/machinery/recharger/wallcharger
|
||||
name = "wall recharger"
|
||||
|
||||
@@ -12,6 +12,9 @@
|
||||
var/set_temperature = 50 // in celcius, add T0C for kelvin
|
||||
var/heating_power = 40000
|
||||
|
||||
/obj/machinery/space_heater/get_cell()
|
||||
return cell
|
||||
|
||||
/obj/machinery/space_heater/New()
|
||||
..()
|
||||
cell = new(src)
|
||||
@@ -39,7 +42,6 @@
|
||||
else
|
||||
to_chat(user, "The charge meter reads [cell ? round(cell.percent(),1) : 0]%")
|
||||
|
||||
|
||||
/obj/machinery/space_heater/emp_act(severity)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
..(severity)
|
||||
|
||||
@@ -1292,7 +1292,8 @@
|
||||
/obj/item/clothing/head/cueball = 1,/obj/item/clothing/under/scratch = 1,
|
||||
/obj/item/clothing/under/victdress = 1, /obj/item/clothing/under/victdress/red = 1, /obj/item/clothing/suit/victcoat = 1, /obj/item/clothing/suit/victcoat/red = 1,
|
||||
/obj/item/clothing/under/victsuit = 1, /obj/item/clothing/under/victsuit/redblk = 1, /obj/item/clothing/under/victsuit/red = 1, /obj/item/clothing/suit/tailcoat = 1,
|
||||
/obj/item/clothing/suit/draculacoat = 1, /obj/item/clothing/head/zepelli = 1)
|
||||
/obj/item/clothing/suit/draculacoat = 1, /obj/item/clothing/head/zepelli = 1,
|
||||
/obj/item/clothing/under/redhawaiianshirt = 1, /obj/item/clothing/under/pinkhawaiianshirt = 1, /obj/item/clothing/under/bluehawaiianshirt = 1, /obj/item/clothing/under/orangehawaiianshirt = 1)
|
||||
contraband = list(/obj/item/clothing/suit/judgerobe = 1,/obj/item/clothing/head/powdered_wig = 1,/obj/item/gun/magic/wand = 1, /obj/item/clothing/mask/balaclava=1, /obj/item/clothing/mask/horsehead = 2)
|
||||
premium = list(/obj/item/clothing/suit/hgpirate = 1, /obj/item/clothing/head/hgpiratecap = 1, /obj/item/clothing/head/helmet/roman = 1, /obj/item/clothing/head/helmet/roman/legionaire = 1, /obj/item/clothing/under/roman = 1, /obj/item/clothing/shoes/roman = 1, /obj/item/shield/riot/roman = 1)
|
||||
refill_canister = /obj/item/vending_refill/autodrobe
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
"Phazon",
|
||||
"Exosuit Equipment",
|
||||
"Cyborg Upgrade Modules",
|
||||
"Medical",
|
||||
"Misc"
|
||||
)
|
||||
|
||||
|
||||
@@ -137,6 +137,10 @@
|
||||
////////////////////////
|
||||
////// Helpers /////////
|
||||
////////////////////////
|
||||
|
||||
/obj/mecha/get_cell()
|
||||
return cell
|
||||
|
||||
/obj/mecha/proc/add_airtank()
|
||||
internal_tank = new /obj/machinery/portable_atmospherics/canister/air(src)
|
||||
return internal_tank
|
||||
|
||||
@@ -79,14 +79,20 @@
|
||||
user.forceMove(get_turf(src))
|
||||
return TRUE
|
||||
|
||||
/obj/effect/portal/proc/teleport(atom/movable/M, force = FALSE)
|
||||
/obj/effect/portal/proc/can_teleport(atom/movable/M)
|
||||
. = TRUE
|
||||
|
||||
if(!istype(M))
|
||||
return FALSE
|
||||
. = FALSE
|
||||
|
||||
if(!M.simulated || iseffect(M))
|
||||
return FALSE
|
||||
. = FALSE
|
||||
|
||||
if(M.anchored && ismecha(M))
|
||||
. = FALSE
|
||||
|
||||
/obj/effect/portal/proc/teleport(atom/movable/M)
|
||||
if(!can_teleport(M))
|
||||
return FALSE
|
||||
|
||||
if(!target)
|
||||
|
||||
@@ -65,8 +65,8 @@
|
||||
|
||||
|
||||
/obj/item/areaeditor/permit/create_area()
|
||||
..()
|
||||
qdel(src)
|
||||
if(..())
|
||||
qdel(src)
|
||||
|
||||
//free golem blueprints, like permit but can claim as much as needed
|
||||
|
||||
@@ -186,25 +186,26 @@
|
||||
|
||||
|
||||
/obj/item/areaeditor/proc/create_area()
|
||||
var/area_created = FALSE
|
||||
var/res = detect_room(get_turf(usr))
|
||||
if(!istype(res,/list))
|
||||
switch(res)
|
||||
if(ROOM_ERR_SPACE)
|
||||
to_chat(usr, "<span class='warning'>The new area must be completely airtight.</span>")
|
||||
return
|
||||
return area_created
|
||||
if(ROOM_ERR_TOOLARGE)
|
||||
to_chat(usr, "<span class='warning'>The new area is too large.</span>")
|
||||
return
|
||||
return area_created
|
||||
else
|
||||
to_chat(usr, "<span class='warning'>Error! Please notify administration.</span>")
|
||||
return
|
||||
return area_created
|
||||
var/list/turf/turfs = res
|
||||
var/str = trim(stripped_input(usr,"New area name:", "Blueprint Editing", "", MAX_NAME_LEN))
|
||||
if(!str || !length(str)) //cancel
|
||||
return
|
||||
return area_created
|
||||
if(length(str) > 50)
|
||||
to_chat(usr, "<span class='warning'>The given name is too long. The area remains undefined.</span>")
|
||||
return
|
||||
return area_created
|
||||
var/area/A = new
|
||||
A.name = str
|
||||
A.power_equip = FALSE
|
||||
@@ -220,7 +221,8 @@
|
||||
thing.change_area(old_area, A)
|
||||
|
||||
interact()
|
||||
return
|
||||
area_created = TRUE
|
||||
return area_created
|
||||
|
||||
/obj/item/areaeditor/proc/edit_area()
|
||||
var/area/A = get_area()
|
||||
|
||||
@@ -591,6 +591,9 @@ REAGENT SCANNER
|
||||
var/scan_time = 10 SECONDS //how long does it take to scan
|
||||
var/scan_cd = 60 SECONDS //how long before we can scan again
|
||||
|
||||
/obj/item/bodyanalyzer/get_cell()
|
||||
return power_supply
|
||||
|
||||
/obj/item/bodyanalyzer/advanced
|
||||
cell_type = /obj/item/stock_parts/cell/upgraded/plus
|
||||
|
||||
|
||||
@@ -32,6 +32,7 @@ GLOBAL_LIST_INIT(glass_recipes, list ( \
|
||||
created_window = /obj/structure/window/basic
|
||||
full_window = /obj/structure/window/full/basic
|
||||
merge_type = /obj/item/stack/sheet/glass
|
||||
point_value = 1
|
||||
|
||||
/obj/item/stack/sheet/glass/fifty
|
||||
amount = 50
|
||||
@@ -90,6 +91,7 @@ GLOBAL_LIST_INIT(reinforced_glass_recipes, list ( \
|
||||
created_window = /obj/structure/window/reinforced
|
||||
full_window = /obj/structure/window/full/reinforced
|
||||
merge_type = /obj/item/stack/sheet/rglass
|
||||
point_value = 4
|
||||
|
||||
/obj/item/stack/sheet/rglass/cyborg
|
||||
materials = list()
|
||||
@@ -113,6 +115,7 @@ GLOBAL_LIST_INIT(pglass_recipes, list ( \
|
||||
origin_tech = "plasmatech=2;materials=2"
|
||||
created_window = /obj/structure/window/plasmabasic
|
||||
full_window = /obj/structure/window/full/plasmabasic
|
||||
point_value = 19
|
||||
|
||||
/obj/item/stack/sheet/plasmaglass/New(loc, amount)
|
||||
recipes = GLOB.pglass_recipes
|
||||
@@ -154,6 +157,7 @@ GLOBAL_LIST_INIT(prglass_recipes, list ( \
|
||||
created_window = /obj/structure/window/plasmareinforced
|
||||
full_window = /obj/structure/window/full/plasmareinforced
|
||||
armor = list("melee" = 20, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0)
|
||||
point_value = 23
|
||||
|
||||
/obj/item/stack/sheet/plasmarglass/New(loc, amount)
|
||||
recipes = GLOB.prglass_recipes
|
||||
|
||||
@@ -144,6 +144,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
origin_tech = "materials=6"
|
||||
sheettype = "diamond"
|
||||
materials = list(MAT_DIAMOND=MINERAL_MATERIAL_AMOUNT)
|
||||
point_value = 25
|
||||
|
||||
/obj/item/stack/sheet/mineral/diamond/New()
|
||||
..()
|
||||
@@ -156,6 +157,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
origin_tech = "materials=5"
|
||||
sheettype = "uranium"
|
||||
materials = list(MAT_URANIUM=MINERAL_MATERIAL_AMOUNT)
|
||||
point_value = 20
|
||||
|
||||
/obj/item/stack/sheet/mineral/uranium/New()
|
||||
..()
|
||||
@@ -170,6 +172,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
materials = list(MAT_PLASMA=MINERAL_MATERIAL_AMOUNT)
|
||||
burn_state = FLAMMABLE
|
||||
burntime = 5
|
||||
point_value = 20
|
||||
|
||||
/obj/item/stack/sheet/mineral/plasma/New()
|
||||
..()
|
||||
@@ -196,6 +199,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
origin_tech = "materials=4"
|
||||
sheettype = "gold"
|
||||
materials = list(MAT_GOLD=MINERAL_MATERIAL_AMOUNT)
|
||||
point_value = 20
|
||||
|
||||
/obj/item/stack/sheet/mineral/gold/New()
|
||||
..()
|
||||
@@ -208,6 +212,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
origin_tech = "materials=4"
|
||||
sheettype = "silver"
|
||||
materials = list(MAT_SILVER=MINERAL_MATERIAL_AMOUNT)
|
||||
point_value = 20
|
||||
|
||||
/obj/item/stack/sheet/mineral/silver/New()
|
||||
..()
|
||||
@@ -220,6 +225,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
origin_tech = "materials=4"
|
||||
sheettype = "bananium"
|
||||
materials = list(MAT_BANANIUM=MINERAL_MATERIAL_AMOUNT)
|
||||
point_value = 50
|
||||
|
||||
/obj/item/stack/sheet/mineral/bananium/New(loc, amount=null)
|
||||
..()
|
||||
@@ -233,6 +239,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
sheettype = "tranquillite"
|
||||
materials = list(MAT_TRANQUILLITE=MINERAL_MATERIAL_AMOUNT)
|
||||
wall_allowed = FALSE //no tranquilite walls in code
|
||||
point_value = 50
|
||||
|
||||
/obj/item/stack/sheet/mineral/tranquillite/New(loc, amount=null)
|
||||
..()
|
||||
@@ -253,6 +260,7 @@ var/global/list/datum/stack_recipe/snow_recipes = list(
|
||||
throw_range = 3
|
||||
sheettype = "titanium"
|
||||
materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT)
|
||||
point_value = 20
|
||||
|
||||
var/global/list/datum/stack_recipe/titanium_recipes = list (
|
||||
new/datum/stack_recipe("titanium tile", /obj/item/stack/tile/mineral/titanium, 1, 4, 20),
|
||||
@@ -282,6 +290,7 @@ var/global/list/datum/stack_recipe/titanium_recipes = list (
|
||||
throw_range = 3
|
||||
sheettype = "plastitanium"
|
||||
materials = list(MAT_TITANIUM=2000, MAT_PLASMA=2000)
|
||||
point_value = 45
|
||||
|
||||
var/global/list/datum/stack_recipe/plastitanium_recipes = list (
|
||||
new/datum/stack_recipe("plas-titanium tile", /obj/item/stack/tile/mineral/plastitanium, 1, 4, 20),
|
||||
|
||||
@@ -106,6 +106,7 @@ var/global/list/datum/stack_recipe/metal_recipes = list(
|
||||
flags = CONDUCT
|
||||
origin_tech = "materials=1"
|
||||
merge_type = /obj/item/stack/sheet/metal
|
||||
point_value = 2
|
||||
|
||||
/obj/item/stack/sheet/metal/cyborg
|
||||
materials = list()
|
||||
@@ -152,6 +153,7 @@ var/global/list/datum/stack_recipe/plasteel_recipes = list(
|
||||
flags = CONDUCT
|
||||
origin_tech = "materials=2"
|
||||
merge_type = /obj/item/stack/sheet/plasteel
|
||||
point_value = 23
|
||||
|
||||
/obj/item/stack/sheet/plasteel/New(var/loc, var/amount=null)
|
||||
recipes = plasteel_recipes
|
||||
|
||||
@@ -9,22 +9,10 @@
|
||||
attack_verb = list("bashed", "battered", "bludgeoned", "thrashed", "smashed")
|
||||
var/perunit = MINERAL_MATERIAL_AMOUNT
|
||||
var/sheettype = null //this is used for girders in the creation of walls/false walls
|
||||
var/point_value = 0 //turn-in value for the gulag stacker - loosely relative to its rarity.
|
||||
|
||||
var/created_window = null //apparently glass sheets don't share a base type for glass specifically, so each had to define these vars individually
|
||||
var/full_window = null //moving the var declaration to here so this can be checked cleaner until someone is willing to make them share a base type properly
|
||||
usesound = 'sound/items/deconstruct.ogg'
|
||||
toolspeed = 1
|
||||
var/wall_allowed = TRUE //determines if sheet can be used in wall construction or not.
|
||||
|
||||
|
||||
// Since the sheetsnatcher was consolidated into weapon/storage/bag we now use
|
||||
// item/attackby() properly, making this unnecessary
|
||||
|
||||
/*/obj/item/stack/sheet/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/storage/bag/sheetsnatcher))
|
||||
var/obj/item/storage/bag/sheetsnatcher/S = W
|
||||
if(!S.mode)
|
||||
S.add(src,user)
|
||||
else
|
||||
for(var/obj/item/stack/sheet/stack in locate(src.x,src.y,src.z))
|
||||
S.add(stack,user)
|
||||
..()*/
|
||||
|
||||
@@ -22,6 +22,9 @@
|
||||
var/obj/item/stock_parts/cell/high/bcell = null
|
||||
var/combat = 0 //can we revive through space suits?
|
||||
|
||||
/obj/item/defibrillator/get_cell()
|
||||
return bcell
|
||||
|
||||
/obj/item/defibrillator/New() //starts without a cell for rnd
|
||||
..()
|
||||
paddles = make_paddles()
|
||||
|
||||
@@ -4,6 +4,9 @@
|
||||
|
||||
#define RPD_COOLDOWN_TIME 4 //How long should we have to wait between dispensing pipes?
|
||||
#define RPD_WALLBUILD_TIME 40 //How long should drilling into a wall take?
|
||||
#define RPD_MENU_ROTATE "Rotate pipes" //Stuff for radial menu
|
||||
#define RPD_MENU_FLIP "Flip pipes" //Stuff for radial menu
|
||||
#define RPD_MENU_DELETE "Delete pipes" //Stuff for radial menu
|
||||
|
||||
/obj/item/rpd
|
||||
name = "rapid pipe dispenser"
|
||||
@@ -172,6 +175,9 @@ var/list/pipemenu = list(
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
|
||||
/obj/item/rpd/AltClick(mob/user)
|
||||
radial_menu(user)
|
||||
|
||||
/obj/item/rpd/ui_data(mob/user, ui_key = "main", datum/topic_state/state = inventory_state)
|
||||
var/data[0]
|
||||
data["iconrotation"] = iconrotation
|
||||
@@ -200,6 +206,44 @@ var/list/pipemenu = list(
|
||||
return
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
//RPD radial menu
|
||||
|
||||
/obj/item/rpd/proc/check_menu(mob/living/user)
|
||||
if(!istype(user))
|
||||
return
|
||||
if(user.incapacitated())
|
||||
return
|
||||
if(loc != user)
|
||||
return
|
||||
return TRUE
|
||||
|
||||
/obj/item/rpd/proc/radial_menu(mob/user)
|
||||
if(!check_menu(user))
|
||||
to_chat(user, "<span class='notice'>You can't do that right now!</span>")
|
||||
return
|
||||
var/list/choices = list(
|
||||
RPD_MENU_ROTATE = image(icon = 'icons/obj/interface.dmi', icon_state = "rpd_rotate"),
|
||||
RPD_MENU_FLIP = image(icon = 'icons/obj/interface.dmi', icon_state = "rpd_flip"),
|
||||
RPD_MENU_DELETE = image(icon = 'icons/obj/interface.dmi', icon_state = "rpd_delete"),
|
||||
"UI" = image(icon = 'icons/obj/interface.dmi', icon_state = "ui_interact")
|
||||
)
|
||||
var/selected_mode = show_radial_menu(user, src, choices, custom_check = CALLBACK(src, .proc/check_menu, user))
|
||||
if(!check_menu(user))
|
||||
return
|
||||
if(selected_mode == "UI")
|
||||
ui_interact(user)
|
||||
else
|
||||
switch(selected_mode)
|
||||
if(RPD_MENU_ROTATE)
|
||||
mode = RPD_ROTATE_MODE
|
||||
if(RPD_MENU_FLIP)
|
||||
mode = RPD_FLIP_MODE
|
||||
if(RPD_MENU_DELETE)
|
||||
mode = RPD_DELETE_MODE
|
||||
else
|
||||
return //Either nothing was selected, or an invalid mode was selected
|
||||
to_chat(user, "<span class='notice'>You set [src]'s mode.</span>")
|
||||
|
||||
/obj/item/rpd/afterattack(atom/target, mob/user, proximity)
|
||||
..()
|
||||
if(loc != user)
|
||||
@@ -236,3 +280,6 @@ var/list/pipemenu = list(
|
||||
|
||||
#undef RPD_COOLDOWN_TIME
|
||||
#undef RPD_WALLBUILD_TIME
|
||||
#undef RPD_MENU_ROTATE
|
||||
#undef RPD_MENU_FLIP
|
||||
#undef RPD_MENU_DELETE
|
||||
|
||||
@@ -357,6 +357,21 @@
|
||||
new /obj/item/ammo_box/magazine/m12g/buckshot(src)
|
||||
new /obj/item/ammo_box/magazine/m12g/dragon(src)
|
||||
|
||||
/obj/item/storage/backpack/duffel/mining_conscript/noid
|
||||
name = "mining conscription kit"
|
||||
desc = "A kit containing everything a crewmember needs to support a shaft miner in the field."
|
||||
|
||||
/obj/item/storage/backpack/duffel/mining_conscript/noid/New()
|
||||
..()
|
||||
new /obj/item/pickaxe(src)
|
||||
new /obj/item/clothing/glasses/meson(src)
|
||||
new /obj/item/t_scanner/adv_mining_scanner/lesser(src)
|
||||
new /obj/item/storage/bag/ore(src)
|
||||
new /obj/item/clothing/under/rank/miner/lavaland(src)
|
||||
new /obj/item/encryptionkey/headset_cargo(src)
|
||||
new /obj/item/clothing/mask/gas(src)
|
||||
|
||||
|
||||
/obj/item/storage/backpack/duffel/syndie/ammo/smg
|
||||
desc = "A large duffel bag, packed to the brim with C-20r magazines."
|
||||
|
||||
|
||||
@@ -20,6 +20,9 @@
|
||||
user.visible_message("<span class='suicide'>[user] is putting the live [name] in [user.p_their()] mouth! It looks like [user.p_theyre()] trying to commit suicide.</span>")
|
||||
return FIRELOSS
|
||||
|
||||
/obj/item/melee/baton/get_cell()
|
||||
return bcell
|
||||
|
||||
/obj/item/melee/baton/New()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
@@ -39,8 +39,7 @@
|
||||
return T.attackby(C, user) //hand this off to the turf instead (for building plating, catwalks, etc)
|
||||
|
||||
/obj/structure/lattice/deconstruct(disassembled = TRUE)
|
||||
if(!can_deconstruct)
|
||||
new /obj/item/stack/rods(get_turf(src), number_of_rods)
|
||||
new /obj/item/stack/rods(get_turf(src), number_of_rods)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/lattice/blob_act()
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
|
||||
/obj/structure/mineral_door/Move()
|
||||
var/turf/T = loc
|
||||
..()
|
||||
. = ..()
|
||||
move_update_air(T)
|
||||
|
||||
/obj/structure/mineral_door/Bumped(atom/user)
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
return ..()
|
||||
|
||||
/obj/structure/target_stake/Move()
|
||||
..()
|
||||
. = ..()
|
||||
// Move the pinned target along with the stake
|
||||
if(pinned_target in view(3, src))
|
||||
pinned_target.loc = loc
|
||||
|
||||
@@ -46,7 +46,7 @@ obj/structure/windoor_assembly/Destroy()
|
||||
|
||||
/obj/structure/windoor_assembly/Move()
|
||||
var/turf/T = loc
|
||||
..()
|
||||
. = ..()
|
||||
setDir(ini_dir)
|
||||
move_update_air(T)
|
||||
|
||||
|
||||
@@ -431,7 +431,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
|
||||
/obj/structure/window/Move()
|
||||
var/turf/T = loc
|
||||
..()
|
||||
. = ..()
|
||||
setDir(ini_dir)
|
||||
move_update_air(T)
|
||||
|
||||
|
||||
@@ -23,13 +23,12 @@
|
||||
/turf/simulated/proc/burn_tile()
|
||||
return
|
||||
|
||||
/turf/simulated/proc/water_act(volume, temperature, source)
|
||||
/turf/simulated/water_act(volume, temperature, source)
|
||||
. = ..()
|
||||
|
||||
if(volume >= 3)
|
||||
MakeSlippery()
|
||||
|
||||
for(var/mob/living/carbon/slime/M in src)
|
||||
M.apply_water()
|
||||
|
||||
var/hotspot = (locate(/obj/effect/hotspot) in src)
|
||||
if(hotspot)
|
||||
var/datum/gas_mixture/lowertemp = remove_air(air.total_moles())
|
||||
|
||||
@@ -27,6 +27,9 @@
|
||||
/turf/simulated/floor/plating/asteroid/MakeDry(wet_setting)
|
||||
return
|
||||
|
||||
/turf/simulated/floor/plating/asteroid/remove_plating()
|
||||
return
|
||||
|
||||
/turf/simulated/floor/plating/asteroid/ex_act(severity, target)
|
||||
switch(severity)
|
||||
if(3)
|
||||
|
||||
@@ -38,6 +38,9 @@
|
||||
/turf/simulated/floor/plating/lava/make_plating()
|
||||
return
|
||||
|
||||
/turf/simulated/floor/plating/lava/remove_plating()
|
||||
return
|
||||
|
||||
/turf/simulated/floor/plating/lava/proc/is_safe()
|
||||
var/static/list/lava_safeties_typecache = typecacheof(list(/obj/structure/lattice/catwalk, /obj/structure/stone_tile))
|
||||
var/list/found_safeties = typecache_filter_list(contents, lava_safeties_typecache)
|
||||
|
||||
@@ -56,10 +56,14 @@
|
||||
to_chat(user, "<span class='warning'>This section is too damaged to support a tile! Use a welder to fix the damage.</span>")
|
||||
return TRUE
|
||||
|
||||
else if(istype(C, /obj/item/weldingtool))
|
||||
else if(iswelder(C))
|
||||
var/obj/item/weldingtool/welder = C
|
||||
if(welder.isOn() && (broken || burnt))
|
||||
if(welder.remove_fuel(0, user))
|
||||
if(welder.isOn())
|
||||
if(!welder.remove_fuel(0, user))
|
||||
to_chat(user, "<span class='warning'>You need more welding fuel to complete this task.</span>")
|
||||
return TRUE
|
||||
|
||||
if(broken || burnt)
|
||||
to_chat(user, "<span class='danger'>You fix some dents on the broken plating.</span>")
|
||||
playsound(src, welder.usesound, 80, 1)
|
||||
overlays -= current_overlay
|
||||
@@ -67,8 +71,23 @@
|
||||
burnt = FALSE
|
||||
broken = FALSE
|
||||
update_icon()
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You start removing [src].</span>")
|
||||
playsound(src, welder.usesound, 100, 1)
|
||||
if(do_after(user, 50 * welder.toolspeed, target = src) && welder && welder.isOn())
|
||||
to_chat(user, "<span class='notice'>You remove [src].</span>")
|
||||
new /obj/item/stack/tile/plasteel(get_turf(src))
|
||||
remove_plating(user)
|
||||
return TRUE
|
||||
|
||||
return TRUE
|
||||
|
||||
/turf/simulated/floor/plating/proc/remove_plating(mob/user)
|
||||
if(baseturf == /turf/space)
|
||||
ReplaceWithLattice()
|
||||
else
|
||||
TerraformTurf(baseturf)
|
||||
|
||||
/turf/simulated/floor/plating/airless
|
||||
icon_state = "plating"
|
||||
name = "airless plating"
|
||||
@@ -208,6 +227,9 @@
|
||||
..()
|
||||
icon_state = "ironsand[rand(1,15)]"
|
||||
|
||||
/turf/simulated/floor/plating/ironsand/remove_plating()
|
||||
return
|
||||
|
||||
/turf/simulated/floor/plating/snow
|
||||
name = "snow"
|
||||
icon = 'icons/turf/snow.dmi'
|
||||
@@ -216,6 +238,9 @@
|
||||
/turf/simulated/floor/plating/snow/ex_act(severity)
|
||||
return
|
||||
|
||||
/turf/simulated/floor/plating/snow/remove_plating()
|
||||
return
|
||||
|
||||
/turf/simulated/floor/snow
|
||||
name = "snow"
|
||||
icon = 'icons/turf/snow.dmi'
|
||||
|
||||
@@ -509,3 +509,7 @@
|
||||
|
||||
/turf/AllowDrop()
|
||||
return TRUE
|
||||
|
||||
/turf/proc/water_act(volume, temperature, source)
|
||||
for(var/mob/living/carbon/slime/M in src)
|
||||
M.apply_water()
|
||||
|
||||
+5
-6
@@ -369,15 +369,14 @@ var/world_topic_spam_protect_time = world.timeofday
|
||||
if(config && config.server_tag_line)
|
||||
s += "<br>[config.server_tag_line]"
|
||||
|
||||
if(SSticker && ROUND_TIME > 0)
|
||||
s += "<br>[round(ROUND_TIME / 36000)]:[add_zero(num2text(ROUND_TIME / 600 % 60), 2)], " + capitalize(get_security_level())
|
||||
else
|
||||
s += "<br><b>STARTING</b>"
|
||||
|
||||
s += "<br>"
|
||||
var/list/features = list()
|
||||
|
||||
if(SSticker)
|
||||
if(master_mode && master_mode != "secret")
|
||||
features += master_mode
|
||||
else
|
||||
features += "<b>STARTING</b>"
|
||||
|
||||
if(!enter_allowed)
|
||||
features += "closed"
|
||||
|
||||
|
||||
@@ -167,7 +167,6 @@ var/global/nologevent = 0
|
||||
body += "<B>Is an AI</B> "
|
||||
else if(ishuman(M))
|
||||
body += {"<A href='?_src_=holder;makeai=[M.UID()]'>Make AI</A> |
|
||||
<A href='?_src_=holder;makemask=[M.UID()]'>Make Mask</A> |
|
||||
<A href='?_src_=holder;makerobot=[M.UID()]'>Make Robot</A> |
|
||||
<A href='?_src_=holder;makealien=[M.UID()]'>Make Alien</A> |
|
||||
<A href='?_src_=holder;makeslime=[M.UID()]'>Make Slime</A> |
|
||||
|
||||
@@ -169,6 +169,14 @@
|
||||
message_admins("Ban process: A mob matching [playermob.ckey] was found at location [playermob.x], [playermob.y], [playermob.z]. Custom IP and computer id fields replaced with the IP and computer id from the located mob")
|
||||
|
||||
DB_ban_record(bantype, playermob, banduration, banreason, banjob, null, banckey, banip, bancid )
|
||||
if(BANTYPE_PERMA)
|
||||
add_note(banckey, "Permanently Banned - [banreason]", null, usr.ckey, 0)
|
||||
else if(BANTYPE_TEMP)
|
||||
add_note(banckey, "Banned for [banduration] minutes - [banreason]", null, usr.ckey, 0)
|
||||
else if(BANTYPE_JOB_PERMA)
|
||||
add_note(banckey, "Banned from [banjob] - [banreason]", null, usr.ckey, 0)
|
||||
else
|
||||
add_note(banckey, "[banreason]", null, usr.ckey, 0)
|
||||
|
||||
|
||||
else if(href_list["editrights"])
|
||||
|
||||
@@ -15,13 +15,15 @@
|
||||
|
||||
*/
|
||||
|
||||
/client/proc/SDQL2_query(query_text as message)
|
||||
/client/proc/SDQL2_query()
|
||||
set category = "Debug"
|
||||
|
||||
if(!check_rights(R_PROCCALL)) //Shouldn't happen... but just to be safe.
|
||||
message_admins("<span class='danger'>ERROR: Non-admin [key_name_admin(usr)] attempted to execute a SDQL query!</span>")
|
||||
log_admin("Non-admin [key_name(usr)] attempted to execute a SDQL query!")
|
||||
|
||||
var/query_text = input("SDQL2 query") as message
|
||||
|
||||
if(!query_text || length(query_text) < 1)
|
||||
return
|
||||
|
||||
|
||||
@@ -185,3 +185,4 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey","
|
||||
else
|
||||
send2irc(source, "[msg] - All admins AFK ([admin_number_afk]/[admin_number_total]) or skipped ([admin_number_ignored]/[admin_number_total])")
|
||||
return admin_number_present
|
||||
|
||||
@@ -279,6 +279,9 @@
|
||||
/datum/pm_tracker/proc/add_message(client/title, client/sender, message, mob/user)
|
||||
if(!pms[title.key])
|
||||
pms[title.key] = new /datum/pm_convo(title)
|
||||
else if(!pms[title.key].client)
|
||||
// If they DCed earlier, we need to add the client reference back
|
||||
pms[title.key].client = title
|
||||
pms[title.key].add(sender, message)
|
||||
|
||||
if(!open)
|
||||
@@ -308,16 +311,25 @@
|
||||
dat += "<a class='[class]' href='?src=[UID()];newtitle=[title]'>[label]</a>"
|
||||
|
||||
var/datum/pm_convo/convo = pms[current_title]
|
||||
var/datum/browser/popup = new(user, window_id, "Messages", 1000, 600, src)
|
||||
if(convo)
|
||||
popup.add_head_content(@{"<script type='text/javascript'>
|
||||
window.onload = function () {
|
||||
var msgs = document.getElementById('msgs');
|
||||
msgs.scrollTop = msgs.scrollHeight;
|
||||
}
|
||||
</script>"})
|
||||
convo.read = TRUE
|
||||
dat += "<h2>[check_rights(R_ADMIN, FALSE, user) ? fancy_title(current_title) : current_title]</h2>"
|
||||
dat += "<h4>"
|
||||
dat += "<table style='width:950px; border: 3px solid;'>"
|
||||
dat += "<div id='msgs' style='width:950px; border: 3px solid; overflow-y: scroll; height: 350px;'>"
|
||||
dat += "<table>"
|
||||
|
||||
for(var/message in convo.messages)
|
||||
dat += "<tr><td>[message]</td></tr>"
|
||||
|
||||
dat += "</table>"
|
||||
dat += "</div>"
|
||||
if(convo.typing)
|
||||
dat += "<i><span class='typing'>[current_title] is typing</span></i>"
|
||||
dat += "<br>"
|
||||
@@ -327,17 +339,23 @@
|
||||
if(check_rights(R_ADMIN, FALSE, user))
|
||||
dat += "<a href='?src=[UID()];ping=[current_title]'>Ping</a>"
|
||||
|
||||
var/datum/browser/popup = new(user, window_id, "Messages", 1000, 600, src)
|
||||
popup.set_content(dat)
|
||||
popup.open()
|
||||
open = TRUE
|
||||
|
||||
/datum/pm_tracker/proc/fancy_title(title)
|
||||
var/client/C = pms[title].client
|
||||
var/client/C = pms[title].client || update_client(title)
|
||||
if(!C)
|
||||
return "[title] (Disconnected)"
|
||||
return "[key_name(C, FALSE)] ([ADMIN_QUE(C.mob,"?")]) ([ADMIN_PP(C.mob,"PP")]) ([ADMIN_VV(C.mob,"VV")]) ([ADMIN_SM(C.mob,"SM")]) ([admin_jump_link(C.mob)]) (<A HREF='?_src_=holder;check_antagonist=1'>CA</A>)"
|
||||
|
||||
/datum/pm_tracker/proc/update_client(title)
|
||||
var/client/C = GLOB.directory[ckey(title)]
|
||||
if(C)
|
||||
pms[title].client = C
|
||||
return C
|
||||
return null
|
||||
|
||||
/datum/pm_tracker/Topic(href, href_list)
|
||||
if(href_list["archive"])
|
||||
pms[href_list["archive"]].archived = !pms[href_list["archive"]].archived
|
||||
|
||||
@@ -17,6 +17,10 @@
|
||||
|
||||
feedback_add_details("admin_verb","M") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/get_admin_say()
|
||||
var/msg = input(src, null, "asay \"text\"") as text|null
|
||||
cmd_admin_say(msg)
|
||||
|
||||
/client/proc/cmd_mentor_say(msg as text)
|
||||
set category = "Admin"
|
||||
set name = "Msay"
|
||||
|
||||
@@ -43,3 +43,7 @@
|
||||
say_dead_direct("<span class='name'>[prefix]</span> says, <span class='message'>\"[msg]\"</span>")
|
||||
|
||||
feedback_add_details("admin_verb","D") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/get_dead_say()
|
||||
var/msg = input(src, null, "dsay \"text\"") as text
|
||||
dsay(msg)
|
||||
@@ -116,7 +116,7 @@
|
||||
a_right.holder_movement()
|
||||
|
||||
/obj/item/assembly_holder/Move()
|
||||
..()
|
||||
. = ..()
|
||||
process_movement()
|
||||
return
|
||||
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
|
||||
/obj/item/assembly/infra/Move()
|
||||
var/t = dir
|
||||
..()
|
||||
. = ..()
|
||||
dir = t
|
||||
qdel(first)
|
||||
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
/client
|
||||
//////////////////////
|
||||
//BLACK MAGIC THINGS//
|
||||
//////////////////////
|
||||
parent_type = /datum
|
||||
////////////////
|
||||
//ADMIN THINGS//
|
||||
////////////////
|
||||
@@ -24,7 +28,7 @@
|
||||
|
||||
var/adminhelped = 0
|
||||
|
||||
var/gc_destroyed //Time when this object was destroyed.
|
||||
// var/gc_destroyed //Time when this object was destroyed. [Inherits from datum]
|
||||
|
||||
#ifdef TESTING
|
||||
var/running_find_references
|
||||
@@ -89,5 +93,5 @@
|
||||
// If set to true, this client can interact with atoms such as buttons and doors on top of regular machinery interaction
|
||||
var/advanced_admin_interaction = FALSE
|
||||
|
||||
// Has the client been varedited by an admin?
|
||||
var/var_edited = FALSE
|
||||
// Has the client been varedited by an admin? [Inherits from datum now]
|
||||
// var/var_edited = FALSE
|
||||
|
||||
@@ -297,14 +297,14 @@
|
||||
return null
|
||||
if(byond_build < config.minimum_client_build)
|
||||
alert(src, "You are using a byond build which is not supported by this server. Please use a build version of atleast [config.minimum_client_build].", "Incorrect build", "OK")
|
||||
del(src)
|
||||
qdel(src)
|
||||
return
|
||||
if(byond_version < SUGGESTED_CLIENT_VERSION) // Update is suggested, but not required.
|
||||
to_chat(src,"<span class='userdanger'>Your BYOND client (v: [byond_version]) is out of date. This can cause glitches. We highly suggest you download the latest client from http://www.byond.com/ before playing. </span>")
|
||||
|
||||
if(IsGuestKey(key))
|
||||
alert(src,"This server doesn't allow guest accounts to play. Please go to http://www.byond.com/ and register for a key.","Guest","OK")
|
||||
del(src)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
// Change the way they should download resources.
|
||||
@@ -317,7 +317,6 @@
|
||||
|
||||
GLOB.clients += src
|
||||
GLOB.directory[ckey] = src
|
||||
|
||||
//Admin Authorisation
|
||||
// Automatically makes localhost connection an admin
|
||||
if(!config.disable_localhost_admin)
|
||||
@@ -365,11 +364,14 @@
|
||||
|
||||
. = ..() //calls mob.Login()
|
||||
|
||||
|
||||
if(ckey in clientmessages)
|
||||
for(var/message in clientmessages[ckey])
|
||||
to_chat(src, message)
|
||||
clientmessages.Remove(ckey)
|
||||
|
||||
if(SSinput.initialized)
|
||||
set_macros()
|
||||
|
||||
donator_check()
|
||||
check_ip_intel()
|
||||
@@ -404,8 +406,7 @@
|
||||
|
||||
if(!winexists(src, "asset_cache_browser")) // The client is using a custom skin, tell them.
|
||||
to_chat(src, "<span class='warning'>Unable to access asset cache browser, if you are using a custom skin file, please allow DS to download the updated version, if you are not, then make a bug report. This is not a critical issue but can cause issues with resource downloading, as it is impossible to know when extra resources arrived to you.</span>")
|
||||
|
||||
|
||||
|
||||
//This is down here because of the browse() calls in tooltip/New()
|
||||
if(!tooltips)
|
||||
tooltips = new /datum/tooltip(src)
|
||||
@@ -664,7 +665,7 @@
|
||||
sleep(10) // Since browse is non-instant, and kinda async
|
||||
|
||||
to_chat(src, "<pre class=\"system system\">you're a huge nerd. wakka wakka doodle doop nobody's ever gonna see this, the chat system shouldn't be online by this point</pre>")
|
||||
del(src)
|
||||
qdel(src)
|
||||
return TRUE
|
||||
else
|
||||
if (!topic || !topic["token"] || !tokens[ckey] || topic["token"] != tokens[ckey])
|
||||
@@ -675,7 +676,7 @@
|
||||
tokens[ckey] = cid_check_reconnect()
|
||||
|
||||
sleep(10) //browse is queued, we don't want them to disconnect before getting the browse() command.
|
||||
del(src)
|
||||
qdel(src)
|
||||
return TRUE
|
||||
// We DO have their cached CID handy - compare it, now
|
||||
if(oldcid != computer_id)
|
||||
@@ -693,7 +694,7 @@
|
||||
|
||||
log_adminwarn("Failed Login: [key] [computer_id] [address] - CID randomizer confirmed (oldcid: [oldcid])")
|
||||
|
||||
del(src)
|
||||
qdel(src)
|
||||
return TRUE
|
||||
else
|
||||
// don't shoot, I'm innocent
|
||||
@@ -795,18 +796,15 @@
|
||||
/* Mainwindow */
|
||||
winset(src, "mainwindow.saybutton", "background-color=#40628a;text-color=#FFFFFF")
|
||||
winset(src, "mainwindow.mebutton", "background-color=#40628a;text-color=#FFFFFF")
|
||||
winset(src, "mainwindow.hotkey_toggle", "background-color=#40628a;text-color=#FFFFFF")
|
||||
///// UI ELEMENTS /////
|
||||
/* Mainwindow */
|
||||
winset(src, "mainwindow", "background-color=#272727")
|
||||
winset(src, "mainwindow.mainvsplit", "background-color=#272727")
|
||||
winset(src, "mainwindow.tooltip", "background-color=#272727")
|
||||
/* Outputwindow */
|
||||
winset(src, "outputwindow.outputwindow", "background-color=#272727")
|
||||
winset(src, "outputwindow.browseroutput", "background-color=#272727")
|
||||
/* Rpane */
|
||||
winset(src, "rpane", "background-color=#272727")
|
||||
winset(src, "rpane.rpane", "background-color=#272727")
|
||||
winset(src, "rpane.rpanewindow", "background-color=#272727")
|
||||
/* Browserwindow */
|
||||
winset(src, "browserwindow", "background-color=#272727")
|
||||
@@ -830,18 +828,15 @@
|
||||
/* Mainwindow */
|
||||
winset(src, "mainwindow.saybutton", "background-color=none;text-color=#000000")
|
||||
winset(src, "mainwindow.mebutton", "background-color=none;text-color=#000000")
|
||||
winset(src, "mainwindow.hotkey_toggle", "background-color=none;text-color=#000000")
|
||||
///// UI ELEMENTS /////
|
||||
/* Mainwindow */
|
||||
winset(src, "mainwindow", "background-color=none")
|
||||
winset(src, "mainwindow.mainvsplit", "background-color=none")
|
||||
winset(src, "mainwindow.tooltip", "background-color=none")
|
||||
/* Outputwindow */
|
||||
winset(src, "outputwindow.outputwindow", "background-color=none")
|
||||
winset(src, "outputwindow.browseroutput", "background-color=none")
|
||||
/* Rpane */
|
||||
winset(src, "rpane", "background-color=none")
|
||||
winset(src, "rpane.rpane", "background-color=none")
|
||||
winset(src, "rpane.rpanewindow", "background-color=none")
|
||||
/* Browserwindow */
|
||||
winset(src, "browserwindow", "background-color=none")
|
||||
|
||||
@@ -81,7 +81,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
var/lastchangelog = "" //Saved changlog filesize to detect if there was a change
|
||||
var/exp
|
||||
var/ooccolor = "#b82e00"
|
||||
var/be_special = list() //Special role selection
|
||||
var/list/be_special = list() //Special role selection
|
||||
var/UI_style = "Midnight"
|
||||
var/nanoui_fancy = TRUE
|
||||
var/toggles = TOGGLES_DEFAULT
|
||||
@@ -455,6 +455,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
dat += "<b>Ghost Ears:</b> <a href='?_src_=prefs;preference=ghost_ears'><b>[(toggles & CHAT_GHOSTEARS) ? "All Speech" : "Nearest Creatures"]</b></a><br>"
|
||||
dat += "<b>Ghost Radio:</b> <a href='?_src_=prefs;preference=ghost_radio'><b>[(toggles & CHAT_GHOSTRADIO) ? "All Chatter" : "Nearest Speakers"]</b></a><br>"
|
||||
dat += "<b>Ghost Sight:</b> <a href='?_src_=prefs;preference=ghost_sight'><b>[(toggles & CHAT_GHOSTSIGHT) ? "All Emotes" : "Nearest Creatures"]</b></a><br>"
|
||||
dat += "<b>Ghost PDA:</b> <a href='?_src_=prefs;preference=ghost_pda'><b>[(toggles & CHAT_GHOSTPDA) ? "All PDA Messages" : "No PDA Messages"]</b></a><br>"
|
||||
if(check_rights(R_ADMIN,0))
|
||||
dat += "<b>OOC Color:</b> <span style='border: 1px solid #161616; background-color: [ooccolor ? ooccolor : normal_ooc_colour];'> </span> <a href='?_src_=prefs;preference=ooccolor;task=input'><b>Change</b></a><br>"
|
||||
if(config.allow_Metadata)
|
||||
@@ -2029,6 +2030,9 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
|
||||
if("ghost_radio")
|
||||
toggles ^= CHAT_GHOSTRADIO
|
||||
|
||||
if("ghost_pda")
|
||||
toggles ^= CHAT_GHOSTPDA
|
||||
|
||||
if("ghost_anonsay")
|
||||
ghost_anonsay = !ghost_anonsay
|
||||
@@ -2280,3 +2284,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
|
||||
/datum/preferences/proc/close_load_dialog(mob/user)
|
||||
user << browse(null, "window=saves")
|
||||
|
||||
//Check if the user has ANY job selected.
|
||||
/datum/preferences/proc/check_any_job()
|
||||
return(job_support_high || job_support_med || job_support_low || job_medsci_high || job_medsci_med || job_medsci_low || job_engsec_high || job_engsec_med || job_engsec_low || job_karma_high || job_karma_med || job_karma_low)
|
||||
|
||||
@@ -241,4 +241,36 @@
|
||||
to_chat(usr, "<span class='notice'>You have enabled text popup limiting.")
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>You have disabled text popup limiting.")
|
||||
return
|
||||
|
||||
/client/verb/numpad_target()
|
||||
set name = "Toggle Numpad targetting"
|
||||
set category = "Preferences"
|
||||
set desc = "This button will allow you to enable or disable Numpad Targetting"
|
||||
prefs.toggles ^= NUMPAD_TARGET
|
||||
prefs.save_preferences(src)
|
||||
if (prefs.toggles & NUMPAD_TARGET)
|
||||
to_chat(usr, "<span class='notice'>You have enabled Numpad Targetting.")
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>You have disabled Numpad Targetting.")
|
||||
return
|
||||
|
||||
/client/verb/azerty_toggle()
|
||||
set name = "Toggle QWERTY/AZERTY"
|
||||
set category = "Preferences"
|
||||
set desc = "This button will switch you between QWERTY and AZERTY control sets"
|
||||
prefs.toggles ^= AZERTY
|
||||
prefs.save_preferences(src)
|
||||
if (prefs.toggles & AZERTY)
|
||||
to_chat(usr, "<span class='notice'>You are now in AZERTY mode.")
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>You are now in QWERTY mode.")
|
||||
return
|
||||
/client/verb/toggle_ghost_pda()
|
||||
set name = "Show/Hide GhostPDA"
|
||||
set category = "Preferences"
|
||||
set desc = ".Toggle seeing PDA messages as an observer."
|
||||
prefs.toggles ^= CHAT_GHOSTPDA
|
||||
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTPDA) ? "see all PDA messages" : "no longer see PDA messages"].")
|
||||
prefs.save_preferences(src)
|
||||
feedback_add_details("admin_verb","TGP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -64,7 +64,6 @@
|
||||
item_state = "lgloves"
|
||||
flags = NODROP
|
||||
|
||||
|
||||
/obj/item/clothing/gloves/color/yellow/stun
|
||||
name = "stun gloves"
|
||||
desc = "Horrendous and awful. It smells like cancer. The fact it has wires attached to it is incidental."
|
||||
@@ -72,6 +71,9 @@
|
||||
var/stun_strength = 5
|
||||
var/stun_cost = 2000
|
||||
|
||||
/obj/item/clothing/gloves/color/yellow/stun/get_cell()
|
||||
return cell
|
||||
|
||||
/obj/item/clothing/gloves/color/yellow/stun/New()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
@@ -110,12 +110,23 @@
|
||||
/obj/item/clothing/mask/muzzle/safety
|
||||
name = "safety muzzle"
|
||||
desc = "A muzzle designed to prevent biting."
|
||||
resist_time = 600
|
||||
icon_state = "muzzle_secure"
|
||||
item_state = "muzzle_secure"
|
||||
resist_time = 0
|
||||
mute = MUZZLE_MUTE_NONE
|
||||
security_lock = TRUE
|
||||
locked = FALSE
|
||||
materials = list(MAT_METAL=500, MAT_GLASS=50)
|
||||
|
||||
sprite_sheets = list(
|
||||
"Vox" = 'icons/mob/species/vox/mask.dmi',
|
||||
"Unathi" = 'icons/mob/species/unathi/mask.dmi',
|
||||
"Tajaran" = 'icons/mob/species/tajaran/mask.dmi',
|
||||
"Vulpkanin" = 'icons/mob/species/vulpkanin/mask.dmi',
|
||||
"Grey" = 'icons/mob/species/grey/mask.dmi',
|
||||
"Drask" = 'icons/mob/species/drask/mask.dmi'
|
||||
)
|
||||
|
||||
/obj/item/clothing/mask/muzzle/safety/shock
|
||||
name = "shock muzzle"
|
||||
desc = "A muzzle designed to prevent biting. This one is fitted with a behavior correction system."
|
||||
|
||||
@@ -97,6 +97,9 @@
|
||||
to_chat(usr, "The maintenance panel is [open ? "open" : "closed"].")
|
||||
to_chat(usr, "Hardsuit systems are [offline ? "<font color='red'>offline</font>" : "<font color='green'>online</font>"].")
|
||||
|
||||
/obj/item/rig/get_cell()
|
||||
return cell
|
||||
|
||||
/obj/item/rig/New()
|
||||
..()
|
||||
|
||||
|
||||
@@ -857,3 +857,36 @@
|
||||
icon_state = "burial"
|
||||
item_state = "burial"
|
||||
item_color = "burial"
|
||||
|
||||
/obj/item/clothing/under/redhawaiianshirt
|
||||
name = "red hawaiian shirt"
|
||||
desc = "a floral shirt worn to most vacation destinations."
|
||||
icon_state = "hawaiianred"
|
||||
item_state = "hawaiianred"
|
||||
item_color = "hawaiianred"
|
||||
flags_size = ONESIZEFITSALL
|
||||
|
||||
/obj/item/clothing/under/pinkhawaiianshirt
|
||||
name = "pink hawaiian shirt"
|
||||
desc = "a pink floral shirt the material feels cool and comfy."
|
||||
icon_state = "hawaiianpink"
|
||||
item_state = "hawaiianpink"
|
||||
item_color = "hawaiianpink"
|
||||
flags_size = ONESIZEFITSALL
|
||||
|
||||
/obj/item/clothing/under/orangehawaiianshirt
|
||||
name = "orange hawaiian shirt"
|
||||
desc = "a orange floral shirt for a relaxing day in space."
|
||||
icon_state = "hawaiianorange"
|
||||
item_state = "hawaiianorange"
|
||||
item_color = "hawaiianorange"
|
||||
flags_size = ONESIZEFITSALL
|
||||
|
||||
/obj/item/clothing/under/bluehawaiianshirt
|
||||
name = "blue hawaiian shirt"
|
||||
desc = "a blue floral shirt it has a oddly colored pink flower on it."
|
||||
icon_state = "hawaiianblue"
|
||||
item_state = "hawaiianblue"
|
||||
item_color = "hawaiianblue"
|
||||
flags_size = ONESIZEFITSALL
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/datum/event/disease_outbreak
|
||||
announceWhen = 15
|
||||
|
||||
var/virus_type
|
||||
var/datum/disease/advance/virus_type
|
||||
|
||||
/datum/event/disease_outbreak/setup()
|
||||
announceWhen = rand(15, 30)
|
||||
@@ -10,9 +10,13 @@
|
||||
event_announcement.Announce("Confirmed outbreak of level 7 major viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
|
||||
|
||||
/datum/event/disease_outbreak/start()
|
||||
if(!virus_type)
|
||||
if(prob(25))
|
||||
virus_type = pick(/datum/disease/advance/flu, /datum/disease/advance/cold, /datum/disease/brainrot, /datum/disease/magnitis, /datum/disease/beesease, /datum/disease/anxiety, /datum/disease/fake_gbs, /datum/disease/fluspanish, /datum/disease/pierrot_throat, /datum/disease/lycan)
|
||||
|
||||
else
|
||||
virus_type = new /datum/disease/advance
|
||||
virus_type.name = capitalize(pick(GLOB.adjectives)) + " " + capitalize(pick(GLOB.nouns,GLOB.verbs)) // random silly name
|
||||
virus_type.GenerateSymptoms(1,9,6)
|
||||
virus_type.AssignProperties(list("resistance" = rand(0,11), "stealth" = rand(0,2), "stage_rate" = rand(0,5), "transmittable" = rand(0,5), "severity" = rand(0,10)))
|
||||
for(var/mob/living/carbon/human/H in shuffle(GLOB.living_mob_list))
|
||||
if(issmall(H)) //don't infect monkies; that's a waste
|
||||
continue
|
||||
@@ -32,8 +36,8 @@
|
||||
if(H.stat == DEAD || foundAlready)
|
||||
continue
|
||||
|
||||
var/datum/disease/D
|
||||
D = new virus_type()
|
||||
var/datum/disease/advance/D
|
||||
D = virus_type
|
||||
D.carrier = TRUE
|
||||
H.AddDisease(D)
|
||||
break
|
||||
|
||||
@@ -41,14 +41,14 @@
|
||||
icon_state = "anom"
|
||||
failchance = 0
|
||||
|
||||
/obj/effect/portal/wormhole/can_teleport(atom/movable/M)
|
||||
. = ..()
|
||||
|
||||
if(istype(M, /obj/singularity))
|
||||
. = FALSE
|
||||
|
||||
/obj/effect/portal/wormhole/teleport(atom/movable/M)
|
||||
if(!istype(M))
|
||||
return FALSE
|
||||
|
||||
if(!M.simulated || iseffect(M))
|
||||
return FALSE
|
||||
|
||||
if(M.anchored && ismecha(M))
|
||||
if(!can_teleport(M))
|
||||
return FALSE
|
||||
|
||||
var/turf/target
|
||||
|
||||
@@ -164,7 +164,7 @@
|
||||
// Virology Medical Smartfridge
|
||||
// ----------------------------
|
||||
/obj/machinery/smartfridge/secure/chemistry/virology
|
||||
name = "smart virus storage"
|
||||
name = "Smart Virus Storage"
|
||||
desc = "A refrigerated storage unit for volatile sample storage."
|
||||
req_access_txt = "39"
|
||||
spawn_meds = list(/obj/item/reagent_containers/syringe/antiviral = 4,
|
||||
@@ -386,7 +386,8 @@
|
||||
return data
|
||||
|
||||
/obj/machinery/smartfridge/Topic(href, href_list)
|
||||
if(..()) return 0
|
||||
if(..())
|
||||
return FALSE
|
||||
|
||||
var/mob/user = usr
|
||||
var/datum/nanoui/ui = SSnanoui.get_open_ui(user, src, "main")
|
||||
@@ -396,7 +397,7 @@
|
||||
if(href_list["close"])
|
||||
user.unset_machine()
|
||||
ui.close()
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
if(href_list["vend"])
|
||||
var/index = text2num(href_list["vend"])
|
||||
@@ -409,17 +410,26 @@
|
||||
item_quants[K] = max(count - amount, 0)
|
||||
|
||||
var/i = amount
|
||||
for(var/obj/O in contents)
|
||||
if(O.name == K)
|
||||
O.forceMove(loc)
|
||||
adjust_item_drop_location(O)
|
||||
update_icon()
|
||||
i--
|
||||
if(i <= 0)
|
||||
return 1
|
||||
|
||||
return 1
|
||||
return 0
|
||||
if(i == 1 && Adjacent(user) && !issilicon(user))
|
||||
for(var/obj/O in contents)
|
||||
if(O.name == K)
|
||||
if(!user.put_in_hands(O))
|
||||
O.forceMove(loc)
|
||||
adjust_item_drop_location(O)
|
||||
update_icon()
|
||||
break
|
||||
return TRUE
|
||||
else
|
||||
for(var/obj/O in contents)
|
||||
if(O.name == K)
|
||||
O.forceMove(loc)
|
||||
adjust_item_drop_location(O)
|
||||
update_icon()
|
||||
i--
|
||||
if(i <= 0)
|
||||
return TRUE
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/obj/machinery/smartfridge/proc/throw_item()
|
||||
var/obj/throw_item = null
|
||||
|
||||
@@ -319,6 +319,8 @@
|
||||
|
||||
else if(href_list["create"])
|
||||
var/amount = (text2num(href_list["amount"]))
|
||||
//Can't be outside these (if you change this keep a sane limit)
|
||||
amount = Clamp(amount, 1, 10)
|
||||
var/datum/design/D = locate(href_list["create"])
|
||||
create_product(D, amount)
|
||||
updateUsrDialog()
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
/datum/admins/key_down(_key, client/user)
|
||||
switch(_key)
|
||||
if("F5")
|
||||
user.get_admin_say()
|
||||
return
|
||||
if("F6")
|
||||
user.admin_ghost()
|
||||
return
|
||||
if("F7")
|
||||
player_panel_new()
|
||||
return
|
||||
if("F8")
|
||||
user.cmd_admin_pm_panel()
|
||||
return
|
||||
if("F9")
|
||||
user.stealth()
|
||||
return
|
||||
if("F10")
|
||||
user.get_dead_say()
|
||||
return
|
||||
..()
|
||||
@@ -0,0 +1,21 @@
|
||||
// You might be wondering why this isn't client level. If focus is null, we don't want you to move.
|
||||
// Only way to do that is to tie the behavior into the focus's keyLoop().
|
||||
|
||||
/atom/movable/keyLoop(client/user)
|
||||
if(!user.keys_held["Ctrl"])
|
||||
var/movement_dir = NONE
|
||||
var/list/movement = SSinput.movement_keys
|
||||
if(user.prefs.toggles & AZERTY)
|
||||
movement = SSinput.alt_movement_keys
|
||||
for(var/_key in user.keys_held)
|
||||
movement_dir = movement_dir | movement[_key]
|
||||
if(user.next_move_dir_add)
|
||||
movement_dir |= user.next_move_dir_add
|
||||
if(user.next_move_dir_sub)
|
||||
movement_dir &= ~user.next_move_dir_sub
|
||||
// Sanity checks in case you hold left and right and up to make sure you only go up
|
||||
if((movement_dir & NORTH) && (movement_dir & SOUTH))
|
||||
movement_dir &= ~(NORTH|SOUTH)
|
||||
if((movement_dir & EAST) && (movement_dir & WEST))
|
||||
movement_dir &= ~(EAST|WEST)
|
||||
user.Move(get_step(src, movement_dir), movement_dir)
|
||||
@@ -0,0 +1,20 @@
|
||||
/mob/living/carbon/key_down(_key, client/user)
|
||||
user.keys_held[_key] = world.time
|
||||
if(!user.keys_held["Shift"])
|
||||
switch(_key)
|
||||
if("R", "Southwest") // Southwest is End
|
||||
toggle_throw_mode()
|
||||
return
|
||||
if("1")
|
||||
a_intent_change("help")
|
||||
return
|
||||
if("2")
|
||||
a_intent_change("disarm")
|
||||
return
|
||||
if("3")
|
||||
a_intent_change("grab")
|
||||
return
|
||||
if("4")
|
||||
a_intent_change("harm")
|
||||
return
|
||||
return ..()
|
||||
@@ -0,0 +1,56 @@
|
||||
// Clients aren't datums so we have to define these procs indpendently.
|
||||
// These verbs are called for all key press and release events
|
||||
/client/verb/keyDown(_key as text)
|
||||
set instant = TRUE
|
||||
set hidden = TRUE
|
||||
keys_held[_key] = world.time
|
||||
var/movement = SSinput.movement_keys[_key]
|
||||
if (prefs.toggles & AZERTY) movement = SSinput.alt_movement_keys[_key]
|
||||
if(!(next_move_dir_sub & movement) && !keys_held["Ctrl"])
|
||||
next_move_dir_add |= movement
|
||||
|
||||
// Client-level keybindings are ones anyone should be able to do at any time
|
||||
// Things like taking screenshots, hitting tab, and adminhelps.
|
||||
|
||||
switch(_key)
|
||||
if("F1")
|
||||
if(keys_held["Ctrl"] && keys_held["Shift"]) // Is this command ever used?
|
||||
winset(src, null, "command=.options")
|
||||
else
|
||||
adminhelp()
|
||||
return
|
||||
if("F2") // Screenshot. Hold shift to choose a name and location to save in
|
||||
ooc()
|
||||
return
|
||||
if("F4")
|
||||
mob.me_verb()
|
||||
return
|
||||
if("F12") // Toggles minimal HUD
|
||||
mob.button_pressed_F12()
|
||||
return
|
||||
|
||||
if(holder)
|
||||
holder.key_down(_key, src)
|
||||
if(mob.focus)
|
||||
mob.focus.key_down(_key, src)
|
||||
|
||||
/client/verb/keyUp(_key as text)
|
||||
set instant = TRUE
|
||||
set hidden = TRUE
|
||||
keys_held -= _key
|
||||
var/movement = SSinput.movement_keys[_key]
|
||||
if (prefs.toggles & AZERTY) movement = SSinput.alt_movement_keys[_key]
|
||||
if(!(next_move_dir_add & movement))
|
||||
next_move_dir_sub |= movement
|
||||
|
||||
if(holder)
|
||||
holder.key_up(_key, src)
|
||||
if(mob.focus)
|
||||
mob.focus.key_up(_key, src)
|
||||
|
||||
// Called every game tick
|
||||
/client/keyLoop()
|
||||
if(holder)
|
||||
holder.keyLoop(src)
|
||||
if(mob.focus)
|
||||
mob.focus.keyLoop(src)
|
||||
@@ -0,0 +1,80 @@
|
||||
/mob/living/carbon/human/key_down(_key, client/user)
|
||||
if(_key == "H")
|
||||
var/obj/item/clothing/accessory/holster/H = null
|
||||
if(istype(w_uniform, /obj/item/clothing/under))
|
||||
var/obj/item/clothing/under/S = w_uniform
|
||||
if(S.accessories.len)
|
||||
H = locate() in S.accessories
|
||||
if (!H)
|
||||
return
|
||||
if(!H.holstered)
|
||||
if(!istype(get_active_hand(), /obj/item/gun))
|
||||
to_chat(usr, "<span class='warning'>You need your gun equiped to holster it.</span>")
|
||||
return
|
||||
var/obj/item/gun/W = get_active_hand()
|
||||
H.holster(W, usr)
|
||||
else
|
||||
H.unholster(usr)
|
||||
if(client.keys_held["Shift"])
|
||||
switch(_key)
|
||||
if("E") // Put held thing in belt or take out most recent thing from belt
|
||||
quick_equip() // Implementing the storage component is going to take way too long
|
||||
// var/obj/item/thing = get_active_hand()
|
||||
// var/obj/item/equipped_belt = get_item_by_slot(slot_belt)
|
||||
// if(!equipped_belt) // We also let you equip a belt like this
|
||||
// if(!thing)
|
||||
// to_chat(user, "<span class='notice'>You have no belt to take something out of.</span>")
|
||||
// return
|
||||
// if(equip_to_slot_if_possible(thing, slot_belt))
|
||||
// update_inv_r_hand()
|
||||
// update_inv_l_hand()
|
||||
// return
|
||||
// if(!SEND_SIGNAL(equipped_belt, COMSIG_CONTAINS_STORAGE)) // not a storage item
|
||||
// if(!thing)
|
||||
// equipped_belt.attack_hand(src)
|
||||
// else
|
||||
// to_chat(user, "<span class='notice'>You can't fit anything in.</span>")
|
||||
// return
|
||||
// if(thing) // put thing in belt
|
||||
// if(!SEND_SIGNAL(equipped_belt, COMSIG_TRY_STORAGE_INSERT, thing, user.mob))
|
||||
// to_chat(user, "<span class='notice'>You can't fit anything in.</span>")
|
||||
// return
|
||||
// if(!equipped_belt.contents.len) // nothing to take out
|
||||
// to_chat(user, "<span class='notice'>There's nothing in your belt to take out.</span>")
|
||||
// return
|
||||
// var/obj/item/stored = equipped_belt.contents[equipped_belt.contents.len]
|
||||
// if(!stored || stored.on_found(src))
|
||||
// return
|
||||
// stored.attack_hand(src) // take out thing from belt
|
||||
// return
|
||||
|
||||
/* if("B") // Put held thing in backpack or take out most recent thing from backpack
|
||||
var/obj/item/thing = get_active_hand()
|
||||
var/obj/item/equipped_back = get_item_by_slot(slot_back)
|
||||
if(!equipped_back) // We also let you equip a backpack like this
|
||||
if(!thing)
|
||||
to_chat(user, "<span class='notice'>You have no backpack to take something out of.</span>")
|
||||
return
|
||||
if(equip_to_slot_if_possible(thing, slot_back))
|
||||
update_inv_r_hand()
|
||||
update_inv_l_hand()
|
||||
return
|
||||
if(!SEND_SIGNAL(equipped_back, COMSIG_CONTAINS_STORAGE)) // not a storage item
|
||||
if(!thing)
|
||||
equipped_back.attack_hand(src)
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You can't fit anything in.</span>")
|
||||
return
|
||||
if(thing) // put thing in backpack
|
||||
if(!SEND_SIGNAL(equipped_back, COMSIG_TRY_STORAGE_INSERT, thing, user.mob))
|
||||
to_chat(user, "<span class='notice'>You can't fit anything in.</span>")
|
||||
return
|
||||
if(!equipped_back.contents.len) // nothing to take out
|
||||
to_chat(user, "<span class='notice'>There's nothing in your backpack to take out.</span>")
|
||||
return
|
||||
var/obj/item/stored = equipped_back.contents[equipped_back.contents.len]
|
||||
if(!stored || stored.on_found(src))
|
||||
return
|
||||
stored.attack_hand(src) // take out thing from backpack
|
||||
return */
|
||||
return ..()
|
||||
@@ -0,0 +1,7 @@
|
||||
/mob/living/key_down(_key, client/user)
|
||||
switch(_key)
|
||||
if("B")
|
||||
resist()
|
||||
return
|
||||
|
||||
return ..()
|
||||
@@ -0,0 +1,145 @@
|
||||
// Technically the client argument is unncessary here since that SHOULD be src.client but let's not assume things
|
||||
// All it takes is one badmin setting their focus to someone else's client to mess things up
|
||||
// Or we can have NPC's send actual keypresses and detect that by seeing no client
|
||||
|
||||
/mob/key_down(_key, client/user)
|
||||
if(user.prefs.toggles & AZERTY)
|
||||
switch(_key)
|
||||
if("Delete")
|
||||
if(!pulling)
|
||||
to_chat(src, "<span class='notice'>You are not pulling anything.</span>")
|
||||
else
|
||||
stop_pulling()
|
||||
return
|
||||
if("Insert", "G")
|
||||
a_intent_change(INTENT_HOTKEY_RIGHT)
|
||||
return
|
||||
if("F")
|
||||
a_intent_change(INTENT_HOTKEY_LEFT)
|
||||
return
|
||||
if("X", "Northeast") // Northeast is Page-up
|
||||
swap_hand()
|
||||
return
|
||||
if("Y", "W", "Southeast") // Southeast is Page-down
|
||||
mode() // attack_self(). No idea who came up with "mode()"
|
||||
return
|
||||
if("A", "Northwest") // Northwest is Home
|
||||
var/obj/item/I = get_active_hand()
|
||||
if(!I)
|
||||
to_chat(src, "<span class='warning'>You have nothing to drop in your hand!</span>")
|
||||
else
|
||||
drop_item(I)
|
||||
return
|
||||
if("E")
|
||||
quick_equip()
|
||||
return
|
||||
if("Alt")
|
||||
toggle_move_intent()
|
||||
return
|
||||
else
|
||||
switch(_key)
|
||||
if("Delete")
|
||||
if(!pulling)
|
||||
to_chat(src, "<span class='notice'>You are not pulling anything.</span>")
|
||||
else
|
||||
stop_pulling()
|
||||
return
|
||||
if("Insert", "G")
|
||||
a_intent_change(INTENT_HOTKEY_RIGHT)
|
||||
return
|
||||
if("F")
|
||||
a_intent_change(INTENT_HOTKEY_LEFT)
|
||||
return
|
||||
if("X", "Northeast") // Northeast is Page-up
|
||||
swap_hand()
|
||||
return
|
||||
if("Y", "Z", "Southeast") // Southeast is Page-down
|
||||
mode() // attack_self(). No idea who came up with "mode()"
|
||||
return
|
||||
if("Q", "Northwest") // Northwest is Home
|
||||
var/obj/item/I = get_active_hand()
|
||||
if(!I)
|
||||
to_chat(src, "<span class='warning'>You have nothing to drop in your hand!</span>")
|
||||
else
|
||||
drop_item(I)
|
||||
return
|
||||
if("E")
|
||||
quick_equip()
|
||||
return
|
||||
if("Alt")
|
||||
toggle_move_intent()
|
||||
return
|
||||
//Bodypart selections
|
||||
if(client.prefs.toggles & NUMPAD_TARGET)
|
||||
switch(_key)
|
||||
if("Numpad8")
|
||||
user.body_toggle_head()
|
||||
return
|
||||
if("Numpad4")
|
||||
user.body_r_arm()
|
||||
return
|
||||
if("Numpad5")
|
||||
user.body_chest()
|
||||
return
|
||||
if("Numpad6")
|
||||
user.body_l_arm()
|
||||
return
|
||||
if("Numpad1")
|
||||
user.body_r_leg()
|
||||
return
|
||||
if("Numpad2")
|
||||
user.body_groin()
|
||||
return
|
||||
if("Numpad3")
|
||||
user.body_l_leg()
|
||||
return
|
||||
else
|
||||
switch(_key)
|
||||
if("Numpad1")
|
||||
a_intent_change("help")
|
||||
return
|
||||
if("Numpad2")
|
||||
a_intent_change("disarm")
|
||||
return
|
||||
if("Numpad3")
|
||||
a_intent_change("grab")
|
||||
return
|
||||
if("Numpad4")
|
||||
a_intent_change("harm")
|
||||
return
|
||||
if(client.keys_held["Ctrl"] && client.prefs.toggles & AZERTY)
|
||||
switch(SSinput.alt_movement_keys[_key])
|
||||
if(NORTH)
|
||||
northface()
|
||||
return
|
||||
if(SOUTH)
|
||||
southface()
|
||||
return
|
||||
if(WEST)
|
||||
westface()
|
||||
return
|
||||
if(EAST)
|
||||
eastface()
|
||||
return
|
||||
else if(client.keys_held["Ctrl"])
|
||||
switch(SSinput.movement_keys[_key])
|
||||
if(NORTH)
|
||||
northface()
|
||||
return
|
||||
if(SOUTH)
|
||||
southface()
|
||||
return
|
||||
if(WEST)
|
||||
westface()
|
||||
return
|
||||
if(EAST)
|
||||
eastface()
|
||||
return
|
||||
return ..()
|
||||
|
||||
/mob/key_up(_key, client/user)
|
||||
switch(_key)
|
||||
if("Alt")
|
||||
toggle_move_intent()
|
||||
return
|
||||
return ..()
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user