Merge branch 'ghost-rad-hud' of https://github.com/chafla/Paradise into ghost-rad-hud

This commit is contained in:
chafla
2021-07-13 15:43:22 -07:00
251 changed files with 4085 additions and 4488 deletions
+32 -6
View File
@@ -1,12 +1,38 @@
[langserver]
dreamchecker = true
# Keep the keys in this file alphabetical please
[code_standards]
disallow_relative_type_definitions = true
disallow_relative_proc_definitions = true
disallow_relative_type_definitions = true
[debugger]
engine = "auxtools"
[dmdoc]
use_typepath_names = true
[debugger]
engine = "auxtools"
[langserver]
dreamchecker = true
[map_renderer]
hide_invisible = [
"/obj/effect/landmark",
"/obj/effect/mapping_helpers",
"/obj/effect/spawner/random_barrier",
"/obj/effect/spawner/random_spawners",
]
[map_renderer.fancy_layers]
# -10
"/turf/simulated/floor/plating" = -10
"/turf/space" = -10
# -2
"/turf/simulated/floor/bluegrid" = -2
"/turf/simulated/floor/carpet" = -2
"/turf/simulated/floor/engine" = -2
"/turf/simulated/floor/plasteel" = -2
"/turf/simulated/floor/wood" = -2
"/turf/simulated/wall" = -2
[map_renderer.render_passes]
icon-smoothing = false
icon-smoothing-2016 = true
smart-cables = false
@@ -146,7 +146,7 @@
/turf/simulated/floor/plating/airless,
/area/space/nearstation)
"F" = (
/obj/structure/computerframe/HONKputer,
/obj/structure/computerframe,
/turf/simulated/floor/plasteel/airless,
/area/space/nearstation)
"G" = (
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+8
View File
@@ -743,3 +743,11 @@
///SSalarm signals
#define COMSIG_TRIGGERED_ALARM "ssalarm_triggered"
#define COMSIG_CANCELLED_ALARM "ssalarm_cancelled"
// /obj/machinery/door signals
#define COMSIG_DOOR_OPEN "door_open"
#define COMSIG_DOOR_CLOSE "door_close"
// /obj/machinery/door/airlock signals
#define COMSIG_AIRLOCK_OPEN "airlock_open"
#define COMSIG_AIRLOCK_CLOSE "airlock_close"
-1
View File
@@ -32,7 +32,6 @@
#define SPECIAL_ROLE_FREE_GOLEM "Free Golem"
#define SPECIAL_ROLE_GOLEM "Golem"
#define SPECIAL_ROLE_HEAD_REV "Head Revolutionary"
#define SPECIAL_ROLE_HONKSQUAD "Honksquad"
#define SPECIAL_ROLE_REV "Revolutionary"
#define SPECIAL_ROLE_MORPH "Morph"
#define SPECIAL_ROLE_MULTIVERSE "Multiverse Traveller"
-2
View File
@@ -22,8 +22,6 @@
#define iseffect(A) (istype(A, /obj/effect))
#define is_cleanable(A) (istype(A, /obj/effect/decal/cleanable) || istype(A, /obj/effect/rune)) //if something is cleanable
#define isclothing(A) (istype(A, /obj/item/clothing))
#define is_pen(W) (istype(W, /obj/item/pen))
+5
View File
@@ -489,3 +489,8 @@
/// Send to the mentor Discord webhook
#define DISCORD_WEBHOOK_MENTOR "MENTOR"
// Hallucination severities
#define HALLUCINATE_MINOR 1
#define HALLUCINATE_MODERATE 2
#define HALLUCINATE_MAJOR 3
+5
View File
@@ -277,6 +277,11 @@
#define HEARING_PROTECTION_MAJOR 2
#define HEARING_PROTECTION_TOTAL 3
// Defines used in /mob/living/carbon/human/update_health_hud to override the health status
#define HEALTH_HUD_OVERRIDE_NONE 0
#define HEALTH_HUD_OVERRIDE_CRIT 1
#define HEALTH_HUD_OVERRIDE_DEAD 2
#define HEALTH_HUD_OVERRIDE_HEALTHY 3
// Eye protection
#define FLASH_PROTECTION_SENSITIVE -1
#define FLASH_PROTECTION_NONE 0
+5
View File
@@ -39,11 +39,16 @@
#define ROLE_ERT "emergency response team"
#define ROLE_NYMPH "Dionaea"
#define ROLE_GSPIDER "giant spider"
#define ROLE_TSPIDER "terror spider"
#define ROLE_DRONE "drone"
#define ROLE_DEATHSQUAD "deathsquad"
#define ROLE_EVENTMISC "eventmisc"
#define ROLE_GHOST "ghost role"
// Misc jobban categories
#define ROLEBAN_AHUD "AntagHUD"
#define ROLEBAN_RECORDS "Records"
//Missing assignment means it's not a gamemode specific role, IT'S NOT A BUG OR ERROR.
//The gamemode specific ones are just so the gamemodes can query whether a player is old enough
//(in game days played) to play that role
+3 -2
View File
@@ -18,6 +18,7 @@ GLOBAL_LIST_INIT(antag_roles, list(
ROLE_GUARDIAN,
ROLE_MORPH,
ROLE_GSPIDER,
ROLE_TSPIDER,
))
// Bannable other roles
@@ -26,6 +27,6 @@ GLOBAL_LIST_INIT(other_roles, list(
ROLE_NYMPH,
ROLE_ERT,
ROLE_GHOST,
"AntagHUD",
"Records"
ROLEBAN_AHUD,
ROLEBAN_RECORDS
))
+8
View File
@@ -140,6 +140,14 @@ GLOBAL_PROTECT(log_end)
/proc/log_tgui(text)
rustg_log_write(GLOB.tgui_log, "[text][GLOB.log_end]")
#ifdef REFERENCE_TRACKING
/proc/log_gc(text)
rustg_log_write(GLOB.gc_log, "[text][GLOB.log_end]")
for(var/client/C in GLOB.admins)
if(check_rights(R_DEBUG, FALSE, C.mob) && (C.prefs.toggles & PREFTOGGLE_CHAT_DEBUGLOGS))
to_chat(C, "GC DEBUG: [text]")
#endif
/proc/log_sql(text)
rustg_log_write(GLOB.sql_log, "[text][GLOB.log_end]")
SEND_TEXT(world.log, text) // Redirect it to DD too
+2 -2
View File
@@ -308,7 +308,7 @@
if(G.client != null)
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
if(!G.client.is_afk(afk_bracket) && (be_special_type in G.client.prefs.be_special))
if(!override_jobban || (!jobban_isbanned(G, roletext) && !jobban_isbanned(G,"Syndicate")))
if(!override_jobban || (!jobban_isbanned(G, roletext) && !jobban_isbanned(G, ROLE_SYNDICATE)))
if(override_age || player_old_enough_antag(G.client,be_special_type))
candidates += G.client
afk_bracket += 600 // Add a minute to the bracket, for every attempt
@@ -324,7 +324,7 @@
if(G.client != null)
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
if(!G.client.is_afk(afk_bracket) && (be_special_type in G.client.prefs.be_special))
if(!override_jobban || (!jobban_isbanned(G, roletext) && !jobban_isbanned(G,"Syndicate")))
if(!override_jobban || (!jobban_isbanned(G, roletext) && !jobban_isbanned(G, ROLE_SYNDICATE)))
if(override_age || player_old_enough_antag(G.client,be_special_type))
candidates += G
afk_bracket += 600 // Add a minute to the bracket, for every attempt
+1
View File
@@ -119,6 +119,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_XENO_HOST "xeno_host" //Tracks whether we're gonna be a baby alien's mummy.
#define TRAIT_SHOCKIMMUNE "shock_immunity"
#define TRAIT_TESLA_SHOCKIMMUNE "tesla_shock_immunity"
#define TRAIT_TELEKINESIS "telekinesis"
#define TRAIT_RESISTHEAT "resist_heat"
#define TRAIT_RESISTHEATHANDS "resist_heat_handsonly" //For when you want to be able to touch hot things, but still want fire to be an issue.
#define TRAIT_RESISTCOLD "resist_cold"
+11 -14
View File
@@ -31,19 +31,20 @@
return 1
/proc/Get_Angle(atom/movable/start,atom/movable/end)//For beams.
if(!start || !end) return 0
/proc/get_angle(atom/movable/start, atom/movable/end)//For beams.
if(!start || !end)
return 0
var/dy
var/dx
dy=(32*end.y+end.pixel_y)-(32*start.y+start.pixel_y)
dx=(32*end.x+end.pixel_x)-(32*start.x+start.pixel_x)
dy = (32 * end.y + end.pixel_y) - (32 * start.y + start.pixel_y)
dx = (32 * end.x + end.pixel_x) - (32 * start.x + start.pixel_x)
if(!dy)
return (dx>=0)?90:270
.=arctan(dx/dy)
if(dy<0)
.+=180
else if(dx<0)
.+=360
return (dx >= 0) ? 90 : 270
. = arctan(dx / dy)
if(dy < 0)
. += 180
else if(dx < 0)
. += 360
//Returns location. Returns null if no location was found.
/proc/get_teleport_loc(turf/location,mob/target,distance = 1, density = 0, errorx = 0, errory = 0, eoffsetx = 0, eoffsety = 0)
@@ -1246,10 +1247,6 @@ GLOBAL_LIST_INIT(wall_items, typecacheof(list(/obj/machinery/power/apc, /obj/mac
return 1
return 0
/proc/get_angle(atom/a, atom/b)
return atan2(b.y - a.y, b.x - a.x)
/proc/atan2(x, y)
if(!x && !y) return 0
return y >= 0 ? arccos(x / sqrt(x * x + y * y)) : -arccos(x / sqrt(x * x + y * y))
+7 -5
View File
@@ -9,13 +9,15 @@
#define UNIT_TESTS
#endif
#ifdef TESTING
//#define GC_FAILURE_HARD_LOOKUP //makes paths that fail to GC call find_references before del'ing.
//implies FIND_REF_NO_CHECK_TICK
/***** All toggles for the GC ref finder *****/
//#define FIND_REF_NO_CHECK_TICK //Sets world.loop_checks to false and prevents find references from sleeping
// #define REFERENCE_TRACKING // Uncomment to enable ref finding
#endif
// #define GC_FAILURE_HARD_LOOKUP //makes paths that fail to GC call find_references before del'ing.
// #define FIND_REF_NO_CHECK_TICK //Sets world.loop_checks to false and prevents find references from sleeping
/***** End toggles for the GC ref finder *****/
#define IS_MODE_COMPILED(MODE) (ispath(text2path("/datum/game_mode/"+(MODE))))
+2 -1
View File
@@ -30,7 +30,8 @@ GLOBAL_LIST_INIT(restricted_camera_networks, list(
"UO45",
"UO45R",
"UO71",
"Xeno"
"Xeno",
"SyndicateTestLab"
)) //Those networks can only be accessed by preexisting terminals. AIs and new terminals can't use them.
GLOBAL_LIST_INIT(ruin_landmarks, list())
+1 -1
View File
@@ -40,7 +40,7 @@ GLOBAL_LIST_INIT(drinks, list("beer2","hot_coco","orangejuice","tomatojuice","li
"booger","bloodymary","gargleblaster","bravebull","tequilasunrise","toxinsspecial",
"beepskysmash","salglu_solution","irishcream","manlydorf","longislandicedtea",
"moonshine","b52","irishcoffee","margarita","blackrussian","manhattan",
"manhattan_proj","whiskeysoda","antifreeze","barefoot","snowwhite","demonsblood",
"manhattan_proj","whiskeysoda","adminfreeze","antifreeze","barefoot","snowwhite","demonsblood",
"vodkatonic","ginfizz","bahama_mama","singulo","sbiten","devilskiss","red_mead",
"mead","iced_beer","grog","aloe","andalusia","alliescocktail","soy_latte",
"cafe_latte","acidspit","amasec","neurotoxin","hippiesdelight","bananahonk",
+5
View File
@@ -24,6 +24,11 @@ GLOBAL_PROTECT(chat_debug_log)
GLOBAL_VAR(round_id)
GLOBAL_PROTECT(round_id)
#ifdef REFERENCE_TRACKING
GLOBAL_VAR(gc_log)
GLOBAL_PROTECT(gc_log)
#endif
GLOBAL_LIST_EMPTY(jobMax)
GLOBAL_PROTECT(jobMax)
GLOBAL_LIST_EMPTY(admin_log)
-38
View File
@@ -33,44 +33,6 @@ GLOBAL_VAR_INIT(gravity_is_on, 1) //basically unused, just one admin verb..
// Recall time limit: 2 hours
GLOBAL_VAR_INIT(recall_time_limit, 72000) //apparently used for the comm console
//////SCORE STUFF
//Goonstyle scoreboard
GLOBAL_VAR_INIT(score_crewscore, 0) // this is the overall var/score for the whole round
GLOBAL_VAR_INIT(score_stuffshipped, 0) // how many useful items have cargo shipped out?
GLOBAL_VAR_INIT(score_stuffharvested, 0) // how many harvests have hydroponics done?
GLOBAL_VAR_INIT(score_oremined, 0) // obvious
GLOBAL_VAR_INIT(score_researchdone, 0)
GLOBAL_VAR_INIT(score_eventsendured, 0) // how many random events did the station survive?
GLOBAL_VAR_INIT(score_powerloss, 0) // how many APCs have poor charge?
GLOBAL_VAR_INIT(score_escapees, 0) // how many people got out alive?
GLOBAL_VAR_INIT(score_deadcrew, 0) // dead bodies on the station, oh no
GLOBAL_VAR_INIT(score_mess, 0) // how much poo, puke, gibs, etc went uncleaned
GLOBAL_VAR_INIT(score_meals, 0)
GLOBAL_VAR_INIT(score_disease, 0) // how many rampant, uncured diseases are on board the station
GLOBAL_VAR_INIT(score_deadcommand, 0) // used during rev, how many command staff perished
GLOBAL_VAR_INIT(score_arrested, 0) // how many traitors/revs/whatever are alive in the brig
GLOBAL_VAR_INIT(score_traitorswon, 0) // how many traitors were successful?
GLOBAL_VAR_INIT(score_allarrested, 0) // did the crew catch all the enemies alive?
GLOBAL_VAR_INIT(score_opkilled, 0) // used during nuke mode, how many operatives died?
GLOBAL_VAR_INIT(score_disc, 0) // is the disc safe and secure?
GLOBAL_VAR_INIT(score_nuked, 0) // was the station blown into little bits?
GLOBAL_VAR_INIT(score_nuked_penalty, 0) //penalty for getting blown to bits
// these ones are mainly for the stat panel
GLOBAL_VAR_INIT(score_powerbonus, 0) // if all APCs on the station are running optimally, big bonus
GLOBAL_VAR_INIT(score_messbonus, 0) // if there are no messes on the station anywhere, huge bonus
GLOBAL_VAR_INIT(score_deadaipenalty, 0) // is the AI dead? if so, big penalty
GLOBAL_VAR_INIT(score_foodeaten, 0) // nom nom nom
GLOBAL_VAR_INIT(score_clownabuse, 0) // how many times a clown was punched, struck or otherwise maligned
GLOBAL_VAR(score_richestname) // this is all stuff to show who was the richest alive on the shuttle
GLOBAL_VAR(score_richestjob) // kinda pointless if you dont have a money system i guess
GLOBAL_VAR_INIT(score_richestcash, 0)
GLOBAL_VAR(score_richestkey)
GLOBAL_VAR(score_dmgestname) // who had the most damage on the shuttle (but was still alive)
GLOBAL_VAR(score_dmgestjob)
GLOBAL_VAR_INIT(score_dmgestdamage, 0)
GLOBAL_VAR(score_dmgestkey)
#define TAB "&nbsp;&nbsp;&nbsp;&nbsp;"
GLOBAL_VAR_INIT(timezoneOffset, 0) // The difference betwen midnight (of the host computer) and 0 world.ticks.
+1
View File
@@ -24,6 +24,7 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_XENO_HOST" = TRAIT_XENO_HOST,
"TRAIT_SHOCKIMMUNE" = TRAIT_SHOCKIMMUNE,
"TRAIT_TESLA_SHOCKIMMUNE" = TRAIT_TESLA_SHOCKIMMUNE,
"TRAIT_TELEKINESIS" = TRAIT_TELEKINESIS,
"TRAIT_RESISTHEAT" = TRAIT_RESISTHEAT,
"TRAIT_RESISTHEATHANDS" = TRAIT_RESISTHEATHANDS,
"TRAIT_RESISTCOLD" = TRAIT_RESISTCOLD,
-8
View File
@@ -215,11 +215,3 @@
if(!ai_control_check(user))
return
toggle_light(user)
// AI-CONTROLLED SLIP GENERATOR IN AI CORE
/obj/machinery/ai_slipper/AICtrlClick(mob/living/silicon/ai/user) //Turns liquid dispenser on or off
ToggleOn()
/obj/machinery/ai_slipper/AIAltClick() //Dispenses liquid if on
Activate()
+1 -11
View File
@@ -17,7 +17,7 @@
if(is_ventcrawling(src)) // To stop drones interacting with anything while ventcrawling
return
if(stat == DEAD)
if(stat == DEAD || lockcharge || IsWeakened() || stunned || paralysis || low_power_mode)
return
var/list/modifiers = params2list(params)
@@ -169,16 +169,6 @@
/obj/machinery/power/apc/BorgCtrlClick(mob/living/silicon/robot/user) // turns off/on APCs. Forwards to AI code.
AICtrlClick(user)
// AI SLIPPER
/obj/machinery/ai_slipper/BorgCtrlClick(mob/living/silicon/robot/user) //Turns liquid dispenser on or off
ToggleOn()
/obj/machinery/ai_slipper/BorgAltClick(mob/living/silicon/robot/user) //Dispenses liquid if on
Activate()
// TURRETCONTROL
/obj/machinery/turretid/BorgCtrlClick(mob/living/silicon/robot/user) //turret control on/off. Forwards to AI code.
+1 -1
View File
@@ -45,7 +45,7 @@
if(HAS_TRAIT(src, TRAIT_LASEREYES) && a_intent == INTENT_HARM)
LaserEyes(A)
if(dna.GetSEState(GLOB.teleblock))
if(HAS_TRAIT(src, TRAIT_TELEKINESIS))
A.attack_tk(src)
if(isturf(A) && get_dist(src, A) <= 1)
+8 -2
View File
@@ -39,7 +39,7 @@
/obj/item/attack_tk(mob/user)
if(user.stat || !isturf(loc))
return
if(user.dna?.GetSEState(GLOB.teleblock) && !user.get_active_hand()) // both should already be true to get here
if(HAS_TRAIT(user, TRAIT_TELEKINESIS) && !user.get_active_hand()) // both should already be true to get here
var/obj/item/tk_grab/O = new(src)
O.form_grab(user, src)
else
@@ -109,7 +109,7 @@
if(!host || host != user)
qdel(src)
return
if(!host.dna?.GetSEState(GLOB.teleblock))
if(!HAS_TRAIT(host, TRAIT_TELEKINESIS))
qdel(src)
return
if(isobj(target) && !isturf(target.loc))
@@ -139,6 +139,12 @@
else
if(focus.buckled_mobs)
to_chat(user, "<span class='notice'>This object is too heavy to move with something buckled to it!</span>")
return
if(length(focus.client_mobs_in_contents))
to_chat(user, "<span class='notice'>This object is too heavy to move with something inside of it!</span>")
return
apply_focus_overlay()
focus.throw_at(target, 10, 1, user)
last_throw = world.time
+16
View File
@@ -0,0 +1,16 @@
SUBSYSTEM_DEF(chat_pings)
name = "Chat Pings"
flags = SS_NO_INIT
runlevels = RUNLEVEL_INIT | RUNLEVEL_LOBBY | RUNLEVEL_SETUP | RUNLEVEL_GAME | RUNLEVEL_POSTGAME // ALL OF THEM
wait = 30 SECONDS // Chat pings every 30 seconds
/// List of all held chat datums
var/list/datum/chatOutput/chat_datums = list() // Do NOT put this in Initialize(). You will cause issues.
/datum/controller/subsystem/chat_pings/fire(resumed)
for(var/datum/chatOutput/CO as anything in chat_datums)
CO.updatePing()
if(MC_TICK_CHECK)
return
/datum/controller/subsystem/chat_pings/stat_entry()
..("P: [length(chat_datums)]")
+110 -57
View File
@@ -26,8 +26,9 @@ SUBSYSTEM_DEF(garbage)
//Queue
var/list/queues
#ifdef TESTING
#ifdef REFERENCE_TRACKING
var/list/reference_find_on_fail = list()
var/ref_search_stop = FALSE
#endif
@@ -137,7 +138,7 @@ SUBSYSTEM_DEF(garbage)
++gcedlasttick
++totalgcs
pass_counts[level]++
#ifdef TESTING
#ifdef REFERENCE_TRACKING
reference_find_on_fail -= refID //It's deleted we don't care anymore.
#endif
if(MC_TICK_CHECK)
@@ -146,20 +147,27 @@ SUBSYSTEM_DEF(garbage)
// Something's still referring to the qdel'd object.
fail_counts[level]++
#ifdef REFERENCE_TRACKING
var/ref_searching = FALSE
#endif
switch(level)
if(GC_QUEUE_CHECK)
#ifdef TESTING
if(reference_find_on_fail[refID])
D.find_references()
#ifdef REFERENCE_TRACKING
if(reference_find_on_fail[refID] && !ref_search_stop)
INVOKE_ASYNC(D, /datum/proc/find_references)
ref_searching = TRUE
#ifdef GC_FAILURE_HARD_LOOKUP
else
D.find_references()
else if (!ref_search_stop)
INVOKE_ASYNC(D, /datum/proc/find_references)
ref_searching = TRUE
#endif
reference_find_on_fail -= refID
#endif
var/type = D.type
var/datum/qdel_item/I = items[type]
testing("GC: -- \ref[src] | [type] was unable to be GC'd --")
#ifdef REFERENCE_TRACKING
log_gc("GC: -- \ref[src] | [type] was unable to be GC'd --")
#endif
I.failures++
if(GC_QUEUE_HARDDELETE)
HardDelete(D)
@@ -169,6 +177,11 @@ SUBSYSTEM_DEF(garbage)
Queue(D, level + 1)
#ifdef REFERENCE_TRACKING
if(ref_searching)
return
#endif
if(MC_TICK_CHECK)
return
if(count)
@@ -243,10 +256,14 @@ SUBSYSTEM_DEF(garbage)
/datum/qdel_item/New(mytype)
name = "[mytype]"
#ifdef TESTING
/proc/qdel_and_find_ref_if_fail(datum/D, force = FALSE)
SSgarbage.reference_find_on_fail["\ref[D]"] = TRUE
qdel(D, force)
#ifdef REFERENCE_TRACKING
/proc/qdel_and_find_ref_if_fail(datum/thing_to_del, force = FALSE)
thing_to_del.qdel_and_find_ref_if_fail(force)
/datum/proc/qdel_and_find_ref_if_fail(force = FALSE)
SSgarbage.reference_find_on_fail["\ref[src]"] = TRUE
qdel(src, force)
#endif
// Should be treated as a replacement for the 'del' keyword.
@@ -304,38 +321,39 @@ SUBSYSTEM_DEF(garbage)
SSgarbage.HardDelete(D)
if(QDEL_HINT_FINDREFERENCE)//qdel will, if TESTING is enabled, display all references to this object, then queue the object for deletion.
SSgarbage.Queue(D)
#ifdef TESTING
#ifdef REFERENCE_TRACKING
D.find_references()
#endif
if(QDEL_HINT_IFFAIL_FINDREFERENCE)
SSgarbage.Queue(D)
#ifdef TESTING
#ifdef REFERENCE_TRACKING
SSgarbage.reference_find_on_fail["\ref[D]"] = TRUE
#endif
else
#ifdef TESTING
#ifdef REFERENCE_TRACKING
if(!I.no_hint)
testing("WARNING: [D.type] is not returning a qdel hint. It is being placed in the queue. Further instances of this type will also be queued.")
log_gc("WARNING: [D.type] is not returning a qdel hint. It is being placed in the queue. Further instances of this type will also be queued.")
#endif
I.no_hint++
SSgarbage.Queue(D)
else if(D.gc_destroyed == GC_CURRENTLY_BEING_QDELETED)
CRASH("[D.type] destroy proc was called multiple times, likely due to a qdel loop in the Destroy logic")
#ifdef TESTING
#ifdef REFERENCE_TRACKING
/datum/verb/find_refs()
/datum/proc/find_refs()
set category = "Debug"
set name = "Find References"
set src in world
if(!check_rights(R_DEBUG))
return
find_references(FALSE)
/datum/proc/find_references(skip_alert)
running_find_references = type
if(usr && usr.client)
if(usr.client.running_find_references)
testing("CANCELLED search for references to a [usr.client.running_find_references].")
log_gc("CANCELLED search for references to a [usr.client.running_find_references].")
usr.client.running_find_references = null
running_find_references = null
//restart the garbage collector
@@ -354,20 +372,27 @@ SUBSYSTEM_DEF(garbage)
if(usr && usr.client)
usr.client.running_find_references = type
testing("Beginning search for references to a [type].")
last_find_references = world.time
log_gc("Beginning search for references to a [type].")
var/starting_time = world.time
DoSearchVar(GLOB) //globals
DoSearchVar(GLOB, "GLOB") //globals
log_gc("Finished searching globals")
for(var/datum/thing in world) //atoms (don't beleive it's lies)
DoSearchVar(thing, "World -> [thing]")
DoSearchVar(thing, "World -> [thing.type]", search_time = starting_time)
log_gc("Finished searching atoms")
for(var/datum/thing) //datums
DoSearchVar(thing, "World -> [thing]")
DoSearchVar(thing, "World -> [thing.type]", search_time = starting_time)
log_gc("Finished searching datums")
for(var/client/thing) //clients
DoSearchVar(thing, "World -> [thing]")
DoSearchVar(thing, "World -> [thing.type]", search_time = starting_time)
testing("Completed search for references to a [type].")
log_gc("Finished searching clients")
log_gc("Completed search for references to a [type].")
if(usr && usr.client)
usr.client.running_find_references = null
running_find_references = null
@@ -376,58 +401,86 @@ SUBSYSTEM_DEF(garbage)
SSgarbage.can_fire = 1
SSgarbage.next_fire = world.time + world.tick_lag
/datum/verb/qdel_then_find_references()
/datum/proc/qdel_then_find_references()
set category = "Debug"
set name = "qdel() then Find References"
set src in world
if(!check_rights(R_DEBUG))
return
qdel(src, TRUE) //Force.
qdel(src, TRUE) //force a qdel
if(!running_find_references)
find_references(TRUE)
/datum/verb/qdel_then_if_fail_find_references()
/datum/proc/qdel_then_if_fail_find_references()
set category = "Debug"
set name = "qdel() then Find References if GC failure"
set src in world
if(!check_rights(R_DEBUG))
return
qdel_and_find_ref_if_fail(src, TRUE)
/datum/proc/DoSearchVar(X, Xname, recursive_limit = 64)
if(usr && usr.client && !usr.client.running_find_references)
return
if(!recursive_limit)
/datum/proc/DoSearchVar(potential_container, container_name, recursive_limit = 64, search_time = world.time)
if((usr?.client && !usr.client.running_find_references) || SSgarbage.ref_search_stop)
return
if(istype(X, /datum))
var/datum/D = X
if(D.last_find_references == last_find_references)
if(!recursive_limit)
log_gc("Recursion limit reached. [container_name]")
return
//Check each time you go down a layer. This makes it a bit slow, but it won't effect the rest of the game at all
#ifndef FIND_REF_NO_CHECK_TICK
CHECK_TICK
#endif
if(istype(potential_container, /datum))
var/datum/datum_container = potential_container
if(datum_container.last_find_references == search_time)
return
D.last_find_references = last_find_references
var/list/L = D.vars
datum_container.last_find_references = search_time
var/list/vars_list = datum_container.vars
for(var/varname in L)
if(varname == "vars")
for(var/varname in vars_list)
#ifndef FIND_REF_NO_CHECK_TICK
CHECK_TICK
#endif
if(varname == "vars" || varname == "vis_locs") //Fun fact, vis_locs don't count for references
continue
var/variable = L[varname]
var/variable = vars_list[varname]
if(variable == src)
testing("Found [src.type] \ref[src] in [D.type]'s [varname] var. [Xname]")
log_gc("Found [type] \ref[src] in [datum_container.type]'s \ref[datum_container] [varname] var. [container_name]")
continue
else if(islist(variable))
DoSearchVar(variable, "[Xname] -> list", recursive_limit - 1)
if(islist(variable))
DoSearchVar(variable, "[container_name] \ref[datum_container] -> [varname] (list)", recursive_limit - 1, search_time)
else if(islist(X))
var/normal = IS_NORMAL_LIST(X)
for(var/I in X)
if(I == src)
testing("Found [src.type] \ref[src] in list [Xname].")
else if(islist(potential_container))
var/normal = IS_NORMAL_LIST(potential_container)
var/list/potential_cache = potential_container
for(var/element_in_list in potential_cache)
#ifndef FIND_REF_NO_CHECK_TICK
CHECK_TICK
#endif
//Check normal entrys
if(element_in_list == src)
log_gc("Found [type] \ref[src] in list [container_name].")
continue
else if(I && !isnum(I) && normal && X[I] == src)
testing("Found [src.type] \ref[src] in list [Xname]\[[I]\]")
else if(islist(I))
DoSearchVar(I, "[Xname] -> list", recursive_limit - 1)
var/assoc_val = null
if(!isnum(element_in_list) && normal)
assoc_val = potential_cache[element_in_list]
//Check assoc entrys
if(assoc_val == src)
log_gc("Found [type] \ref[src] in list [container_name]\[[element_in_list]\]")
continue
//We need to run both of these checks, since our object could be hiding in either of them
//Check normal sublists
if(islist(element_in_list))
DoSearchVar(element_in_list, "[container_name] -> [element_in_list] (list)", recursive_limit - 1, search_time)
//Check assoc sublists
if(islist(assoc_val))
DoSearchVar(potential_container[element_in_list], "[container_name]\[[element_in_list]\] -> [assoc_val] (list)", recursive_limit - 1, search_time)
#ifndef FIND_REF_NO_CHECK_TICK
CHECK_TICK
+1 -1
View File
@@ -164,7 +164,7 @@ SUBSYSTEM_DEF(ghost_spawns)
if(!player_old_enough_antag(M.client, role))
return
if(role_text)
if(jobban_isbanned(M, role_text) || jobban_isbanned(M, "Syndicate"))
if(jobban_isbanned(M, role_text) || jobban_isbanned(M, ROLE_SYNDICATE))
return
if(config.use_exp_restrictions && min_hours)
if(M.client.get_exp_type_num(EXP_TYPE_LIVING) < min_hours * 60)
+5 -1
View File
@@ -61,6 +61,8 @@ SUBSYSTEM_DEF(ticker)
var/end_state = "undefined"
/// Time the real reboot kicks in
var/real_reboot_time = 0
/// Datum used to generate the end of round scoreboard.
var/datum/scoreboard/score = null
/datum/controller/subsystem/ticker/Initialize()
login_music = pick(\
@@ -136,6 +138,7 @@ SUBSYSTEM_DEF(ticker)
/datum/controller/subsystem/ticker/proc/setup()
cultdat = setupcult()
score = new()
// Create and announce mode
if(GLOB.master_mode == "secret")
@@ -482,7 +485,8 @@ SUBSYSTEM_DEF(ticker)
if(findtext("[handler]","auto_declare_completion_"))
call(mode, handler)()
scoreboard()
// Display the scoreboard window
score.scoreboard()
// Declare the completion of the station goals
mode.declare_station_goal_completion()
+1 -1
View File
@@ -58,7 +58,7 @@
return ..()
/datum/beam/proc/Draw()
var/Angle = round(Get_Angle(origin,target))
var/Angle = round(get_angle(origin, target))
var/matrix/rot_matrix = matrix()
rot_matrix.Turn(Angle)
+1
View File
@@ -49,6 +49,7 @@ GLOBAL_DATUM_INIT(crew_repository, /datum/repository/crew, new())
if(C.sensor_mode >= SUIT_SENSOR_VITAL)
crewmemberData["stat"] = H.stat
crewmemberData["health"] = H.health
crewmemberData["oxy"] = round(H.getOxyLoss(), 1)
crewmemberData["tox"] = round(H.getToxLoss(), 1)
crewmemberData["fire"] = round(H.getFireLoss(), 1)
+3 -3
View File
@@ -163,7 +163,7 @@ GLOBAL_VAR_INIT(record_id_num, 1001)
G.fields["photo"] = get_id_photo(H)
G.fields["photo-south"] = "data:image/png;base64,[icon2base64(icon(G.fields["photo"], dir = SOUTH))]"
G.fields["photo-west"] = "data:image/png;base64,[icon2base64(icon(G.fields["photo"], dir = WEST))]"
if(H.gen_record && !jobban_isbanned(H, "Records"))
if(H.gen_record && !jobban_isbanned(H, ROLEBAN_RECORDS))
G.fields["notes"] = H.gen_record
else
G.fields["notes"] = "No notes found."
@@ -183,7 +183,7 @@ GLOBAL_VAR_INIT(record_id_num, 1001)
M.fields["alg_d"] = "No allergies have been detected in this patient."
M.fields["cdi"] = "None"
M.fields["cdi_d"] = "No diseases have been diagnosed at the moment."
if(H.med_record && !jobban_isbanned(H, "Records"))
if(H.med_record && !jobban_isbanned(H, ROLEBAN_RECORDS))
M.fields["notes"] = H.med_record
else
M.fields["notes"] = "No notes found."
@@ -199,7 +199,7 @@ GLOBAL_VAR_INIT(record_id_num, 1001)
S.fields["ma_crim"] = "None"
S.fields["ma_crim_d"] = "No major crime convictions."
S.fields["notes"] = "No notes."
if(H.sec_record && !jobban_isbanned(H, "Records"))
if(H.sec_record && !jobban_isbanned(H, ROLEBAN_RECORDS))
S.fields["notes"] = H.sec_record
else
S.fields["notes"] = "No notes found."
+1 -1
View File
@@ -10,7 +10,7 @@
var/var_edited = FALSE //Warranty void if seal is broken
var/tmp/unique_datum_id = null
#ifdef TESTING
#ifdef REFERENCE_TRACKING
var/running_find_references
var/last_find_references = 0
#endif
+18
View File
@@ -742,6 +742,24 @@
log_admin("[key_name_admin(usr)] has turned [key_name_admin(H)] into a skeleton")
href_list["datumrefresh"] = href_list["make_skeleton"]
else if(href_list["hallucinate"])
if(!check_rights(R_SERVER | R_EVENT))
return
var/mob/living/carbon/C = locateUID(href_list["hallucinate"])
if(!istype(C))
to_chat(usr, "<span class='warning'>This can only be used on instances of type /mob/living/carbon</span>")
return
var/haltype = input(usr, "Select the hallucination type:", "Hallucinate") as null|anything in subtypesof(/obj/effect/hallucination)
if(!haltype)
return
C.hallucinate(haltype)
message_admins("[key_name(usr)] has given [key_name(C)] the [haltype] hallucination")
log_admin("[key_name_admin(usr)] has given [key_name_admin(C)] the [haltype] hallucination")
href_list["datumrefresh"] = href_list["hallucinate"]
else if(href_list["offer_control"])
if(!check_rights(R_ADMIN)) return
+7
View File
@@ -50,6 +50,10 @@ GLOBAL_LIST_INIT(diseases, subtypesof(/datum/disease))
var/stage = 1
var/max_stages = 0
var/stage_prob = 4
/// The fraction of stages the virus must at least be at to show up on medical HUDs. Rounded up.
var/discovery_threshold = 0.5
/// If TRUE, this virus will show up on medical HUDs. Automatically set when it reaches mid-stage.
var/discovered = FALSE
//Other
var/list/viable_mobtypes = list() //typepaths of viable mobs
@@ -82,6 +86,9 @@ GLOBAL_LIST_INIT(diseases, subtypesof(/datum/disease))
if(!cure)
if(prob(stage_prob))
stage = min(stage + 1,max_stages)
if(!discovered && stage >= CEILING(max_stages * discovery_threshold, 1)) // Once we reach a late enough stage, medical HUDs can pick us up even if we regress
discovered = TRUE
affected_mob.med_hud_set_status()
else
if(prob(cure_chance))
stage = max(stage - 1, 1)
+4
View File
@@ -15,6 +15,7 @@
var/list/stage3 = list("You feel utterly plain.")
var/list/stage4 = list("You feel white bread.")
var/list/stage5 = list("Oh the humanity!")
var/transformation_text = null
var/new_form = /mob/living/carbon/human
/datum/disease/transformation/stage_act()
@@ -44,6 +45,8 @@
return
if(affected_mob.notransform)
return
if(transformation_text)
to_chat(affected_mob, transformation_text)
affected_mob.notransform = 1
affected_mob.canmove = 0
affected_mob.icon = null
@@ -243,4 +246,5 @@
stage3 = list("<span class='danger'>Your appendages are melting away.</span>", "<span class='danger'>Your limbs begin to lose their shape.</span>")
stage4 = list("<span class='danger'>You're ravenous.</span>")
stage5 = list("<span class='danger'>You have become a morph.</span>")
transformation_text = "<span class='userdanger'>This transformation does NOT make you an antagonist if you were not one already. If you were not an antagonist, you should not eat any steal objectives or the contents of the armory.</span>"
new_form = /mob/living/simple_animal/hostile/morph
+1
View File
@@ -4,6 +4,7 @@
. = ..()
var/obj/machinery/hologram/holopad/H = origin
H.move_hologram(eye_user, loc)
ai_detector_visible = FALSE // Holocalls dont trigger the Ai Detector
//this datum manages it's own references
+77 -12
View File
@@ -84,7 +84,7 @@
shoes = /obj/item/clothing/shoes/magboots/syndie
r_pocket = /obj/item/radio/uplink/nuclear
l_pocket = /obj/item/pinpointer/advpinpointer
l_hand = /obj/item/tank/jetpack/oxygen/harness
l_hand = /obj/item/tank/internals/oxygen/red
backpack_contents = list(
/obj/item/storage/box/survival_syndi = 1,
@@ -836,7 +836,7 @@
apply_to_card(I, H, get_all_accesses(), "Space Explorer")
/datum/outfit/admin/hardsuit
name = "Hardsuit Generic"
name = "Hardsuit - Generic"
back = /obj/item/tank/jetpack/oxygen
mask = /obj/item/clothing/mask/breath
shoes = /obj/item/clothing/shoes/magboots
@@ -857,34 +857,34 @@
apply_to_card(I, H, get_all_accesses(), "Hardsuit Tester")
/datum/outfit/admin/hardsuit/engineer
name = "Engineer Hardsuit"
name = "Hardsuit - Engineer"
suit = /obj/item/clothing/suit/space/hardsuit/engine
/datum/outfit/admin/hardsuit/ce
name = "CE Hardsuit"
name = "Hardsuit - CE"
suit = /obj/item/clothing/suit/space/hardsuit/engine/elite
shoes = /obj/item/clothing/shoes/magboots/advance
/datum/outfit/admin/hardsuit/mining
name = "Mining Hardsuit"
name = "Hardsuit - Mining"
suit = /obj/item/clothing/suit/space/hardsuit/mining
/datum/outfit/admin/hardsuit/syndi
name = "Syndi Hardsuit"
name = "Hardsuit - Syndi"
suit = /obj/item/clothing/suit/space/hardsuit/syndi
shoes = /obj/item/clothing/shoes/magboots/syndie
/datum/outfit/admin/hardsuit/wizard
name = "Wizard Hardsuit"
name = "Hardsuit - Wizard"
suit = /obj/item/clothing/suit/space/hardsuit/shielded/wizard
shoes = /obj/item/clothing/shoes/magboots
/datum/outfit/admin/hardsuit/medical
name = "Medical Hardsuit"
name = "Hardsuit - Medical"
suit = /obj/item/clothing/suit/space/hardsuit/medical
/datum/outfit/admin/hardsuit/atmos
name = "Atmos Hardsuit"
name = "Hardsuit - Atmos"
suit = /obj/item/clothing/suit/space/hardsuit/engine/atmos
@@ -1146,20 +1146,20 @@
apply_to_card(I, H, get_all_accesses(), "Wizard")
/datum/outfit/admin/wizard/red
name = "Red Wizard"
name = "Wizard - Red Wizard"
suit = /obj/item/clothing/suit/wizrobe/red
head = /obj/item/clothing/head/wizard/red
/datum/outfit/admin/wizard/marisa
name = "Marisa Wizard"
name = "Wizard - Marisa Wizard"
suit = /obj/item/clothing/suit/wizrobe/marisa
shoes = /obj/item/clothing/shoes/sandal/marisa
head = /obj/item/clothing/head/wizard/marisa
/datum/outfit/admin/wizard/arch
name = "Arch Wizard"
name = "Wizard - Arch Wizard"
suit = /obj/item/clothing/suit/wizrobe/magusred
head = /obj/item/clothing/head/wizard/magus
@@ -1223,3 +1223,68 @@
var/obj/item/radio/headset/R = H.l_ear
if(istype(R))
R.flags |= NODROP
/datum/outfit/admin/honksquad
name = "Honksquad"
uniform = /obj/item/clothing/under/rank/clown
mask = /obj/item/clothing/mask/gas/clown_hat
back = /obj/item/storage/backpack/clown
id = /obj/item/card/id/clown
backpack_contents = list(
/obj/item/storage/box/survival = 1,
/obj/item/bikehorn = 1,
/obj/item/stamp/clown = 1,
/obj/item/toy/crayon/rainbow = 1,
/obj/item/reagent_containers/spray/waterflower = 1,
/obj/item/reagent_containers/food/snacks/grown/banana = 1,
)
shoes = /obj/item/clothing/shoes/clown_shoes
suit = /obj/item/clothing/suit/storage/det_suit
pda = /obj/item/pda/clown
l_ear = /obj/item/radio/headset
r_pocket = /obj/item/reagent_containers/food/pill/patch/jestosterone
/datum/outfit/admin/honksquad/pre_equip(mob/living/carbon/human/H, visualsOnly = FALSE)
. = ..()
if(H.gender == FEMALE)
uniform = /obj/item/clothing/under/rank/clown/sexy
mask = /obj/item/clothing/mask/gas/clown_hat/sexy
if(prob(50))
// You have to do it like this to make it work with assoc lists without a runtime.
// Trust me.
backpack_contents.Add(/obj/item/gun/energy/clown)
backpack_contents[/obj/item/gun/energy/clown] = 1 // Amount. Not boolean. Do not TRUE this. You turkey.
else
backpack_contents.Add(/obj/item/gun/throw/piecannon)
backpack_contents[/obj/item/gun/throw/piecannon] = 1
/datum/outfit/admin/honksquad/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE)
. = ..()
if(visualsOnly)
return
// Setup their clumsy gene
H.dna.SetSEState(GLOB.clumsyblock, TRUE)
H.check_mutations = TRUE
// Setup their headset
var/obj/item/radio/R = H.l_ear
if(istype(R))
R.set_frequency(DTH_FREQ) // Clowns can be part of "special operations"
// And their PDA
var/obj/item/pda/P = H.wear_pda
if(istype(P))
P.owner = H.real_name
P.ownjob = "Clown"
P.name = "PDA-[H.real_name] ([P.ownjob])"
// And their ID
var/obj/item/card/id/I = H.wear_id
if(istype(I))
apply_to_card(I, H, list(ACCESS_CLOWN), "Clown")
H.sec_hud_set_ID()
+27 -27
View File
@@ -7,140 +7,140 @@
mask = /obj/item/clothing/mask/breath
/datum/outfit/plasmaman/bar
name = "Bartender Plasmaman"
name = "Plasmaman Bartender"
head = /obj/item/clothing/head/helmet/space/plasmaman/white
uniform = /obj/item/clothing/under/plasmaman/enviroslacks
/datum/outfit/plasmaman/chef
name = "Chef Plasmaman"
name = "Plasmaman Chef"
head = /obj/item/clothing/head/helmet/space/plasmaman/chef
uniform = /obj/item/clothing/under/plasmaman/chef
/datum/outfit/plasmaman/botany
name = "Botany Plasmaman"
name = "Plasmaman Botany"
head = /obj/item/clothing/head/helmet/space/plasmaman/botany
uniform = /obj/item/clothing/under/plasmaman/botany
/datum/outfit/plasmaman/librarian
name = "Librarian Plasmaman"
name = "Plasmaman Librarian"
head = /obj/item/clothing/head/helmet/space/plasmaman/librarian
uniform = /obj/item/clothing/under/plasmaman/librarian
/datum/outfit/plasmaman/chaplain
name = "Chaplain Plasmaman"
name = "Plasmaman Chaplain"
head = /obj/item/clothing/head/helmet/space/plasmaman/chaplain
uniform = /obj/item/clothing/under/plasmaman/chaplain
/datum/outfit/plasmaman/janitor
name = "Janitor Plasmaman"
name = "Plasmaman Janitor"
head = /obj/item/clothing/head/helmet/space/plasmaman/janitor
uniform = /obj/item/clothing/under/plasmaman/janitor
/datum/outfit/plasmaman/security
name = "Security Plasmaman"
name = "Plasmaman Security"
head = /obj/item/clothing/head/helmet/space/plasmaman/security
uniform = /obj/item/clothing/under/plasmaman/security
/datum/outfit/plasmaman/detective
name = "Detective Plasmaman"
name = "Plasmaman Detective"
head = /obj/item/clothing/head/helmet/space/plasmaman/white
uniform = /obj/item/clothing/under/plasmaman/enviroslacks
l_ear = /obj/item/radio/headset/headset_sec
/datum/outfit/plasmaman/warden
name = "Warden Plasmaman"
name = "Plasmaman Warden"
head = /obj/item/clothing/head/helmet/space/plasmaman/security/warden
uniform = /obj/item/clothing/under/plasmaman/security/warden
/datum/outfit/plasmaman/hos
name = "Head of Security Plasmaman"
name = "Plasmaman Head of Security"
head = /obj/item/clothing/head/helmet/space/plasmaman/security/hos
uniform = /obj/item/clothing/under/plasmaman/security/hos
/datum/outfit/plasmaman/cargo
name = "Cargo Plasmaman"
name = "Plasmaman Cargo"
head = /obj/item/clothing/head/helmet/space/plasmaman/cargo
uniform = /obj/item/clothing/under/plasmaman/cargo
/datum/outfit/plasmaman/mining
name = "Mining Plasmaman"
name = "Plasmaman Mining"
head = /obj/item/clothing/head/helmet/space/plasmaman/mining
uniform = /obj/item/clothing/under/plasmaman/mining
/datum/outfit/plasmaman/medical
name = "Medical Plasmaman"
name = "Plasmaman Medical"
head = /obj/item/clothing/head/helmet/space/plasmaman/medical
uniform = /obj/item/clothing/under/plasmaman/medical
/datum/outfit/plasmaman/cmo
name = "Chief Medical Officer Plasmaman"
name = "Plasmaman Chief Medical Officer"
head = /obj/item/clothing/head/helmet/space/plasmaman/cmo
uniform = /obj/item/clothing/under/plasmaman/cmo
/datum/outfit/plasmaman/viro
name = "Virology Plasmaman"
name = "Plasmaman Virology"
head = /obj/item/clothing/head/helmet/space/plasmaman/viro
uniform = /obj/item/clothing/under/plasmaman/viro
/datum/outfit/plasmaman/chemist
name = "Chemist Plasmaman"
name = "Plasmaman Chemist"
head = /obj/item/clothing/head/helmet/space/plasmaman/chemist
uniform = /obj/item/clothing/under/plasmaman/chemist
/datum/outfit/plasmaman/genetics
name = "Genetics Plasmaman"
name = "Plasmaman Genetics"
head = /obj/item/clothing/head/helmet/space/plasmaman/genetics
uniform = /obj/item/clothing/under/plasmaman/genetics
/datum/outfit/plasmaman/science
name = "Science Plasmaman"
name = "Plasmaman Science"
head = /obj/item/clothing/head/helmet/space/plasmaman/science
uniform = /obj/item/clothing/under/plasmaman/science
/datum/outfit/plasmaman/rd
name = "Research Director Plasmaman"
name = "Plasmaman Research Director"
head = /obj/item/clothing/head/helmet/space/plasmaman/rd
uniform = /obj/item/clothing/under/plasmaman/rd
/datum/outfit/plasmaman/robotics
name = "Robotics Plasmaman"
name = "Plasmaman Robotics"
head = /obj/item/clothing/head/helmet/space/plasmaman/robotics
uniform = /obj/item/clothing/under/plasmaman/robotics
/datum/outfit/plasmaman/engineering
name = "Engineering Plasmaman"
name = "Plasmaman Engineering"
head = /obj/item/clothing/head/helmet/space/plasmaman/engineering
uniform = /obj/item/clothing/under/plasmaman/engineering
/datum/outfit/plasmaman/ce
name = "Chief Engineer Plasmaman"
name = "Plasmaman Chief Engineer"
head = /obj/item/clothing/head/helmet/space/plasmaman/engineering/ce
uniform = /obj/item/clothing/under/plasmaman/engineering/ce
/datum/outfit/plasmaman/atmospherics
name = "Atmospherics Plasmaman"
name = "Plasmaman Atmospherics"
head = /obj/item/clothing/head/helmet/space/plasmaman/atmospherics
uniform = /obj/item/clothing/under/plasmaman/atmospherics
@@ -160,25 +160,25 @@
mask = /obj/item/clothing/mask/gas/clown_hat
/datum/outfit/plasmaman/hop
name = "Head of Personnel Plasmaman"
name = "Plasmaman Head of Personnel"
head = /obj/item/clothing/head/helmet/space/plasmaman/hop
uniform = /obj/item/clothing/under/plasmaman/hop
/datum/outfit/plasmaman/captain
name = "Captain Plasmaman"
name = "Plasmaman Captain"
head = /obj/item/clothing/head/helmet/space/plasmaman/captain
uniform = /obj/item/clothing/under/plasmaman/captain
/datum/outfit/plasmaman/blueshield
name = "Blueshield Plasmaman"
name = "Plasmaman Blueshield"
head = /obj/item/clothing/head/helmet/space/plasmaman/blueshield
uniform = /obj/item/clothing/under/plasmaman/blueshield
/datum/outfit/plasmaman/wizard
name = "Wizard Plasmaman"
name = "Plasmaman Wizard"
head = /obj/item/clothing/head/helmet/space/plasmaman/wizard
uniform = /obj/item/clothing/under/plasmaman/wizard
+1 -1
View File
@@ -503,8 +503,8 @@ GLOBAL_LIST_INIT(spells, typesof(/obj/effect/proc_holder/spell))
revert_cast(user)
return FALSE
perform(targets, user = user, make_attack_logs = create_logs)
remove_ranged_ability(user)
perform(targets, user = user, make_attack_logs = create_logs)
return TRUE
/* Checks if a target is valid
+4 -3
View File
@@ -572,9 +572,10 @@ GLOBAL_LIST_INIT(all_supply_groups, list(SUPPLY_EMERGENCY,SUPPLY_SECURITY,SUPPLY
containername = "electrical maintenance crate"
/datum/supply_packs/vending/engivend
name = "EngiVend Supply Crate"
cost = 15
contains = list(/obj/item/vending_refill/engivend)
name = "Engineering Vendor Supply Crate"
cost = 20
contains = list(/obj/item/vending_refill/engivend,
/obj/item/vending_refill/youtool)
containername = "engineering supply crate"
/datum/supply_packs/engineering/powergamermitts
+2 -1
View File
@@ -1017,6 +1017,7 @@ GLOBAL_LIST_INIT(uplink_items, subtypesof(/datum/uplink_item))
cost = 11
surplus = 0
cant_discount = TRUE
hijack_only = TRUE
/datum/uplink_item/explosives/emp_bomb
name = "EMP bomb"
@@ -1426,7 +1427,7 @@ GLOBAL_LIST_INIT(uplink_items, subtypesof(/datum/uplink_item))
name = "Power Sink"
desc = "When screwed to wiring attached to an electric grid, then activated, this large device places excessive load on the grid, causing a stationwide blackout. The sink cannot be carried because of its excessive size. Ordering this sends you a small beacon that will teleport the power sink to your location on activation."
reference = "PS"
item = /obj/item/powersink
item = /obj/item/radio/beacon/syndicate/power_sink
cost = 10
/datum/uplink_item/device_tools/singularity_beacon
+9 -1
View File
@@ -1072,7 +1072,7 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons)
Returning TRUE here will override the above proc's result.
*/
/atom/proc/CanAStarPassTo(ID, dir, obj/destination)
return TRUE
return FALSE
/** Call this when you want to present a renaming prompt to the user.
@@ -1139,3 +1139,11 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons)
else
name = "[prefix][t]"
return t
/atom/proc/set_angle(degrees)
var/matrix/M = matrix()
M.Turn(degrees)
// If we aint 0, make it NN transform
if(degrees)
appearance_flags |= PIXEL_SCALE
transform = M
+2
View File
@@ -90,6 +90,8 @@
/mob/living/carbon/proc/has_virus()
for(var/thing in viruses)
var/datum/disease/D = thing
if(!D.discovered) // Early-stage viruses should not show up on med HUD (though health analywers can still pick them up)
continue
if((!(D.visibility_flags & HIDDEN_SCANNER)) && (D.severity != NONTHREAT))
return TRUE
return FALSE
+1
View File
@@ -185,6 +185,7 @@
activation_messages = list("You feel smarter.")
deactivation_messages = list("You feel dumber.")
instability = GENE_INSTABILITY_MAJOR
traits_to_add = list(TRAIT_TELEKINESIS)
activation_prob = 15
/datum/mutation/tk/New()
@@ -84,7 +84,7 @@
traitorcount += 1
continue
if(ishuman(player) || isAI(player))
if((ROLE_TRAITOR in player.client.prefs.be_special) && !player.client.skip_antag && !jobban_isbanned(player, ROLE_TRAITOR) && !jobban_isbanned(player, "Syndicate"))
if((ROLE_TRAITOR in player.client.prefs.be_special) && !player.client.skip_antag && !jobban_isbanned(player, ROLE_TRAITOR) && !jobban_isbanned(player, ROLE_SYNDICATE))
possible_traitors += player.mind
for(var/datum/mind/player in possible_traitors)
for(var/job in restricted_jobs)
@@ -144,7 +144,7 @@
if(SSshuttle.emergency.mode >= SHUTTLE_ESCAPE)
return
//message_admins("Late Join Check")
if(character.client && (ROLE_TRAITOR in character.client.prefs.be_special) && !character.client.skip_antag && !jobban_isbanned(character, ROLE_TRAITOR) && !jobban_isbanned(character, "Syndicate"))
if(character.client && (ROLE_TRAITOR in character.client.prefs.be_special) && !character.client.skip_antag && !jobban_isbanned(character, ROLE_TRAITOR) && !jobban_isbanned(character, ROLE_SYNDICATE))
//message_admins("Late Joiner has Be Syndicate")
//message_admins("Checking number of players")
var/playercount = 0
+1 -1
View File
@@ -57,7 +57,7 @@ GLOBAL_LIST_EMPTY(blob_nodes)
/datum/game_mode/blob/proc/get_blob_candidates()
var/list/candidates = list()
for(var/mob/living/carbon/human/player in GLOB.player_list)
if(!player.stat && player.mind && !player.client.skip_antag && !player.mind.special_role && !jobban_isbanned(player, "Syndicate") && (ROLE_BLOB in player.client.prefs.be_special))
if(!player.stat && player.mind && !player.client.skip_antag && !player.mind.special_role && !jobban_isbanned(player, ROLE_SYNDICATE) && (ROLE_BLOB in player.client.prefs.be_special))
candidates += player
return candidates
@@ -93,5 +93,7 @@ the same goes for Remove(). if you override Remove(), call parent or else your p
/datum/action/changeling/proc/transform_dna(mob/living/carbon/human/H, datum/dna/D)
if(!D)
return
H.change_dna(D, TRUE)
var/changesSpecies = TRUE
if (H.dna.species.name == D.species.name)
changesSpecies = FALSE
H.change_dna(D, changesSpecies)
@@ -1,11 +1,11 @@
/datum/action/changeling/digitalcamo
name = "Digital Camouflage"
desc = "By evolving the ability to distort our form and proprotions, we defeat common altgorithms used to detect lifeforms on cameras."
helptext = "We cannot be tracked by camera while using this skill. However, humans looking at us will find us... uncanny."
helptext = "We cannot be tracked by camera while using this skill."
button_icon_state = "digital_camo"
dna_cost = 1
//Prevents AIs tracking you but makes you easily detectable to the human-eye.
//Prevents AIs tracking you.
/datum/action/changeling/digitalcamo/sting_action(mob/user)
if(user.digitalcamo)
@@ -243,7 +243,6 @@
damage_type = BRUTE
range = 8
hitsound = 'sound/weapons/thudswoosh.ogg'
var/chain
var/obj/item/ammo_casing/magic/tentacle/source //the item that shot it
/obj/item/projectile/tentacle/New(obj/item/ammo_casing/magic/tentacle/tentacle_casing)
@@ -7,51 +7,7 @@
//Revive from regenerative stasis
/datum/action/changeling/revive/sting_action(mob/living/carbon/user)
user.setToxLoss(0, FALSE)
user.setOxyLoss(0, FALSE)
user.setCloneLoss(0, FALSE)
user.setBrainLoss(0, FALSE)
user.SetParalysis(0, FALSE)
user.SetStunned(0, FALSE)
user.SetWeakened(0, FALSE)
user.radiation = 0
user.SetEyeBlind(0, FALSE)
user.SetEyeBlurry(0, FALSE)
user.RestoreEars()
user.heal_overall_damage(user.getBruteLoss(), user.getFireLoss(), updating_health = FALSE)
user.cure_blind(null, FALSE)
user.CureDeaf()
user.cure_nearsighted(null, FALSE)
user.reagents.clear_reagents()
user.germ_level = 0
user.timeofdeath = 0
if(ishuman(user))
var/mob/living/carbon/human/H = user
H.restore_blood()
H.next_pain_time = 0
H.dna.species.create_organs(H)
// Now that recreating all organs is necessary, the rest of this organ stuff probably
// isn't, but I don't want to remove it, just in case.
for(var/organ_name in H.bodyparts_by_name)
var/obj/item/organ/external/O = H.bodyparts_by_name[organ_name]
if(!O)
continue
O.brute_dam = 0
O.burn_dam = 0
O.damage_state = "00"
O.germ_level = 0
QDEL_NULL(O.hidden)
O.open = 0
O.internal_bleeding = FALSE
O.perma_injury = 0
O.status = 0
O.trace_chemicals.Cut()
for(var/obj/item/organ/internal/IO in H.internal_organs)
IO.rejuvenate()
IO.trace_chemicals.Cut()
H.remove_all_embedded_objects()
for(var/datum/disease/critical/C in user.viruses)
C.cure()
user.revive()
REMOVE_TRAIT(user, TRAIT_FAKEDEATH, "changeling")
user.updatehealth("revive sting")
user.update_blind_effects()
+6 -2
View File
@@ -848,8 +848,12 @@
uses += max(1, temp)
/obj/item/melee/blood_magic/manipulator/attack_self(mob/living/user)
var/list/options = list("Blood Orb (50)", "Blood Recharge (75)", "Blood Spear (150)", "Blood Bolt Barrage (300)")
var/choice = input(user, "Choose a greater blood rite...", "Greater Blood Rites") as null|anything in options
var/list/options = list("Blood Orb (50)" = image(icon = 'icons/obj/cult.dmi', icon_state = "summoning_orb"),
"Blood Recharge (75)" = image(icon = 'icons/mob/actions/actions_cult.dmi', icon_state = "blood_charge"),
"Blood Spear (150)" = image(icon = 'icons/mob/actions/actions_cult.dmi', icon_state = "bloodspear"),
"Blood Bolt Barrage (300)" = image(icon = 'icons/mob/actions/actions_cult.dmi', icon_state = "blood_barrage"))
var/choice = show_radial_menu(user, src, options)
switch(choice)
if("Blood Orb (50)")
if(uses < BLOOD_ORB_COST)
+6
View File
@@ -130,6 +130,9 @@ To draw a rune, use a ritual dagger.
visible_message("<span class='danger'>[src] suddenly appears!</span>")
alpha = initial(alpha)
/obj/effect/rune/is_cleanable()
return TRUE
/*
There are a few different procs each rune runs through when a cultist activates it.
@@ -991,6 +994,9 @@ structure_check() searches for nearby cultist structures required for the invoca
/obj/effect/rune/narsie/cult_conceal() //can't hide this, and you wouldn't want to
return
/obj/effect/rune/narsie/is_cleanable() //No, you can't just yeet a cleaning grenade to remove it.
return FALSE
/obj/effect/rune/narsie/invoke(list/invokers)
if(used)
return
+1 -1
View File
@@ -238,7 +238,7 @@
// Assemble a list of active players without jobbans.
for(var/mob/new_player/player in GLOB.player_list)
if(player.client && player.ready && player.has_valid_preferences())
if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, roletext))
if(!jobban_isbanned(player, ROLE_SYNDICATE) && !jobban_isbanned(player, roletext))
if(player_old_enough_antag(player.client,role))
players += player
@@ -128,8 +128,8 @@
if(cannotPossess(user))
to_chat(user, "<span class='boldnotice'>Upon using the antagHUD you forfeited the ability to join the round.</span>")
return
if(jobban_isbanned(user, "Syndicate"))
to_chat(user, "<span class='warning'>You are banned from antagonists!</span>")
if(jobban_isbanned(user, ROLE_SYNDICATE) || jobban_isbanned(user, ROLE_BORER))
to_chat(user, "<span class='warning'>You are banned from playing this antagonist!</span>")
return
if(key)
return
@@ -30,9 +30,8 @@
/mob/living/simple_animal/hostile/guardian/fire/AttackingTarget()
. = ..()
if(toggle)
if(. && ishuman(target) && !summoner)
spawn(0)
new /obj/effect/hallucination/delusion(target.loc, target, force_kind = "custom", duration = 200, skip_nearby = 0, custom_icon = icon_state, custom_icon_file = icon)
if(. && iscarbon(target))
new /obj/effect/hallucination/delusion(get_turf(target), target, icon, icon_state)
else
if(prob(45))
if(ismovable(target))
@@ -10,6 +10,7 @@
melee_damage_lower = 10
melee_damage_upper = 10
damage_transfer = 0.9
can_strip = TRUE
projectiletype = /obj/item/projectile/guardian
ranged_cooldown_time = 5 //fast!
projectilesound = 'sound/effects/hit_on_shattered_glass.ogg'
@@ -35,6 +36,7 @@
alpha = 255
range = 13
incorporeal_move = 0
can_strip = TRUE
to_chat(src, "<span class='danger'>You switch to combat mode.</span>")
toggle = FALSE
else
@@ -46,6 +48,7 @@
alpha = 60
range = 255
incorporeal_move = 1
can_strip = FALSE //spiritual pickpocketting is forbidden
to_chat(src, "<span class='danger'>You switch to scout mode.</span>")
toggle = TRUE
else
+28 -24
View File
@@ -188,6 +188,9 @@
M.regenerate_icons()
M.update_body()
if(!the_bomb)
the_bomb = locate(/obj/machinery/nuclearbomb/syndicate) in GLOB.poi_list
if(the_bomb)
synd_mind.store_memory("<B>Syndicate [the_bomb.name] Code</B>: [the_bomb.r_code]")
to_chat(synd_mind.current, "The code for \the [the_bomb.name] is: <B>[the_bomb.r_code]</B>")
@@ -436,54 +439,55 @@
return newname
/datum/game_mode/nuclear/set_scoreboard_gvars()
/datum/game_mode/nuclear/set_scoreboard_vars()
var/datum/scoreboard/scoreboard = SSticker.score
var/foecount = 0
for(var/datum/mind/M in SSticker.mode.syndicates)
foecount++
if(!M || !M.current)
GLOB.score_opkilled++
scoreboard.score_ops_killed++
continue
if(M.current.stat == DEAD)
GLOB.score_opkilled++
scoreboard.score_ops_killed++
else if(M.current.restrained())
GLOB.score_arrested++
scoreboard.score_arrested++
if(foecount == GLOB.score_arrested)
GLOB.score_allarrested = 1
if(foecount == scoreboard.score_arrested)
scoreboard.all_arrested = TRUE // how the hell did they manage that
for(var/obj/machinery/nuclearbomb/nuke in GLOB.machines)
if(nuke.r_code == "Nope") continue
var/obj/machinery/nuclearbomb/syndicate/nuke = locate() in GLOB.poi_list
if(nuke?.r_code != "Nope")
var/area/A = get_area(nuke)
var/list/thousand_penalty = list(/area/solar)
var/list/fiftythousand_penalty = list(/area/security/main, /area/security/brig, /area/security/armoury, /area/security/checkpoint2)
if(is_type_in_list(A, thousand_penalty))
GLOB.score_nuked_penalty = 1000
scoreboard.nuked_penalty = 1000
else if(is_type_in_list(A, fiftythousand_penalty))
GLOB.score_nuked_penalty = 50000
scoreboard.nuked_penalty = 50000
else if(istype(A, /area/engine))
GLOB.score_nuked_penalty = 100000
scoreboard.nuked_penalty = 100000
else
GLOB.score_nuked_penalty = 10000
scoreboard.nuked_penalty = 10000
break
var/killpoints = GLOB.score_opkilled * 250
var/arrestpoints = GLOB.score_arrested * 1000
GLOB.score_crewscore += killpoints
GLOB.score_crewscore += arrestpoints
if(GLOB.score_nuked)
GLOB.score_crewscore -= GLOB.score_nuked_penalty
var/killpoints = scoreboard.score_ops_killed * 250
var/arrestpoints = scoreboard.score_arrested * 1000
scoreboard.crewscore += killpoints
scoreboard.crewscore += arrestpoints
if(scoreboard.nuked)
scoreboard.crewscore -= scoreboard.nuked_penalty
/datum/game_mode/nuclear/get_scoreboard_stats()
var/datum/scoreboard/scoreboard = SSticker.score
var/foecount = 0
var/crewcount = 0
@@ -530,11 +534,11 @@
dat += "<br>"
dat += "<b>Operatives Arrested:</b> [GLOB.score_arrested] ([GLOB.score_arrested * 1000] Points)<br>"
dat += "<b>All Operatives Arrested:</b> [GLOB.score_allarrested ? "Yes" : "No"] (Score tripled)<br>"
dat += "<b>Operatives Arrested:</b> [scoreboard.score_arrested] ([scoreboard.score_arrested * 1000] Points)<br>"
dat += "<b>All Operatives Arrested:</b> [scoreboard.all_arrested ? "Yes" : "No"] (Score tripled)<br>"
dat += "<b>Operatives Killed:</b> [GLOB.score_opkilled] ([GLOB.score_opkilled * 1000] Points)<br>"
dat += "<b>Station Destroyed:</b> [GLOB.score_nuked ? "Yes" : "No"] (-[GLOB.score_nuked_penalty] Points)<br>"
dat += "<b>Operatives Killed:</b> [scoreboard.score_ops_killed] ([scoreboard.score_ops_killed * 1000] Points)<br>"
dat += "<b>Station Destroyed:</b> [scoreboard.nuked ? "Yes" : "No"] (-[scoreboard.nuked_penalty] Points)<br>"
dat += "<hr>"
return dat
+27 -26
View File
@@ -370,44 +370,45 @@
text += "<br>"
to_chat(world, text)
/datum/game_mode/revolution/set_scoreboard_gvars()
/datum/game_mode/revolution/set_scoreboard_vars()
var/datum/scoreboard/scoreboard = SSticker.score
var/foecount = 0
for(var/datum/mind/M in SSticker.mode.head_revolutionaries)
foecount++
if(!M || !M.current)
GLOB.score_opkilled++
scoreboard.score_ops_killed++
continue
if(M.current.stat == DEAD)
GLOB.score_opkilled++
scoreboard.score_ops_killed++
else if(M.current.restrained())
GLOB.score_arrested++
scoreboard.score_arrested++
if(foecount == GLOB.score_arrested)
GLOB.score_allarrested = 1
if(foecount == scoreboard.score_arrested)
scoreboard.all_arrested = TRUE
for(var/thing in GLOB.human_list)
var/mob/living/carbon/human/player = thing
if(player.mind)
var/role = player.mind.assigned_role
if(role in list("Captain", "Head of Security", "Head of Personnel", "Chief Engineer", "Research Director"))
if(player.stat == DEAD)
GLOB.score_deadcommand++
for(var/I in GLOB.human_list)
var/mob/living/carbon/human/H = I
if(H.stat == DEAD && H.mind?.assigned_role)
if(H.mind.assigned_role in list("Captain", "Head of Security", "Head of Personnel", "Chief Engineer", "Research Director"))
scoreboard.score_dead_command++
var/arrestpoints = GLOB.score_arrested * 1000
var/killpoints = GLOB.score_opkilled * 500
var/comdeadpts = GLOB.score_deadcommand * 500
if(GLOB.score_traitorswon)
GLOB.score_crewscore -= 10000
var/arrestpoints = scoreboard.score_arrested * 1000
var/killpoints = scoreboard.score_ops_killed * 500
var/comdeadpts = scoreboard.score_dead_command * 500
if(scoreboard.score_greentext)
scoreboard.crewscore -= 10000
GLOB.score_crewscore += arrestpoints
GLOB.score_crewscore += killpoints
GLOB.score_crewscore -= comdeadpts
scoreboard.crewscore += arrestpoints
scoreboard.crewscore += killpoints
scoreboard.crewscore -= comdeadpts
/datum/game_mode/revolution/get_scoreboard_stats()
var/datum/scoreboard/scoreboard = SSticker.score
var/foecount = 0
var/comcount = 0
var/revcount = 0
@@ -444,12 +445,12 @@
dat += "<b>Number of Surviving Loyal Crew:</b> [loycount]<br>"
dat += "<br>"
dat += "<b>Revolution Heads Arrested:</b> [GLOB.score_arrested] ([GLOB.score_arrested * 1000] Points)<br>"
dat += "<b>All Revolution Heads Arrested:</b> [GLOB.score_allarrested ? "Yes" : "No"] (Score tripled)<br>"
dat += "<b>Revolution Heads Arrested:</b> [scoreboard.score_arrested] ([scoreboard.score_arrested * 1000] Points)<br>"
dat += "<b>All Revolution Heads Arrested:</b> [scoreboard.all_arrested ? "Yes" : "No"] (Score tripled)<br>"
dat += "<b>Revolution Heads Slain:</b> [GLOB.score_opkilled] ([GLOB.score_opkilled * 500] Points)<br>"
dat += "<b>Command Staff Slain:</b> [GLOB.score_deadcommand] (-[GLOB.score_deadcommand * 500] Points)<br>"
dat += "<b>Revolution Successful:</b> [GLOB.score_traitorswon ? "Yes" : "No"] (-[GLOB.score_traitorswon * 10000] Points)<br>"
dat += "<b>Revolution Heads Slain:</b> [scoreboard.score_ops_killed] ([scoreboard.score_ops_killed * 500] Points)<br>"
dat += "<b>Command Staff Slain:</b> [scoreboard.score_dead_command] (-[scoreboard.score_dead_command * 500] Points)<br>"
dat += "<b>Revolution Successful:</b> [scoreboard.score_greentext ? "Yes" : "No"] (-[scoreboard.score_greentext * 10000] Points)<br>"
dat += "<HR>"
return dat
+237 -163
View File
@@ -1,3 +1,5 @@
GLOBAL_VAR(scoreboard) // Variable to save the scoreboard string once it's been generated
//Thresholds for Score Ratings
#define SINGULARITY_DESERVES_BETTER -3500
#define SINGULARITY_FODDER -3000
@@ -14,190 +16,275 @@
#define PRIDE_OF_SCIENCE 4000
#define NANOTRANSEN_FINEST 5000
/datum/controller/subsystem/ticker/proc/scoreboard()
//Print a list of antagonists to the server log
/datum/scoreboard
/// Overall combined score for the whole round.
var/crewscore = 0
/// How many useful items have cargo shipped out?
var/score_things_shipped = 0
/// How many harvests have hydroponics done?
var/score_things_harvested = 0
/// How much ore has been mined on the mining z level?
var/score_ore_mined = 0
/// How much research was done by science?
var/score_research_done = 0
/// How many random events did the station survive?
var/score_events_endured = 0
/// How many APCs have poor charge?
var/score_power_loss = 0
/// How many people got out alive?
var/score_escapees = 0
/// How many people /didn't/ get out alive?
var/score_dead_crew = 0
/// How much blood, puke, stains etc went uncleaned?
var/score_mess = 0
/// How many meals were made?
var/score_meals = 0
/// How many rampant, uncured diseases are on board the station?
var/score_disease = 0
/// How many command members died? (Revolution)
var/score_dead_command = 0
/// How many antagonists are alive in the brig? (Nuke ops & Revolution)
var/score_arrested = 0
/// How many operatives were killed? (Nuke ops & Revolution)
var/score_ops_killed = 0
/// How much noms were had by the crew?
var/score_food_eaten = 0
/// How many times was the clown punched, struck, or otherwise maligned?
var/score_clown_abuse = 0
// Booleans //
/// Were the antagonists successful?
var/score_greentext = FALSE
/// Did the crew catch all of the antags alive?
var/all_arrested = FALSE
/// Is the NAD safe and secure?
var/disc_secure = FALSE
// Points penalties/bonuses //
/// If all APCs on the station are running optimally, big bonus.
var/power_bonus = FALSE
/// If there are no messes on the station anywhere, huge bonus.
var/mess_bonus = FALSE
/// If the AI is dead, big points penalty.
var/dead_ai = FALSE
/// Was the station blown into little bits?
var/nuked = FALSE
/// Points penalty for being blown to little bits.
var/nuked_penalty = 0
// Player Stats //
/// What was the name of the richest person on the shuttle?
var/richest_name = ""
/// What was the ckey of the richest person on the shuttle?
var/richest_key = ""
/// What was the job of the richest person on the shuttle?
var/richest_job = ""
/// How much money did the richest person on the shuttle have?
var/richest_cash = 0
/// What was the name of the most injured person on the shuttle?
var/damaged_name
/// What was the ckey of the most injured person on the shuttle?
var/damaged_key
/// What was the job of the most injured person on the shuttle?
var/damaged_job
/// How damaged was the most injured person on the shuttle?
var/damaged_health
/datum/scoreboard/proc/scoreboard()
// Print a list of antagonists to the server log.
log_antags()
for(var/_I in GLOB.mob_list)
var/mob/M = _I
if(is_station_level(M.z))
check_station_player(M)
else if(SSshuttle.emergency.mode >= SHUTTLE_ENDGAME && istype(get_area(M), SSshuttle.emergency.areaInstance))
check_shuttle_player(M)
check_apc_power()
check_cleanables()
generate_scoreboard()
/datum/scoreboard/proc/log_antags()
var/list/total_antagonists = list()
//Look into all mobs in world, dead or alive
for(var/datum/mind/Mind in SSticker.minds)
var/temprole = Mind.special_role
if(temprole) //if they are an antagonist of some sort.
if(temprole in total_antagonists) //If the role exists already, add the name to it
total_antagonists[temprole] += ", [Mind.name]([Mind.key])"
else
total_antagonists.Add(temprole) //If the role doesnt exist in the list, create it and add the mob
total_antagonists[temprole] += ": [Mind.name]([Mind.key])"
// Look into all mobs in the world, dead or alive
for(var/mind in SSticker.minds)
var/datum/mind/M = mind
var/role = M.special_role
//Now print them all into the log!
// If they're an antagonist of some sort.
if(role)
if(total_antagonists[role]) // If the role exists already, add the name to it.
total_antagonists[role] += ", [M.name]([M.key])"
else // If the role doesn't exist in the list, create it and add the mob
total_antagonists[role] += ": [M.name]([M.key])"
// Now print them all into the log!
log_game("Antagonists at round end were...")
for(var/i in total_antagonists)
log_game("[i]s[total_antagonists[i]].")
// Score Calculation and Display
// Who is alive/dead, who escaped
for(var/mob/living/silicon/ai/I in GLOB.mob_list)
if(I.stat == DEAD && is_station_level(I.z))
GLOB.score_deadaipenalty++
GLOB.score_deadcrew++
for(var/thing in GLOB.human_list)
var/mob/living/carbon/human/I = thing
if(I.stat == DEAD && is_station_level(I.z))
GLOB.score_deadcrew++
if(SSshuttle.emergency.mode >= SHUTTLE_ENDGAME)
for(var/mob/living/player in GLOB.mob_list)
if(player.client)
if(player.stat != DEAD)
var/turf/location = get_turf(player.loc)
var/area/escape_zone = locate(/area/shuttle/escape)
if(location in escape_zone)
GLOB.score_escapees++
for(var/I in total_antagonists)
log_game("[I]s[total_antagonists[I]].")
/datum/scoreboard/proc/check_station_player(mob/M)
if(!is_station_level(M.z) || M.stat < DEAD)
return
if(isAI(M))
dead_ai = TRUE
score_dead_crew++
else if(ishuman(M))
score_dead_crew++
var/cash_score = 0
var/dmg_score = 0
/datum/scoreboard/proc/check_shuttle_player(mob/M)
if(!M.mind || M.stat == DEAD || !ishuman(M))
return
var/mob/living/carbon/human/H = M
if(SSshuttle.emergency.mode >= SHUTTLE_ENDGAME)
for(var/thing in GLOB.human_list)
var/mob/living/carbon/human/E = thing
cash_score = 0
dmg_score = 0
var/turf/location = get_turf(E.loc)
var/area/escape_zone = SSshuttle.emergency.areaInstance
score_escapees++
if(E.stat != DEAD && (location in escape_zone)) // Escapee Scores
cash_score = get_score_container_worth(E)
var/cash_score = get_score_container_worth(H)
if(cash_score > richest_cash)
richest_cash = cash_score
richest_name = H.real_name
richest_job = H.job
richest_key = H.key
if(cash_score > GLOB.score_richestcash)
GLOB.score_richestcash = cash_score
GLOB.score_richestname = E.real_name
GLOB.score_richestjob = E.job
GLOB.score_richestkey = E.key
var/damage_score = H.getBruteLoss() + H.getFireLoss() + H.getToxLoss() + H.getOxyLoss()
if(damage_score > damaged_health)
damaged_health = damage_score
damaged_name = H.real_name
damaged_job = H.job
damaged_key = H.key
dmg_score = E.getBruteLoss() + E.getFireLoss() + E.getToxLoss() + E.getOxyLoss()
if(dmg_score > GLOB.score_dmgestdamage)
GLOB.score_dmgestdamage = dmg_score
GLOB.score_dmgestname = E.real_name
GLOB.score_dmgestjob = E.job
GLOB.score_dmgestkey = E.key
// A recursive function to properly determine the wealthiest escapee
/datum/scoreboard/proc/get_score_container_worth(atom/C, level = 0)
. = 0
if(level >= 5)
// in case the containers recurse or something
return 0
if(SSticker && SSticker.mode)
SSticker.mode.set_scoreboard_gvars()
for(var/obj/item/card/id/id in C.contents)
var/datum/money_account/A = get_money_account(id.associated_account_number)
// has an account?
if(A)
. += A.money
for(var/obj/item/stack/spacecash/cash in C.contents)
. += cash.amount
for(var/obj/item/storage/S in C.contents)
. += .(S, level + 1)
/datum/scoreboard/proc/check_apc_power()
for(var/_A in GLOB.apcs)
var/obj/machinery/power/apc/A = _A
if(!is_station_level(A.z))
continue
var/obj/item/stock_parts/cell/C = A.cell
if(!C || C.charge < 2300)
score_power_loss++ //200 charge leeway
/datum/scoreboard/proc/check_cleanables()
for(var/obj/effect/decal/cleanable/C in world)
if(!is_station_level(C.z))
continue
if(istype(C, /obj/effect/decal/cleanable/blood/gibs))
score_mess += 3
else if(istype(C, /obj/effect/decal/cleanable/blood))
score_mess += 1
else if(istype(C, /obj/effect/decal/cleanable/vomit))
score_mess += 1
// Check station's power levels
for(var/thing in GLOB.apcs)
var/obj/machinery/power/apc/A = thing
if(!is_station_level(A.z)) continue
for(var/obj/item/stock_parts/cell/C in A.contents)
if(C.charge < 2300)
GLOB.score_powerloss++ //200 charge leeway
/datum/scoreboard/proc/generate_scoreboard()
// Point modifiers
var/points_events_endured = score_events_endured * 50
var/points_research_done = score_research_done * 30
var/points_disease = score_disease * 30
var/points_dead_crew = score_dead_crew * 25
var/points_escapees = score_escapees * 25
var/points_power_loss = score_power_loss * 20
var/points_things_harvested = score_things_harvested * 5
var/points_things_shipped = score_things_shipped * 5
var/points_meals = score_meals * 5
var/points_ore_mined = score_ore_mined * 2
// Bonuses
crewscore += points_events_endured
crewscore += points_research_done
crewscore += points_escapees
crewscore += points_things_harvested
crewscore += points_things_shipped
crewscore += points_meals
crewscore += points_ore_mined
// Check how much uncleaned mess is on the station
for(var/obj/effect/decal/cleanable/M in world)
if(!is_station_level(M.z)) continue
if(istype(M, /obj/effect/decal/cleanable/blood/gibs))
GLOB.score_mess += 3
if(!score_power_loss)
crewscore += 2500
power_bonus = TRUE
if(istype(M, /obj/effect/decal/cleanable/blood))
GLOB.score_mess += 1
if(!score_mess)
crewscore += 1500
mess_bonus = TRUE
if(istype(M, /obj/effect/decal/cleanable/vomit))
GLOB.score_mess += 1
if(all_arrested) // This only seems to be implemented for Rev and Nukies. -DaveKorhal
crewscore *= 3 // This needs to be here for the bonus to be applied properly
// Penalties
crewscore -= points_dead_crew
crewscore -= points_power_loss
crewscore -= points_disease
crewscore -= score_mess
// Bonus Modifiers
var/deathpoints = GLOB.score_deadcrew * 25 //done
var/researchpoints = GLOB.score_researchdone * 30
var/eventpoints = GLOB.score_eventsendured * 50
var/escapoints = GLOB.score_escapees * 25 //done
var/harvests = GLOB.score_stuffharvested * 5
var/shipping = GLOB.score_stuffshipped * 5
var/mining = GLOB.score_oremined * 2 //done, might want polishing
var/meals = GLOB.score_meals * 5
var/power = GLOB.score_powerloss * 20
var/messpoints
if(GLOB.score_mess != 0)
messpoints = GLOB.score_mess //done
var/plaguepoints = GLOB.score_disease * 30
if(dead_ai)
crewscore -= 250
// Good Things
GLOB.score_crewscore += shipping
GLOB.score_crewscore += harvests
GLOB.score_crewscore += mining
GLOB.score_crewscore += researchpoints
GLOB.score_crewscore += eventpoints
GLOB.score_crewscore += escapoints
if(power == 0)
GLOB.score_crewscore += 2500
GLOB.score_powerbonus = 1
GLOB.score_crewscore += meals
if(GLOB.score_allarrested) // This only seems to be implemented for Rev and Nukies. -DaveKorhal
GLOB.score_crewscore *= 3 // This needs to be here for the bonus to be applied properly
GLOB.score_crewscore -= deathpoints
if(GLOB.score_deadaipenalty)
GLOB.score_crewscore -= 250
GLOB.score_crewscore -= power
GLOB.score_crewscore -= messpoints
GLOB.score_crewscore -= plaguepoints
// Show the score - might add "ranks" later
to_chat(world, "<b>The crew's final score is:</b>")
to_chat(world, "<b><font size='4'>[GLOB.score_crewscore]</font></b>")
// Generate the score panel
var/dat = "<b>Round Statistics and Score</b><br><hr>"
if(mode)
dat += mode.get_scoreboard_stats()
var/list/dat = list("<b>Round Statistics and Score</b><br><hr>")
if(SSticker.mode)
dat += SSticker.mode.get_scoreboard_stats()
dat += {"
<b><u>General Statistics</u></b><br>
<u>The Good</u><br>
<b>Ore Mined:</b> [GLOB.score_oremined] ([GLOB.score_oremined * 2] Points)<br>"}
if(SSshuttle.emergency.mode == SHUTTLE_ENDGAME) dat += "<b>Shuttle Escapees:</b> [GLOB.score_escapees] ([GLOB.score_escapees * 25] Points)<br>"
dat += {"
<b>Whole Station Powered:</b> [GLOB.score_powerbonus ? "Yes" : "No"] ([GLOB.score_powerbonus * 2500] Points)<br><br>
<b>Ore Mined:</b> [score_ore_mined] ([points_ore_mined] Points)<br>"}
if(score_escapees)
dat += "<b>Shuttle Escapees:</b> [score_escapees] ([points_escapees] Points)<br>"
dat += "<b>Whole Station Powered:</b> [power_bonus ? "Yes" : "No"] ([power_bonus * 2500] Points)<br>"
dat += "<b>Whole Station Cleaned:</b> [mess_bonus ? "Yes" : "No"] ([mess_bonus * 1500] Points)<br><br>"
<U>The Bad</U><br>
<b>Dead bodies on Station:</b> [GLOB.score_deadcrew] (-[GLOB.score_deadcrew * 25] Points)<br>
<b>Uncleaned Messes:</b> [GLOB.score_mess] (-[GLOB.score_mess] Points)<br>
<b>Station Power Issues:</b> [GLOB.score_powerloss] (-[GLOB.score_powerloss * 20] Points)<br>
<b>AI Destroyed:</b> [GLOB.score_deadaipenalty ? "Yes" : "No"] (-[GLOB.score_deadaipenalty * 250] Points)<br><br>
dat += "<U>The Bad</U><br>"
dat += "<b>Dead bodies on Station:</b> [score_dead_crew] (-[points_dead_crew] Points)<br>"
if(!mess_bonus)
dat += "<b>Uncleaned Messes:</b> [score_mess] (-[score_mess] Points)<br>"
if(!power_bonus)
dat += "<b>Station Power Issues:</b> [score_power_loss] (-[points_power_loss] Points)<br>"
dat += {"
<b>AI Destroyed:</b> [dead_ai ? "Yes" : "No"] (-[dead_ai * 250] Points)<br><br>
<U>The Weird</U><br>
<b>Food Eaten:</b> [GLOB.score_foodeaten] bites/sips<br>
<b>Times a Clown was Abused:</b> [GLOB.score_clownabuse]<br><br>
"}
if(GLOB.score_escapees)
dat += {"<b>Richest Escapee:</b> [GLOB.score_richestname], [GLOB.score_richestjob]: $[num2text(GLOB.score_richestcash,50)] ([GLOB.score_richestkey])<br>
<b>Most Battered Escapee:</b> [GLOB.score_dmgestname], [GLOB.score_dmgestjob]: [GLOB.score_dmgestdamage] damage ([GLOB.score_dmgestkey])<br>"}
<b>Food Eaten:</b> [score_food_eaten] bites/sips.<br>
<b>Times a Clown was Abused:</b> [score_clown_abuse]<br><br>"}
if(score_escapees)
dat += "<b>Richest Escapee:</b> [richest_name], [richest_job]: $[num2text(richest_cash, 50)] ([richest_key])<br>"
if(damaged_health)
dat += "<b>Most Battered Escapee:</b> [damaged_name], [damaged_job]: [damaged_health] damage ([damaged_key])<br>"
else
if(SSshuttle.emergency.mode <= SHUTTLE_STRANDED)
dat += "The station wasn't evacuated!<br>"
else
dat += "No-one escaped!<br>"
dat += mode.declare_job_completion()
dat += SSticker.mode.declare_job_completion()
dat += {"
<hr><br>
<b><u>FINAL SCORE: [GLOB.score_crewscore]</u></b><br>
<b><u>FINAL SCORE: [crewscore]</u></b><br>
"}
var/score_rating = "The Aristocrats!"
switch(GLOB.score_crewscore)
if(-99999 to SINGULARITY_DESERVES_BETTER) score_rating = "Even the Singularity Deserves Better"
switch(crewscore)
if(-INFINITY to SINGULARITY_DESERVES_BETTER) score_rating = "Even the Singularity Deserves Better"
if(SINGULARITY_DESERVES_BETTER+1 to SINGULARITY_FODDER) score_rating = "Singularity Fodder"
if(SINGULARITY_FODDER+1 to ALL_FIRED) score_rating = "You're All Fired"
if(ALL_FIRED+1 to WASTE_OF_OXYGEN) score_rating = "A Waste of Perfectly Good Oxygen"
@@ -214,33 +301,20 @@
if(NANOTRANSEN_FINEST to INFINITY) score_rating = "Nanotrasen's Finest"
dat += "<b><u>RATING:</u></b> [score_rating]"
src << browse(dat, "window=roundstats;size=500x600")
GLOB.scoreboard = jointext(dat, "")
for(var/mob/E in GLOB.player_list)
if(E.client && !E.get_preference(PREFTOGGLE_DISABLE_SCOREBOARD))
E << browse(dat, "window=roundstats;size=500x600")
if(E.client)
to_chat(E, "<b>The crew's final score is:</b>")
to_chat(E, "<b><font size='4'><a href='?src=[E.UID()];scoreboard=1'>[crewscore]</a></font></b>")
if(!E.get_preference(PREFTOGGLE_DISABLE_SCOREBOARD))
E << browse(GLOB.scoreboard, "window=roundstats;size=500x600")
// A recursive function to properly determine the wealthiest escapee
/datum/controller/subsystem/ticker/proc/get_score_container_worth(atom/C, level=0)
if(level >= 5)
// in case the containers recurse or something
return 0
else
. = 0
for(var/obj/item/card/id/id in C.contents)
var/datum/money_account/A = get_money_account(id.associated_account_number)
// has an account?
if(A)
. += A.money
for(var/obj/item/stack/spacecash/cash in C.contents)
. += cash.amount
for(var/obj/item/storage/S in C.contents)
. += .(S, level + 1)
/datum/game_mode/proc/get_scoreboard_stats()
return null
/datum/game_mode/proc/set_scoreboard_gvars()
/datum/game_mode/proc/set_scoreboard_vars()
return null
#undef SINGULARITY_DESERVES_BETTER
+12 -11
View File
@@ -9,6 +9,7 @@
action_background_icon_state = "bg_vampire"
var/required_blood = 0
var/gain_desc = null
var/deduct_blood_on_cast = TRUE //Do we want to take the blood when this is cast, or at a later point?
/obj/effect/proc_holder/spell/vampire/New()
..()
@@ -99,6 +100,8 @@
var/datum/vampire/vampire = usr.mind.vampire
if(required_blood <= vampire.bloodusable)
if(!deduct_blood_on_cast) //don't take the blood yet if this is false!
return
vampire.bloodusable -= required_blood
else
// stop!!
@@ -288,8 +291,10 @@
gain_desc = "You have gained the Enthrall ability which at a heavy blood cost allows you to enslave a human that is not loyal to any other for a random period of time."
action_icon_state = "vampire_enthrall"
required_blood = 300
deduct_blood_on_cast = FALSE
/obj/effect/proc_holder/spell/vampire/targetted/enthrall/cast(list/targets, mob/user = usr)
var/datum/vampire/vampire = user.mind.vampire
for(var/mob/living/target in targets)
user.visible_message("<span class='warning'>[user] bites [target]'s neck!</span>", "<span class='warning'>You bite [target]'s neck and begin the flow of power.</span>")
to_chat(target, "<span class='warning'>You feel the tendrils of evil invade your mind.</span>")
@@ -299,6 +304,7 @@
if(do_mob(user, target, 50))
if(can_enthrall(user, target))
handle_enthrall(user, target)
vampire.bloodusable -= required_blood //we take the blood after enthralling, not before
else
revert_cast(user)
to_chat(user, "<span class='warning'>You or your target either moved or you dont have enough usable blood.</span>")
@@ -418,7 +424,7 @@
name = "Mist Form (30)"
desc = "You take on the form of mist for a short period of time."
gain_desc = "You have gained the Mist Form ability which allows you to take on the form of mist for a short period and pass over any obstacle in your path."
action_icon_state = "jaunt"
action_icon_state = "mist"
charge_max = 600
required_blood = 30
centcom_cancast = 0
@@ -430,28 +436,23 @@
var/originalloc = get_turf(user.loc)
var/obj/effect/dummy/spell_jaunt/holder = new /obj/effect/dummy/spell_jaunt(originalloc)
var/atom/movable/overlay/animation = new /atom/movable/overlay(originalloc)
animation.name = "water"
animation.name = "blood"
animation.density = 0
animation.anchored = 1
animation.icon = 'icons/mob/mob.dmi'
animation.icon_state = "liquify"
animation.icon_state = "empty"
animation.layer = 5
animation.master = holder
U.ExtinguishMob()
flick("liquify", animation)
flick("mist", animation)
user.forceMove(holder)
user.client.eye = holder
var/datum/effect_system/steam_spread/steam = new /datum/effect_system/steam_spread()
steam.set_up(10, 0, originalloc)
steam.start()
sleep(jaunt_duration)
var/mobloc = get_turf(user.loc)
animation.loc = mobloc
steam.location = mobloc
steam.start()
user.canmove = 0
sleep(20)
flick("reappear",animation)
flick("mist_reappear", animation)
sleep(5)
if(!user.Move(mobloc))
for(var/direction in list(1,2,4,8,5,6,9,10))
@@ -470,7 +471,7 @@
name = "Shadowstep (30)"
desc = "Vanish into the shadows."
gain_desc = "You have gained the ability to shadowstep, which makes you disappear into nearby shadows at the cost of blood."
action_icon_state = "blink"
action_icon_state = "shadowblink"
charge_max = 20
required_blood = 30
centcom_cancast = 0
+1 -1
View File
@@ -366,7 +366,7 @@
qdel(SS)
/proc/make_new_construct(mob/living/simple_animal/hostile/construct/c_type, mob/target, mob/user, cult_override = FALSE)
if(jobban_isbanned(target, "cultist"))
if(jobban_isbanned(target, ROLE_CULTIST))
return
var/mob/living/simple_animal/hostile/construct/C = new c_type(get_turf(target))
C.faction |= "\ref[user]"
+2 -2
View File
@@ -446,7 +446,7 @@
/datum/spellbook_entry/item/warp_cubes
name = "Warp Cubes"
desc = "Two magic cubes, that when they are twisted in hand, teleports the user to the location of the other cube instantly. Great for silently teleporting to a fixed location, or teleporting you to an appretnance, or vice versa. Do not leave on the wizard den, it will not work."
desc = "Two magic cubes, that when they are twisted in hand, teleports the user to the location of the other cube instantly. Great for silently teleporting to a fixed location, or teleporting you to an apprentice, or vice versa. Do not leave on the wizard den, it will not work."
item_path = /obj/item/warp_cube/red
log_name = "WC"
cost = 1
@@ -479,7 +479,7 @@
/datum/spellbook_entry/item/singularity_hammer
name = "Singularity Hammer"
desc = "A hammer that creates an intensely powerful field of gravity where it strikes, pulling everthing nearby to the point of impact."
desc = "A hammer that creates an intensely powerful field of gravity where it strikes, pulling everything nearby to the point of impact."
item_path = /obj/item/twohanded/singularityhammer
log_name = "SI"
category = "Weapons and Armors"
+1 -1
View File
@@ -225,7 +225,7 @@
to_chat(H, "<span class='danger'>Failed to locate a storage object on your mob, either you spawned with no hands free and no backpack or this is a bug.</span>")
qdel(G)
qdel(gear_leftovers)
gear_leftovers.Cut()
return 1
+38 -105
View File
@@ -4,133 +4,66 @@
icon_state = "liquid_dispenser"
layer = 3
plane = FLOOR_PLANE
anchored = 1.0
anchored = TRUE
max_integrity = 200
armor = list(melee = 50, bullet = 20, laser = 20, energy = 20, bomb = 0, bio = 0, rad = 0, fire = 50, acid = 30)
var/uses = 20
var/disabled = TRUE
var/lethal = 0
var/locked = TRUE
var/cooldown_time = 0
var/cooldown_timeleft = 0
var/cooldown_time = 10 SECONDS
var/cooldown_on = FALSE
req_access = list(ACCESS_AI_UPLOAD)
/obj/machinery/ai_slipper/examine(mob/user)
. = ..()
. += "<span class='notice'>A small counter shows it has: [uses] use\s remaining.</span>"
/obj/machinery/ai_slipper/power_change()
if(stat & BROKEN)
update_icon()
if(powered())
stat &= ~NOPOWER
else
if( powered() )
stat &= ~NOPOWER
else
stat |= NOPOWER
disabled = TRUE
update_icon()
/obj/machinery/ai_slipper/proc/setState(enabled, uses)
disabled = disabled
uses = uses
power_change()
/obj/machinery/ai_slipper/attackby(obj/item/W, mob/user, params)
if(stat & (NOPOWER|BROKEN))
return
if(istype(user, /mob/living/silicon))
return attack_hand(user)
if(allowed(usr)) // trying to unlock the interface
locked = !locked
to_chat(user, "You [locked ? "lock" : "unlock"] the device.")
if(locked)
if(user.machine == src)
user.unset_machine()
user << browse(null, "window=ai_slipper")
else
if(user.machine == src)
attack_hand(usr)
return
return ..()
/obj/machinery/ai_slipper/proc/ToggleOn()
if(stat & (NOPOWER|BROKEN))
return
disabled = !disabled
stat |= NOPOWER
update_icon()
/obj/machinery/ai_slipper/proc/Activate()
/obj/machinery/ai_slipper/attack_ai(mob/user)
add_hiddenprint(user)
return attack_hand(user)
/obj/machinery/ai_slipper/attack_ghost(mob/user)
if(user.can_advanced_admin_interact())
Activate(user)
/obj/machinery/ai_slipper/attack_hand(mob/user)
if(stat & (NOPOWER|BROKEN))
to_chat(user, "<span class='warning'>[src] has no power or is broken!</span>")
return
if(!allowed(user))
to_chat(user, "<span class='warning'>Access denied.</span>")
return
Activate(user)
/obj/machinery/ai_slipper/proc/Activate(mob/user)
if(stat & (NOPOWER|BROKEN))
return
if(cooldown_on || disabled)
if(!uses)
to_chat(user, "<span class='warning'>[src] is empty!</span>")
return
if(cooldown_on)
to_chat(user, "<span class='warning'>[src] is still recharging!</span>")
return
else
new /obj/effect/particle_effect/foam(loc)
uses--
cooldown_on = TRUE
cooldown_time = world.timeofday + 100
slip_process()
power_change()
addtimer(CALLBACK(src, .proc/recharge), cooldown_time)
/obj/machinery/ai_slipper/update_icon()
if(stat & (NOPOWER|BROKEN) || disabled)
if(stat & (NOPOWER|BROKEN) || cooldown_on || !uses)
icon_state = "liquid_dispenser"
else
icon_state = "liquid_dispenser_on"
/obj/machinery/ai_slipper/attack_ai(mob/user)
return attack_hand(user)
/obj/machinery/ai_slipper/attack_ghost(mob/user)
return attack_hand(user)
/obj/machinery/ai_slipper/attack_hand(mob/user)
if(stat & (NOPOWER|BROKEN))
/obj/machinery/ai_slipper/proc/recharge()
if(!uses)
return
if(get_dist(src, user) > 1 && (!issilicon(user) && !user.can_admin_interact()))
to_chat(user, "<span class='warning'>Too far away.</span>")
user.unset_machine()
user << browse(null, "window=ai_slipper")
return
user.set_machine(src)
var/area/myarea = get_area(src)
var/t = "<TT><B>AI Liquid Dispenser</B> ([myarea.name])<HR>"
if(locked && (!issilicon(user) && !user.can_admin_interact()))
t += "<I>(Swipe ID card to unlock control panel.)</I><BR>"
else
t += text("Dispenser [] - <A href='?src=[UID()];toggleOn=1'>[]?</a><br>\n", disabled ? "deactivated" : "activated", disabled ? "Enable" : "Disable")
t += text("Uses Left: [uses]. <A href='?src=[UID()];toggleUse=1'>Activate the dispenser?</A><br>\n")
user << browse(t, "window=computer;size=575x450")
onclose(user, "computer")
/obj/machinery/ai_slipper/Topic(href, href_list)
if(..())
return 1
if(locked && (!issilicon(usr) && !usr.can_admin_interact()))
to_chat(usr, "Control panel is locked!")
return 1
if(href_list["toggleOn"])
ToggleOn()
if(href_list["toggleUse"])
Activate()
attack_hand(usr)
/obj/machinery/ai_slipper/proc/slip_process()
while(cooldown_time - world.timeofday > 0)
var/ticksleft = cooldown_time - world.timeofday
if(ticksleft > 1e5)
cooldown_time = world.timeofday + 10 // midnight rollover
cooldown_timeleft = (ticksleft / 10)
sleep(5)
if(uses <= 0)
return
if(uses >= 0)
cooldown_on = FALSE
cooldown_on = FALSE
power_change()
File diff suppressed because it is too large Load Diff
@@ -75,7 +75,7 @@
for(var/obj/machinery/camera/C in GLOB.cameranet.cameras)
if(!C.can_use())
continue
if(C.network&networks)
if(length(C.network & networks))
camera_location = get_turf(C)
break
if(camera_location)
@@ -101,6 +101,8 @@
/mob/camera/aiEye/remote
name = "Inactive Camera Eye"
// Abductors dont trigger the Ai Detector
ai_detector_visible = FALSE
var/sprint = 10
var/cooldown = 0
var/acceleration = 1
+4 -4
View File
@@ -130,6 +130,7 @@
if(circuit) //no circuit, no computer frame
var/obj/structure/computerframe/A = new /obj/structure/computerframe(loc)
var/obj/item/circuitboard/M = new circuit(A)
A.name += " ([M.board_name])"
A.setDir(dir)
A.circuit = M
A.anchored = TRUE
@@ -140,13 +141,12 @@
playsound(src, 'sound/effects/hit_on_shattered_glass.ogg', 70, TRUE)
new /obj/item/shard(drop_location())
new /obj/item/shard(drop_location())
A.state = 3
A.icon_state = "3"
A.state = 4
else
if(user)
to_chat(user, "<span class='notice'>You disconnect the monitor.</span>")
A.state = 4
A.icon_state = "4"
A.state = 5
A.update_icon()
for(var/obj/C in src)
C.forceMove(loc)
qdel(src)
-118
View File
@@ -1,118 +0,0 @@
/obj/machinery/computer/HONKputer
name = "\improper HONKputer Mark I"
desc = "A yellow computer used in case of critically low levels of HONK."
icon = 'icons/obj/machines/HONKputer.dmi'
icon_state = "honkputer"
icon_keyboard = "key_honk"
icon_screen = "honkcomms"
light_color = LIGHT_COLOR_PINK
req_access = list(ACCESS_CLOWN)
circuit = /obj/item/circuitboard/HONKputer
var/authenticated = 0
var/message_cooldown = 0
var/state = STATE_DEFAULT
var/const/STATE_DEFAULT = 1
/obj/machinery/computer/HONKputer/process()
if(..())
src.updateDialog()
/obj/machinery/computer/HONKputer/Topic(href, href_list)
if(..())
return 1
if(is_away_level(src.z))
to_chat(usr, "<span class='danger'>Unable to establish a connection</span>: You're too far away from the station!")
return
usr.set_machine(src)
if(!href_list["operation"])
return
switch(href_list["operation"])
// main interface
if("main")
src.state = STATE_DEFAULT
if("login")
var/mob/M = usr
var/obj/item/card/id/I = M.get_active_hand()
if(istype(I, /obj/item/pda))
var/obj/item/pda/pda = I
I = pda.id
if(I && istype(I))
if(src.check_access(I) || src.emagged==1)
authenticated = 1
if("logout")
authenticated = 0
if("MessageHonkplanet")
if(src.authenticated==1)
if(message_cooldown)
to_chat(usr, "Arrays recycling. Please stand by.")
return
var/input = stripped_input(usr, "Please choose a message to transmit to your HONKbrothers on the homeworld. Transmission does not guarantee a response.", "To abort, send an empty message.", "")
if(!input || !(usr in view(1,src)))
return
HONK_announce(input, usr)
to_chat(usr, "Message transmitted.")
log_game("[key_name(usr)] has made a HONKplanet announcement: [input]")
message_cooldown = 1
spawn(6000)//10 minute cooldown
message_cooldown = 0
src.updateUsrDialog()
/obj/machinery/computer/HONKputer/emag_act(user as mob)
if(!emagged)
src.emagged = 1
to_chat(user, "You scramble the login circuits, allowing anyone to use the console!")
/obj/machinery/computer/HONKputer/attack_hand(mob/user as mob)
if(..())
return
if(is_away_level(src.z))
to_chat(user, "<span class='danger'>Unable to establish a connection</span>: You're too far away from the station!")
return
user.set_machine(src)
var/dat = "<head><title>HONKputer Interface</title></head><body>"
if(istype(user, /mob/living/silicon))
to_chat(user, "This console is not networked to the rest of the grid.")
return
switch(src.state)
if(STATE_DEFAULT)
if(src.authenticated)
dat += "<BR>\[ <A HREF='?src=[UID()];operation=logout'>Log Out</A> \]"
dat += "<BR>\[ <A HREF='?src=[UID()];operation=MessageHonkplanet'>Send an emergency message to Honkplanet</A> \]"
else
dat += "<BR>\[ <A HREF='?src=[UID()];operation=login'>Log In</A> \]"
dat += "<BR>\[ [(src.state != STATE_DEFAULT) ? "<A HREF='?src=[UID()];operation=main'>Main Menu</A> | " : ""]<A HREF='?src=[user.UID()];mach_close=honkputer'>Close</A> \]"
user << browse(dat, "window=honkputer;size=400x500")
onclose(user, "honkputer")
/obj/machinery/computer/HONKputer/attackby(obj/I, mob/user, params)
if(istype(I, /obj/item/screwdriver) && circuit)
var/obj/item/screwdriver/S = I
playsound(src.loc, S.usesound, 50, 1)
if(do_after(user, 20 * S.toolspeed, target = src))
var/obj/structure/computerframe/HONKputer/A = new /obj/structure/computerframe/HONKputer( src.loc )
var/obj/item/circuitboard/M = new circuit( A )
A.circuit = M
A.anchored = 1
for(var/obj/C in src)
C.loc = src.loc
if(src.stat & BROKEN)
to_chat(user, "<span class='notice'>The broken glass falls out.</span>")
new /obj/item/shard( src.loc )
A.state = 3
A.icon_state = "3"
else
to_chat(user, "<span class='notice'>You disconnect the monitor.</span>")
A.state = 4
A.icon_state = "4"
qdel(src)
else
return ..()
@@ -1,110 +0,0 @@
#define SALVAGE_SHIP_MOVE_TIME 300
#define SALVAGE_SHIP_COOLDOWN 800
/obj/machinery/computer/salvage_ship
name = "salvage ship terminal"
icon = 'icons/obj/computer.dmi'
icon_keyboard = "syndie_key"
icon_screen = "syndishuttle"
req_access = list(ACCESS_SALVAGE_CAPTAIN)
var/area/curr_location
var/moving = 0
var/lastMove = 0
/obj/machinery/computer/salvage_ship/New()
. = ..()
curr_location = locate(/area/shuttle/salvage/start)
/obj/machinery/computer/salvage_ship/proc/salvage_move_to(area/destination as area)
if(moving) return
if(lastMove + SALVAGE_SHIP_COOLDOWN > world.time) return
var/area/dest_location = locate(destination)
if(curr_location == dest_location) return
moving = 1
lastMove = world.time
if(curr_location.z != dest_location.z)
var/area/transit_location = locate(/area/shuttle/salvage/transit)
curr_location.move_contents_to(transit_location)
curr_location = transit_location
sleep(SALVAGE_SHIP_MOVE_TIME)
curr_location.move_contents_to(dest_location)
curr_location = dest_location
moving = 0
return 1
/obj/machinery/computer/salvage_ship/attack_ai(mob/user as mob)
src.add_hiddenprint(user)
return attack_hand(user)
/obj/machinery/computer/salvage_ship/attack_hand(mob/user as mob)
if(!allowed(user))
to_chat(user, "<span class='warning'>Access Denied</span>")
return
user.set_machine(src)
var/dat = {"Location: [curr_location]<br>
Ready to move[max(lastMove + SALVAGE_SHIP_COOLDOWN - world.time, 0) ? " in [max(round((lastMove + SALVAGE_SHIP_COOLDOWN - world.time) * 0.1), 0)] seconds" : ": now"]<br>
<a href='?src=[UID()];start=1'>Middle of Nowhere</a><br>
<a href='?src=[UID()];arrivals=1'>Station Auxiliary Docking</a> |
<a href='?src=[UID()];north=1'>North of the Station</a> |
<a href='?src=[UID()];east=1'>East of the Station</a> |
<a href='?src=[UID()];south=1'>South of the Station</a><br>
<a href='?src=[UID()];trading_post=1'>Trading Post</a><br>
<a href='?src=[UID()];clown_asteroid=1'>Clown Asteroid</a> |
<a href='?src=[UID()];derelict=1'>Derelict Station</a> |
<a href='?src=[UID()];djstation=1'>Ruskie DJ Station</a><br>
<a href='?src=[UID()];commssat=1'>Communications Satellite</a> |
<a href='?src=[UID()];abandoned_ship=1'>Abandoned Ship</a><br>
<a href='?src=[user.UID()];mach_close=computer'>Close</a>"}
user << browse(dat, "window=computer;size=575x450")
onclose(user, "computer")
return
/obj/machinery/computer/salvage_ship/Topic(href, href_list)
if(..())
return 1
if(!isliving(usr)) return
var/mob/living/user = usr
if(in_range(src, user) || istype(user, /mob/living/silicon))
user.set_machine(src)
if(href_list["salvage"])
salvage_move_to(/area/shuttle/salvage/start)
else if(href_list["start"])
salvage_move_to(/area/shuttle/salvage/start)
else if(href_list["arrivals"])
salvage_move_to(/area/shuttle/salvage/arrivals)
else if(href_list["derelict"])
salvage_move_to(/area/shuttle/salvage/derelict)
else if(href_list["djstation"])
salvage_move_to(/area/shuttle/salvage/djstation)
else if(href_list["north"])
salvage_move_to(/area/shuttle/salvage/north)
else if(href_list["east"])
salvage_move_to(/area/shuttle/salvage/east)
else if(href_list["south"])
salvage_move_to(/area/shuttle/salvage/south)
else if(href_list["commssat"])
salvage_move_to(/area/shuttle/salvage/commssat)
else if(href_list["abandoned_ship"])
salvage_move_to(/area/shuttle/salvage/abandoned_ship)
else if(href_list["clown_asteroid"])
salvage_move_to(/area/shuttle/salvage/clown_asteroid)
else if(href_list["trading_post"])
salvage_move_to(/area/shuttle/salvage/trading_post)
add_fingerprint(usr)
updateUsrDialog()
return
/obj/machinery/computer/salvage_ship/bullet_act(obj/item/projectile/Proj)
visible_message("[Proj] ricochets off [src]!")
@@ -1,338 +0,0 @@
//Config stuff
#define SPECOPS_MOVETIME 600 //Time to station is milliseconds. 60 seconds, enough time for everyone to be on the shuttle before it leaves.
#define SPECOPS_STATION_AREATYPE "/area/shuttle/specops/station" //Type of the spec ops shuttle area for station
#define SPECOPS_DOCK_AREATYPE "/area/shuttle/specops/centcom" //Type of the spec ops shuttle area for dock
#define SPECOPS_RETURN_DELAY 6000 //Time between the shuttle is capable of moving.
GLOBAL_VAR_INIT(specops_shuttle_moving_to_station, 0)
GLOBAL_VAR_INIT(specops_shuttle_moving_to_centcom, 0)
GLOBAL_VAR_INIT(specops_shuttle_at_station, 0)
GLOBAL_VAR_INIT(specops_shuttle_can_send, 1)
GLOBAL_VAR_INIT(specops_shuttle_time, 0)
GLOBAL_VAR_INIT(specops_shuttle_timeleft, 0)
/obj/machinery/computer/specops_shuttle
name = "\improper Spec. Ops. shuttle console"
icon = 'icons/obj/computer.dmi'
icon_keyboard = "security_key"
icon_screen = "syndishuttle"
light_color = LIGHT_COLOR_PURE_CYAN
req_access = list(ACCESS_CENT_SPECOPS)
// req_access = list(ACCESS_CENT_SPECOPS)
var/temp = null
var/hacked = 0
var/allowedtocall = 0
var/specops_shuttle_timereset = 0
/proc/specops_return()
var/obj/item/radio/intercom/announcer = new /obj/item/radio/intercom(null)//We need a fake AI to announce some stuff below. Otherwise it will be wonky.
announcer.config(list("Response Team" = 0))
var/message_tracker[] = list(0,1,2,3,5,10,30,45)//Create a a list with potential time values.
var/message = "\"THE SPECIAL OPERATIONS SHUTTLE IS PREPARING TO RETURN\""//Initial message shown.
if(announcer)
announcer.autosay(message, "A.L.I.C.E.", "Response Team", list(1,2))
while(GLOB.specops_shuttle_time - world.timeofday > 0)
var/ticksleft = GLOB.specops_shuttle_time - world.timeofday
if(ticksleft > 1e5)
GLOB.specops_shuttle_time = world.timeofday + 10 // midnight rollover
GLOB.specops_shuttle_timeleft = (ticksleft / 10)
//All this does is announce the time before launch.
if(announcer)
var/rounded_time_left = round(GLOB.specops_shuttle_timeleft)//Round time so that it will report only once, not in fractions.
if(rounded_time_left in message_tracker)//If that time is in the list for message announce.
message = "\"ALERT: [rounded_time_left] SECOND[(rounded_time_left!=1)?"S":""] REMAIN\""
if(rounded_time_left==0)
message = "\"ALERT: TAKEOFF\""
announcer.autosay(message, "A.L.I.C.E.", "Response Team")
message_tracker -= rounded_time_left//Remove the number from the list so it won't be called again next cycle.
//Should call all the numbers but lag could mean some issues. Oh well. Not much I can do about that.
sleep(5)
GLOB.specops_shuttle_moving_to_station = 0
GLOB.specops_shuttle_moving_to_centcom = 0
GLOB.specops_shuttle_at_station = 1
var/area/start_location = locate(/area/shuttle/specops/station)
var/area/end_location = locate(/area/shuttle/specops/centcom)
var/list/dstturfs = list()
var/throwy = world.maxy
for(var/turf/T in end_location)
dstturfs += T
if(T.y < throwy)
throwy = T.y
// hey you, get out of the way!
for(var/turf/T in dstturfs)
// find the turf to move things to
var/turf/D = locate(T.x, throwy - 1, 1)
//var/turf/E = get_step(D, SOUTH)
for(var/atom/movable/AM as mob|obj in T)
AM.Move(D)
if(istype(T, /turf/simulated))
qdel(T)
for(var/mob/living/carbon/bug in end_location) // If someone somehow is still in the shuttle's docking area...
bug.gib()
for(var/mob/living/simple_animal/pest in end_location) // And for the other kind of bug...
pest.gib()
start_location.move_contents_to(end_location)
for(var/turf/T in get_area_turfs(end_location) )
var/mob/M = locate(/mob) in T
to_chat(M, "<span class='warning'>You have arrived at Central Command. Operation has ended!</span>")
GLOB.specops_shuttle_at_station = 0
for(var/obj/machinery/computer/specops_shuttle/S in GLOB.machines)
S.specops_shuttle_timereset = world.time + SPECOPS_RETURN_DELAY
qdel(announcer)
/proc/specops_process()
var/area/centcom/specops/special_ops = locate()//Where is the specops area located?
var/obj/item/radio/intercom/announcer = new /obj/item/radio/intercom(null)//We need a fake AI to announce some stuff below. Otherwise it will be wonky.
announcer.config(list("Response Team" = 0))
var/message_tracker[] = list(0,1,2,3,5,10,30,45)//Create a a list with potential time values.
var/message = "\"THE SPECIAL OPERATIONS SHUTTLE IS PREPARING FOR LAUNCH\""//Initial message shown.
if(announcer)
announcer.autosay(message, "A.L.I.C.E.", "Response Team")
//message = "ARMORED SQUAD TAKE YOUR POSITION ON GRAVITY LAUNCH PAD"
//announcer.autosay(message, "A.L.I.C.E.", "Response Team")
while(GLOB.specops_shuttle_time - world.timeofday > 0)
var/ticksleft = GLOB.specops_shuttle_time - world.timeofday
if(ticksleft > 1e5)
GLOB.specops_shuttle_time = world.timeofday + 10 // midnight rollover
GLOB.specops_shuttle_timeleft = (ticksleft / 10)
//All this does is announce the time before launch.
if(announcer)
var/rounded_time_left = round(GLOB.specops_shuttle_timeleft)//Round time so that it will report only once, not in fractions.
if(rounded_time_left in message_tracker)//If that time is in the list for message announce.
message = "\"ALERT: [rounded_time_left] SECOND[(rounded_time_left!=1)?"S":""] REMAIN\""
if(rounded_time_left==0)
message = "\"ALERT: TAKEOFF\""
announcer.autosay(message, "A.L.I.C.E.", "Response Team")
message_tracker -= rounded_time_left//Remove the number from the list so it won't be called again next cycle.
//Should call all the numbers but lag could mean some issues. Oh well. Not much I can do about that.
sleep(5)
GLOB.specops_shuttle_moving_to_station = 0
GLOB.specops_shuttle_moving_to_centcom = 0
GLOB.specops_shuttle_at_station = 1
if(GLOB.specops_shuttle_moving_to_station || GLOB.specops_shuttle_moving_to_centcom) return
if(!specops_can_move())
to_chat(usr, "<span class='warning'>The Special Operations shuttle is unable to leave.</span>")
return
//Begin Marauder launchpad.
spawn(0)//So it parallel processes it.
for(var/obj/machinery/door/poddoor/M in special_ops)
switch(M.id_tag)
if("ASSAULT0")
spawn(10)//1 second delay between each.
M.open()
if("ASSAULT1")
spawn(20)
M.open()
if("ASSAULT2")
spawn(30)
M.open()
if("ASSAULT3")
spawn(40)
M.open()
sleep(10)
var/spawn_marauder[] = new()
for(var/thing in GLOB.landmarks_list)
var/obj/effect/landmark/L = thing
if(L.name == "Marauder Entry")
spawn_marauder.Add(L.loc)
for(var/thing in GLOB.landmarks_list)
var/obj/effect/landmark/L = thing
if(L.name == "Marauder Exit")
var/obj/effect/portal/P = new(L.loc, pick(spawn_marauder))
//P.invisibility = 101//So it is not seen by anyone.
P.failchance = 0//So it has no fail chance when teleporting.
spawn_marauder.Remove(P.target)
sleep(10)
for(var/obj/machinery/mass_driver/M in special_ops)
switch(M.id_tag)
if("ASSAULT0")
spawn(10)
M.drive()
if("ASSAULT1")
spawn(20)
M.drive()
if("ASSAULT2")
spawn(30)
M.drive()
if("ASSAULT3")
spawn(40)
M.drive()
sleep(50)//Doors remain open for 5 seconds.
for(var/obj/machinery/door/poddoor/M in special_ops)
switch(M.id_tag)//Doors close at the same time.
if("ASSAULT0")
spawn(0)
M.close()
if("ASSAULT1")
spawn(0)
M.close()
if("ASSAULT2")
spawn(0)
M.close()
if("ASSAULT3")
spawn(0)
M.close()
//End Marauder launchpad.
var/area/start_location = locate(/area/shuttle/specops/centcom)
var/area/end_location = locate(/area/shuttle/specops/station)
var/list/dstturfs = list()
var/throwy = world.maxy
for(var/turf/T in end_location)
dstturfs += T
if(T.y < throwy)
throwy = T.y
// hey you, get out of the way!
for(var/turf/T in dstturfs)
// find the turf to move things to
var/turf/D = locate(T.x, throwy - 1, 1)
//var/turf/E = get_step(D, SOUTH)
for(var/atom/movable/AM as mob|obj in T)
AM.Move(D)
if(istype(T, /turf/simulated))
qdel(T)
start_location.move_contents_to(end_location)
for(var/turf/T in get_area_turfs(end_location) )
var/mob/M = locate(/mob) in T
to_chat(M, "<span class='warning'>You have arrived to [station_name()]. Commence operation!</span>")
for(var/obj/machinery/computer/specops_shuttle/S in GLOB.machines)
S.specops_shuttle_timereset = world.time + SPECOPS_RETURN_DELAY
qdel(announcer)
/proc/specops_can_move()
if(GLOB.specops_shuttle_moving_to_station || GLOB.specops_shuttle_moving_to_centcom)
return 0
for(var/obj/machinery/computer/specops_shuttle/S in GLOB.machines)
if(world.timeofday <= S.specops_shuttle_timereset)
return 0
return 1
/obj/machinery/computer/specops_shuttle/attack_ai(mob/user as mob)
to_chat(user, "<span class='warning'>Access Denied.</span>")
return 1
/obj/machinery/computer/specops_shuttle/attackby(I as obj, user as mob, params)
if(istype(I,/obj/item/card/emag))
to_chat(user, "<span class='notice'>The electronic systems in this console are far too advanced for your primitive hacking peripherals.</span>")
else
return ..()
/obj/machinery/computer/specops_shuttle/attack_hand(mob/user as mob)
if(!allowed(user))
to_chat(user, "<span class='warning'>Access Denied.</span>")
return
//Commented out so admins can do shenanigans at their leisure. Also makes the force-spawned admin ERTs able to use the shuttle.
// if(sent_strike_team == 0 && send_emergency_team == 0)
// to_chat(usr, "<span class='warning'>The strike team has not yet deployed.</span>")
// return
if(..())
return
user.machine = src
var/dat
if(temp)
dat = temp
else
dat += {"<BR><B>Special Operations Shuttle</B><HR>
\nLocation: [GLOB.specops_shuttle_moving_to_station || GLOB.specops_shuttle_moving_to_centcom ? "Departing for [station_name()] in ([GLOB.specops_shuttle_timeleft] seconds.)":GLOB.specops_shuttle_at_station ? "Station":"Dock"]<BR>
[GLOB.specops_shuttle_moving_to_station || GLOB.specops_shuttle_moving_to_centcom ? "\n*The Special Ops. shuttle is already leaving.*<BR>\n<BR>":GLOB.specops_shuttle_at_station ? "\n<A href='?src=[UID()];sendtodock=1'>Shuttle standing by...</A><BR>\n<BR>":"\n<A href='?src=[UID()];sendtostation=1'>Depart to [station_name()]</A><BR>\n<BR>"]
\n<A href='?src=[user.UID()];mach_close=computer'>Close</A>"}
user << browse(dat, "window=computer;size=575x450")
onclose(user, "computer")
return
/obj/machinery/computer/specops_shuttle/Topic(href, href_list)
if(..())
return 1
if((usr.contents.Find(src) || (in_range(src, usr) && istype(loc, /turf))) || (istype(usr, /mob/living/silicon)))
usr.machine = src
if(href_list["sendtodock"])
if(!GLOB.specops_shuttle_at_station|| GLOB.specops_shuttle_moving_to_station || GLOB.specops_shuttle_moving_to_centcom) return
if(!specops_can_move())
to_chat(usr, "<span class='notice'>Central Command will not allow the Special Operations shuttle to return yet.</span>")
if(world.timeofday <= specops_shuttle_timereset)
if(((world.timeofday - specops_shuttle_timereset)/10) > 60)
to_chat(usr, "<span class='notice'>[-((world.timeofday - specops_shuttle_timereset)/10)/60] minutes remain!</span>")
to_chat(usr, "<span class='notice'>[-(world.timeofday - specops_shuttle_timereset)/10] seconds remain!</span>")
return
to_chat(usr, "<span class='notice'>The Special Operations shuttle will arrive at Central Command in [(SPECOPS_MOVETIME/10)] seconds.</span>")
temp += "Shuttle departing.<BR><BR><A href='?src=[UID()];mainmenu=1'>OK</A>"
updateUsrDialog()
GLOB.specops_shuttle_moving_to_centcom = 1
GLOB.specops_shuttle_time = world.timeofday + SPECOPS_MOVETIME
spawn(0)
specops_return()
else if(href_list["sendtostation"])
if(GLOB.specops_shuttle_at_station || GLOB.specops_shuttle_moving_to_station || GLOB.specops_shuttle_moving_to_centcom) return
if(!specops_can_move())
to_chat(usr, "<span class='warning'>The Special Operations shuttle is unable to leave.</span>")
return
to_chat(usr, "<span class='notice'>The Special Operations shuttle will arrive on [station_name()] in [(SPECOPS_MOVETIME/10)] seconds.</span>")
temp += "Shuttle departing.<BR><BR><A href='?src=[UID()];mainmenu=1'>OK</A>"
updateUsrDialog()
GLOB.specops_shuttle_moving_to_station = 1
GLOB.specops_shuttle_time = world.timeofday + SPECOPS_MOVETIME
spawn(0)
specops_process()
else if(href_list["mainmenu"])
temp = null
add_fingerprint(usr)
updateUsrDialog()
return
@@ -1,254 +0,0 @@
//Config stuff
#define SYNDICATE_ELITE_MOVETIME 600 //Time to station is milliseconds. 60 seconds, enough time for everyone to be on the shuttle before it leaves.
#define SYNDICATE_ELITE_STATION_AREATYPE "/area/shuttle/syndicate_elite/station" //Type of the spec ops shuttle area for station
#define SYNDICATE_ELITE_DOCK_AREATYPE "/area/shuttle/syndicate_elite/mothership" //Type of the spec ops shuttle area for dock
GLOBAL_VAR_INIT(syndicate_elite_shuttle_moving_to_station, 0)
GLOBAL_VAR_INIT(syndicate_elite_shuttle_moving_to_mothership, 0)
GLOBAL_VAR_INIT(syndicate_elite_shuttle_at_station, 0)
GLOBAL_VAR_INIT(syndicate_elite_shuttle_can_send, 1)
GLOBAL_VAR_INIT(syndicate_elite_shuttle_time, 0)
GLOBAL_VAR_INIT(syndicate_elite_shuttle_timeleft, 0)
/obj/machinery/computer/syndicate_elite_shuttle
name = "\improper Elite Syndicate Squad shuttle console"
icon = 'icons/obj/computer.dmi'
icon_keyboard = "syndie_key"
icon_screen = "syndishuttle"
light_color = LIGHT_COLOR_PURE_CYAN
req_access = list(ACCESS_SYNDICATE)
bubble_icon = "syndibot"
var/temp = null
var/hacked = 0
var/allowedtocall = 0
/proc/syndicate_elite_process()
var/area/syndicate_mothership/control/syndicate_ship = locate()//To find announcer. This area should exist for this proc to work.
//var/area/syndicate_mothership/elite_squad/elite_squad = locate()//Where is the specops area located?
var/mob/living/silicon/decoy/announcer = locate() in syndicate_ship//We need a fake AI to announce some stuff below. Otherwise it will be wonky.
var/message_tracker[] = list(0,1,2,3,5,10,30,45)//Create a a list with potential time values.
var/message = "THE SYNDICATE ELITE SHUTTLE IS PREPARING FOR LAUNCH"//Initial message shown.
if(announcer)
announcer.say(message)
// message = "ARMORED SQUAD TAKE YOUR POSITION ON GRAVITY LAUNCH PAD"
// announcer.say(message)
while(GLOB.syndicate_elite_shuttle_time - world.timeofday > 0)
var/ticksleft = GLOB.syndicate_elite_shuttle_time - world.timeofday
if(ticksleft > 1e5)
GLOB.syndicate_elite_shuttle_time = world.timeofday // midnight rollover
GLOB.syndicate_elite_shuttle_timeleft = (ticksleft / 10)
//All this does is announce the time before launch.
if(announcer)
var/rounded_time_left = round(GLOB.syndicate_elite_shuttle_timeleft)//Round time so that it will report only once, not in fractions.
if(rounded_time_left in message_tracker)//If that time is in the list for message announce.
message = "ALERT: [rounded_time_left] SECOND[(rounded_time_left!=1)?"S":""] REMAIN"
if(rounded_time_left==0)
message = "ALERT: TAKEOFF"
announcer.say(message)
message_tracker -= rounded_time_left//Remove the number from the list so it won't be called again next cycle.
//Should call all the numbers but lag could mean some issues. Oh well. Not much I can do about that.
sleep(5)
GLOB.syndicate_elite_shuttle_moving_to_station = 0
GLOB.syndicate_elite_shuttle_moving_to_mothership = 0
GLOB.syndicate_elite_shuttle_at_station = 1
if(GLOB.syndicate_elite_shuttle_moving_to_station || GLOB.syndicate_elite_shuttle_moving_to_mothership) return
if(!syndicate_elite_can_move())
to_chat(usr, "<span class='warning'>The Syndicate Elite shuttle is unable to leave.</span>")
return
/*
//Begin Marauder launchpad.
spawn(0)//So it parallel processes it.
for(var/obj/machinery/door/poddoor/M in elite_squad)
switch(M.id)
if("ASSAULT0")
spawn(10)//1 second delay between each.
M.open()
if("ASSAULT1")
spawn(20)
M.open()
if("ASSAULT2")
spawn(30)
M.open()
if("ASSAULT3")
spawn(40)
M.open()
sleep(10)
var/spawn_marauder[] = new()
for(var/obj/effect/landmark/L in GLOB.landmarks_list)
if(L.name == "Marauder Entry")
spawn_marauder.Add(L)
for(var/obj/effect/landmark/L in GLOB.landmarks_list)
if(L.name == "Marauder Exit")
var/obj/effect/portal/P = new(L.loc)
P.invisibility = 101//So it is not seen by anyone.
P.failchance = 0//So it has no fail chance when teleporting.
P.target = pick(spawn_marauder)//Where the marauder will arrive.
spawn_marauder.Remove(P.target)
sleep(10)
for(var/obj/machinery/mass_driver/M in elite_squad)
switch(M.id)
if("ASSAULT0")
spawn(10)
M.drive()
if("ASSAULT1")
spawn(20)
M.drive()
if("ASSAULT2")
spawn(30)
M.drive()
if("ASSAULT3")
spawn(40)
M.drive()
sleep(50)//Doors remain open for 5 seconds.
for(var/obj/machinery/door/poddoor/M in elite_squad)
switch(M.id)//Doors close at the same time.
if("ASSAULT0")
spawn(0)
M.close()
if("ASSAULT1")
spawn(0)
M.close()
if("ASSAULT2")
spawn(0)
M.close()
if("ASSAULT3")
spawn(0)
M.close()
elite_squad.readyreset()//Reset firealarm after the team launched.
*/
//End Marauder launchpad.
for(var/thing in GLOB.landmarks_list)
var/obj/effect/landmark/L = thing
if(L.name == "Syndicate Breach Area")
explosion(L.loc,4,6,8,10,0)
sleep(40)
var/area/start_location = locate(/area/shuttle/syndicate_elite/mothership)
var/area/end_location = locate(/area/shuttle/syndicate_elite/station)
var/list/dstturfs = list()
var/throwy = world.maxy
for(var/turf/T in end_location)
dstturfs = T
if(T.y < throwy)
throwy = T.y
// hey you, get out of the way!
for(var/turf/T in dstturfs)
// find the turf to move things to
var/turf/D = locate(T.x, throwy - 1, 1)
//var/turf/E = get_step(D, SOUTH)
for(var/atom/movable/AM as mob|obj in T)
AM.Move(D)
if(istype(T, /turf/simulated))
qdel(T)
for(var/mob/living/carbon/bug in end_location) // If someone somehow is still in the shuttle's docking area...
bug.gib()
for(var/mob/living/simple_animal/pest in end_location) // And for the other kind of bug...
pest.gib()
start_location.move_contents_to(end_location)
for(var/turf/T in get_area_turfs(end_location) )
var/mob/M = locate(/mob) in T
to_chat(M, "<span class='warning'>You have arrived to [station_name()]. Commence operation!</span>")
/proc/syndicate_elite_can_move()
if(GLOB.syndicate_elite_shuttle_moving_to_station || GLOB.syndicate_elite_shuttle_moving_to_mothership) return 0
else return 1
/obj/machinery/computer/syndicate_elite_shuttle/attack_ai(mob/user as mob)
to_chat(user, "<span class='warning'>Access Denied.</span>")
return 1
/obj/machinery/computer/syndicate_elite_shuttle/attackby(I as obj, user as mob, params)
if(istype(I,/obj/item/card/emag))
to_chat(user, "<span class='notice'>The electronic systems in this console are far too advanced for your primitive hacking peripherals.</span>")
else
return ..()
/obj/machinery/computer/syndicate_elite_shuttle/attack_hand(mob/user as mob)
if(!allowed(user))
to_chat(user, "<span class='warning'>Access Denied.</span>")
return
// if(sent_syndicate_strike_team == 0)
// to_chat(usr, "<span class='warning'>The strike team has not yet deployed.</span>")
// return
if(..())
return
user.set_machine(src)
var/dat
if(temp)
dat = temp
else
dat = {"<BR><B>Special Operations Shuttle</B><HR>
\nLocation: [GLOB.syndicate_elite_shuttle_moving_to_station || GLOB.syndicate_elite_shuttle_moving_to_mothership ? "Departing for [station_name()] in ([GLOB.syndicate_elite_shuttle_timeleft] seconds.)":GLOB.syndicate_elite_shuttle_at_station ? "Station":"Dock"]<BR>
[GLOB.syndicate_elite_shuttle_moving_to_station || GLOB.syndicate_elite_shuttle_moving_to_mothership ? "\n*The Syndicate Elite shuttle is already leaving.*<BR>\n<BR>":GLOB.syndicate_elite_shuttle_at_station ? "\n<A href='?src=[UID()];sendtodock=1'>Shuttle Offline</A><BR>\n<BR>":"\n<A href='?src=[UID()];sendtostation=1'>Depart to [station_name()]</A><BR>\n<BR>"]
\n<A href='?src=[user.UID()];mach_close=computer'>Close</A>"}
user << browse(dat, "window=computer;size=575x450")
onclose(user, "computer")
return
/obj/machinery/computer/syndicate_elite_shuttle/Topic(href, href_list)
if(..())
return 1
if((usr.contents.Find(src) || (in_range(src, usr) && istype(loc, /turf))) || (istype(usr, /mob/living/silicon)))
usr.set_machine(src)
if(href_list["sendtodock"])
if(!GLOB.syndicate_elite_shuttle_at_station|| GLOB.syndicate_elite_shuttle_moving_to_station || GLOB.syndicate_elite_shuttle_moving_to_mothership) return
to_chat(usr, "<span class='notice'>The Syndicate will not allow the Elite Squad shuttle to return.</span>")
return
else if(href_list["sendtostation"])
if(GLOB.syndicate_elite_shuttle_at_station || GLOB.syndicate_elite_shuttle_moving_to_station || GLOB.syndicate_elite_shuttle_moving_to_mothership) return
if(!specops_can_move())
to_chat(usr, "<span class='warning'>The Syndicate Elite shuttle is unable to leave.</span>")
return
to_chat(usr, "<span class='notice'>The Syndicate Elite shuttle will arrive on [station_name()] in [(SYNDICATE_ELITE_MOVETIME/10)] seconds.</span>")
temp = "Shuttle departing.<BR><BR><A href='?src=[UID()];mainmenu=1'>OK</A>"
updateUsrDialog()
GLOB.syndicate_elite_shuttle_moving_to_station = 1
GLOB.syndicate_elite_shuttle_time = world.timeofday + SYNDICATE_ELITE_MOVETIME
spawn(0)
syndicate_elite_process()
else if(href_list["mainmenu"])
temp = null
add_fingerprint(usr)
updateUsrDialog()
return
+130 -132
View File
@@ -104,6 +104,7 @@
circuit = P
user.drop_item()
P.loc = src
name += " ([B.board_name])"
icon_state = "box_2"
state = 3
components = list()
@@ -133,6 +134,7 @@
to_chat(user, "<span class='notice'>You remove the circuit board and other components.</span>")
for(var/obj/item/I in components)
I.loc = src.loc
name = initial(name)
desc = initial(desc)
req_components = null
components = null
@@ -223,61 +225,58 @@ Note: Once everything is added to the public areas, will add MAT_METAL and MAT_G
to destroy them and players will be able to make replacements.
*/
/obj/item/circuitboard/vendor
name = "circuit board (Booze-O-Mat Vendor)"
board_name = "Booze-O-Mat Vendor"
board_type = "machine"
origin_tech = "programming=1"
build_path = /obj/machinery/vending/boozeomat
req_components = list(/obj/item/vending_refill/boozeomat = 1)
var/static/list/vending_names_paths = list(
/obj/machinery/vending/boozeomat = "Booze-O-Mat",
/obj/machinery/vending/coffee = "Solar's Best Hot Drinks",
/obj/machinery/vending/snack = "Getmore Chocolate Corp",
/obj/machinery/vending/chinese = "Mr. Chang",
/obj/machinery/vending/cola = "Robust Softdrinks",
/obj/machinery/vending/cigarette = "ShadyCigs Deluxe",
/obj/machinery/vending/hatdispenser = "Hatlord 9000",
/obj/machinery/vending/suitdispenser = "Suitlord 9000",
/obj/machinery/vending/shoedispenser = "Shoelord 9000",
/obj/machinery/vending/autodrobe = "AutoDrobe",
/obj/machinery/vending/clothing = "ClothesMate",
/obj/machinery/vending/medical = "NanoMed Plus",
/obj/machinery/vending/wallmed = "NanoMed",
/obj/machinery/vending/assist = "Vendomat",
/obj/machinery/vending/engivend = "Engi-Vend",
/obj/machinery/vending/hydronutrients = "NutriMax",
/obj/machinery/vending/hydroseeds = "MegaSeed Servitor",
/obj/machinery/vending/sustenance = "Sustenance Vendor",
/obj/machinery/vending/dinnerware = "Plasteel Chef's Dinnerware Vendor",
/obj/machinery/vending/cart = "PTech",
/obj/machinery/vending/robotics = "Robotech Deluxe",
/obj/machinery/vending/engineering = "Robco Tool Maker",
/obj/machinery/vending/sovietsoda = "BODA",
/obj/machinery/vending/security = "SecTech",
/obj/machinery/vending/crittercare = "CritterCare")
"Booze-O-Mat" = /obj/machinery/vending/boozeomat,
"Solar's Best Hot Drinks" = /obj/machinery/vending/coffee,
"Getmore Chocolate Corp" = /obj/machinery/vending/snack,
"Mr. Chang" = /obj/machinery/vending/chinese,
"Robust Softdrinks" = /obj/machinery/vending/cola,
"ShadyCigs Deluxe" = /obj/machinery/vending/cigarette,
"Hatlord 9000" = /obj/machinery/vending/hatdispenser,
"Suitlord 9000" = /obj/machinery/vending/suitdispenser,
"Shoelord 9000" = /obj/machinery/vending/shoedispenser,
"AutoDrobe" = /obj/machinery/vending/autodrobe,
"ClothesMate" = /obj/machinery/vending/clothing,
"NanoMed Plus" = /obj/machinery/vending/medical,
"NanoMed" = /obj/machinery/vending/wallmed,
"Vendomat" = /obj/machinery/vending/assist,
"YouTool" = /obj/machinery/vending/tool,
"Engi-Vend" = /obj/machinery/vending/engivend,
"NutriMax" = /obj/machinery/vending/hydronutrients,
"MegaSeed Servitor" = /obj/machinery/vending/hydroseeds,
"Sustenance Vendor" = /obj/machinery/vending/sustenance,
"Plasteel Chef's Dinnerware Vendor" = /obj/machinery/vending/dinnerware,
"PTech" = /obj/machinery/vending/cart,
"Robotech Deluxe" = /obj/machinery/vending/robotics,
"Robco Tool Maker" = /obj/machinery/vending/engineering,
"BODA" = /obj/machinery/vending/sovietsoda,
"SecTech" = /obj/machinery/vending/security,
"CritterCare" = /obj/machinery/vending/crittercare)
/obj/item/circuitboard/vendor/screwdriver_act(mob/user, obj/item/I)
. = TRUE
if(!I.use_tool(src, user, 0, volume = I.tool_volume))
return
var/static/list/display_vending_names_paths
if(!display_vending_names_paths)
display_vending_names_paths = list()
for(var/path in vending_names_paths)
display_vending_names_paths[vending_names_paths[path]] = path
var/choice = input(user, "Choose a new brand","Select an Item") as null|anything in display_vending_names_paths
if(loc != user)
to_chat(user, "<span class='notice'>You need to keep [src] in your hands while doing that!</span>")
var/choice = input(user, "Choose a new brand", "Select an Item") as null|anything in vending_names_paths
if(!choice)
return
set_type(display_vending_names_paths[choice])
set_type(choice)
/obj/item/circuitboard/vendor/proc/set_type(obj/machinery/vending/typepath)
/obj/item/circuitboard/vendor/proc/set_type(type)
var/obj/machinery/vending/typepath = vending_names_paths[type]
build_path = typepath
name = "circuit board ([vending_names_paths[build_path]] Vendor)"
board_name = "[type] Vendor"
format_board_name()
req_components = list(initial(typepath.refill_canister) = 1)
/obj/item/circuitboard/smes
name = "circuit board (SMES)"
board_name = "SMES"
build_path = /obj/machinery/power/smes
board_type = "machine"
origin_tech = "programming=3;powerstorage=3;engineering=3"
@@ -287,7 +286,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 1)
/obj/item/circuitboard/emitter
name = "circuit board (Emitter)"
board_name = "Emitter"
build_path = /obj/machinery/power/emitter
board_type = "machine"
origin_tech = "programming=3;powerstorage=4;engineering=4"
@@ -296,7 +295,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 1)
/obj/item/circuitboard/power_compressor
name = "circuit board (Power Compressor)"
board_name = "Power Compressor"
build_path = /obj/machinery/power/compressor
board_type = "machine"
origin_tech = "programming=4;powerstorage=4;engineering=4"
@@ -305,7 +304,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 6)
/obj/item/circuitboard/power_turbine
name = "circuit board (Power Turbine)"
board_name = "Power Turbine"
build_path = /obj/machinery/power/turbine
board_type = "machine"
origin_tech = "programming=4;powerstorage=4;engineering=4"
@@ -314,7 +313,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 6)
/obj/item/circuitboard/thermomachine
name = "Thermomachine (Machine Board)"
board_name = "Thermomachine"
build_path = /obj/machinery/atmospherics/unary/thermomachine
board_type = "machine"
origin_tech = "programming=3;plasmatech=3"
@@ -325,14 +324,14 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/recharger
name = "circuit board (Recharger)"
board_name = "Recharger"
build_path = /obj/machinery/recharger
board_type = "machine"
origin_tech = "powerstorage=3;materials=2"
req_components = list(/obj/item/stock_parts/capacitor = 1)
/obj/item/circuitboard/snow_machine
name = "circuit board (snow machine)"
board_name = "Snow Machine"
build_path = /obj/machinery/snow_machine
board_type = "machine"
origin_tech = "programming=2;materials=2"
@@ -341,7 +340,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/micro_laser = 1)
/obj/item/circuitboard/biogenerator
name = "circuit board (Biogenerator)"
board_name = "Biogenerator"
build_path = /obj/machinery/biogenerator
board_type = "machine"
origin_tech = "programming=2;biotech=3;materials=3"
@@ -352,7 +351,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/plantgenes
name = "Plant DNA Manipulator (Machine Board)"
board_name = "Plant DNA Manipulator"
build_path = /obj/machinery/plantgenes
board_type = "machine"
origin_tech = "programming=3;biotech=3"
@@ -365,7 +364,7 @@ to destroy them and players will be able to make replacements.
/obj/item/circuitboard/plantgenes/vault
/obj/item/circuitboard/seed_extractor
name = "circuit board (Seed Extractor)"
board_name = "Seed Extractor"
build_path = /obj/machinery/seed_extractor
board_type = "machine"
origin_tech = "programming=1"
@@ -374,7 +373,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 1)
/obj/item/circuitboard/hydroponics
name = "circuit board (Hydroponics Tray)"
board_name = "Hydroponics Tray"
build_path = /obj/machinery/hydroponics/constructable
board_type = "machine"
origin_tech = "programming=1;biotech=2"
@@ -384,7 +383,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/microwave
name = "circuit board (Microwave)"
board_name = "Microwave"
build_path = /obj/machinery/kitchen_machine/microwave
board_type = "machine"
origin_tech = "programming=2;magnets=2"
@@ -394,7 +393,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/oven
name = "circuit board (Oven)"
board_name = "Oven"
build_path = /obj/machinery/kitchen_machine/oven
board_type = "machine"
origin_tech = "programming=2;magnets=2"
@@ -404,7 +403,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/grill
name = "circuit board (Grill)"
board_name = "Grill"
build_path = /obj/machinery/kitchen_machine/grill
board_type = "machine"
origin_tech = "programming=2;magnets=2"
@@ -414,7 +413,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/candy_maker
name = "circuit board (Candy Maker)"
board_name = "Candy Maker"
build_path = /obj/machinery/kitchen_machine/candy_maker
board_type = "machine"
origin_tech = "programming=2;magnets=2"
@@ -424,7 +423,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/deepfryer
name = "circuit board (Deep Fryer)"
board_name = "Deep Fryer"
build_path = /obj/machinery/cooker/deepfryer
board_type = "machine"
origin_tech = "programming=1"
@@ -433,7 +432,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/cable_coil = 5)
/obj/item/circuitboard/gibber
name = "circuit board (Gibber)"
board_name = "Gibber"
build_path = /obj/machinery/gibber
board_type = "machine"
origin_tech = "programming=2;engineering=2"
@@ -442,7 +441,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 1)
/obj/item/circuitboard/tesla_coil
name = "circuit board (Tesla Coil)"
board_name = "Tesla Coil"
build_path = /obj/machinery/power/tesla_coil
board_type = "machine"
origin_tech = "programming=3;magnets=3;powerstorage=3"
@@ -450,7 +449,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 1)
/obj/item/circuitboard/grounding_rod
name = "circuit board (Grounding Rod)"
board_name = "Grounding Rod"
build_path = /obj/machinery/power/grounding_rod
board_type = "machine"
origin_tech = "programming=3;powerstorage=3;magnets=3;plasmatech=2"
@@ -458,7 +457,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 1)
/obj/item/circuitboard/processor
name = "circuit board (Food processor)"
board_name = "Food Processor"
build_path = /obj/machinery/processor
board_type = "machine"
origin_tech = "programming=1"
@@ -467,7 +466,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 1)
/obj/item/circuitboard/recycler
name = "circuit board (Recycler)"
board_name = "Recycler"
build_path = /obj/machinery/recycler
board_type = "machine"
origin_tech = "programming=2;engineering=2"
@@ -476,51 +475,49 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 1)
/obj/item/circuitboard/smartfridge
name = "circuit board (Smartfridge)"
board_name = "Smartfridge"
build_path = /obj/machinery/smartfridge
board_type = "machine"
origin_tech = "programming=1"
req_components = list(
/obj/item/stock_parts/matter_bin = 1)
var/list/fridge_names_paths = list(
"\improper SmartFridge" = /obj/machinery/smartfridge,
"\improper MegaSeed Servitor" = /obj/machinery/smartfridge/seeds,
"\improper Refrigerated Medicine Storage" = /obj/machinery/smartfridge/medbay,
"\improper Slime Extract Storage" = /obj/machinery/smartfridge/secure/extract,
"\improper Secure Refrigerated Medicine Storage" = /obj/machinery/smartfridge/secure/medbay,
"\improper Smart Chemical Storage" = /obj/machinery/smartfridge/secure/chemistry,
"smart virus storage" = /obj/machinery/smartfridge/secure/chemistry/virology,
"\improper Drink Showcase" = /obj/machinery/smartfridge/drinks,
"disk compartmentalizer" = /obj/machinery/smartfridge/disks
)
var/static/list/fridge_names_paths = list(
"SmartFridge" = /obj/machinery/smartfridge,
"MegaSeed Servitor" = /obj/machinery/smartfridge/seeds,
"Refrigerated Medicine Storage" = /obj/machinery/smartfridge/medbay,
"Slime Extract Storage" = /obj/machinery/smartfridge/secure/extract,
"Secure Refrigerated Medicine Storage" = /obj/machinery/smartfridge/secure/medbay,
"Smart Chemical Storage" = /obj/machinery/smartfridge/secure/chemistry,
"Smart Virus Storage" = /obj/machinery/smartfridge/secure/chemistry/virology,
"Drink Showcase" = /obj/machinery/smartfridge/drinks,
"Disk Compartmentalizer" = /obj/machinery/smartfridge/disks)
/obj/item/circuitboard/smartfridge/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/screwdriver))
set_type(null, user)
/obj/item/circuitboard/smartfridge/screwdriver_act(mob/living/user, obj/item/I)
. = TRUE
if(!I.use_tool(src, user, 0, volume = I.tool_volume))
return
return ..()
var/choice = input(user, "Circuit Setting", "What would you change the board setting to?") as null|anything in fridge_names_paths
if(!choice)
return
set_type(user, choice)
/obj/item/circuitboard/smartfridge/proc/set_type(typepath, mob/user)
var/new_name = ""
if(!typepath)
new_name = input("Circuit Setting", "What would you change the board setting to?") in fridge_names_paths
typepath = fridge_names_paths[new_name]
/obj/item/circuitboard/smartfridge/proc/set_type(mob/user, type)
if(!ispath(type))
board_name = type
type = fridge_names_paths[type]
else
for(var/name in fridge_names_paths)
if(fridge_names_paths[name] == typepath)
new_name = name
if(fridge_names_paths[name] == type)
board_name = name
break
build_path = typepath
name = new_name
if(findtextEx(new_name, "\improper"))
new_name = replacetext(new_name, "\improper", "")
build_path = type
format_board_name()
if(user)
to_chat(user, "<span class='notice'>You set the board to [new_name].</span>")
to_chat(user, "<span class='notice'>You set the board to [board_name].</span>")
/obj/item/circuitboard/monkey_recycler
name = "circuit board (Monkey Recycler)"
board_name = "Monkey Recycler"
build_path = /obj/machinery/monkey_recycler
board_type = "machine"
origin_tech = "programming=1;biotech=2"
@@ -529,7 +526,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/manipulator = 1)
/obj/item/circuitboard/holopad
name = "circuit board (AI Holopad)"
board_name = "AI Holopad"
build_path = /obj/machinery/hologram/holopad
board_type = "machine"
origin_tech = "programming=1"
@@ -537,7 +534,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 1)
/obj/item/circuitboard/chem_dispenser
name = "circuit board (Chem Dispenser)"
board_name = "Chem Dispenser"
build_path = /obj/machinery/chem_dispenser
board_type = "machine"
origin_tech = "materials=4;programming=4;plasmatech=4;biotech=3"
@@ -548,7 +545,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/cell = 1)
/obj/item/circuitboard/chem_master
name = "circuit board (ChemMaster 3000)"
board_name = "ChemMaster 3000"
build_path = /obj/machinery/chem_master
board_type = "machine"
origin_tech = "materials=3;programming=2;biotech=3"
@@ -573,11 +570,11 @@ to destroy them and players will be able to make replacements.
to_chat(user, "<span class='notice'>You change the circuit board setting to \"[new_name]\".</span>")
/obj/item/circuitboard/chem_master/condi_master
name = "circuit board (CondiMaster 3000)"
board_name = "CondiMaster 3000"
build_path = /obj/machinery/chem_master/condimaster
/obj/item/circuitboard/chem_heater
name = "circuit board (Chemical Heater)"
board_name = "Chemical Heater"
build_path = /obj/machinery/chem_heater
board_type = "machine"
origin_tech = "programming=2;engineering=2;biotech=2"
@@ -586,7 +583,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/reagentgrinder
name = "circuit board (All-In-One Grinder)"
board_name = "All-In-One Grinder"
build_path = /obj/machinery/reagentgrinder/empty
board_type = "machine"
origin_tech = "materials=2;engineering=2;biotech=2"
@@ -596,7 +593,7 @@ to destroy them and players will be able to make replacements.
//Almost the same recipe as destructive analyzer to give people choices.
/obj/item/circuitboard/experimentor
name = "circuit board (E.X.P.E.R.I-MENTOR)"
board_name = "E.X.P.E.R.I-MENTOR"
build_path = /obj/machinery/r_n_d/experimentor
board_type = "machine"
origin_tech = "magnets=1;engineering=1;programming=1;biotech=1;bluespace=2"
@@ -606,7 +603,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/micro_laser = 2)
/obj/item/circuitboard/destructive_analyzer
name = "Circuit board (Destructive Analyzer)"
board_name = "Destructive Analyzer"
build_path = /obj/machinery/r_n_d/destructive_analyzer
board_type = "machine"
origin_tech = "magnets=2;engineering=2;programming=2"
@@ -616,7 +613,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/micro_laser = 1)
/obj/item/circuitboard/autolathe
name = "Circuit board (Autolathe)"
board_name = "Autolathe"
build_path = /obj/machinery/autolathe
board_type = "machine"
origin_tech = "engineering=2;programming=2"
@@ -630,7 +627,7 @@ to destroy them and players will be able to make replacements.
build_path = /obj/machinery/autolathe/syndicate
/obj/item/circuitboard/protolathe
name = "Circuit board (Protolathe)"
board_name = "Protolathe"
build_path = /obj/machinery/r_n_d/protolathe
board_type = "machine"
origin_tech = "engineering=2;programming=2"
@@ -640,15 +637,15 @@ to destroy them and players will be able to make replacements.
/obj/item/reagent_containers/glass/beaker = 2)
/obj/item/circuitboard/chem_dispenser/soda
name = "Circuit board (Soda Machine)"
board_name = "Soda Machine"
build_path = /obj/machinery/chem_dispenser/soda
/obj/item/circuitboard/chem_dispenser/beer
name = "Circuit board (Beer Machine)"
board_name = "Beer Machine"
build_path = /obj/machinery/chem_dispenser/beer
/obj/item/circuitboard/circuit_imprinter
name = "Circuit board (Circuit Imprinter)"
board_name = "Circuit Imprinter"
build_path = /obj/machinery/r_n_d/circuit_imprinter
board_type = "machine"
origin_tech = "engineering=2;programming=2"
@@ -658,7 +655,7 @@ to destroy them and players will be able to make replacements.
/obj/item/reagent_containers/glass/beaker = 2)
/obj/item/circuitboard/pacman
name = "Circuit Board (PACMAN-type Generator)"
board_name = "PACMAN-type Generator"
build_path = /obj/machinery/power/port_gen/pacman
board_type = "machine"
origin_tech = "programming=2;powerstorage=3;plasmatech=3;engineering=3"
@@ -669,17 +666,17 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 1)
/obj/item/circuitboard/pacman/super
name = "Circuit Board (SUPERPACMAN-type Generator)"
board_name = "SUPERPACMAN-type Generator"
build_path = /obj/machinery/power/port_gen/pacman/super
origin_tech = "programming=3;powerstorage=4;engineering=4"
/obj/item/circuitboard/pacman/mrs
name = "Circuit Board (MRSPACMAN-type Generator)"
board_name = "MRSPACMAN-type Generator"
build_path = /obj/machinery/power/port_gen/pacman/mrs
origin_tech = "programming=3;powerstorage=4;engineering=4;plasmatech=4"
/obj/item/circuitboard/rdserver
name = "Circuit Board (R&D Server)"
board_name = "R&D Server"
build_path = /obj/machinery/r_n_d/server
board_type = "machine"
origin_tech = "programming=3"
@@ -688,7 +685,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/scanning_module = 1)
/obj/item/circuitboard/mechfab
name = "Circuit board (Exosuit Fabricator)"
board_name = "Exosuit Fabricator"
build_path = /obj/machinery/mecha_part_fabricator
board_type = "machine"
origin_tech = "programming=2;engineering=2"
@@ -699,7 +696,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/podfab
name = "Circuit board (Spacepod Fabricator)"
board_name = "Spacepod Fabricator"
build_path = /obj/machinery/mecha_part_fabricator/spacepod
board_type = "machine"
origin_tech = "programming=2;engineering=2"
@@ -711,7 +708,7 @@ to destroy them and players will be able to make replacements.
/obj/item/circuitboard/clonepod
name = "Circuit board (Clone Pod)"
board_name = "Clone Pod"
build_path = /obj/machinery/clonepod
board_type = "machine"
origin_tech = "programming=2;biotech=2"
@@ -722,7 +719,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/clonescanner
name = "Circuit board (Cloning Scanner)"
board_name = "Cloning Scanner"
build_path = /obj/machinery/dna_scannernew
board_type = "machine"
origin_tech = "programming=2;biotech=2"
@@ -734,7 +731,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/cable_coil = 2,)
/obj/item/circuitboard/mech_recharger
name = "circuit board (Mech Bay Recharger)"
board_name = "Mech Bay Recharger"
build_path = /obj/machinery/mech_bay_recharge_port
board_type = "machine"
origin_tech = "programming=3;powerstorage=3;engineering=3"
@@ -743,7 +740,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/capacitor = 5)
/obj/item/circuitboard/teleporter_hub
name = "circuit board (Teleporter Hub)"
board_name = "Teleporter Hub"
build_path = /obj/machinery/teleport/hub
board_type = "machine"
origin_tech = "programming=3;engineering=4;bluespace=4;materials=4"
@@ -752,7 +749,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/matter_bin = 1)
/obj/item/circuitboard/teleporter_station
name = "circuit board (Teleporter Station)"
board_name = "Teleporter Station"
build_path = /obj/machinery/teleport/station
board_type = "machine"
origin_tech = "programming=4;engineering=4;bluespace=4;plasmatech=3"
@@ -762,7 +759,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/teleporter_perma
name = "circuit board (Permanent Teleporter)"
board_name = "Permanent Teleporter"
build_path = /obj/machinery/teleport/perma
board_type = "machine"
origin_tech = "programming=3;engineering=4;bluespace=4;materials=4"
@@ -781,7 +778,7 @@ to destroy them and players will be able to make replacements.
return ..()
/obj/item/circuitboard/telesci_pad
name = "Circuit board (Telepad)"
board_name = "Telepad"
build_path = /obj/machinery/telepad
board_type = "machine"
origin_tech = "programming=4;engineering=3;plasmatech=4;bluespace=4"
@@ -792,7 +789,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/quantumpad
name = "circuit board (Quantum Pad)"
board_name = "Quantum Pad"
build_path = /obj/machinery/quantumpad
board_type = "machine"
origin_tech = "programming=3;engineering=3;plasmatech=3;bluespace=4"
@@ -803,7 +800,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/cable_coil = 1)
/obj/item/circuitboard/sleeper
name = "circuit board (Sleeper)"
board_name = "Sleeper"
build_path = /obj/machinery/sleeper
board_type = "machine"
origin_tech = "programming=3;biotech=2;engineering=3"
@@ -814,16 +811,16 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 2)
/obj/item/circuitboard/sleeper/syndicate
name = "circuit board (Sleeper Syndicate)"
board_name = "Sleeper - Syndicate"
build_path = /obj/machinery/sleeper/syndie
/obj/item/circuitboard/sleeper/survival
name = "circuit board (Sleeper Survival Pod)"
board_name = "Sleeper - Survival Pod"
build_path = /obj/machinery/sleeper/survival_pod
/obj/item/circuitboard/bodyscanner
name = "circuit board (Body Scanner)"
board_name = "Body Scanner"
build_path = /obj/machinery/bodyscanner
board_type = "machine"
origin_tech = "programming=3;biotech=2;engineering=3"
@@ -833,7 +830,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 2)
/obj/item/circuitboard/cryo_tube
name = "circuit board (Cryotube)"
board_name = "Cryotube"
build_path = /obj/machinery/atmospherics/unary/cryo_cell
board_type = "machine"
origin_tech = "programming=4;biotech=3;engineering=4;plasmatech=3"
@@ -843,7 +840,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 4)
/obj/item/circuitboard/cyborgrecharger
name = "circuit board (Cyborg Recharger)"
board_name = "Cyborg Recharger"
build_path = /obj/machinery/recharge_station
board_type = "machine"
origin_tech = "powerstorage=3;engineering=3"
@@ -854,21 +851,22 @@ to destroy them and players will be able to make replacements.
// Telecomms circuit boards:
/obj/item/circuitboard/tcomms/relay
name = "Circuit Board (Telecommunications Relay)"
board_name = "Telecommunications Relay"
build_path = /obj/machinery/tcomms/relay
board_type = "machine"
origin_tech = "programming=2;engineering=2;bluespace=2"
req_components = list(/obj/item/stock_parts/manipulator = 2, /obj/item/stack/cable_coil = 2)
/obj/item/circuitboard/tcomms/core
name = "Circuit Board (Telecommunications Core)"
board_name = "Telecommunications Core"
build_path = /obj/machinery/tcomms/core
board_type = "machine"
origin_tech = "programming=2;engineering=2"
req_components = list(/obj/item/stock_parts/manipulator = 2, /obj/item/stack/cable_coil = 2)
// End telecomms circuit boards
/obj/item/circuitboard/ore_redemption
name = "circuit board (Ore Redemption)"
board_name = "Ore Redemption"
build_path = /obj/machinery/mineral/ore_redemption
board_type = "machine"
origin_tech = "programming=1;engineering=2"
@@ -880,15 +878,15 @@ to destroy them and players will be able to make replacements.
/obj/item/assembly/igniter = 1)
/obj/item/circuitboard/ore_redemption/golem
name = "circuit board (Golem Ore Redemption)"
board_name = "Ore Redemption - Golem"
build_path = /obj/machinery/mineral/ore_redemption/golem
/obj/item/circuitboard/ore_redemption/labor
name = "circuit board (Labor Ore Redemption)"
board_name = "Ore Redemption - Labour"
build_path = /obj/machinery/mineral/ore_redemption/labor
/obj/item/circuitboard/mining_equipment_vendor
name = "circuit board (Mining Equipment Vendor)"
board_name = "Mining Equipment Vendor"
build_path = /obj/machinery/mineral/equipment_vendor
board_type = "machine"
origin_tech = "programming=1;engineering=3"
@@ -897,15 +895,15 @@ to destroy them and players will be able to make replacements.
/obj/item/stock_parts/matter_bin = 3)
/obj/item/circuitboard/mining_equipment_vendor/golem
name = "circuit board (Mining Equipment Vendor)"
board_name = "Golem Equipment Vendor"
build_path = /obj/machinery/mineral/equipment_vendor/golem
/obj/item/circuitboard/mining_equipment_vendor/labor
name = "circuit board (Labor Equipment Vendor)"
board_name = "Labour Equipment Vendor"
build_path = /obj/machinery/mineral/equipment_vendor/labor
/obj/item/circuitboard/clawgame
name = "circuit board (Claw Game)"
board_name = "Claw Game"
build_path = /obj/machinery/arcade/claw
board_type = "machine"
origin_tech = "programming=1"
@@ -916,7 +914,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/prize_counter
name = "circuit board (Prize Counter)"
board_name = "Prize Counter"
build_path = /obj/machinery/prize_counter
board_type = "machine"
origin_tech = "programming=1"
@@ -927,7 +925,7 @@ to destroy them and players will be able to make replacements.
/obj/item/stack/cable_coil = 1)
/obj/item/circuitboard/gameboard
name = "circuit board (Virtual Gameboard)"
board_name = "Virtual Gameboard"
build_path = /obj/machinery/gameboard
board_type = "machine"
origin_tech = "programming=1"
+6 -2
View File
@@ -170,12 +170,12 @@
dispense_item(I)
/obj/item/circuitboard/cryopodcontrol
name = "Circuit board (Cryogenic Oversight Console)"
board_name = "Cryogenic Oversight Console"
build_path = "/obj/machinery/computer/cryopod"
origin_tech = "programming=1"
/obj/item/circuitboard/robotstoragecontrol
name = "Circuit board (Robotic Storage Console)"
board_name = "Robotic Storage Console"
build_path = "/obj/machinery/computer/cryopod/robot"
origin_tech = "programming=1"
@@ -720,6 +720,10 @@
// Won't announce when used for cryoing.
silent = TRUE
/obj/machinery/cryopod/offstation/right
orient_right = TRUE
icon_state = "body_scanner_0-r"
/obj/machinery/computer/cryopod/robot
name = "robotic storage console"
desc = "An interface between crew and the robotic storage systems"
+2
View File
@@ -1188,6 +1188,7 @@ About the new airlock wires panel:
if(!density)
return TRUE
SEND_SIGNAL(src, COMSIG_AIRLOCK_OPEN)
operating = TRUE
update_icon(AIRLOCK_OPENING, 1)
sleep(1)
@@ -1228,6 +1229,7 @@ About the new airlock wires panel:
if(killthis)
killthis.ex_act(EXPLODE_HEAVY)//Smashin windows
SEND_SIGNAL(src, COMSIG_AIRLOCK_CLOSE)
operating = TRUE
update_icon(AIRLOCK_CLOSING, 1)
layer = CLOSED_DOOR_LAYER
+2
View File
@@ -266,6 +266,7 @@
return TRUE
if(operating)
return
SEND_SIGNAL(src, COMSIG_DOOR_OPEN)
operating = TRUE
do_animate("opening")
set_opacity(0)
@@ -295,6 +296,7 @@
autoclose_in(60)
return
SEND_SIGNAL(src, COMSIG_DOOR_CLOSE)
operating = TRUE
do_animate("closing")
+2
View File
@@ -145,6 +145,8 @@
else if(our_rpd.mode == RPD_FLIP_MODE)
flip()
else if(our_rpd.mode == RPD_DELETE_MODE)
if(pipe_type == PIPE_CIRCULATOR) //Skip TEG heat circulators, they aren't really pipes
return ..()
our_rpd.delete_single_pipe(user, src)
else
return ..()
+6 -1
View File
@@ -657,6 +657,7 @@ GLOBAL_LIST_EMPTY(turret_icons)
qdel(flick_holder)
set_raised_raising(FALSE, FALSE)
set_angle(0)
update_icon()
/obj/machinery/porta_turret/on_assess_perp(mob/living/carbon/human/perp)
@@ -678,7 +679,8 @@ GLOBAL_LIST_EMPTY(turret_icons)
last_target = target
if(has_cover)
popUp() //pop the turret up if it's not already up.
setDir(get_dir(src, target)) //even if you can't shoot, follow the target
// Set angle
set_angle(get_angle(src, target))
shootAt(target)
return TRUE
@@ -842,6 +844,9 @@ GLOBAL_LIST_EMPTY(turret_icons)
if(!user.unEquip(I))
to_chat(user, "<span class='notice'>\the [I] is stuck to your hand, you cannot put it in \the [src]</span>")
return
if(!E.can_fit_in_turrets)
to_chat(user, "<span class='notice'>[I] will not operate correctly in [src].</span>")
return
installation = I.type //installation becomes I.type
gun_charge = E.cell.charge //the gun's charge is stored in gun_charge
to_chat(user, "<span class='notice'>You add [I] to the turret.</span>")
+31 -15
View File
@@ -161,7 +161,7 @@
name = "syndicate suit storage unit"
suit_type = /obj/item/clothing/suit/space/hardsuit/syndi
mask_type = /obj/item/clothing/mask/gas/syndicate
storage_type = /obj/item/tank/jetpack/oxygen/harness
storage_type = /obj/item/tank/internals/oxygen/red
req_access = list(ACCESS_SYNDICATE)
safeties = FALSE //in a syndicate base, everything can be used as a murder weapon at a moment's notice.
@@ -331,26 +331,42 @@
if(default_deconstruction_screwdriver(user, "panel", "close", I))
I.play_tool_sound(user, I.tool_volume)
/**
* Tries to store the item into whatever slot it can go, returns true if the item is stored successfully.
*
**/
/obj/machinery/suit_storage_unit/proc/store_item(obj/item/I, mob/user)
. = FALSE
if(istype(I, /obj/item/clothing/suit) && !suit)
suit = I
. = TRUE
if(try_store_item(I, user))
suit = I
return TRUE
if(istype(I, /obj/item/clothing/head) && !helmet)
helmet = I
. = TRUE
if(try_store_item(I, user))
helmet = I
return TRUE
if(istype(I, /obj/item/clothing/mask) && !mask)
mask = I
. = TRUE
if(try_store_item(I, user))
mask = I
return TRUE
if(istype(I, /obj/item/clothing/shoes) && !boots)
boots = I
. = TRUE
if((istype(I, /obj/item/tank) || I.w_class <= WEIGHT_CLASS_SMALL) && !storage && !.)
storage = I
. = TRUE
if(.)
user.drop_item()
if(try_store_item(I, user))
boots = I
return TRUE
if((istype(I, /obj/item/tank) || I.w_class <= WEIGHT_CLASS_SMALL) && !storage)
if(try_store_item(I, user))
storage = I
return TRUE
return FALSE
/**
* Tries to store the item, returns true if it's moved successfully, false otherwise (because of nodrop etc)
*
**/
/obj/machinery/suit_storage_unit/proc/try_store_item(obj/item/I, mob/user)
if(user.drop_item())
I.forceMove(src)
return TRUE
return FALSE
/obj/machinery/suit_storage_unit/power_change()
+6 -3
View File
@@ -313,7 +313,7 @@
name = "teleporter hub"
desc = "It's the hub of a teleporting machine."
icon_state = "tele0"
var/accurate = FALSE
var/accurate = 0
use_power = IDLE_POWER_USE
idle_power_usage = 10
active_power_usage = 2000
@@ -353,6 +353,8 @@
for(var/obj/item/stock_parts/matter_bin/M in component_parts)
A += M.rating
accurate = A
if(accurate >= 3)
calibrated = TRUE
/obj/machinery/teleport/hub/proc/link_power_station()
if(power_station)
@@ -401,12 +403,13 @@
if(!calibrated && com.cc_beacon)
visible_message("<span class='alert'>Cannot lock on target. Please calibrate the teleporter before attempting long range teleportation.</span>")
else if(!calibrated && prob(25 - ((accurate) * 10)) && !com.cc_beacon) //oh dear a problem
var/list/target_z = levels_by_trait(REACHABLE)
var/list/target_z = levels_by_trait(SPAWN_RUINS)
target_z -= M.z //Where to sir? Anywhere but here.
. = do_teleport(M, locate(rand((2*TRANSITIONEDGE), world.maxx - (2*TRANSITIONEDGE)), rand((2*TRANSITIONEDGE), world.maxy - (2*TRANSITIONEDGE)), pick(target_z)), 2, bypass_area_flag = com.area_bypass)
else
. = do_teleport(M, com.target, bypass_area_flag = com.area_bypass)
calibrated = FALSE
if(accurate < 3)
calibrated = FALSE
/obj/machinery/teleport/hub/update_icon()
if(panel_open)
+20 -205
View File
@@ -101,16 +101,24 @@
var/force_no_power_icon_state = FALSE
/obj/machinery/vending/Initialize(mapload)
. = ..()
var/build_inv = FALSE
if(!refill_canister)
build_inv = TRUE
. = ..()
else
component_parts = list()
var/obj/item/circuitboard/vendor/V = new
V.set_type(replacetext(name, "\improper", ""))
component_parts += V
component_parts += new refill_canister
RefreshParts()
wires = new(src)
if(build_inv) //non-constructable vending machine
build_inventory(products, product_records)
build_inventory(contraband, hidden_records)
build_inventory(premium, coin_records)
for (var/datum/data/vending_product/R in (product_records + coin_records + hidden_records))
for(var/datum/data/vending_product/R in (product_records + coin_records + hidden_records))
var/obj/item/I = R.product_path
var/pp = replacetext(replacetext("[R.product_path]", "/obj/item/", ""), "/", "-")
imagelist[pp] = "[icon2base64(icon(initial(I.icon), initial(I.icon_state)))]"
@@ -887,14 +895,6 @@
ads_list = list("Only the finest!","Have some tools.","The most robust equipment.","The finest gear in space!")
refill_canister = /obj/item/vending_refill/assist
/obj/machinery/vending/assist/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/assist(null)
RefreshParts()
return ..()
/obj/machinery/vending/boozeomat
name = "\improper Booze-O-Mat"
@@ -934,15 +934,6 @@
/obj/machinery/vending/boozeomat/syndicate_access
req_access = list(ACCESS_SYNDICATE)
/obj/machinery/vending/boozeomat/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/boozeomat(null)
RefreshParts()
return ..()
/obj/machinery/vending/coffee
name = "\improper Hot Drinks machine"
@@ -964,15 +955,6 @@
/obj/machinery/vending/coffee/free
prices = list()
/obj/machinery/vending/coffee/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/coffee(null)
RefreshParts()
return ..()
/obj/machinery/vending/coffee/item_slot_check(mob/user, obj/item/I)
if(!(istype(I, /obj/item/reagent_containers/glass) || istype(I, /obj/item/reagent_containers/food/drinks)))
return FALSE
@@ -1029,14 +1011,6 @@
/obj/machinery/vending/snack/free
prices = list()
/obj/machinery/vending/snack/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/snack(null)
RefreshParts()
return ..()
/obj/machinery/vending/chinese
name = "\improper Mr. Chang"
@@ -1052,14 +1026,6 @@
/obj/machinery/vending/chinese/free
prices = list()
/obj/machinery/vending/chinese/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/chinese(null)
RefreshParts()
return ..()
/obj/machinery/vending/cola
name = "\improper Robust Softdrinks"
@@ -1079,15 +1045,6 @@
/obj/machinery/vending/cola/free
prices = list()
/obj/machinery/vending/cola/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/cola(null)
RefreshParts()
return ..()
/obj/machinery/vending/cart
name = "\improper PTech"
@@ -1107,14 +1064,6 @@
/obj/machinery/vending/cart/free
prices = list()
/obj/machinery/vending/cart/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/cart(null)
RefreshParts()
return ..()
/obj/machinery/vending/liberationstation
name = "\improper Liberation Station"
@@ -1161,6 +1110,7 @@
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 0, bio = 0, rad = 0, fire = 100, acid = 50)
resistance_flags = FIRE_PROOF
/obj/machinery/vending/cigarette
name = "cigarette machine"
desc = "If you want to get cancer, might as well do it in style."
@@ -1190,6 +1140,7 @@
/obj/machinery/vending/cigarette/syndicate/free
prices = list()
/obj/machinery/vending/cigarette/beach //Used in the lavaland_biodome_beach.dmm ruin
name = "\improper ShadyCigs Ultra"
desc = "Now with extra premium products!"
@@ -1208,14 +1159,6 @@
/obj/item/lighter/zippo = 3)
prices = list()
/obj/machinery/vending/cigarette/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/cigarette(null)
RefreshParts()
return ..()
/obj/machinery/vending/medical
name = "\improper NanoMed Plus"
@@ -1242,14 +1185,6 @@
name = "\improper SyndiMed Plus"
req_access = list(ACCESS_SYNDICATE)
/obj/machinery/vending/medical/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/medical(null)
RefreshParts()
return ..()
/obj/machinery/vending/plasmaresearch
name = "\improper Toximate 3000"
@@ -1258,6 +1193,7 @@
/obj/item/wirecutters = 1, /obj/item/assembly/timer = 8)
contraband = list(/obj/item/flashlight = 5, /obj/item/assembly/voice = 3, /obj/item/assembly/health = 3, /obj/item/assembly/infra = 3)
/obj/machinery/vending/wallmed
name = "\improper NanoMed"
desc = "Wall-mounted Medical Equipment dispenser."
@@ -1271,14 +1207,6 @@
resistance_flags = FIRE_PROOF
refill_canister = /obj/item/vending_refill/wallmed
/obj/machinery/vending/wallmed/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/wallmed(null)
RefreshParts()
return ..()
/obj/machinery/vending/wallmed/syndicate
name = "\improper SyndiMed Plus"
@@ -1290,6 +1218,7 @@
products = list(/obj/item/stack/medical/bruise_pack = 2,/obj/item/stack/medical/ointment = 2,/obj/item/reagent_containers/hypospray/autoinjector = 4,/obj/item/healthanalyzer = 1)
contraband = list(/obj/item/reagent_containers/syringe/charcoal = 4,/obj/item/reagent_containers/syringe/antiviral = 4,/obj/item/reagent_containers/food/pill/tox = 1)
/obj/machinery/vending/security
name = "\improper SecTech"
desc = "A security equipment vendor."
@@ -1303,14 +1232,6 @@
contraband = list(/obj/item/clothing/glasses/sunglasses = 2,/obj/item/storage/fancy/donut_box = 2,/obj/item/hailer = 5)
refill_canister = /obj/item/vending_refill/security
/obj/machinery/vending/security/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/security(null)
RefreshParts()
return ..()
/obj/machinery/vending/hydronutrients
name = "\improper NutriMax"
@@ -1324,14 +1245,6 @@
contraband = list(/obj/item/reagent_containers/glass/bottle/ammonia = 10,/obj/item/reagent_containers/glass/bottle/diethylamine = 5)
refill_canister = /obj/item/vending_refill/hydronutrients
/obj/machinery/vending/hydronutrients/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/hydronutrients(null)
RefreshParts()
return ..()
/obj/machinery/vending/hydroseeds
name = "\improper MegaSeed Servitor"
@@ -1394,14 +1307,6 @@
premium = list(/obj/item/reagent_containers/spray/waterflower = 1)
refill_canister = /obj/item/vending_refill/hydroseeds
/obj/machinery/vending/hydroseeds/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/hydroseeds(null)
RefreshParts()
return ..()
/obj/machinery/vending/magivend
name = "\improper MagiVend"
@@ -1429,6 +1334,7 @@
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 0, bio = 0, rad = 0, fire = 100, acid = 50)
resistance_flags = FIRE_PROOF
/obj/machinery/vending/autodrobe
name = "\improper AutoDrobe"
desc = "A vending machine for costumes."
@@ -1564,14 +1470,6 @@
/obj/item/clothing/head/cuban_hat = 1)
refill_canister = /obj/item/vending_refill/autodrobe
/obj/machinery/vending/autodrobe/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/autodrobe(null)
RefreshParts()
return ..()
/obj/machinery/vending/dinnerware
name = "\improper Plasteel Chef's Dinnerware Vendor"
@@ -1602,14 +1500,6 @@
contraband = list(/obj/item/kitchen/rollingpin = 2, /obj/item/kitchen/knife/butcher = 2)
refill_canister = /obj/item/vending_refill/dinnerware
/obj/machinery/vending/dinnerware/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/dinnerware(null)
RefreshParts()
return ..()
/obj/machinery/vending/sovietsoda
name = "\improper BODA"
@@ -1621,14 +1511,6 @@
resistance_flags = FIRE_PROOF
refill_canister = /obj/item/vending_refill/sovietsoda
/obj/machinery/vending/sovietsoda/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/sovietsoda(null)
RefreshParts()
return ..()
/obj/machinery/vending/tool
name = "\improper YouTool"
@@ -1639,9 +1521,11 @@
/obj/item/wrench = 5,/obj/item/analyzer = 5,/obj/item/t_scanner = 5,/obj/item/screwdriver = 5)
contraband = list(/obj/item/weldingtool/hugetank = 2,/obj/item/clothing/gloves/color/fyellow = 2)
premium = list(/obj/item/clothing/gloves/color/yellow = 1)
refill_canister = /obj/item/vending_refill/youtool
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 0, bio = 0, rad = 0, fire = 100, acid = 70)
resistance_flags = FIRE_PROOF
/obj/machinery/vending/engivend
name = "\improper Engi-Vend"
desc = "Spare tool vending. What? Did you expect some witty description?"
@@ -1653,14 +1537,6 @@
premium = list(/obj/item/storage/belt/utility = 3)
refill_canister = /obj/item/vending_refill/engivend
/obj/machinery/vending/engivend/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/engivend(null)
RefreshParts()
return ..()
/obj/machinery/vending/engineering
name = "\improper Robco Tool Maker"
@@ -1676,14 +1552,6 @@
/obj/item/stock_parts/matter_bin = 5,/obj/item/stock_parts/manipulator = 5)
refill_canister = /obj/item/vending_refill/engineering
/obj/machinery/vending/engineering/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/engineering(null)
RefreshParts()
return ..()
/obj/machinery/vending/robotics
name = "\improper Robotech Deluxe"
@@ -1697,14 +1565,6 @@
/obj/item/screwdriver = 5,/obj/item/crowbar = 5)
refill_canister = /obj/item/vending_refill/robotics
/obj/machinery/vending/robotics/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/robotics(null)
RefreshParts()
return ..()
/obj/machinery/vending/sustenance
name = "\improper Sustenance Vendor"
@@ -1721,14 +1581,6 @@
/obj/item/clothing/mask/breath = 6)
refill_canister = /obj/item/vending_refill/sustenance
/obj/machinery/vending/sustenance/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/sustenance(null)
RefreshParts()
return ..()
/obj/machinery/vending/hatdispenser
name = "\improper Hatlord 9000"
@@ -1745,14 +1597,6 @@
premium = list(/obj/item/clothing/head/soft/rainbow = 1)
refill_canister = /obj/item/vending_refill/hatdispenser
/obj/machinery/vending/hatdispenser/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/hatdispenser(null)
RefreshParts()
return ..()
/obj/machinery/vending/suitdispenser
name = "\improper Suitlord 9000"
@@ -1766,14 +1610,6 @@
premium = list(/obj/item/clothing/under/rainbow = 1)
refill_canister = /obj/item/vending_refill/suitdispenser
/obj/machinery/vending/suitdispenser/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/suitdispenser(null)
RefreshParts()
return ..()
/obj/machinery/vending/shoedispenser
name = "\improper Shoelord 9000"
@@ -1785,14 +1621,6 @@
premium = list(/obj/item/clothing/shoes/rainbow = 1)
refill_canister = /obj/item/vending_refill/shoedispenser
/obj/machinery/vending/shoedispenser/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/shoedispenser(null)
RefreshParts()
return ..()
/obj/machinery/vending/syndicigs
name = "\improper Suspicious Cigarette Machine"
@@ -1803,6 +1631,7 @@
icon_state = "cigs"
products = list(/obj/item/storage/fancy/cigarettes/syndicate = 10,/obj/item/lighter/random = 5)
/obj/machinery/vending/syndisnack
name = "\improper Getmore Chocolate Corp"
desc = "A modified snack machine courtesy of the Getmore Chocolate Corporation, based out of Mars"
@@ -1812,6 +1641,7 @@
products = list(/obj/item/reagent_containers/food/snacks/chips =6,/obj/item/reagent_containers/food/snacks/sosjerky = 6,
/obj/item/reagent_containers/food/snacks/syndicake = 6, /obj/item/reagent_containers/food/snacks/cheesiehonkers = 6)
//don't forget to change the refill size if you change the machine's contents!
/obj/machinery/vending/clothing
name = "\improper ClothesMate" //renamed to make the slogan rhyme
@@ -1907,14 +1737,6 @@
refill_canister = /obj/item/vending_refill/clothing
/obj/machinery/vending/clothing/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/clothing(null)
RefreshParts()
return ..()
/obj/machinery/vending/artvend
name = "\improper ArtVend"
@@ -1931,6 +1753,7 @@
contraband = list(/obj/item/toy/crayon/mime = 1,/obj/item/toy/crayon/rainbow = 1)
premium = list(/obj/item/poster/random_contraband = 5)
/obj/machinery/vending/crittercare
name = "\improper CritterCare"
desc = "A vending machine for pet supplies."
@@ -1955,11 +1778,3 @@
/obj/machinery/vending/crittercare/free
prices = list()
/obj/machinery/vending/crittercare/Initialize(mapload)
component_parts = list()
var/obj/item/circuitboard/vendor/V = new(null)
V.set_type(type)
component_parts += V
component_parts += new /obj/item/vending_refill/crittercare(null)
RefreshParts()
return ..()
+1 -1
View File
@@ -57,7 +57,7 @@
to_chat(user, "<span class='warning'>You feel a dark stirring inside of the Wish Granter, something you want nothing of. Your instincts are better than any man's.</warning>")
return TRUE
if(is_special_character(user) || jobban_isbanned(user, ROLE_TRAITOR) || jobban_isbanned(user, "Syndicate"))
if(is_special_character(user) || jobban_isbanned(user, ROLE_TRAITOR) || jobban_isbanned(user, ROLE_SYNDICATE))
to_chat(user, "<span class='warning'>Something instinctual makes you pull away.</span>")
return TRUE
@@ -483,7 +483,7 @@
if(R.can_synth && add_known_reagent(R.id, R.name))
occupant_message("Reagent analyzed, identified as [R.name] and added to database.")
send_byjax(chassis.occupant,"msyringegun.browser","reagents_form",get_reagents_form())
occupant_message("Analyzis complete.")
occupant_message("Analysis complete.")
return 1
/obj/item/mecha_parts/mecha_equipment/medical/syringe_gun/proc/add_known_reagent(r_id,r_name)
+33 -25
View File
@@ -30,28 +30,38 @@
return
if(!cargo_holder)
return
if(istype(target,/obj))
if(isobj(target))
var/obj/O = target
if(!O.anchored)
if(cargo_holder.cargo.len < cargo_holder.cargo_capacity)
chassis.visible_message("[chassis] lifts [target] and starts to load it into cargo compartment.")
O.anchored = 1
if(do_after_cooldown(target))
cargo_holder.cargo += O
O.loc = chassis
O.anchored = 0
occupant_message("<span class='notice'>[target] successfully loaded.</span>")
log_message("Loaded [O]. Cargo compartment capacity: [cargo_holder.cargo_capacity - cargo_holder.cargo.len]")
else
O.anchored = initial(O.anchored)
else
occupant_message("<span class='warning'>Not enough room in cargo compartment!</span>")
else
if(istype(target, /obj/machinery/power/supermatter_crystal)) //No, you can't pick up the SM with this you moron, did you think you were clever?
var/obj/mecha/working/ripley/R = chassis
QDEL_LIST(R.cargo) //We don't want to drop cargo that just spam hits the SM, let's delete it
occupant_message("<span class='userdanger'>You realise in horror what you have done as [chassis] starts warping around you!</span>")
chassis.occupant.dust()
target.Bumped(chassis)
return
if(O.anchored)
occupant_message("<span class='warning'>[target] is firmly secured!</span>")
return
if(length(cargo_holder.cargo) >= cargo_holder.cargo_capacity)
occupant_message("<span class='warning'>Not enough room in cargo compartment!</span>")
return
chassis.visible_message("<span class='notice'>[chassis] lifts [target] and starts to load it into cargo compartment.</span>")
var/anchor_state_before_load = O.anchored
O.anchored = TRUE
if(!do_after_cooldown(target))
O.anchored = anchor_state_before_load
return
cargo_holder.cargo += O
O.forceMove(chassis)
O.anchored = FALSE
occupant_message("<span class='notice'>[target] was successfully loaded.</span>")
log_message("Loaded [O]. Cargo compartment capacity: [cargo_holder.cargo_capacity - length(cargo_holder.cargo)]")
return
else if(istype(target,/mob/living))
if(isliving(target))
var/mob/living/M = target
if(M.stat == DEAD) return
if(M.stat == DEAD)
return
if(chassis.occupant.a_intent == INTENT_HARM)
M.take_overall_damage(dam_force)
if(!M)
@@ -62,12 +72,10 @@
"<span class='italics'>You hear something crack.</span>")
add_attack_logs(chassis.occupant, M, "Squeezed with [src] ([uppertext(chassis.occupant.a_intent)]) ([uppertext(damtype)])")
start_cooldown()
else
step_away(M,chassis)
occupant_message("<span class='notice'>You push [target] out of the way.</span>")
chassis.visible_message("<span class='notice'>[chassis] pushes [target] out of the way.</span>")
return 1
return
step_away(M, chassis)
occupant_message("<span class='notice'>You push [target] out of the way.</span>")
chassis.visible_message("<span class='notice'>[chassis] pushes [target] out of the way.</span>")
//This is pretty much just for the death-ripley
@@ -220,7 +228,7 @@
switch(mode)
if(0)
if(istype(target, /turf/simulated/wall))
if(istype(target, /turf/simulated/wall/r_wall) && !canRwall)
if((istype(target, /turf/simulated/wall/r_wall) && !canRwall) || istype(target, /turf/simulated/wall/indestructible))
return 0
var/turf/simulated/wall/W = target
occupant_message("Deconstructing [target]...")
+3 -2
View File
@@ -1200,7 +1200,8 @@
/obj/mecha/Exited(atom/movable/M, atom/newloc)
if(occupant && occupant == M) // The occupant exited the mech without calling go_out()
go_out(1, newloc)
if(!isAI(occupant)) //This causes carded AIS to gib, so we do not want this to be called during carding.
go_out(1, newloc)
/obj/mecha/proc/go_out(forced, atom/newloc = loc)
if(!occupant)
@@ -1507,7 +1508,7 @@
if(internal_tank)
WR.crowbar_salvage += internal_tank
internal_tank.forceMove(WR)
cell = null
internal_tank = null
. = ..()
/obj/mecha/CtrlClick(mob/living/L)
+44 -40
View File
@@ -347,117 +347,121 @@
///////// Circuitboards
/obj/item/circuitboard/mecha
name = "Exosuit Circuit board"
icon = 'icons/obj/module.dmi'
icon_state = "std_mod"
item_state = "electronic"
board_type = "other"
flags = CONDUCT
force = 5.0
w_class = WEIGHT_CLASS_SMALL
throwforce = 5.0
force = 5
throwforce = 5
throw_speed = 3
throw_range = 15
/obj/item/circuitboard/mecha/ripley
origin_tech = "programming=2"
/obj/item/circuitboard/mecha/ripley/main
board_name = "Ripley Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/ripley/peripherals
name = "Circuit board (Ripley Peripherals Control module)"
board_name = "Ripley Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/ripley/main
name = "Circuit board (Ripley Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/gygax
origin_tech = "programming=4;combat=3;engineering=3"
/obj/item/circuitboard/mecha/gygax/main
board_name = "Gygax Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/gygax/peripherals
name = "Circuit board (Gygax Peripherals Control module)"
board_name = "Gygax Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/gygax/targeting
name = "Circuit board (Gygax Weapon Control and Targeting module)"
board_name = "Gygax Weapon Control and Targeting Module"
icon_state = "mcontroller"
origin_tech = "programming=4;combat=4"
/obj/item/circuitboard/mecha/gygax/main
name = "Circuit board (Gygax Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/durand
origin_tech = "programming=4;combat=3;engineering=3"
/obj/item/circuitboard/mecha/durand/main
board_name = "Durand Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/durand/peripherals
name = "Circuit board (Durand Peripherals Control module)"
board_name = "Durand Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/durand/targeting
name = "Circuit board (Durand Weapon Control and Targeting module)"
board_name = "Durand Weapon Control and Targeting Module"
icon_state = "mcontroller"
origin_tech = "programming=4;combat=4;engineering=3"
/obj/item/circuitboard/mecha/durand/main
name = "Circuit board (Durand Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/phazon
origin_tech = "programming=5;plasmatech=4"
/obj/item/circuitboard/mecha/phazon/main
board_name = "Phazon Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/phazon/peripherals
name = "Circuit board (Phazon Peripherals Control module)"
board_name = "Phazon Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/phazon/targeting
name = "Circuit board (Phazon Weapon Control and Targeting module)"
board_name = "Phazon Weapon Control and Targeting Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/phazon/main
name = "Circuit board (Phazon Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/honker
origin_tech = "programming=3;engineering=3"
/obj/item/circuitboard/mecha/honker/main
board_name = "H.O.N.K Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/honker/peripherals
name = "Circuit board (H.O.N.K Peripherals Control module)"
board_name = "H.O.N.K Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/honker/targeting
name = "Circuit board (H.O.N.K Weapon Control and Targeting module)"
board_name = "H.O.N.K Weapon Control and Targeting Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/honker/main
name = "Circuit board (H.O.N.K Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/reticence
origin_tech = "programming=3;engineering=3"
/obj/item/circuitboard/mecha/reticence/main
board_name = "Reticence Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/reticence/peripherals
name = "circuit board (Reticence Peripherals Control module)"
board_name = "Reticence Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/reticence/targeting
name = "circuit board (Reticence Weapon Control and Targeting module)"
board_name = "Reticence Weapon Control and Targeting Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/reticence/main
name = "circuit board (Reticence Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/odysseus
origin_tech = "programming=3;biotech=3"
/obj/item/circuitboard/mecha/odysseus/main
board_name = "Odysseus Central Control Module"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/odysseus/peripherals
name = "Circuit board (Odysseus Peripherals Control module)"
board_name = "Odysseus Peripherals Control Module"
icon_state = "mcontroller"
/obj/item/circuitboard/mecha/odysseus/main
name = "Circuit board (Odysseus Central Control module)"
icon_state = "mainboard"
/obj/item/circuitboard/mecha/pod
name = "Circuit board (Space Pod Mainboard)"
board_name = "Space Pod Mainboard"
icon_state = "mainboard"
+1 -1
View File
@@ -59,7 +59,7 @@
user.visible_message("<span class='notice'>[user] pries [S] from [src].</span>", "<span class='notice'>You pry [S] from [src].</span>")
crowbar_salvage -= S
return
to_chat(user, "<span class='notice'>You don't see anything that can be cut with [I]!</span>")
to_chat(user, "<span class='notice'>You don't see anything that can be pried with [I]!</span>")
/obj/structure/mecha_wreckage/welder_act(mob/user, obj/item/I)
. = TRUE
+4
View File
@@ -122,6 +122,10 @@
if(!in_range(user, src) || !isturf(user.loc) || user.incapacitated() || M.anchored)
return FALSE
if (isguardian(user))
if (M.loc == user.loc || user.alpha == 60) //Alpha is for detecting ranged guardians in scout mode
return //unmanifested guardians shouldn't be able to buckle mobs
add_fingerprint(user)
. = buckle_mob(M, check_loc = check_loc)
if(.)
@@ -53,6 +53,9 @@
/obj/effect/decal/cleanable/proc/can_bloodcrawl_in()
return FALSE
/obj/effect/decal/cleanable/is_cleanable()
return TRUE
/obj/effect/decal/cleanable/Initialize(mapload)
. = ..()
if(loc && isturf(loc))
+3
View File
@@ -25,6 +25,9 @@
/obj/effect/acid_act()
return
/obj/effect/proc/is_cleanable() //Called when you want to clean something, and usualy delete it after
return FALSE
/obj/effect/mech_melee_attack(obj/mecha/M)
return 0
+1 -2
View File
@@ -135,8 +135,7 @@
var/red_splash = list(1,0,0,0.8,0.2,0, 0.8,0,0.2,0.1,0,0)
var/pure_red = list(0,0,0,0,0,0,0,0,0,1,0,0)
spawn(0)
new /obj/effect/hallucination/delusion(victim.loc, victim, force_kind = "demon", duration = duration, skip_nearby = 0)
new /obj/effect/hallucination/delusion(get_turf(victim), victim, 'icons/mob/mob.dmi', "daemon")
var/obj/item/twohanded/required/chainsaw/doomslayer/chainsaw = new(victim.loc)
chainsaw.flags |= NODROP | DROPDEL
+6 -2
View File
@@ -14,6 +14,7 @@
var/precision = TRUE // how close to the portal you will teleport. FALSE = on the portal, TRUE = adjacent
var/can_multitool_to_remove = FALSE
var/ignore_tele_proof_area_setting = FALSE
var/one_use = FALSE // Does this portal go away after one teleport?
/obj/effect/portal/New(loc, turf/target, creator = null, lifespan = 300)
..()
@@ -101,14 +102,17 @@
if(prob(failchance))
icon_state = fail_icon
if(!do_teleport(M, locate(rand(5, world.maxx - 5), rand(5, world.maxy -5), 3), 0, bypass_area_flag = ignore_tele_proof_area_setting)) // Try to send them to deep space.
var/list/target_z = levels_by_trait(SPAWN_RUINS)
target_z -= M.z
if(!do_teleport(M, locate(rand(5, world.maxx - 5), rand(5, world.maxy -5), pick(target_z)), 0, bypass_area_flag = ignore_tele_proof_area_setting)) // Try to send them to deep space.
invalid_teleport()
return FALSE
else
if(!do_teleport(M, target, precision, bypass_area_flag = ignore_tele_proof_area_setting)) // Try to send them to a turf adjacent to target.
invalid_teleport()
return FALSE
if(one_use)
qdel(src)
return TRUE
/obj/effect/portal/proc/invalid_teleport()
@@ -354,3 +354,12 @@
/obj/effect/temp_visual/impact_effect/ion
icon_state = "shieldsparkles"
duration = 6
/obj/effect/temp_visual/bsg_kaboom
name = "bluespace explosion"
icon = 'icons/effects/96x96.dmi'
icon_state = "explosionfast"
color = "blue"
pixel_x = -32
pixel_y = -32
duration = 42
+11
View File
@@ -424,6 +424,17 @@ GLOBAL_DATUM_INIT(fire_overlay, /image, image("icon" = 'icons/goonstation/effect
/obj/item/proc/on_enter_storage(obj/item/storage/S as obj)
return
/**
* Called to check if this item can be put into a storage item.
*
* Return `FALSE` if `src` can't be inserted, and `TRUE` if it can.
* Arguments:
* * S - The [/obj/item/storage] that `src` is being inserted into.
* * user - The mob trying to insert the item.
*/
/obj/item/proc/can_enter_storage(obj/item/storage/S, mob/user)
return TRUE
// called when "found" in pockets and storage items. Returns 1 if the search should end.
/obj/item/proc/on_found(mob/finder as mob)
return
+6
View File
@@ -30,6 +30,12 @@
else i = 3
icon_state = "candle[i][lit ? "_lit" : ""]"
/obj/item/candle/can_enter_storage(obj/item/storage/S, mob/user)
if(lit)
to_chat(user, "<span class='warning'>[S] can't hold [src] while it's lit!</span>")
return FALSE
else
return TRUE
/obj/item/candle/attackby(obj/item/W, mob/user, params)
if(is_hot(W))
-23
View File
@@ -1,23 +0,0 @@
/obj/item/changestone
name = "An uncut ruby"
desc = "The ruby shines and catches the light, despite being uncut"
icon = 'icons/obj/artifacts.dmi'
icon_state = "changerock"
/obj/item/changestone/attack_hand(mob/user as mob)
if(istype(user,/mob/living/carbon/human))
var/mob/living/carbon/human/H = user
if(!H.gloves)
if(H.gender == FEMALE)
H.change_gender(MALE)
else
H.change_gender(FEMALE)
H.dna.ready_dna(H)
H.update_body()
..()
@@ -50,6 +50,10 @@
/obj/item/radio/beacon/bacon/proc/digest_delay()
QDEL_IN(src, 600)
/obj/item/radio/beacon/emagged
syndicate = TRUE
emagged = TRUE
// SINGULO BEACON SPAWNER
/obj/item/radio/beacon/syndicate
name = "suspicious beacon"
@@ -71,6 +75,18 @@
user.drop_item()
qdel(src)
/obj/item/radio/beacon/syndicate/power_sink
name = "suspicious beacon"
desc = "A label on it reads: <i>Warning: Activating this device will send a power sink to your location</i>."
/obj/item/radio/beacon/syndicate/power_sink/attack_self(mob/user)
if(user)
to_chat(user, "<span class='notice'>Locked In</span>")
new /obj/item/powersink(user.loc)
playsound(src, 'sound/effects/pop.ogg', 100, TRUE, 1)
user.drop_item()
qdel(src)
/obj/item/radio/beacon/syndicate/bomb
name = "suspicious beacon"
desc = "A label on it reads: <i>Warning: Activating this device will send a high-ordinance explosive to your location</i>."
@@ -273,20 +273,20 @@ effective or pretty fucking useless.
/obj/item/teleporter/proc/dir_correction(mob/user) //Direction movement, screws with teleport distance and saving throw, and thus must be removed first
var/temp_direction = user.dir
switch(temp_direction)
if(NORTHEAST || SOUTHEAST)
if(NORTHEAST, SOUTHEAST)
user.dir = EAST
if(NORTHWEST || SOUTHWEST)
if(NORTHWEST, SOUTHWEST)
user.dir = WEST
/obj/item/teleporter/proc/panic_teleport(mob/user, turf/destination, direction = NORTH)
var/saving_throw
switch(direction)
if(NORTH || SOUTH)
if(NORTH, SOUTH)
if(prob(50))
saving_throw = EAST
else
saving_throw = WEST
if(EAST || WEST)
if(EAST, WEST)
if(prob(50))
saving_throw = NORTH
else
@@ -28,5 +28,5 @@
return TRUE
/obj/item/mounted/frame/apc_frame/do_build(turf/on_wall, mob/user)
new /obj/machinery/power/apc(get_turf(src), get_dir(user, on_wall), 1)
new /obj/machinery/power/apc(get_turf(src), get_dir(user, on_wall), TRUE)
qdel(src)
+1 -1
View File
@@ -226,7 +226,7 @@
to_chat(user, "<span class='warning'>Sticking an empty [M] into the frame would sort of defeat the purpose.</span>")
return
if(jobban_isbanned(M.brainmob, "Cyborg") || jobban_isbanned(M.brainmob,"nonhumandept"))
if(jobban_isbanned(M.brainmob, "Cyborg") || jobban_isbanned(M.brainmob, "nonhumandept"))
to_chat(user, "<span class='warning'>This [W] is not fit to serve as a cyborg!</span>")
return

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