Merge branch 'master' into donoritemmodularization

This commit is contained in:
deathride58
2017-12-04 20:17:02 -05:00
569 changed files with 8426 additions and 5523 deletions
-4
View File
@@ -30,10 +30,6 @@ GLOBAL_LIST_EMPTY(active_alternate_appearances)
appearance_key = key
/datum/atom_hud/alternate_appearance/Destroy()
for(var/v in hudusers)
remove_hud_from(v)
for(var/v in hudatoms)
remove_from_hud(v)
GLOB.active_alternate_appearances -= src
return ..()
-33
View File
@@ -1486,36 +1486,3 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
/area/tcommsat/lounge
name = "Telecommunications Satellite Lounge"
icon_state = "tcomsatlounge"
/////////////////////////////////////////////////////////////////////
/*
Lists of areas to be used with is_type_in_list.
Used in gamemodes code at the moment. --rastaf0
*/
//SPACE STATION 13
GLOBAL_LIST_INIT(the_station_areas, list (
/area/bridge,
/area/chapel,
/area/construction,
/area/crew_quarters,
/area/engine,
/area/hallway,
/area/holodeck,
/area/hydroponics,
/area/janitor,
/area/lawoffice,
/area/library,
/area/maintenance,
/area/medical,
/area/quartermaster,
/area/science,
/area/security,
/area/solar,
/area/storage,
/area/teleporter,
/area/ai_monitored/storage/eva, //do not try to simplify to "/area/ai_monitored" --rastaf0
/area/ai_monitored/turret_protected/ai_upload, //do not try to simplify to "/area/ai_monitored/turret_protected" --rastaf0
/area/ai_monitored/turret_protected/ai_upload_foyer,
/area/ai_monitored/turret_protected/ai,
))
+1 -17
View File
@@ -421,22 +421,6 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons)
/atom/proc/wash_cream()
return 1
/atom/proc/get_global_map_pos()
if(!islist(GLOB.global_map) || isemptylist(GLOB.global_map))
return
var/cur_x = null
var/cur_y = null
var/list/y_arr = null
for(cur_x=1,cur_x<=GLOB.global_map.len,cur_x++)
y_arr = GLOB.global_map[cur_x]
cur_y = y_arr.Find(src.z)
if(cur_y)
break
if(cur_x && cur_y)
return list("x"=cur_x,"y"=cur_y)
else
return 0
/atom/proc/isinspace()
if(isspaceturf(get_turf(src)))
return 1
@@ -634,4 +618,4 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons)
return
/atom/proc/wirecutter_act(mob/user, obj/item/tool)
return
return
+1
View File
@@ -26,6 +26,7 @@
appearance_flags = TILE_BOUND|PIXEL_SCALE
var/datum/forced_movement/force_moving = null //handled soley by forced_movement.dm
var/floating = FALSE
var/movement_type = GROUND //Incase you have multiple types, you automatically use the most useful one. IE: Skating on ice, flippers on water, flying over chasm/space, etc.
/atom/movable/vv_edit_var(var_name, var_value)
var/static/list/banned_edits = list("step_x", "step_y", "step_size")
+8
View File
@@ -50,8 +50,16 @@
hud_icons = list(ID_HUD, IMPTRACK_HUD, IMPLOYAL_HUD, IMPCHEM_HUD, WANTED_HUD)
/datum/atom_hud/data/diagnostic
/datum/atom_hud/data/diagnostic/basic
hud_icons = list (DIAG_HUD, DIAG_STAT_HUD, DIAG_BATT_HUD, DIAG_MECH_HUD, DIAG_BOT_HUD, DIAG_TRACK_HUD, DIAG_AIRLOCK_HUD)
/datum/atom_hud/data/diagnostic/advanced
hud_icons = list (DIAG_HUD, DIAG_STAT_HUD, DIAG_BATT_HUD, DIAG_MECH_HUD, DIAG_BOT_HUD, DIAG_TRACK_HUD, DIAG_AIRLOCK_HUD, DIAG_PATH_HUD)
/datum/atom_hud/data/bot_path
hud_icons = list(DIAG_PATH_HUD)
/* MED/SEC/DIAG HUD HOOKS */
/*
+1 -1
View File
@@ -127,7 +127,7 @@
return
used = TRUE
var/mob/dead/observer/theghost = pick(nuke_candidates)
spawn_antag(theghost.client, get_turf(src), "syndieborg")
spawn_antag(theghost.client, get_turf(src), "syndieborg", user)
do_sparks(4, TRUE, src)
qdel(src)
else
+2 -9
View File
@@ -56,13 +56,6 @@
return 1
return ..()
/mob/living/simple_animal/hostile/blob/handle_inherent_channels(message, message_mode)
if(message_mode == MODE_BINARY)
blob_chat(message)
return 1
else
..()
/mob/living/simple_animal/hostile/blob/proc/blob_chat(msg)
var/spanned_message = say_quote(msg, get_spans())
var/rendered = "<font color=\"#EE4000\"><b>\[Blob Telepathy\] [real_name]</b> [spanned_message]</font>"
@@ -100,7 +93,7 @@
var/death_cloud_size = 1 //size of cloud produced from a dying spore
var/mob/living/carbon/human/oldguy
var/is_zombie = 0
gold_core_spawnable = 1
gold_core_spawnable = HOSTILE_SPAWN
/mob/living/simple_animal/hostile/blob/blobspore/Initialize(mapload, var/obj/structure/blob/factory/linked_node)
if(istype(linked_node))
@@ -299,4 +292,4 @@
/mob/living/simple_animal/hostile/blob/blobbernaut/independent
independent = TRUE
gold_core_spawnable = 1
gold_core_spawnable = HOSTILE_SPAWN
+1 -1
View File
@@ -19,7 +19,7 @@
GLOB.poi_list |= src
update_icon() //so it atleast appears
if(!placed && !overmind)
qdel(src)
return INITIALIZE_HINT_QDEL
if(overmind)
update_icon()
point_rate = new_rate
+4 -4
View File
@@ -114,19 +114,19 @@
for(var/datum/objective/objective in team.objectives)
if(objective.check_completion())
text += "<br><B>Objective #[objective_count]</B>: [objective.explanation_text] <font color='green'><B>Success!</B></font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("traitor_objective","[objective.type]|SUCCESS")
SSblackbox.record_feedback("nested tally", "traitor_objective", 1, list("[objective.type]", "SUCCESS"))
else
text += "<br><B>Objective #[objective_count]</B>: [objective.explanation_text] <font color='red'>Fail.</font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("traitor_objective","[objective.type]|FAIL")
SSblackbox.record_feedback("nested tally", "traitor_objective", 1, list("[objective.type]", "FAIL"))
if(!(istype(objective, /datum/objective/crew)))
win = FALSE
objective_count++
if(win)
text += "<br><font color='green'><B>The blood brothers were successful!</B></font>"
SSblackbox.add_details("brother_success","SUCCESS")
SSblackbox.record_feedback("tally", "brother_success", 1, "SUCCESS")
else
text += "<br><font color='red'><B>The blood brothers have failed!</B></font>"
SSblackbox.add_details("brother_success","FAIL")
SSblackbox.record_feedback("tally", "brother_success", 1, "FAIL")
text += "<br>"
to_chat(world, text)
+5 -5
View File
@@ -115,20 +115,20 @@ GLOBAL_VAR(changeling_team_objective_type) //If this is not null, we hand our th
for(var/datum/objective/objective in changeling.objectives)
if(objective.check_completion())
text += "<br><b>Objective #[count]</b>: [objective.explanation_text] <font color='green'><b>Success!</b></font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("changeling_objective","[objective.type]|SUCCESS")
SSblackbox.record_feedback("nested tally", "changeling_objective", 1, list("[objective.type]", "SUCCESS"))
else
text += "<br><b>Objective #[count]</b>: [objective.explanation_text] <span class='danger'>Fail.</span> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("changeling_objective","[objective.type]|FAIL")
SSblackbox.record_feedback("nested tally", "changeling_objective", 1, list("[objective.type]", "FAIL"))
if(!(istype(objective, /datum/objective/crew)))
changelingwin = 0
count++
if(changelingwin)
text += "<br><font color='green'><b>The changeling was successful!</b></font>"
SSblackbox.add_details("changeling_success","SUCCESS")
SSblackbox.record_feedback("tally", "changeling_success", 1, "SUCCESS")
else
text += "<br><span class='boldannounce'>The changeling has failed.</span>"
SSblackbox.add_details("changeling_success","FAIL")
SSblackbox.record_feedback("tally", "changeling_success", 1, "FAIL")
text += "<br>"
to_chat(world, text)
@@ -174,4 +174,4 @@ GLOBAL_VAR(changeling_team_objective_type) //If this is not null, we hand our th
if(equip)
user.equip_to_slot_or_del(C, GLOB.slot2slot[slot])
user.regenerate_icons()
user.regenerate_icons()
@@ -19,7 +19,7 @@
/obj/effect/proc_holder/changeling/proc/on_purchase(mob/user, is_respec)
if(!is_respec)
SSblackbox.add_details("changeling_power_purchase",name)
SSblackbox.record_feedback("tally", "changeling_power_purchase", 1, name)
/obj/effect/proc_holder/changeling/proc/on_refund(mob/user)
return
@@ -35,7 +35,7 @@
return
var/datum/antagonist/changeling/c = user.mind.has_antag_datum(/datum/antagonist/changeling)
if(sting_action(user, target))
SSblackbox.add_details("changeling_powers",name)
SSblackbox.record_feedback("nested tally", "changeling_powers", 1, list("[name]"))
sting_feedback(user, target)
c.chem_charges -= chemical_cost
@@ -41,13 +41,13 @@
to_chat(target, "<span class='userdanger'>You feel a sharp stabbing pain!</span>")
target.take_overall_damage(40)
SSblackbox.add_details("changeling_powers","Absorb DNA|[i]")
SSblackbox.record_feedback("nested tally", "changeling_powers", 1, list("Absorb DNA", "[i]"))
if(!do_mob(user, target, 150))
to_chat(user, "<span class='warning'>Our absorption of [target] has been interrupted!</span>")
changeling.isabsorbing = 0
return
SSblackbox.add_details("changeling_powers","Absorb DNA|4")
SSblackbox.record_feedback("nested tally", "changeling_powers", 1, list("Absorb DNA", "4"))
user.visible_message("<span class='danger'>[user] sucks the fluids from [target]!</span>", "<span class='notice'>We have absorbed [target].</span>")
to_chat(target, "<span class='userdanger'>You are absorbed by the changeling!</span>")
@@ -50,14 +50,14 @@
to_chat(target, "<span class='userdanger'>A migraine throbs behind your eyes, you hear yourself screaming - but your mouth has not opened!</span>")
for(var/mi in GLOB.mob_list)
var/mob/M = mi
if(M.lingcheck() == 2)
if(M.lingcheck() == LINGHIVE_LING)
to_chat(M, "<i><font color=#800080>We can sense a foreign presence in the hivemind...</font></i>")
target.mind.linglink = 1
target.say(":g AAAAARRRRGGGGGHHHHH!!")
to_chat(target, "<font color=#800040><span class='boldannounce'>You can now communicate in the changeling hivemind, say \":g message\" to communicate!</span>")
target.reagents.add_reagent("salbutamol", 40) // So they don't choke to death while you interrogate them
sleep(1800)
SSblackbox.add_details("changeling_powers","Hivemind Link|[i]")
SSblackbox.record_feedback("nested tally", "changeling_powers", 1, list("[name]", "[i]"))
if(!do_mob(user, target, 20))
to_chat(user, "<span class='warning'>Our link with [target] has ended!</span>")
changeling.islinking = 0
@@ -10,6 +10,13 @@
light_power = 3
light_color = "#6A4D2F"
/obj/effect/clockwork/city_of_cogs_rift/singularity_act()
return
/obj/effect/clockwork/city_of_cogs_rift/singularity_pull()
return
/obj/effect/clockwork/city_of_cogs_rift/Initialize()
. = ..()
visible_message("<span class='warning'>The air above [loc] shimmers and pops as a [name] forms there!</span>")
@@ -10,6 +10,11 @@
/obj/effect/clockwork/overlay/ex_act()
return FALSE
/obj/effect/clockwork/overlay/singularity_act()
return
/obj/effect/clockwork/overlay/singularity_pull()
return
/obj/effect/clockwork/overlay/singularity_pull(S, current_size)
return
@@ -11,6 +11,12 @@
animate(src, alpha = 0, time = 10)
QDEL_IN(src, 10)
/obj/effect/clockwork/general_marker/singularity_act()
return
/obj/effect/clockwork/general_marker/singularity_pull()
return
/obj/effect/clockwork/general_marker/inathneq
name = "Inath-neq, the Resonant Cogwheel"
desc = "A humanoid form blazing with blue fire. It radiates an aura of kindness and caring."
@@ -18,3 +18,9 @@
to_chat(L, "<span class='danger'>The space beyond here can't be accessed by you or other servants.</span>")
return
return TRUE
/obj/effect/clockwork/servant_blocker/singularity_act()
return
/obj/effect/clockwork/servant_blocker/singularity_pull()
return
@@ -109,6 +109,14 @@
return TRUE
return FALSE
/obj/effect/clockwork/spatial_gateway/singularity_act()
return
/obj/effect/clockwork/spatial_gateway/singularity_pull()
return
/obj/effect/clockwork/spatial_gateway/CollidedWith(atom/movable/AM)
..()
if(!QDELETED(AM))
@@ -162,6 +162,12 @@
user = caster
INVOKE_ASYNC(src, .proc/judicialblast)
/obj/effect/clockwork/judicial_marker/singularity_act()
return
/obj/effect/clockwork/judicial_marker/singularity_pull()
return
/obj/effect/clockwork/judicial_marker/proc/judicialblast()
playsound(src, 'sound/magic/magic_missile.ogg', 50, 1, 1, 1)
flick("judicial_marker", src)
@@ -66,7 +66,7 @@ Applications: 8 servants, 3 caches, and 100 CV
else
successful = TRUE
if(slab && !slab.no_cost && !GLOB.ratvar_awakens) //if the slab exists and isn't debug and ratvar isn't up, log the scripture as being used
SSblackbox.add_details("clockcult_scripture_recited", name)
SSblackbox.record_feedback("tally", "clockcult_scripture_recited", 1, name)
if(slab)
slab.busy = null
post_recital()
+10 -10
View File
@@ -237,27 +237,27 @@
if("survive")
if(!check_survive())
explanation = "Make sure at least [acolytes_needed] acolytes escape on the shuttle. ([acolytes_survived] escaped) <span class='greenannounce'>Success!</span>"
SSblackbox.add_details("cult_objective","cult_survive|SUCCESS|[acolytes_needed]")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_survive", "SUCCESS"))
SSticker.news_report = CULT_ESCAPE
else
explanation = "Make sure at least [acolytes_needed] acolytes escape on the shuttle. ([acolytes_survived] escaped) <span class='boldannounce'>Fail.</span>"
SSblackbox.add_details("cult_objective","cult_survive|FAIL|[acolytes_needed]")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_survive", "FAIL"))
SSticker.news_report = CULT_FAILURE
if("sacrifice")
if(GLOB.sac_complete)
explanation = "Sacrifice [GLOB.sac_mind], the [GLOB.sac_mind.assigned_role]. <span class='greenannounce'>Success!</span>"
SSblackbox.add_details("cult_objective","cult_sacrifice|SUCCESS")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_sacrifice", "SUCCESS"))
else
explanation = "Sacrifice [GLOB.sac_mind], the [GLOB.sac_mind.assigned_role]. <span class='boldannounce'>Fail.</span>"
SSblackbox.add_details("cult_objective","cult_sacrifice|FAIL")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_sacrifice", "FAIL"))
if("eldergod")
if(!eldergod)
explanation = "Summon Nar-Sie. The summoning can only be accomplished in [english_list(GLOB.summon_spots)].<span class='greenannounce'>Success!</span>"
SSblackbox.add_details("cult_objective","cult_narsie|SUCCESS")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_narsie", "SUCCESS"))
SSticker.news_report = CULT_SUMMON
else
explanation = "Summon Nar-Sie. The summoning can only be accomplished in [english_list(GLOB.summon_spots)]<span class='boldannounce'>Fail.</span>"
SSblackbox.add_details("cult_objective","cult_narsie|FAIL")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_narsie", "FAIL"))
SSticker.news_report = CULT_FAILURE
text += "<br><B>Objective #[obj_count]</B>: [explanation]"
@@ -297,18 +297,18 @@
if(GLOB.sac_mind)
if(GLOB.sac_complete)
explanation = "Sacrifice [GLOB.sac_mind], the [GLOB.sac_mind.assigned_role]. <span class='greenannounce'>Success!</span>"
SSblackbox.add_details("cult_objective","cult_sacrifice|SUCCESS")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_sacrifice", "SUCCESS"))
else
explanation = "Sacrifice [GLOB.sac_mind], the [GLOB.sac_mind.assigned_role]. <span class='boldannounce'>Fail.</span>"
SSblackbox.add_details("cult_objective","cult_sacrifice|FAIL")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_sacrifice", "FAIL"))
if("eldergod")
if(!eldergod)
explanation = "Summon Nar-Sie. <span class='greenannounce'>Success!</span>"
SSblackbox.add_details("cult_objective","cult_narsie|SUCCESS")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_narsie", "SUCCESS"))
SSticker.news_report = CULT_SUMMON
else
explanation = "Summon Nar-Sie. <span class='boldannounce'>Fail.</span>"
SSblackbox.add_details("cult_objective","cult_narsie|FAIL")
SSblackbox.record_feedback("nested tally", "cult_objective", 1, list("cult_narsie", "FAIL"))
SSticker.news_report = CULT_FAILURE
text += "<br><B>Objective #[obj_count]</B>: [explanation]"
to_chat(world, text)
@@ -240,3 +240,9 @@
icon_state = "hole"
density = TRUE
anchored = TRUE
/obj/effect/gateway/singularity_act()
return
/obj/effect/gateway/singularity_pull()
return
+1 -1
View File
@@ -246,7 +246,7 @@ This file contains the arcane tome files.
var/obj/effect/rune/R = new rune_to_scribe(Turf, chosen_keyword)
R.add_mob_blood(user)
to_chat(user, "<span class='cult'>The [lowertext(R.cultist_name)] rune [R.cultist_desc]</span>")
SSblackbox.add_details("cult_runes_scribed", R.cultist_name)
SSblackbox.record_feedback("tally", "cult_runes_scribed", 1, R.cultist_name)
/obj/item/tome/proc/check_rune_turf(turf/T, mob/user)
if(isspaceturf(T))
+1 -1
View File
@@ -23,7 +23,7 @@
for(var/D in devils)
var/datum/mind/devil = D
text += printplayer(devil)
text += printdevilinfo(devil)
text += printdevilinfo(devil.current)
text += printobjectives(devil)
text += "<br>"
text += "<br>"
+13 -12
View File
@@ -266,18 +266,19 @@
if(isobserver(M))
ghosts++
if(clients > 0)
SSblackbox.set_val("round_end_clients",clients)
if(ghosts > 0)
SSblackbox.set_val("round_end_ghosts",ghosts)
if(surviving_humans > 0)
SSblackbox.set_val("survived_human",surviving_humans)
if(surviving_total > 0)
SSblackbox.set_val("survived_total",surviving_total)
if(escaped_humans > 0)
SSblackbox.set_val("escaped_human",escaped_humans)
if(escaped_total > 0)
SSblackbox.set_val("escaped_total",escaped_total)
if(clients)
SSblackbox.record_feedback("nested tally", "round_end_stats", clients, list("clients"))
if(ghosts)
SSblackbox.record_feedback("nested tally", "round_end_stats", ghosts, list("ghosts"))
if(surviving_humans)
SSblackbox.record_feedback("nested tally", "round_end_stats", surviving_humans, list("survivors", "human"))
if(surviving_total)
SSblackbox.record_feedback("nested tally", "round_end_stats", surviving_total, list("survivors", "total"))
if(escaped_humans)
SSblackbox.record_feedback("nested tally", "round_end_stats", escaped_humans, list("escapees", "human"))
if(escaped_total)
SSblackbox.record_feedback("nested tally", "round_end_stats", escaped_total, list("escapees", "total"))
send2irc("Server", "Round just ended.")
if(cult.len && !istype(SSticker.mode, /datum/game_mode/cult))
datum_cult_completion()
@@ -734,6 +734,33 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list(
owner.playsound_local(owner, "sparks", 50, 0)
//Disable Emergency Lights
/datum/AI_Module/small/emergency_lights
module_name = "Disable Emergency Lights"
mod_pick_name = "disable_emergency_lights"
description = "Cuts emergency lights across the entire station. If power is lost to light fixtures, they will not attempt to fall back on emergency power reserves."
cost = 10
one_purchase = TRUE
power_type = /datum/action/innate/ai/emergency_lights
unlock_text = "<span class='notice'>You hook into the powernet and locate the connections between light fixtures and their fallbacks.</span>"
unlock_sound = "sparks"
/datum/action/innate/ai/emergency_lights
name = "Disable Emergency Lights"
desc = "Disables all emergency lighting. Note that emergency lights can be restored through reboot at an APC."
button_icon_state = "emergency_lights"
uses = 1
/datum/action/innate/ai/emergency_lights/Activate()
for(var/obj/machinery/light/L in GLOB.machines)
if(L.z in GLOB.station_z_levels)
L.no_emergency = TRUE
INVOKE_ASYNC(L, /obj/machinery/light/.proc/update, FALSE)
CHECK_TICK
to_chat(owner, "<span class='notice'>Emergency light connections severed.</span>")
owner.playsound_local(owner, 'sound/effects/light_flicker.ogg', 50, FALSE)
//Reactivate Camera Network: Reactivates up to 30 cameras across the station.
/datum/AI_Module/small/reactivate_cameras
module_name = "Reactivate Camera Network"
@@ -101,8 +101,8 @@
/mob/living/simple_animal/hostile/swarmer/Initialize()
. = ..()
verbs -= /mob/living/verb/pulled
var/datum/atom_hud/data/diagnostic/diag_hud = GLOB.huds[DATA_HUD_DIAGNOSTIC]
diag_hud.add_to_hud(src)
for(var/datum/atom_hud/data/diagnostic/diag_hud in GLOB.huds)
diag_hud.add_to_hud(src)
/mob/living/simple_animal/hostile/swarmer/med_hud_set_health()
var/image/holder = hud_list[DIAG_HUD]
@@ -121,13 +121,6 @@
if(statpanel("Status"))
stat("Resources:",resources)
/mob/living/simple_animal/hostile/swarmer/handle_inherent_channels(message, message_mode)
if(message_mode == MODE_BINARY)
swarmer_chat(message)
return ITALICS | REDUCE_RANGE
else
. = ..()
/mob/living/simple_animal/hostile/swarmer/get_spans()
return ..() | SPAN_ROBOT
@@ -32,7 +32,7 @@
return MAP_ERROR
var/obj/effect/dummy/slaughter/holder = new /obj/effect/dummy/slaughter((pick(spawn_locs)))
var/mob/living/simple_animal/slaughter/S = new /mob/living/simple_animal/slaughter/(holder)
var/mob/living/simple_animal/slaughter/S = new (holder)
S.holder = holder
player_mind.transfer_to(S)
player_mind.assigned_role = "Slaughter Demon"
+6 -7
View File
@@ -264,10 +264,11 @@
var/TC_uses = 0
for(var/datum/mind/syndicate in syndicates)
text += printplayer(syndicate)
for(var/obj/item/device/uplink/H in GLOB.uplinks)
if(H && H.owner && H.owner == syndicate.key)
TC_uses += H.spent_telecrystals
purchases += H.purchase_log
for(var/datum/component/uplink/H in GLOB.uplinks)
if(H.purchase_log)
purchases += H.purchase_log.generate_render()
else
stack_trace("WARNING: Uplink with no purchase_log in nuclear mode! Owner: [H.owner]")
text += "<br>"
text += "(Syndicates used [TC_uses] TC) [purchases]"
if(TC_uses == 0 && station_was_nuked && !are_operatives_dead())
@@ -325,9 +326,7 @@
R.freqlock = 1
if(tc)
var/obj/item/device/radio/uplink/nuclear/U = new(H)
U.hidden_uplink.owner = "[H.key]"
U.hidden_uplink.telecrystals = tc
var/obj/item/device/radio/uplink/nuclear/U = new(H, H.key, tc)
H.equip_to_slot_or_del(U, slot_in_backpack)
var/obj/item/implant/weapons_auth/W = new/obj/item/implant/weapons_auth(H)
@@ -54,33 +54,31 @@
var/obj/item/circuitboard/computer/syndicate_shuttle/board = V
board.challenge = TRUE
var/obj/item/device/radio/uplink/nuclear/U = new(get_turf(user))
U.hidden_uplink.owner = "[user.key]"
U.hidden_uplink.telecrystals = CHALLENGE_TELECRYSTALS
U.hidden_uplink.set_gamemode(/datum/game_mode/nuclear)
new /obj/item/device/radio/uplink/nuclear(get_turf(user), user.key, CHALLENGE_TELECRYSTALS)
CONFIG_SET(number/shuttle_refuel_delay, max(CONFIG_GET(number/shuttle_refuel_delay), CHALLENGE_SHUTTLE_DELAY))
SSblackbox.set_val("nuclear_challenge_mode",1)
SSblackbox.record_feedback("amount", "nuclear_challenge_mode", 1)
qdel(src)
/obj/item/device/nuclear_challenge/proc/check_allowed(mob/living/user)
if(declaring_war)
to_chat(user, "You are already in the process of declaring war! Make your mind up.")
return 0
return FALSE
if(GLOB.player_list.len < CHALLENGE_MIN_PLAYERS)
to_chat(user, "The enemy crew is too small to be worth declaring war on.")
return 0
return FALSE
if(user.z != ZLEVEL_CENTCOM)
to_chat(user, "You have to be at your base to use this.")
return 0
return FALSE
if(world.time-SSticker.round_start_time > CHALLENGE_TIME_LIMIT)
to_chat(user, "It's too late to declare hostilities. Your benefactors are already busy with other schemes. You'll have to make do with what you have on hand.")
return 0
return FALSE
for(var/V in GLOB.syndicate_shuttle_boards)
var/obj/item/circuitboard/computer/syndicate_shuttle/board = V
if(board.moved)
to_chat(user, "The shuttle has already been moved! You have forfeit the right to declare war.")
return 0
return 1
return FALSE
return TRUE
#undef CHALLENGE_TELECRYSTALS
#undef CHALLENGE_MIN_PLAYERS
+1 -1
View File
@@ -28,7 +28,7 @@ GLOBAL_VAR_INIT(hsboxspawn, TRUE)
var/global/list/spawn_forbidden = list(
/obj/item/tk_grab, /obj/item/implant, // not implanter, the actual thing that is inside you
/obj/item/assembly, /obj/item/device/onetankbomb, /obj/item/radio, /obj/item/device/pda/ai,
/obj/item/device/uplink, /obj/item/smallDelivery, /obj/item/projectile,
/obj/item/smallDelivery, /obj/item/projectile,
/obj/item/borg/sight, /obj/item/borg/stun, /obj/item/robot_module)
/datum/hSB/proc/update()
+6 -6
View File
@@ -103,11 +103,11 @@
var/TC_uses = 0
var/uplink_true = FALSE
var/purchases = ""
for(var/obj/item/device/uplink/H in GLOB.uplinks)
for(var/datum/component/uplink/H in GLOB.uplinks)
if(H && H.owner && H.owner == traitor.key)
TC_uses += H.spent_telecrystals
uplink_true = TRUE
purchases += H.purchase_log
purchases += H.purchase_log.generate_render(FALSE)
var/objectives = ""
if(traitor.objectives.len)//If the traitor had no objectives, don't need to process this.
@@ -115,10 +115,10 @@
for(var/datum/objective/objective in traitor.objectives)
if(objective.check_completion())
objectives += "<br><B>Objective #[count]</B>: [objective.explanation_text] <font color='green'><B>Success!</B></font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("traitor_objective","[objective.type]|SUCCESS")
SSblackbox.record_feedback("nested tally", "traitor_objective", 1, list("[objective.type]", "SUCCESS"))
else
objectives += "<br><B>Objective #[count]</B>: [objective.explanation_text] <font color='red'>Fail.</font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("traitor_objective","[objective.type]|FAIL")
SSblackbox.record_feedback("nested tally", "traitor_objective", 1, list("[objective.type]", "FAIL"))
if(!(istype(objective, /datum/objective/crew)))
traitorwin = FALSE
count++
@@ -140,10 +140,10 @@
if(traitorwin)
text += "<br><font color='green'><B>The [special_role_text] was successful!</B></font>"
SSblackbox.add_details("traitor_success","SUCCESS")
SSblackbox.record_feedback("tally", "traitor_success", 1, "SUCCESS")
else
text += "<br><font color='red'><B>The [special_role_text] has failed!</B></font>"
SSblackbox.add_details("traitor_success","FAIL")
SSblackbox.record_feedback("tally", "traitor_success", 1, "FAIL")
SEND_SOUND(traitor.current, 'sound/ambience/ambifailure.ogg')
text += "<br>"
+12 -2
View File
@@ -33,7 +33,7 @@
/obj/effect/rend
name = "tear in the fabric of reality"
desc = "You should run now."
icon = 'icons/obj/biomass.dmi'
icon = 'icons/effects/effects.dmi'
icon_state = "rift"
density = TRUE
anchored = TRUE
@@ -66,6 +66,12 @@
else
return ..()
/obj/effect/rend/singularity_pull()
return
/obj/effect/rend/singularity_pull()
return
/obj/item/veilrender/vealrender
name = "veal render"
desc = "A wicked curved blade of alien origin, recovered from the ruins of a vast farm."
@@ -300,6 +306,11 @@
var/area/A = get_area(src)
to_chat(victim, "<span class='notice'>You feel a dark presence from [A.name]</span>")
/obj/item/voodoo/suicide_act(mob/living/carbon/user)
user.visible_message("<span class='suicide'>[user] links the voodoo doll to themself and sits on it, infinitely crushing themself! It looks like [user.p_theyre()] trying to commit suicide!</span>")
user.gib()
return(BRUTELOSS)
/obj/item/voodoo/fire_act(exposed_temperature, exposed_volume)
if(target)
target.adjust_fire_stacks(20)
@@ -307,7 +318,6 @@
GiveHint(target,1)
return ..()
//Provides a decent heal, need to pump every 6 seconds
/obj/item/organ/heart/cursed/wizard
pump_delay = 60
+8 -8
View File
@@ -57,10 +57,10 @@
aspell.name = "Instant [aspell.name]"
if(aspell.spell_level >= aspell.level_max)
to_chat(user, "<span class='notice'>This spell cannot be strengthened any further.</span>")
SSblackbox.add_details("wizard_spell_improved", "[name]|[aspell.level]")
SSblackbox.record_feedback("nested tally", "wizard_spell_improved", 1, list("[name]", "[aspell.level]"))
return 1
//No same spell found - just learn it
SSblackbox.add_details("wizard_spell_learned", name)
SSblackbox.record_feedback("tally", "wizard_spell_learned", 1, name)
user.mind.AddSpell(S)
to_chat(user, "<span class='notice'>You have learned [S.name].</span>")
return 1
@@ -265,7 +265,7 @@
/datum/spellbook_entry/item/Buy(mob/living/carbon/human/user,obj/item/spellbook/book)
new item_path(get_turf(user))
SSblackbox.add_details("wizard_spell_learned", name)
SSblackbox.record_feedback("tally", "wizard_spell_learned", 1, name)
return 1
/datum/spellbook_entry/item/GetInfo()
@@ -464,7 +464,7 @@
return TRUE
/datum/spellbook_entry/summon/ghosts/Buy(mob/living/carbon/human/user, obj/item/spellbook/book)
SSblackbox.add_details("wizard_spell_learned", name)
SSblackbox.record_feedback("tally", "wizard_spell_learned", 1, name)
new /datum/round_event/wizard/ghost()
active = TRUE
to_chat(user, "<span class='notice'>You have cast summon ghosts!</span>")
@@ -481,7 +481,7 @@
return !CONFIG_GET(flag/no_summon_guns)
/datum/spellbook_entry/summon/guns/Buy(mob/living/carbon/human/user,obj/item/spellbook/book)
SSblackbox.add_details("wizard_spell_learned", name)
SSblackbox.record_feedback("tally", "wizard_spell_learned", 1, name)
rightandwrong(0, user, 25)
active = 1
playsound(get_turf(user), 'sound/magic/castsummon.ogg', 50, 1)
@@ -498,7 +498,7 @@
return !CONFIG_GET(flag/no_summon_magic)
/datum/spellbook_entry/summon/magic/Buy(mob/living/carbon/human/user,obj/item/spellbook/book)
SSblackbox.add_details("wizard_spell_learned", name)
SSblackbox.record_feedback("tally", "wizard_spell_learned", 1, name)
rightandwrong(1, user, 25)
active = 1
playsound(get_turf(user), 'sound/magic/castsummon.ogg', 50, 1)
@@ -516,7 +516,7 @@
return !CONFIG_GET(flag/no_summon_events)
/datum/spellbook_entry/summon/events/Buy(mob/living/carbon/human/user,obj/item/spellbook/book)
SSblackbox.add_details("wizard_spell_learned", name)
SSblackbox.record_feedback("tally", "wizard_spell_learned", 1, name)
summonevents()
times++
playsound(get_turf(user), 'sound/magic/castsummon.ogg', 50, 1)
@@ -905,7 +905,7 @@
var/static/banned_spells = list(/obj/item/spellbook/oneuse/mimery_blockade, /obj/item/spellbook/oneuse/mimery_guns)
var/real_type = pick(subtypesof(/obj/item/spellbook/oneuse) - banned_spells)
new real_type(loc)
qdel(src)
return INITIALIZE_HINT_QDEL
/obj/item/spellbook/oneuse/sacredflame
spell = /obj/effect/proc_holder/spell/targeted/sacred_flame
+5 -5
View File
@@ -91,20 +91,20 @@
for(var/datum/objective/objective in wizard.objectives)
if(objective.check_completion())
text += "<br><B>Objective #[count]</B>: [objective.explanation_text] <font color='green'><B>Success!</B></font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("wizard_objective","[objective.type]|SUCCESS")
SSblackbox.record_feedback("nested tally", "wizard_objective", 1, list("[objective.type]", "SUCCESS"))
else
text += "<br><B>Objective #[count]</B>: [objective.explanation_text] <font color='red'>Fail.</font> [istype(objective, /datum/objective/crew) ? "<font color='grey'>(Optional)</font>" : ""]"
SSblackbox.add_details("wizard_objective","[objective.type]|FAIL")
SSblackbox.record_feedback("nested tally", "wizard_objective", 1, list("[objective.type]", "FAIL"))
if(!(istype(objective, /datum/objective/crew)))
wizardwin = 0
count++
if(wizard.current && wizard.current.stat!=2 && wizardwin)
if(wizard.current && wizardwin)
text += "<br><font color='green'><B>The wizard was successful!</B></font>"
SSblackbox.add_details("wizard_success","SUCCESS")
SSblackbox.record_feedback("tally", "wizard_success", 1, "SUCCESS")
else
text += "<br><font color='red'><B>The wizard has failed!</B></font>"
SSblackbox.add_details("wizard_success","FAIL")
SSblackbox.record_feedback("tally", "wizard_success", 1, "FAIL")
if(wizard.spell_list.len>0)
text += "<br><B>[wizard.name] used the following spells: </B>"
var/i = 1
+4 -8
View File
@@ -229,7 +229,6 @@
playsound(loc, 'sound/arcade/win.ogg', 50, 1, extrarange = -3, falloff = 10)
if(emagged)
SSblackbox.inc("arcade_win_emagged")
new /obj/effect/spawner/newbomb/timer/syndicate(loc)
new /obj/item/clothing/head/collectable/petehat(loc)
message_admins("[key_name_admin(usr)] has outbombed Cuban Pete and been awarded a bomb.")
@@ -237,8 +236,9 @@
Reset()
emagged = FALSE
else
SSblackbox.inc("arcade_win_normal")
prizevend()
SSblackbox.record_feedback("nested tally", "arcade_results", 1, list("win", (emagged ? "emagged":"normal")))
else if (emagged && (turtle >= 4))
var/boomamt = rand(5,10)
@@ -259,10 +259,8 @@
temp = "You have been drained! GAME OVER"
playsound(loc, 'sound/arcade/lose.ogg', 50, 1, extrarange = -3, falloff = 10)
if(emagged)
SSblackbox.inc("arcade_loss_mana_emagged")
usr.gib()
else
SSblackbox.inc("arcade_loss_mana_normal")
SSblackbox.record_feedback("nested tally", "arcade_results", 1, list("loss", "mana", (emagged ? "emagged":"normal")))
else if ((enemy_hp <= 10) && (enemy_mp > 4))
temp = "[enemy_name] heals for 4 health!"
@@ -281,10 +279,8 @@
temp = "You have been crushed! GAME OVER"
playsound(loc, 'sound/arcade/lose.ogg', 50, 1, extrarange = -3, falloff = 10)
if(emagged)
SSblackbox.inc("arcade_loss_hp_emagged")
usr.gib()
else
SSblackbox.inc("arcade_loss_hp_normal")
SSblackbox.record_feedback("nested tally", "arcade_results", 1, list("loss", "hp", (emagged ? "emagged":"normal")))
blocked = FALSE
return
@@ -43,6 +43,7 @@
for(var/V in actions)
var/datum/action/A = V
A.Remove(user)
actions.Cut()
if(user.client)
user.reset_perspective(null)
eyeobj.RemoveImages()
@@ -62,6 +63,7 @@
current_user.unset_machine()
if(eyeobj)
qdel(eyeobj)
QDEL_LIST(actions)
return ..()
/obj/machinery/computer/camera_advanced/on_unset_machine(mob/M)
+1 -11
View File
@@ -115,11 +115,6 @@
//Only notify the admins if an actual change happened
log_game("[key_name(usr)] has changed the security level to [get_security_level()].")
message_admins("[key_name_admin(usr)] has changed the security level to [get_security_level()].")
switch(GLOB.security_level)
if(SEC_LEVEL_GREEN)
SSblackbox.inc("alert_comms_green",1)
if(SEC_LEVEL_BLUE)
SSblackbox.inc("alert_comms_blue",1)
tmp_alertlevel = 0
else
to_chat(usr, "<span class='warning'>You are not authorized to do this!</span>")
@@ -178,7 +173,7 @@
SSshuttle.points -= S.credit_cost
minor_announce("[usr.name] has purchased [S.name] for [S.credit_cost] credits." , "Shuttle Purchase")
message_admins("[key_name_admin(usr)] purchased [S.name].")
SSblackbox.add_details("shuttle_purchase", S.name)
SSblackbox.record_feedback("text", "shuttle_purchase", 1, "[S.name]")
else
to_chat(usr, "Something went wrong! The shuttle exchange system seems to be down.")
else
@@ -387,11 +382,6 @@
//Only notify the admins if an actual change happened
log_game("[key_name(usr)] has changed the security level to [get_security_level()].")
message_admins("[key_name_admin(usr)] has changed the security level to [get_security_level()].")
switch(GLOB.security_level)
if(SEC_LEVEL_GREEN)
SSblackbox.inc("alert_comms_green",1)
if(SEC_LEVEL_BLUE)
SSblackbox.inc("alert_comms_blue",1)
tmp_alertlevel = 0
aistate = STATE_DEFAULT
if("ai-changeseclevel")
+6 -6
View File
@@ -75,9 +75,9 @@
popup.add_stylesheet("scannernew", 'html/browser/scannernew.css')
var/mob/living/carbon/viable_occupant
var/occupant_status = "<div class='line'><div class='statusLabel'>Subject Status:</div><div class='statusValue'>"
var/list/occupant_status = list("<div class='line'><div class='statusLabel'>Subject Status:</div><div class='statusValue'>")
var/scanner_status
var/temp_html
var/list/temp_html = list()
if(connected && connected.is_operational())
if(connected.occupant) //set occupant_status message
viable_occupant = connected.occupant
@@ -117,9 +117,9 @@
occupant_status += "<span class='bad'>----</span></div></div>"
scanner_status += "<span class='bad'>Error: No scanner detected</span>"
var/status = "<div class='statusDisplay'>"
var/list/status = list("<div class='statusDisplay'>")
status += "<div class='line'><div class='statusLabel'>Scanner:</div><div class='statusValue'>[scanner_status]</div></div>"
status += "[occupant_status]"
status += occupant_status
status += "<div class='line'><h3>Radiation Emitter Status</h3></div>"
@@ -143,7 +143,7 @@
status += "<div class='line'><div class='statusLabel'>Pulse Duration:</div><div class='statusValue'>[radduration]</div></div>"
status += "<div class='line'><div class='statusLabel'>&nbsp;&nbsp;\> Accuracy:</div><div class='statusValue'>[chance_to_hit]</div></div>"
status += "<br></div>" // Close statusDisplay div
var/buttons = "<a href='?src=[REF(src)];'>Scan</a> "
var/list/buttons = list("<a href='?src=[REF(src)];'>Scan</a> ")
if(connected)
buttons += " <a href='?src=[REF(src)];task=toggleopen;'>[connected.state_open ? "Close" : "Open"] Scanner</a> "
if (connected.state_open)
@@ -304,7 +304,7 @@
temp_html += "----"
temp_html += "</div></div></div>"
popup.set_content(temp_html)
popup.set_content(temp_html.Join())
popup.open()
+1 -1
View File
@@ -3,7 +3,7 @@
/obj/machinery/computer/robotics
name = "robotics control console"
desc = "Used to remotely lockdown or detonate linked Cyborgs."
desc = "Used to remotely lockdown or detonate linked Cyborgs and Drones."
icon_screen = "robot"
icon_keyboard = "rd_key"
req_access = list(ACCESS_ROBOTICS)
@@ -33,7 +33,8 @@ GLOBAL_LIST_INIT(possible_uplinker_IDs, list("Alfa","Bravo","Charlie","Delta","E
if(uplinkholder)
to_chat(user, "<span class='notice'>[src] already has an uplink in it.</span>")
return
if(I.hidden_uplink)
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, I)
if(hidden_uplink)
if(!user.transferItemToLoc(I, src))
return
uplinkholder = I
@@ -56,26 +57,28 @@ GLOBAL_LIST_INIT(possible_uplinker_IDs, list("Alfa","Bravo","Charlie","Delta","E
/obj/machinery/computer/telecrystals/uplinker/proc/donateTC(amt, addLog = 1)
if(uplinkholder && linkedboss)
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, uplinkholder)
if(amt < 0)
linkedboss.storedcrystals += uplinkholder.hidden_uplink.telecrystals
linkedboss.storedcrystals += hidden_uplink.telecrystals
if(addLog)
linkedboss.logTransfer("[src] donated [uplinkholder.hidden_uplink.telecrystals] telecrystals to [linkedboss].")
uplinkholder.hidden_uplink.telecrystals = 0
else if(amt <= uplinkholder.hidden_uplink.telecrystals)
uplinkholder.hidden_uplink.telecrystals -= amt
linkedboss.logTransfer("[src] donated [hidden_uplink.telecrystals] telecrystals to [linkedboss].")
hidden_uplink.telecrystals = 0
else if(amt <= hidden_uplink.telecrystals)
hidden_uplink.telecrystals -= amt
linkedboss.storedcrystals += amt
if(addLog)
linkedboss.logTransfer("[src] donated [amt] telecrystals to [linkedboss].")
/obj/machinery/computer/telecrystals/uplinker/proc/giveTC(amt, addLog = 1)
if(uplinkholder && linkedboss)
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, uplinkholder)
if(amt < 0)
uplinkholder.hidden_uplink.telecrystals += linkedboss.storedcrystals
hidden_uplink.telecrystals += linkedboss.storedcrystals
if(addLog)
linkedboss.logTransfer("[src] received [linkedboss.storedcrystals] telecrystals from [linkedboss].")
linkedboss.storedcrystals = 0
else if(amt <= linkedboss.storedcrystals)
uplinkholder.hidden_uplink.telecrystals += amt
hidden_uplink.telecrystals += amt
linkedboss.storedcrystals -= amt
if(addLog)
linkedboss.logTransfer("[src] received [amt] telecrystals from [linkedboss].")
@@ -95,7 +98,8 @@ GLOBAL_LIST_INIT(possible_uplinker_IDs, list("Alfa","Bravo","Charlie","Delta","E
dat += "No linked management consoles detected. Scan for uplink stations using the management console.<BR><BR>"
if(uplinkholder)
dat += "[uplinkholder.hidden_uplink.telecrystals] telecrystals remain in this uplink.<BR>"
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, uplinkholder)
dat += "[hidden_uplink.telecrystals] telecrystals remain in this uplink.<BR>"
if(linkedboss)
dat += "Donate TC: <a href='byond://?src=[REF(src)];donate=1'>1</a> | <a href='byond://?src=[REF(src)];donate=5'>5</a> | <a href='byond://?src=[REF(src)];donate=-1'>All</a>"
dat += "<br><a href='byond://?src=[REF(src)];eject=1'>Eject Uplink</a>"
@@ -175,7 +179,8 @@ GLOBAL_LIST_INIT(possible_uplinker_IDs, list("Alfa","Bravo","Charlie","Delta","E
for(var/obj/machinery/computer/telecrystals/uplinker/A in TCstations)
dat += "[A.name] | "
if(A.uplinkholder)
dat += "[A.uplinkholder.hidden_uplink.telecrystals] telecrystals."
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, A.uplinkholder)
dat += "[hidden_uplink.telecrystals] telecrystals."
if(storedcrystals)
dat+= "<BR>Add TC: <a href ='?src=[REF(src)];target=[REF(A)];give=1'>1</a> | <a href ='?src=[REF(src)];target=[REF(A)];give=5'>5</a> | <a href ='?src=[REF(src)];target=[REF(A)];give=10'>10</a> | <a href ='?src=[REF(src)];target=[REF(A)];give=-1'>All</a>"
dat += "<BR>"
+5 -4
View File
@@ -49,6 +49,7 @@
var/normal_integrity = AIRLOCK_INTEGRITY_N
integrity_failure = 70
damage_deflection = AIRLOCK_DAMAGE_DEFLECTION_N
interact_open = TRUE
var/security_level = 0 //How much are wires secured
var/aiControlDisabled = 0 //If 1, AI control is disabled until the AI hacks back in and disables the lock. If 2, the AI has bypassed the lock. If -1, the control is enabled but the AI had bypassed it earlier, so if it is disabled again the AI would have no trouble getting back in.
@@ -118,8 +119,8 @@
if(damage_deflection == AIRLOCK_DAMAGE_DEFLECTION_N && security_level > AIRLOCK_SECURITY_METAL)
damage_deflection = AIRLOCK_DAMAGE_DEFLECTION_R
prepare_huds()
var/datum/atom_hud/data/diagnostic/diag_hud = GLOB.huds[DATA_HUD_DIAGNOSTIC]
diag_hud.add_to_hud(src)
for(var/datum/atom_hud/data/diagnostic/diag_hud in GLOB.huds)
diag_hud.add_to_hud(src)
diag_hud_set_electrified()
return INITIALIZE_HINT_LATELOAD
@@ -241,8 +242,8 @@
for(var/obj/machinery/doorButtons/D in GLOB.machines)
D.removeMe(src)
qdel(note)
var/datum/atom_hud/data/diagnostic/diag_hud = GLOB.huds[DATA_HUD_DIAGNOSTIC]
diag_hud.remove_from_hud(src)
for(var/datum/atom_hud/data/diagnostic/diag_hud in GLOB.huds)
diag_hud.remove_from_hud(src)
return ..()
/obj/machinery/door/airlock/handle_atom_del(atom/A)
+3
View File
@@ -255,12 +255,15 @@
return 1
if(operating)
return
if(welded)
return
if(safe)
for(var/atom/movable/M in get_turf(src))
if(M.density && M != src) //something is blocking the door
if(autoclose)
addtimer(CALLBACK(src, .proc/autoclose), 60)
return
operating = TRUE
do_animate("closing")
-106
View File
@@ -1,106 +0,0 @@
/obj/machinery/exonet_node
name = "exonet node"
icon = 'icons/obj/stationobjs.dmi'
icon_state = "exonet_node"
idle_power_usage = 25
var/on = TRUE
var/toggle = TRUE
density = TRUE
anchored = TRUE
circuit = /obj/item/circuitboard/machine/exonet_node
max_integrity = 300
integrity_failure = 100
armor = list("melee" = 20, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 70)
desc = "This machine is exonet node."
var/list/logs = list() // Gets written to by exonet's send_message() function.
var/opened = FALSE
/obj/machinery/exonet_node/Initialize()
. = ..()
SScircuit.all_exonet_nodes += src
/obj/machinery/exonet_node/Destroy()
SScircuit.all_exonet_nodes -= src
return ..()
/obj/machinery/exonet_node/proc/is_operating()
return on && !stat
// Proc: update_icon()
// Parameters: None
// Description: Self explanatory.
/obj/machinery/exonet_node/update_icon()
icon_state = "[initial(icon_state)][on? "" : "_off"]"
// Proc: update_power()
// Parameters: None
// Description: Sets the device on/off and adjusts power draw based on stat and toggle variables.
/obj/machinery/exonet_node/proc/update_power()
on = is_operational() && toggle
use_power = on
update_icon()
// Proc: emp_act()
// Parameters: 1 (severity - how strong the EMP is, with lower numbers being stronger)
// Description: Shuts off the machine for awhile if an EMP hits it. Ion anomalies also call this to turn it off.
/obj/machinery/exonet_node/emp_act(severity)
if(!(stat & EMPED))
stat |= EMPED
var/duration = (300 * 10)/severity
addtimer(CALLBACK(src, /obj/machinery/exonet_node/proc/unemp_act), rand(duration - 20, duration + 20))
update_icon()
..()
/obj/machinery/exonet_node/proc/unemp_act(severity)
stat &= ~EMPED
// Proc: attackby()
// Parameters: 2 (I - the item being whacked against the machine, user - the person doing the whacking)
// Description: Handles deconstruction.
/obj/machinery/exonet_node/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/screwdriver))
default_deconstruction_screwdriver(user, I)
else if(istype(I, /obj/item/crowbar))
default_deconstruction_crowbar(user, I)
else
return ..()
// Proc: attack_ai()
// Parameters: 1 (user - the AI clicking on the machine)
// Description: Redirects to attack_hand()
/obj/machinery/exonet_node/attack_ai(mob/user)
ui_interact(user)
/obj/machinery/exonet_node/ui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, var/force_open = 1,datum/tgui/master_ui = null, datum/ui_state/state = GLOB.default_state)
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
if(!ui)
ui = new(user, src, ui_key, "exonet_node", name, 600, 300, master_ui, state)
ui.open()
/obj/machinery/exonet_node/ui_data(mob/user)
var/list/data = list()
data["toggle"] = toggle
data["logs"] = logs
return data
/obj/machinery/exonet_node/ui_act(action, params)
if(..())
return
switch(action)
if("toggle_power")
toggle = !toggle
update_power()
if(!toggle)
investigate_log("has been turned off by [key_name(usr)].", INVESTIGATE_EXONET)
. = TRUE
update_icon()
add_fingerprint(usr)
// Proc: get_exonet_node()
// Parameters: None
// Description: Helper proc to get a reference to an Exonet node.
/obj/machinery/exonet_node/proc/write_log(var/origin_address, var/target_address, var/data_type, var/content)
var/msg = "[time2text(world.time, "hh:mm:ss")] | FROM [origin_address] TO [target_address] | TYPE: [data_type] | CONTENT: [content]"
logs.Add(msg)
+192 -3
View File
@@ -47,6 +47,12 @@ Possible to do for anyone motivated enough:
var/temp = ""
var/list/holo_calls //array of /datum/holocalls
var/datum/holocall/outgoing_call //do not modify the datums only check and call the public procs
var/obj/item/disk/holodisk/disk //Record disk
var/replay_mode = FALSE //currently replaying a recording
var/record_mode = FALSE //currently recording
var/record_start = 0 //recording start time
var/record_user //user that inititiated the recording
var/obj/effect/overlay/holo_pad_hologram/replay_holo //replay hologram
var/static/force_answer_call = FALSE //Calls will be automatically answered after a couple rings, here for debugging
var/static/list/holopads = list()
@@ -64,6 +70,14 @@ Possible to do for anyone motivated enough:
for (var/I in masters)
clear_holo(I)
if(replay_mode)
replay_stop()
if(record_mode)
record_stop()
QDEL_NULL(disk)
holopads -= src
return ..()
@@ -72,6 +86,10 @@ Possible to do for anyone motivated enough:
stat &= ~NOPOWER
else
stat |= NOPOWER
if(replay_mode)
replay_stop()
if(record_mode)
record_stop()
if(outgoing_call)
outgoing_call.ConnectionFailure(src)
@@ -101,6 +119,18 @@ Possible to do for anyone motivated enough:
if(default_deconstruction_crowbar(P))
return
if(istype(P,/obj/item/disk/holodisk))
if(disk)
to_chat(user,"<span class='notice'>There's already a disk inside [src]</span>")
return
if (!user.transferItemToLoc(P,src))
return
to_chat(user,"<span class='notice'>You insert [P] into [src]</span>")
disk = P
updateDialog()
return
return ..()
/obj/machinery/holopad/AltClick(mob/living/carbon/human/user)
@@ -122,6 +152,17 @@ Possible to do for anyone motivated enough:
else
dat = "<a href='?src=[REF(src)];AIrequest=1'>Request an AI's presence.</a><br>"
dat += "<a href='?src=[REF(src)];Holocall=1'>Call another holopad.</a><br>"
if(disk)
if(disk.record)
//Replay
dat += "<a href='?src=[REF(src)];replay_start=1'>Replay disk recording.</a><br>"
//Clear
dat += "<a href='?src=[REF(src)];record_clear=1'>Clear disk recording.</a><br>"
else
//Record
dat += "<a href='?src=[REF(src)];record_start=1'>Start new recording.</a><br>"
//Eject
dat += "<a href='?src=[REF(src)];disk_eject=1'>Eject disk.</a><br>"
if(LAZYLEN(holo_calls))
dat += "=====================================================<br>"
@@ -145,7 +186,7 @@ Possible to do for anyone motivated enough:
dat += "<a href='?src=[REF(src)];disconnectcall=[REF(HC)]'>Disconnect call from [HC.user].</a><br>"
var/datum/browser/popup = new(user, "holopad", name, 300, 130)
var/datum/browser/popup = new(user, "holopad", name, 300, 150)
popup.set_content(dat)
popup.set_title_image(user.browse_rsc_icon(src.icon, src.icon_state))
popup.open()
@@ -215,6 +256,22 @@ Possible to do for anyone motivated enough:
temp = ""
if(outgoing_call)
outgoing_call.Disconnect()
else if(href_list["disk_eject"])
if(disk && !replay_mode)
disk.forceMove(drop_location())
disk = null
else if(href_list["replay_stop"])
replay_stop()
else if(href_list["replay_start"])
replay_start()
else if(href_list["record_start"])
record_start(usr)
else if(href_list["record_stop"])
record_stop()
else if(href_list["record_clear"])
record_clear()
updateDialog()
@@ -269,6 +326,7 @@ Possible to do for anyone motivated enough:
else
playsound(src, 'sound/machines/twobeep.ogg', 100) //bring, bring!
/obj/machinery/holopad/proc/activate_holo(mob/living/user)
var/mob/living/silicon/ai/AI = user
if(!istype(AI))
@@ -321,15 +379,24 @@ For the other part of the code, check silicon say.dm. Particularly robot talk.*/
if(outgoing_call && speaker == outgoing_call.user)
outgoing_call.hologram.say(raw_message)
if(record_mode && speaker == record_user)
record_message(speaker,raw_message,message_language)
/obj/machinery/holopad/proc/SetLightsAndPower()
var/total_users = masters.len + LAZYLEN(holo_calls)
use_power = total_users > 0 ? ACTIVE_POWER_USE : IDLE_POWER_USE
active_power_usage = HOLOPAD_PASSIVE_POWER_USAGE + (HOLOGRAM_POWER_USAGE * total_users)
if(total_users)
if(total_users || replay_mode)
set_light(2)
icon_state = "holopad1"
else
set_light(0)
update_icon()
/obj/machinery/holopad/update_icon()
var/total_users = masters.len + LAZYLEN(holo_calls)
if(total_users || replay_mode)
icon_state = "holopad1"
else
icon_state = "holopad0"
/obj/machinery/holopad/proc/set_holo(mob/living/user, var/obj/effect/overlay/holo_pad_hologram/h)
@@ -365,6 +432,128 @@ For the other part of the code, check silicon say.dm. Particularly robot talk.*/
clear_holo(user)
return TRUE
// RECORDED MESSAGES
/obj/machinery/holopad/proc/setup_replay_holo(datum/holorecord/record)
var/obj/effect/overlay/holo_pad_hologram/Hologram = new(loc)//Spawn a blank effect at the location.
Hologram.add_overlay(record.caller_image)
Hologram.alpha = 170
Hologram.add_atom_colour("#77abff", FIXED_COLOUR_PRIORITY)
Hologram.dir = SOUTH //for now
Hologram.grant_all_languages(omnitongue=TRUE)
var/datum/language_holder/holder = Hologram.get_language_holder()
holder.selected_default_language = record.language
Hologram.mouse_opacity = MOUSE_OPACITY_TRANSPARENT//So you can't click on it.
Hologram.layer = FLY_LAYER//Above all the other objects/mobs. Or the vast majority of them.
Hologram.anchored = TRUE//So space wind cannot drag it.
Hologram.name = "[record.caller_name] (Hologram)"//If someone decides to right click.
Hologram.set_light(2) //hologram lighting
visible_message("<span class='notice'>A holographic image of [record.caller_name] flickers to life before your eyes!</span>")
return Hologram
/obj/machinery/holopad/proc/replay_start()
if(!replay_mode)
replay_mode = TRUE
replay_holo = setup_replay_holo(disk.record)
temp = "Replaying...<br>"
temp += "<A href='?src=[REF(src)];replay_stop=1'>End replay.</A>"
SetLightsAndPower()
replay_entry(1)
return
/obj/machinery/holopad/proc/replay_stop()
if(replay_mode)
replay_mode = FALSE
temp = null
QDEL_NULL(replay_holo)
SetLightsAndPower()
updateDialog()
/obj/machinery/holopad/proc/record_start(mob/living/user)
if(!user || !disk || disk.record)
return
disk.record = new
record_mode = TRUE
record_start = world.time
record_user = user
disk.record.caller_image = get_record_icon(user)
temp = "Recording...<br>"
temp += "<A href='?src=[REF(src)];record_stop=1'>End recording.</A>"
/obj/machinery/holopad/proc/get_record_icon(mob/living/user)
var/olddir = user.dir
user.setDir(SOUTH)
. = getFlatIcon(user)
user.setDir(olddir)
/obj/machinery/holopad/proc/record_message(mob/living/speaker,message,language)
if(!record_mode)
return
//make this command so you can have multiple languages in single record
if(!disk.record.caller_name && istype(speaker))
disk.record.caller_name = speaker.name
if(!disk.record.language)
disk.record.language = language
else if(language != disk.record.language)
disk.record.entries += list(list(HOLORECORD_LANGUAGE,language))
var/current_delay = 0
for(var/E in disk.record.entries)
var/list/entry = E
if(entry[1] != HOLORECORD_DELAY)
continue
current_delay += entry[2]
var/time_delta = world.time - record_start - current_delay
if(time_delta >= 1)
disk.record.entries += list(list(HOLORECORD_DELAY,time_delta))
disk.record.entries += list(list(HOLORECORD_SAY,message))
if(disk.record.entries.len >= HOLORECORD_MAX_LENGTH)
record_stop()
/obj/machinery/holopad/proc/replay_entry(entry_number)
if(!replay_mode)
return
if(disk.record.entries.len < entry_number)
replay_stop()
return
var/list/entry = disk.record.entries[entry_number]
var/command = entry[1]
switch(command)
if(HOLORECORD_SAY)
var/message = entry[2]
if(replay_holo)
replay_holo.say(message)
if(HOLORECORD_SOUND)
playsound(src,entry[2],50,1)
if(HOLORECORD_DELAY)
addtimer(CALLBACK(src,.proc/replay_entry,entry_number+1),entry[2])
return
if(HOLORECORD_LANGUAGE)
var/datum/language_holder/holder = replay_holo.get_language_holder()
holder.selected_default_language = entry[2]
if(HOLORECORD_PRESET)
var/preset_type = entry[2]
var/datum/preset_holoimage/H = new preset_type
replay_holo.cut_overlays()
replay_holo.add_overlay(H.build_image())
if(HOLORECORD_RENAME)
replay_holo.name = entry[2] + " (Hologram)"
.(entry_number+1)
/obj/machinery/holopad/proc/record_stop()
if(record_mode)
record_mode = FALSE
temp = null
record_user = null
updateDialog()
/obj/machinery/holopad/proc/record_clear()
if(disk && disk.record)
QDEL_NULL(disk.record)
updateDialog()
/obj/effect/overlay/holo_pad_hologram
var/mob/living/Impersonation
var/datum/holocall/HC
+1 -1
View File
@@ -175,7 +175,7 @@
return
if(beaker)
beaker.forceMove(get_turf(src))
beaker.forceMove(drop_location())
beaker = null
update_icon()
+1 -1
View File
@@ -155,7 +155,7 @@
briefcase = loc
else
log_game("[src] has been spawned without a briefcase.")
qdel(src)
return INITIALIZE_HINT_QDEL
/obj/machinery/launchpad/briefcase/Destroy()
QDEL_NULL(briefcase)
+3 -3
View File
@@ -533,7 +533,7 @@ GLOBAL_LIST_EMPTY(allCasters)
if(choice=="Confirm")
scan_user(usr)
GLOB.news_network.CreateFeedChannel(channel_name, scanned_user, c_locked)
SSblackbox.inc("newscaster_channels",1)
SSblackbox.record_feedback("text", "newscaster_channels", 1, "[channel_name]")
screen=5
updateUsrDialog()
else if(href_list["set_channel_receiving"])
@@ -556,7 +556,7 @@ GLOBAL_LIST_EMPTY(allCasters)
screen=6
else
GLOB.news_network.SubmitArticle("<font face=\"[PEN_FONT]\">[parsemarkdown(msg, usr)]</font>", scanned_user, channel_name, photo, 0, allow_comments)
SSblackbox.inc("newscaster_stories",1)
SSblackbox.record_feedback("amount", "newscaster_stories", 1)
screen=4
msg = ""
updateUsrDialog()
@@ -846,7 +846,7 @@ GLOBAL_LIST_EMPTY(allCasters)
return
/obj/machinery/newscaster/proc/print_paper()
SSblackbox.inc("newscaster_newspapers_printed",1)
SSblackbox.record_feedback("amount", "newspapers_printed", 1)
var/obj/item/newspaper/NEWSPAPER = new /obj/item/newspaper
for(var/datum/newscaster/feed_channel/FC in GLOB.news_network.network_channels)
NEWSPAPER.news_content += FC
@@ -73,6 +73,8 @@
var/obj/machinery/turretid/cp = null
var/wall_turret_direction //The turret will try to shoot from a turf in that direction when in a wall
/obj/machinery/porta_turret/Initialize()
. = ..()
if(!base)
@@ -503,6 +505,20 @@
if(!istype(T) || !istype(U))
return
//Wall turrets will try to find adjacent empty turf to shoot from to cover full arc
if(T.density)
if(wall_turret_direction)
var/turf/closer = get_step(T,wall_turret_direction)
if(istype(closer) && !is_blocked_turf(closer) && T.Adjacent(closer))
T = closer
else
var/target_dir = get_dir(T,target)
for(var/d in list(0,-45,45))
var/turf/closer = get_step(T,turn(target_dir,d))
if(istype(closer) && !is_blocked_turf(closer) && T.Adjacent(closer))
T = closer
break
update_icon()
var/obj/item/projectile/A
//any emagged turrets drains 2x power and uses a different projectile?
@@ -517,10 +533,13 @@
//Shooting Code:
A.preparePixelProjectile(target, src)
A.preparePixelProjectile(target, T)
A.fire()
return A
/obj/machinery/porta_turret/shuttleRotate(rotation)
if(wall_turret_direction)
wall_turret_direction = turn(wall_turret_direction,rotation)
/obj/machinery/porta_turret/proc/setState(on, mode)
if(controllock)
@@ -142,9 +142,7 @@
if(length(receive))
// --- This following recording is intended for research and feedback in the use of department radio channels ---
var/blackbox_msg = "[AM] [AM.say_quote(message, spans)]"
SSblackbox.LogBroadcast(blackbox_msg, freq)
SSblackbox.LogBroadcast(freq)
sleep(50)
if(!QDELETED(virt)) //It could happen to YOU
+2 -2
View File
@@ -510,7 +510,7 @@
if(icon_vend) //Show the vending animation if needed
flick(icon_vend,src)
new R.product_path(get_turf(src))
SSblackbox.add_details("vending_machine_usage","[type]|[R.product_path]")
SSblackbox.record_feedback("nested tally", "vending_machine_usage", 1, list("[type]", "[R.product_path]"))
vend_ready = 1
return
@@ -1066,7 +1066,7 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C
/obj/item/crowbar = 12, /obj/item/wirecutters = 12, /obj/item/device/multitool = 12, /obj/item/wrench = 12, /obj/item/device/t_scanner = 12,
/obj/item/stock_parts/cell = 8, /obj/item/weldingtool = 8, /obj/item/clothing/head/welding = 8,
/obj/item/light/tube = 10, /obj/item/clothing/suit/fire = 4, /obj/item/stock_parts/scanning_module = 5, /obj/item/stock_parts/micro_laser = 5,
/obj/item/stock_parts/matter_bin = 5, /obj/item/stock_parts/manipulator = 5, /obj/item/stock_parts/console_screen = 5)
/obj/item/stock_parts/matter_bin = 5, /obj/item/stock_parts/manipulator = 5)
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 0, bio = 0, rad = 0, fire = 100, acid = 50)
resistance_flags = FIRE_PROOF
@@ -504,7 +504,7 @@
return 1
return
/obj/item/mecha_parts/mecha_equipment/medical/syringe_gun/on_reagent_change()
/obj/item/mecha_parts/mecha_equipment/medical/syringe_gun/on_reagent_change(changetype)
..()
update_equip_info()
return
@@ -179,9 +179,6 @@
/obj/item/mecha_parts/mecha_equipment/extinguisher/get_equip_info()
return "[..()] \[[src.reagents.total_volume]\]"
/obj/item/mecha_parts/mecha_equipment/extinguisher/on_reagent_change()
return
/obj/item/mecha_parts/mecha_equipment/extinguisher/can_attach(obj/mecha/working/M as obj)
if(..())
if(istype(M))
+3 -3
View File
@@ -137,8 +137,8 @@
log_message("[src.name] created.")
GLOB.mechas_list += src //global mech list
prepare_huds()
var/datum/atom_hud/data/diagnostic/diag_hud = GLOB.huds[DATA_HUD_DIAGNOSTIC]
diag_hud.add_to_hud(src)
for(var/datum/atom_hud/data/diagnostic/diag_hud in GLOB.huds)
diag_hud.add_to_hud(src)
diag_hud_set_mechhealth()
diag_hud_set_mechcell()
diag_hud_set_mechstat()
@@ -1042,4 +1042,4 @@ GLOBAL_VAR_INIT(year_integer, text2num(year)) // = 2013???
/obj/mecha/update_remote_sight(mob/living/user)
if(occupant_sight_flags)
if(user == occupant)
user.sight |= occupant_sight_flags
user.sight |= occupant_sight_flags
@@ -304,13 +304,6 @@
holder.icon_state = "ripley14"
return TRUE
/datum/construction/reversible/mecha/ripley/spawn_mecha_result()
..()
SSblackbox.inc("mecha_ripley_created",1)
return
/datum/construction/mecha/gygax_chassis
steps = list(list("key"=/obj/item/mecha_parts/part/gygax_torso), //1
list("key"=/obj/item/mecha_parts/part/gygax_left_arm), //2
@@ -617,11 +610,6 @@
holder.icon_state = "gygax20"
return TRUE
/datum/construction/reversible/mecha/gygax/spawn_mecha_result()
..()
SSblackbox.inc("mecha_gygax_created",1)
return
/datum/construction/mecha/firefighter_chassis
steps = list(list("key"=/obj/item/mecha_parts/part/ripley_torso), //1
list("key"=/obj/item/mecha_parts/part/ripley_left_arm), //2
@@ -866,13 +854,6 @@
holder.icon_state = "fireripley15"
return TRUE
/datum/construction/reversible/mecha/firefighter/spawn_mecha_result()
..()
SSblackbox.inc("mecha_firefighter_created",1)
return
/datum/construction/mecha/honker_chassis
steps = list(list("key"=/obj/item/mecha_parts/part/honker_torso), //1
list("key"=/obj/item/mecha_parts/part/honker_left_arm), //2
@@ -953,10 +934,6 @@
qdel(used_atom)
return TRUE
/datum/construction/mecha/honker/spawn_mecha_result()
..()
SSblackbox.inc("mecha_honker_created",1)
/datum/construction/mecha/durand_chassis
steps = list(list("key"=/obj/item/mecha_parts/part/durand_torso), //1
list("key"=/obj/item/mecha_parts/part/durand_left_arm), //2
@@ -1264,10 +1241,6 @@
holder.icon_state = "durand20"
return TRUE
/datum/construction/reversible/mecha/durand/spawn_mecha_result()
..()
SSblackbox.inc("mecha_durand_created",1)
//PHAZON
/datum/construction/mecha/phazon_chassis
@@ -1620,10 +1593,6 @@
spawn_mecha_result()
return TRUE
/datum/construction/reversible/mecha/phazon/spawn_mecha_result()
..()
SSblackbox.inc("mecha_phazon_created",1)
//ODYSSEUS
/datum/construction/mecha/odysseus_chassis
@@ -1857,7 +1826,3 @@
user.visible_message("[user] unfastens the external armor layer.", "<span class='notice'>You unfasten the external armor layer.</span>")
holder.icon_state = "odysseus14"
return TRUE
/datum/construction/reversible/mecha/odysseus/spawn_mecha_result()
..()
SSblackbox.inc("mecha_odysseus_created",1)
+5 -3
View File
@@ -242,15 +242,17 @@
user.changeNext_move(CLICK_CD_MELEE)
var/obj/item/weldingtool/WT = W
if(obj_integrity<max_integrity)
if (WT.remove_fuel(0,user))
if(WT.remove_fuel(1, user))
if (internal_damage & MECHA_INT_TANK_BREACH)
clearInternalDamage(MECHA_INT_TANK_BREACH)
to_chat(user, "<span class='notice'>You repair the damaged gas tank.</span>")
else
user.visible_message("<span class='notice'>[user] repairs some damage to [name].</span>")
user.visible_message("<span class='notice'>[user] repairs some damage to [name].</span>", "<span class='notice'>You repair some damage to [src].</span>")
obj_integrity += min(10, max_integrity-obj_integrity)
if(obj_integrity == max_integrity)
to_chat(user, "<span class='notice'>It looks to be fully repaired now.</span>")
else
to_chat(user, "<span class='warning'>The welder must be on for this task!</span>")
to_chat(user, "<span class='warning'>[WT] needs to be on for this task!</span>")
return 1
else
to_chat(user, "<span class='warning'>The [name] is at full integrity!</span>")
+8 -5
View File
@@ -65,6 +65,7 @@
M.throw_alert("buckled", /obj/screen/alert/restrained/buckled)
post_buckle_mob(M)
SendSignal(COMSIG_MOVABLE_BUCKLE, M, force)
return TRUE
/obj/buckle_mob(mob/living/M, force = FALSE, check_loc = TRUE)
@@ -82,8 +83,9 @@
buckled_mob.update_canmove()
buckled_mob.clear_alert("buckled")
buckled_mobs -= buckled_mob
SendSignal(COMSIG_MOVABLE_UNBUCKLE, buckled_mob, force)
post_buckle_mob(.)
post_unbuckle_mob(.)
/atom/movable/proc/unbuckle_all_mobs(force=FALSE)
if(!has_buckled_mobs())
@@ -91,15 +93,16 @@
for(var/m in buckled_mobs)
unbuckle_mob(m, force)
//Handle any extras after buckling/unbuckling
//Called on buckle_mob() and unbuckle_mob()
//Handle any extras after buckling
//Called on buckle_mob()
/atom/movable/proc/post_buckle_mob(mob/living/M)
return
//same but for unbuckle
/atom/movable/proc/post_unbuckle_mob(mob/living/M)
//Wrapper procs that handle sanity and user feedback
/atom/movable/proc/user_buckle_mob(mob/living/M, mob/user, check_loc = TRUE)
if(!in_range(user, src) || user.stat || user.restrained())
if(!in_range(user, src) || !isturf(user.loc) || user.incapacitated())
return FALSE
add_fingerprint(user)
+1 -1
View File
@@ -228,7 +228,7 @@
var/turf/newloc = locate(A.x + x_distance, A.y + y_distance, TO.z) // calculate the new place
if(!A.Move(newloc) && newloc) // if the atom, for some reason, can't move, FORCE them to move! :) We try Move() first to invoke any movement-related checks the atom needs to perform after moving
A.loc = newloc
A.forceMove(newloc)
spawn()
if(ismob(A) && !(A in flashers)) // don't flash if we're already doing an effect
+31 -25
View File
@@ -1,30 +1,36 @@
/obj/effect/bump_teleporter
name = "bump-teleporter"
icon = 'icons/mob/screen_gen.dmi'
icon_state = "x2"
var/id = null //id of this bump_teleporter.
var/id_target = null //id of bump_teleporter which this moves you to.
invisibility = INVISIBILITY_ABSTRACT //nope, can't see this
/obj/effect/bump_teleporter
name = "bump-teleporter"
icon = 'icons/mob/screen_gen.dmi'
icon_state = "x2"
var/id = null //id of this bump_teleporter.
var/id_target = null //id of bump_teleporter which this moves you to.
invisibility = INVISIBILITY_ABSTRACT //nope, can't see this
anchored = TRUE
density = TRUE
opacity = 0
var/static/list/AllTeleporters
/obj/effect/bump_teleporter/New()
..()
LAZYADD(AllTeleporters, src)
/obj/effect/bump_teleporter/Destroy()
LAZYREMOVE(AllTeleporters, src)
return ..()
opacity = 0
var/static/list/AllTeleporters
/obj/effect/bump_teleporter/New()
..()
LAZYADD(AllTeleporters, src)
/obj/effect/bump_teleporter/Destroy()
LAZYREMOVE(AllTeleporters, src)
return ..()
/obj/effect/bump_teleporter/singularity_act()
return
/obj/effect/bump_teleporter/singularity_pull()
return
/obj/effect/bump_teleporter/CollidedWith(atom/movable/AM)
if(!ismob(AM))
return
if(!id_target)
return
for(var/obj/effect/bump_teleporter/BT in AllTeleporters)
if(BT.id == src.id_target)
return
if(!id_target)
return
for(var/obj/effect/bump_teleporter/BT in AllTeleporters)
if(BT.id == src.id_target)
AM.forceMove(BT.loc) //Teleport to location with correct id.
+6
View File
@@ -154,3 +154,9 @@
else
var/time_left = max(0, (A.death_time - world.time) / 10)
return round(time_left)
/obj/effect/countdown/singularity_pull()
return
/obj/effect/countdown/singularity_act()
return
+6
View File
@@ -56,3 +56,9 @@
/obj/effect/abstract/singularity_act()
return
/obj/effect/dummy/singularity_pull()
return
/obj/effect/dummy/singularity_act()
return
+3
View File
@@ -7,6 +7,9 @@
density = TRUE
CanAtmosPass = ATMOS_PASS_DENSITY
/obj/effect/forcefield/singularity_pull()
return
/obj/effect/forcefield/cult
desc = "An unholy shield that blocks all attacks."
name = "glowing wall"
+13
View File
@@ -19,15 +19,23 @@
icon = 'icons/mob/screen_gen.dmi'
icon_state = "x"
anchored = TRUE
var/jobspawn_override = FALSE
var/delete_after_roundstart = TRUE
/obj/effect/landmark/start/New()
GLOB.start_landmarks_list += src
if(jobspawn_override)
if(!GLOB.jobspawn_overrides[name])
GLOB.jobspawn_overrides[name] = list()
GLOB.jobspawn_overrides[name] += src
..()
if(name != "start")
tag = "start*[name]"
/obj/effect/landmark/start/Destroy()
GLOB.start_landmarks_list -= src
if(jobspawn_override)
GLOB.jobspawn_overrides[name] -= src
return ..()
// START LANDMARKS FOLLOW. Don't change the names unless
@@ -36,6 +44,10 @@
/obj/effect/landmark/start/assistant
name = "Assistant"
/obj/effect/landmark/start/assistant/override
jobspawn_override = TRUE
delete_after_roundstart = FALSE
/obj/effect/landmark/start/janitor
name = "Janitor"
@@ -74,6 +86,7 @@
/obj/effect/landmark/start/ai
name = "AI"
delete_after_roundstart = FALSE
/obj/effect/landmark/start/captain
name = "Captain"
+6
View File
@@ -12,6 +12,12 @@
var/def_zone
pass_flags = PASSTABLE
/obj/effect/beam/singularity_act()
return
/obj/effect/beam/singularity_pull()
return
/obj/effect/spawner
name = "object spawner"
+6
View File
@@ -75,6 +75,12 @@
if(isturf(hard_target_override))
hard_target = hard_target_override
/obj/effect/portal/singularity_pull()
return
/obj/effect/portal/singularity_act()
return
/obj/effect/portal/proc/link_portal(obj/effect/portal/newlink)
linked = newlink
if(atmos_link)
@@ -1,46 +1,46 @@
/obj/effect/spawner/newbomb
name = "bomb"
icon = 'icons/mob/screen_gen.dmi'
icon_state = "x"
var/btemp1 = 1500
var/btemp2 = 1000 // tank temperatures
var/assembly_type
/obj/effect/spawner/newbomb/Initialize()
/obj/effect/spawner/newbomb
name = "bomb"
icon = 'icons/mob/screen_gen.dmi'
icon_state = "x"
var/btemp1 = 1500
var/btemp2 = 1000 // tank temperatures
var/assembly_type
/obj/effect/spawner/newbomb/Initialize()
. = ..()
var/obj/item/device/transfer_valve/V = new(src.loc)
var/obj/item/tank/internals/plasma/full/PT = new(V)
var/obj/item/tank/internals/oxygen/OT = new(V)
PT.air_contents.temperature = btemp1 + T0C
OT.air_contents.temperature = btemp2 + T0C
V.tank_one = PT
V.tank_two = OT
PT.master = V
OT.master = V
if(assembly_type)
var/obj/item/device/assembly/A = new assembly_type(V)
V.attached_device = A
A.holder = V
A.toggle_secure()
V.update_icon()
qdel(src)
/obj/effect/spawner/newbomb/timer
assembly_type = /obj/item/device/assembly/timer
/obj/effect/spawner/newbomb/timer/syndicate
btemp1 = 150
btemp2 = 20
/obj/effect/spawner/newbomb/proximity
assembly_type = /obj/item/device/assembly/prox_sensor
/obj/effect/spawner/newbomb/radio
assembly_type = /obj/item/device/assembly/signaler
var/obj/item/device/transfer_valve/V = new(src.loc)
var/obj/item/tank/internals/plasma/full/PT = new(V)
var/obj/item/tank/internals/oxygen/OT = new(V)
PT.air_contents.temperature = btemp1 + T0C
OT.air_contents.temperature = btemp2 + T0C
V.tank_one = PT
V.tank_two = OT
PT.master = V
OT.master = V
if(assembly_type)
var/obj/item/device/assembly/A = new assembly_type(V)
V.attached_device = A
A.holder = V
A.toggle_secure()
V.update_icon()
return INITIALIZE_HINT_QDEL
/obj/effect/spawner/newbomb/timer
assembly_type = /obj/item/device/assembly/timer
/obj/effect/spawner/newbomb/timer/syndicate
btemp1 = 150
btemp2 = 20
/obj/effect/spawner/newbomb/proximity
assembly_type = /obj/item/device/assembly/prox_sensor
/obj/effect/spawner/newbomb/radio
assembly_type = /obj/item/device/assembly/signaler
@@ -38,7 +38,7 @@
if(directions.len)
gib.streak(directions)
qdel(src)
return INITIALIZE_HINT_QDEL
@@ -13,7 +13,7 @@ again.
if(spawn_list && spawn_list.len)
for(var/I in spawn_list)
new I(get_turf(src))
qdel(src)
return INITIALIZE_HINT_QDEL
//normal windows
+198 -193
View File
@@ -1,194 +1,199 @@
/* Simple object type, calls a proc when "stepped" on by something */
/obj/effect/step_trigger
var/affect_ghosts = 0
var/stopper = 1 // stops throwers
var/mobs_only = FALSE
invisibility = INVISIBILITY_ABSTRACT // nope cant see this shit
/* Simple object type, calls a proc when "stepped" on by something */
/obj/effect/step_trigger
var/affect_ghosts = 0
var/stopper = 1 // stops throwers
var/mobs_only = FALSE
invisibility = INVISIBILITY_ABSTRACT // nope cant see this shit
anchored = TRUE
/obj/effect/step_trigger/proc/Trigger(atom/movable/A)
return 0
/obj/effect/step_trigger/Crossed(H as mob|obj)
..()
if(!H)
return
if(isobserver(H) && !affect_ghosts)
return
if(!ismob(H) && mobs_only)
return
Trigger(H)
/* Sends a message to mob when triggered*/
/obj/effect/step_trigger/message
var/message //the message to give to the mob
var/once = 1
mobs_only = TRUE
/obj/effect/step_trigger/message/Trigger(mob/M)
if(M.client)
to_chat(M, "<span class='info'>[message]</span>")
if(once)
qdel(src)
/* Tosses things in a certain direction */
/obj/effect/step_trigger/thrower
var/direction = SOUTH // the direction of throw
var/tiles = 3 // if 0: forever until atom hits a stopper
var/immobilize = 1 // if nonzero: prevents mobs from moving while they're being flung
var/speed = 1 // delay of movement
var/facedir = 0 // if 1: atom faces the direction of movement
var/nostop = 0 // if 1: will only be stopped by teleporters
var/list/affecting = list()
/obj/effect/step_trigger/thrower/Trigger(atom/A)
if(!A || !ismovableatom(A))
return
var/atom/movable/AM = A
var/curtiles = 0
var/stopthrow = 0
for(var/obj/effect/step_trigger/thrower/T in orange(2, src))
if(AM in T.affecting)
return
if(ismob(AM))
var/mob/M = AM
if(immobilize)
M.canmove = 0
affecting.Add(AM)
while(AM && !stopthrow)
if(tiles)
if(curtiles >= tiles)
break
if(AM.z != src.z)
break
curtiles++
sleep(speed)
// Calculate if we should stop the process
if(!nostop)
for(var/obj/effect/step_trigger/T in get_step(AM, direction))
if(T.stopper && T != src)
stopthrow = 1
else
for(var/obj/effect/step_trigger/teleporter/T in get_step(AM, direction))
if(T.stopper)
stopthrow = 1
if(AM)
var/predir = AM.dir
step(AM, direction)
if(!facedir)
AM.setDir(predir)
affecting.Remove(AM)
if(ismob(AM))
var/mob/M = AM
if(immobilize)
M.canmove = 1
/* Stops things thrown by a thrower, doesn't do anything */
/obj/effect/step_trigger/stopper
/* Instant teleporter */
/obj/effect/step_trigger/teleporter
var/teleport_x = 0 // teleportation coordinates (if one is null, then no teleport!)
var/teleport_y = 0
var/teleport_z = 0
/obj/effect/step_trigger/teleporter/Trigger(atom/movable/A)
if(teleport_x && teleport_y && teleport_z)
A.x = teleport_x
A.y = teleport_y
A.z = teleport_z
/* Random teleporter, teleports atoms to locations ranging from teleport_x - teleport_x_offset, etc */
/obj/effect/step_trigger/teleporter/random
var/teleport_x_offset = 0
var/teleport_y_offset = 0
var/teleport_z_offset = 0
/obj/effect/step_trigger/teleporter/random/Trigger(atom/movable/A)
if(teleport_x && teleport_y && teleport_z)
if(teleport_x_offset && teleport_y_offset && teleport_z_offset)
A.x = rand(teleport_x, teleport_x_offset)
A.y = rand(teleport_y, teleport_y_offset)
A.z = rand(teleport_z, teleport_z_offset)
/* Fancy teleporter, creates sparks and smokes when used */
/obj/effect/step_trigger/teleport_fancy
var/locationx
var/locationy
var/uses = 1 //0 for infinite uses
var/entersparks = 0
var/exitsparks = 0
var/entersmoke = 0
var/exitsmoke = 0
/obj/effect/step_trigger/teleport_fancy/Trigger(mob/M)
var/dest = locate(locationx, locationy, z)
M.Move(dest)
if(entersparks)
var/datum/effect_system/spark_spread/s = new
s.set_up(4, 1, src)
s.start()
if(exitsparks)
var/datum/effect_system/spark_spread/s = new
s.set_up(4, 1, dest)
s.start()
if(entersmoke)
var/datum/effect_system/smoke_spread/s = new
s.set_up(4, 1, src, 0)
s.start()
if(exitsmoke)
var/datum/effect_system/smoke_spread/s = new
s.set_up(4, 1, dest, 0)
s.start()
uses--
if(uses == 0)
qdel(src)
/* Simple sound player, Mapper friendly! */
/obj/effect/step_trigger/sound_effect
var/sound //eg. path to the sound, inside '' eg: 'growl.ogg'
var/volume = 100
var/freq_vary = 1 //Should the frequency of the sound vary?
var/extra_range = 0 // eg World.view = 7, extra_range = 1, 7+1 = 8, 8 turfs radius
var/happens_once = 0
var/triggerer_only = 0 //Whether the triggerer is the only person who hears this
/obj/effect/step_trigger/sound_effect/Trigger(atom/movable/A)
var/turf/T = get_turf(A)
if(!T)
return
if(triggerer_only && ismob(A))
var/mob/B = A
B.playsound_local(T, sound, volume, freq_vary)
else
playsound(T, sound, volume, freq_vary, extra_range)
if(happens_once)
qdel(src)
/obj/effect/step_trigger/proc/Trigger(atom/movable/A)
return 0
/obj/effect/step_trigger/Crossed(H as mob|obj)
..()
if(!H)
return
if(isobserver(H) && !affect_ghosts)
return
if(!ismob(H) && mobs_only)
return
Trigger(H)
/obj/effect/step_trigger/singularity_act()
return
/obj/effect/step_trigger/singularity_pull()
return
/* Sends a message to mob when triggered*/
/obj/effect/step_trigger/message
var/message //the message to give to the mob
var/once = 1
mobs_only = TRUE
/obj/effect/step_trigger/message/Trigger(mob/M)
if(M.client)
to_chat(M, "<span class='info'>[message]</span>")
if(once)
qdel(src)
/* Tosses things in a certain direction */
/obj/effect/step_trigger/thrower
var/direction = SOUTH // the direction of throw
var/tiles = 3 // if 0: forever until atom hits a stopper
var/immobilize = 1 // if nonzero: prevents mobs from moving while they're being flung
var/speed = 1 // delay of movement
var/facedir = 0 // if 1: atom faces the direction of movement
var/nostop = 0 // if 1: will only be stopped by teleporters
var/list/affecting = list()
/obj/effect/step_trigger/thrower/Trigger(atom/A)
if(!A || !ismovableatom(A))
return
var/atom/movable/AM = A
var/curtiles = 0
var/stopthrow = 0
for(var/obj/effect/step_trigger/thrower/T in orange(2, src))
if(AM in T.affecting)
return
if(ismob(AM))
var/mob/M = AM
if(immobilize)
M.canmove = 0
affecting.Add(AM)
while(AM && !stopthrow)
if(tiles)
if(curtiles >= tiles)
break
if(AM.z != src.z)
break
curtiles++
sleep(speed)
// Calculate if we should stop the process
if(!nostop)
for(var/obj/effect/step_trigger/T in get_step(AM, direction))
if(T.stopper && T != src)
stopthrow = 1
else
for(var/obj/effect/step_trigger/teleporter/T in get_step(AM, direction))
if(T.stopper)
stopthrow = 1
if(AM)
var/predir = AM.dir
step(AM, direction)
if(!facedir)
AM.setDir(predir)
affecting.Remove(AM)
if(ismob(AM))
var/mob/M = AM
if(immobilize)
M.canmove = 1
/* Stops things thrown by a thrower, doesn't do anything */
/obj/effect/step_trigger/stopper
/* Instant teleporter */
/obj/effect/step_trigger/teleporter
var/teleport_x = 0 // teleportation coordinates (if one is null, then no teleport!)
var/teleport_y = 0
var/teleport_z = 0
/obj/effect/step_trigger/teleporter/Trigger(atom/movable/A)
if(teleport_x && teleport_y && teleport_z)
var/turf/T = locate(teleport_x, teleport_y, teleport_z)
A.forceMove(T)
/* Random teleporter, teleports atoms to locations ranging from teleport_x - teleport_x_offset, etc */
/obj/effect/step_trigger/teleporter/random
var/teleport_x_offset = 0
var/teleport_y_offset = 0
var/teleport_z_offset = 0
/obj/effect/step_trigger/teleporter/random/Trigger(atom/movable/A)
if(teleport_x && teleport_y && teleport_z)
if(teleport_x_offset && teleport_y_offset && teleport_z_offset)
var/turf/T = locate(rand(teleport_x, teleport_x_offset), rand(teleport_y, teleport_y_offset), rand(teleport_z, teleport_z_offset))
if (T)
A.forceMove(T)
/* Fancy teleporter, creates sparks and smokes when used */
/obj/effect/step_trigger/teleport_fancy
var/locationx
var/locationy
var/uses = 1 //0 for infinite uses
var/entersparks = 0
var/exitsparks = 0
var/entersmoke = 0
var/exitsmoke = 0
/obj/effect/step_trigger/teleport_fancy/Trigger(mob/M)
var/dest = locate(locationx, locationy, z)
M.Move(dest)
if(entersparks)
var/datum/effect_system/spark_spread/s = new
s.set_up(4, 1, src)
s.start()
if(exitsparks)
var/datum/effect_system/spark_spread/s = new
s.set_up(4, 1, dest)
s.start()
if(entersmoke)
var/datum/effect_system/smoke_spread/s = new
s.set_up(4, 1, src, 0)
s.start()
if(exitsmoke)
var/datum/effect_system/smoke_spread/s = new
s.set_up(4, 1, dest, 0)
s.start()
uses--
if(uses == 0)
qdel(src)
/* Simple sound player, Mapper friendly! */
/obj/effect/step_trigger/sound_effect
var/sound //eg. path to the sound, inside '' eg: 'growl.ogg'
var/volume = 100
var/freq_vary = 1 //Should the frequency of the sound vary?
var/extra_range = 0 // eg World.view = 7, extra_range = 1, 7+1 = 8, 8 turfs radius
var/happens_once = 0
var/triggerer_only = 0 //Whether the triggerer is the only person who hears this
/obj/effect/step_trigger/sound_effect/Trigger(atom/movable/A)
var/turf/T = get_turf(A)
if(!T)
return
if(triggerer_only && ismob(A))
var/mob/B = A
B.playsound_local(T, sound, volume, freq_vary)
else
playsound(T, sound, volume, freq_vary, extra_range)
if(happens_once)
qdel(src)
-4
View File
@@ -57,7 +57,6 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
var/slowdown = 0 // How much clothing is slowing you down. Negative values speeds you up
var/armour_penetration = 0 //percentage of armour effectiveness to remove
var/list/allowed = null //suit storage stuff.
var/obj/item/device/uplink/hidden_uplink = null
var/equip_delay_self = 0 //In deciseconds, how long an item takes to equip; counts only for normal clothing slots, not pockets etc.
var/equip_delay_other = 20 //In deciseconds, how long an item takes to put on another person
var/strip_delay = 40 //In deciseconds, how long an item takes to remove from another person
@@ -224,9 +223,6 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
/obj/item/interact(mob/user)
add_fingerprint(user)
if(hidden_uplink && hidden_uplink.active)
hidden_uplink.interact(user)
return 1
ui_interact(user)
/obj/item/ui_act(action, params)
+3 -3
View File
@@ -45,7 +45,7 @@
if(response_timer_id)
to_chat(user, "You're still waiting for approval from your employers about your proposed name change, it'd be best to wait for now.")
return
if(!new_name)
return
log_game("[key_name(user)] has proposed to name the station as \
@@ -85,7 +85,7 @@
name = "station charter for [station_name()]"
desc = "An official document entrusting the governance of \
[station_name()] and surrounding space to Captain [uname]."
SSblackbox.set_details("station_renames","[station_name()]")
SSblackbox.record_feedback("text", "station_renames", 1, "[station_name()]")
if(!unlimited_uses)
used = TRUE
@@ -112,7 +112,7 @@
log_game("[ukey] has renamed the planet as [station_name()].")
name = "banner of [station_name()]"
desc = "The banner bears the official coat of arms of Nanotrasen, signifying that [station_name()] has been claimed by Captain [uname] in the name of the company."
SSblackbox.set_details("station_renames","[station_name()]")
SSblackbox.record_feedback("text", "station_renames", 1, "[station_name()]")
if(!unlimited_uses)
used = TRUE
+4 -1
View File
@@ -62,7 +62,7 @@
TED = loc
else //admin must have spawned it
TED = new(src.loc)
qdel(src)
return INITIALIZE_HINT_QDEL
/obj/item/gun/energy/chrono_gun/update_icon()
return
@@ -252,6 +252,9 @@
/obj/effect/chrono_field/singularity_act()
return
/obj/effect/chrono_field/singularity_pull()
return
/obj/effect/chrono_field/ex_act()
return
@@ -6,8 +6,7 @@
/obj/item/stock_parts/matter_bin = 1,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stack/cable_coil = 1,
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1)
/obj/item/stack/sheet/glass = 2)
/obj/item/circuitboard/machine/announcement_system
name = "Announcement System (Machine Board)"
@@ -15,7 +14,7 @@
origin_tech = "programming=3;bluespace=3;magnets=2"
req_components = list(
/obj/item/stack/cable_coil = 2,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/autolathe
name = "Autolathe (Machine Board)"
@@ -24,7 +23,7 @@
req_components = list(
/obj/item/stock_parts/matter_bin = 3,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/clonepod
name = "Clone Pod (Machine Board)"
@@ -78,7 +77,7 @@
req_components = list(
/obj/item/stock_parts/manipulator = 1,
/obj/item/reagent_containers/glass/beaker = 2,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/quantumpad
name = "Quantum Pad (Machine Board)"
@@ -193,19 +192,6 @@
/obj/item/stack/cable_coil = 1,
/obj/item/stock_parts/subspace/filter = 1)
/obj/item/circuitboard/machine/exonet_node
name = "Exonet Node(machine board)"
build_path = /obj/machinery/exonet_node
origin_tech = "programming=3;engineering=4;bluespace=3;materials=3"
req_components = list(
/obj/item/stock_parts/subspace/ansible = 1,
/obj/item/stock_parts/subspace/filter = 1,
/obj/item/stock_parts/manipulator = 2,
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/subspace/crystal = 1,
/obj/item/stock_parts/subspace/treatment = 2,
/obj/item/stack/cable_coil = 2)
/obj/item/circuitboard/machine/teleporter_hub
name = "Teleporter Hub (Machine Board)"
build_path = /obj/machinery/teleport/hub
@@ -222,7 +208,7 @@
req_components = list(
/obj/item/ore/bluespace_crystal = 2,
/obj/item/stock_parts/capacitor = 2,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
def_components = list(/obj/item/ore/bluespace_crystal = /obj/item/ore/bluespace_crystal/artificial)
/obj/item/circuitboard/machine/vendor
@@ -281,7 +267,7 @@
/obj/item/stock_parts/matter_bin = 2,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/cryo_tube
name = "Cryotube (Machine Board)"
@@ -290,18 +276,17 @@
req_components = list(
/obj/item/stock_parts/matter_bin = 1,
/obj/item/stack/cable_coil = 1,
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 2)
/obj/item/stack/sheet/glass = 4)
/obj/item/circuitboard/machine/thermomachine
name = "Thermomachine (Machine Board)"
desc = "You can use a screwdriver to switch between heater and freezer."
origin_tech = "programming=3;plasmatech=3"
req_components = list(
/obj/item/stock_parts/matter_bin = 2,
/obj/item/stock_parts/micro_laser = 2,
/obj/item/stack/cable_coil = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stock_parts/matter_bin = 2,
/obj/item/stock_parts/micro_laser = 2,
/obj/item/stack/cable_coil = 1,
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/thermomachine/Initialize()
. = ..()
@@ -430,7 +415,7 @@
/obj/item/stock_parts/matter_bin = 1,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stack/cable_coil = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/plantgenes
name = "Plant DNA Manipulator (Machine Board)"
@@ -439,7 +424,7 @@
req_components = list(
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/stock_parts/scanning_module = 1)
/obj/item/circuitboard/machine/plantgenes/vault
@@ -460,7 +445,7 @@
req_components = list(
/obj/item/stock_parts/matter_bin = 2,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/seed_extractor
name = "Seed Extractor (Machine Board)"
@@ -475,7 +460,7 @@
build_path = /obj/machinery/mineral/ore_redemption
origin_tech = "programming=1;engineering=2"
req_components = list(
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/stock_parts/matter_bin = 1,
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/manipulator = 1,
@@ -486,7 +471,7 @@
build_path = /obj/machinery/mineral/equipment_vendor
origin_tech = "programming=1;engineering=3"
req_components = list(
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/stock_parts/matter_bin = 3)
/obj/item/circuitboard/machine/mining_equipment_vendor/golem
@@ -607,7 +592,7 @@
/obj/item/stock_parts/matter_bin = 2,
/obj/item/stock_parts/capacitor = 1,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/stock_parts/cell = 1)
def_components = list(/obj/item/stock_parts/cell = /obj/item/stock_parts/cell/high)
@@ -619,7 +604,7 @@
/obj/item/stock_parts/matter_bin = 2,
/obj/item/stock_parts/capacitor = 1,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/stock_parts/cell = 1)
/obj/item/circuitboard/machine/chem_heater
@@ -628,7 +613,7 @@
origin_tech = "programming=2;engineering=2;biotech=2"
req_components = list(
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/chem_master
name = "ChemMaster 3000 (Machine Board)"
@@ -637,7 +622,7 @@
req_components = list(
/obj/item/reagent_containers/glass/beaker = 2,
/obj/item/stock_parts/manipulator = 1,
/obj/item/stock_parts/console_screen = 1)
/obj/item/stack/sheet/glass = 1)
/obj/item/circuitboard/machine/chem_master/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/screwdriver))
@@ -743,13 +728,12 @@
/obj/item/stock_parts/micro_laser = 1,
/obj/item/stock_parts/matter_bin = 1,
/obj/item/stack/cable_coil = 2,
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1)
/obj/item/stack/sheet/glass = 2)
/obj/item/circuitboard/machine/vending/donksofttoyvendor
name = "Donksoft Toy Vendor (Machine Board)"
build_path = /obj/machinery/vending/donksofttoyvendor
origin_tech = "programming=1;syndicate=2"
req_components = list(
/obj/item/stock_parts/console_screen = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/vending_refill/donksoft = 3)
+1
View File
@@ -545,6 +545,7 @@
H.set_heartattack(FALSE)
H.revive()
H.emote("gasp")
H.Jitter(100)
if(tplus > tloss)
H.setBrainLoss( max(0, min(99, ((tlimit - tplus) / tlimit * 100))))
add_logs(user, H, "revived", defib)
+8 -6
View File
@@ -155,15 +155,17 @@ GLOBAL_LIST_EMPTY(PDAs)
return
/obj/item/device/pda/attack_self(mob/user)
if(!user.IsAdvancedToolUser())
to_chat(user, "<span class='warning'>You don't have the dexterity to do this!</span>")
return
. = ..()
var/datum/asset/assets = get_asset_datum(/datum/asset/simple/pda)
assets.send(user)
user.set_machine(src)
if(hidden_uplink && hidden_uplink.active)
hidden_uplink.interact(user)
return
var/dat = "<!DOCTYPE html><html><head><title>Personal Data Assistant</title><link href=\"https://fonts.googleapis.com/css?family=Orbitron|Share+Tech+Mono|VT323\" rel=\"stylesheet\"></head><body bgcolor=\"" + background_color + "\"><style>body{" + font_mode + "}ul,ol{list-style-type: none;}a, a:link, a:visited, a:active, a:hover { color: #000000;text-decoration:none; }img {border-style:none;}a img{padding-right: 9px;}</style>"
@@ -496,7 +498,9 @@ GLOBAL_LIST_EMPTY(PDAs)
if("Ringtone")
var/t = input(U, "Please enter new ringtone", name, ttone) as text
if(in_range(src, U) && loc == U && t)
GET_COMPONENT(hidden_uplink, /datum/component/uplink)
if(hidden_uplink && (trim(lowertext(t)) == trim(lowertext(lock_code))))
hidden_uplink.locked = FALSE
hidden_uplink.interact(U)
to_chat(U, "The PDA softly beeps.")
U << browse(null, "window=pda")
@@ -822,8 +826,6 @@ GLOBAL_LIST_EMPTY(PDAs)
var/obj/item/photo/P = C
photo = P.img
to_chat(user, "<span class='notice'>You scan \the [C].</span>")
else if(hidden_uplink && hidden_uplink.active)
hidden_uplink.attackby(C, user, params)
else
return ..()
@@ -7,7 +7,7 @@
/obj/item/cartridge/virus/message_header()
return "<b>[charges] viral files left.</b><HR>"
/obj/item/cartridge/virus/message_special(obj/item/device/pda/target)
if (!istype(loc, /obj/item/device/pda))
return "" //Sanity check, this shouldn't be possible.
@@ -67,11 +67,12 @@
var/difficulty = 0
if(target.cartridge)
difficulty += BitCount(target.cartridge.access&(CART_MEDICAL | CART_SECURITY | CART_ENGINE | CART_CLOWN | CART_JANITOR | CART_MANIFEST))
if(target.cartridge.access & CART_MANIFEST)
if(target.cartridge.access & CART_MANIFEST)
difficulty++ //if cartridge has manifest access it has extra snowflake difficulty
else
difficulty += 2
if(!target.detonatable || prob(difficulty * 15) || (target.hidden_uplink))
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, target)
if(!target.detonatable || prob(difficulty * 15) || (hidden_uplink))
U.show_message("<span class='danger'>An error flashes on your [src].</span>", 1)
else
U.show_message("<span class='notice'>Success!</span>", 1)
@@ -92,14 +93,14 @@
charges--
var/lock_code = "[rand(100,999)] [pick(GLOB.phonetic_alphabet)]"
to_chat(U, "<span class='notice'>Virus Sent! The unlock code to the target is: [lock_code]</span>")
if(!target.hidden_uplink)
var/obj/item/device/uplink/uplink = new(target)
target.hidden_uplink = uplink
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, target)
if(!hidden_uplink)
hidden_uplink = target.LoadComponent(/datum/component/uplink)
target.lock_code = lock_code
else
target.hidden_uplink.hidden_crystals += target.hidden_uplink.telecrystals //Temporarially hide the PDA's crystals, so you can't steal telecrystals.
target.hidden_uplink.telecrystals = telecrystals
hidden_uplink.hidden_crystals += hidden_uplink.telecrystals //Temporarially hide the PDA's crystals, so you can't steal telecrystals.
hidden_uplink.telecrystals = telecrystals
telecrystals = 0
target.hidden_uplink.active = TRUE
hidden_uplink.active = TRUE
else
to_chat(U, "PDA not found.")
@@ -102,7 +102,11 @@
appearance = saved_appearance
if(istype(M.buckled, /obj/vehicle))
var/obj/vehicle/V = M.buckled
V.riding_datum.force_dismount(M)
GET_COMPONENT_FROM(VRD, /datum/component/riding, V)
if(VRD)
VRD.force_dismount(M)
else
V.unbuckle_mob(M, force = TRUE)
M.loc = src
master = C
master.active_dummy = src
+185 -160
View File
@@ -1,165 +1,190 @@
/obj/item/device/laser_pointer
name = "laser pointer"
desc = "Don't shine it in your eyes!"
icon = 'icons/obj/device.dmi'
icon_state = "pointer"
item_state = "pen"
var/pointer_icon_state
/obj/item/device/laser_pointer
name = "laser pointer"
desc = "Don't shine it in your eyes!"
icon = 'icons/obj/device.dmi'
icon_state = "pointer"
item_state = "pen"
var/pointer_icon_state
flags_1 = CONDUCT_1 | NOBLUDGEON_1
slot_flags = SLOT_BELT
materials = list(MAT_METAL=500, MAT_GLASS=500)
w_class = WEIGHT_CLASS_SMALL
origin_tech = "combat=1;magnets=2"
var/turf/pointer_loc
var/energy = 5
var/max_energy = 5
var/effectchance = 33
var/recharging = 0
slot_flags = SLOT_BELT
materials = list(MAT_METAL=500, MAT_GLASS=500)
w_class = WEIGHT_CLASS_SMALL
origin_tech = "combat=1;magnets=2"
var/turf/pointer_loc
var/energy = 5
var/max_energy = 5
var/effectchance = 33
var/recharging = 0
var/recharge_locked = FALSE
var/obj/item/stock_parts/micro_laser/diode //used for upgrading!
/obj/item/device/laser_pointer/red
pointer_icon_state = "red_laser"
/obj/item/device/laser_pointer/green
pointer_icon_state = "green_laser"
/obj/item/device/laser_pointer/blue
pointer_icon_state = "blue_laser"
/obj/item/device/laser_pointer/purple
pointer_icon_state = "purple_laser"
/obj/item/device/laser_pointer/New()
..()
diode = new(src)
if(!pointer_icon_state)
pointer_icon_state = pick("red_laser","green_laser","blue_laser","purple_laser")
/obj/item/device/laser_pointer/upgraded/New()
..()
diode = new /obj/item/stock_parts/micro_laser/ultra
/obj/item/device/laser_pointer/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/stock_parts/micro_laser))
if(!diode)
if(!user.transferItemToLoc(W, src))
return
diode = W
to_chat(user, "<span class='notice'>You install a [diode.name] in [src].</span>")
else
to_chat(user, "<span class='notice'>[src] already has a diode installed.</span>")
else if(istype(W, /obj/item/screwdriver))
if(diode)
to_chat(user, "<span class='notice'>You remove the [diode.name] from \the [src].</span>")
diode.loc = get_turf(src.loc)
diode = null
else
return ..()
/obj/item/device/laser_pointer/afterattack(atom/target, mob/living/user, flag, params)
laser_act(target, user, params)
/obj/item/device/laser_pointer/proc/laser_act(atom/target, mob/living/user, params)
if( !(user in (viewers(7,target))) )
return
if (!diode)
to_chat(user, "<span class='notice'>You point [src] at [target], but nothing happens!</span>")
return
if (!user.IsAdvancedToolUser())
to_chat(user, "<span class='warning'>You don't have the dexterity to do this!</span>")
return
if(ishuman(user))
var/mob/living/carbon/human/H = user
if(H.dna.check_mutation(HULK) || (NOGUNS in H.dna.species.species_traits))
to_chat(user, "<span class='warning'>Your fingers can't press the button!</span>")
return
add_fingerprint(user)
//nothing happens if the battery is drained
if(recharge_locked)
to_chat(user, "<span class='notice'>You point [src] at [target], but it's still charging.</span>")
return
var/outmsg
var/turf/targloc = get_turf(target)
//human/alien mobs
if(iscarbon(target))
var/mob/living/carbon/C = target
if(user.zone_selected == "eyes")
add_logs(user, C, "shone in the eyes", src)
var/severity = 1
if(prob(33))
severity = 2
else if(prob(50))
severity = 0
//20% chance to actually hit the eyes
if(prob(effectchance * diode.rating) && C.flash_act(severity))
outmsg = "<span class='notice'>You blind [C] by shining [src] in their eyes.</span>"
else
outmsg = "<span class='warning'>You fail to blind [C] by shining [src] at their eyes!</span>"
//robots
else if(iscyborg(target))
var/mob/living/silicon/S = target
//20% chance to actually hit the sensors
if(prob(effectchance * diode.rating))
S.flash_act(affect_silicon = 1)
S.Knockdown(rand(100,200))
to_chat(S, "<span class='danger'>Your sensors were overloaded by a laser!</span>")
outmsg = "<span class='notice'>You overload [S] by shining [src] at their sensors.</span>"
add_logs(user, S, "shone in the sensors", src)
else
outmsg = "<span class='warning'>You fail to overload [S] by shining [src] at their sensors!</span>"
//cameras
else if(istype(target, /obj/machinery/camera))
var/obj/machinery/camera/C = target
if(prob(effectchance * diode.rating))
var/obj/item/stock_parts/micro_laser/diode //used for upgrading!
/obj/item/device/laser_pointer/red
pointer_icon_state = "red_laser"
/obj/item/device/laser_pointer/green
pointer_icon_state = "green_laser"
/obj/item/device/laser_pointer/blue
pointer_icon_state = "blue_laser"
/obj/item/device/laser_pointer/purple
pointer_icon_state = "purple_laser"
/obj/item/device/laser_pointer/New()
..()
diode = new(src)
if(!pointer_icon_state)
pointer_icon_state = pick("red_laser","green_laser","blue_laser","purple_laser")
/obj/item/device/laser_pointer/upgraded/New()
..()
diode = new /obj/item/stock_parts/micro_laser/ultra
/obj/item/device/laser_pointer/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/stock_parts/micro_laser))
if(!diode)
if(!user.transferItemToLoc(W, src))
return
diode = W
to_chat(user, "<span class='notice'>You install a [diode.name] in [src].</span>")
else
to_chat(user, "<span class='notice'>[src] already has a diode installed.</span>")
else if(istype(W, /obj/item/screwdriver))
if(diode)
to_chat(user, "<span class='notice'>You remove the [diode.name] from \the [src].</span>")
diode.loc = get_turf(src.loc)
diode = null
else
return ..()
/obj/item/device/laser_pointer/afterattack(atom/target, mob/living/user, flag, params)
laser_act(target, user, params)
/obj/item/device/laser_pointer/proc/laser_act(atom/target, mob/living/user, params)
if( !(user in (viewers(7,target))) )
return
if (!diode)
to_chat(user, "<span class='notice'>You point [src] at [target], but nothing happens!</span>")
return
if (!user.IsAdvancedToolUser())
to_chat(user, "<span class='warning'>You don't have the dexterity to do this!</span>")
return
if(ishuman(user))
var/mob/living/carbon/human/H = user
if(H.dna.check_mutation(HULK) || (NOGUNS in H.dna.species.species_traits))
to_chat(user, "<span class='warning'>Your fingers can't press the button!</span>")
return
add_fingerprint(user)
//nothing happens if the battery is drained
if(recharge_locked)
to_chat(user, "<span class='notice'>You point [src] at [target], but it's still charging.</span>")
return
var/outmsg
var/turf/targloc = get_turf(target)
//human/alien mobs
if(iscarbon(target))
var/mob/living/carbon/C = target
if(user.zone_selected == "eyes")
add_logs(user, C, "shone in the eyes", src)
var/severity = 1
if(prob(33))
severity = 2
else if(prob(50))
severity = 0
//chance to actually hit the eyes depends on internal component
if(prob(effectchance * diode.rating) && C.flash_act(severity))
outmsg = "<span class='notice'>You blind [C] by shining [src] in their eyes.</span>"
else
outmsg = "<span class='warning'>You fail to blind [C] by shining [src] at their eyes!</span>"
//robots
else if(iscyborg(target))
var/mob/living/silicon/S = target
add_logs(user, S, "shone in the sensors", src)
//chance to actually hit the eyes depends on internal component
if(prob(effectchance * diode.rating))
S.flash_act(affect_silicon = 1)
S.Knockdown(rand(100,200))
to_chat(S, "<span class='danger'>Your sensors were overloaded by a laser!</span>")
outmsg = "<span class='notice'>You overload [S] by shining [src] at their sensors.</span>"
else
outmsg = "<span class='warning'>You fail to overload [S] by shining [src] at their sensors!</span>"
//cameras
else if(istype(target, /obj/machinery/camera))
var/obj/machinery/camera/C = target
if(prob(effectchance * diode.rating))
C.emp_act(EMP_HEAVY)
outmsg = "<span class='notice'>You hit the lens of [C] with [src], temporarily disabling the camera!</span>"
add_logs(user, C, "EMPed", src)
else
outmsg = "<span class='warning'>You miss the lens of [C] with [src]!</span>"
//laser pointer image
icon_state = "pointer_[pointer_icon_state]"
var/image/I = image('icons/obj/projectiles.dmi',targloc,pointer_icon_state,10)
var/list/click_params = params2list(params)
if(click_params)
if(click_params["icon-x"])
I.pixel_x = (text2num(click_params["icon-x"]) - 16)
if(click_params["icon-y"])
I.pixel_y = (text2num(click_params["icon-y"]) - 16)
else
I.pixel_x = target.pixel_x + rand(-5,5)
I.pixel_y = target.pixel_y + rand(-5,5)
if(outmsg)
to_chat(user, outmsg)
else
to_chat(user, "<span class='info'>You point [src] at [target].</span>")
energy -= 1
if(energy <= max_energy)
if(!recharging)
recharging = 1
START_PROCESSING(SSobj, src)
if(energy <= 0)
to_chat(user, "<span class='warning'>[src]'s battery is overused, it needs time to recharge!</span>")
outmsg = "<span class='notice'>You hit the lens of [C] with [src], temporarily disabling the camera!</span>"
add_logs(user, C, "EMPed", src)
else
outmsg = "<span class='warning'>You miss the lens of [C] with [src]!</span>"
//catpeople
for(var/mob/living/carbon/human/H in view(1,targloc))
if(!iscatperson(H) || H.incapacitated() || H.eye_blind )
continue
if(!H.lying)
H.setDir(get_dir(H,targloc)) // kitty always looks at the light
if(prob(effectchance))
H.visible_message("<span class='warning'>[H] makes a grab for the light!</span>","<span class='userdanger'>LIGHT!</span>")
H.Move(targloc)
add_logs(user, H, "moved with a laser pointer",src)
else
H.visible_message("<span class='notice'>[H] looks briefly distracted by the light.</span>","<span class = 'warning'> You're briefly tempted by the shiny light... </span>")
else
H.visible_message("<span class='notice'>[H] stares at the light</span>","<span class = 'warning'> You stare at the light... </span>")
//cats!
for(var/mob/living/simple_animal/pet/cat/C in view(1,targloc))
if(prob(50))
C.visible_message("<span class='notice'>[C] pounces on the light!</span>","<span class='warning'>LIGHT!</span>")
C.Move(targloc)
C.resting = TRUE
C.update_canmove()
else
C.visible_message("<span class='notice'>[C] looks uninterested in your games.</span>","<span class='warning'>You spot [user] shining [src] at you. How insulting!</span>")
//laser pointer image
icon_state = "pointer_[pointer_icon_state]"
var/image/I = image('icons/obj/projectiles.dmi',targloc,pointer_icon_state,10)
var/list/click_params = params2list(params)
if(click_params)
if(click_params["icon-x"])
I.pixel_x = (text2num(click_params["icon-x"]) - 16)
if(click_params["icon-y"])
I.pixel_y = (text2num(click_params["icon-y"]) - 16)
else
I.pixel_x = target.pixel_x + rand(-5,5)
I.pixel_y = target.pixel_y + rand(-5,5)
if(outmsg)
to_chat(user, outmsg)
else
to_chat(user, "<span class='info'>You point [src] at [target].</span>")
energy -= 1
if(energy <= max_energy)
if(!recharging)
recharging = 1
START_PROCESSING(SSobj, src)
if(energy <= 0)
to_chat(user, "<span class='warning'>[src]'s battery is overused, it needs time to recharge!</span>")
recharge_locked = TRUE
flick_overlay_view(I, targloc, 10)
icon_state = "pointer"
/obj/item/device/laser_pointer/process()
if(prob(20 - recharge_locked*5))
energy += 1
if(energy >= max_energy)
energy = max_energy
recharging = 0
flick_overlay_view(I, targloc, 10)
icon_state = "pointer"
/obj/item/device/laser_pointer/process()
if(prob(20 - recharge_locked*5))
energy += 1
if(energy >= max_energy)
energy = max_energy
recharging = 0
recharge_locked = FALSE
..()
..()
+3 -4
View File
@@ -59,8 +59,7 @@
if(io.holder.assembly && io.holder.assembly != selected_io.holder.assembly)
to_chat(user, "<span class='warning'>Both \the [io.holder] and \the [selected_io.holder] need to be inside the same assembly.</span>")
return
selected_io.linked |= io
io.linked |= selected_io
io.connect_pin(selected_io)
to_chat(user, "<span class='notice'>You connect \the [selected_io.holder]'s [selected_io.name] to \the [io.holder]'s [io.name].</span>")
selected_io.holder.interact(user) // This is to update the UI.
@@ -82,8 +81,7 @@
to_chat(user, "<span class='warning'>These data pins aren't connected!</span>")
return
else
io1.linked.Remove(io2)
io2.linked.Remove(io1)
io1.disconnect_pin(io2)
to_chat(user, "<span class='notice'>You clip the data connection between the [io1.holder.displayed_name]'s \
[io1.name] and the [io2.holder.displayed_name]'s [io2.name].</span>")
io1.holder.interact(user) // This is to update the UI.
@@ -164,3 +162,4 @@
icon_state = "multitool"
toolspeed = 0.1
origin_tech = "magnets=5;engineering=5;abductor=3"
toolspeed = 0.1
@@ -155,7 +155,9 @@
if(.)
frequency = sanitize_frequency(tune, freerange)
set_frequency(frequency)
if(frequency == traitor_frequency && hidden_uplink)
GET_COMPONENT(hidden_uplink, /datum/component/uplink)
if(hidden_uplink && (frequency == traitor_frequency))
hidden_uplink.locked = FALSE
hidden_uplink.interact(usr)
ui.close()
if("listen")
@@ -2,10 +2,8 @@
/*
CONTAINS:
T-RAY
DETECTIVE SCANNER
HEALTH ANALYZER
GAS ANALYZER
MASS SPECTROMETER
*/
/obj/item/device/t_scanner
@@ -394,70 +392,6 @@ MASS SPECTROMETER
to_chat(user, "<span class='alert'>[env_gases[id][GAS_META][META_GAS_NAME]]: [round(gas_concentration*100, 0.01)] %</span>")
to_chat(user, "<span class='info'>Temperature: [round(environment.temperature-T0C)] &deg;C</span>")
/obj/item/device/mass_spectrometer
desc = "A hand-held mass spectrometer which identifies trace chemicals in a blood sample."
name = "mass-spectrometer"
icon_state = "spectrometer"
item_state = "analyzer"
lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi'
w_class = WEIGHT_CLASS_SMALL
flags_1 = CONDUCT_1
slot_flags = SLOT_BELT
container_type = OPENCONTAINER_1
throwforce = 0
throw_speed = 3
throw_range = 7
materials = list(MAT_METAL=150, MAT_GLASS=100)
origin_tech = "magnets=2;biotech=1;plasmatech=2"
var/details = 0
/obj/item/device/mass_spectrometer/New()
..()
create_reagents(5)
/obj/item/device/mass_spectrometer/on_reagent_change()
if(reagents.total_volume)
icon_state = initial(icon_state) + "_s"
else
icon_state = initial(icon_state)
/obj/item/device/mass_spectrometer/attack_self(mob/user)
if (user.stat || user.eye_blind)
return
if (!user.IsAdvancedToolUser())
to_chat(user, "<span class='warning'>You don't have the dexterity to do this!</span>")
return
if(reagents.total_volume)
var/list/blood_traces = list()
for(var/datum/reagent/R in reagents.reagent_list)
if(R.id != "blood")
reagents.clear_reagents()
to_chat(user, "<span class='warning'>The sample was contaminated! Please insert another sample.</span>")
return
else
blood_traces = params2list(R.data["trace_chem"])
break
var/dat = "<i><b>Trace Chemicals Found:</b>"
if(!blood_traces.len)
dat += "<br>None"
else
for(var/R in blood_traces)
dat += "<br>[GLOB.chemical_reagents_list[R]]"
if(details)
dat += " ([blood_traces[R]] units)"
dat += "</i>"
to_chat(user, dat)
reagents.clear_reagents()
/obj/item/device/mass_spectrometer/adv
name = "advanced mass-spectrometer"
icon_state = "adv_spectrometer"
details = 1
origin_tech = "magnets=4;biotech=3;plasmatech=3"
/obj/item/device/slime_scanner
name = "slime scanner"
desc = "A device that analyzes a slime's internal composition and measures its stats."
@@ -0,0 +1,31 @@
// A collection of pre-set uplinks, for admin spawns.
/obj/item/device/radio/uplink/Initialize(mapload, _owner, _tc_amount = 20)
. = ..()
icon_state = "radio"
lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi'
righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi'
LoadComponent(/datum/component/uplink, _owner, FALSE, TRUE, null, _tc_amount)
/obj/item/device/radio/uplink/nuclear/Initialize()
. = ..()
GET_COMPONENT(hidden_uplink, /datum/component/uplink)
hidden_uplink.set_gamemode(/datum/game_mode/nuclear)
/obj/item/device/multitool/uplink/Initialize(mapload, _owner, _tc_amount = 20)
. = ..()
LoadComponent(/datum/component/uplink, _owner, FALSE, TRUE, null, _tc_amount)
/obj/item/pen/uplink/Initialize(mapload, _owner, _tc_amount = 20)
. = ..()
LoadComponent(/datum/component/uplink)
traitor_unlock_degrees = 360
/obj/item/device/radio/uplink/old
name = "dusty radio"
desc = "A dusty looking radio."
/obj/item/device/radio/uplink/old/Initialize(mapload, _owner, _tc_amount = 10)
. = ..()
GET_COMPONENT(hidden_uplink, /datum/component/uplink)
hidden_uplink.name = "dusty radio"
+3 -3
View File
@@ -47,7 +47,7 @@
if(do_mob(user, C, 30) && (C.get_num_arms() >= 2 || C.get_arm_ignore()))
apply_cuffs(C,user)
to_chat(user, "<span class='notice'>You handcuff [C].</span>")
SSblackbox.add_details("handcuffs","[type]")
SSblackbox.record_feedback("tally", "handcuffs", 1, type)
add_logs(user, C, "handcuffed")
else
@@ -298,7 +298,7 @@
C.legcuffed = src
src.loc = C
C.update_inv_legcuffed()
SSblackbox.add_details("handcuffs","[type]")
SSblackbox.record_feedback("tally", "handcuffs", 1, type)
else if(isanimal(L))
var/mob/living/simple_animal/SA = L
if(SA.mob_size > MOB_SIZE_TINY)
@@ -359,7 +359,7 @@
C.legcuffed = src
src.loc = C
C.update_inv_legcuffed()
SSblackbox.add_details("handcuffs","[type]")
SSblackbox.record_feedback("tally", "handcuffs", 1, type)
to_chat(C, "<span class='userdanger'>\The [src] ensnares you!</span>")
C.Knockdown(knockdown)
+1 -1
View File
@@ -42,7 +42,7 @@
SSreligion.holy_weapon_type = holy_weapon.type
SSblackbox.set_details("chaplain_weapon","[choice]")
SSblackbox.record_feedback("tally", "chaplain_weapon", 1, "[choice]")
if(holy_weapon)
holy_weapon.reskinned = TRUE
@@ -5,28 +5,34 @@
icon_state = "radio"
lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi'
righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi'
origin_tech = "materials=4;magnets=4;programming=4;biotech=4;syndicate=5;bluespace=5"
var/starting_tc = 0
/obj/item/implant/uplink/New()
hidden_uplink = new(src)
hidden_uplink.telecrystals = starting_tc
..()
/obj/item/implant/uplink/Initialize(mapload, _owner)
. = ..()
LoadComponent(/datum/component/uplink, _owner, TRUE, FALSE, null, starting_tc)
/obj/item/implant/uplink/implant(mob/living/target, mob/user, silent = 0)
for(var/X in target.implants)
if(istype(X, type))
var/obj/item/implant/imp_e = X
imp_e.hidden_uplink.telecrystals += hidden_uplink.telecrystals
qdel(src)
return 1
GET_COMPONENT(hidden_uplink, /datum/component/uplink)
if(hidden_uplink)
for(var/X in target.implants)
if(istype(X, type))
var/obj/item/implant/imp_e = X
GET_COMPONENT_FROM(their_hidden_uplink, /datum/component/uplink, imp_e)
if(their_hidden_uplink)
their_hidden_uplink.telecrystals += hidden_uplink.telecrystals
qdel(src)
return TRUE
else
qdel(imp_e) //INFERIOR AND EMPTY!
if(..())
hidden_uplink.owner = "[user.key]"
return 1
return 0
if(hidden_uplink)
hidden_uplink.owner = "[user.key]"
return TRUE
return FALSE
/obj/item/implant/uplink/activate()
GET_COMPONENT(hidden_uplink, /datum/component/uplink)
if(hidden_uplink)
hidden_uplink.interact(usr)
+296 -2
View File
@@ -9,13 +9,91 @@
var/list/squeak_override //Weighted list; If you want your plush to have different squeak sounds use this
var/stuffed = TRUE //If the plushie has stuffing in it
var/obj/item/grenade/grenade //You can remove the stuffing from a plushie and add a grenade to it for *nefarious uses*
//--love ~<3--
gender = NEUTER
var/obj/item/toy/plush/lover
var/obj/item/toy/plush/partner
var/obj/item/toy/plush/plush_child
var/obj/item/toy/plush/paternal_parent //who initiated creation
var/obj/item/toy/plush/maternal_parent //who owns, see love()
var/list/scorned = list() //who the plush hates
var/list/scorned_by = list() //who hates the plush, to remove external references on Destroy()
var/heartbroken = FALSE
var/vowbroken = FALSE
var/young = FALSE
var/mood_message
var/list/love_message
var/list/partner_message
var/list/heartbroken_message
var/list/vowbroken_message
var/list/parent_message
var/normal_desc
//--end of love :'(--
/obj/item/toy/plush/Initialize()
. = ..()
AddComponent(/datum/component/squeak, squeak_override)
//have we decided if Pinocchio goes in the blue or pink aisle yet?
if(gender == NEUTER)
if(prob(50))
gender = FEMALE
else
gender = MALE
love_message = list("\n[src] is so happy, \he could rip a seam!")
partner_message = list("\n[src] has a ring on \his finger! It says bound to my dear [partner].")
heartbroken_message = list("\n[src] looks so sad.")
vowbroken_message = list("\n[src] lost \his ring...")
parent_message = list("\n[src] can't remember what sleep is.")
normal_desc = desc
/obj/item/toy/plush/Destroy()
QDEL_NULL(grenade)
//inform next of kin and... acquaintances
if(partner)
partner.bad_news(src)
partner = null
lover = null
else if(lover)
lover.bad_news(src)
lover = null
if(paternal_parent)
paternal_parent.bad_news(src)
paternal_parent = null
if(maternal_parent)
maternal_parent.bad_news(src)
maternal_parent = null
if(plush_child)
plush_child.bad_news(src)
plush_child = null
var/i
var/obj/item/toy/plush/P
for(i=1, i<=scorned.len, i++)
P = scorned[i]
P.bad_news(src)
scorned = null
for(i=1, i<=scorned_by.len, i++)
P = scorned_by[i]
P.bad_news(src)
scorned_by = null
//null remaining lists
squeak_override = null
love_message = null
partner_message = null
heartbroken_message = null
vowbroken_message = null
parent_message = null
return ..()
/obj/item/toy/plush/handle_atom_del(atom/A)
@@ -66,8 +144,221 @@
var/turf/T = get_turf(user)
log_game("[key_name(user)] added a grenade ([I.name]) to [src] at [COORD(T)].")
return
if(istype(I, /obj/item/toy/plush))
love(I, user)
return
return ..()
/obj/item/toy/plush/proc/love(obj/item/toy/plush/Kisser, mob/living/user) //~<3
var/chance = 100 //to steal a kiss, surely there's a 100% chance no-one would reject a plush such as I?
var/concern = 20 //perhaps something might cloud true love with doubt
var/loyalty = 30 //why should another get between us?
var/duty = 50 //conquering another's is what I live for
//we are not catholic
if(young == TRUE || Kisser.young == TRUE)
user.show_message("<span class='notice'>[src] plays tag with [Kisser].</span>", 1,
"<span class='notice'>They're happy.</span>", 0)
Kisser.cheer_up()
cheer_up()
//never again
else if(Kisser in scorned)
//message, visible, alternate message, neither visible nor audible
user.show_message("<span class='notice'>[src] rejects the advances of [Kisser]!</span>", 1,
"<span class='notice'>That didn't feel like it worked.</span>", 0)
else if(src in Kisser.scorned)
user.show_message("<span class='notice'>[Kisser] realises who [src] is and turns away.</span>", 1,
"<span class='notice'>That didn't feel like it worked.</span>", 0)
//first comes love
else if(Kisser.lover != src && Kisser.partner != src) //cannot be lovers or married
if(Kisser.lover) //if the initiator has a lover
Kisser.lover.heartbreak(Kisser) //the old lover can get over the kiss-and-run whilst the kisser has some fun
chance -= concern //one heart already broken, what does another mean?
if(lover) //if the recipient has a lover
chance -= loyalty //mustn't... but those lips
if(partner) //if the recipient has a partner
chance -= duty //do we mate for life?
if(prob(chance)) //did we bag a date?
user.visible_message("<span class='notice'>[user] makes [Kisser] kiss [src]!</span>",
"<span class='notice'>You make [Kisser] kiss [src]!</span>")
if(lover) //who cares for the past, we live in the present
lover.heartbreak(src)
new_lover(Kisser)
Kisser.new_lover(src)
else
user.show_message("<span class='notice'>[src] rejects the advances of [Kisser], maybe next time?</span>", 1,
"<span class='notice'>That didn't feel like it worked, this time.</span>", 0)
//then comes marriage
else if(Kisser.lover == src && Kisser.partner != src) //need to be lovers (assumes loving is a two way street) but not married (also assumes similar)
user.visible_message("<span class='notice'>[user] pronounces [Kisser] and [src] married! D'aw.</span>",
"<span class='notice'>You pronounce [Kisser] and [src] married!</span>")
new_partner(Kisser)
Kisser.new_partner(src)
//then comes a baby in a baby's carriage, or an adoption in an adoption's orphanage
else if(Kisser.partner == src && !plush_child) //the one advancing does not take ownership of the child and we have a one child policy in the toyshop
user.visible_message("<span class='notice'>[user] is going to break [Kisser] and [src] by bashing them like that.</span>",
"<span class='notice'>[Kisser] passionately embraces [src] in your hands. Look away you perv!</span>")
plop(Kisser)
user.visible_message("<span class='notice'>Something drops at the feet of [user].</span>",
"<span class='notice'>The miracle of oh god did that just come out of [src]?!</span>")
//then comes protection, or abstinence if we are catholic
else if(Kisser.partner == src && plush_child)
user.visible_message("<span class='notice'>[user] makes [Kisser] nuzzle [src]!</span>",
"<span class='notice'>You make [Kisser] nuzzle [src]!</span>")
//then oh fuck something unexpected happened
else
user.show_message("<span class='warning'>[Kisser] and [src] don't know what to do with one another.</span>", 0)
/obj/item/toy/plush/proc/heartbreak(obj/item/toy/plush/Brutus)
if(lover != Brutus)
to_chat(world, "lover != Brutus")
return //why are we considering someone we don't love?
scorned.Add(Brutus)
Brutus.scorned_by(src)
lover = null
Brutus.lover = null //feeling's mutual
heartbroken = TRUE
mood_message = pick(heartbroken_message)
if(partner == Brutus) //oh dear...
partner = null
Brutus.partner = null //it'd be weird otherwise
vowbroken = TRUE
mood_message = pick(vowbroken_message)
update_desc()
/obj/item/toy/plush/proc/scorned_by(obj/item/toy/plush/Outmoded)
scorned_by.Add(Outmoded)
/obj/item/toy/plush/proc/new_lover(obj/item/toy/plush/Juliet)
if(lover == Juliet)
return //nice try
lover = Juliet
cheer_up()
lover.cheer_up()
mood_message = pick(love_message)
update_desc()
if(partner) //who?
partner = null //more like who cares
/obj/item/toy/plush/proc/new_partner(obj/item/toy/plush/Apple_of_my_eye)
if(partner == Apple_of_my_eye)
return //double marriage is just insecurity
if(lover != Apple_of_my_eye)
return //union not born out of love will falter
partner = Apple_of_my_eye
heal_memories()
partner.heal_memories()
mood_message = pick(partner_message)
update_desc()
/obj/item/toy/plush/proc/plop(obj/item/toy/plush/Daddy)
if(partner != Daddy)
return //we do not have bastards in our toyshop
if(prob(50)) //it has my eyes
plush_child = new type(get_turf(loc))
else //it has your eyes
plush_child = new Daddy.type(get_turf(loc))
plush_child.make_young(src, Daddy)
/obj/item/toy/plush/proc/make_young(obj/item/toy/plush/Mama, obj/item/toy/plush/Dada)
if(Mama == Dada)
return //cloning is reserved for plants and spacemen
maternal_parent = Mama
paternal_parent = Dada
young = TRUE
name = "[Mama] Jr" //Icelandic naming convention pending
normal_desc = "[src] is a little baby of [maternal_parent] and [paternal_parent]!" //original desc won't be used so the child can have moods
update_desc()
Mama.mood_message = pick(Mama.parent_message)
Mama.update_desc()
Dada.mood_message = pick(Dada.parent_message)
Dada.update_desc()
/obj/item/toy/plush/proc/bad_news(obj/item/toy/plush/Deceased) //cotton to cotton, sawdust to sawdust
var/is_that_letter_for_me = FALSE
if(partner == Deceased) //covers marriage
is_that_letter_for_me = TRUE
partner = null
lover = null
else if(lover == Deceased) //covers lovers
is_that_letter_for_me = TRUE
lover = null
//covers children
if(maternal_parent == Deceased)
is_that_letter_for_me = TRUE
maternal_parent = null
if(paternal_parent == Deceased)
is_that_letter_for_me = TRUE
paternal_parent = null
//covers parents
if(plush_child == Deceased)
is_that_letter_for_me = TRUE
plush_child = null
//covers bad memories
if(Deceased in scorned)
scorned.Remove(Deceased)
cheer_up() //what cold button eyes you have
if(Deceased in scorned_by)
scorned_by.Remove(Deceased)
//all references to the departed should be cleaned up by now
if(is_that_letter_for_me)
heartbroken = TRUE
mood_message = pick(heartbroken_message)
update_desc()
/obj/item/toy/plush/proc/cheer_up() //it'll be all right
if(!heartbroken)
return //you cannot make smile what is already
if(vowbroken)
return //it's a pretty big deal
heartbroken = !heartbroken
if(mood_message in heartbroken_message)
mood_message = null
update_desc()
/obj/item/toy/plush/proc/heal_memories() //time fixes all wounds
if(!vowbroken)
vowbroken = !vowbroken
if(mood_message in vowbroken_message)
mood_message = null
cheer_up()
/obj/item/toy/plush/proc/update_desc()
desc = normal_desc
if(mood_message)
desc += mood_message
/obj/item/toy/plush/carpplushie
name = "space carp plushie"
desc = "An adorable stuffed toy that resembles a space carp."
@@ -88,6 +379,7 @@
desc = "An adorable plushie of the clockwork justiciar himself with new and improved spring arm action."
icon_state = "plushvar"
var/obj/item/toy/plush/narplush/clash_target
gender = MALE //he's a boy, right?
/obj/item/toy/plush/plushvar/Moved()
. = ..()
@@ -173,6 +465,7 @@
desc = "A small stuffed doll of the elder god nar'sie. Who thought this was a good children's toy?"
icon_state = "narplush"
var/clashing
gender = FEMALE //it's canon if the toy is
/obj/item/toy/plush/narplush/Moved()
. = ..()
@@ -198,7 +491,7 @@
/obj/item/toy/plush/nukeplushie
name = "operative plushie"
desc = "An stuffed toy that resembles a syndicate nuclear operative. The tag claims operatives to be purely fictitious."
desc = "A stuffed toy that resembles a syndicate nuclear operative. The tag claims operatives to be purely fictitious."
icon_state = "plushie_nuke"
item_state = "plushie_nuke"
attack_verb = list("shot", "nuked", "detonated")
@@ -210,4 +503,5 @@
icon_state = "plushie_slime"
item_state = "plushie_slime"
attack_verb = list("blorbled", "slimed", "absorbed")
squeak_override = list('sound/effects/blobattack.ogg' = 1)
squeak_override = list('sound/effects/blobattack.ogg' = 1)
gender = FEMALE //given all the jokes and drawings, I'm not sure the xenobiologists would make a slimeboy
+2 -5
View File
@@ -58,7 +58,7 @@
if(src.l_arm && src.r_arm)
if(src.l_leg && src.r_leg)
if(src.chest && src.head)
SSblackbox.inc("cyborg_frames_built",1)
SSblackbox.record_feedback("amount", "cyborg_frames_built", 1)
return 1
return 0
@@ -234,9 +234,7 @@
qdel(O.mmi)
O.mmi = W //and give the real mmi to the borg.
O.updatename()
SSblackbox.inc("cyborg_birth",1)
SSblackbox.record_feedback("amount", "cyborg_birth", 1)
forceMove(O)
O.robot_suit = src
@@ -335,4 +333,3 @@
add_fingerprint(usr)
Interact(usr)
@@ -18,14 +18,24 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \
new/datum/stack_recipe("stool", /obj/structure/chair/stool, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("bar stool", /obj/structure/chair/stool/bar, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("chair", /obj/structure/chair, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("swivel chair", /obj/structure/chair/office/dark, 5, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("comfy chair", /obj/structure/chair/comfy/beige, 2, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("bed", /obj/structure/bed, 2, one_per_turf = TRUE, on_floor = TRUE), \
new /datum/stack_recipe("sofa (middle)", /obj/structure/chair/sofa, one_per_turf = TRUE, on_floor = TRUE), \
new /datum/stack_recipe("sofa (left)", /obj/structure/chair/sofa/left, one_per_turf = TRUE, on_floor = TRUE), \
new /datum/stack_recipe("sofa (right)", /obj/structure/chair/sofa/right, one_per_turf = TRUE, on_floor = TRUE), \
new /datum/stack_recipe("sofa (corner)", /obj/structure/chair/sofa/corner, one_per_turf = TRUE, on_floor = TRUE), \
null, \
new/datum/stack_recipe_list("office chairs", list( \
new/datum/stack_recipe("dark office chair", /obj/structure/chair/office/dark, 5, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("light office chair", /obj/structure/chair/office/light, 5, one_per_turf = TRUE, on_floor = TRUE), \
)), \
new/datum/stack_recipe_list("comfy chairs", list( \
new/datum/stack_recipe("beige comfy chair", /obj/structure/chair/comfy/beige, 2, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("black comfy chair", /obj/structure/chair/comfy/black, 2, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("brown comfy chair", /obj/structure/chair/comfy/brown, 2, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("lime comfy chair", /obj/structure/chair/comfy/lime, 2, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("teal comfy chair", /obj/structure/chair/comfy/teal, 2, one_per_turf = TRUE, on_floor = TRUE), \
)), \
null, \
new/datum/stack_recipe("rack parts", /obj/item/rack_parts), \
new/datum/stack_recipe("closet", /obj/structure/closet, 2, time = 15, one_per_turf = TRUE, on_floor = TRUE), \
null, \
@@ -246,6 +256,8 @@ GLOBAL_LIST_INIT(cardboard_recipes, list ( \
icon_state = "sheet-card"
origin_tech = "materials=1"
resistance_flags = FLAMMABLE
force = 0
throwforce = 0
merge_type = /obj/item/stack/sheet/cardboard
novariants = TRUE
+64 -37
View File
@@ -1,7 +1,8 @@
/* Stack type objects!
* Contains:
* Stacks
* Recipe datum
* Recipe datum
* Recipe list datum
*/
/*
@@ -88,58 +89,76 @@
/obj/item/stack/attack_self(mob/user)
interact(user)
/obj/item/stack/interact(mob/user)
/obj/item/stack/interact(mob/user, recipes_sublist)
if (!recipes)
return
if (!src || get_amount() <= 0)
user << browse(null, "window=stack")
return
user.set_machine(src) //for correct work of onclose
var/t1 = text("<HTML><HEAD><title>Constructions from []</title></HEAD><body><TT>Amount Left: []<br>", src, get_amount())
for(var/i=1;i<=recipes.len,i++)
var/datum/stack_recipe/R = recipes[i]
if (isnull(R))
var/list/recipe_list = recipes
if (recipes_sublist && recipe_list[recipes_sublist] && istype(recipe_list[recipes_sublist], /datum/stack_recipe_list))
var/datum/stack_recipe_list/srl = recipe_list[recipes_sublist]
recipe_list = srl.recipes
var/t1 = "Amount Left: [amount]<br>"
for(var/i in 1 to length(recipe_list))
var/E = recipe_list[i]
if (isnull(E))
t1 += "<hr>"
continue
if (i>1 && !isnull(recipes[i-1]))
if (i>1 && !isnull(recipe_list[i-1]))
t1+="<br>"
var/max_multiplier = round(get_amount() / R.req_amount)
var/title as text
var/can_build = 1
can_build = can_build && (max_multiplier>0)
if (R.res_amount>1)
title+= "[R.res_amount]x [R.title]\s"
else
title+= "[R.title]"
title+= " ([R.req_amount] [singular_name]\s)"
if (can_build)
t1 += text("<A href='?src=[REF(src)];make=[];multiplier=1'>[]</A> ", i, title)
else
t1 += text("[]", title)
continue
if (R.max_res_amount>1 && max_multiplier>1)
max_multiplier = min(max_multiplier, round(R.max_res_amount/R.res_amount))
t1 += " |"
var/list/multipliers = list(5,10,25)
for (var/n in multipliers)
if (max_multiplier>=n)
t1 += " <A href='?src=[REF(src)];make=[i];multiplier=[n]'>[n*R.res_amount]x</A>"
if (!(max_multiplier in multipliers))
t1 += " <A href='?src=[REF(src)];make=[i];multiplier=[max_multiplier]'>[max_multiplier*R.res_amount]x</A>"
t1 += "</TT></body></HTML>"
user << browse(t1, "window=stack")
if (istype(E, /datum/stack_recipe_list))
var/datum/stack_recipe_list/srl = E
t1 += "<a href='?src=\ref[src];sublist=[i]'>[srl.title]</a>"
if (istype(E, /datum/stack_recipe))
var/datum/stack_recipe/R = E
var/max_multiplier = round(get_amount() / R.req_amount)
var/title as text
var/can_build = 1
can_build = can_build && (max_multiplier>0)
if (R.res_amount>1)
title+= "[R.res_amount]x [R.title]\s"
else
title+= "[R.title]"
title+= " ([R.req_amount] [singular_name]\s)"
if (can_build)
t1 += text("<A href='?src=\ref[src];sublist=[recipes_sublist];make=[i];multiplier=1'>[title]</A> ")
else
t1 += text("[]", title)
continue
if (R.max_res_amount>1 && max_multiplier>1)
max_multiplier = min(max_multiplier, round(R.max_res_amount/R.res_amount))
t1 += " |"
var/list/multipliers = list(5,10,25)
for (var/n in multipliers)
if (max_multiplier>=n)
t1 += " <A href='?src=\ref[src];make=[i];multiplier=[n]'>[n*R.res_amount]x</A>"
if (!(max_multiplier in multipliers))
t1 += " <A href='?src=\ref[src];make=[i];multiplier=[max_multiplier]'>[max_multiplier*R.res_amount]x</A>"
var/datum/browser/popup = new(user, "stack", name, 400, 400)
popup.set_content(t1)
popup.open(0)
onclose(user, "stack")
/obj/item/stack/Topic(href, href_list)
..()
if (usr.restrained() || usr.stat || usr.get_active_held_item() != src)
return
if (href_list["sublist"] && !href_list["make"])
interact(usr, text2num(href_list["sublist"]))
if (href_list["make"])
if (get_amount() < 1)
qdel(src) //Never should happen
var/datum/stack_recipe/R = recipes[text2num(href_list["make"])]
var/list/recipes_list = recipes
if (href_list["sublist"])
var/datum/stack_recipe_list/srl = recipes_list[text2num(href_list["sublist"])]
recipes_list = srl.recipes
var/datum/stack_recipe/R = recipes_list[text2num(href_list["make"])]
var/multiplier = text2num(href_list["multiplier"])
if (!multiplier ||(multiplier <= 0)) //href protection
return
@@ -187,9 +206,6 @@
qdel(I)
//BubbleWrap END
if (src && usr.machine==src) //do not reopen closed window
addtimer(CALLBACK(src, /atom/.proc/interact, usr), 0)
/obj/item/stack/proc/building_checks(datum/stack_recipe/R, multiplier)
if (get_amount() < R.req_amount*multiplier)
if (R.req_amount*multiplier>1)
@@ -345,3 +361,14 @@
src.one_per_turf = one_per_turf
src.on_floor = on_floor
src.window_checks = window_checks
/*
* Recipe list datum
*/
/datum/stack_recipe_list
var/title = "ERROR"
var/list/recipes
/datum/stack_recipe_list/New(title, recipes)
src.title = title
src.recipes = recipes
+10 -10
View File
@@ -13,18 +13,16 @@
if(target == user) //You can't go around smacking people with crystals to find out if they have an uplink or not.
for(var/obj/item/implant/uplink/I in target)
if(I && I.imp_in)
I.hidden_uplink.telecrystals += amount
use(amount)
to_chat(user, "<span class='notice'>You press [src] onto yourself and charge your hidden uplink.</span>")
GET_COMPONENT_FROM(hidden_uplink, /datum/component/uplink, I)
if(hidden_uplink)
hidden_uplink.telecrystals += amount
use(amount)
to_chat(user, "<span class='notice'>You press [src] onto yourself and charge your hidden uplink.</span>")
else
return ..()
/obj/item/stack/telecrystal/afterattack(obj/item/I, mob/user, proximity)
if(!proximity)
return
if(isitem(I) && I.hidden_uplink && I.hidden_uplink.active) //No metagaming by using this on every PDA around just to see if it gets used up.
I.hidden_uplink.telecrystals += amount
use(amount)
to_chat(user, "<span class='notice'>You slot [src] into [I] and charge its internal uplink.</span>")
else if(istype(I, /obj/item/cartridge/virus/frame))
if(istype(I, /obj/item/cartridge/virus/frame))
var/obj/item/cartridge/virus/frame/cart = I
if(!cart.charges)
to_chat(user, "<span class='notice'>[cart] is out of charges, it's refusing to accept [src].</span>")
@@ -32,6 +30,8 @@
cart.telecrystals += amount
use(amount)
to_chat(user, "<span class='notice'>You slot [src] into [cart]. The next time it's used, it will also give telecrystals.</span>")
else
return ..()
/obj/item/stack/telecrystal/five
amount = 5
+6 -1
View File
@@ -70,8 +70,13 @@
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, 0)
return 0
/obj/item/storage/backpack/holding/handle_item_insertion(obj/item/W, prevent_warning = 0, mob/user)
/obj/item/storage/backpack/holding/handle_item_insertion(obj/item/W, prevent_warning = 0, mob/living/user)
if((istype(W, /obj/item/storage/backpack/holding) || count_by_type(W.GetAllContents(), /obj/item/storage/backpack/holding)))
var/turf/loccheck = get_turf(src)
if(loccheck.z == ZLEVEL_CITYOFCOGS)
user.visible_message("<span class='warning'>An unseen force knocks [user] to the ground!</span>", "<span class='big_brass'>\"I think not!\"</span>")
user.Knockdown(60)
return
var/safety = alert(user, "Doing this will have extremely dire consequences for the station and its crew. Be sure you know what you're doing.", "Put in [name]?", "Proceed", "Abort")
if(safety == "Abort" || !in_range(src, user) || !src || !W || user.incapacitated())
return
+1
View File
@@ -37,6 +37,7 @@
/obj/item/stack/cable_coil,
/obj/item/device/t_scanner,
/obj/item/device/analyzer,
/obj/item/device/geiger_counter,
/obj/item/extinguisher/mini,
/obj/item/device/radio,
/obj/item/clothing/gloves
+1 -1
View File
@@ -65,7 +65,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible",
SSreligion.bible_icon_state = B.icon_state
SSreligion.bible_item_state = B.item_state
SSblackbox.set_details("religion_book","[biblename]")
SSblackbox.record_feedback("text", "religion_book", 1, "[biblename]")
usr << browse(null, "window=editicon")
/obj/item/storage/book/bible/proc/bless(mob/living/carbon/human/H, mob/living/user)
+5 -2
View File
@@ -93,6 +93,10 @@
else
return ..()
/obj/item/watertank/dropped(mob/user)
..()
remove_noz()
// This mister item is intended as an extension of the watertank and always attached to it.
// Therefore, it's designed to be "locked" to the player's hands or extended back onto
// the watertank backpack. Allowing it to be placed elsewhere or created without a parent
@@ -109,7 +113,7 @@
amount_per_transfer_from_this = 50
possible_transfer_amounts = list(25,50,100)
volume = 500
flags_1 = NODROP_1 | NOBLUDGEON_1
flags_1 = NOBLUDGEON_1
container_type = OPENCONTAINER_1
slot_flags = 0
@@ -221,7 +225,6 @@
precision = 1
cooling_power = 5
w_class = WEIGHT_CLASS_HUGE
flags_1 = NODROP_1 //Necessary to ensure that the nozzle and tank never separate
var/obj/item/watertank/tank
var/nozzle_mode = 0
var/metal_synthesis_cooldown = 0
+2
View File
@@ -41,6 +41,8 @@
else //something wrong
name = "[initial(name)]"
update_icon()
if(user.get_item_by_slot(slot_back) == src)
user.update_inv_back()
if(show_message)
if(iscyborg(user))
to_chat(user, "<span class='notice'>You free up your module.</span>")
+1 -1
View File
@@ -474,7 +474,7 @@
attack_verb = list("smacked", "whacked", "slammed", "smashed")
/obj/item/melee/skateboard/attack_self(mob/user)
new /obj/vehicle/scooter/skateboard(get_turf(user))
new /obj/vehicle/ridden/scooter/skateboard(get_turf(user))
qdel(src)
/obj/item/melee/baseball_bat
+1 -1
View File
@@ -185,7 +185,7 @@
if(brain.force_replace_ai_name)
A.fully_replace_character_name(A.name, brain.replacement_ai_name())
SSblackbox.inc("cyborg_ais_created",1)
SSblackbox.record_feedback("amount", "ais_created", 1)
qdel(src)
else
state = AI_READY_CORE
@@ -66,16 +66,16 @@
"<span class='italics'>You hear squelching...</span>")
/obj/structure/bed/nest/post_buckle_mob(mob/living/M)
if(M in buckled_mobs)
M.pixel_y = 0
M.pixel_x = initial(M.pixel_x) + 2
M.layer = BELOW_MOB_LAYER
add_overlay(nest_overlay)
else
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
M.layer = initial(M.layer)
cut_overlay(nest_overlay)
M.pixel_y = 0
M.pixel_x = initial(M.pixel_x) + 2
M.layer = BELOW_MOB_LAYER
add_overlay(nest_overlay)
/obj/structure/bed/nest/post_unbuckle_mob(mob/living/M)
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
M.layer = initial(M.layer)
cut_overlay(nest_overlay)
/obj/structure/bed/nest/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0)
switch(damage_type)
@@ -85,21 +85,21 @@
qdel(src)
/obj/structure/bed/roller/post_buckle_mob(mob/living/M)
if(M in buckled_mobs)
density = TRUE
icon_state = "up"
M.pixel_y = initial(M.pixel_y)
else
density = FALSE
icon_state = "down"
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
density = TRUE
icon_state = "up"
M.pixel_y = initial(M.pixel_y)
/obj/structure/bed/roller/Moved()
. = ..()
if(has_gravity())
playsound(src, 'sound/effects/roll.ogg', 100, 1)
/obj/structure/bed/roller/post_unbuckle_mob(mob/living/M)
density = FALSE
icon_state = "down"
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
/obj/item/roller
name = "roller bed"
desc = "A collapsed roller bed that can be carried around."
@@ -91,7 +91,11 @@
layer = OBJ_LAYER
/obj/structure/chair/post_buckle_mob(mob/living/M)
..()
. = ..()
handle_layer()
/obj/structure/chair/post_unbuckle_mob()
. = ..()
handle_layer()
/obj/structure/chair/proc/spin()
@@ -167,12 +171,18 @@
return ..()
/obj/structure/chair/comfy/post_buckle_mob(mob/living/M)
..()
. = ..()
update_armrest()
/obj/structure/chair/comfy/proc/update_armrest()
if(has_buckled_mobs())
add_overlay(armrest)
else
cut_overlay(armrest)
/obj/structure/chair/comfy/post_unbuckle_mob()
. = ..()
update_armrest()
/obj/structure/chair/comfy/brown
color = rgb(255,113,0)

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