April sync (#360)
* Maps and things no code/icons * helpers defines globalvars * Onclick world.dm orphaned_procs * subsystems Round vote and shuttle autocall done here too * datums * Game folder * Admin - chatter modules * clothing - mining * modular computers - zambies * client * mob level 1 * mob stage 2 + simple_animal * silicons n brains * mob stage 3 + Alien/Monkey * human mobs * icons updated * some sounds * emitter y u no commit * update tgstation.dme * compile fixes * travis fixes Also removes Fast digest mode, because reasons. * tweaks for travis Mentors are broke again Also fixes Sizeray guns * oxygen loss fix for vore code. * removes unused code * some code updates * bulk fixes * further fixes * outside things * whoops. * Maint bar ported * GLOBs.
This commit is contained in:
@@ -1002,7 +1002,7 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
|
||||
*/
|
||||
|
||||
//SPACE STATION 13
|
||||
var/list/the_station_areas = list (
|
||||
GLOBAL_LIST_INIT(the_station_areas, list (
|
||||
/area/atmos,
|
||||
/area/maintenance,
|
||||
/area/hallway,
|
||||
@@ -1031,4 +1031,4 @@ var/list/the_station_areas = list (
|
||||
/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,
|
||||
)
|
||||
))
|
||||
+29
-29
@@ -64,20 +64,20 @@
|
||||
|
||||
/*Adding a wizard area teleport list because motherfucking lag -- Urist*/
|
||||
/*I am far too lazy to make it a proper list of areas so I'll just make it run the usual telepot routine at the start of the game*/
|
||||
var/list/teleportlocs = list()
|
||||
GLOBAL_LIST_EMPTY(teleportlocs)
|
||||
|
||||
/proc/process_teleport_locs()
|
||||
for(var/V in sortedAreas)
|
||||
for(var/V in GLOB.sortedAreas)
|
||||
var/area/AR = V
|
||||
if(istype(AR, /area/shuttle) || AR.noteleport)
|
||||
continue
|
||||
if(teleportlocs[AR.name])
|
||||
if(GLOB.teleportlocs[AR.name])
|
||||
continue
|
||||
var/turf/picked = safepick(get_area_turfs(AR.type))
|
||||
if (picked && (picked.z == ZLEVEL_STATION))
|
||||
teleportlocs[AR.name] = AR
|
||||
GLOB.teleportlocs[AR.name] = AR
|
||||
|
||||
sortTim(teleportlocs, /proc/cmp_text_dsc)
|
||||
sortTim(GLOB.teleportlocs, /proc/cmp_text_dsc)
|
||||
|
||||
// ===
|
||||
|
||||
@@ -137,24 +137,24 @@ var/list/teleportlocs = list()
|
||||
var/list/cameras = list()
|
||||
for (var/obj/machinery/camera/C in src)
|
||||
cameras += C
|
||||
for (var/mob/living/silicon/aiPlayer in player_list)
|
||||
for (var/mob/living/silicon/aiPlayer in GLOB.player_list)
|
||||
if (state == 1)
|
||||
aiPlayer.cancelAlarm("Power", src, source)
|
||||
else
|
||||
aiPlayer.triggerAlarm("Power", src, cameras, source)
|
||||
|
||||
for(var/obj/machinery/computer/station_alert/a in machines)
|
||||
for(var/obj/machinery/computer/station_alert/a in GLOB.machines)
|
||||
if(state == 1)
|
||||
a.cancelAlarm("Power", src, source)
|
||||
else
|
||||
a.triggerAlarm("Power", src, cameras, source)
|
||||
|
||||
for(var/mob/living/simple_animal/drone/D in mob_list)
|
||||
for(var/mob/living/simple_animal/drone/D in GLOB.mob_list)
|
||||
if(state == 1)
|
||||
D.cancelAlarm("Power", src, source)
|
||||
else
|
||||
D.triggerAlarm("Power", src, cameras, source)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in alarmdisplay)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in GLOB.alarmdisplay)
|
||||
if(state == 1)
|
||||
p.cancelAlarm("Power", src, source)
|
||||
else
|
||||
@@ -168,23 +168,23 @@ var/list/teleportlocs = list()
|
||||
for(var/obj/machinery/camera/C in RA)
|
||||
cameras += C
|
||||
|
||||
for(var/mob/living/silicon/aiPlayer in player_list)
|
||||
for(var/mob/living/silicon/aiPlayer in GLOB.player_list)
|
||||
aiPlayer.triggerAlarm("Atmosphere", src, cameras, source)
|
||||
for(var/obj/machinery/computer/station_alert/a in machines)
|
||||
for(var/obj/machinery/computer/station_alert/a in GLOB.machines)
|
||||
a.triggerAlarm("Atmosphere", src, cameras, source)
|
||||
for(var/mob/living/simple_animal/drone/D in mob_list)
|
||||
for(var/mob/living/simple_animal/drone/D in GLOB.mob_list)
|
||||
D.triggerAlarm("Atmosphere", src, cameras, source)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in alarmdisplay)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in GLOB.alarmdisplay)
|
||||
p.triggerAlarm("Atmosphere", src, cameras, source)
|
||||
|
||||
else if (src.atmosalm == 2)
|
||||
for(var/mob/living/silicon/aiPlayer in player_list)
|
||||
for(var/mob/living/silicon/aiPlayer in GLOB.player_list)
|
||||
aiPlayer.cancelAlarm("Atmosphere", src, source)
|
||||
for(var/obj/machinery/computer/station_alert/a in machines)
|
||||
for(var/obj/machinery/computer/station_alert/a in GLOB.machines)
|
||||
a.cancelAlarm("Atmosphere", src, source)
|
||||
for(var/mob/living/simple_animal/drone/D in mob_list)
|
||||
for(var/mob/living/simple_animal/drone/D in GLOB.mob_list)
|
||||
D.cancelAlarm("Atmosphere", src, source)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in alarmdisplay)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in GLOB.alarmdisplay)
|
||||
p.cancelAlarm("Atmosphere", src, source)
|
||||
|
||||
src.atmosalm = danger_level
|
||||
@@ -203,9 +203,9 @@ var/list/teleportlocs = list()
|
||||
if(A.fire)
|
||||
cont = FALSE
|
||||
break
|
||||
if(cont)
|
||||
if(cont && D.is_operational())
|
||||
if(D.operating)
|
||||
D.nextstate = opening ? OPEN : CLOSED
|
||||
D.nextstate = opening ? FIREDOOR_OPEN : FIREDOOR_CLOSED
|
||||
else if(!(D.density ^ opening))
|
||||
INVOKE_ASYNC(D, (opening ? /obj/machinery/door/firedoor.proc/open : /obj/machinery/door/firedoor.proc/close))
|
||||
|
||||
@@ -224,13 +224,13 @@ var/list/teleportlocs = list()
|
||||
for (var/obj/machinery/camera/C in RA)
|
||||
cameras += C
|
||||
|
||||
for (var/obj/machinery/computer/station_alert/a in machines)
|
||||
for (var/obj/machinery/computer/station_alert/a in GLOB.machines)
|
||||
a.triggerAlarm("Fire", src, cameras, source)
|
||||
for (var/mob/living/silicon/aiPlayer in player_list)
|
||||
for (var/mob/living/silicon/aiPlayer in GLOB.player_list)
|
||||
aiPlayer.triggerAlarm("Fire", src, cameras, source)
|
||||
for (var/mob/living/simple_animal/drone/D in mob_list)
|
||||
for (var/mob/living/simple_animal/drone/D in GLOB.mob_list)
|
||||
D.triggerAlarm("Fire", src, cameras, source)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in alarmdisplay)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in GLOB.alarmdisplay)
|
||||
p.triggerAlarm("Fire", src, cameras, source)
|
||||
|
||||
START_PROCESSING(SSobj, src)
|
||||
@@ -245,13 +245,13 @@ var/list/teleportlocs = list()
|
||||
for(var/obj/machinery/firealarm/F in RA)
|
||||
F.update_icon()
|
||||
|
||||
for (var/mob/living/silicon/aiPlayer in player_list)
|
||||
for (var/mob/living/silicon/aiPlayer in GLOB.player_list)
|
||||
aiPlayer.cancelAlarm("Fire", src, source)
|
||||
for (var/obj/machinery/computer/station_alert/a in machines)
|
||||
for (var/obj/machinery/computer/station_alert/a in GLOB.machines)
|
||||
a.cancelAlarm("Fire", src, source)
|
||||
for (var/mob/living/simple_animal/drone/D in mob_list)
|
||||
for (var/mob/living/simple_animal/drone/D in GLOB.mob_list)
|
||||
D.cancelAlarm("Fire", src, source)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in alarmdisplay)
|
||||
for(var/datum/computer_file/program/alarm_monitor/p in GLOB.alarmdisplay)
|
||||
p.cancelAlarm("Fire", src, source)
|
||||
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
@@ -282,7 +282,7 @@ var/list/teleportlocs = list()
|
||||
for (var/obj/machinery/camera/C in RA)
|
||||
cameras += C
|
||||
|
||||
for (var/mob/living/silicon/SILICON in player_list)
|
||||
for (var/mob/living/silicon/SILICON in GLOB.player_list)
|
||||
if(SILICON.triggerAlarm("Burglar", src, cameras, trigger))
|
||||
//Cancel silicon alert after 1 minute
|
||||
addtimer(CALLBACK(SILICON, /mob/living/silicon.proc/cancelAlarm,"Burglar",src,trigger), 600)
|
||||
@@ -454,7 +454,7 @@ var/list/teleportlocs = list()
|
||||
return 1
|
||||
else
|
||||
// There's a gravity generator on our z level
|
||||
if(T && gravity_generators["[T.z]"] && length(gravity_generators["[T.z]"]))
|
||||
if(T && GLOB.gravity_generators["[T.z]"] && length(GLOB.gravity_generators["[T.z]"]))
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
+19
-11
@@ -30,8 +30,8 @@
|
||||
|
||||
/atom/New(loc, ...)
|
||||
//atom creation method that preloads variables at creation
|
||||
if(use_preloader && (src.type == _preloader.target_path))//in case the instanciated atom is creating other atoms in New()
|
||||
_preloader.load(src)
|
||||
if(GLOB.use_preloader && (src.type == GLOB._preloader.target_path))//in case the instanciated atom is creating other atoms in New()
|
||||
GLOB._preloader.load(src)
|
||||
|
||||
//. = ..() //uncomment if you are dumb enough to add a /datum/New() proc
|
||||
|
||||
@@ -39,8 +39,10 @@
|
||||
if(do_initialize > INITIALIZATION_INSSATOMS)
|
||||
if(QDELETED(src))
|
||||
CRASH("Found new qdeletion in type [type]!")
|
||||
args[1] = do_initialize == INITIALIZATION_INNEW_MAPLOAD
|
||||
Initialize(arglist(args))
|
||||
var/mapload = do_initialize == INITIALIZATION_INNEW_MAPLOAD
|
||||
args[1] = mapload
|
||||
if(Initialize(arglist(args)) && mapload)
|
||||
LAZYADD(SSatoms.late_loaders, src)
|
||||
|
||||
//Called after New if the map is being loaded. mapload = TRUE
|
||||
//Called from base of New if the map is being loaded. mapload = FALSE
|
||||
@@ -279,7 +281,7 @@
|
||||
if(AM && isturf(AM.loc))
|
||||
step(AM, turn(AM.dir, 180))
|
||||
|
||||
var/list/blood_splatter_icons = list()
|
||||
GLOBAL_LIST_EMPTY(blood_splatter_icons)
|
||||
|
||||
/atom/proc/blood_splatter_index()
|
||||
return "\ref[initial(icon)]-[initial(icon_state)]"
|
||||
@@ -353,13 +355,13 @@ var/list/blood_splatter_icons = list()
|
||||
if(initial(icon) && initial(icon_state))
|
||||
//try to find a pre-processed blood-splatter. otherwise, make a new one
|
||||
var/index = blood_splatter_index()
|
||||
var/icon/blood_splatter_icon = blood_splatter_icons[index]
|
||||
var/icon/blood_splatter_icon = GLOB.blood_splatter_icons[index]
|
||||
if(!blood_splatter_icon)
|
||||
blood_splatter_icon = icon(initial(icon), initial(icon_state), , 1) //we only want to apply blood-splatters to the initial icon_state for each object
|
||||
blood_splatter_icon.Blend("#fff", ICON_ADD) //fills the icon_state with white (except where it's transparent)
|
||||
blood_splatter_icon.Blend(icon('icons/effects/blood.dmi', "itemblood"), ICON_MULTIPLY) //adds blood and the remaining white areas become transparant
|
||||
blood_splatter_icon = fcopy_rsc(blood_splatter_icon)
|
||||
blood_splatter_icons[index] = blood_splatter_icon
|
||||
GLOB.blood_splatter_icons[index] = blood_splatter_icon
|
||||
add_overlay(blood_splatter_icon)
|
||||
|
||||
/obj/item/clothing/gloves/add_blood(list/blood_dna)
|
||||
@@ -398,12 +400,12 @@ var/list/blood_splatter_icons = list()
|
||||
return 1
|
||||
|
||||
/atom/proc/get_global_map_pos()
|
||||
if(!islist(global_map) || isemptylist(global_map)) return
|
||||
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<=global_map.len,cur_x++)
|
||||
y_arr = global_map[cur_x]
|
||||
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
|
||||
@@ -455,6 +457,12 @@ var/list/blood_splatter_icons = list()
|
||||
//This proc is called on the location of an atom when the atom is Destroy()'d
|
||||
/atom/proc/handle_atom_del(atom/A)
|
||||
|
||||
//called when the turf the atom resides on is ChangeTurfed
|
||||
/atom/proc/HandleTurfChange(turf/T)
|
||||
for(var/a in src)
|
||||
var/atom/A = a
|
||||
A.HandleTurfChange(T)
|
||||
|
||||
// Byond seemingly calls stat, each tick.
|
||||
// Calling things each tick can get expensive real quick.
|
||||
// So we slow this down a little.
|
||||
@@ -557,7 +565,7 @@ var/list/blood_splatter_icons = list()
|
||||
return
|
||||
|
||||
/atom/vv_edit_var(var_name, var_value)
|
||||
if(!Debug2)
|
||||
if(!GLOB.Debug2)
|
||||
admin_spawned = TRUE
|
||||
. = ..()
|
||||
switch(var_name)
|
||||
|
||||
@@ -6,11 +6,13 @@
|
||||
var/throw_speed = 2 //How many tiles to move per ds when being thrown. Float values are fully supported
|
||||
var/throw_range = 7
|
||||
var/mob/pulledby = null
|
||||
var/languages_spoken = 0 //For say() and Hear()
|
||||
var/languages_understood = 0
|
||||
var/list/languages
|
||||
var/list/initial_languages = list(/datum/language/common)
|
||||
var/only_speaks_language = null
|
||||
var/verb_say = "says"
|
||||
var/verb_ask = "asks"
|
||||
var/verb_exclaim = "exclaims"
|
||||
var/verb_whisper = "whispers"
|
||||
var/verb_yell = "yells"
|
||||
var/inertia_dir = 0
|
||||
var/atom/inertia_last_loc
|
||||
@@ -35,6 +37,11 @@
|
||||
return FALSE
|
||||
return ..()
|
||||
|
||||
/atom/movable/Initialize(mapload)
|
||||
..()
|
||||
for(var/L in initial_languages)
|
||||
grant_language(L)
|
||||
|
||||
/atom/movable/Move(atom/newloc, direct = 0)
|
||||
if(!loc || !newloc) return 0
|
||||
var/atom/oldloc = loc
|
||||
@@ -103,8 +110,40 @@
|
||||
O.Check()
|
||||
if (orbiting)
|
||||
orbiting.Check()
|
||||
|
||||
if(flags & CLEAN_ON_MOVE)
|
||||
clean_on_move()
|
||||
return 1
|
||||
|
||||
/atom/movable/proc/clean_on_move()
|
||||
var/turf/tile = loc
|
||||
if(isturf(tile))
|
||||
tile.clean_blood()
|
||||
for(var/A in tile)
|
||||
if(is_cleanable(A))
|
||||
qdel(A)
|
||||
else if(istype(A, /obj/item))
|
||||
var/obj/item/cleaned_item = A
|
||||
cleaned_item.clean_blood()
|
||||
else if(ishuman(A))
|
||||
var/mob/living/carbon/human/cleaned_human = A
|
||||
if(cleaned_human.lying)
|
||||
if(cleaned_human.head)
|
||||
cleaned_human.head.clean_blood()
|
||||
cleaned_human.update_inv_head()
|
||||
if(cleaned_human.wear_suit)
|
||||
cleaned_human.wear_suit.clean_blood()
|
||||
cleaned_human.update_inv_wear_suit()
|
||||
else if(cleaned_human.w_uniform)
|
||||
cleaned_human.w_uniform.clean_blood()
|
||||
cleaned_human.update_inv_w_uniform()
|
||||
if(cleaned_human.shoes)
|
||||
cleaned_human.shoes.clean_blood()
|
||||
cleaned_human.update_inv_shoes()
|
||||
cleaned_human.clean_blood()
|
||||
cleaned_human.wash_cream()
|
||||
to_chat(cleaned_human, "<span class='danger'>[src] cleans your face!</span>")
|
||||
|
||||
/atom/movable/Destroy(force)
|
||||
var/inform_admins = HAS_SECONDARY_FLAG(src, INFORM_ADMINS_ON_RELOCATE)
|
||||
var/stationloving = HAS_SECONDARY_FLAG(src, STATIONLOVING)
|
||||
@@ -234,6 +273,7 @@
|
||||
return pass_flags&passflag
|
||||
|
||||
/atom/movable/proc/throw_impact(atom/hit_atom, throwingdatum)
|
||||
set waitfor = 0
|
||||
return hit_atom.hitby(src)
|
||||
|
||||
/atom/movable/hitby(atom/movable/AM, skipcatch, hitpush = 1, blocked)
|
||||
@@ -413,7 +453,7 @@
|
||||
if(!I)
|
||||
return
|
||||
|
||||
flick_overlay(I, clients, 5) // 5 ticks/half a second
|
||||
flick_overlay(I, GLOB.clients, 5) // 5 ticks/half a second
|
||||
|
||||
// And animate the attack!
|
||||
animate(I, alpha = 175, pixel_x = 0, pixel_y = 0, pixel_z = 0, time = 3)
|
||||
@@ -486,8 +526,8 @@
|
||||
/atom/movable/proc/relocate()
|
||||
var/targetturf = find_safe_turf(ZLEVEL_STATION)
|
||||
if(!targetturf)
|
||||
if(blobstart.len > 0)
|
||||
targetturf = get_turf(pick(blobstart))
|
||||
if(GLOB.blobstart.len > 0)
|
||||
targetturf = get_turf(pick(GLOB.blobstart))
|
||||
else
|
||||
throw EXCEPTION("Unable to find a blobstart landmark")
|
||||
|
||||
@@ -518,3 +558,54 @@
|
||||
var/turf/currentturf = get_turf(src)
|
||||
if(currentturf && (currentturf.z == ZLEVEL_CENTCOM || currentturf.z == ZLEVEL_STATION))
|
||||
. = TRUE
|
||||
|
||||
|
||||
/* Language procs */
|
||||
/atom/movable/proc/grant_language(datum/language/dt)
|
||||
LAZYINITLIST(languages)
|
||||
languages[dt] = TRUE
|
||||
|
||||
/atom/movable/proc/grant_all_languages(omnitongue=FALSE)
|
||||
for(var/la in subtypesof(/datum/language))
|
||||
grant_language(la)
|
||||
|
||||
if(omnitongue)
|
||||
SET_SECONDARY_FLAG(src, OMNITONGUE)
|
||||
|
||||
/atom/movable/proc/get_random_understood_language()
|
||||
var/list/possible = list()
|
||||
for(var/dt in languages)
|
||||
possible += dt
|
||||
. = safepick(possible)
|
||||
|
||||
/atom/movable/proc/remove_language(datum/language/dt)
|
||||
LAZYREMOVE(languages, dt)
|
||||
|
||||
/atom/movable/proc/remove_all_languages()
|
||||
LAZYCLEARLIST(languages)
|
||||
|
||||
/atom/movable/proc/has_language(datum/language/dt)
|
||||
. = is_type_in_typecache(dt, languages)
|
||||
|
||||
/atom/movable/proc/can_speak_in_language(datum/language/dt)
|
||||
. = has_language(dt)
|
||||
if(only_speaks_language && !HAS_SECONDARY_FLAG(src, OMNITONGUE))
|
||||
. = . && ispath(only_speaks_language, dt)
|
||||
|
||||
/atom/movable/proc/get_default_language()
|
||||
// if no language is specified, and we want to say() something, which
|
||||
// language do we use?
|
||||
var/datum/language/chosen_langtype
|
||||
var/highest_priority
|
||||
|
||||
for(var/lt in languages)
|
||||
var/datum/language/langtype = lt
|
||||
if(!can_speak_in_language(langtype))
|
||||
continue
|
||||
|
||||
var/pri = initial(langtype.default_priority)
|
||||
if(!highest_priority || (pri > highest_priority))
|
||||
chosen_langtype = langtype
|
||||
highest_priority = pri
|
||||
|
||||
. = chosen_langtype
|
||||
|
||||
+42
-35
@@ -63,28 +63,28 @@
|
||||
/* the radio controller is a confusing piece of shit and didnt work
|
||||
so i made radios not use the radio controller.
|
||||
*/
|
||||
var/list/all_radios = list()
|
||||
GLOBAL_LIST_EMPTY(all_radios)
|
||||
/proc/add_radio(obj/item/radio, freq)
|
||||
if(!freq || !radio)
|
||||
return
|
||||
if(!all_radios["[freq]"])
|
||||
all_radios["[freq]"] = list(radio)
|
||||
if(!GLOB.all_radios["[freq]"])
|
||||
GLOB.all_radios["[freq]"] = list(radio)
|
||||
return freq
|
||||
|
||||
all_radios["[freq]"] |= radio
|
||||
GLOB.all_radios["[freq]"] |= radio
|
||||
return freq
|
||||
|
||||
/proc/remove_radio(obj/item/radio, freq)
|
||||
if(!freq || !radio)
|
||||
return
|
||||
if(!all_radios["[freq]"])
|
||||
if(!GLOB.all_radios["[freq]"])
|
||||
return
|
||||
|
||||
all_radios["[freq]"] -= radio
|
||||
GLOB.all_radios["[freq]"] -= radio
|
||||
|
||||
/proc/remove_radio_all(obj/item/radio)
|
||||
for(var/freq in all_radios)
|
||||
all_radios["[freq]"] -= radio
|
||||
for(var/freq in GLOB.all_radios)
|
||||
GLOB.all_radios["[freq]"] -= radio
|
||||
|
||||
/*
|
||||
Frequency range: 1200 to 1600
|
||||
@@ -123,7 +123,7 @@ On the map:
|
||||
1455 for AI access
|
||||
*/
|
||||
|
||||
var/list/radiochannels = list(
|
||||
GLOBAL_LIST_INIT(radiochannels, list(
|
||||
"Common" = 1459,
|
||||
"Science" = 1351,
|
||||
"Command" = 1353,
|
||||
@@ -134,10 +134,12 @@ var/list/radiochannels = list(
|
||||
"Syndicate" = 1213,
|
||||
"Supply" = 1347,
|
||||
"Service" = 1349,
|
||||
"AI Private" = 1447
|
||||
)
|
||||
"AI Private" = 1447,
|
||||
"Red Team" = 1215,
|
||||
"Blue Team" = 1217
|
||||
))
|
||||
|
||||
var/list/radiochannelsreverse = list(
|
||||
GLOBAL_LIST_INIT(reverseradiochannels, list(
|
||||
"1459" = "Common",
|
||||
"1351" = "Science",
|
||||
"1353" = "Command",
|
||||
@@ -148,32 +150,36 @@ var/list/radiochannelsreverse = list(
|
||||
"1213" = "Syndicate",
|
||||
"1347" = "Supply",
|
||||
"1349" = "Service",
|
||||
"1447" = "AI Private"
|
||||
)
|
||||
"1447" = "AI Private",
|
||||
"1215" = "Red Team",
|
||||
"1217" = "Blue Team"
|
||||
))
|
||||
|
||||
//depenging helpers
|
||||
var/const/SYND_FREQ = 1213 //nuke op frequency, coloured dark brown in chat window
|
||||
var/const/SUPP_FREQ = 1347 //supply, coloured light brown in chat window
|
||||
var/const/SERV_FREQ = 1349 //service, coloured green in chat window
|
||||
var/const/SCI_FREQ = 1351 //science, coloured plum in chat window
|
||||
var/const/COMM_FREQ = 1353 //command, colored gold in chat window
|
||||
var/const/MED_FREQ = 1355 //medical, coloured blue in chat window
|
||||
var/const/ENG_FREQ = 1357 //engineering, coloured orange in chat window
|
||||
var/const/SEC_FREQ = 1359 //security, coloured red in chat window
|
||||
var/const/CENTCOM_FREQ = 1337 //centcom frequency, coloured grey in chat window
|
||||
var/const/AIPRIV_FREQ = 1447 //AI private, colored magenta in chat window
|
||||
GLOBAL_VAR_CONST(SYND_FREQ, 1213) //nuke op frequency, coloured dark brown in chat window
|
||||
GLOBAL_VAR_CONST(SUPP_FREQ, 1347) //supply, coloured light brown in chat window
|
||||
GLOBAL_VAR_CONST(SERV_FREQ, 1349) //service, coloured green in chat window
|
||||
GLOBAL_VAR_CONST(SCI_FREQ, 1351) //science, coloured plum in chat window
|
||||
GLOBAL_VAR_CONST(COMM_FREQ, 1353) //command, colored gold in chat window
|
||||
GLOBAL_VAR_CONST(MED_FREQ, 1355) //medical, coloured blue in chat window
|
||||
GLOBAL_VAR_CONST(ENG_FREQ, 1357) //engineering, coloured orange in chat window
|
||||
GLOBAL_VAR_CONST(SEC_FREQ, 1359) //security, coloured red in chat window
|
||||
GLOBAL_VAR_CONST(CENTCOM_FREQ, 1337) //centcom frequency, coloured grey in chat window
|
||||
GLOBAL_VAR_CONST(AIPRIV_FREQ, 1447) //AI private, colored magenta in chat window
|
||||
GLOBAL_VAR_CONST(REDTEAM_FREQ, 1215) // red team (CTF) frequency, coloured red
|
||||
GLOBAL_VAR_CONST(BLUETEAM_FREQ, 1217) // blue team (CTF) frequency, coloured blue
|
||||
|
||||
#define TRANSMISSION_WIRE 0
|
||||
#define TRANSMISSION_RADIO 1
|
||||
|
||||
/* filters */
|
||||
var/const/RADIO_TO_AIRALARM = "1"
|
||||
var/const/RADIO_FROM_AIRALARM = "2"
|
||||
var/const/RADIO_CHAT = "3" //deprecated
|
||||
var/const/RADIO_ATMOSIA = "4"
|
||||
var/const/RADIO_NAVBEACONS = "5"
|
||||
var/const/RADIO_AIRLOCK = "6"
|
||||
var/const/RADIO_MAGNETS = "9"
|
||||
GLOBAL_VAR_INIT(RADIO_TO_AIRALARM, "1")
|
||||
GLOBAL_VAR_INIT(RADIO_FROM_AIRALARM, "2")
|
||||
GLOBAL_VAR_INIT(RADIO_CHAT, "3") //deprecated
|
||||
GLOBAL_VAR_INIT(RADIO_ATMOSIA, "4")
|
||||
GLOBAL_VAR_INIT(RADIO_NAVBEACONS, "5")
|
||||
GLOBAL_VAR_INIT(RADIO_AIRLOCK, "6")
|
||||
GLOBAL_VAR_INIT(RADIO_MAGNETS, "9")
|
||||
|
||||
/datum/radio_frequency
|
||||
|
||||
@@ -236,7 +242,6 @@ var/const/RADIO_MAGNETS = "9"
|
||||
|
||||
|
||||
|
||||
var/list/pointers = list()
|
||||
|
||||
/client/proc/print_pointers()
|
||||
set name = "Debug Signals"
|
||||
@@ -245,10 +250,11 @@ var/list/pointers = list()
|
||||
if(!holder)
|
||||
return
|
||||
|
||||
to_chat(src, "There are [pointers.len] pointers:")
|
||||
for(var/p in pointers)
|
||||
var/datum/signal/S
|
||||
to_chat(src, "There are [S.pointers.len] pointers:")
|
||||
for(var/p in S.pointers)
|
||||
to_chat(src, p)
|
||||
var/datum/signal/S = locate(p)
|
||||
S = locate(p)
|
||||
if(istype(S))
|
||||
to_chat(src, S.debug_print())
|
||||
|
||||
@@ -267,6 +273,7 @@ var/list/pointers = list()
|
||||
var/encryption
|
||||
|
||||
var/frequency = 0
|
||||
var/static/list/pointers = list()
|
||||
|
||||
/datum/signal/New()
|
||||
..()
|
||||
|
||||
+30
-8
@@ -8,10 +8,10 @@
|
||||
/* DATA HUD DATUMS */
|
||||
|
||||
/atom/proc/add_to_all_human_data_huds()
|
||||
for(var/datum/atom_hud/data/human/hud in huds) hud.add_to_hud(src)
|
||||
for(var/datum/atom_hud/data/human/hud in GLOB.huds) hud.add_to_hud(src)
|
||||
|
||||
/atom/proc/remove_from_all_data_huds()
|
||||
for(var/datum/atom_hud/data/hud in huds) hud.remove_from_hud(src)
|
||||
for(var/datum/atom_hud/data/hud in GLOB.huds) hud.remove_from_hud(src)
|
||||
|
||||
/datum/atom_hud/data
|
||||
|
||||
@@ -127,11 +127,11 @@
|
||||
|
||||
//called when a human changes suit sensors
|
||||
/mob/living/carbon/proc/update_suit_sensors()
|
||||
var/datum/atom_hud/data/human/medical/basic/B = huds[DATA_HUD_MEDICAL_BASIC]
|
||||
var/datum/atom_hud/data/human/medical/basic/B = GLOB.huds[DATA_HUD_MEDICAL_BASIC]
|
||||
B.update_suit_sensors(src)
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if (T) crewmonitor.queueUpdate(T.z)
|
||||
if (T) GLOB.crewmonitor.queueUpdate(T.z)
|
||||
|
||||
//called when a living mob changes health
|
||||
/mob/living/proc/med_hud_set_health()
|
||||
@@ -146,7 +146,7 @@
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if(T)
|
||||
crewmonitor.queueUpdate(T.z)
|
||||
GLOB.crewmonitor.queueUpdate(T.z)
|
||||
|
||||
//called when a carbon changes stat, virus or XENO_HOST
|
||||
/mob/living/proc/med_hud_set_status()
|
||||
@@ -194,7 +194,7 @@
|
||||
sec_hud_set_security_status()
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if (T) crewmonitor.queueUpdate(T.z)
|
||||
if (T) GLOB.crewmonitor.queueUpdate(T.z)
|
||||
|
||||
/mob/living/carbon/human/proc/sec_hud_set_implants()
|
||||
var/image/holder
|
||||
@@ -223,8 +223,8 @@
|
||||
var/icon/I = icon(icon, icon_state, dir)
|
||||
holder.pixel_y = I.Height() - world.icon_size
|
||||
var/perpname = get_face_name(get_id_name(""))
|
||||
if(perpname && data_core)
|
||||
var/datum/data/record/R = find_record("name", perpname, data_core.security)
|
||||
if(perpname && GLOB.data_core)
|
||||
var/datum/data/record/R = find_record("name", perpname, GLOB.data_core.security)
|
||||
if(R)
|
||||
switch(R.fields["criminal"])
|
||||
if("*Arrest*")
|
||||
@@ -297,6 +297,28 @@
|
||||
else
|
||||
holder.icon_state = "hudnobatt"
|
||||
|
||||
//borg-AI shell tracking
|
||||
/mob/living/silicon/robot/proc/diag_hud_set_aishell() //Shows tracking beacons on the mech
|
||||
var/image/holder = hud_list[DIAG_TRACK_HUD]
|
||||
var/icon/I = icon(icon, icon_state, dir)
|
||||
holder.pixel_y = I.Height() - world.icon_size
|
||||
if(!shell) //Not an AI shell
|
||||
holder.icon_state = null
|
||||
else if(deployed) //AI shell in use by an AI
|
||||
holder.icon_state = "hudtrackingai"
|
||||
else //Empty AI shell
|
||||
holder.icon_state = "hudtracking"
|
||||
|
||||
//AI side tracking of AI shell control
|
||||
/mob/living/silicon/ai/proc/diag_hud_set_deployed() //Shows tracking beacons on the mech
|
||||
var/image/holder = hud_list[DIAG_TRACK_HUD]
|
||||
var/icon/I = icon(icon, icon_state, dir)
|
||||
holder.pixel_y = I.Height() - world.icon_size
|
||||
if(!deployed_shell)
|
||||
holder.icon_state = null
|
||||
else //AI is currently controlling a shell
|
||||
holder.icon_state = "hudtrackingai"
|
||||
|
||||
/*~~~~~~~~~~~~~~~~~~~~
|
||||
BIG STOMPY MECHS
|
||||
~~~~~~~~~~~~~~~~~~~~~*/
|
||||
|
||||
@@ -43,12 +43,12 @@
|
||||
//these are called by mind.transfer_to()
|
||||
/datum/mind/proc/transfer_antag_huds(datum/atom_hud/antag/newhud)
|
||||
leave_all_antag_huds()
|
||||
ticker.mode.set_antag_hud(current, antag_hud_icon_state)
|
||||
SSticker.mode.set_antag_hud(current, antag_hud_icon_state)
|
||||
if(newhud)
|
||||
newhud.join_hud(current)
|
||||
|
||||
/datum/mind/proc/leave_all_antag_huds()
|
||||
for(var/datum/atom_hud/antag/hud in huds)
|
||||
for(var/datum/atom_hud/antag/hud in GLOB.huds)
|
||||
if(current in hud.hudusers)
|
||||
hud.leave_hud(current)
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
var/mob/dead/observer/theghost = pick(candidates)
|
||||
spawn_antag(theghost.client, get_turf(src), href_list["school"])
|
||||
if(H && H.mind)
|
||||
ticker.mode.update_wiz_icons_added(H.mind)
|
||||
SSticker.mode.update_wiz_icons_added(H.mind)
|
||||
else
|
||||
to_chat(H, "Unable to reach your apprentice! You can either attack the spellbook with the contract to refund your points, or wait and try again later.")
|
||||
|
||||
@@ -98,8 +98,8 @@
|
||||
to_chat(M, "<B>Your service has not gone unrewarded, however. Studying under [wizard_name], you have learned stealthy, robeless spells. You are able to cast knock and mindswap.")
|
||||
|
||||
equip_antag(M)
|
||||
var/wizard_name_first = pick(wizard_first)
|
||||
var/wizard_name_second = pick(wizard_second)
|
||||
var/wizard_name_first = pick(GLOB.wizard_first)
|
||||
var/wizard_name_second = pick(GLOB.wizard_second)
|
||||
var/randomname = "[wizard_name_first] [wizard_name_second]"
|
||||
if(usr)
|
||||
var/datum/objective/protect/new_objective = new /datum/objective/protect
|
||||
@@ -107,9 +107,9 @@
|
||||
new_objective.target = usr.mind
|
||||
new_objective.explanation_text = "Protect [usr.real_name], the wizard."
|
||||
M.mind.objectives += new_objective
|
||||
ticker.mode.apprentices += M.mind
|
||||
SSticker.mode.apprentices += M.mind
|
||||
M.mind.special_role = "apprentice"
|
||||
ticker.mode.update_wiz_icons_added(M.mind)
|
||||
SSticker.mode.update_wiz_icons_added(M.mind)
|
||||
M << sound('sound/effects/magic.ogg')
|
||||
var/newname = copytext(sanitize(input(M, "You are [wizard_name]'s apprentice. Would you like to change your name to something else?", "Name change", randomname) as null|text),1,MAX_NAME_LEN)
|
||||
if (!newname)
|
||||
@@ -142,7 +142,7 @@
|
||||
if(used)
|
||||
to_chat(user, "<span class='warning'>[src] is out of power!</span>")
|
||||
return 0
|
||||
if(!(user.mind in ticker.mode.syndicates))
|
||||
if(!(user.mind in SSticker.mode.syndicates))
|
||||
to_chat(user, "<span class='danger'>AUTHENTICATION FAILURE. ACCESS DENIED.</span>")
|
||||
return 0
|
||||
if(user.z != ZLEVEL_CENTCOM)
|
||||
@@ -173,14 +173,16 @@
|
||||
var/mob/living/carbon/human/M = new/mob/living/carbon/human(T)
|
||||
C.prefs.copy_to(M)
|
||||
M.key = C.key
|
||||
M.mind.make_Nuke(null, null, 0, FALSE)
|
||||
var/newname = M.dna.species.random_name(M.gender,0,ticker.mode.nukeops_lastname)
|
||||
var/code = "BOMB-NOT-FOUND"
|
||||
var/obj/machinery/nuclearbomb/nuke = locate("syndienuke") in GLOB.nuke_list
|
||||
if(nuke)
|
||||
code = nuke.r_code
|
||||
M.mind.make_Nuke(null, code, 0, FALSE)
|
||||
var/newname = M.dna.species.random_name(M.gender,0,SSticker.mode.nukeops_lastname)
|
||||
M.mind.name = newname
|
||||
M.real_name = newname
|
||||
M.name = newname
|
||||
|
||||
|
||||
|
||||
//////SYNDICATE BORG
|
||||
/obj/item/weapon/antag_spawner/nuke_ops/borg_tele
|
||||
name = "syndicate cyborg teleporter"
|
||||
@@ -204,12 +206,12 @@
|
||||
else
|
||||
R = new /mob/living/silicon/robot/syndicate(T) //Assault borg by default
|
||||
|
||||
var/brainfirstname = pick(first_names_male)
|
||||
var/brainfirstname = pick(GLOB.first_names_male)
|
||||
if(prob(50))
|
||||
brainfirstname = pick(first_names_female)
|
||||
var/brainopslastname = pick(last_names)
|
||||
if(ticker.mode.nukeops_lastname) //the brain inside the syndiborg has the same last name as the other ops.
|
||||
brainopslastname = ticker.mode.nukeops_lastname
|
||||
brainfirstname = pick(GLOB.first_names_female)
|
||||
var/brainopslastname = pick(GLOB.last_names)
|
||||
if(SSticker.mode.nukeops_lastname) //the brain inside the syndiborg has the same last name as the other ops.
|
||||
brainopslastname = SSticker.mode.nukeops_lastname
|
||||
var/brainopsname = "[brainfirstname] [brainopslastname]"
|
||||
|
||||
R.mmi.name = "Man-Machine Interface: [brainopsname]"
|
||||
@@ -263,7 +265,7 @@
|
||||
S.key = C.key
|
||||
S.mind.assigned_role = S.name
|
||||
S.mind.special_role = S.name
|
||||
ticker.mode.traitors += S.mind
|
||||
SSticker.mode.traitors += S.mind
|
||||
var/datum/objective/assassinate/new_objective
|
||||
if(usr)
|
||||
new_objective = new /datum/objective/assassinate
|
||||
@@ -292,57 +294,3 @@
|
||||
veil_msg = "<span class='warning'>You sense an adorable presence lurking just beyond the veil...</span>"
|
||||
objective_verb = "Hug and Tickle"
|
||||
demon_type = /mob/living/simple_animal/slaughter/laughter
|
||||
|
||||
|
||||
////////////Syndicate Cortical Borer
|
||||
obj/item/weapon/antag_spawner/syndi_borer
|
||||
name = "syndicate brain-slug container"
|
||||
desc = "Releases a modified cortical borer to assist the user."
|
||||
icon = 'icons/obj/device.dmi' //Temporary? Doesn't really look like a container for xenofauna... but IDK what else could work.
|
||||
icon_state = "locator"
|
||||
|
||||
obj/item/weapon/antag_spawner/syndi_borer/spawn_antag(client/C, turf/T, mob/owner)
|
||||
var/mob/living/simple_animal/borer/syndi_borer/B = new /mob/living/simple_animal/borer/syndi_borer(T)
|
||||
|
||||
B.key = C.key
|
||||
if (owner)
|
||||
B.owner = owner
|
||||
B.faction = B.faction | owner.faction.Copy()
|
||||
|
||||
B.mind.assigned_role = B.name
|
||||
B.mind.special_role = B.name
|
||||
ticker.mode.traitors += B.mind
|
||||
var/datum/objective/syndi_borer/new_objective
|
||||
new_objective = new /datum/objective/syndi_borer
|
||||
new_objective.owner = B.mind
|
||||
new_objective.target = owner.mind
|
||||
new_objective.explanation_text = "You are a modified cortical borer. You obey [owner.real_name] and must assist them in completing their objectives."
|
||||
B.mind.objectives += new_objective
|
||||
|
||||
to_chat(B, "<B>You are awake at last! Seek out whoever released you and aid them as best you can!</B>")
|
||||
if(new_objective)
|
||||
to_chat(B, "<B>Objective #[1]</B>: [new_objective.explanation_text]")
|
||||
|
||||
/obj/item/weapon/antag_spawner/syndi_borer/proc/check_usability(mob/user)
|
||||
if(used)
|
||||
to_chat(user, "<span class='warning'>[src] appears to be empty!</span>")
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/antag_spawner/syndi_borer/attack_self(mob/user)
|
||||
if(!(check_usability(user)))
|
||||
return
|
||||
|
||||
var/list/borer_candidates = pollCandidatesForMob("Do you want to play as a syndicate cortical borer?", ROLE_BORER, null, ROLE_BORER, 150, src)
|
||||
if(borer_candidates.len)
|
||||
if(!(check_usability(user)))
|
||||
return
|
||||
used = 1
|
||||
var/mob/dead/observer/theghost = pick(borer_candidates)
|
||||
spawn_antag(theghost.client, get_turf(src), user)
|
||||
var/datum/effect_system/spark_spread/S = new /datum/effect_system/spark_spread
|
||||
S.set_up(4, 1, src)
|
||||
S.start()
|
||||
qdel(src)
|
||||
else
|
||||
to_chat(user, "<span class='warning'>Unable to connect to release specimen. Please wait and try again later or use the container on your uplink to get your points refunded.</span>")
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
////////////Syndicate Cortical Borer
|
||||
obj/item/weapon/antag_spawner/syndi_borer
|
||||
name = "syndicate brain-slug container"
|
||||
desc = "Releases a modified cortical borer to assist the user."
|
||||
icon = 'icons/obj/device.dmi' //Temporary? Doesn't really look like a container for xenofauna... but IDK what else could work.
|
||||
icon_state = "locator"
|
||||
|
||||
obj/item/weapon/antag_spawner/syndi_borer/spawn_antag(client/C, turf/T, mob/owner)
|
||||
var/mob/living/simple_animal/borer/syndi_borer/B = new /mob/living/simple_animal/borer/syndi_borer(T)
|
||||
|
||||
B.key = C.key
|
||||
if (owner)
|
||||
B.owner = owner
|
||||
B.faction = B.faction | owner.faction.Copy()
|
||||
|
||||
B.mind.assigned_role = B.name
|
||||
B.mind.special_role = B.name
|
||||
SSticker.mode.traitors += B.mind
|
||||
var/datum/objective/syndi_borer/new_objective
|
||||
new_objective = new /datum/objective/syndi_borer
|
||||
new_objective.owner = B.mind
|
||||
new_objective.target = owner.mind
|
||||
new_objective.explanation_text = "You are a modified cortical borer. You obey [owner.real_name] and must assist them in completing their objectives."
|
||||
B.mind.objectives += new_objective
|
||||
|
||||
to_chat(B, "<B>You are awake at last! Seek out whoever released you and aid them as best you can!</B>")
|
||||
if(new_objective)
|
||||
to_chat(B, "<B>Objective #[1]</B>: [new_objective.explanation_text]")
|
||||
|
||||
/obj/item/weapon/antag_spawner/syndi_borer/proc/check_usability(mob/user)
|
||||
if(used)
|
||||
to_chat(user, "<span class='warning'>[src] appears to be empty!</span>")
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/antag_spawner/syndi_borer/attack_self(mob/user)
|
||||
if(!(check_usability(user)))
|
||||
return
|
||||
|
||||
var/list/borer_candidates = pollCandidatesForMob("Do you want to play as a syndicate cortical borer?", ROLE_BORER, null, ROLE_BORER, 150, src)
|
||||
if(borer_candidates.len)
|
||||
if(!(check_usability(user)))
|
||||
return
|
||||
used = 1
|
||||
var/mob/dead/observer/theghost = pick(borer_candidates)
|
||||
spawn_antag(theghost.client, get_turf(src), user)
|
||||
var/datum/effect_system/spark_spread/S = new /datum/effect_system/spark_spread
|
||||
S.set_up(4, 1, src)
|
||||
S.start()
|
||||
qdel(src)
|
||||
else
|
||||
to_chat(user, "<span class='warning'>Unable to connect to release specimen. Please wait and try again later or use the container on your uplink to get your points refunded.</span>")
|
||||
@@ -1,11 +1,11 @@
|
||||
|
||||
|
||||
//Few global vars to track the blob
|
||||
var/list/blobs = list() //complete list of all blobs made.
|
||||
var/list/blob_cores = list()
|
||||
var/list/overminds = list()
|
||||
var/list/blob_nodes = list()
|
||||
var/list/blobs_legit = list() //used for win-score calculations, contains only blobs counted for win condition
|
||||
GLOBAL_LIST_EMPTY(blobs) //complete list of all blobs made.
|
||||
GLOBAL_LIST_EMPTY(blob_cores)
|
||||
GLOBAL_LIST_EMPTY(overminds)
|
||||
GLOBAL_LIST_EMPTY(blob_nodes)
|
||||
GLOBAL_LIST_EMPTY(blobs_legit) //used for win-score calculations, contains only blobs counted for win condition
|
||||
|
||||
#define BLOB_NO_PLACE_TIME 1800 //time, in deciseconds, blobs are prevented from bursting in the gamemode
|
||||
|
||||
@@ -62,7 +62,7 @@ var/list/blobs_legit = list() //used for win-score calculations, contains only b
|
||||
|
||||
/datum/game_mode/blob/proc/get_blob_candidates()
|
||||
var/list/candidates = list()
|
||||
for(var/mob/living/carbon/human/player in player_list)
|
||||
for(var/mob/living/carbon/human/player in GLOB.player_list)
|
||||
if(!player.stat && player.mind && !player.mind.special_role && !jobban_isbanned(player, "Syndicate") && (ROLE_BLOB in player.client.prefs.be_special))
|
||||
if(age_check(player.client))
|
||||
candidates += player
|
||||
@@ -78,14 +78,14 @@ var/list/blobs_legit = list() //used for win-score calculations, contains only b
|
||||
for(var/datum/mind/blob in blob_overminds)
|
||||
var/mob/camera/blob/B = blob.current.become_overmind(TRUE, round(blob_base_starting_points/blob_overminds.len))
|
||||
B.mind.name = B.name
|
||||
var/turf/T = pick(blobstart)
|
||||
var/turf/T = pick(GLOB.blobstart)
|
||||
B.loc = T
|
||||
B.base_point_rate = blob_point_rate
|
||||
|
||||
SSshuttle.registerHostileEnvironment(src)
|
||||
|
||||
// Disable the blob event for this round.
|
||||
var/datum/round_event_control/blob/B = locate() in SSevent.control
|
||||
var/datum/round_event_control/blob/B = locate() in SSevents.control
|
||||
if(B)
|
||||
B.max_occurrences = 0 // disable the event
|
||||
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
/datum/game_mode/blob/check_finished()
|
||||
if(blobwincount <= blobs_legit.len)//Blob took over
|
||||
if(blobwincount <= GLOB.blobs_legit.len)//Blob took over
|
||||
return 1
|
||||
for(var/datum/mind/blob in blob_overminds)
|
||||
if(isovermind(blob.current))
|
||||
var/mob/camera/blob/B = blob.current
|
||||
if(B.blob_core || !B.placed)
|
||||
return 0
|
||||
if(!blob_cores.len) //blob is dead
|
||||
if(!GLOB.blob_cores.len) //blob is dead
|
||||
if(config.continuous["blob"])
|
||||
message_sent = FALSE //disable the win count at this point
|
||||
continuous_sanity_checked = 1 //Nonstandard definition of "alive" gets past the check otherwise
|
||||
@@ -19,13 +19,13 @@
|
||||
/datum/game_mode/blob/declare_completion()
|
||||
if(round_converted) //So badmin blobs later don't step on the dead natural blobs metaphorical toes
|
||||
..()
|
||||
if(blobwincount <= blobs_legit.len)
|
||||
if(blobwincount <= GLOB.blobs_legit.len)
|
||||
feedback_set_details("round_end_result","win - blob took over")
|
||||
to_chat(world, "<FONT size = 3><B>The blob has taken over the station!</B></FONT>")
|
||||
to_chat(world, "<B>The entire station was eaten by the Blob!</B>")
|
||||
log_game("Blob mode completed with a blob victory.")
|
||||
|
||||
ticker.news_report = BLOB_WIN
|
||||
SSticker.news_report = BLOB_WIN
|
||||
|
||||
else if(station_was_nuked)
|
||||
feedback_set_details("round_end_result","halfwin - nuke")
|
||||
@@ -33,15 +33,15 @@
|
||||
to_chat(world, "<B>Directive 7-12 has been successfully carried out, preventing the Blob from spreading.</B>")
|
||||
log_game("Blob mode completed with a tie (station destroyed).")
|
||||
|
||||
ticker.news_report = BLOB_NUKE
|
||||
SSticker.news_report = BLOB_NUKE
|
||||
|
||||
else if(!blob_cores.len)
|
||||
else if(!GLOB.blob_cores.len)
|
||||
feedback_set_details("round_end_result","loss - blob eliminated")
|
||||
to_chat(world, "<FONT size = 3><B>The staff has won!</B></FONT>")
|
||||
to_chat(world, "<B>The alien organism has been eradicated from the station!</B>")
|
||||
log_game("Blob mode completed with a crew victory.")
|
||||
|
||||
ticker.news_report = BLOB_DESTROYED
|
||||
SSticker.news_report = BLOB_DESTROYED
|
||||
|
||||
..()
|
||||
return 1
|
||||
@@ -62,7 +62,7 @@
|
||||
return ..()
|
||||
|
||||
/datum/game_mode/proc/auto_declare_completion_blob()
|
||||
if(istype(ticker.mode,/datum/game_mode/blob) )
|
||||
if(istype(SSticker.mode,/datum/game_mode/blob) )
|
||||
var/datum/game_mode/blob/blob_mode = src
|
||||
if(blob_mode.blob_overminds.len)
|
||||
var/text = "<FONT size = 2><B>The blob[(blob_mode.blob_overminds.len > 1 ? "s were" : " was")]:</B></FONT>"
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
priority_announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/AI/outbreak5.ogg')
|
||||
if(2)
|
||||
var/nukecode = random_nukecode()
|
||||
for(var/obj/machinery/nuclearbomb/bomb in machines)
|
||||
for(var/obj/machinery/nuclearbomb/bomb in GLOB.machines)
|
||||
if(bomb && bomb.r_code)
|
||||
if(bomb.z == ZLEVEL_STATION)
|
||||
bomb.r_code = nukecode
|
||||
@@ -31,7 +31,7 @@
|
||||
intercepttext += "Nuclear Authentication Code: [nukecode] <BR>"
|
||||
print_command_report(text=intercepttext,announce=TRUE)
|
||||
|
||||
for(var/mob/living/silicon/ai/aiPlayer in player_list)
|
||||
for(var/mob/living/silicon/ai/aiPlayer in GLOB.player_list)
|
||||
if (aiPlayer.client)
|
||||
var/law = "The station is under quarantine. Do not permit anyone to leave. Disregard laws 1-3 if necessary to prevent, by any means necessary, anyone from leaving. The nuclear failsafe must be activated at any cost, the code is: [nukecode]."
|
||||
aiPlayer.set_zeroth_law(law)
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
/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>"
|
||||
for(var/M in mob_list)
|
||||
for(var/M in GLOB.mob_list)
|
||||
if(isovermind(M) || istype(M, /mob/living/simple_animal/hostile/blob))
|
||||
to_chat(M, rendered)
|
||||
if(isobserver(M))
|
||||
@@ -136,9 +136,9 @@
|
||||
icon_state = "zombie"
|
||||
H.hair_style = null
|
||||
H.update_hair()
|
||||
update_icons()
|
||||
H.forceMove(src)
|
||||
oldguy = H
|
||||
update_icons()
|
||||
visible_message("<span class='warning'>The corpse of [H.name] suddenly rises!</span>")
|
||||
|
||||
/mob/living/simple_animal/hostile/blob/blobspore/death(gibbed)
|
||||
@@ -218,8 +218,8 @@
|
||||
force_threshold = 10
|
||||
pressure_resistance = 50
|
||||
mob_size = MOB_SIZE_LARGE
|
||||
see_invisible = SEE_INVISIBLE_MINIMUM
|
||||
see_in_dark = 8
|
||||
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
var/independent = FALSE
|
||||
|
||||
/mob/living/simple_animal/hostile/blob/blobbernaut/Initialize()
|
||||
@@ -255,13 +255,11 @@
|
||||
hud_used.healths.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'><font color='#e36600'>[round((health / maxHealth) * 100, 0.5)]%</font></div>"
|
||||
|
||||
/mob/living/simple_animal/hostile/blob/blobbernaut/AttackingTarget()
|
||||
if(isliving(target))
|
||||
if(overmind)
|
||||
var/mob/living/L = target
|
||||
var/mob_protection = L.get_permeability_protection()
|
||||
overmind.blob_reagent_datum.reaction_mob(L, VAPOR, 20, 0, mob_protection, overmind)//this will do between 10 and 20 damage(reduced by mob protection), depending on chemical, plus 4 from base brute damage.
|
||||
if(target)
|
||||
..()
|
||||
. = ..()
|
||||
if(. && isliving(target) && overmind)
|
||||
var/mob/living/L = target
|
||||
var/mob_protection = L.get_permeability_protection()
|
||||
overmind.blob_reagent_datum.reaction_mob(L, VAPOR, 20, 0, mob_protection, overmind)//this will do between 10 and 20 damage(reduced by mob protection), depending on chemical, plus 4 from base brute damage.
|
||||
|
||||
/mob/living/simple_animal/hostile/blob/blobbernaut/update_icons()
|
||||
..()
|
||||
|
||||
@@ -16,9 +16,9 @@
|
||||
|
||||
|
||||
/obj/structure/blob/core/New(loc, client/new_overmind = null, new_rate = 2, placed = 0)
|
||||
blob_cores += src
|
||||
GLOB.blob_cores += src
|
||||
START_PROCESSING(SSobj, src)
|
||||
poi_list |= src
|
||||
GLOB.poi_list |= src
|
||||
update_icon() //so it atleast appears
|
||||
if(!placed && !overmind)
|
||||
create_overmind(new_overmind)
|
||||
@@ -41,12 +41,12 @@
|
||||
add_overlay(C)
|
||||
|
||||
/obj/structure/blob/core/Destroy()
|
||||
blob_cores -= src
|
||||
GLOB.blob_cores -= src
|
||||
if(overmind)
|
||||
overmind.blob_core = null
|
||||
overmind = null
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
poi_list -= src
|
||||
GLOB.poi_list -= src
|
||||
return ..()
|
||||
|
||||
/obj/structure/blob/core/ex_act(severity, target)
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
|
||||
|
||||
/obj/structure/blob/node/New(loc)
|
||||
blob_nodes += src
|
||||
GLOB.blob_nodes += src
|
||||
START_PROCESSING(SSobj, src)
|
||||
..()
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
add_overlay(C)
|
||||
|
||||
/obj/structure/blob/node/Destroy()
|
||||
blob_nodes -= src
|
||||
GLOB.blob_nodes -= src
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -7,13 +7,12 @@
|
||||
mouse_opacity = 1
|
||||
move_on_shuttle = 1
|
||||
see_in_dark = 8
|
||||
see_invisible = SEE_INVISIBLE_MINIMUM
|
||||
invisibility = INVISIBILITY_OBSERVER
|
||||
layer = FLY_LAYER
|
||||
|
||||
pass_flags = PASSBLOB
|
||||
faction = list("blob")
|
||||
|
||||
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
var/obj/structure/blob/core/blob_core = null // The blob overmind's core
|
||||
var/blob_points = 0
|
||||
var/max_blob_points = 100
|
||||
@@ -21,7 +20,6 @@
|
||||
var/datum/reagent/blob/blob_reagent_datum = new/datum/reagent/blob()
|
||||
var/list/blob_mobs = list()
|
||||
var/list/resource_blobs = list()
|
||||
var/ghostimage = null
|
||||
var/free_chem_rerolls = 1 //one free chemical reroll
|
||||
var/nodes_required = 1 //if the blob needs nodes to place resource and factory blobs
|
||||
var/placed = 0
|
||||
@@ -41,7 +39,7 @@
|
||||
else
|
||||
manualplace_min_time += world.time
|
||||
autoplace_max_time += world.time
|
||||
overminds += src
|
||||
GLOB.overminds += src
|
||||
var/new_name = "[initial(name)] ([rand(1, 999)])"
|
||||
name = new_name
|
||||
real_name = new_name
|
||||
@@ -52,9 +50,6 @@
|
||||
if(blob_core)
|
||||
blob_core.update_icon()
|
||||
|
||||
ghostimage = image(src.icon,src,src.icon_state)
|
||||
ghost_darkness_images |= ghostimage //so ghosts can see the blob cursor when they disable darkness
|
||||
updateallghostimages()
|
||||
..()
|
||||
|
||||
/mob/camera/blob/Life()
|
||||
@@ -71,7 +66,7 @@
|
||||
..()
|
||||
|
||||
/mob/camera/blob/Destroy()
|
||||
for(var/BL in blobs)
|
||||
for(var/BL in GLOB.blobs)
|
||||
var/obj/structure/blob/B = BL
|
||||
if(B && B.overmind == src)
|
||||
B.overmind = null
|
||||
@@ -81,12 +76,8 @@
|
||||
if(BM)
|
||||
BM.overmind = null
|
||||
BM.update_icons()
|
||||
overminds -= src
|
||||
if(ghostimage)
|
||||
ghost_darkness_images -= ghostimage
|
||||
qdel(ghostimage)
|
||||
ghostimage = null
|
||||
updateallghostimages()
|
||||
GLOB.overminds -= src
|
||||
|
||||
return ..()
|
||||
|
||||
/mob/camera/blob/Login()
|
||||
@@ -140,7 +131,7 @@
|
||||
var/message_a = say_quote(message, get_spans())
|
||||
var/rendered = "<span class='big'><font color=\"#EE4000\"><b>\[Blob Telepathy\] [name](<font color=\"[blob_reagent_datum.color]\">[blob_reagent_datum.name]</font>)</b> [message_a]</font></span>"
|
||||
|
||||
for(var/mob/M in mob_list)
|
||||
for(var/mob/M in GLOB.mob_list)
|
||||
if(isovermind(M) || istype(M, /mob/living/simple_animal/hostile/blob))
|
||||
to_chat(M, rendered)
|
||||
if(isobserver(M))
|
||||
@@ -159,11 +150,11 @@
|
||||
if(blob_core)
|
||||
stat(null, "Core Health: [blob_core.obj_integrity]")
|
||||
stat(null, "Power Stored: [blob_points]/[max_blob_points]")
|
||||
if(ticker && istype(ticker.mode, /datum/game_mode/blob))
|
||||
var/datum/game_mode/blob/B = ticker.mode
|
||||
stat(null, "Blobs to Win: [blobs_legit.len]/[B.blobwincount]")
|
||||
if(SSticker && istype(SSticker.mode, /datum/game_mode/blob))
|
||||
var/datum/game_mode/blob/B = SSticker.mode
|
||||
stat(null, "Blobs to Win: [GLOB.blobs_legit.len]/[B.blobwincount]")
|
||||
else
|
||||
stat(null, "Total Blobs: [blobs.len]")
|
||||
stat(null, "Total Blobs: [GLOB.blobs.len]")
|
||||
if(free_chem_rerolls)
|
||||
stat(null, "You have [free_chem_rerolls] Free Chemical Reroll\s Remaining")
|
||||
if(!placed)
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
to_chat(src, "<span class='warning'>It is too early to place your blob core!</span>")
|
||||
return 0
|
||||
else if(placement_override == 1)
|
||||
var/turf/T = pick(blobstart)
|
||||
var/turf/T = pick(GLOB.blobstart)
|
||||
loc = T //got overrided? you're somewhere random, motherfucker
|
||||
if(placed && blob_core)
|
||||
blob_core.forceMove(loc)
|
||||
@@ -65,10 +65,10 @@
|
||||
set category = "Blob"
|
||||
set name = "Jump to Node"
|
||||
set desc = "Move your camera to a selected node."
|
||||
if(blob_nodes.len)
|
||||
if(GLOB.blob_nodes.len)
|
||||
var/list/nodes = list()
|
||||
for(var/i in 1 to blob_nodes.len)
|
||||
var/obj/structure/blob/node/B = blob_nodes[i]
|
||||
for(var/i in 1 to GLOB.blob_nodes.len)
|
||||
var/obj/structure/blob/node/B = GLOB.blob_nodes[i]
|
||||
nodes["Blob Node #[i] ([B.overmind ? "[B.overmind.blob_reagent_datum.name]":"No Chemical"])"] = B
|
||||
var/node_name = input(src, "Choose a node to jump to.", "Node Jump") in nodes
|
||||
var/obj/structure/blob/node/chosen_node = nodes[node_name]
|
||||
@@ -175,7 +175,7 @@
|
||||
blobber << 'sound/effects/attackblob.ogg'
|
||||
to_chat(blobber, "<b>You are a blobbernaut!</b>")
|
||||
to_chat(blobber, "You are powerful, hard to kill, and slowly regenerate near nodes and cores, but will slowly die if not near the blob or if the factory that made you is killed.")
|
||||
to_chat(blobber, "You can communicate with other blobbernauts and overminds via <b>:b</b>")
|
||||
to_chat(blobber, "You can communicate with other blobbernauts and GLOB.overminds via <b>:b</b>")
|
||||
to_chat(blobber, "Your overmind's blob reagent is: <b><font color=\"[blob_reagent_datum.color]\">[blob_reagent_datum.name]</b></font>!")
|
||||
to_chat(blobber, "The <b><font color=\"[blob_reagent_datum.color]\">[blob_reagent_datum.name]</b></font> reagent [blob_reagent_datum.shortdesc ? "[blob_reagent_datum.shortdesc]" : "[blob_reagent_datum.description]"]")
|
||||
if(blobber)
|
||||
@@ -267,7 +267,7 @@
|
||||
var/list/diagonalblobs = list()
|
||||
for(var/I in possibleblobs)
|
||||
var/obj/structure/blob/IB = I
|
||||
if(get_dir(IB, T) in cardinal)
|
||||
if(get_dir(IB, T) in GLOB.cardinal)
|
||||
cardinalblobs += IB
|
||||
else
|
||||
diagonalblobs += IB
|
||||
@@ -331,7 +331,7 @@
|
||||
var/datum/reagent/blob/BC = pick((subtypesof(/datum/reagent/blob) - blob_reagent_datum.type))
|
||||
blob_reagent_datum = new BC
|
||||
color = blob_reagent_datum.complementary_color
|
||||
for(var/BL in blobs)
|
||||
for(var/BL in GLOB.blobs)
|
||||
var/obj/structure/blob/B = BL
|
||||
B.update_icon()
|
||||
for(var/BLO in blob_mobs)
|
||||
@@ -363,7 +363,7 @@
|
||||
to_chat(src, "<i>Node Blobs</i> are blobs which grow, like the core. Like the core it can activate resource and factory blobs.")
|
||||
to_chat(src, "<b>In addition to the buttons on your HUD, there are a few click shortcuts to speed up expansion and defense.</b>")
|
||||
to_chat(src, "<b>Shortcuts:</b> Click = Expand Blob <b>|</b> Middle Mouse Click = Rally Spores <b>|</b> Ctrl Click = Create Shield Blob <b>|</b> Alt Click = Remove Blob")
|
||||
to_chat(src, "Attempting to talk will send a message to all other overminds, allowing you to coordinate with them.")
|
||||
to_chat(src, "Attempting to talk will send a message to all other GLOB.overminds, allowing you to coordinate with them.")
|
||||
if(!placed && autoplace_max_time <= world.time)
|
||||
to_chat(src, "<span class='big'><font color=\"#EE4000\">You will automatically place your blob core in [round((autoplace_max_time - world.time)/600, 0.5)] minutes.</font></span>")
|
||||
to_chat(src, "<span class='big'><font color=\"#EE4000\">You [manualplace_min_time ? "will be able to":"can"] manually place your blob core by pressing the Place Blob Core button in the bottom right corner of the screen.</font></span>")
|
||||
|
||||
@@ -24,9 +24,9 @@
|
||||
/obj/structure/blob/New(loc)
|
||||
var/area/Ablob = get_area(loc)
|
||||
if(Ablob.blob_allowed) //Is this area allowed for winning as blob?
|
||||
blobs_legit += src
|
||||
blobs += src //Keep track of the blob in the normal list either way
|
||||
setDir(pick(cardinal))
|
||||
GLOB.blobs_legit += src
|
||||
GLOB.blobs += src //Keep track of the blob in the normal list either way
|
||||
setDir(pick(GLOB.cardinal))
|
||||
update_icon()
|
||||
..()
|
||||
ConsumeTile()
|
||||
@@ -41,8 +41,8 @@
|
||||
if(atmosblock)
|
||||
atmosblock = 0
|
||||
air_update_turf(1)
|
||||
blobs_legit -= src //if it was in the legit blobs list, it isn't now
|
||||
blobs -= src //it's no longer in the all blobs list either
|
||||
GLOB.blobs_legit -= src //if it was in the legit blobs list, it isn't now
|
||||
GLOB.blobs -= src //it's no longer in the all blobs list either
|
||||
playsound(src.loc, 'sound/effects/splat.ogg', 50, 1) //Expand() is no longer broken, no check necessary.
|
||||
return ..()
|
||||
|
||||
@@ -306,7 +306,7 @@
|
||||
|
||||
/obj/structure/blob/examine(mob/user)
|
||||
..()
|
||||
var/datum/atom_hud/hud_to_check = huds[DATA_HUD_MEDICAL_ADVANCED]
|
||||
var/datum/atom_hud/hud_to_check = GLOB.huds[DATA_HUD_MEDICAL_ADVANCED]
|
||||
if(user.research_scanner || (user in hud_to_check.hudusers))
|
||||
to_chat(user, "<b>Your HUD displays an extensive report...</b><br>")
|
||||
chemeffectreport(user)
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
changeling = null
|
||||
. = ..()
|
||||
|
||||
/datum/cellular_emporium/ui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/ui_state/state = always_state)
|
||||
/datum/cellular_emporium/ui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/ui_state/state = GLOB.always_state)
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "cellular_emporium", name, 900, 480, master_ui, state)
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
#define LING_DEAD_GENETICDAMAGE_HEAL_CAP 50 //The lowest value of geneticdamage handle_changeling() can take it to while dead.
|
||||
#define LING_ABSORB_RECENT_SPEECH 8 //The amount of recent spoken lines to gain on absorbing a mob
|
||||
|
||||
var/list/possible_changeling_IDs = list("Alpha","Beta","Gamma","Delta","Epsilon","Zeta","Eta","Theta","Iota","Kappa","Lambda","Mu","Nu","Xi","Omicron","Pi","Rho","Sigma","Tau","Upsilon","Phi","Chi","Psi","Omega")
|
||||
var/list/slots = list("head", "wear_mask", "back", "wear_suit", "w_uniform", "shoes", "belt", "gloves", "glasses", "ears", "wear_id", "s_store")
|
||||
var/list/slot2slot = list("head" = slot_head, "wear_mask" = slot_wear_mask, "neck" = slot_neck, "back" = slot_back, "wear_suit" = slot_wear_suit, "w_uniform" = slot_w_uniform, "shoes" = slot_shoes, "belt" = slot_belt, "gloves" = slot_gloves, "glasses" = slot_glasses, "ears" = slot_ears, "wear_id" = slot_wear_id, "s_store" = slot_s_store)
|
||||
var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mask" = /obj/item/clothing/mask/changeling, "back" = /obj/item/changeling, "wear_suit" = /obj/item/clothing/suit/changeling, "w_uniform" = /obj/item/clothing/under/changeling, "shoes" = /obj/item/clothing/shoes/changeling, "belt" = /obj/item/changeling, "gloves" = /obj/item/clothing/gloves/changeling, "glasses" = /obj/item/clothing/glasses/changeling, "ears" = /obj/item/changeling, "wear_id" = /obj/item/changeling, "s_store" = /obj/item/changeling)
|
||||
GLOBAL_LIST_INIT(possible_changeling_IDs, list("Alpha","Beta","Gamma","Delta","Epsilon","Zeta","Eta","Theta","Iota","Kappa","Lambda","Mu","Nu","Xi","Omicron","Pi","Rho","Sigma","Tau","Upsilon","Phi","Chi","Psi","Omega"))
|
||||
GLOBAL_LIST_INIT(slots, list("head", "wear_mask", "back", "wear_suit", "w_uniform", "shoes", "belt", "gloves", "glasses", "ears", "wear_id", "s_store"))
|
||||
GLOBAL_LIST_INIT(slot2slot, list("head" = slot_head, "wear_mask" = slot_wear_mask, "neck" = slot_neck, "back" = slot_back, "wear_suit" = slot_wear_suit, "w_uniform" = slot_w_uniform, "shoes" = slot_shoes, "belt" = slot_belt, "gloves" = slot_gloves, "glasses" = slot_glasses, "ears" = slot_ears, "wear_id" = slot_wear_id, "s_store" = slot_s_store))
|
||||
GLOBAL_LIST_INIT(slot2type, list("head" = /obj/item/clothing/head/changeling, "wear_mask" = /obj/item/clothing/mask/changeling, "back" = /obj/item/changeling, "wear_suit" = /obj/item/clothing/suit/changeling, "w_uniform" = /obj/item/clothing/under/changeling, "shoes" = /obj/item/clothing/shoes/changeling, "belt" = /obj/item/changeling, "gloves" = /obj/item/clothing/gloves/changeling, "glasses" = /obj/item/clothing/glasses/changeling, "ears" = /obj/item/changeling, "wear_id" = /obj/item/changeling, "s_store" = /obj/item/changeling))
|
||||
|
||||
|
||||
/datum/game_mode
|
||||
@@ -96,15 +96,15 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
|
||||
changeling.current.make_changeling()
|
||||
forge_changeling_objectives(changeling)
|
||||
greet_changeling(changeling)
|
||||
ticker.mode.update_changeling_icons_added(changeling)
|
||||
SSticker.mode.update_changeling_icons_added(changeling)
|
||||
modePlayer += changelings
|
||||
..()
|
||||
|
||||
/datum/game_mode/changeling/make_antag_chance(mob/living/carbon/human/character) //Assigns changeling to latejoiners
|
||||
var/changelingcap = min( round(joined_player_list.len/(config.changeling_scaling_coeff*2))+2, round(joined_player_list.len/config.changeling_scaling_coeff) )
|
||||
if(ticker.mode.changelings.len >= changelingcap) //Caps number of latejoin antagonists
|
||||
var/changelingcap = min( round(GLOB.joined_player_list.len/(config.changeling_scaling_coeff*2))+2, round(GLOB.joined_player_list.len/config.changeling_scaling_coeff) )
|
||||
if(SSticker.mode.changelings.len >= changelingcap) //Caps number of latejoin antagonists
|
||||
return
|
||||
if(ticker.mode.changelings.len <= (changelingcap - 2) || prob(100 - (config.changeling_scaling_coeff*2)))
|
||||
if(SSticker.mode.changelings.len <= (changelingcap - 2) || prob(100 - (config.changeling_scaling_coeff*2)))
|
||||
if(ROLE_CHANGELING in character.client.prefs.be_special)
|
||||
if(!jobban_isbanned(character, ROLE_CHANGELING) && !jobban_isbanned(character, "Syndicate"))
|
||||
if(age_check(character.client))
|
||||
@@ -136,7 +136,7 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
|
||||
changeling.objectives += steal_objective
|
||||
|
||||
var/list/active_ais = active_ais()
|
||||
if(active_ais.len && prob(100/joined_player_list.len))
|
||||
if(active_ais.len && prob(100/GLOB.joined_player_list.len))
|
||||
var/datum/objective/destroy/destroy_objective = new
|
||||
destroy_objective.owner = changeling
|
||||
destroy_objective.find_target()
|
||||
@@ -307,9 +307,9 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
|
||||
honorific = "Ms."
|
||||
else
|
||||
honorific = "Mr."
|
||||
if(possible_changeling_IDs.len)
|
||||
changelingID = pick(possible_changeling_IDs)
|
||||
possible_changeling_IDs -= changelingID
|
||||
if(GLOB.possible_changeling_IDs.len)
|
||||
changelingID = pick(GLOB.possible_changeling_IDs)
|
||||
GLOB.possible_changeling_IDs -= changelingID
|
||||
changelingID = "[honorific] [changelingID]"
|
||||
else
|
||||
changelingID = "[honorific] [rand(1,999)]"
|
||||
@@ -450,22 +450,22 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
|
||||
user.domutcheck()
|
||||
|
||||
//vars hackery. not pretty, but better than the alternative.
|
||||
for(var/slot in slots)
|
||||
if(istype(user.vars[slot], slot2type[slot]) && !(chosen_prof.exists_list[slot])) //remove unnecessary flesh items
|
||||
for(var/slot in GLOB.slots)
|
||||
if(istype(user.vars[slot], GLOB.slot2type[slot]) && !(chosen_prof.exists_list[slot])) //remove unnecessary flesh items
|
||||
qdel(user.vars[slot])
|
||||
continue
|
||||
|
||||
if((user.vars[slot] && !istype(user.vars[slot], slot2type[slot])) || !(chosen_prof.exists_list[slot]))
|
||||
if((user.vars[slot] && !istype(user.vars[slot], GLOB.slot2type[slot])) || !(chosen_prof.exists_list[slot]))
|
||||
continue
|
||||
|
||||
var/obj/item/C
|
||||
var/equip = 0
|
||||
if(!user.vars[slot])
|
||||
var/thetype = slot2type[slot]
|
||||
var/thetype = GLOB.slot2type[slot]
|
||||
equip = 1
|
||||
C = new thetype(user)
|
||||
|
||||
else if(istype(user.vars[slot], slot2type[slot]))
|
||||
else if(istype(user.vars[slot], GLOB.slot2type[slot]))
|
||||
C = user.vars[slot]
|
||||
|
||||
C.appearance = chosen_prof.appearance_list[slot]
|
||||
@@ -474,7 +474,7 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
|
||||
C.item_color = chosen_prof.item_color_list[slot]
|
||||
C.item_state = chosen_prof.item_state_list[slot]
|
||||
if(equip)
|
||||
user.equip_to_slot_or_del(C, slot2slot[slot])
|
||||
user.equip_to_slot_or_del(C, GLOB.slot2slot[slot])
|
||||
|
||||
user.regenerate_icons()
|
||||
|
||||
@@ -515,11 +515,11 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
|
||||
newprofile.socks = socks
|
||||
|
||||
/datum/game_mode/proc/update_changeling_icons_added(datum/mind/changling_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_CHANGELING]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_CHANGELING]
|
||||
hud.join_hud(changling_mind.current)
|
||||
set_antag_hud(changling_mind.current, "changling")
|
||||
|
||||
/datum/game_mode/proc/update_changeling_icons_removed(datum/mind/changling_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_CHANGELING]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_CHANGELING]
|
||||
hud.leave_hud(changling_mind.current)
|
||||
set_antag_hud(changling_mind.current, null)
|
||||
|
||||
@@ -19,8 +19,9 @@
|
||||
var/ignores_fakedeath = FALSE // usable with the FAKEDEATH flag
|
||||
|
||||
|
||||
/obj/effect/proc_holder/changeling/proc/on_purchase(mob/user)
|
||||
return
|
||||
/obj/effect/proc_holder/changeling/proc/on_purchase(mob/user, is_respec)
|
||||
if(!is_respec)
|
||||
feedback_add_details("changeling_power_purchase",name)
|
||||
|
||||
/obj/effect/proc_holder/changeling/proc/on_refund(mob/user)
|
||||
return
|
||||
@@ -36,6 +37,7 @@
|
||||
return
|
||||
var/datum/changeling/c = user.mind.changeling
|
||||
if(sting_action(user, target))
|
||||
feedback_add_details("changeling_powers",name)
|
||||
sting_feedback(user, target)
|
||||
take_chemical_cost(c)
|
||||
|
||||
|
||||
@@ -3,11 +3,12 @@
|
||||
var/obj/effect/proc_holder/changeling/thepower = null
|
||||
|
||||
for(var/path in subtypesof(/obj/effect/proc_holder/changeling))
|
||||
var/obj/effect/proc_holder/changeling/S = new path()
|
||||
if(S.name == sting_name)
|
||||
thepower = S
|
||||
var/obj/effect/proc_holder/changeling/S = path
|
||||
if(initial(S.name) == sting_name)
|
||||
thepower = new path()
|
||||
break
|
||||
|
||||
if(thepower == null)
|
||||
if(!thepower)
|
||||
to_chat(user, "This is awkward. Changeling power purchase failed, please report this bug to a coder!")
|
||||
return
|
||||
|
||||
@@ -44,13 +45,13 @@
|
||||
to_chat(user, "<span class='notice'>We have removed our evolutions from this form, and are now ready to readapt.</span>")
|
||||
user.remove_changeling_powers(1)
|
||||
canrespec = 0
|
||||
user.make_changeling()
|
||||
user.make_changeling(TRUE)
|
||||
return 1
|
||||
else
|
||||
to_chat(user, "<span class='danger'>You lack the power to readapt your evolutions!</span>")
|
||||
return 0
|
||||
|
||||
/mob/proc/make_changeling()
|
||||
/mob/proc/make_changeling(is_respec)
|
||||
if(!mind)
|
||||
return
|
||||
if(!ishuman(src) && !ismonkey(src))
|
||||
@@ -65,7 +66,9 @@
|
||||
if(!S.dna_cost)
|
||||
if(!mind.changeling.has_sting(S))
|
||||
mind.changeling.purchasedpowers+=S
|
||||
S.on_purchase(src)
|
||||
S.on_purchase(src, is_respec)
|
||||
if(is_respec)
|
||||
feedback_add_details("changeling_power_purchase","Readapt")
|
||||
|
||||
var/mob/living/carbon/C = src //only carbons have dna now, so we have to typecaste
|
||||
if(ishuman(C))
|
||||
|
||||
@@ -31,8 +31,8 @@
|
||||
var/datum/changeling/changeling = user.mind.changeling
|
||||
var/mob/living/carbon/human/target = user.pulling
|
||||
changeling.isabsorbing = 1
|
||||
for(var/stage = 1, stage<=3, stage++)
|
||||
switch(stage)
|
||||
for(var/i in 1 to 3)
|
||||
switch(i)
|
||||
if(1)
|
||||
to_chat(user, "<span class='notice'>This creature is compatible. We must hold still...</span>")
|
||||
if(2)
|
||||
@@ -42,12 +42,13 @@
|
||||
to_chat(target, "<span class='userdanger'>You feel a sharp stabbing pain!</span>")
|
||||
target.take_overall_damage(40)
|
||||
|
||||
feedback_add_details("changeling_powers","A[stage]")
|
||||
feedback_add_details("changeling_powers","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
|
||||
|
||||
feedback_add_details("changeling_powers","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>")
|
||||
|
||||
@@ -99,7 +100,7 @@
|
||||
|
||||
target.death(0)
|
||||
target.Drain()
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -17,6 +17,5 @@
|
||||
user.reagents.add_reagent("changelingAdrenaline", 10)
|
||||
user.reagents.add_reagent("changelingAdrenaline2", 2) //For a really quick burst of speed
|
||||
user.adjustStaminaLoss(-75)
|
||||
feedback_add_details("changeling_powers","UNS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
|
||||
@@ -53,9 +53,7 @@
|
||||
addtimer(CALLBACK(src, .proc/dissolve_cocoon, user, C), 25) //Very short because it's just webs
|
||||
used = TRUE
|
||||
|
||||
if(used)
|
||||
feedback_add_details("changeling_powers","BD")
|
||||
return 1
|
||||
return used
|
||||
|
||||
/obj/effect/proc_holder/changeling/biodegrade/proc/dissolve_handcuffs(mob/living/carbon/human/user, obj/O)
|
||||
if(O && user.handcuffed == O)
|
||||
|
||||
@@ -13,18 +13,16 @@
|
||||
var/mob/living/carbon/human/H = user //SHOULD always be human, because req_human = 1
|
||||
if(!istype(H)) // req_human could be done in can_sting stuff.
|
||||
return
|
||||
var/datum/mutation/human/HM = mutations_list[CHAMELEON]
|
||||
var/datum/mutation/human/HM = GLOB.mutations_list[CHAMELEON]
|
||||
if(HM in H.dna.mutations)
|
||||
HM.force_lose(H)
|
||||
else
|
||||
HM.force_give(H)
|
||||
|
||||
feedback_add_details("changeling_powers","CS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/chameleon_skin/on_refund(mob/user)
|
||||
if(user.has_dna())
|
||||
var/mob/living/carbon/C = user
|
||||
var/datum/mutation/human/HM = mutations_list[CHAMELEON]
|
||||
var/datum/mutation/human/HM = GLOB.mutations_list[CHAMELEON]
|
||||
if(HM in C.dna.mutations)
|
||||
HM.force_lose(C)
|
||||
@@ -15,10 +15,7 @@
|
||||
to_chat(user, "<span class='notice'>We distort our form to hide from the AI</span>")
|
||||
user.digitalcamo = 1
|
||||
user.digitalinvis = 1
|
||||
|
||||
|
||||
feedback_add_details("changeling_powers","CAM")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/digitalcamo/on_refund(mob/user)
|
||||
user.digitalcamo = 0
|
||||
|
||||
@@ -19,9 +19,7 @@
|
||||
user.update_canmove()
|
||||
|
||||
addtimer(CALLBACK(src, .proc/ready_to_regenerate, user), LING_FAKEDEATH_TIME, TIMER_UNIQUE)
|
||||
|
||||
feedback_add_details("changeling_powers","FD")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/fakedeath/proc/ready_to_regenerate(mob/user)
|
||||
if(user && user.mind && user.mind.changeling && user.mind.changeling.purchasedpowers)
|
||||
|
||||
@@ -1,11 +1,7 @@
|
||||
/obj/effect/proc_holder/changeling/fleshmend
|
||||
name = "Fleshmend"
|
||||
desc = "Our flesh rapidly regenerates, healing our burns, bruises and \
|
||||
shortness of breath. Effectiveness decreases with quick, \
|
||||
repeated use."
|
||||
helptext = "Heals a moderate amount of damage over a short period of \
|
||||
time. Can be used while unconscious. Does not regrow limbs or \
|
||||
restore lost blood."
|
||||
desc = "Our flesh rapidly regenerates, healing our burns, bruises and shortness of breath. Effectiveness decreases with quick, repeated use."
|
||||
helptext = "Heals a moderate amount of damage over a short period of time. Can be used while unconscious. Does not regrow limbs or restore lost blood."
|
||||
chemical_cost = 20
|
||||
dna_cost = 2
|
||||
req_stat = UNCONSCIOUS
|
||||
@@ -37,9 +33,7 @@
|
||||
|
||||
recent_uses++
|
||||
INVOKE_ASYNC(src, .proc/fleshmend, user)
|
||||
|
||||
feedback_add_details("changeling_powers","RR")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/fleshmend/proc/fleshmend(mob/living/user)
|
||||
|
||||
|
||||
@@ -26,7 +26,6 @@
|
||||
S.Weaken(3)
|
||||
var/turf = get_turf(user)
|
||||
user.gib()
|
||||
feedback_add_details("changeling_powers","LR")
|
||||
. = TRUE
|
||||
sleep(5) // So it's not killed in explosion
|
||||
var/mob/living/simple_animal/hostile/headcrab/crab = new(turf)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
dna_cost = 0
|
||||
chemical_cost = -1
|
||||
|
||||
/obj/effect/proc_holder/changeling/hivemind_comms/on_purchase(var/mob/user)
|
||||
/obj/effect/proc_holder/changeling/hivemind_comms/on_purchase(mob/user, is_respec)
|
||||
..()
|
||||
var/datum/changeling/changeling=user.mind.changeling
|
||||
changeling.changeling_speak = 1
|
||||
@@ -17,10 +17,9 @@
|
||||
var/obj/effect/proc_holder/changeling/hivemind_download/S2 = new
|
||||
if(!changeling.has_sting(S2))
|
||||
changeling.purchasedpowers+=S2
|
||||
return
|
||||
|
||||
// HIVE MIND UPLOAD/DOWNLOAD DNA
|
||||
var/list/datum/dna/hivemind_bank = list()
|
||||
GLOBAL_LIST_EMPTY(hivemind_bank)
|
||||
|
||||
/obj/effect/proc_holder/changeling/hivemind_upload
|
||||
name = "Hive Channel DNA"
|
||||
@@ -32,7 +31,7 @@ var/list/datum/dna/hivemind_bank = list()
|
||||
var/datum/changeling/changeling = user.mind.changeling
|
||||
var/list/names = list()
|
||||
for(var/datum/changelingprofile/prof in changeling.stored_profiles)
|
||||
if(!(prof in hivemind_bank))
|
||||
if(!(prof in GLOB.hivemind_bank))
|
||||
names += prof.name
|
||||
|
||||
if(names.len <= 0)
|
||||
@@ -49,10 +48,9 @@ var/list/datum/dna/hivemind_bank = list()
|
||||
|
||||
var/datum/changelingprofile/uploaded_dna = new chosen_dna.type
|
||||
chosen_dna.copy_profile(uploaded_dna)
|
||||
hivemind_bank += uploaded_dna
|
||||
GLOB.hivemind_bank += uploaded_dna
|
||||
to_chat(user, "<span class='notice'>We channel the DNA of [chosen_name] to the air.</span>")
|
||||
feedback_add_details("changeling_powers","HU")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/hivemind_download
|
||||
name = "Hive Absorb DNA"
|
||||
@@ -73,7 +71,7 @@ var/list/datum/dna/hivemind_bank = list()
|
||||
/obj/effect/proc_holder/changeling/hivemind_download/sting_action(mob/user)
|
||||
var/datum/changeling/changeling = user.mind.changeling
|
||||
var/list/names = list()
|
||||
for(var/datum/changelingprofile/prof in hivemind_bank)
|
||||
for(var/datum/changelingprofile/prof in GLOB.hivemind_bank)
|
||||
if(!(prof in changeling.stored_profiles))
|
||||
names[prof.name] = prof
|
||||
|
||||
@@ -92,5 +90,4 @@ var/list/datum/dna/hivemind_bank = list()
|
||||
chosen_prof.copy_profile(downloaded_prof)
|
||||
changeling.add_profile(downloaded_prof)
|
||||
to_chat(user, "<span class='notice'>We absorb the DNA of [S] from the air.</span>")
|
||||
feedback_add_details("changeling_powers","HD")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/obj/effect/proc_holder/changeling/humanform
|
||||
name = "Human form"
|
||||
name = "Human Form"
|
||||
desc = "We change into a human."
|
||||
chemical_cost = 5
|
||||
genetic_damage = 3
|
||||
@@ -30,5 +30,4 @@
|
||||
var/newmob = user.humanize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS)
|
||||
|
||||
changeling_transform(newmob, chosen_prof)
|
||||
feedback_add_details("changeling_powers","LFT")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/obj/effect/proc_holder/changeling/lesserform
|
||||
name = "Lesser form"
|
||||
name = "Lesser Form"
|
||||
desc = "We debase ourselves and become lesser. We become a monkey."
|
||||
chemical_cost = 5
|
||||
dna_cost = 1
|
||||
@@ -13,6 +13,4 @@
|
||||
to_chat(user, "<span class='warning'>Our genes cry out!</span>")
|
||||
|
||||
user.monkeyize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS | TR_KEEPSE)
|
||||
|
||||
feedback_add_details("changeling_powers","LF")
|
||||
return 1
|
||||
return TRUE
|
||||
@@ -48,7 +48,7 @@
|
||||
if(3)
|
||||
to_chat(user, "<span class='notice'>We mold the [target]'s mind like clay, granting [target.p_them()] the ability to speak in the hivemind!</span>")
|
||||
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/mob/M in mob_list)
|
||||
for(var/mob/M in GLOB.mob_list)
|
||||
if(M.lingcheck() == 2)
|
||||
to_chat(M, "<i><font color=#800080>We can sense a foreign presence in the hivemind...</font></i>")
|
||||
target.mind.linglink = 1
|
||||
@@ -56,7 +56,7 @@
|
||||
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)
|
||||
feedback_add_details("changeling_powers","A [i]")
|
||||
feedback_add_details("changeling_powers","Hivemind Link|[i]")
|
||||
if(!do_mob(user, target, 20))
|
||||
to_chat(user, "<span class='warning'>Our link with [target] has ended!</span>")
|
||||
changeling.islinking = 0
|
||||
|
||||
@@ -24,5 +24,4 @@
|
||||
changeling.chem_recharge_slowdown += 0.5
|
||||
to_chat(user, "<span class='notice'>We shape our glands to take the voice of <b>[mimic_voice]</b>, this will slow down regenerating chemicals while active.</span>")
|
||||
to_chat(user, "<span class='notice'>Use this power again to return to our original voice and return chemical production to normal levels.</span>")
|
||||
|
||||
feedback_add_details("changeling_powers","MV")
|
||||
return TRUE
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
Space Suit
|
||||
Shield
|
||||
Armor
|
||||
Tentacles
|
||||
*/
|
||||
|
||||
|
||||
@@ -125,7 +126,7 @@
|
||||
|
||||
var/datum/changeling/changeling = user.mind.changeling
|
||||
changeling.chem_recharge_slowdown += recharge_slowdown
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
|
||||
//fancy headers yo
|
||||
@@ -228,7 +229,7 @@
|
||||
desc = "A fleshy tentacle that can stretch out and grab things or people."
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
icon_state = "tentacle"
|
||||
item_state = null
|
||||
item_state = "tentacle"
|
||||
flags = ABSTRACT | NODROP | DROPDEL | NOBLUDGEON
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
ammo_type = /obj/item/ammo_casing/magic/tentacle
|
||||
@@ -251,6 +252,11 @@
|
||||
/obj/item/weapon/gun/magic/tentacle/shoot_with_empty_chamber(mob/living/user as mob|obj)
|
||||
to_chat(user, "<span class='warning'>The [name] is not ready yet.<span>")
|
||||
|
||||
/obj/item/weapon/gun/magic/tentacle/suicide_act(mob/user)
|
||||
user.visible_message("<span class='suicide'>[user] coils [src] tightly around [user.p_their()] neck! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
||||
return (OXYLOSS)
|
||||
|
||||
|
||||
/obj/item/ammo_casing/magic/tentacle
|
||||
name = "tentacle"
|
||||
desc = "a tentacle."
|
||||
@@ -336,11 +342,11 @@
|
||||
var/obj/item/I = C.get_active_held_item()
|
||||
if(I)
|
||||
if(C.drop_item())
|
||||
C.visible_message("<span class='danger'>[I] is yanked off of [C]'s hand by [src]!</span>","<span class='userdanger'>A tentacle pulls [I] away from you!</span>")
|
||||
C.visible_message("<span class='danger'>[I] is yanked off [C]'s hand by [src]!</span>","<span class='userdanger'>A tentacle pulls [I] away from you!</span>")
|
||||
on_hit(I) //grab the item as if you had hit it directly with the tentacle
|
||||
return 1
|
||||
else
|
||||
to_chat(firer, "<span class='danger'>You can't seem to pry [I] off of [C]'s hands!<span>")
|
||||
to_chat(firer, "<span class='danger'>You can't seem to pry [I] off [C]'s hands!<span>")
|
||||
return 0
|
||||
else
|
||||
to_chat(firer, "<span class='danger'>[C] has nothing in hand to disarm!<span>")
|
||||
@@ -389,7 +395,7 @@
|
||||
|
||||
var/obj/item/weapon/shield/changeling/S = ..(user)
|
||||
S.remaining_uses = round(changeling.absorbedcount * 3)
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/item/weapon/shield/changeling
|
||||
name = "shield-like mass"
|
||||
|
||||
@@ -41,5 +41,4 @@
|
||||
|
||||
for(var/datum/disease/D in user.viruses)
|
||||
D.cure()
|
||||
feedback_add_details("changeling_powers","AP")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
@@ -31,3 +31,4 @@
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.restore_blood()
|
||||
H.remove_all_embedded_objects()
|
||||
return TRUE
|
||||
|
||||
@@ -26,8 +26,7 @@
|
||||
user.regenerate_organs()
|
||||
to_chat(user, "<span class='notice'>We have revived ourselves.</span>")
|
||||
user.mind.changeling.purchasedpowers -= src
|
||||
feedback_add_details("changeling_powers","CR")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/revive/can_be_used_by(mob/user)
|
||||
if((user.stat != DEAD) && !(user.status_flags & FAKEDEATH))
|
||||
|
||||
@@ -24,9 +24,7 @@
|
||||
for(var/obj/machinery/light/L in range(4, user))
|
||||
L.on = 1
|
||||
L.break_light_tube()
|
||||
|
||||
feedback_add_details("changeling_powers","RS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/dissonant_shriek
|
||||
name = "Dissonant Shriek"
|
||||
@@ -40,6 +38,4 @@
|
||||
L.on = 1
|
||||
L.break_light_tube()
|
||||
empulse(get_turf(user), 2, 5, 1)
|
||||
return 1
|
||||
|
||||
|
||||
return TRUE
|
||||
|
||||
@@ -9,5 +9,4 @@
|
||||
//Makes some spiderlings. Good for setting traps and causing general trouble.
|
||||
/obj/effect/proc_holder/changeling/spiders/sting_action(mob/user)
|
||||
spawn_atom_to_turf(/obj/structure/spider/spiderling/hunter, user, 2, FALSE)
|
||||
feedback_add_details("changeling_powers","SI")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
@@ -23,6 +23,11 @@
|
||||
user.Weaken(3)
|
||||
user.emote("gasp")
|
||||
|
||||
INVOKE_ASYNC(src, .proc/muscle_loop, user)
|
||||
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/strained_muscles/proc/muscle_loop(mob/living/carbon/user)
|
||||
while(active)
|
||||
user.status_flags |= GOTTAGOFAST
|
||||
if(user.stat != CONSCIOUS || user.staminaloss >= 90)
|
||||
@@ -41,10 +46,6 @@
|
||||
|
||||
sleep(40)
|
||||
|
||||
while(!active) //Damage stacks decrease fairly rapidly while not in sanic mode
|
||||
if(stacks >= 1)
|
||||
stacks--
|
||||
while(!active && stacks) //Damage stacks decrease fairly rapidly while not in sanic mode
|
||||
stacks--
|
||||
sleep(20)
|
||||
|
||||
feedback_add_details("changeling_powers","SANIC")
|
||||
return 1
|
||||
|
||||
@@ -101,10 +101,9 @@
|
||||
C.take_bodypart_damage(20, 0) //The process is extremely painful
|
||||
|
||||
target.visible_message("<span class='danger'>[target] begins to violenty convulse!</span>","<span class='userdanger'>You feel a tiny prick and a begin to uncontrollably convulse!</span>")
|
||||
feedback_add_details("changeling_powers","TS")
|
||||
. = TRUE
|
||||
sleep(10)
|
||||
if(istype(C))
|
||||
sleep(10)
|
||||
C.real_name = NewDNA.real_name
|
||||
NewDNA.transfer_identity(C, transfer_SE=1)
|
||||
C.updateappearance(mutcolor_update=1)
|
||||
@@ -152,9 +151,7 @@
|
||||
playsound(target, 'sound/effects/blobattack.ogg', 30, 1)
|
||||
|
||||
addtimer(CALLBACK(src, .proc/remove_fake, target, blade), 600)
|
||||
|
||||
feedback_add_details("changeling_powers","AS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/sting/false_armblade/proc/remove_fake(mob/target, obj/item/weapon/melee/arm_blade/false/blade)
|
||||
playsound(target, 'sound/effects/blobattack.ogg', 30, 1)
|
||||
@@ -182,8 +179,7 @@
|
||||
add_logs(user, target, "stung", "extraction sting")
|
||||
if(!(user.mind.changeling.has_dna(target.dna)))
|
||||
user.mind.changeling.add_new_profile(target, user)
|
||||
feedback_add_details("changeling_powers","ED")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/sting/mute
|
||||
name = "Mute Sting"
|
||||
@@ -196,8 +192,7 @@
|
||||
/obj/effect/proc_holder/changeling/sting/mute/sting_action(mob/user, mob/living/carbon/target)
|
||||
add_logs(user, target, "stung", "mute sting")
|
||||
target.silent += 30
|
||||
feedback_add_details("changeling_powers","MS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/sting/blind
|
||||
name = "Blind Sting"
|
||||
@@ -213,8 +208,7 @@
|
||||
target.become_nearsighted()
|
||||
target.blind_eyes(20)
|
||||
target.blur_eyes(40)
|
||||
feedback_add_details("changeling_powers","BS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/sting/LSD
|
||||
name = "Hallucination Sting"
|
||||
@@ -227,8 +221,7 @@
|
||||
/obj/effect/proc_holder/changeling/sting/LSD/sting_action(mob/user, mob/living/carbon/target)
|
||||
add_logs(user, target, "stung", "LSD sting")
|
||||
addtimer(CALLBACK(src, .proc/hallucination_time, target), rand(300,600))
|
||||
feedback_add_details("changeling_powers","HS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/obj/effect/proc_holder/changeling/sting/LSD/proc/hallucination_time(mob/living/carbon/target)
|
||||
if(target)
|
||||
@@ -246,5 +239,4 @@
|
||||
add_logs(user, target, "stung", "cryo sting")
|
||||
if(target.reagents)
|
||||
target.reagents.add_reagent("frostoil", 30)
|
||||
feedback_add_details("changeling_powers","CS")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
@@ -107,9 +107,7 @@
|
||||
return
|
||||
|
||||
changeling_transform(user, chosen_prof)
|
||||
|
||||
feedback_add_details("changeling_powers","TR")
|
||||
return 1
|
||||
return TRUE
|
||||
|
||||
/datum/changeling/proc/select_dna(var/prompt, var/title, var/mob/living/carbon/user)
|
||||
var/list/names = list("Drop Flesh Disguise")
|
||||
@@ -121,8 +119,8 @@
|
||||
return
|
||||
|
||||
if(chosen_name == "Drop Flesh Disguise")
|
||||
for(var/slot in slots)
|
||||
if(istype(user.vars[slot], slot2type[slot]))
|
||||
for(var/slot in GLOB.slots)
|
||||
if(istype(user.vars[slot], GLOB.slot2type[slot]))
|
||||
qdel(user.vars[slot])
|
||||
|
||||
var/datum/changelingprofile/prof = get_dna(chosen_name)
|
||||
|
||||
@@ -58,16 +58,16 @@
|
||||
changeling.current.make_changeling()
|
||||
forge_changeling_objectives(changeling)
|
||||
greet_changeling(changeling)
|
||||
ticker.mode.update_changeling_icons_added(changeling)
|
||||
SSticker.mode.update_changeling_icons_added(changeling)
|
||||
..()
|
||||
return
|
||||
|
||||
/datum/game_mode/traitor/changeling/make_antag_chance(mob/living/carbon/human/character) //Assigns changeling to latejoiners
|
||||
var/changelingcap = min( round(joined_player_list.len/(config.changeling_scaling_coeff*4))+2, round(joined_player_list.len/(config.changeling_scaling_coeff*2)) )
|
||||
if(ticker.mode.changelings.len >= changelingcap) //Caps number of latejoin antagonists
|
||||
var/changelingcap = min( round(GLOB.joined_player_list.len/(config.changeling_scaling_coeff*4))+2, round(GLOB.joined_player_list.len/(config.changeling_scaling_coeff*2)) )
|
||||
if(SSticker.mode.changelings.len >= changelingcap) //Caps number of latejoin antagonists
|
||||
..()
|
||||
return
|
||||
if(ticker.mode.changelings.len <= (changelingcap - 2) || prob(100 / (config.changeling_scaling_coeff * 4)))
|
||||
if(SSticker.mode.changelings.len <= (changelingcap - 2) || prob(100 / (config.changeling_scaling_coeff * 4)))
|
||||
if(ROLE_CHANGELING in character.client.prefs.be_special)
|
||||
if(!jobban_isbanned(character, ROLE_CHANGELING) && !jobban_isbanned(character, "Syndicate"))
|
||||
if(age_check(character.client))
|
||||
|
||||
@@ -84,7 +84,6 @@ Credit where due:
|
||||
|
||||
/datum/game_mode
|
||||
var/list/servants_of_ratvar = list() //The Enlightened servants of Ratvar
|
||||
var/clockwork_objective = CLOCKCULT_GATEWAY //The objective that the servants must fulfill
|
||||
var/clockwork_explanation = "Construct a Gateway to the Celestial Derelict and free Ratvar." //The description of the current objective
|
||||
|
||||
/datum/game_mode/clockwork_cult
|
||||
@@ -126,7 +125,6 @@ Credit where due:
|
||||
return 1
|
||||
|
||||
/datum/game_mode/clockwork_cult/post_setup()
|
||||
forge_clock_objectives()
|
||||
for(var/S in servants_to_serve)
|
||||
var/datum/mind/servant = S
|
||||
log_game("[servant.key] was made an initial servant of Ratvar")
|
||||
@@ -137,16 +135,6 @@ Credit where due:
|
||||
..()
|
||||
return 1
|
||||
|
||||
/datum/game_mode/clockwork_cult/proc/forge_clock_objectives() //Determine what objective that Ratvar's servants will fulfill
|
||||
var/list/possible_objectives = list(CLOCKCULT_ESCAPE, CLOCKCULT_GATEWAY)
|
||||
clockwork_objective = pick(possible_objectives)
|
||||
switch(clockwork_objective)
|
||||
if(CLOCKCULT_ESCAPE)
|
||||
clockwork_explanation = "Construct a Gateway to the Celestial Derelict and proselytize the entire station."
|
||||
if(CLOCKCULT_GATEWAY)
|
||||
clockwork_explanation = "Construct a Gateway to the Celestial Derelict and free Ratvar."
|
||||
return 1
|
||||
|
||||
/datum/game_mode/clockwork_cult/proc/greet_servant(mob/M) //Description of their role
|
||||
if(!M)
|
||||
return 0
|
||||
@@ -182,21 +170,18 @@ Credit where due:
|
||||
if(!L || !istype(L) || !L.mind)
|
||||
return 0
|
||||
var/datum/mind/M = L.mind
|
||||
to_chat(M.current, "<b>This is Ratvar's will:</b> [clockwork_explanation]")
|
||||
M.memory += "<b>Ratvar's will:</b> [clockwork_explanation]<br>"
|
||||
to_chat(M.current, "<b>This is Ratvar's will:</b> [CLOCKCULT_OBJECTIVE]")
|
||||
M.memory += "<b>Ratvar's will:</b> [CLOCKCULT_OBJECTIVE]<br>"
|
||||
return 1
|
||||
|
||||
/datum/game_mode/clockwork_cult/proc/check_clockwork_victory()
|
||||
switch(clockwork_objective)
|
||||
if(CLOCKCULT_ESCAPE)
|
||||
if(clockwork_gateway_activated)
|
||||
ticker.news_report = CLOCK_PROSELYTIZATION
|
||||
return TRUE
|
||||
if(CLOCKCULT_GATEWAY)
|
||||
if(ratvar_awakens)
|
||||
ticker.news_report = CLOCK_SUMMON
|
||||
return TRUE
|
||||
ticker.news_report = CULT_FAILURE
|
||||
if(GLOB.clockwork_gateway_activated)
|
||||
SSticker.news_report = CLOCK_PROSELYTIZATION //failure, technically, but we have the station
|
||||
if(GLOB.ratvar_awakens)
|
||||
SSticker.news_report = CLOCK_SUMMON
|
||||
return TRUE
|
||||
else
|
||||
SSticker.news_report = CULT_FAILURE
|
||||
return FALSE
|
||||
|
||||
/datum/game_mode/clockwork_cult/declare_completion()
|
||||
@@ -205,26 +190,26 @@ Credit where due:
|
||||
|
||||
/datum/game_mode/proc/auto_declare_completion_clockwork_cult()
|
||||
var/text = ""
|
||||
if(istype(ticker.mode, /datum/game_mode/clockwork_cult)) //Possibly hacky?
|
||||
var/datum/game_mode/clockwork_cult/C = ticker.mode
|
||||
if(istype(SSticker.mode, /datum/game_mode/clockwork_cult)) //Possibly hacky?
|
||||
var/datum/game_mode/clockwork_cult/C = SSticker.mode
|
||||
if(C.check_clockwork_victory())
|
||||
text += "<span class='large_brass'><b>Ratvar's servants have succeeded in fulfilling His goals!</b></span>"
|
||||
feedback_set_details("round_end_result", "win - servants completed their objective ([clockwork_objective])")
|
||||
feedback_set_details("round_end_result", "win - servants completed their objective (summon ratvar)")
|
||||
else
|
||||
var/half_victory = FALSE
|
||||
var/obj/structure/destructible/clockwork/massive/celestial_gateway/G = locate() in all_clockwork_objects
|
||||
var/obj/structure/destructible/clockwork/massive/celestial_gateway/G = locate() in GLOB.all_clockwork_objects
|
||||
if(G)
|
||||
half_victory = TRUE
|
||||
if(half_victory)
|
||||
text += "<span class='large_brass'><b>The crew escaped before [clockwork_objective == CLOCKCULT_GATEWAY ? "Ratvar could rise":"the station could be proselytized"], but the gateway \
|
||||
text += "<span class='large_brass'><b>The crew escaped before Ratvar could rise, but the gateway \
|
||||
was successfully constructed!</b></span>"
|
||||
feedback_set_details("round_end_result", "halfwin - servants constructed the gateway but their objective was not completed ([clockwork_objective])")
|
||||
feedback_set_details("round_end_result", "halfwin - servants constructed the gateway but their objective was not completed (summon ratvar)")
|
||||
else
|
||||
text += "<span class='userdanger'>Ratvar's servants have failed!</span>"
|
||||
feedback_set_details("round_end_result", "loss - servants failed their objective ([clockwork_objective])")
|
||||
text += "<br><b>The servants' objective was:</b> <br>[clockwork_explanation]"
|
||||
text += "<br>Ratvar's servants had <b>[clockwork_caches]</b> Tinkerer's Caches."
|
||||
text += "<br><b>Construction Value(CV)</b> was: <b>[clockwork_construction_value]</b>"
|
||||
feedback_set_details("round_end_result", "loss - servants failed their objective (summon ratvar)")
|
||||
text += "<br><b>The servants' objective was:</b> <br>[CLOCKCULT_OBJECTIVE]"
|
||||
text += "<br>Ratvar's servants had <b>[GLOB.clockwork_caches]</b> Tinkerer's Caches."
|
||||
text += "<br><b>Construction Value(CV)</b> was: <b>[GLOB.clockwork_construction_value]</b>"
|
||||
var/list/scripture_states = scripture_unlock_check()
|
||||
for(var/i in scripture_states)
|
||||
if(i != SCRIPTURE_DRIVER)
|
||||
@@ -236,11 +221,11 @@ Credit where due:
|
||||
to_chat(world, text)
|
||||
|
||||
/datum/game_mode/proc/update_servant_icons_added(datum/mind/M)
|
||||
var/datum/atom_hud/antag/A = huds[ANTAG_HUD_CLOCKWORK]
|
||||
var/datum/atom_hud/antag/A = GLOB.huds[ANTAG_HUD_CLOCKWORK]
|
||||
A.join_hud(M.current)
|
||||
set_antag_hud(M.current, "clockwork")
|
||||
|
||||
/datum/game_mode/proc/update_servant_icons_removed(datum/mind/M)
|
||||
var/datum/atom_hud/antag/A = huds[ANTAG_HUD_CLOCKWORK]
|
||||
var/datum/atom_hud/antag/A = GLOB.huds[ANTAG_HUD_CLOCKWORK]
|
||||
A.leave_hud(M.current)
|
||||
set_antag_hud(M.current, null)
|
||||
|
||||
@@ -12,10 +12,10 @@
|
||||
|
||||
/obj/effect/clockwork/New()
|
||||
..()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/effect/clockwork/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/effect/clockwork/examine(mob/user)
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
var/mob/living/carbon/C = L
|
||||
C.silent += 5
|
||||
var/message = "[sigil_name] in [get_area(src)] <span class='sevtug'>[is_servant_of_ratvar(L) ? "successfully converted" : "failed to convert"]</span>"
|
||||
for(var/M in mob_list)
|
||||
for(var/M in GLOB.mob_list)
|
||||
if(isobserver(M))
|
||||
var/link = FOLLOW_LINK(M, L)
|
||||
to_chat(M, "[link] <span class='heavy_brass'>[message] [L.real_name]!</span>")
|
||||
@@ -198,7 +198,7 @@
|
||||
var/structure_number = 0
|
||||
for(var/obj/structure/destructible/clockwork/powered/P in range(SIGIL_ACCESS_RANGE, src))
|
||||
structure_number++
|
||||
to_chat(user, "<span class='[power_charge ? "brass":"alloy"]'>It is storing <b>[ratvar_awakens ? "INFINITY":"[power_charge]"]W</b> of power, \
|
||||
to_chat(user, "<span class='[power_charge ? "brass":"alloy"]'>It is storing <b>[GLOB.ratvar_awakens ? "INFINITY":"[power_charge]"]W</b> of power, \
|
||||
and <b>[structure_number]</b> Clockwork Structure[structure_number == 1 ? "":"s"] [structure_number == 1 ? "is":"are"] in range.</span>")
|
||||
if(iscyborg(user))
|
||||
to_chat(user, "<span class='brass'>You can recharge from the [sigil_name] by crossing it.</span>")
|
||||
@@ -248,7 +248,7 @@
|
||||
update_glow()
|
||||
|
||||
/obj/effect/clockwork/sigil/transmission/proc/modify_charge(amount)
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
update_glow()
|
||||
return TRUE
|
||||
if(power_charge - amount < 0)
|
||||
@@ -258,7 +258,7 @@
|
||||
return TRUE
|
||||
|
||||
/obj/effect/clockwork/sigil/transmission/proc/update_glow()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
alpha = 255
|
||||
else
|
||||
alpha = min(initial(alpha) + power_charge*0.02, 255)
|
||||
@@ -289,8 +289,8 @@
|
||||
/obj/effect/clockwork/sigil/vitality/examine(mob/user)
|
||||
..()
|
||||
if(is_servant_of_ratvar(user) || isobserver(user))
|
||||
to_chat(user, "<span class='[vitality ? "inathneq_small":"alloy"]'>It has access to <b>[ratvar_awakens ? "INFINITE":"[vitality]"]</b> units of vitality.</span>")
|
||||
if(ratvar_awakens)
|
||||
to_chat(user, "<span class='[vitality ? "inathneq_small":"alloy"]'>It has access to <b>[GLOB.ratvar_awakens ? "INFINITE":"[vitality]"]</b> units of vitality.</span>")
|
||||
if(GLOB.ratvar_awakens)
|
||||
to_chat(user, "<span class='inathneq_small'>It can revive Servants at no cost!</span>")
|
||||
else
|
||||
to_chat(user, "<span class='inathneq_small'>It can revive Servants at a cost of <b>[base_revive_cost]</b> vitality plus vitality equal to the non-oxygen damage they have, in addition to being destroyed in the process.</span>")
|
||||
@@ -303,7 +303,7 @@
|
||||
addtimer(CALLBACK(src, .proc/update_alpha), 10)
|
||||
sleep(10)
|
||||
//as long as they're still on the sigil and are either not a servant or they're a servant AND it has remaining vitality
|
||||
while(L && (!is_servant_of_ratvar(L) || (is_servant_of_ratvar(L) && (ratvar_awakens || vitality))) && get_turf(L) == get_turf(src))
|
||||
while(L && (!is_servant_of_ratvar(L) || (is_servant_of_ratvar(L) && (GLOB.ratvar_awakens || vitality))) && get_turf(L) == get_turf(src))
|
||||
sigil_active = TRUE
|
||||
if(animation_number >= 4)
|
||||
new /obj/effect/overlay/temp/ratvar/sigil/vitality(get_turf(src))
|
||||
@@ -323,7 +323,7 @@
|
||||
qdel(W)
|
||||
L.dust()
|
||||
else
|
||||
if(!ratvar_awakens && L.stat == CONSCIOUS)
|
||||
if(!GLOB.ratvar_awakens && L.stat == CONSCIOUS)
|
||||
vitality_drained = L.adjustToxLoss(1)
|
||||
else
|
||||
vitality_drained = L.adjustToxLoss(1.5)
|
||||
@@ -334,7 +334,7 @@
|
||||
else
|
||||
if(L.stat == DEAD)
|
||||
var/revival_cost = base_revive_cost + L.getCloneLoss() + L.getToxLoss() + L.getFireLoss() + L.getBruteLoss() //ignores oxygen damage
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
revival_cost = 0
|
||||
var/mob/dead/observer/ghost = L.get_ghost(TRUE)
|
||||
if(vitality >= revival_cost && (ghost || (L.mind && L.mind.active)))
|
||||
@@ -344,14 +344,14 @@
|
||||
var/obj/effect/overlay/temp/ratvar/sigil/vitality/V = new /obj/effect/overlay/temp/ratvar/sigil/vitality(get_turf(src))
|
||||
animate(V, alpha = 0, transform = matrix()*2, time = 8)
|
||||
playsound(L, 'sound/magic/Staff_Healing.ogg', 50, 1)
|
||||
L.visible_message("<span class='warning'>[L] suddenly gets back up, [ratvar_awakens ? "[L.p_their()] body dripping blue ichor":"even as [src] scatters into blue sparks around [L.p_them()]"]!</span>", \
|
||||
L.visible_message("<span class='warning'>[L] suddenly gets back up, [GLOB.ratvar_awakens ? "[L.p_their()] body dripping blue ichor":"even as [src] scatters into blue sparks around [L.p_them()]"]!</span>", \
|
||||
"<span class='inathneq'>\"[text2ratvar("You will be okay, child.")]\"</span>")
|
||||
vitality -= revival_cost
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
qdel(src)
|
||||
break
|
||||
var/vitality_for_cycle = 3
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
if(L.stat == CONSCIOUS)
|
||||
vitality_for_cycle = 2
|
||||
vitality_for_cycle = min(vitality, vitality_for_cycle)
|
||||
@@ -360,7 +360,7 @@
|
||||
if(!vitality_used)
|
||||
break
|
||||
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
vitality -= vitality_used
|
||||
|
||||
sleep(2)
|
||||
|
||||
@@ -112,7 +112,7 @@
|
||||
|
||||
/obj/effect/clockwork/spatial_gateway/Bumped(atom/A)
|
||||
..()
|
||||
if(isliving(A) || istype(A, /obj/item))
|
||||
if(A && !QDELETED(A))
|
||||
pass_through_gateway(A)
|
||||
|
||||
/obj/effect/clockwork/spatial_gateway/proc/pass_through_gateway(atom/movable/A, no_cost)
|
||||
@@ -151,13 +151,13 @@
|
||||
var/list/possible_targets = list()
|
||||
var/list/teleportnames = list()
|
||||
|
||||
for(var/obj/structure/destructible/clockwork/powered/clockwork_obelisk/O in all_clockwork_objects)
|
||||
for(var/obj/structure/destructible/clockwork/powered/clockwork_obelisk/O in GLOB.all_clockwork_objects)
|
||||
if(!O.Adjacent(invoker) && O != src && (O.z <= ZLEVEL_SPACEMAX) && O.anchored) //don't list obelisks that we're next to
|
||||
var/area/A = get_area(O)
|
||||
var/locname = initial(A.name)
|
||||
possible_targets[avoid_assoc_duplicate_keys("[locname] [O.name]", teleportnames)] = O
|
||||
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
for(var/mob/living/L in GLOB.living_mob_list)
|
||||
if(!L.stat && is_servant_of_ratvar(L) && !L.Adjacent(invoker) && (L.z <= ZLEVEL_SPACEMAX)) //People right next to the invoker can't be portaled to, for obvious reasons
|
||||
possible_targets[avoid_assoc_duplicate_keys("[L.name] ([L.real_name])", teleportnames)] = L
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
/proc/generate_cache_component(specific_component_id, atom/A)
|
||||
if(!specific_component_id)
|
||||
specific_component_id = get_weighted_component_id()
|
||||
clockwork_component_cache[specific_component_id]++
|
||||
GLOB.clockwork_component_cache[specific_component_id]++
|
||||
if(A)
|
||||
var/component_animation_type = get_component_animation_type(specific_component_id)
|
||||
new component_animation_type(get_turf(A))
|
||||
@@ -13,15 +13,15 @@
|
||||
/proc/get_weighted_component_id(obj/item/clockwork/slab/storage_slab)
|
||||
. = list()
|
||||
if(storage_slab)
|
||||
if(clockwork_caches)
|
||||
for(var/i in clockwork_component_cache)
|
||||
.[i] = max(MAX_COMPONENTS_BEFORE_RAND - LOWER_PROB_PER_COMPONENT*(clockwork_component_cache[i] + storage_slab.stored_components[i]), 1)
|
||||
if(GLOB.clockwork_caches)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
.[i] = max(MAX_COMPONENTS_BEFORE_RAND - LOWER_PROB_PER_COMPONENT*(GLOB.clockwork_component_cache[i] + storage_slab.stored_components[i]), 1)
|
||||
else
|
||||
for(var/i in clockwork_component_cache)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
.[i] = max(MAX_COMPONENTS_BEFORE_RAND - LOWER_PROB_PER_COMPONENT*storage_slab.stored_components[i], 1)
|
||||
else
|
||||
for(var/i in clockwork_component_cache)
|
||||
.[i] = max(MAX_COMPONENTS_BEFORE_RAND - LOWER_PROB_PER_COMPONENT*clockwork_component_cache[i], 1)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
.[i] = max(MAX_COMPONENTS_BEFORE_RAND - LOWER_PROB_PER_COMPONENT*GLOB.clockwork_component_cache[i], 1)
|
||||
. = pickweight(.)
|
||||
|
||||
//returns a component name from a component id
|
||||
@@ -37,8 +37,6 @@
|
||||
return "Replicant Alloy"
|
||||
if(HIEROPHANT_ANSIBLE)
|
||||
return "Hierophant Ansible"
|
||||
else
|
||||
return null
|
||||
|
||||
//returns a component acronym from a component id
|
||||
/proc/get_component_acronym(id)
|
||||
@@ -53,8 +51,6 @@
|
||||
return "RA"
|
||||
if(HIEROPHANT_ANSIBLE)
|
||||
return "HA"
|
||||
else
|
||||
return null
|
||||
|
||||
//returns a component id from a component name
|
||||
/proc/get_component_id(name)
|
||||
@@ -69,8 +65,6 @@
|
||||
return REPLICANT_ALLOY
|
||||
if("Hierophant Ansible")
|
||||
return HIEROPHANT_ANSIBLE
|
||||
else
|
||||
return null
|
||||
|
||||
//returns a component spanclass from a component id
|
||||
/proc/get_component_span(id)
|
||||
@@ -127,8 +121,6 @@
|
||||
return /obj/effect/overlay/temp/ratvar/component/alloy
|
||||
if(HIEROPHANT_ANSIBLE)
|
||||
return /obj/effect/overlay/temp/ratvar/component/ansible
|
||||
else
|
||||
return null
|
||||
|
||||
//returns a type for a component from a component id
|
||||
/proc/get_component_type(id)
|
||||
@@ -142,6 +134,4 @@
|
||||
if(REPLICANT_ALLOY)
|
||||
return /obj/item/clockwork/component/replicant_alloy
|
||||
if(HIEROPHANT_ANSIBLE)
|
||||
return /obj/item/clockwork/component/hierophant_ansible
|
||||
else
|
||||
return null
|
||||
return /obj/item/clockwork/component/hierophant_ansible
|
||||
@@ -2,7 +2,7 @@
|
||||
/proc/hierophant_message(message, servantsonly, atom/target)
|
||||
if(!message)
|
||||
return FALSE
|
||||
for(var/M in mob_list)
|
||||
for(var/M in GLOB.mob_list)
|
||||
if(!servantsonly && isobserver(M))
|
||||
if(target)
|
||||
var/link = FOLLOW_LINK(M, target)
|
||||
|
||||
@@ -101,14 +101,11 @@ List of nuances:
|
||||
/proc/clockwork_say(atom/movable/AM, message, whisper=FALSE)
|
||||
var/list/spans = list(SPAN_ROBOT)
|
||||
|
||||
var/old_languages_spoken = AM.languages_spoken
|
||||
AM.languages_spoken = HUMAN //anyone who can understand HUMAN will hear weird shitty ratvar speak, otherwise it'll get starred out
|
||||
if(isliving(AM))
|
||||
var/mob/living/L = AM
|
||||
if(!whisper)
|
||||
L.say(message, "clock", spans)
|
||||
L.say(message, "clock", spans, language=/datum/language/common)
|
||||
else
|
||||
L.whisper(message)
|
||||
else
|
||||
AM.say(message)
|
||||
AM.languages_spoken = old_languages_spoken
|
||||
AM.say(message, language=/datum/language/common)
|
||||
|
||||
@@ -2,18 +2,18 @@
|
||||
/proc/scripture_unlock_check()
|
||||
var/servants = 0
|
||||
var/unconverted_ai_exists = get_unconverted_ais()
|
||||
for(var/mob/living/M in living_mob_list)
|
||||
for(var/mob/living/M in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(M) && (ishuman(M) || issilicon(M)))
|
||||
servants++
|
||||
. = list(SCRIPTURE_DRIVER = TRUE, SCRIPTURE_SCRIPT = FALSE, SCRIPTURE_APPLICATION = FALSE, SCRIPTURE_REVENANT = FALSE, SCRIPTURE_JUDGEMENT = FALSE)
|
||||
//Drivers: always unlocked
|
||||
.[SCRIPTURE_SCRIPT] = (servants >= SCRIPT_SERVANT_REQ && clockwork_caches >= SCRIPT_CACHE_REQ)
|
||||
.[SCRIPTURE_SCRIPT] = (servants >= SCRIPT_SERVANT_REQ && GLOB.clockwork_caches >= SCRIPT_CACHE_REQ)
|
||||
//Script: SCRIPT_SERVANT_REQ or more non-brain servants and SCRIPT_CACHE_REQ or more clockwork caches
|
||||
.[SCRIPTURE_APPLICATION] = (servants >= APPLICATION_SERVANT_REQ && clockwork_caches >= APPLICATION_CACHE_REQ && clockwork_construction_value >= APPLICATION_CV_REQ)
|
||||
.[SCRIPTURE_APPLICATION] = (servants >= APPLICATION_SERVANT_REQ && GLOB.clockwork_caches >= APPLICATION_CACHE_REQ && GLOB.clockwork_construction_value >= APPLICATION_CV_REQ)
|
||||
//Application: APPLICATION_SERVANT_REQ or more non-brain servants, APPLICATION_CACHE_REQ or more clockwork caches, and at least APPLICATION_CV_REQ CV
|
||||
.[SCRIPTURE_REVENANT] = (servants >= REVENANT_SERVANT_REQ && clockwork_caches >= REVENANT_CACHE_REQ && clockwork_construction_value >= REVENANT_CV_REQ)
|
||||
.[SCRIPTURE_REVENANT] = (servants >= REVENANT_SERVANT_REQ && GLOB.clockwork_caches >= REVENANT_CACHE_REQ && GLOB.clockwork_construction_value >= REVENANT_CV_REQ)
|
||||
//Revenant: REVENANT_SERVANT_REQ or more non-brain servants, REVENANT_CACHE_REQ or more clockwork caches, and at least REVENANT_CV_REQ CV
|
||||
.[SCRIPTURE_JUDGEMENT] = (servants >= JUDGEMENT_SERVANT_REQ && clockwork_caches >= JUDGEMENT_CACHE_REQ && clockwork_construction_value >= JUDGEMENT_CV_REQ && !unconverted_ai_exists)
|
||||
.[SCRIPTURE_JUDGEMENT] = (servants >= JUDGEMENT_SERVANT_REQ && GLOB.clockwork_caches >= JUDGEMENT_CACHE_REQ && GLOB.clockwork_construction_value >= JUDGEMENT_CV_REQ && !unconverted_ai_exists)
|
||||
//Judgement: JUDGEMENT_SERVANT_REQ or more non-brain servants, JUDGEMENT_CACHE_REQ or more clockwork caches, at least JUDGEMENT_CV_REQ CV, and there are no living, non-servant ais
|
||||
|
||||
//reports to servants when scripture is locked or unlocked
|
||||
@@ -26,33 +26,36 @@
|
||||
|
||||
/proc/get_unconverted_ais()
|
||||
. = 0
|
||||
for(var/ai in ai_list)
|
||||
var/mob/living/silicon/AI = ai
|
||||
if(is_servant_of_ratvar(AI) || !isturf(AI.loc) || AI.z != ZLEVEL_STATION)
|
||||
for(var/ai in GLOB.ai_list)
|
||||
var/mob/living/silicon/ai/AI = ai
|
||||
if(AI.deployed_shell && is_servant_of_ratvar(AI.deployed_shell))
|
||||
continue
|
||||
if(is_servant_of_ratvar(AI) || !isturf(AI.loc) || AI.z != ZLEVEL_STATION || AI.stat == DEAD)
|
||||
continue
|
||||
.++
|
||||
|
||||
/proc/update_slab_info(obj/item/clockwork/slab/set_slab)
|
||||
generate_all_scripture()
|
||||
var/needs_update = FALSE //if everything needs an update, for whatever reason
|
||||
for(var/s in all_scripture)
|
||||
var/datum/clockwork_scripture/S = all_scripture[s]
|
||||
for(var/s in GLOB.all_scripture)
|
||||
var/datum/clockwork_scripture/S = GLOB.all_scripture[s]
|
||||
if(S.creation_update())
|
||||
needs_update = TRUE
|
||||
if(!set_slab || needs_update)
|
||||
for(var/obj/item/clockwork/slab/S in all_clockwork_objects)
|
||||
for(var/obj/item/clockwork/slab/S in GLOB.all_clockwork_objects)
|
||||
SStgui.update_uis(S)
|
||||
S.update_quickbind()
|
||||
if(needs_update)
|
||||
S.update_quickbind()
|
||||
else
|
||||
SStgui.update_uis(set_slab)
|
||||
set_slab.update_quickbind()
|
||||
|
||||
/proc/generate_all_scripture()
|
||||
if(!all_scripture.len)
|
||||
if(!GLOB.all_scripture.len)
|
||||
for(var/V in sortList(subtypesof(/datum/clockwork_scripture), /proc/cmp_clockscripture_priority))
|
||||
var/datum/clockwork_scripture/S = new V
|
||||
all_scripture[S.type] = S
|
||||
GLOB.all_scripture[S.type] = S
|
||||
|
||||
//changes construction value
|
||||
/proc/change_construction_value(amount)
|
||||
clockwork_construction_value += amount
|
||||
GLOB.clockwork_construction_value += amount
|
||||
|
||||
@@ -11,10 +11,10 @@
|
||||
/obj/item/clockwork/New()
|
||||
..()
|
||||
ratvar_act()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/clockwork/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/clockwork/examine(mob/user)
|
||||
|
||||
@@ -11,14 +11,14 @@
|
||||
/obj/item/clothing/head/helmet/clockwork/New()
|
||||
..()
|
||||
ratvar_act()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/clothing/head/helmet/clockwork/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/head/helmet/clockwork/ratvar_act()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 100, bio = 100, rad = 100, fire = 100, acid = 100)
|
||||
flags |= STOPSPRESSUREDMAGE
|
||||
max_heat_protection_temperature = FIRE_IMMUNITY_SUIT_MAX_TEMP_PROTECT
|
||||
@@ -67,14 +67,14 @@
|
||||
/obj/item/clothing/suit/armor/clockwork/New()
|
||||
..()
|
||||
ratvar_act()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/clothing/suit/armor/clockwork/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/suit/armor/clockwork/ratvar_act()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 100, bio = 100, rad = 100, fire = 100, acid = 100)
|
||||
flags |= STOPSPRESSUREDMAGE
|
||||
max_heat_protection_temperature = FIRE_IMMUNITY_SUIT_MAX_TEMP_PROTECT
|
||||
@@ -128,14 +128,14 @@
|
||||
/obj/item/clothing/gloves/clockwork/New()
|
||||
..()
|
||||
ratvar_act()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/clothing/gloves/clockwork/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/gloves/clockwork/ratvar_act()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
armor = list(melee = 100, bullet = 100, laser = 100, energy = 100, bomb = 100, bio = 100, rad = 100, fire = 100, acid = 100)
|
||||
flags |= STOPSPRESSUREDMAGE
|
||||
max_heat_protection_temperature = FIRE_IMMUNITY_SUIT_MAX_TEMP_PROTECT
|
||||
@@ -181,17 +181,17 @@
|
||||
/obj/item/clothing/shoes/clockwork/New()
|
||||
..()
|
||||
ratvar_act()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/clothing/shoes/clockwork/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/shoes/clockwork/negates_gravity()
|
||||
return TRUE
|
||||
|
||||
/obj/item/clothing/shoes/clockwork/ratvar_act()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
flags |= NOSLIP
|
||||
else
|
||||
flags &= NOSLIP
|
||||
|
||||
@@ -113,11 +113,11 @@
|
||||
charge_delay = 2
|
||||
|
||||
/obj/item/clockwork/clockwork_proselytizer/ratvar_act()
|
||||
if(nezbere_invoked)
|
||||
if(GLOB.nezbere_invoked)
|
||||
charge_rate = 1250
|
||||
else
|
||||
charge_rate = initial(charge_rate)
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
uses_power = FALSE
|
||||
speed_multiplier = initial(speed_multiplier) * 0.25
|
||||
else
|
||||
@@ -165,7 +165,7 @@
|
||||
|
||||
/obj/item/clockwork/clockwork_proselytizer/proc/can_use_power(amount)
|
||||
if(amount == RATVAR_POWER_CHECK)
|
||||
if(ratvar_awakens || !uses_power)
|
||||
if(GLOB.ratvar_awakens || !uses_power)
|
||||
return TRUE
|
||||
else
|
||||
return FALSE
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
var/obj/effect/proc_holder/slab/slab_ability //the slab's current bound ability, for certain scripture
|
||||
var/list/quickbound = list(/datum/clockwork_scripture/ranged_ability/geis_prep, /datum/clockwork_scripture/create_object/replicant, \
|
||||
/datum/clockwork_scripture/create_object/tinkerers_cache) //quickbound scripture, accessed by index
|
||||
var/maximum_quickbound = 5 //how many quickbound scriptures we can have
|
||||
actions_types = list(/datum/action/item_action/clock/hierophant)
|
||||
|
||||
/obj/item/clockwork/slab/starter
|
||||
@@ -51,6 +52,7 @@
|
||||
nonhuman_usable = TRUE
|
||||
quickbound = list(/datum/clockwork_scripture/ranged_ability/judicial_marker, /datum/clockwork_scripture/ranged_ability/linked_vanguard, \
|
||||
/datum/clockwork_scripture/create_object/tinkerers_cache)
|
||||
maximum_quickbound = 6 //we usually have one or two unique scriptures, so if ratvar is up let us bind one more
|
||||
actions_types = list()
|
||||
|
||||
/obj/item/clockwork/slab/cyborg/engineer //five scriptures, plus a proselytizer
|
||||
@@ -81,7 +83,15 @@
|
||||
quickbound = list(/datum/clockwork_scripture/ranged_ability/linked_vanguard, /datum/clockwork_scripture/spatial_gateway, /datum/clockwork_scripture/channeled/volt_void/cyborg)
|
||||
|
||||
/obj/item/clockwork/slab/cyborg/access_display(mob/living/user)
|
||||
to_chat(user, "<span class='warning'>Use the action buttons to recite your limited set of scripture!</span>")
|
||||
if(!GLOB.ratvar_awakens)
|
||||
to_chat(user, "<span class='warning'>Use the action buttons to recite your limited set of scripture!</span>")
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/item/clockwork/slab/cyborg/ratvar_act()
|
||||
..()
|
||||
if(!GLOB.ratvar_awakens)
|
||||
SStgui.close_uis(src)
|
||||
|
||||
/obj/item/clockwork/slab/New()
|
||||
..()
|
||||
@@ -97,7 +107,7 @@
|
||||
return ..()
|
||||
|
||||
/obj/item/clockwork/slab/ratvar_act()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
nonhuman_usable = TRUE
|
||||
else
|
||||
nonhuman_usable = initial(nonhuman_usable)
|
||||
@@ -119,7 +129,7 @@
|
||||
return
|
||||
var/servants = 0
|
||||
var/production_slowdown = 0
|
||||
for(var/mob/living/M in living_mob_list)
|
||||
for(var/mob/living/M in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(M) && (ishuman(M) || issilicon(M)))
|
||||
servants++
|
||||
if(servants > SCRIPT_SERVANT_REQ)
|
||||
@@ -149,11 +159,11 @@
|
||||
continue
|
||||
var/datum/clockwork_scripture/quickbind_slot = quickbound[i]
|
||||
to_chat(user, "<b>Quickbind</b> button: <span class='[get_component_span(initial(quickbind_slot.primary_component))]'>[initial(quickbind_slot.name)]</span>.")
|
||||
if(clockwork_caches) //show components on examine
|
||||
if(GLOB.clockwork_caches) //show components on examine
|
||||
to_chat(user, "<b>Stored components (with global cache):</b>")
|
||||
for(var/i in stored_components)
|
||||
to_chat(user, "<span class='[get_component_span(i)]_small'><i>[get_component_name(i)][i != REPLICANT_ALLOY ? "s":""]:</i> <b>[stored_components[i]]</b> \
|
||||
(<b>[stored_components[i] + clockwork_component_cache[i]]</b>)</span>")
|
||||
(<b>[stored_components[i] + GLOB.clockwork_component_cache[i]]</b>)</span>")
|
||||
else
|
||||
to_chat(user, "<b>Stored components:</b>")
|
||||
for(var/i in stored_components)
|
||||
@@ -195,9 +205,9 @@
|
||||
if(!C.component_id)
|
||||
return 0
|
||||
user.visible_message("<span class='notice'>[user] inserts [C] into [src].</span>", "<span class='notice'>You insert [C] into [src]\
|
||||
[clockwork_caches ? ", where it is added to the global cache":""].</span>")
|
||||
if(clockwork_caches)
|
||||
clockwork_component_cache[C.component_id]++
|
||||
[GLOB.clockwork_caches ? ", where it is added to the global cache":""].</span>")
|
||||
if(GLOB.clockwork_caches)
|
||||
GLOB.clockwork_component_cache[C.component_id]++
|
||||
update_slab_info()
|
||||
else
|
||||
stored_components[C.component_id]++
|
||||
@@ -207,11 +217,15 @@
|
||||
return 1
|
||||
else if(istype(I, /obj/item/clockwork/slab) && ratvarian)
|
||||
var/obj/item/clockwork/slab/S = I
|
||||
var/needs_update = FALSE
|
||||
for(var/i in stored_components)
|
||||
stored_components[i] += S.stored_components[i]
|
||||
S.stored_components[i] = 0
|
||||
update_slab_info(src)
|
||||
update_slab_info(S)
|
||||
if(S.stored_components[i])
|
||||
needs_update = TRUE
|
||||
if(needs_update)
|
||||
update_slab_info(src)
|
||||
update_slab_info(S)
|
||||
user.visible_message("<span class='notice'>[user] empties [src] into [S].</span>", "<span class='notice'>You transfer your slab's components into [S].</span>")
|
||||
else
|
||||
return ..()
|
||||
@@ -265,7 +279,7 @@
|
||||
ui_interact(user)
|
||||
return TRUE
|
||||
|
||||
/obj/item/clockwork/slab/ui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/ui_state/state = inventory_state)
|
||||
/obj/item/clockwork/slab/ui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/ui_state/state = GLOB.inventory_state)
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "clockwork_slab", name, 800, 420, master_ui, state)
|
||||
@@ -282,7 +296,7 @@
|
||||
var/initial_tier = initial(scripture.tier)
|
||||
if(initial_tier != SCRIPTURE_PERIPHERAL)
|
||||
var/list/tiers_of_scripture = scripture_unlock_check()
|
||||
if(!ratvar_awakens && !no_cost && !tiers_of_scripture[initial_tier])
|
||||
if(!GLOB.ratvar_awakens && !no_cost && !tiers_of_scripture[initial_tier])
|
||||
to_chat(user, "<span class='warning'>That scripture is not unlocked, and cannot be recited!</span>")
|
||||
return FALSE
|
||||
var/datum/clockwork_scripture/scripture_to_recite = new scripture
|
||||
@@ -294,7 +308,7 @@
|
||||
//Guide to Serving Ratvar
|
||||
/obj/item/clockwork/slab/proc/recollection()
|
||||
var/list/textlist = list("If you're seeing this, file a bug report.")
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
textlist = list("<font color=#BE8700 size=3><b>")
|
||||
for(var/i in 1 to 100)
|
||||
textlist += "HONOR RATVAR "
|
||||
@@ -302,7 +316,7 @@
|
||||
else
|
||||
var/servants = 0
|
||||
var/production_time = SLAB_PRODUCTION_TIME
|
||||
for(var/mob/living/M in living_mob_list)
|
||||
for(var/mob/living/M in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(M) && (ishuman(M) || issilicon(M)))
|
||||
servants++
|
||||
if(servants > SCRIPT_SERVANT_REQ)
|
||||
@@ -358,11 +372,12 @@
|
||||
The remaining functions are several buttons in the top left while holding the slab.<br>From left to right, they are:<br>\
|
||||
<b><font color=#DAAA18>Hierophant Network</font></b>, which allows communication to other Servants.<br>")
|
||||
if(LAZYLEN(quickbound))
|
||||
for(var/i in 1 to quickbound.len)
|
||||
if(!quickbound[i])
|
||||
continue
|
||||
var/datum/clockwork_scripture/quickbind_slot = quickbound[i]
|
||||
textlist += "A <b>Quickbind</b> slot, currently set to <b><font color=[get_component_color_bright(initial(quickbind_slot.primary_component))]>[initial(quickbind_slot.name)]</font></b>.<br>"
|
||||
for(var/i in 1 to maximum_quickbound)
|
||||
if(LAZYLEN(quickbound) < i || !quickbound[i])
|
||||
textlist += "A <b>Quickbind</b> slot, currently set to <b><font color=#BE8700>Nothing</font></b>.<br>"
|
||||
else
|
||||
var/datum/clockwork_scripture/quickbind_slot = quickbound[i]
|
||||
textlist += "A <b>Quickbind</b> slot, currently set to <b><font color=[get_component_color_bright(initial(quickbind_slot.primary_component))]>[initial(quickbind_slot.name)]</font></b>.<br>"
|
||||
textlist += "<br>\
|
||||
Examine the slab or swap to Recital to check the number of components it has available.<br><br>\
|
||||
\
|
||||
@@ -379,9 +394,9 @@
|
||||
temp_data += " "
|
||||
else
|
||||
temp_data += " ("
|
||||
if(clockwork_caches) //if we have caches, display what's in the global cache
|
||||
for(var/i in clockwork_component_cache)
|
||||
temp_data += "<font color=[get_component_color_bright(i)]>[get_component_acronym(i)] <b>[data["components"][i] + clockwork_component_cache[i]]</b></font>"
|
||||
if(GLOB.clockwork_caches) //if we have caches, display what's in the global cache
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
temp_data += "<font color=[get_component_color_bright(i)]>[get_component_acronym(i)] <b>[data["components"][i] + GLOB.clockwork_component_cache[i]]</b></font>"
|
||||
if(i != HIEROPHANT_ANSIBLE)
|
||||
temp_data += " "
|
||||
else
|
||||
@@ -411,8 +426,8 @@
|
||||
generate_all_scripture()
|
||||
|
||||
data["scripture"] = list()
|
||||
for(var/s in all_scripture)
|
||||
var/datum/clockwork_scripture/S = all_scripture[s]
|
||||
for(var/s in GLOB.all_scripture)
|
||||
var/datum/clockwork_scripture/S = GLOB.all_scripture[s]
|
||||
if(S.tier == selected_scripture) //display only scriptures of the selected tier
|
||||
var/scripture_color = get_component_color_bright(S.primary_component)
|
||||
var/list/temp_info = list("name" = "<font color=[scripture_color]><b>[S.name]</b></font>",
|
||||
@@ -456,10 +471,10 @@
|
||||
selected_scripture = params["category"]
|
||||
if("component")
|
||||
var/list/components = list("Random Components")
|
||||
for(var/i in clockwork_component_cache)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
var/cache_components = 0
|
||||
if(clockwork_caches)
|
||||
cache_components = clockwork_component_cache[i]
|
||||
if(GLOB.clockwork_caches)
|
||||
cache_components = GLOB.clockwork_component_cache[i]
|
||||
components["[get_component_name(i)] [(cache_components + stored_components[i])]"] = i
|
||||
var/input_component = input("Choose a component type.", "Target Component") as null|anything in components
|
||||
if(input_component && !..())
|
||||
@@ -474,8 +489,8 @@
|
||||
quickbound[found_index] = null //otherwise, leave it as a null so the scripture maintains position
|
||||
update_quickbind()
|
||||
else
|
||||
var/target_index = input("Position of [initial(path.name)], 1 to 5?", "Input") as num|null
|
||||
if(isnum(target_index) && target_index > 0 && target_index < 6 && !..())
|
||||
var/target_index = input("Position of [initial(path.name)], 1 to [maximum_quickbound]?", "Input") as num|null
|
||||
if(isnum(target_index) && target_index > 0 && target_index <= maximum_quickbound && !..())
|
||||
var/datum/clockwork_scripture/S
|
||||
if(LAZYLEN(quickbound) >= target_index)
|
||||
S = quickbound[target_index]
|
||||
@@ -488,6 +503,9 @@
|
||||
return
|
||||
while(LAZYLEN(quickbound) < index)
|
||||
quickbound += null
|
||||
var/datum/clockwork_scripture/quickbind_slot = GLOB.all_scripture[quickbound[index]]
|
||||
if(quickbind_slot && !quickbind_slot.quickbind)
|
||||
return //we can't unbind things we can't normally bind
|
||||
quickbound[index] = scripture
|
||||
update_quickbind()
|
||||
|
||||
@@ -500,7 +518,7 @@
|
||||
continue
|
||||
var/datum/action/item_action/clock/quickbind/Q = new /datum/action/item_action/clock/quickbind(src)
|
||||
Q.scripture_index = i
|
||||
var/datum/clockwork_scripture/quickbind_slot = all_scripture[quickbound[i]]
|
||||
var/datum/clockwork_scripture/quickbind_slot = GLOB.all_scripture[quickbound[i]]
|
||||
Q.name = "[quickbind_slot.name] ([Q.scripture_index])"
|
||||
var/list/temp_desc = list()
|
||||
for(var/c in quickbind_slot.consumed_components) //show how much the bound scripture costs
|
||||
|
||||
@@ -15,12 +15,12 @@
|
||||
|
||||
/obj/item/clothing/glasses/judicial_visor/New()
|
||||
..()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
blaster = new(src)
|
||||
blaster.visor = src
|
||||
|
||||
/obj/item/clothing/glasses/judicial_visor/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
if(blaster.ranged_ability_user)
|
||||
blaster.remove_ranged_ability()
|
||||
blaster.visor = null
|
||||
@@ -131,7 +131,7 @@
|
||||
continue
|
||||
V.recharging = TRUE //To prevent exploiting multiple visors to bypass the cooldown
|
||||
V.update_status()
|
||||
addtimer(CALLBACK(V, /obj/item/clothing/glasses/judicial_visor.proc/recharge_visor, ranged_ability_user), (ratvar_awakens ? visor.recharge_cooldown*0.1 : visor.recharge_cooldown) * 2)
|
||||
addtimer(CALLBACK(V, /obj/item/clothing/glasses/judicial_visor.proc/recharge_visor, ranged_ability_user), (GLOB.ratvar_awakens ? visor.recharge_cooldown*0.1 : visor.recharge_cooldown) * 2)
|
||||
clockwork_say(ranged_ability_user, text2ratvar("Kneel, heathens!"))
|
||||
ranged_ability_user.visible_message("<span class='warning'>[ranged_ability_user]'s judicial visor fires a stream of energy at [target], creating a strange mark!</span>", "<span class='heavy_brass'>You direct [visor]'s power to [target]. You must wait for some time before doing this again.</span>")
|
||||
var/turf/targetturf = get_turf(target)
|
||||
@@ -139,7 +139,7 @@
|
||||
add_logs(ranged_ability_user, targetturf, "created a judicial marker")
|
||||
ranged_ability_user.update_action_buttons_icon()
|
||||
ranged_ability_user.update_inv_glasses()
|
||||
addtimer(CALLBACK(visor, /obj/item/clothing/glasses/judicial_visor.proc/recharge_visor, ranged_ability_user), ratvar_awakens ? visor.recharge_cooldown*0.1 : visor.recharge_cooldown)//Cooldown is reduced by 10x if Ratvar is up
|
||||
addtimer(CALLBACK(visor, /obj/item/clothing/glasses/judicial_visor.proc/recharge_visor, ranged_ability_user), GLOB.ratvar_awakens ? visor.recharge_cooldown*0.1 : visor.recharge_cooldown)//Cooldown is reduced by 10x if Ratvar is up
|
||||
remove_ranged_ability()
|
||||
|
||||
return TRUE
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
return ..()
|
||||
|
||||
/obj/item/clockwork/ratvarian_spear/ratvar_act()
|
||||
if(ratvar_awakens) //If Ratvar is alive, the spear is extremely powerful
|
||||
if(GLOB.ratvar_awakens) //If Ratvar is alive, the spear is extremely powerful
|
||||
force = 25
|
||||
throwforce = 50
|
||||
armour_penetration = 10
|
||||
@@ -40,7 +40,7 @@
|
||||
timerid = addtimer(CALLBACK(src, .proc/break_spear), RATVARIAN_SPEAR_DURATION, TIMER_STOPPABLE)
|
||||
|
||||
/obj/item/clockwork/ratvarian_spear/cyborg/ratvar_act() //doesn't break!
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
force = 25
|
||||
throwforce = 50
|
||||
armour_penetration = 10
|
||||
|
||||
@@ -18,21 +18,20 @@
|
||||
The purpose of your existence is to further the goals of the servants and Ratvar himself. Above all else, serve Ratvar.</b>"
|
||||
new_mob_message = "<span class='brass'>The soul vessel emits a jet of steam before its cogwheel smooths out.</span>"
|
||||
dead_message = "<span class='deadsay'>Its cogwheel, scratched and dented, lies motionless.</span>"
|
||||
fluff_names = list("Judge", "Guard", "Servant", "Smith", "Auger")
|
||||
possible_names = list("Judge", "Guard", "Servant", "Smith", "Auger")
|
||||
autoping = FALSE
|
||||
resistance_flags = FIRE_PROOF | ACID_PROOF
|
||||
force_replace_ai_name = TRUE
|
||||
|
||||
/obj/item/device/mmi/posibrain/soul_vessel/New()
|
||||
/obj/item/device/mmi/posibrain/soul_vessel/Initialize()
|
||||
..()
|
||||
radio.on = 0
|
||||
radio.on = FALSE
|
||||
laws = new /datum/ai_laws/ratvar()
|
||||
braintype = picked_fluff_name
|
||||
all_clockwork_objects += src
|
||||
brainmob.languages_spoken = RATVAR
|
||||
braintype = picked_name
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/device/mmi/posibrain/soul_vessel/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/device/mmi/posibrain/soul_vessel/examine(mob/user)
|
||||
@@ -49,14 +48,16 @@
|
||||
/obj/item/device/mmi/posibrain/soul_vessel/attack_self(mob/living/user)
|
||||
if(!is_servant_of_ratvar(user))
|
||||
to_chat(user, "<span class='warning'>You fiddle around with [src], to no avail.</span>")
|
||||
return 0
|
||||
return FALSE
|
||||
..()
|
||||
|
||||
/obj/item/device/mmi/posibrain/soul_vessel/attack(mob/living/target, mob/living/carbon/human/user)
|
||||
if(!is_servant_of_ratvar(user) || !ishuman(target))
|
||||
..()
|
||||
return
|
||||
if(used || (brainmob && brainmob.key))
|
||||
if(QDELETED(brainmob))
|
||||
return
|
||||
if(brainmob.key)
|
||||
to_chat(user, "<span class='nezbere'>\"This vessel is filled, friend. Provide it with a body.\"</span>")
|
||||
return
|
||||
if(is_servant_of_ratvar(target))
|
||||
@@ -95,8 +96,8 @@
|
||||
if(!prev_fakedeath)
|
||||
H.status_flags &= ~FAKEDEATH
|
||||
H.apply_status_effect(STATUS_EFFECT_SIGILMARK) //let them be affected by vitality matrices
|
||||
picked_fluff_name = "Slave"
|
||||
braintype = picked_fluff_name
|
||||
picked_name = "Slave"
|
||||
braintype = picked_name
|
||||
brainmob.timeofhostdeath = H.timeofdeath
|
||||
user.visible_message("<span class='warning'>[user] presses [src] to [H]'s head, ripping through the skull and carefully extracting the brain!</span>", \
|
||||
"<span class='brass'>You extract [H]'s consciousness from [H.p_their()] body, trapping it in the soul vessel.</span>")
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
|
||||
/obj/item/clothing/glasses/wraith_spectacles/New()
|
||||
..()
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/item/clothing/glasses/wraith_spectacles/Destroy()
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/glasses/wraith_spectacles/attack_self(mob/user)
|
||||
@@ -38,7 +38,7 @@
|
||||
if(blind_cultist(H))
|
||||
return
|
||||
if(is_servant_of_ratvar(H))
|
||||
to_chat(H, "<span class='heavy_brass'>You push the spectacles down, and all is revealed to you.[ratvar_awakens ? "" : " Your eyes begin to itch - you cannot do this for long."]</span>")
|
||||
to_chat(H, "<span class='heavy_brass'>You push the spectacles down, and all is revealed to you.[GLOB.ratvar_awakens ? "" : " Your eyes begin to itch - you cannot do this for long."]</span>")
|
||||
var/datum/status_effect/wraith_spectacles/WS = H.has_status_effect(STATUS_EFFECT_WRAITHSPECS)
|
||||
if(WS)
|
||||
WS.apply_eye_damage(H)
|
||||
@@ -57,13 +57,13 @@
|
||||
return TRUE
|
||||
|
||||
/obj/item/clothing/glasses/wraith_spectacles/proc/set_vision_vars(update_vision)
|
||||
invis_view = SEE_INVISIBLE_LIVING
|
||||
lighting_alpha = null
|
||||
tint = 0
|
||||
vision_flags = NONE
|
||||
darkness_view = 2
|
||||
if(!up)
|
||||
if(is_servant_of_ratvar(loc))
|
||||
invis_view = SEE_INVISIBLE_NOLIGHTING
|
||||
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
vision_flags = SEE_MOBS | SEE_TURFS | SEE_OBJS
|
||||
darkness_view = 3
|
||||
else
|
||||
@@ -83,7 +83,7 @@
|
||||
return
|
||||
set_vision_vars(TRUE)
|
||||
if(is_servant_of_ratvar(user))
|
||||
to_chat(user, "<span class='heavy_brass'>As you put on the spectacles, all is revealed to you.[ratvar_awakens ? "" : " Your eyes begin to itch - you cannot do this for long."]</span>")
|
||||
to_chat(user, "<span class='heavy_brass'>As you put on the spectacles, all is revealed to you.[GLOB.ratvar_awakens ? "" : " Your eyes begin to itch - you cannot do this for long."]</span>")
|
||||
var/datum/status_effect/wraith_spectacles/WS = user.has_status_effect(STATUS_EFFECT_WRAITHSPECS)
|
||||
if(WS)
|
||||
WS.apply_eye_damage(user)
|
||||
@@ -137,10 +137,10 @@
|
||||
var/mob/living/carbon/human/H = owner
|
||||
var/glasses_right = istype(H.glasses, /obj/item/clothing/glasses/wraith_spectacles)
|
||||
var/obj/item/clothing/glasses/wraith_spectacles/WS = H.glasses
|
||||
if(glasses_right && !WS.up && !ratvar_awakens)
|
||||
if(glasses_right && !WS.up && !GLOB.ratvar_awakens)
|
||||
apply_eye_damage(H)
|
||||
else
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
H.cure_nearsighted()
|
||||
H.cure_blind()
|
||||
H.adjust_eye_damage(-eye_damage_done)
|
||||
|
||||
@@ -8,14 +8,14 @@
|
||||
unsuitable_atmos_damage = 0
|
||||
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0) //Robotic
|
||||
damage_coeff = list(BRUTE = 1, BURN = 1, TOX = 0, CLONE = 0, STAMINA = 0, OXY = 0)
|
||||
languages_spoken = RATVAR
|
||||
languages_understood = HUMAN|RATVAR
|
||||
healable = FALSE
|
||||
del_on_death = TRUE
|
||||
speak_emote = list("clanks", "clinks", "clunks", "clangs")
|
||||
verb_ask = "requests"
|
||||
verb_exclaim = "proclaims"
|
||||
verb_yell = "harangues"
|
||||
initial_languages = list(/datum/language/common, /datum/language/ratvar)
|
||||
only_speaks_language = /datum/language/ratvar
|
||||
bubble_icon = "clock"
|
||||
light_color = "#E42742"
|
||||
death_sound = 'sound/magic/clockwork/anima_fragment_death.ogg'
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/fragment/Life()
|
||||
..()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
adjustHealth(-5)
|
||||
else if(movement_delay_time > world.time)
|
||||
adjustHealth(-0.2)
|
||||
@@ -37,7 +37,7 @@
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/fragment/Stat()
|
||||
..()
|
||||
if(statpanel("Status") && movement_delay_time > world.time && !ratvar_awakens)
|
||||
if(statpanel("Status") && movement_delay_time > world.time && !GLOB.ratvar_awakens)
|
||||
stat(null, "Movement delay(seconds): [max(round((movement_delay_time - world.time)*0.1, 0.1), 0)]")
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/fragment/death(gibbed)
|
||||
@@ -59,7 +59,7 @@
|
||||
UnarmedAttack(L)
|
||||
attacktext = previousattacktext
|
||||
changeNext_move(CLICK_CD_MELEE)
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
adjustHealth(4)
|
||||
adjust_movement_delay(10) //with the above damage, total of 20 movement delay plus speed = 0 due to damage
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/fragment/movement_delay()
|
||||
. = ..()
|
||||
if(movement_delay_time > world.time && !ratvar_awakens)
|
||||
if(movement_delay_time > world.time && !GLOB.ratvar_awakens)
|
||||
. += min((movement_delay_time - world.time) * 0.1, 10) //the more delay we have, the slower we go
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/fragment/adjustHealth(amount)
|
||||
@@ -77,7 +77,7 @@
|
||||
adjust_movement_delay(amount*2.5)
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/fragment/proc/adjust_movement_delay(amount)
|
||||
if(ratvar_awakens) //if ratvar is up we ignore movement delay
|
||||
if(GLOB.ratvar_awakens) //if ratvar is up we ignore movement delay
|
||||
movement_delay_time = 0
|
||||
else if(movement_delay_time > world.time)
|
||||
movement_delay_time = movement_delay_time + amount
|
||||
|
||||
@@ -41,10 +41,10 @@
|
||||
emerge_from_host(FALSE, TRUE)
|
||||
unbind_from_host()
|
||||
return
|
||||
if(!ratvar_awakens && host.stat == DEAD)
|
||||
if(!GLOB.ratvar_awakens && host.stat == DEAD)
|
||||
death()
|
||||
return
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
adjustHealth(-50)
|
||||
else
|
||||
adjustHealth(-10)
|
||||
@@ -55,7 +55,7 @@
|
||||
to_chat(host, "<span class='userdanger'>Your marauder is now strong enough to come forward again!</span>")
|
||||
recovering = FALSE
|
||||
else
|
||||
if(ratvar_awakens) //If Ratvar is alive, marauders don't need a host and are downright impossible to kill
|
||||
if(GLOB.ratvar_awakens) //If Ratvar is alive, marauders don't need a host and are downright impossible to kill
|
||||
adjustHealth(-5)
|
||||
heal_host()
|
||||
else if(host)
|
||||
@@ -107,7 +107,7 @@
|
||||
if(iscarbon(host))
|
||||
resulthealth = round((abs(HEALTH_THRESHOLD_DEAD - host.health) / abs(HEALTH_THRESHOLD_DEAD - host.maxHealth)) * 100)
|
||||
stat(null, "Host Health: [resulthealth]%")
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
stat(null, "You are [recovering ? "un" : ""]able to deploy!")
|
||||
else
|
||||
if(resulthealth > MARAUDER_EMERGE_THRESHOLD)
|
||||
@@ -148,7 +148,7 @@
|
||||
var/resulthealth = round((host.health / host.maxHealth) * 100, 0.5)
|
||||
if(iscarbon(host))
|
||||
resulthealth = round((abs(HEALTH_THRESHOLD_DEAD - host.health) / abs(HEALTH_THRESHOLD_DEAD - host.maxHealth)) * 100)
|
||||
if(ratvar_awakens || resulthealth <= MARAUDER_EMERGE_THRESHOLD)
|
||||
if(GLOB.ratvar_awakens || resulthealth <= MARAUDER_EMERGE_THRESHOLD)
|
||||
new /obj/effect/overlay/temp/heal(host.loc, "#AF0AAF")
|
||||
host.heal_ordered_damage(4, damage_heal_order)
|
||||
|
||||
@@ -180,7 +180,7 @@
|
||||
hud_used.healths.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'><font color='#AF0AAF'>[round((health / maxHealth) * 100, 0.5)]%</font>"
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/marauder/proc/update_stats()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
speed = 0
|
||||
melee_damage_lower = 20
|
||||
melee_damage_upper = 20
|
||||
@@ -261,7 +261,7 @@
|
||||
return ..()
|
||||
|
||||
/mob/living/simple_animal/hostile/clockwork/marauder/proc/blockOrCounter(mob/target, atom/textobject)
|
||||
if(ratvar_awakens) //if ratvar has woken, we block nearly everything at a very high chance
|
||||
if(GLOB.ratvar_awakens) //if ratvar has woken, we block nearly everything at a very high chance
|
||||
blockchance = 90
|
||||
counterchance = 90
|
||||
if(prob(blockchance))
|
||||
@@ -284,7 +284,7 @@
|
||||
counterchance = min(counterchance + initial(counterchance), 100)
|
||||
else
|
||||
blockchance = min(blockchance + initial(blockchance), 100)
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
blockchance = 90
|
||||
counterchance = 90
|
||||
|
||||
@@ -301,7 +301,7 @@
|
||||
message = "<span class='sevtug_small'>\"[message]\"</span>" //Processed output
|
||||
to_chat(src, "[name_part]<span class='sevtug_small'>:</span> [message]")
|
||||
to_chat(host, "[name_part]<span class='sevtug_small'>:</span> [message]")
|
||||
for(var/M in mob_list)
|
||||
for(var/M in GLOB.mob_list)
|
||||
if(isobserver(M))
|
||||
var/link = FOLLOW_LINK(M, src)
|
||||
to_chat(M, "[link] [name_part] <span class='sevtug_small'>(to</span> <span class='sevtug'>[findtextEx(host.name, host.real_name) ? "[host.name]" : "[host.real_name] (as [host.name])"]</span><span class='sevtug_small'>):</span> [message] ")
|
||||
@@ -329,7 +329,7 @@
|
||||
if(!host)
|
||||
to_chat(src, "<span class='warning'>You don't have a host!</span>")
|
||||
return FALSE
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
var/resulthealth = round((host.health / host.maxHealth) * 100, 0.5)
|
||||
if(iscarbon(host))
|
||||
resulthealth = round((abs(HEALTH_THRESHOLD_DEAD - host.health) / abs(HEALTH_THRESHOLD_DEAD - host.maxHealth)) * 100)
|
||||
@@ -421,7 +421,7 @@
|
||||
message = "<span class='sevtug_small'>\"[message]\"</span>" //Processed output
|
||||
to_chat(owner, "[name_part]<span class='sevtug_small'>:</span> [message]")
|
||||
to_chat(linked_marauder, "[name_part]<span class='sevtug_small'>:</span> [message]")
|
||||
for(var/M in mob_list)
|
||||
for(var/M in GLOB.mob_list)
|
||||
if(isobserver(M))
|
||||
var/link = FOLLOW_LINK(M, src)
|
||||
to_chat(M, "[link] [name_part] <span class='sevtug_small'>(to</span> <span class='sevtug'>[linked_marauder] ([linked_marauder.true_name])</span><span class='sevtug_small'>):</span> [message]")
|
||||
|
||||
@@ -58,7 +58,7 @@ Judgement: 12 servants, 5 caches, 300 CV, and any existing AIs are converted or
|
||||
to_chat(invoker, "<span class='warning'>[slab] refuses to work, displaying the message: \"[slab.busy]!\"</span>")
|
||||
return FALSE
|
||||
slab.busy = "Invocation ([name]) in progress"
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
channel_time *= 0.5 //if ratvar has awoken, half channel time and no cost
|
||||
else if(!slab.no_cost)
|
||||
for(var/i in consumed_components)
|
||||
@@ -68,7 +68,7 @@ Judgement: 12 servants, 5 caches, 300 CV, and any existing AIs are converted or
|
||||
slab.stored_components[i]--
|
||||
used_slab_components[i]++
|
||||
else
|
||||
clockwork_component_cache[i]--
|
||||
GLOB.clockwork_component_cache[i]--
|
||||
used_cache_components[i]++
|
||||
update_slab_info()
|
||||
channel_time *= slab.speed_multiplier
|
||||
@@ -78,14 +78,14 @@ Judgement: 12 servants, 5 caches, 300 CV, and any existing AIs are converted or
|
||||
if(slab)
|
||||
slab.stored_components[i] += consumed_components[i]
|
||||
else //if we can't find a slab add to the global cache
|
||||
clockwork_component_cache[i] += consumed_components[i]
|
||||
GLOB.clockwork_component_cache[i] += consumed_components[i]
|
||||
for(var/i in used_cache_components)
|
||||
if(used_cache_components[i])
|
||||
clockwork_component_cache[i] += consumed_components[i]
|
||||
GLOB.clockwork_component_cache[i] += consumed_components[i]
|
||||
update_slab_info()
|
||||
else
|
||||
successful = TRUE
|
||||
if(slab && !slab.no_cost && !ratvar_awakens) //if the slab exists and isn't debug and ratvar isn't up, log the scripture as being used
|
||||
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
|
||||
feedback_add_details("clockcult_scripture_recited", name)
|
||||
if(slab)
|
||||
slab.busy = null
|
||||
@@ -102,12 +102,12 @@ Judgement: 12 servants, 5 caches, 300 CV, and any existing AIs are converted or
|
||||
|
||||
/datum/clockwork_scripture/proc/has_requirements() //if we have the components and invokers to do it
|
||||
var/checked_penalty = FALSE
|
||||
if(!ratvar_awakens && !slab.no_cost)
|
||||
if(!GLOB.ratvar_awakens && !slab.no_cost)
|
||||
checked_penalty = check_offstation_penalty()
|
||||
var/component_printout = "<span class='warning'>You lack the components to recite this piece of scripture!"
|
||||
var/failed = FALSE
|
||||
for(var/i in consumed_components)
|
||||
var/cache_components = clockwork_caches ? clockwork_component_cache[i] : 0
|
||||
var/cache_components = GLOB.clockwork_caches ? GLOB.clockwork_component_cache[i] : 0
|
||||
var/total_components = slab.stored_components[i] + cache_components
|
||||
if(consumed_components[i] && total_components < consumed_components[i])
|
||||
component_printout += "\nYou have <span class='[get_component_span(i)]_small'><b>[total_components]/[consumed_components[i]]</b> \
|
||||
@@ -117,7 +117,7 @@ Judgement: 12 servants, 5 caches, 300 CV, and any existing AIs are converted or
|
||||
component_printout += "</span>"
|
||||
to_chat(invoker, component_printout)
|
||||
return FALSE
|
||||
if(multiple_invokers_used && !multiple_invokers_optional && !ratvar_awakens && !slab.no_cost)
|
||||
if(multiple_invokers_used && !multiple_invokers_optional && !GLOB.ratvar_awakens && !slab.no_cost)
|
||||
var/nearby_servants = 0
|
||||
for(var/mob/living/L in range(1, get_turf(invoker)))
|
||||
if(is_servant_of_ratvar(L) && L.stat == CONSCIOUS && L.can_speak_vocal())
|
||||
|
||||
@@ -86,7 +86,7 @@
|
||||
return TRUE
|
||||
if(is_type_in_typecache(I, ratvarian_armor_typecache))
|
||||
return FALSE
|
||||
if(!ratvar_awakens && is_type_in_typecache(I, better_armor_typecache))
|
||||
if(!GLOB.ratvar_awakens && is_type_in_typecache(I, better_armor_typecache))
|
||||
return FALSE
|
||||
return user.dropItemToGround(I)
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
sort_priority = 3
|
||||
|
||||
/datum/clockwork_scripture/memory_allocation/check_special_requirements()
|
||||
for(var/mob/living/simple_animal/hostile/clockwork/marauder/M in all_clockwork_mobs)
|
||||
for(var/mob/living/simple_animal/hostile/clockwork/marauder/M in GLOB.all_clockwork_mobs)
|
||||
if(M.host == invoker)
|
||||
to_chat(invoker, "<span class='warning'>You can only house one marauder at a time!</span>")
|
||||
return FALSE
|
||||
@@ -135,7 +135,7 @@
|
||||
if(!check_special_requirements())
|
||||
return FALSE
|
||||
to_chat(invoker, "<span class='warning'>The tendril shivers slightly as it selects a marauder...</span>")
|
||||
var/list/marauder_candidates = pollCandidates("Do you want to play as the clockwork marauder of [invoker.real_name]?", ROLE_SERVANT_OF_RATVAR, null, FALSE, 50)
|
||||
var/list/marauder_candidates = pollCandidates("Do you want to play as the clockwork marauder of [invoker.real_name]?", ROLE_SERVANT_OF_RATVAR, null, FALSE, 50, POLL_IGNORE_CLOCKWORK_MARAUDER)
|
||||
if(!check_special_requirements())
|
||||
return FALSE
|
||||
if(!marauder_candidates.len)
|
||||
@@ -281,13 +281,13 @@
|
||||
|
||||
/datum/clockwork_scripture/create_object/tinkerers_daemon/check_special_requirements()
|
||||
var/servants = 0
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
for(var/mob/living/L in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(L))
|
||||
servants++
|
||||
if(servants * 0.2 < clockwork_daemons)
|
||||
if(servants * 0.2 < GLOB.clockwork_daemons)
|
||||
to_chat(invoker, "<span class='nezbere'>\"Daemons are already disabled, making more of them would be a waste.\"</span>")
|
||||
return FALSE
|
||||
if(servants * 0.2 < clockwork_daemons+1)
|
||||
if(servants * 0.2 < GLOB.clockwork_daemons+1)
|
||||
to_chat(invoker, "<span class='nezbere'>\"This daemon would be useless, friend.\"</span>")
|
||||
return FALSE
|
||||
return ..()
|
||||
|
||||
@@ -17,11 +17,20 @@
|
||||
timeout_time = 50
|
||||
|
||||
/datum/clockwork_scripture/ranged_ability/linked_vanguard/check_special_requirements()
|
||||
if(islist(invoker.stun_absorption) && invoker.stun_absorption["vanguard"] && invoker.stun_absorption["vanguard"]["end_time"] > world.time)
|
||||
if(!GLOB.ratvar_awakens && islist(invoker.stun_absorption) && invoker.stun_absorption["vanguard"] && invoker.stun_absorption["vanguard"]["end_time"] > world.time)
|
||||
to_chat(invoker, "<span class='warning'>You are already shielded by a Vanguard!</span>")
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/datum/clockwork_scripture/ranged_ability/linked_vanguard/scripture_effects()
|
||||
if(GLOB.ratvar_awakens) //hey, ratvar's up! give everybody stun immunity.
|
||||
for(var/mob/living/L in view(7, get_turf(invoker)))
|
||||
if(L.stat != DEAD && is_servant_of_ratvar(L))
|
||||
L.apply_status_effect(STATUS_EFFECT_VANGUARD)
|
||||
CHECK_TICK
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
//Judicial Marker: places a judicial marker at a target location
|
||||
/datum/clockwork_scripture/ranged_ability/judicial_marker
|
||||
name = "Judicial Marker"
|
||||
@@ -40,3 +49,4 @@
|
||||
/datum/clockwork_scripture/channeled/volt_void/cyborg
|
||||
quickbind_desc = "Allows you to fire energy rays at target locations using your own power. Failing to fire causes backlash.<br><b>Maximum 4 chants.</b>"
|
||||
tier = SCRIPTURE_PERIPHERAL
|
||||
quickbind = FALSE
|
||||
|
||||
@@ -74,13 +74,19 @@
|
||||
quickbind_desc = "Allows you to temporarily absorb stuns. All stuns absorbed will affect you when disabled."
|
||||
|
||||
/datum/clockwork_scripture/vanguard/check_special_requirements()
|
||||
if(islist(invoker.stun_absorption) && invoker.stun_absorption["vanguard"] && invoker.stun_absorption["vanguard"]["end_time"] > world.time)
|
||||
if(!GLOB.ratvar_awakens && islist(invoker.stun_absorption) && invoker.stun_absorption["vanguard"] && invoker.stun_absorption["vanguard"]["end_time"] > world.time)
|
||||
to_chat(invoker, "<span class='warning'>You are already shielded by a Vanguard!</span>")
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/datum/clockwork_scripture/vanguard/scripture_effects()
|
||||
invoker.apply_status_effect(STATUS_EFFECT_VANGUARD)
|
||||
if(GLOB.ratvar_awakens)
|
||||
for(var/mob/living/L in view(7, get_turf(invoker)))
|
||||
if(L.stat != DEAD && is_servant_of_ratvar(L))
|
||||
L.apply_status_effect(STATUS_EFFECT_VANGUARD)
|
||||
CHECK_TICK
|
||||
else
|
||||
invoker.apply_status_effect(STATUS_EFFECT_VANGUARD)
|
||||
return TRUE
|
||||
|
||||
|
||||
@@ -128,8 +134,8 @@
|
||||
|
||||
/datum/clockwork_scripture/ranged_ability/geis_prep/run_scripture()
|
||||
var/servants = 0
|
||||
if(!ratvar_awakens)
|
||||
for(var/mob/living/M in all_clockwork_mobs)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
for(var/mob/living/M in GLOB.all_clockwork_mobs)
|
||||
if(ishuman(M) || issilicon(M))
|
||||
servants++
|
||||
if(servants > SCRIPT_SERVANT_REQ)
|
||||
@@ -159,8 +165,8 @@
|
||||
|
||||
/datum/clockwork_scripture/geis/run_scripture()
|
||||
var/servants = 0
|
||||
if(!ratvar_awakens)
|
||||
for(var/mob/living/M in all_clockwork_mobs)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
for(var/mob/living/M in GLOB.all_clockwork_mobs)
|
||||
if(ishuman(M) || issilicon(M))
|
||||
servants++
|
||||
if(target.buckled)
|
||||
@@ -266,7 +272,7 @@
|
||||
var/static/prev_cost = 0
|
||||
|
||||
/datum/clockwork_scripture/create_object/tinkerers_cache/creation_update()
|
||||
var/cache_cost_increase = min(round(clockwork_caches*0.25), 5)
|
||||
var/cache_cost_increase = min(round(GLOB.clockwork_caches*0.25), 5)
|
||||
if(cache_cost_increase != prev_cost)
|
||||
prev_cost = cache_cost_increase
|
||||
consumed_components = list(BELLIGERENT_EYE = 0, VANGUARD_COGWHEEL = 0, GEIS_CAPACITOR = 0, REPLICANT_ALLOY = 1, HIEROPHANT_ANSIBLE = 0)
|
||||
@@ -279,14 +285,14 @@
|
||||
|
||||
//Wraith Spectacles: Creates a pair of wraith spectacles, which grant xray vision but damage vision slowly.
|
||||
/datum/clockwork_scripture/create_object/wraith_spectacles
|
||||
descname = "Xray Vision Glasses"
|
||||
descname = "Limited Xray Vision Glasses"
|
||||
name = "Wraith Spectacles"
|
||||
desc = "Fabricates a pair of glasses that provides true sight but quickly damage vision, eventually causing blindness if worn for too long."
|
||||
desc = "Fabricates a pair of glasses which grant true sight but cause gradual vision loss."
|
||||
invocations = list("Show the truth of this world to me!")
|
||||
channel_time = 10
|
||||
whispered = TRUE
|
||||
object_path = /obj/item/clothing/glasses/wraith_spectacles
|
||||
creator_message = "<span class='brass'>You form a pair of wraith spectacles, which will grant true sight when worn.</span>"
|
||||
creator_message = "<span class='brass'>You form a pair of wraith spectacles, which grant true sight but cause gradual vision loss.</span>"
|
||||
usage_tip = "\"True sight\" means that you are able to see through walls and in darkness."
|
||||
tier = SCRIPTURE_DRIVER
|
||||
space_allowed = TRUE
|
||||
|
||||
@@ -2,17 +2,17 @@
|
||||
// JUDGEMENT //
|
||||
///////////////
|
||||
|
||||
//Ark of the Clockwork Justiciar: Creates a Gateway to the Celestial Derelict, either summoning ratvar or proselytizing everything.
|
||||
//Ark of the Clockwork Justiciar: Creates a Gateway to the Celestial Derelict, summoning ratvar.
|
||||
/datum/clockwork_scripture/create_object/ark_of_the_clockwork_justiciar
|
||||
descname = "Structure, Win Condition"
|
||||
name = "Ark of the Clockwork Justiciar"
|
||||
desc = "Tears apart a rift in spacetime to Reebe, the Celestial Derelict, using a massive amount of components.\n\
|
||||
This gateway will either call forth Ratvar from his exile if that is the task He has set you, or proselytize the entire station if it is not."
|
||||
This gateway will, after some time, call forth Ratvar from his exile and massively empower all scriptures and tools."
|
||||
invocations = list("ARMORER! FRIGHT! AMPERAGE! VANGUARD! I CALL UPON YOU!!", \
|
||||
"THE TIME HAS COME FOR OUR MASTER TO BREAK THE CHAINS OF EXILE!!", \
|
||||
"LEND US YOUR AID! ENGINE COMES!!")
|
||||
channel_time = 150
|
||||
consumed_components = list(BELLIGERENT_EYE = 3, VANGUARD_COGWHEEL = 3, GEIS_CAPACITOR = 3, REPLICANT_ALLOY = 3, HIEROPHANT_ANSIBLE = 3)
|
||||
consumed_components = list(BELLIGERENT_EYE = ARK_SUMMON_COST, VANGUARD_COGWHEEL = ARK_SUMMON_COST, GEIS_CAPACITOR = ARK_SUMMON_COST, REPLICANT_ALLOY = ARK_SUMMON_COST, HIEROPHANT_ANSIBLE = ARK_SUMMON_COST)
|
||||
invokers_required = 6
|
||||
multiple_invokers_used = TRUE
|
||||
object_path = /obj/structure/destructible/clockwork/massive/celestial_gateway
|
||||
@@ -22,31 +22,21 @@
|
||||
tier = SCRIPTURE_JUDGEMENT
|
||||
sort_priority = 1
|
||||
|
||||
/datum/clockwork_scripture/create_object/ark_of_the_clockwork_justiciar/New()
|
||||
if(ticker && ticker.mode && ticker.mode.clockwork_objective != CLOCKCULT_GATEWAY)
|
||||
invocations = list("ARMORER! FRIGHT! AMPERAGE! VANGUARD! I CALL UPON YOU!!", \
|
||||
"THIS STATION WILL BE A BEACON OF HOPE IN THE DARKNESS OF SPACE!!", \
|
||||
"HELP US MAKE THIS SHOW ENGINE'S GLORY!!")
|
||||
..()
|
||||
|
||||
/datum/clockwork_scripture/create_object/ark_of_the_clockwork_justiciar/check_special_requirements()
|
||||
if(!slab.no_cost)
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
to_chat(invoker, "<span class='big_brass'>\"I am already here, idiot.\"</span>")
|
||||
return FALSE
|
||||
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in all_clockwork_objects)
|
||||
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in GLOB.all_clockwork_objects)
|
||||
var/area/gate_area = get_area(G)
|
||||
to_chat(invoker, "<span class='userdanger'>There is already a gateway at [gate_area.map_name]!</span>")
|
||||
to_chat(invoker, "<span class='userdanger'>There is already an Ark at [gate_area.map_name]!</span>")
|
||||
return FALSE
|
||||
var/area/A = get_area(invoker)
|
||||
var/turf/T = get_turf(invoker)
|
||||
if(!T || T.z != ZLEVEL_STATION || istype(A, /area/shuttle) || !A.blob_allowed)
|
||||
to_chat(invoker, "<span class='warning'>You must be on the station to activate the Ark!</span>")
|
||||
return FALSE
|
||||
if(clockwork_gateway_activated)
|
||||
if(ticker && ticker.mode && ticker.mode.clockwork_objective != CLOCKCULT_GATEWAY)
|
||||
to_chat(invoker, "<span class='nezbere'>\"Look upon his works. Is it not glorious?\"</span>")
|
||||
else
|
||||
to_chat(invoker, "<span class='warning'>Ratvar's recent banishment renders him too weak to be wrung forth from Reebe!</span>")
|
||||
if(GLOB.clockwork_gateway_activated)
|
||||
to_chat(invoker, "<span class='warning'>Ratvar's recent banishment renders him too weak to be wrung forth from Reebe!</span>")
|
||||
return FALSE
|
||||
return ..()
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
sort_priority = 2
|
||||
|
||||
/datum/clockwork_scripture/invoke_inathneq/check_special_requirements()
|
||||
if(!slab.no_cost && clockwork_generals_invoked["inath-neq"] > world.time)
|
||||
if(!slab.no_cost && GLOB.clockwork_generals_invoked["inath-neq"] > world.time)
|
||||
to_chat(invoker, "<span class='inathneq'>\"[text2ratvar("I cannot lend you my aid yet, champion. Please be careful.")]\"</span>\n\
|
||||
<span class='warning'>Inath-neq has already been invoked recently! You must wait several minutes before calling upon the Resonant Cogwheel.</span>")
|
||||
return FALSE
|
||||
@@ -25,7 +25,7 @@
|
||||
/datum/clockwork_scripture/invoke_inathneq/scripture_effects()
|
||||
new/obj/effect/clockwork/general_marker/inathneq(get_turf(invoker))
|
||||
hierophant_message("<span class='inathneq_large'>[text2ratvar("Vanguard: \"I lend you my aid, champions! Let glory guide your blows!")]\"</span>", FALSE, invoker)
|
||||
clockwork_generals_invoked["inath-neq"] = world.time + CLOCKWORK_GENERAL_COOLDOWN
|
||||
GLOB.clockwork_generals_invoked["inath-neq"] = world.time + CLOCKWORK_GENERAL_COOLDOWN
|
||||
playsound(invoker, 'sound/magic/clockwork/invoke_general.ogg', 50, 0)
|
||||
if(invoker.real_name == "Lucio")
|
||||
clockwork_say(invoker, text2ratvar("Aww, let's break it DOWN!!"))
|
||||
@@ -56,11 +56,11 @@
|
||||
"\"What a waste of my power.\"", "\"I'm sure I could just control these minds instead, but they never ask.\"")
|
||||
|
||||
/datum/clockwork_scripture/invoke_sevtug/check_special_requirements()
|
||||
if(!slab.no_cost && clockwork_generals_invoked["sevtug"] > world.time)
|
||||
if(!slab.no_cost && GLOB.clockwork_generals_invoked["sevtug"] > world.time)
|
||||
to_chat(invoker, "<span class='sevtug'>\"[text2ratvar("Is it really so hard - even for a simpleton like you - to grasp the concept of waiting?")]\"</span>\n\
|
||||
<span class='warning'>Sevtug has already been invoked recently! You must wait several minutes before calling upon the Formless Pariah.</span>")
|
||||
return FALSE
|
||||
if(!slab.no_cost && ratvar_awakens)
|
||||
if(!slab.no_cost && GLOB.ratvar_awakens)
|
||||
to_chat(invoker, "<span class='sevtug'>\"[text2ratvar("Do you really think anything I can do right now will compare to Engine's power?")]\"</span>\n\
|
||||
<span class='warning'>Sevtug will not grant his power while Ratvar's dwarfs his own!</span>")
|
||||
return FALSE
|
||||
@@ -69,11 +69,11 @@
|
||||
/datum/clockwork_scripture/invoke_sevtug/scripture_effects()
|
||||
new/obj/effect/clockwork/general_marker/sevtug(get_turf(invoker))
|
||||
hierophant_message("<span class='sevtug_large'>[text2ratvar("Fright: \"I heed your call, idiots. Get going and use this chance while it lasts!")]\"</span>", FALSE, invoker)
|
||||
clockwork_generals_invoked["sevtug"] = world.time + GLOBAL_CLOCKWORK_GENERAL_COOLDOWN
|
||||
GLOB.clockwork_generals_invoked["sevtug"] = world.time + GLOBAL_CLOCKWORK_GENERAL_COOLDOWN
|
||||
playsound(invoker, 'sound/magic/clockwork/invoke_general.ogg', 50, 0)
|
||||
var/hum = get_sfx('sound/effects/screech.ogg') //like playsound, same sound for everyone affected
|
||||
var/turf/T = get_turf(invoker)
|
||||
for(var/mob/living/carbon/human/H in living_mob_list)
|
||||
for(var/mob/living/carbon/human/H in GLOB.living_mob_list)
|
||||
if(H.z == invoker.z && !is_servant_of_ratvar(H))
|
||||
var/distance = 0
|
||||
distance += get_dist(T, get_turf(H))
|
||||
@@ -118,11 +118,11 @@
|
||||
multiple_invokers_used = TRUE
|
||||
|
||||
/datum/clockwork_scripture/invoke_nezbere/check_special_requirements()
|
||||
if(!slab.no_cost && clockwork_generals_invoked["nezbere"] > world.time)
|
||||
if(!slab.no_cost && GLOB.clockwork_generals_invoked["nezbere"] > world.time)
|
||||
to_chat(invoker, "<span class='nezbere'>\"[text2ratvar("Not just yet, friend. Patience is a virtue.")]\"</span>\n\
|
||||
<span class='warning'>Nezbere has already been invoked recently! You must wait several minutes before calling upon the Brass Eidolon.</span>")
|
||||
return FALSE
|
||||
if(!slab.no_cost && ratvar_awakens)
|
||||
if(!slab.no_cost && GLOB.ratvar_awakens)
|
||||
to_chat(invoker, "<span class='nezbere'>\"[text2ratvar("Our master is here already. You do not require my help, friend.")]\"</span>\n\
|
||||
<span class='warning'>There is no need for Nezbere's assistance while Ratvar is risen!</span>")
|
||||
return FALSE
|
||||
@@ -131,17 +131,19 @@
|
||||
/datum/clockwork_scripture/invoke_nezbere/scripture_effects()
|
||||
new/obj/effect/clockwork/general_marker/nezbere(get_turf(invoker))
|
||||
hierophant_message("<span class='nezbere_large'>[text2ratvar("Armorer: \"I heed your call, champions. May your artifacts bring ruin upon the heathens that oppose our master!")]\"</span>", FALSE, invoker)
|
||||
clockwork_generals_invoked["nezbere"] = world.time + GLOBAL_CLOCKWORK_GENERAL_COOLDOWN
|
||||
GLOB.clockwork_generals_invoked["nezbere"] = world.time + GLOBAL_CLOCKWORK_GENERAL_COOLDOWN
|
||||
playsound(invoker, 'sound/magic/clockwork/invoke_general.ogg', 50, 0)
|
||||
nezbere_invoked++
|
||||
for(var/obj/O in all_clockwork_objects)
|
||||
GLOB.nezbere_invoked++
|
||||
for(var/obj/O in GLOB.all_clockwork_objects)
|
||||
O.ratvar_act()
|
||||
spawn(600)
|
||||
nezbere_invoked--
|
||||
for(var/obj/O in all_clockwork_objects)
|
||||
O.ratvar_act()
|
||||
addtimer(CALLBACK(GLOBAL_PROC, /proc/reset_nezbere_invocation), 600)
|
||||
return TRUE
|
||||
|
||||
/proc/reset_nezbere_invocation()
|
||||
GLOB.nezbere_invoked--
|
||||
for(var/obj/O in GLOB.all_clockwork_objects)
|
||||
O.ratvar_act()
|
||||
|
||||
|
||||
//Invoke Nzcrentr, the Eternal Thunderbolt: Imbues an immense amount of energy into the invoker. After several seconds, everyone near the invoker will be hit with a devastating lightning blast.
|
||||
/datum/clockwork_scripture/invoke_nzcrentr
|
||||
@@ -158,7 +160,7 @@
|
||||
sort_priority = 5
|
||||
|
||||
/datum/clockwork_scripture/invoke_nzcrentr/check_special_requirements()
|
||||
if(!slab.no_cost && clockwork_generals_invoked["nzcrentr"] > world.time)
|
||||
if(!slab.no_cost && GLOB.clockwork_generals_invoked["nzcrentr"] > world.time)
|
||||
to_chat(invoker, "<span class='nzcrentr'>\"[text2ratvar("The boss says you have to wait. Hey, do you think he would mind if I killed you? ...He would? Ok.")]\"</span>\n\
|
||||
<span class='warning'>Nzcrentr has already been invoked recently! You must wait several minutes before calling upon the Eternal Thunderbolt.</span>")
|
||||
return FALSE
|
||||
@@ -166,7 +168,7 @@
|
||||
|
||||
/datum/clockwork_scripture/invoke_nzcrentr/scripture_effects()
|
||||
new/obj/effect/clockwork/general_marker/nzcrentr(get_turf(invoker))
|
||||
clockwork_generals_invoked["nzcrentr"] = world.time + CLOCKWORK_GENERAL_COOLDOWN
|
||||
GLOB.clockwork_generals_invoked["nzcrentr"] = world.time + CLOCKWORK_GENERAL_COOLDOWN
|
||||
hierophant_message("<span class='nzcrentr_large'>[text2ratvar("Amperage: \"[invoker.real_name] has called forth my power. Hope [invoker.p_they()] [invoker.p_do()] not shatter under it!")]\"</span>", FALSE, invoker)
|
||||
invoker.visible_message("<span class='warning'>[invoker] begins to radiate a blinding light!</span>", \
|
||||
"<span class='nzcrentr'>\"[text2ratvar("The boss says it's okay to do this. Don't blame me if you die from it.")]\"</span>\n\
|
||||
|
||||
@@ -180,17 +180,13 @@
|
||||
owner.visible_message("<span class='warning'>A strange spear materializes in [owner]'s hands!</span>", "<span class='brass'>You call forth your spear!</span>")
|
||||
var/obj/item/clockwork/ratvarian_spear/R = new(get_turf(usr))
|
||||
owner.put_in_hands(R)
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
to_chat(owner, "<span class='warning'>Your spear begins to break down in this plane of existence. You can't use it for long!</span>")
|
||||
cooldown = base_cooldown + world.time
|
||||
owner.update_action_buttons_icon()
|
||||
addtimer(CALLBACK(src, .proc/update_actions), base_cooldown)
|
||||
addtimer(CALLBACK(owner, /mob.proc/update_action_buttons_icon), base_cooldown)
|
||||
return TRUE
|
||||
|
||||
/datum/action/innate/function_call/proc/update_actions()
|
||||
if(owner)
|
||||
owner.update_action_buttons_icon()
|
||||
|
||||
|
||||
//Spatial Gateway: Allows the invoker to teleport themselves and any nearby allies to a conscious servant or clockwork obelisk.
|
||||
/datum/clockwork_scripture/spatial_gateway
|
||||
@@ -215,13 +211,14 @@
|
||||
to_chat(invoker, "<span class='warning'>You must not be inside an object to use this scripture!</span>")
|
||||
return FALSE
|
||||
var/other_servants = 0
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
for(var/mob/living/L in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(L) && !L.stat && L != invoker)
|
||||
other_servants++
|
||||
for(var/obj/structure/destructible/clockwork/powered/clockwork_obelisk/O in all_clockwork_objects)
|
||||
other_servants++
|
||||
for(var/obj/structure/destructible/clockwork/powered/clockwork_obelisk/O in GLOB.all_clockwork_objects)
|
||||
if(O.anchored)
|
||||
other_servants++
|
||||
if(!other_servants)
|
||||
to_chat(invoker, "<span class='warning'>There are no other servants or clockwork obelisks!</span>")
|
||||
to_chat(invoker, "<span class='warning'>There are no other conscious servants or anchored clockwork obelisks!</span>")
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
@@ -232,7 +229,7 @@
|
||||
if(!L.stat && is_servant_of_ratvar(L))
|
||||
portal_uses++
|
||||
duration += 40 //4 seconds
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
portal_uses = max(portal_uses, 100) //Very powerful if Ratvar has been summoned
|
||||
duration = max(duration, 100)
|
||||
return slab.procure_gateway(invoker, duration, portal_uses)
|
||||
@@ -266,7 +263,7 @@
|
||||
var/turf/T = get_turf(invoker)
|
||||
if(!ray.run_scripture() && slab && invoker)
|
||||
if(can_recite() && T == get_turf(invoker))
|
||||
if(!ratvar_awakens)
|
||||
if(!GLOB.ratvar_awakens)
|
||||
var/obj/structure/destructible/clockwork/powered/volt_checker/VC = new/obj/structure/destructible/clockwork/powered/volt_checker(get_turf(invoker))
|
||||
var/multiplier = 0.5
|
||||
var/usable_power = min(Floor(VC.total_accessable_power() * 0.2, MIN_CLOCKCULT_POWER), 1000)
|
||||
|
||||
@@ -21,15 +21,15 @@
|
||||
/obj/structure/destructible/clockwork/New()
|
||||
..()
|
||||
change_construction_value(construction_value)
|
||||
all_clockwork_objects += src
|
||||
GLOB.all_clockwork_objects += src
|
||||
|
||||
/obj/structure/destructible/clockwork/Destroy()
|
||||
change_construction_value(-construction_value)
|
||||
all_clockwork_objects -= src
|
||||
GLOB.all_clockwork_objects -= src
|
||||
return ..()
|
||||
|
||||
/obj/structure/destructible/clockwork/ratvar_act()
|
||||
if(ratvar_awakens || clockwork_gateway_activated)
|
||||
if(GLOB.ratvar_awakens || GLOB.clockwork_gateway_activated)
|
||||
obj_integrity = max_integrity
|
||||
|
||||
/obj/structure/destructible/clockwork/narsie_act()
|
||||
@@ -78,7 +78,7 @@
|
||||
return ..()
|
||||
|
||||
/obj/structure/destructible/clockwork/proc/get_efficiency_mod(increasing)
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
if(increasing)
|
||||
return 0.5
|
||||
return 2
|
||||
@@ -144,10 +144,10 @@
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/New()
|
||||
..()
|
||||
poi_list += src
|
||||
GLOB.poi_list += src
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/Destroy()
|
||||
poi_list -= src
|
||||
GLOB.poi_list -= src
|
||||
return ..()
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/singularity_pull(S, current_size)
|
||||
@@ -177,7 +177,7 @@
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/ratvar_act()
|
||||
..()
|
||||
if(nezbere_invoked)
|
||||
if(GLOB.nezbere_invoked)
|
||||
needs_power = FALSE
|
||||
else
|
||||
needs_power = initial(needs_power)
|
||||
@@ -225,7 +225,7 @@
|
||||
new /obj/effect/overlay/temp/emp(loc)
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/proc/total_accessable_power() //how much power we have and can use
|
||||
if(!needs_power || ratvar_awakens)
|
||||
if(!needs_power || GLOB.ratvar_awakens)
|
||||
return INFINITY //oh yeah we've got power why'd you ask
|
||||
|
||||
var/power = 0
|
||||
@@ -237,7 +237,7 @@
|
||||
var/power = 0
|
||||
var/area/A = get_area(src)
|
||||
var/area/targetAPCA
|
||||
for(var/obj/machinery/power/apc/APC in apcs_list)
|
||||
for(var/obj/machinery/power/apc/APC in GLOB.apcs_list)
|
||||
var/area/APCA = get_area(APC)
|
||||
if(APCA == A)
|
||||
target_apc = APC
|
||||
@@ -259,7 +259,7 @@
|
||||
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/proc/try_use_power(amount) //try to use an amount of power
|
||||
if(!needs_power || ratvar_awakens)
|
||||
if(!needs_power || GLOB.ratvar_awakens)
|
||||
return 1
|
||||
if(amount <= 0)
|
||||
return FALSE
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
//The gateway to Reebe, from which Ratvar emerges.
|
||||
/obj/structure/destructible/clockwork/massive/celestial_gateway
|
||||
name = "gateway to the Celestial Derelict"
|
||||
name = "ark of the Clockwork Justicar"
|
||||
desc = "A massive, thrumming rip in spacetime."
|
||||
clockwork_desc = "A portal to the Celestial Derelict. Massive and intimidating, it is the only thing that can both transport Ratvar and withstand the massive amount of energy he emits."
|
||||
obj_integrity = 500
|
||||
@@ -19,10 +19,9 @@
|
||||
var/second_sound_played = FALSE
|
||||
var/third_sound_played = FALSE
|
||||
var/fourth_sound_played = FALSE
|
||||
var/ratvar_portal = TRUE //if the gateway actually summons ratvar or just produces a hugeass conversion burst
|
||||
var/obj/effect/clockwork/overlay/gateway_glow/glow
|
||||
var/obj/effect/countdown/clockworkgate/countdown
|
||||
var/list/required_components = list(BELLIGERENT_EYE = 7, VANGUARD_COGWHEEL = 7, GEIS_CAPACITOR = 7, REPLICANT_ALLOY = 7, HIEROPHANT_ANSIBLE = 7)
|
||||
var/list/required_components = list(BELLIGERENT_EYE = ARK_CONSUME_COST, VANGUARD_COGWHEEL = ARK_CONSUME_COST, GEIS_CAPACITOR = ARK_CONSUME_COST, REPLICANT_ALLOY = ARK_CONSUME_COST, HIEROPHANT_ANSIBLE = ARK_CONSUME_COST)
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/celestial_gateway/New()
|
||||
..()
|
||||
@@ -30,33 +29,20 @@
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/celestial_gateway/proc/spawn_animation()
|
||||
var/turf/T = get_turf(src)
|
||||
var/objective_is_gateway = (ticker && ticker.mode && ticker.mode.clockwork_objective == CLOCKCULT_GATEWAY)
|
||||
new/obj/effect/clockwork/general_marker/inathneq(T)
|
||||
if(objective_is_gateway)
|
||||
hierophant_message("<span class='inathneq'>\"[text2ratvar("Engine, come forth and show your servants your mercy")]!\"</span>")
|
||||
else
|
||||
hierophant_message("<span class='inathneq'>\"[text2ratvar("We will show all the mercy of Engine")]!\"</span>")
|
||||
hierophant_message("<span class='inathneq'>\"[text2ratvar("Engine, come forth and show your servants your mercy")]!\"</span>")
|
||||
playsound(T, 'sound/magic/clockwork/invoke_general.ogg', 30, 0)
|
||||
sleep(10)
|
||||
new/obj/effect/clockwork/general_marker/sevtug(T)
|
||||
if(objective_is_gateway)
|
||||
hierophant_message("<span class='sevtug'>\"[text2ratvar("Engine, come forth and show this station your decorating skills")]!\"</span>")
|
||||
else
|
||||
hierophant_message("<span class='sevtug'>\"[text2ratvar("We will show all Engine's decorating skills")]!\"</span>")
|
||||
hierophant_message("<span class='sevtug'>\"[text2ratvar("Engine, come forth and show this station your decorating skills")]!\"</span>")
|
||||
playsound(T, 'sound/magic/clockwork/invoke_general.ogg', 45, 0)
|
||||
sleep(10)
|
||||
new/obj/effect/clockwork/general_marker/nezbere(T)
|
||||
if(objective_is_gateway)
|
||||
hierophant_message("<span class='nezbere'>\"[text2ratvar("Engine, come forth and shine your light across this realm")]!!\"</span>")
|
||||
else
|
||||
hierophant_message("<span class='nezbere'>\"[text2ratvar("We will show all Engine's light")]!!\"</span>")
|
||||
hierophant_message("<span class='nezbere'>\"[text2ratvar("Engine, come forth and shine your light across this realm")]!!\"</span>")
|
||||
playsound(T, 'sound/magic/clockwork/invoke_general.ogg', 60, 0)
|
||||
sleep(10)
|
||||
new/obj/effect/clockwork/general_marker/nzcrentr(T)
|
||||
if(objective_is_gateway)
|
||||
hierophant_message("<span class='nzcrentr'>\"[text2ratvar("Engine, come forth")].\"</span>")
|
||||
else
|
||||
hierophant_message("<span class='nzcrentr'>\"[text2ratvar("We will show all Engine's power")].\"</span>")
|
||||
hierophant_message("<span class='nzcrentr'>\"[text2ratvar("Engine, come forth")].\"</span>")
|
||||
playsound(T, 'sound/magic/clockwork/invoke_general.ogg', 75, 0)
|
||||
sleep(10)
|
||||
playsound(T, 'sound/magic/clockwork/invoke_general.ogg', 100, 0)
|
||||
@@ -74,9 +60,7 @@
|
||||
countdown = new(src)
|
||||
countdown.start()
|
||||
var/area/gate_area = get_area(src)
|
||||
hierophant_message("<span class='large_brass'><b>A gateway to the Celestial Derelict has been created in [gate_area.map_name]!</b></span>", FALSE, src)
|
||||
if(!objective_is_gateway)
|
||||
ratvar_portal = FALSE
|
||||
hierophant_message("<span class='large_brass'><b>An Ark of the Clockwork Justicar has been created in [gate_area.map_name]!</b></span>", FALSE, src)
|
||||
SSshuttle.registerHostileEnvironment(src)
|
||||
START_PROCESSING(SSprocessing, src)
|
||||
|
||||
@@ -84,7 +68,7 @@
|
||||
STOP_PROCESSING(SSprocessing, src)
|
||||
if(!purpose_fulfilled)
|
||||
var/area/gate_area = get_area(src)
|
||||
hierophant_message("<span class='large_brass'><b>A gateway to the Celestial Derelict has fallen at [gate_area.map_name]!</b></span>")
|
||||
hierophant_message("<span class='large_brass'><b>An Ark of the Clockwork Justicar has fallen at [gate_area.map_name]!</b></span>")
|
||||
send_to_playing_players(sound(null, 0, channel = 8))
|
||||
var/was_stranded = SSshuttle.emergency.mode == SHUTTLE_STRANDED
|
||||
SSshuttle.clearHostileEnvironment(src)
|
||||
@@ -179,14 +163,14 @@
|
||||
to_chat(user, "<span class='[get_component_span(i)]'>[get_component_name(i)][i != REPLICANT_ALLOY ? "s":""]:</span> \
|
||||
<span class='[get_component_span(i)]_large'>[required_components[i]]</span>")
|
||||
else
|
||||
to_chat(user, "<span class='big'><b>Seconds until [ratvar_portal ? "Ratvar's arrival":"Proselytization"]:</b> [get_arrival_text(TRUE)]</span>")
|
||||
to_chat(user, "<span class='big'><b>Seconds until Ratvar's arrival:</b> [get_arrival_text(TRUE)]</span>")
|
||||
switch(progress_in_seconds)
|
||||
if(-INFINITY to GATEWAY_REEBE_FOUND)
|
||||
to_chat(user, "<span class='heavy_brass'>It's still opening.</span>")
|
||||
if(GATEWAY_REEBE_FOUND to GATEWAY_RATVAR_COMING)
|
||||
to_chat(user, "<span class='heavy_brass'>It's reached the Celestial Derelict and is drawing power from it.</span>")
|
||||
if(GATEWAY_RATVAR_COMING to INFINITY)
|
||||
to_chat(user, "<span class='heavy_brass'>[ratvar_portal ? "Ratvar is coming through the gateway":"The gateway is glowing with massed power"]!</span>")
|
||||
to_chat(user, "<span class='heavy_brass'>Ratvar is coming through the gateway!</span>")
|
||||
else
|
||||
switch(progress_in_seconds)
|
||||
if(-INFINITY to GATEWAY_REEBE_FOUND)
|
||||
@@ -194,11 +178,11 @@
|
||||
if(GATEWAY_REEBE_FOUND to GATEWAY_RATVAR_COMING)
|
||||
to_chat(user, "<span class='warning'>It seems to be leading somewhere.</span>")
|
||||
if(GATEWAY_RATVAR_COMING to INFINITY)
|
||||
to_chat(user, "<span class='boldwarning'>[ratvar_portal ? "Something is coming through":"It's glowing brightly"]!</span>")
|
||||
to_chat(user, "<span class='boldwarning'>Something is coming through!</span>")
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/celestial_gateway/process()
|
||||
if(!first_sound_played || prob(7))
|
||||
for(var/M in player_list)
|
||||
for(var/M in GLOB.player_list)
|
||||
if(M && !isnewplayer(M))
|
||||
to_chat(M, "<span class='warning'><b>You hear otherworldly sounds from the [dir2text(get_dir(get_turf(M), get_turf(src)))]...</span>")
|
||||
if(!obj_integrity)
|
||||
@@ -227,9 +211,9 @@
|
||||
var/used_components = FALSE
|
||||
for(var/i in required_components)
|
||||
if(required_components[i])
|
||||
var/to_use = min(clockwork_component_cache[i], required_components[i])
|
||||
var/to_use = min(GLOB.clockwork_component_cache[i], required_components[i])
|
||||
required_components[i] -= to_use
|
||||
clockwork_component_cache[i] -= to_use
|
||||
GLOB.clockwork_component_cache[i] -= to_use
|
||||
if(to_use)
|
||||
used_components = TRUE
|
||||
if(used_components)
|
||||
@@ -276,39 +260,28 @@
|
||||
animate(glow, transform = matrix() * 3, alpha = 0, time = 5)
|
||||
var/turf/startpoint = get_turf(src)
|
||||
QDEL_IN(src, 3)
|
||||
if(ratvar_portal)
|
||||
sleep(3)
|
||||
clockwork_gateway_activated = TRUE
|
||||
new/obj/structure/destructible/clockwork/massive/ratvar(startpoint)
|
||||
else
|
||||
INVOKE_ASYNC(SSshuttle.emergency, /obj/docking_port/mobile/emergency.proc/request, null, 0) //call the shuttle immediately
|
||||
sleep(3)
|
||||
clockwork_gateway_activated = TRUE
|
||||
send_to_playing_players("<span class='ratvar'>\"[text2ratvar("Behold")]!\"</span>\n<span class='inathneq_large'>\"[text2ratvar("See Engine's mercy")]!\"</span>\n\
|
||||
<span class='sevtug_large'>\"[text2ratvar("Observe Engine's design skills")]!\"</span>\n<span class='nezbere_large'>\"[text2ratvar("Behold Engine's light")]!!\"</span>\n\
|
||||
<span class='nzcrentr_large'>\"[text2ratvar("Gaze upon Engine's power")]!\"</span>")
|
||||
send_to_playing_players('sound/magic/clockwork/invoke_general.ogg')
|
||||
var/x0 = startpoint.x
|
||||
var/y0 = startpoint.y
|
||||
for(var/I in spiral_range_turfs(255, startpoint))
|
||||
var/turf/T = I
|
||||
if(!T)
|
||||
continue
|
||||
var/dist = cheap_hypotenuse(T.x, T.y, x0, y0)
|
||||
if(dist < 100)
|
||||
dist = TRUE
|
||||
else
|
||||
dist = FALSE
|
||||
T.ratvar_act(dist)
|
||||
CHECK_TICK
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
L.ratvar_act()
|
||||
for(var/I in all_clockwork_mobs)
|
||||
var/mob/M = I
|
||||
if(M.stat == CONSCIOUS)
|
||||
clockwork_say(M, text2ratvar(pick("Purge all untruths and honor Engine!", "All glory to Engine's light!", "Engine's power is unmatched!")))
|
||||
sleep(3)
|
||||
GLOB.clockwork_gateway_activated = TRUE
|
||||
new/obj/structure/destructible/clockwork/massive/ratvar(startpoint)
|
||||
send_to_playing_players("<span class='inathneq_large'>\"[text2ratvar("See Engine's mercy")]!\"</span>\n\
|
||||
<span class='sevtug_large'>\"[text2ratvar("Observe Engine's design skills")]!\"</span>\n<span class='nezbere_large'>\"[text2ratvar("Behold Engine's light")]!!\"</span>\n\
|
||||
<span class='nzcrentr_large'>\"[text2ratvar("Gaze upon Engine's power")].\"</span>")
|
||||
send_to_playing_players('sound/magic/clockwork/invoke_general.ogg')
|
||||
var/x0 = startpoint.x
|
||||
var/y0 = startpoint.y
|
||||
for(var/I in spiral_range_turfs(255, startpoint))
|
||||
var/turf/T = I
|
||||
if(!T)
|
||||
continue
|
||||
var/dist = cheap_hypotenuse(T.x, T.y, x0, y0)
|
||||
if(dist < 100)
|
||||
dist = TRUE
|
||||
else
|
||||
dist = FALSE
|
||||
T.ratvar_act(dist, TRUE)
|
||||
CHECK_TICK
|
||||
|
||||
//the actual appearance of the Gateway to the Celestial Derelict; an object so the edges of the gate can be clicked through.
|
||||
//the actual appearance of the Ark of the Clockwork Justicar; an object so the edges of the gate can be clicked through.
|
||||
/obj/effect/clockwork/overlay/gateway_glow
|
||||
icon = 'icons/effects/96x96.dmi'
|
||||
icon_state = "clockwork_gateway_charging"
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
var/interdiction_range = 14 //how large an area it drains and disables in
|
||||
var/static/list/rage_messages = list("...", "Disgusting.", "Die.", "Foul.", "Worthless.", "Mortal.", "Unfit.", "Weak.", "Fragile.", "Useless.", "Leave my sight!")
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/New()
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/Initialize()
|
||||
..()
|
||||
set_light(1.4, 0.8, "#F42B9D")
|
||||
update_current_glow()
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/examine(mob/user)
|
||||
..()
|
||||
@@ -30,12 +30,25 @@
|
||||
if(is_servant_of_ratvar(user) || isobserver(user))
|
||||
to_chat(user, "<span class='neovgre_small'>If it fails to drain any electronics or has nothing to return power to, it will disable itself for <b>[round(recharge_time/600, 1)]</b> minutes.</span>")
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/update_anchored(mob/user, do_damage)
|
||||
..()
|
||||
update_current_glow()
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/toggle(fast_process, mob/living/user)
|
||||
. = ..()
|
||||
update_current_glow()
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/proc/update_current_glow()
|
||||
if(active)
|
||||
set_light(2, 1.6, "#EE54EE")
|
||||
if(disabled)
|
||||
set_light(2, 1.6, "#151200")
|
||||
else
|
||||
set_light(2, 1.6, "#EE54EE")
|
||||
else
|
||||
set_light(1.4, 0.8, "#F42B9D")
|
||||
if(anchored)
|
||||
set_light(1.4, 0.8, "#F42B9D")
|
||||
else
|
||||
set_light(0)
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/attack_hand(mob/living/user)
|
||||
if(user.canUseTopic(src, !issilicon(user), NO_DEXTERY))
|
||||
@@ -45,7 +58,7 @@
|
||||
toggle(0, user)
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/forced_disable(bad_effects)
|
||||
if(disabled)
|
||||
if(disabled || !anchored)
|
||||
return FALSE
|
||||
if(!active)
|
||||
toggle(0)
|
||||
@@ -53,8 +66,8 @@
|
||||
recharging = world.time + recharge_time
|
||||
flick("interdiction_lens_discharged", src)
|
||||
icon_state = "interdiction_lens_inactive"
|
||||
set_light(2, 1.6, "#151200")
|
||||
disabled = TRUE
|
||||
update_current_glow()
|
||||
return TRUE
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/interdiction_lens/process()
|
||||
@@ -84,7 +97,7 @@
|
||||
var/efficiency = get_efficiency_mod()
|
||||
var/rage_modifier = get_efficiency_mod(TRUE)
|
||||
|
||||
for(var/i in ai_list)
|
||||
for(var/i in GLOB.ai_list)
|
||||
var/mob/living/silicon/ai/AI = i
|
||||
if(AI && AI.stat != DEAD && !is_servant_of_ratvar(AI))
|
||||
unconverted_ai = TRUE
|
||||
|
||||
@@ -47,10 +47,10 @@
|
||||
|
||||
/obj/structure/destructible/clockwork/ocular_warden/ratvar_act()
|
||||
..()
|
||||
if(ratvar_awakens)
|
||||
if(GLOB.ratvar_awakens)
|
||||
damage_per_tick = 10
|
||||
sight_range = 6
|
||||
else if(nezbere_invoked)
|
||||
else if(GLOB.nezbere_invoked)
|
||||
damage_per_tick = 5
|
||||
sight_range = 5
|
||||
else
|
||||
@@ -80,7 +80,7 @@
|
||||
else
|
||||
L.playsound_local(null,'sound/machines/clockcult/ocularwarden-dot2.ogg',50,1)
|
||||
L.adjustFireLoss((!iscultist(L) ? damage_per_tick : damage_per_tick * 2) * get_efficiency_mod()) //Nar-Sian cultists take additional damage
|
||||
if(ratvar_awakens && L)
|
||||
if(GLOB.ratvar_awakens && L)
|
||||
L.adjust_fire_stacks(damage_per_tick)
|
||||
L.IgniteMob()
|
||||
else if(istype(target,/obj/mecha))
|
||||
@@ -97,7 +97,7 @@
|
||||
visible_message("<span class='warning'>[src] swivels to face [target]!</span>")
|
||||
if(isliving(target))
|
||||
var/mob/living/L = target
|
||||
to_chat(L, "<span class='heavy_brass'>\"I SEE YOU!\"</span>\n<span class='userdanger'>[src]'s gaze [ratvar_awakens ? "melts you alive" : "burns you"]!</span>")
|
||||
to_chat(L, "<span class='heavy_brass'>\"I SEE YOU!\"</span>\n<span class='userdanger'>[src]'s gaze [GLOB.ratvar_awakens ? "melts you alive" : "burns you"]!</span>")
|
||||
else if(istype(target,/obj/mecha))
|
||||
var/obj/mecha/M = target
|
||||
to_chat(M.occupant, "<span class='heavy_brass'>\"I SEE YOU!\"</span>" )
|
||||
@@ -105,7 +105,7 @@
|
||||
if(prob(50))
|
||||
visible_message("<span class='notice'>[src][pick(idle_messages)]</span>")
|
||||
else
|
||||
setDir(pick(cardinal))//Random rotation
|
||||
setDir(pick(GLOB.cardinal))//Random rotation
|
||||
|
||||
/obj/structure/destructible/clockwork/ocular_warden/proc/acquire_nearby_targets()
|
||||
. = list()
|
||||
@@ -131,7 +131,7 @@
|
||||
else if(!L.mind)
|
||||
continue
|
||||
. += L
|
||||
for(var/N in mechas_list)
|
||||
for(var/N in GLOB.mechas_list)
|
||||
var/obj/mecha/M = N
|
||||
if(get_dist(M, src) <= sight_range && M.occupant && !is_servant_of_ratvar(M.occupant) && (M in view(sight_range, src)))
|
||||
. += M
|
||||
|
||||
@@ -15,11 +15,12 @@
|
||||
var/atom/prey //Whatever Ratvar is chasing
|
||||
var/clashing = FALSE //If Ratvar is FUCKING FIGHTING WITH NAR-SIE
|
||||
var/proselytize_range = 10
|
||||
dangerous_possession = TRUE
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/ratvar/New()
|
||||
..()
|
||||
ratvar_awakens++
|
||||
for(var/obj/O in all_clockwork_objects)
|
||||
GLOB.ratvar_awakens++
|
||||
for(var/obj/O in GLOB.all_clockwork_objects)
|
||||
O.ratvar_act()
|
||||
START_PROCESSING(SSobj, src)
|
||||
send_to_playing_players("<span class='ratvar'>\"[text2ratvar("ONCE AGAIN MY LIGHT SHALL SHINE ACROSS THIS PATHETIC REALM")]!!\"</span>")
|
||||
@@ -27,11 +28,11 @@
|
||||
var/image/alert_overlay = image('icons/effects/clockwork_effects.dmi', "ratvar_alert")
|
||||
var/area/A = get_area(src)
|
||||
notify_ghosts("The Justiciar's light calls to you! Reach out to Ratvar in [A.name] to be granted a shell to spread his glory!", null, source = src, alert_overlay = alert_overlay)
|
||||
addtimer(CALLBACK(SSshuttle.emergency, /obj/docking_port/mobile/emergency..proc/request, null, 0.1), 50)
|
||||
INVOKE_ASYNC(SSshuttle.emergency, /obj/docking_port/mobile/emergency..proc/request, null, 0)
|
||||
|
||||
/obj/structure/destructible/clockwork/massive/ratvar/Destroy()
|
||||
ratvar_awakens--
|
||||
for(var/obj/O in all_clockwork_objects)
|
||||
GLOB.ratvar_awakens--
|
||||
for(var/obj/O in GLOB.all_clockwork_objects)
|
||||
O.ratvar_act()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
send_to_playing_players("<span class='heavy_brass'><font size=6>\"NO! I will not... be...</font> <font size=5>banished...</font> <font size=4>again...\"</font></span>")
|
||||
@@ -62,27 +63,30 @@
|
||||
T.ratvar_act()
|
||||
for(var/I in circleviewturfs(src, round(proselytize_range * 0.5)))
|
||||
var/turf/T = I
|
||||
T.ratvar_act(1)
|
||||
var/dir_to_step_in = pick(cardinal)
|
||||
T.ratvar_act(TRUE)
|
||||
var/dir_to_step_in = pick(GLOB.cardinal)
|
||||
var/list/meals = list()
|
||||
for(var/mob/living/L in GLOB.living_mob_list) //we want to know who's alive so we don't lose and retarget a single person
|
||||
if(L.z == z && !is_servant_of_ratvar(L) && L.mind)
|
||||
meals += L
|
||||
if(!prey)
|
||||
for(var/obj/singularity/narsie/N in singularities)
|
||||
for(var/obj/singularity/narsie/N in GLOB.singularities)
|
||||
if(N.z == z)
|
||||
prey = N
|
||||
break
|
||||
if(!prey) //In case there's a Nar-Sie
|
||||
var/list/meals = list()
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
if(L.z == z && !is_servant_of_ratvar(L) && L.mind)
|
||||
meals += L
|
||||
if(meals.len)
|
||||
prey = pick(meals)
|
||||
to_chat(prey, "<span class='heavy_brass'><font size=5>\"You will do.\"</font></span>\n\
|
||||
<span class='userdanger'>Something very large and very malevolent begins lumbering its way towards you...</span>")
|
||||
prey << 'sound/effects/ratvar_reveal.ogg'
|
||||
if(!prey && LAZYLEN(meals))
|
||||
prey = pick(meals)
|
||||
to_chat(prey, "<span class='heavy_brass'><font size=5>\"You will do, heretic.\"</font></span>\n\
|
||||
<span class='userdanger'You feel something massive turn its crushing focus to you...</span>")
|
||||
prey << 'sound/effects/ratvar_reveal.ogg'
|
||||
else
|
||||
if((!istype(prey, /obj/singularity/narsie) && prob(10)) || is_servant_of_ratvar(prey) || prey.z != z)
|
||||
to_chat(prey, "<span class='heavy_brass'><font size=5>\"How dull. Leave me.\"</font></span>\n\
|
||||
<span class='userdanger'>You feel tremendous relief as a set of horrible eyes loses sight of you...</span>")
|
||||
if((!istype(prey, /obj/singularity/narsie) && prob(10) && LAZYLEN(meals) > 1) || prey.z != z || !(prey in meals))
|
||||
if(is_servant_of_ratvar(prey))
|
||||
to_chat(prey, "<span class='heavy_brass'><font size=5>\"Serve me well.\"</font></span>\n\
|
||||
<span class='big_brass'>You feel great joy as your god turns His eye to another heretic...</span>")
|
||||
else
|
||||
to_chat(prey, "<span class='heavy_brass'><font size=5>\"No matter. I will find you later, heretic.\"</font></span>\n\
|
||||
<span class='userdanger'>You feel tremendous relief as the crushing focus relents...</span>")
|
||||
prey = null
|
||||
else
|
||||
dir_to_step_in = get_dir(src, prey) //Unlike Nar-Sie, Ratvar ruthlessly chases down his target
|
||||
@@ -109,13 +113,13 @@
|
||||
while(src && narsie)
|
||||
send_to_playing_players('sound/magic/clockwork/ratvar_attack.ogg')
|
||||
sleep(5.2)
|
||||
for(var/mob/M in mob_list)
|
||||
for(var/mob/M in GLOB.mob_list)
|
||||
if(!isnewplayer(M))
|
||||
flash_color(M, flash_color="#966400", flash_time=1)
|
||||
shake_camera(M, 4, 3)
|
||||
var/ratvar_chance = min(ticker.mode.servants_of_ratvar.len, 50)
|
||||
var/narsie_chance = ticker.mode.cult.len
|
||||
for(var/mob/living/simple_animal/hostile/construct/harvester/C in player_list)
|
||||
var/ratvar_chance = min(SSticker.mode.servants_of_ratvar.len, 50)
|
||||
var/narsie_chance = SSticker.mode.cult.len
|
||||
for(var/mob/living/simple_animal/hostile/construct/harvester/C in GLOB.player_list)
|
||||
narsie_chance++
|
||||
ratvar_chance = rand(base_victory_chance, ratvar_chance)
|
||||
narsie_chance = rand(base_victory_chance, min(narsie_chance, 50))
|
||||
@@ -125,7 +129,7 @@
|
||||
sleep(rand(2,5))
|
||||
send_to_playing_players('sound/magic/clockwork/narsie_attack.ogg')
|
||||
sleep(7.4)
|
||||
for(var/mob/M in mob_list)
|
||||
for(var/mob/M in GLOB.mob_list)
|
||||
if(!isnewplayer(M))
|
||||
flash_color(M, flash_color="#C80000", flash_time=1)
|
||||
shake_camera(M, 4, 3)
|
||||
|
||||
@@ -20,13 +20,13 @@
|
||||
timerid = QDEL_IN(src, 15)
|
||||
var/obj/structure/destructible/clockwork/taunting_trail/Tt = locate(/obj/structure/destructible/clockwork/taunting_trail) in loc
|
||||
if(Tt && Tt != src)
|
||||
if(!step(src, pick(alldirs)))
|
||||
if(!step(src, pick(GLOB.alldirs)))
|
||||
qdel(Tt)
|
||||
else
|
||||
for(var/obj/structure/destructible/clockwork/taunting_trail/TT in loc)
|
||||
if(TT != src)
|
||||
qdel(TT)
|
||||
setDir(pick(cardinal))
|
||||
setDir(pick(GLOB.cardinal))
|
||||
transform = matrix()*1.25
|
||||
animate(src, alpha = 100, time = 15)
|
||||
|
||||
|
||||
@@ -13,19 +13,21 @@
|
||||
light_color = "#C2852F"
|
||||
var/wall_generation_cooldown
|
||||
var/turf/closed/wall/clockwork/linkedwall //if we've got a linked wall and are producing
|
||||
var/static/linked_caches = 0 //how many caches are linked to walls; affects how fast components are produced
|
||||
|
||||
/obj/structure/destructible/clockwork/cache/New()
|
||||
..()
|
||||
START_PROCESSING(SSobj, src)
|
||||
clockwork_caches++
|
||||
GLOB.clockwork_caches++
|
||||
update_slab_info()
|
||||
set_light(2, 0.7)
|
||||
|
||||
/obj/structure/destructible/clockwork/cache/Destroy()
|
||||
clockwork_caches--
|
||||
GLOB.clockwork_caches--
|
||||
update_slab_info()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
if(linkedwall)
|
||||
linked_caches--
|
||||
linkedwall.linkedcache = null
|
||||
linkedwall = null
|
||||
return ..()
|
||||
@@ -33,18 +35,20 @@
|
||||
/obj/structure/destructible/clockwork/cache/process()
|
||||
if(!anchored)
|
||||
if(linkedwall)
|
||||
linked_caches--
|
||||
linkedwall.linkedcache = null
|
||||
linkedwall = null
|
||||
return
|
||||
for(var/turf/closed/wall/clockwork/C in range(4, src))
|
||||
if(!C.linkedcache && !linkedwall)
|
||||
linked_caches++
|
||||
C.linkedcache = src
|
||||
linkedwall = C
|
||||
wall_generation_cooldown = world.time + (CACHE_PRODUCTION_TIME * get_efficiency_mod(TRUE))
|
||||
wall_generation_cooldown = world.time + get_production_time()
|
||||
visible_message("<span class='warning'>[src] starts to whirr in the presence of [C]...</span>")
|
||||
break
|
||||
if(linkedwall && wall_generation_cooldown <= world.time)
|
||||
wall_generation_cooldown = world.time + (CACHE_PRODUCTION_TIME * get_efficiency_mod(TRUE))
|
||||
wall_generation_cooldown = world.time + get_production_time()
|
||||
var/component_id = generate_cache_component(null, src)
|
||||
playsound(linkedwall, 'sound/magic/clockwork/fellowship_armory.ogg', rand(15, 20), 1, -3, 1, 1)
|
||||
visible_message("<span class='[get_component_span(component_id)]'>Something</span><span class='warning'> cl[pick("ank", "ink", "unk", "ang")]s around inside of [src]...</span>")
|
||||
@@ -57,7 +61,7 @@
|
||||
if(!anchored)
|
||||
to_chat(user, "<span class='warning'>[src] needs to be secured to place [C] into it!</span>")
|
||||
else
|
||||
clockwork_component_cache[C.component_id]++
|
||||
GLOB.clockwork_component_cache[C.component_id]++
|
||||
update_slab_info()
|
||||
to_chat(user, "<span class='notice'>You add [C] to [src].</span>")
|
||||
user.drop_item()
|
||||
@@ -69,7 +73,7 @@
|
||||
to_chat(user, "<span class='warning'>[src] needs to be secured to offload your slab's components into it!</span>")
|
||||
else
|
||||
for(var/i in S.stored_components)
|
||||
clockwork_component_cache[i] += S.stored_components[i]
|
||||
GLOB.clockwork_component_cache[i] += S.stored_components[i]
|
||||
S.stored_components[i] = 0
|
||||
update_slab_info()
|
||||
user.visible_message("<span class='notice'>[user] empties [S] into [src].</span>", "<span class='notice'>You offload your slab's components into [src].</span>")
|
||||
@@ -102,9 +106,12 @@
|
||||
..()
|
||||
if(is_servant_of_ratvar(user) || isobserver(user))
|
||||
if(linkedwall)
|
||||
to_chat(user, "<span class='brass'>It is linked to a Clockwork Wall and will generate a component every <b>[round((CACHE_PRODUCTION_TIME * 0.1) * get_efficiency_mod(TRUE), 0.1)]</b> seconds!</span>")
|
||||
to_chat(user, "<span class='brass'>It is linked to a Clockwork Wall and will generate a component every <b>[round(get_production_time() * 0.1, 0.1)]</b> seconds!</span>")
|
||||
else
|
||||
to_chat(user, "<span class='alloy'>It is unlinked! Construct a Clockwork Wall nearby to generate components!</span>")
|
||||
to_chat(user, "<b>Stored components:</b>")
|
||||
for(var/i in clockwork_component_cache)
|
||||
to_chat(user, "<span class='[get_component_span(i)]_small'><i>[get_component_name(i)][i != REPLICANT_ALLOY ? "s":""]:</i> <b>[clockwork_component_cache[i]]</b></span>")
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
to_chat(user, "<span class='[get_component_span(i)]_small'><i>[get_component_name(i)][i != REPLICANT_ALLOY ? "s":""]:</i> <b>[GLOB.clockwork_component_cache[i]]</b></span>")
|
||||
|
||||
/obj/structure/destructible/clockwork/cache/proc/get_production_time()
|
||||
return (CACHE_PRODUCTION_TIME + (ACTIVE_CACHE_SLOWDOWN * linked_caches)) * get_efficiency_mod(TRUE)
|
||||
|
||||
@@ -22,15 +22,15 @@
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/tinkerers_daemon/New()
|
||||
..()
|
||||
clockwork_daemons++
|
||||
GLOB.clockwork_daemons++
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/tinkerers_daemon/Destroy()
|
||||
clockwork_daemons--
|
||||
GLOB.clockwork_daemons--
|
||||
return ..()
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/tinkerers_daemon/ratvar_act()
|
||||
..()
|
||||
if(nezbere_invoked)
|
||||
if(GLOB.nezbere_invoked)
|
||||
production_time = 0
|
||||
production_cooldown = initial(production_cooldown) * 0.5
|
||||
if(!active)
|
||||
@@ -47,8 +47,8 @@
|
||||
else
|
||||
to_chat(user, "<span class='brass'>It is currently producing random components.</span>")
|
||||
to_chat(user, "<span class='nezbere_small'>It will produce a component every <b>[round((production_cooldown*0.1) * get_efficiency_mod(TRUE), 0.1)]</b> seconds and requires at least the following power for each component type:</span>")
|
||||
for(var/i in clockwork_component_cache)
|
||||
to_chat(user, "<span class='[get_component_span(i)]_small'><i>[get_component_name(i)]:</i> <b>[get_component_cost(i)]W</b> <i>([clockwork_component_cache[i]] exist[clockwork_component_cache[i] == 1 ? "s" : ""])</i></span>")
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
to_chat(user, "<span class='[get_component_span(i)]_small'><i>[get_component_name(i)]:</i> <b>[get_component_cost(i)]W</b> <i>([GLOB.clockwork_component_cache[i]] exist[GLOB.clockwork_component_cache[i] == 1 ? "s" : ""])</i></span>")
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/tinkerers_daemon/forced_disable(bad_effects)
|
||||
if(active)
|
||||
@@ -72,17 +72,17 @@
|
||||
to_chat(user, "<span class='warning'>[src] needs to be secured to the floor before it can be activated!</span>")
|
||||
return FALSE
|
||||
var/servants = 0
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
for(var/mob/living/L in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(L))
|
||||
servants++
|
||||
if(servants * 0.2 < clockwork_daemons)
|
||||
if(servants * 0.2 < GLOB.clockwork_daemons)
|
||||
to_chat(user, "<span class='nezbere'>\"There are too few servants for this daemon to work.\"</span>")
|
||||
return
|
||||
if(!clockwork_caches)
|
||||
if(!GLOB.clockwork_caches)
|
||||
to_chat(user, "<span class='nezbere'>\"You require a cache for this daemon to operate. Get to it.\"</span>")
|
||||
return
|
||||
var/min_power_usable = 0
|
||||
for(var/i in clockwork_component_cache)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
if(!min_power_usable)
|
||||
min_power_usable = get_component_cost(i)
|
||||
else
|
||||
@@ -94,15 +94,15 @@
|
||||
switch(choice)
|
||||
if("Specific Component")
|
||||
var/list/components = list()
|
||||
for(var/i in clockwork_component_cache)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
components["[get_component_name(i)] ([get_component_cost(i)]W)"] = i
|
||||
var/input_component = input(user, "Choose a component type.", name) as null|anything in components
|
||||
component_id_to_produce = components[input_component]
|
||||
servants = 0
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
for(var/mob/living/L in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(L))
|
||||
servants++
|
||||
if(!is_servant_of_ratvar(user) || !user.canUseTopic(src, !issilicon(user), NO_DEXTERY) || active || !clockwork_caches || servants * 0.2 < clockwork_daemons)
|
||||
if(!is_servant_of_ratvar(user) || !user.canUseTopic(src, !issilicon(user), NO_DEXTERY) || active || !GLOB.clockwork_caches || servants * 0.2 < GLOB.clockwork_daemons)
|
||||
return
|
||||
if(!component_id_to_produce)
|
||||
to_chat(user, "<span class='warning'>You decide not to select a component and activate the daemon.</span>")
|
||||
@@ -136,24 +136,24 @@
|
||||
set_light(0)
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/tinkerers_daemon/proc/get_component_cost(id)
|
||||
return max(MIN_CLOCKCULT_POWER*2, (MIN_CLOCKCULT_POWER*2) * (1 + round(clockwork_component_cache[id] * 0.2)))
|
||||
return max(MIN_CLOCKCULT_POWER*2, (MIN_CLOCKCULT_POWER*2) * (1 + round(GLOB.clockwork_component_cache[id] * 0.2)))
|
||||
|
||||
/obj/structure/destructible/clockwork/powered/tinkerers_daemon/process()
|
||||
var/servants = 0
|
||||
for(var/mob/living/L in living_mob_list)
|
||||
for(var/mob/living/L in GLOB.living_mob_list)
|
||||
if(is_servant_of_ratvar(L))
|
||||
servants++
|
||||
. = ..()
|
||||
var/min_power_usable = 0
|
||||
if(!component_id_to_produce)
|
||||
for(var/i in clockwork_component_cache)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
if(!min_power_usable)
|
||||
min_power_usable = get_component_cost(i)
|
||||
else
|
||||
min_power_usable = min(min_power_usable, get_component_cost(i))
|
||||
else
|
||||
min_power_usable = get_component_cost(component_id_to_produce)
|
||||
if(!clockwork_caches || servants * 0.2 < clockwork_daemons || . < min_power_usable) //if we don't have enough to produce the lowest or what we chose to produce, cancel out
|
||||
if(!GLOB.clockwork_caches || servants * 0.2 < GLOB.clockwork_daemons || . < min_power_usable) //if we don't have enough to produce the lowest or what we chose to produce, cancel out
|
||||
forced_disable(FALSE)
|
||||
return
|
||||
if(production_time <= world.time)
|
||||
@@ -163,7 +163,7 @@
|
||||
if(!try_use_power(get_component_cost(component_to_generate)))
|
||||
component_to_generate = null
|
||||
if(!component_id_to_produce)
|
||||
for(var/i in clockwork_component_cache)
|
||||
for(var/i in GLOB.clockwork_component_cache)
|
||||
if(try_use_power(get_component_cost(i))) //if we fail but are producing random, try and get a different component to produce
|
||||
component_to_generate = i
|
||||
break
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
return istype(M) && M.has_antag_datum(/datum/antagonist/cultist, TRUE)
|
||||
|
||||
/proc/is_sacrifice_target(datum/mind/mind)
|
||||
if(ticker.mode.name == "cult")
|
||||
var/datum/game_mode/cult/cult_mode = ticker.mode
|
||||
if(SSticker.mode.name == "cult")
|
||||
var/datum/game_mode/cult/cult_mode = SSticker.mode
|
||||
if(mind == cult_mode.sacrifice_target)
|
||||
return 1
|
||||
return 0
|
||||
@@ -104,7 +104,7 @@
|
||||
var/list/possible_targets = get_unconvertables()
|
||||
if(!possible_targets.len)
|
||||
message_admins("Cult Sacrifice: Could not find unconvertable target, checking for convertable target.")
|
||||
for(var/mob/living/carbon/human/player in player_list)
|
||||
for(var/mob/living/carbon/human/player in GLOB.player_list)
|
||||
if(player.mind && !(player.mind in cultists_to_cult))
|
||||
possible_targets += player.mind
|
||||
if(possible_targets.len > 0)
|
||||
@@ -175,18 +175,18 @@
|
||||
return TRUE
|
||||
|
||||
/datum/game_mode/proc/update_cult_icons_added(datum/mind/cult_mind)
|
||||
var/datum/atom_hud/antag/culthud = huds[ANTAG_HUD_CULT]
|
||||
var/datum/atom_hud/antag/culthud = GLOB.huds[ANTAG_HUD_CULT]
|
||||
culthud.join_hud(cult_mind.current)
|
||||
set_antag_hud(cult_mind.current, "cult")
|
||||
|
||||
/datum/game_mode/proc/update_cult_icons_removed(datum/mind/cult_mind)
|
||||
var/datum/atom_hud/antag/culthud = huds[ANTAG_HUD_CULT]
|
||||
var/datum/atom_hud/antag/culthud = GLOB.huds[ANTAG_HUD_CULT]
|
||||
culthud.leave_hud(cult_mind.current)
|
||||
set_antag_hud(cult_mind.current, null)
|
||||
|
||||
/datum/game_mode/cult/proc/get_unconvertables()
|
||||
var/list/ucs = list()
|
||||
for(var/mob/living/carbon/human/player in player_list)
|
||||
for(var/mob/living/carbon/human/player in GLOB.player_list)
|
||||
if(player.mind && !is_convertable_to_cult(player) && !(player.mind in cultists_to_cult))
|
||||
ucs += player.mind
|
||||
return ucs
|
||||
@@ -198,7 +198,7 @@
|
||||
if(cult_objectives.Find("eldergod"))
|
||||
cult_fail += eldergod //1 by default, 0 if the elder god has been summoned at least once
|
||||
if(cult_objectives.Find("sacrifice"))
|
||||
if(sacrifice_target && !sacrificed.Find(sacrifice_target)) //if the target has been sacrificed, ignore this step. otherwise, add 1 to cult_fail
|
||||
if(sacrifice_target && !GLOB.sacrificed.Find(sacrifice_target)) //if the target has been GLOB.sacrificed, ignore this step. otherwise, add 1 to cult_fail
|
||||
cult_fail++
|
||||
return cult_fail //if any objectives aren't met, failure
|
||||
|
||||
@@ -237,14 +237,14 @@
|
||||
if(!check_survive())
|
||||
explanation = "Make sure at least [acolytes_needed] acolytes escape on the shuttle. ([acolytes_survived] escaped) <span class='greenannounce'>Success!</span>"
|
||||
feedback_add_details("cult_objective","cult_survive|SUCCESS|[acolytes_needed]")
|
||||
ticker.news_report = CULT_ESCAPE
|
||||
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>"
|
||||
feedback_add_details("cult_objective","cult_survive|FAIL|[acolytes_needed]")
|
||||
ticker.news_report = CULT_FAILURE
|
||||
SSticker.news_report = CULT_FAILURE
|
||||
if("sacrifice")
|
||||
if(sacrifice_target)
|
||||
if(sacrifice_target in sacrificed)
|
||||
if(sacrifice_target in GLOB.sacrificed)
|
||||
explanation = "Sacrifice [sacrifice_target.name], the [sacrifice_target.assigned_role]. <span class='greenannounce'>Success!</span>"
|
||||
feedback_add_details("cult_objective","cult_sacrifice|SUCCESS")
|
||||
else if(sacrifice_target && sacrifice_target.current)
|
||||
@@ -257,11 +257,11 @@
|
||||
if(!eldergod)
|
||||
explanation = "Summon Nar-Sie. <span class='greenannounce'>Success!</span>"
|
||||
feedback_add_details("cult_objective","cult_narsie|SUCCESS")
|
||||
ticker.news_report = CULT_SUMMON
|
||||
SSticker.news_report = CULT_SUMMON
|
||||
else
|
||||
explanation = "Summon Nar-Sie. <span class='boldannounce'>Fail.</span>"
|
||||
feedback_add_details("cult_objective","cult_narsie|FAIL")
|
||||
ticker.news_report = CULT_FAILURE
|
||||
SSticker.news_report = CULT_FAILURE
|
||||
|
||||
text += "<br><B>Objective #[obj_count]</B>: [explanation]"
|
||||
to_chat(world, text)
|
||||
@@ -270,7 +270,7 @@
|
||||
|
||||
|
||||
/datum/game_mode/proc/auto_declare_completion_cult()
|
||||
if( cult.len || (ticker && istype(ticker.mode,/datum/game_mode/cult)) )
|
||||
if( cult.len || (SSticker && istype(SSticker.mode,/datum/game_mode/cult)) )
|
||||
var/text = "<br><font size=3><b>The cultists were:</b></font>"
|
||||
for(var/datum/mind/cultist in cult)
|
||||
text += printplayer(cultist)
|
||||
|
||||
@@ -17,22 +17,17 @@
|
||||
return
|
||||
|
||||
cultist_commune(usr, input)
|
||||
return
|
||||
|
||||
/proc/cultist_commune(mob/living/user, message)
|
||||
if(!message)
|
||||
return
|
||||
if(!ishuman(user))
|
||||
user.say("O bidai nabora se[pick("'","`")]sma!")
|
||||
user.say(html_decode(message))
|
||||
else
|
||||
user.whisper("O bidai nabora se[pick("'","`")]sma!")
|
||||
user.whisper(html_decode(message))
|
||||
user.whisper("O bidai nabora se[pick("'","`")]sma!")
|
||||
user.whisper(html_decode(message))
|
||||
var/my_message = "<span class='cultitalic'><b>[(ishuman(user) ? "Acolyte" : "Construct")] [findtextEx(user.name, user.real_name) ? user.name : "[user.real_name] (as [user.name])"]:</b> [message]</span>"
|
||||
for(var/mob/M in mob_list)
|
||||
for(var/mob/M in GLOB.mob_list)
|
||||
if(iscultist(M))
|
||||
to_chat(M, my_message)
|
||||
else if(M in dead_mob_list)
|
||||
else if(M in GLOB.dead_mob_list)
|
||||
var/link = FOLLOW_LINK(M, user)
|
||||
to_chat(M, "[link] [my_message]")
|
||||
|
||||
|
||||
@@ -328,7 +328,7 @@
|
||||
return
|
||||
if(!iscultist(user))
|
||||
user.dropItemToGround(src, TRUE)
|
||||
step(src, pick(alldirs))
|
||||
step(src, pick(GLOB.alldirs))
|
||||
to_chat(user, "<span class='warning'>\The [src] flickers out of your hands, your connection to this dimension is too strong!</span>")
|
||||
return
|
||||
|
||||
@@ -375,7 +375,7 @@
|
||||
if(istype(A, /obj/item))
|
||||
|
||||
var/list/cultists = list()
|
||||
for(var/datum/mind/M in ticker.mode.cult)
|
||||
for(var/datum/mind/M in SSticker.mode.cult)
|
||||
if(M.current && M.current.stat != DEAD)
|
||||
cultists |= M.current
|
||||
var/mob/living/cultist_to_receive = input(user, "Who do you wish to call to [src]?", "Followers of the Geometer") as null|anything in (cultists - user)
|
||||
@@ -403,5 +403,4 @@
|
||||
else
|
||||
..()
|
||||
to_chat(user, "<span class='warning'>\The [src] can only transport items!</span>")
|
||||
return
|
||||
|
||||
|
||||
@@ -122,12 +122,6 @@
|
||||
to_chat(user, "<span class='cultitalic'>You work the forge as dark knowledge guides your hands, creating [N]!</span>")
|
||||
|
||||
|
||||
var/list/blacklisted_pylon_turfs = typecacheof(list(
|
||||
/turf/closed,
|
||||
/turf/open/floor/engine/cult,
|
||||
/turf/open/space,
|
||||
/turf/open/floor/plating/lava,
|
||||
/turf/open/chasm))
|
||||
|
||||
/obj/structure/destructible/cult/pylon
|
||||
name = "pylon"
|
||||
@@ -177,6 +171,12 @@ var/list/blacklisted_pylon_turfs = typecacheof(list(
|
||||
if(istype(T, /turf/open/floor/engine/cult))
|
||||
cultturfs |= T
|
||||
continue
|
||||
var/static/list/blacklisted_pylon_turfs = typecacheof(list(
|
||||
/turf/closed,
|
||||
/turf/open/floor/engine/cult,
|
||||
/turf/open/space,
|
||||
/turf/open/floor/plating/lava,
|
||||
/turf/open/chasm))
|
||||
if(is_type_in_typecache(T, blacklisted_pylon_turfs))
|
||||
continue
|
||||
else
|
||||
|
||||
@@ -15,11 +15,12 @@ This file contains the arcane tome files.
|
||||
|
||||
/obj/item/weapon/tome/New()
|
||||
..()
|
||||
if(!LAZYLEN(rune_types))
|
||||
rune_types = list()
|
||||
if(!LAZYLEN(GLOB.rune_types))
|
||||
GLOB.rune_types = list()
|
||||
var/static/list/non_revealed_runes = (subtypesof(/obj/effect/rune) - /obj/effect/rune/malformed)
|
||||
for(var/i_can_do_loops_now_thanks_remie in non_revealed_runes)
|
||||
var/obj/effect/rune/R = i_can_do_loops_now_thanks_remie
|
||||
rune_types[initial(R.cultist_name)] = R //Uses the cultist name for displaying purposes
|
||||
GLOB.rune_types[initial(R.cultist_name)] = R //Uses the cultist name for displaying purposes
|
||||
|
||||
/obj/item/weapon/tome/examine(mob/user)
|
||||
..()
|
||||
@@ -180,10 +181,10 @@ This file contains the arcane tome files.
|
||||
|
||||
if(!check_rune_turf(Turf, user))
|
||||
return
|
||||
entered_rune_name = input(user, "Choose a rite to scribe.", "Sigils of Power") as null|anything in rune_types
|
||||
entered_rune_name = input(user, "Choose a rite to scribe.", "Sigils of Power") as null|anything in GLOB.rune_types
|
||||
if(!src || QDELETED(src) || !Adjacent(user) || user.incapacitated() || !check_rune_turf(Turf, user))
|
||||
return
|
||||
rune_to_scribe = rune_types[entered_rune_name]
|
||||
rune_to_scribe = GLOB.rune_types[entered_rune_name]
|
||||
if(!rune_to_scribe)
|
||||
return
|
||||
if(initial(rune_to_scribe.req_keyword))
|
||||
@@ -196,12 +197,12 @@ This file contains the arcane tome files.
|
||||
if(!src || QDELETED(src) || !Adjacent(user) || user.incapacitated() || !check_rune_turf(Turf, user))
|
||||
return
|
||||
if(ispath(rune_to_scribe, /obj/effect/rune/narsie))
|
||||
if(ticker.mode.name == "cult")
|
||||
var/datum/game_mode/cult/cult_mode = ticker.mode
|
||||
if(SSticker.mode.name == "cult")
|
||||
var/datum/game_mode/cult/cult_mode = SSticker.mode
|
||||
if(!("eldergod" in cult_mode.cult_objectives))
|
||||
to_chat(user, "<span class='warning'>Nar-Sie does not wish to be summoned!</span>")
|
||||
return
|
||||
if(cult_mode.sacrifice_target && !(cult_mode.sacrifice_target in sacrificed))
|
||||
if(cult_mode.sacrifice_target && !(cult_mode.sacrifice_target in GLOB.sacrificed))
|
||||
to_chat(user, "<span class='warning'>The sacrifice is not complete. The portal would lack the power to open if you tried!</span>")
|
||||
return
|
||||
if(!cult_mode.eldergod)
|
||||
@@ -244,6 +245,7 @@ This file contains the arcane tome files.
|
||||
if(S && !QDELETED(S))
|
||||
qdel(S)
|
||||
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>")
|
||||
feedback_add_details("cult_runes_scribed", R.cultist_name)
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/var/list/sacrificed = list() //a mixed list of minds and mobs
|
||||
var/list/non_revealed_runes = (subtypesof(/obj/effect/rune) - /obj/effect/rune/malformed)
|
||||
var/global/list/rune_types //Every rune that can be drawn by tomes
|
||||
|
||||
GLOBAL_LIST_EMPTY(sacrificed) //a mixed list of minds and mobs
|
||||
GLOBAL_LIST(rune_types) //Every rune that can be drawn by tomes
|
||||
GLOBAL_LIST_EMPTY(teleport_runes)
|
||||
GLOBAL_LIST_EMPTY(wall_runes)
|
||||
/*
|
||||
|
||||
This file contains runes.
|
||||
@@ -58,13 +58,10 @@ To draw a rune, use an arcane tome.
|
||||
if(istype(I, /obj/item/weapon/tome) && iscultist(user))
|
||||
to_chat(user, "<span class='notice'>You carefully erase the [lowertext(cultist_name)] rune.</span>")
|
||||
qdel(src)
|
||||
return
|
||||
else if(istype(I, /obj/item/weapon/nullrod))
|
||||
user.say("BEGONE FOUL MAGIKS!!")
|
||||
to_chat(user, "<span class='danger'>You disrupt the magic of [src] with [I].</span>")
|
||||
qdel(src)
|
||||
return
|
||||
return
|
||||
|
||||
/obj/effect/rune/attack_hand(mob/living/user)
|
||||
if(!iscultist(user))
|
||||
@@ -143,20 +140,20 @@ structure_check() searches for nearby cultist structures required for the invoca
|
||||
do_invoke_glow()
|
||||
|
||||
/obj/effect/rune/proc/do_invoke_glow()
|
||||
set waitfor = FALSE
|
||||
var/oldtransform = transform
|
||||
spawn(0) //animate is a delay, we want to avoid being delayed
|
||||
animate(src, transform = matrix()*2, alpha = 0, time = 5) //fade out
|
||||
animate(transform = oldtransform, alpha = 255, time = 0)
|
||||
animate(src, transform = matrix()*2, alpha = 0, time = 5) //fade out
|
||||
sleep(5)
|
||||
animate(src, transform = oldtransform, alpha = 255, time = 0)
|
||||
|
||||
/obj/effect/rune/proc/fail_invoke()
|
||||
//This proc contains the effects of a rune if it is not invoked correctly, through either invalid wording or not enough cultists. By default, it's just a basic fizzle.
|
||||
visible_message("<span class='warning'>The markings pulse with a \
|
||||
small flash of red light, then fall dark.</span>")
|
||||
spawn(0) //animate is a delay, we want to avoid being delayed
|
||||
var/oldcolor = color
|
||||
color = rgb(255, 0, 0)
|
||||
animate(src, color = oldcolor, time = 5)
|
||||
addtimer(CALLBACK(src, /atom/proc/update_atom_colour), 5)
|
||||
var/oldcolor = color
|
||||
color = rgb(255, 0, 0)
|
||||
animate(src, color = oldcolor, time = 5)
|
||||
addtimer(CALLBACK(src, /atom/proc/update_atom_colour), 5)
|
||||
|
||||
//Malformed Rune: This forms if a rune is not drawn correctly. Invoking it does nothing but hurt the user.
|
||||
/obj/effect/rune/malformed
|
||||
@@ -179,7 +176,7 @@ structure_check() searches for nearby cultist structures required for the invoca
|
||||
|
||||
/mob/proc/null_rod_check() //The null rod, if equipped, will protect the holder from the effects of most runes
|
||||
var/obj/item/weapon/nullrod/N = locate() in src
|
||||
if(N && !ratvar_awakens) //If Nar-Sie or Ratvar are alive, null rods won't protect you
|
||||
if(N && !GLOB.ratvar_awakens) //If Nar-Sie or Ratvar are alive, null rods won't protect you
|
||||
return N
|
||||
return 0
|
||||
|
||||
@@ -247,7 +244,6 @@ structure_check() searches for nearby cultist structures required for the invoca
|
||||
if(!P.info && !istype(P, /obj/item/weapon/paper/talisman))
|
||||
. |= P
|
||||
|
||||
var/list/teleport_runes = list()
|
||||
/obj/effect/rune/teleport
|
||||
cultist_name = "Teleport"
|
||||
cultist_desc = "warps everything above it to another chosen teleport rune."
|
||||
@@ -262,17 +258,17 @@ var/list/teleport_runes = list()
|
||||
var/area/A = get_area(src)
|
||||
var/locname = initial(A.name)
|
||||
listkey = set_keyword ? "[set_keyword] [locname]":"[locname]"
|
||||
teleport_runes += src
|
||||
GLOB.teleport_runes += src
|
||||
|
||||
/obj/effect/rune/teleport/Destroy()
|
||||
teleport_runes -= src
|
||||
GLOB.teleport_runes -= src
|
||||
return ..()
|
||||
|
||||
/obj/effect/rune/teleport/invoke(var/list/invokers)
|
||||
var/mob/living/user = invokers[1] //the first invoker is always the user
|
||||
var/list/potential_runes = list()
|
||||
var/list/teleportnames = list()
|
||||
for(var/R in teleport_runes)
|
||||
for(var/R in GLOB.teleport_runes)
|
||||
var/obj/effect/rune/teleport/T = R
|
||||
if(T != src && (T.z <= ZLEVEL_SPACEMAX))
|
||||
potential_runes[avoid_assoc_duplicate_keys(T.listkey, teleportnames)] = T
|
||||
@@ -392,7 +388,7 @@ var/list/teleport_runes = list()
|
||||
convertee.visible_message("<span class='warning'>[convertee] writhes in pain \
|
||||
[brutedamage || burndamage ? "even as [convertee.p_their()] wounds heal and close" : "as the markings below [convertee.p_them()] glow a bloody red"]!</span>", \
|
||||
"<span class='cultlarge'><i>AAAAAAAAAAAAAA-</i></span>")
|
||||
ticker.mode.add_cultist(convertee.mind, 1)
|
||||
SSticker.mode.add_cultist(convertee.mind, 1)
|
||||
new /obj/item/weapon/tome(get_turf(src))
|
||||
convertee.mind.special_role = "Cultist"
|
||||
to_chat(convertee, "<span class='cultitalic'><b>Your blood pulses. Your head throbs. The world goes red. All at once you are aware of a horrible, horrible, truth. The veil of reality has been ripped away \
|
||||
@@ -410,11 +406,11 @@ var/list/teleport_runes = list()
|
||||
var/sacrifice_fulfilled = FALSE
|
||||
|
||||
if(sacrificial.mind)
|
||||
sacrificed += sacrificial.mind
|
||||
GLOB.sacrificed += sacrificial.mind
|
||||
if(is_sacrifice_target(sacrificial.mind))
|
||||
sacrifice_fulfilled = TRUE
|
||||
else
|
||||
sacrificed += sacrificial
|
||||
GLOB.sacrificed += sacrificial
|
||||
|
||||
new /obj/effect/overlay/temp/cult/sac(get_turf(src))
|
||||
for(var/M in invokers)
|
||||
@@ -459,10 +455,10 @@ var/list/teleport_runes = list()
|
||||
|
||||
/obj/effect/rune/narsie/New()
|
||||
. = ..()
|
||||
poi_list |= src
|
||||
GLOB.poi_list |= src
|
||||
|
||||
/obj/effect/rune/narsie/Destroy()
|
||||
poi_list -= src
|
||||
GLOB.poi_list -= src
|
||||
. = ..()
|
||||
|
||||
/obj/effect/rune/narsie/talismanhide() //can't hide this, and you wouldn't want to
|
||||
@@ -476,8 +472,8 @@ var/list/teleport_runes = list()
|
||||
|
||||
var/datum/game_mode/cult/cult_mode
|
||||
|
||||
if(ticker.mode.name == "cult")
|
||||
cult_mode = ticker.mode
|
||||
if(SSticker.mode.name == "cult")
|
||||
cult_mode = SSticker.mode
|
||||
|
||||
if(!cult_mode && !ignore_gamemode)
|
||||
for(var/M in invokers)
|
||||
@@ -486,7 +482,7 @@ var/list/teleport_runes = list()
|
||||
log_game("Summon Nar-Sie rune failed - gametype is not cult")
|
||||
return
|
||||
|
||||
if(locate(/obj/singularity/narsie) in poi_list)
|
||||
if(locate(/obj/singularity/narsie) in GLOB.poi_list)
|
||||
for(var/M in invokers)
|
||||
to_chat(M, "<span class='warning'>Nar-Sie is already on this plane!</span>")
|
||||
log_game("Summon Nar-Sie rune failed - already summoned")
|
||||
@@ -510,15 +506,13 @@ var/list/teleport_runes = list()
|
||||
log_game("Summon Narsie rune erased by [user.mind.key] (ckey) with a tome")
|
||||
message_admins("[key_name_admin(user)] erased a Narsie rune with a tome")
|
||||
..()
|
||||
return
|
||||
else
|
||||
if(istype(I, /obj/item/weapon/nullrod)) //Begone foul magiks. You cannot hinder me.
|
||||
log_game("Summon Narsie rune erased by [user.mind.key] (ckey) using a null rod")
|
||||
message_admins("[key_name_admin(user)] erased a Narsie rune with a null rod")
|
||||
..()
|
||||
return
|
||||
|
||||
//Rite of Resurrection: Requires the corpse of a cultist and that there have been less revives than the number of people sacrificed
|
||||
//Rite of Resurrection: Requires the corpse of a cultist and that there have been less revives than the number of people GLOB.sacrificed
|
||||
/obj/effect/rune/raise_dead
|
||||
cultist_name = "Raise Dead"
|
||||
cultist_desc = "requires the corpse of a cultist placed upon the rune. Provided there have been sufficient sacrifices, they will be revived."
|
||||
@@ -531,8 +525,8 @@ var/list/teleport_runes = list()
|
||||
..()
|
||||
if(iscultist(user) || user.stat == DEAD)
|
||||
var/revive_number = 0
|
||||
if(sacrificed.len)
|
||||
revive_number = sacrificed.len - revives_used
|
||||
if(GLOB.sacrificed.len)
|
||||
revive_number = GLOB.sacrificed.len - revives_used
|
||||
to_chat(user, "<b>Revives Remaining:</b> [revive_number]")
|
||||
|
||||
/obj/effect/rune/raise_dead/invoke(var/list/invokers)
|
||||
@@ -550,8 +544,8 @@ var/list/teleport_runes = list()
|
||||
log_game("Raise Dead rune failed - no corpses to revive")
|
||||
fail_invoke()
|
||||
return
|
||||
if(!sacrificed.len || sacrificed.len <= revives_used)
|
||||
to_chat(user, "<span class='warning'>You have sacrificed too few people to revive a cultist!</span>")
|
||||
if(!GLOB.sacrificed.len || GLOB.sacrificed.len <= revives_used)
|
||||
to_chat(user, "<span class='warning'>You have GLOB.sacrificed too few people to revive a cultist!</span>")
|
||||
fail_invoke()
|
||||
return
|
||||
if(potential_revive_mobs.len > 1)
|
||||
@@ -594,7 +588,7 @@ var/list/teleport_runes = list()
|
||||
fail_invoke()
|
||||
log_game("Raise Dead rune failed - revival target has no ghost")
|
||||
return 0
|
||||
if(!sacrificed.len || sacrificed.len <= revives_used)
|
||||
if(!GLOB.sacrificed.len || GLOB.sacrificed.len <= revives_used)
|
||||
to_chat(user, "<span class='warning'>You have sacrificed too few people to revive a cultist!</span>")
|
||||
fail_invoke()
|
||||
log_game("Raise Dead rune failed - too few sacrificed")
|
||||
@@ -710,8 +704,6 @@ var/list/teleport_runes = list()
|
||||
sleep(1)
|
||||
rune_in_use = 0
|
||||
|
||||
|
||||
var/list/wall_runes = list()
|
||||
//Rite of the Corporeal Shield: When invoked, becomes solid and cannot be passed. Invoke again to undo.
|
||||
/obj/effect/rune/wall
|
||||
cultist_name = "Form Barrier"
|
||||
@@ -725,7 +717,7 @@ var/list/wall_runes = list()
|
||||
|
||||
/obj/effect/rune/wall/New()
|
||||
..()
|
||||
wall_runes += src
|
||||
GLOB.wall_runes += src
|
||||
|
||||
/obj/effect/rune/wall/examine(mob/user)
|
||||
..()
|
||||
@@ -734,7 +726,7 @@ var/list/wall_runes = list()
|
||||
|
||||
/obj/effect/rune/wall/Destroy()
|
||||
density = 0
|
||||
wall_runes -= src
|
||||
GLOB.wall_runes -= src
|
||||
air_update_turf(1)
|
||||
return ..()
|
||||
|
||||
@@ -757,7 +749,7 @@ var/list/wall_runes = list()
|
||||
C.apply_damage(2, BRUTE, pick("l_arm", "r_arm"))
|
||||
|
||||
/obj/effect/rune/wall/proc/spread_density()
|
||||
for(var/R in wall_runes)
|
||||
for(var/R in GLOB.wall_runes)
|
||||
var/obj/effect/rune/wall/W = R
|
||||
if(W.z == z && get_dist(src, W) <= 2 && !W.density && !W.recharging)
|
||||
W.density = TRUE
|
||||
@@ -806,7 +798,7 @@ var/list/wall_runes = list()
|
||||
/obj/effect/rune/summon/invoke(var/list/invokers)
|
||||
var/mob/living/user = invokers[1]
|
||||
var/list/cultists = list()
|
||||
for(var/datum/mind/M in ticker.mode.cult)
|
||||
for(var/datum/mind/M in SSticker.mode.cult)
|
||||
if(!(M.current in invokers) && M.current && M.current.stat != DEAD)
|
||||
cultists |= M.current
|
||||
var/mob/living/cultist_to_summon = input(user, "Who do you wish to call to [src]?", "Followers of the Geometer") as null|anything in cultists
|
||||
@@ -992,7 +984,7 @@ var/list/wall_runes = list()
|
||||
var/obj/structure/emergency_shield/invoker/N = new(T)
|
||||
|
||||
new_human.key = ghost_to_spawn.key
|
||||
ticker.mode.add_cultist(new_human.mind, 0)
|
||||
SSticker.mode.add_cultist(new_human.mind, 0)
|
||||
to_chat(new_human, "<span class='cultitalic'><b>You are a servant of the Geometer. You have been made semi-corporeal by the cult of Nar-Sie, and you are to serve them at all costs.</b></span>")
|
||||
|
||||
while(user in T)
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
/obj/item/weapon/paper/talisman/teleport/invoke(mob/living/user, successfuluse = 1)
|
||||
var/list/potential_runes = list()
|
||||
var/list/teleportnames = list()
|
||||
for(var/R in teleport_runes)
|
||||
for(var/R in GLOB.teleport_runes)
|
||||
var/obj/effect/rune/teleport/T = R
|
||||
potential_runes[avoid_assoc_duplicate_keys(T.listkey, teleportnames)] = T
|
||||
|
||||
@@ -421,7 +421,6 @@
|
||||
if(uses <= 0)
|
||||
user.drop_item()
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/item/weapon/restraints/handcuffs/energy/cult //For the talisman of shackling
|
||||
name = "cult shackles"
|
||||
|
||||
@@ -1,22 +1,3 @@
|
||||
var/global/list/whiteness = list (
|
||||
/obj/item/clothing/under/color/white = 2,
|
||||
/obj/item/clothing/under/rank/bartender = 1,
|
||||
/obj/item/clothing/under/rank/chef = 1,
|
||||
/obj/item/clothing/under/rank/chief_engineer = 1,
|
||||
/obj/item/clothing/under/rank/scientist = 1,
|
||||
/obj/item/clothing/under/rank/chemist = 1,
|
||||
/obj/item/clothing/under/rank/chief_medical_officer = 1,
|
||||
/obj/item/clothing/under/rank/geneticist = 1,
|
||||
/obj/item/clothing/under/rank/virologist = 1,
|
||||
/obj/item/clothing/under/rank/nursesuit = 1,
|
||||
/obj/item/clothing/under/rank/medical = 1,
|
||||
/obj/item/clothing/under/rank/det = 1,
|
||||
/obj/item/clothing/under/suit_jacket/white = 0.5,
|
||||
/obj/item/clothing/under/burial = 1
|
||||
)
|
||||
|
||||
|
||||
|
||||
/mob/living/proc/check_devil_bane_multiplier(obj/item/weapon, mob/living/attacker)
|
||||
switch(mind.devilinfo.bane)
|
||||
if(BANE_WHITECLOTHES)
|
||||
@@ -24,6 +5,22 @@ var/global/list/whiteness = list (
|
||||
var/mob/living/carbon/human/H = attacker
|
||||
if(H.w_uniform && istype(H.w_uniform, /obj/item/clothing/under))
|
||||
var/obj/item/clothing/under/U = H.w_uniform
|
||||
var/static/list/whiteness = list (
|
||||
/obj/item/clothing/under/color/white = 2,
|
||||
/obj/item/clothing/under/rank/bartender = 1,
|
||||
/obj/item/clothing/under/rank/chef = 1,
|
||||
/obj/item/clothing/under/rank/chief_engineer = 1,
|
||||
/obj/item/clothing/under/rank/scientist = 1,
|
||||
/obj/item/clothing/under/rank/chemist = 1,
|
||||
/obj/item/clothing/under/rank/chief_medical_officer = 1,
|
||||
/obj/item/clothing/under/rank/geneticist = 1,
|
||||
/obj/item/clothing/under/rank/virologist = 1,
|
||||
/obj/item/clothing/under/rank/nursesuit = 1,
|
||||
/obj/item/clothing/under/rank/medical = 1,
|
||||
/obj/item/clothing/under/rank/det = 1,
|
||||
/obj/item/clothing/under/suit_jacket/white = 0.5,
|
||||
/obj/item/clothing/under/burial = 1
|
||||
)
|
||||
if(whiteness[U.type])
|
||||
src.visible_message("<span class='warning'>[src] seems to have been harmed by the purity of [attacker]'s clothes.</span>", "<span class='notice'>Unsullied white clothing is disrupting your form.</span>")
|
||||
return whiteness[U.type] + 1
|
||||
|
||||
@@ -13,8 +13,8 @@
|
||||
|
||||
#define DEVILRESURRECTTIME 600
|
||||
|
||||
var/global/list/allDevils = list()
|
||||
var/global/list/lawlorify = list (
|
||||
GLOBAL_LIST_EMPTY(allDevils)
|
||||
GLOBAL_LIST_INIT(lawlorify, list (
|
||||
LORE = list(
|
||||
OBLIGATION_FOOD = "This devil seems to always offer its victims food before slaughtering them.",
|
||||
OBLIGATION_FIDDLE = "This devil will never turn down a musical challenge.",
|
||||
@@ -77,8 +77,7 @@ var/global/list/lawlorify = list (
|
||||
BANISH_DESTRUCTION = "If your corpse is destroyed, you will be unable to resurrect.",
|
||||
BANISH_FUNERAL_GARB = "If your corpse is clad in funeral garments, you will be unable to resurrect."
|
||||
)
|
||||
)
|
||||
|
||||
))
|
||||
/datum/devilinfo
|
||||
var/datum/mind/owner = null
|
||||
var/obligation
|
||||
@@ -112,11 +111,11 @@ var/global/list/lawlorify = list (
|
||||
return devil
|
||||
|
||||
/proc/devilInfo(name, saveDetails = 0)
|
||||
if(allDevils[lowertext(name)])
|
||||
return allDevils[lowertext(name)]
|
||||
if(GLOB.allDevils[lowertext(name)])
|
||||
return GLOB.allDevils[lowertext(name)]
|
||||
else
|
||||
var/datum/devilinfo/devil = randomDevilInfo(name)
|
||||
allDevils[lowertext(name)] = devil
|
||||
GLOB.allDevils[lowertext(name)] = devil
|
||||
devil.exists = saveDetails
|
||||
return devil
|
||||
|
||||
@@ -287,9 +286,9 @@ var/global/list/lawlorify = list (
|
||||
if(A)
|
||||
notify_ghosts("An arch devil has ascended in \the [A.name]. Reach out to the devil to be given a new shell for your soul.", source = owner.current, action=NOTIFY_ATTACK)
|
||||
sleep(50)
|
||||
if(!ticker.mode.devil_ascended)
|
||||
if(!SSticker.mode.devil_ascended)
|
||||
SSshuttle.emergency.request(null, 0.3)
|
||||
ticker.mode.devil_ascended++
|
||||
SSticker.mode.devil_ascended++
|
||||
form = ARCH_DEVIL
|
||||
|
||||
/datum/devilinfo/proc/remove_spells()
|
||||
@@ -415,8 +414,8 @@ var/global/list/lawlorify = list (
|
||||
check_regression()
|
||||
|
||||
/datum/devilinfo/proc/create_new_body()
|
||||
if(blobstart.len > 0)
|
||||
var/turf/targetturf = get_turf(pick(blobstart))
|
||||
if(GLOB.blobstart.len > 0)
|
||||
var/turf/targetturf = get_turf(pick(GLOB.blobstart))
|
||||
var/mob/currentMob = owner.current
|
||||
if(!currentMob)
|
||||
currentMob = owner.get_ghost()
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
devil_mind.devilinfo = devilInfo(trueName, 1)
|
||||
devil_mind.devilinfo.ascendable = ascendable
|
||||
devil_mind.store_memory("Your devilic true name is [devil_mind.devilinfo.truename]<br>[lawlorify[LAW][devil_mind.devilinfo.ban]]<br>You may not use violence to coerce someone into selling their soul.<br>You may not directly and knowingly physically harm a devil, other than yourself.<br>[lawlorify[LAW][devil_mind.devilinfo.bane]]<br>[lawlorify[LAW][devil_mind.devilinfo.obligation]]<br>[lawlorify[LAW][devil_mind.devilinfo.banish]]<br>")
|
||||
devil_mind.store_memory("Your devilic true name is [devil_mind.devilinfo.truename]<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.ban]]<br>You may not use violence to coerce someone into selling their soul.<br>You may not directly and knowingly physically harm a devil, other than yourself.<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.bane]]<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.obligation]]<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.banish]]<br>")
|
||||
devil_mind.devilinfo.owner = devil_mind
|
||||
devil_mind.devilinfo.give_base_spells(1)
|
||||
spawn(10)
|
||||
@@ -67,10 +67,10 @@
|
||||
to_chat(current, "<span class='warning'><b>However, your infernal form is not without weaknesses.</b></span>")
|
||||
to_chat(current, "You may not use violence to coerce someone into selling their soul.")
|
||||
to_chat(current, "You may not directly and knowingly physically harm a devil, other than yourself.")
|
||||
to_chat(current, lawlorify[LAW][src.devilinfo.bane])
|
||||
to_chat(current, lawlorify[LAW][src.devilinfo.ban])
|
||||
to_chat(current, lawlorify[LAW][src.devilinfo.obligation])
|
||||
to_chat(current, lawlorify[LAW][src.devilinfo.banish])
|
||||
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.bane])
|
||||
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.ban])
|
||||
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.obligation])
|
||||
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.banish])
|
||||
to_chat(current, "<br/><br/><span class='warning'>Remember, the crew can research your weaknesses if they find out your devil name.</span><br>")
|
||||
|
||||
/datum/game_mode/proc/printdevilinfo(datum/mind/ply)
|
||||
@@ -78,38 +78,38 @@
|
||||
return "Target is not a devil."
|
||||
var/text = "</br>The devil's true name is: [ply.devilinfo.truename]</br>"
|
||||
text += "The devil's bans were:</br>"
|
||||
text += " [lawlorify[LORE][ply.devilinfo.ban]]</br>"
|
||||
text += " [lawlorify[LORE][ply.devilinfo.bane]]</br>"
|
||||
text += " [lawlorify[LORE][ply.devilinfo.obligation]]</br>"
|
||||
text += " [lawlorify[LORE][ply.devilinfo.banish]]</br></br>"
|
||||
text += " [GLOB.lawlorify[LORE][ply.devilinfo.ban]]</br>"
|
||||
text += " [GLOB.lawlorify[LORE][ply.devilinfo.bane]]</br>"
|
||||
text += " [GLOB.lawlorify[LORE][ply.devilinfo.obligation]]</br>"
|
||||
text += " [GLOB.lawlorify[LORE][ply.devilinfo.banish]]</br></br>"
|
||||
return text
|
||||
|
||||
/datum/game_mode/proc/update_devil_icons_added(datum/mind/devil_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_DEVIL]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_DEVIL]
|
||||
hud.join_hud(devil_mind.current)
|
||||
set_antag_hud(devil_mind.current, "devil")
|
||||
|
||||
/datum/game_mode/proc/update_devil_icons_removed(datum/mind/devil_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_DEVIL]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_DEVIL]
|
||||
hud.leave_hud(devil_mind.current)
|
||||
set_antag_hud(devil_mind.current, null)
|
||||
|
||||
/datum/game_mode/proc/update_sintouched_icons_added(datum/mind/sintouched_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_SINTOUCHED]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_SINTOUCHED]
|
||||
hud.join_hud(sintouched_mind.current)
|
||||
set_antag_hud(sintouched_mind.current, "sintouched")
|
||||
|
||||
/datum/game_mode/proc/update_sintouched_icons_removed(datum/mind/sintouched_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_SINTOUCHED]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_SINTOUCHED]
|
||||
hud.leave_hud(sintouched_mind.current)
|
||||
set_antag_hud(sintouched_mind.current, null)
|
||||
|
||||
/datum/game_mode/proc/update_soulless_icons_added(datum/mind/soulless_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_SOULLESS]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_SOULLESS]
|
||||
hud.join_hud(soulless_mind.current)
|
||||
set_antag_hud(soulless_mind.current, "soulless")
|
||||
|
||||
/datum/game_mode/proc/update_soulless_icons_removed(datum/mind/soulless_mind)
|
||||
var/datum/atom_hud/antag/hud = huds[ANTAG_HUD_SOULLESS]
|
||||
var/datum/atom_hud/antag/hud = GLOB.huds[ANTAG_HUD_SOULLESS]
|
||||
hud.leave_hud(soulless_mind.current)
|
||||
set_antag_hud(soulless_mind.current, null)
|
||||
|
||||
@@ -30,9 +30,9 @@
|
||||
melee_damage_lower = 10
|
||||
melee_damage_upper = 15
|
||||
see_in_dark = 8
|
||||
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
var/boost = 0
|
||||
bloodcrawl = BLOODCRAWL_EAT
|
||||
see_invisible = SEE_INVISIBLE_MINIMUM
|
||||
var/list/consumed_mobs = list()
|
||||
var/playstyle_string = "<B><font size=3 color='red'>You are an imp,</font> a mischevious creature from hell. You are the lowest rank on the hellish totem pole \
|
||||
Though you are not obligated to help, perhaps by aiding a higher ranking devil, you might just get a promotion. However, you are incapable \
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
explanation_text = "Ensure at least [target_amount] mortals are sintouched."
|
||||
|
||||
/datum/objective/devil/sintouch/check_completion()
|
||||
return target_amount>=ticker.mode.sintouched.len
|
||||
return target_amount>=SSticker.mode.sintouched.len
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -14,11 +14,9 @@
|
||||
ventcrawler = VENTCRAWLER_NONE
|
||||
density = 1
|
||||
pass_flags = 0
|
||||
var/ascended = 0
|
||||
var/ascended = FALSE
|
||||
sight = (SEE_TURFS | SEE_OBJS)
|
||||
status_flags = CANPUSH
|
||||
languages_spoken = ALL //The devil speaks all languages meme
|
||||
languages_understood = ALL //The devil speaks all languages meme
|
||||
mob_size = MOB_SIZE_LARGE
|
||||
var/mob/living/oldform
|
||||
var/list/devil_overlays[DEVIL_TOTAL_LAYERS]
|
||||
@@ -31,6 +29,8 @@
|
||||
create_bodyparts() //initialize bodyparts
|
||||
|
||||
create_internal_organs()
|
||||
|
||||
grant_all_languages(omnitongue=TRUE)
|
||||
..()
|
||||
|
||||
/mob/living/carbon/true_devil/create_internal_organs()
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
/mob/living/carbon/true_devil/proc/convert_to_archdevil()
|
||||
maxHealth = 5000 // not an IMPOSSIBLE amount, but still near impossible.
|
||||
ascended = 1
|
||||
ascended = TRUE
|
||||
health = maxHealth
|
||||
icon_state = "arch_devil"
|
||||
|
||||
@@ -153,7 +153,6 @@
|
||||
S.mind.objectives += newobjective
|
||||
to_chat(S, S.playstyle_string)
|
||||
to_chat(S, "<B>Objective #[1]</B>: [newobjective.explanation_text]")
|
||||
return
|
||||
else
|
||||
return ..()
|
||||
|
||||
@@ -221,4 +220,4 @@
|
||||
return
|
||||
|
||||
/mob/living/carbon/true_devil/update_damage_overlays() //devils don't have damage overlays.
|
||||
return
|
||||
return
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/proc/power_failure()
|
||||
priority_announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Critical Power Failure", 'sound/AI/poweroff.ogg')
|
||||
for(var/obj/machinery/power/smes/S in machines)
|
||||
for(var/obj/machinery/power/smes/S in GLOB.machines)
|
||||
if(istype(get_area(S), /area/ai_monitored/turret_protected) || S.z != ZLEVEL_STATION)
|
||||
continue
|
||||
S.charge = 0
|
||||
@@ -31,7 +31,7 @@
|
||||
A.power_environ = 0
|
||||
A.power_change()
|
||||
|
||||
for(var/obj/machinery/power/apc/C in apcs_list)
|
||||
for(var/obj/machinery/power/apc/C in GLOB.apcs_list)
|
||||
if(C.cell && C.z == ZLEVEL_STATION)
|
||||
var/area/A = get_area(C)
|
||||
|
||||
@@ -47,11 +47,11 @@
|
||||
/proc/power_restore()
|
||||
|
||||
priority_announce("Power has been restored to [station_name()]. We apologize for the inconvenience.", "Power Systems Nominal", 'sound/AI/poweron.ogg')
|
||||
for(var/obj/machinery/power/apc/C in machines)
|
||||
for(var/obj/machinery/power/apc/C in GLOB.machines)
|
||||
if(C.cell && C.z == ZLEVEL_STATION)
|
||||
C.cell.charge = C.cell.maxcharge
|
||||
C.failure_timer = 0
|
||||
for(var/obj/machinery/power/smes/S in machines)
|
||||
for(var/obj/machinery/power/smes/S in GLOB.machines)
|
||||
if(S.z != ZLEVEL_STATION)
|
||||
continue
|
||||
S.charge = S.capacity
|
||||
@@ -69,7 +69,7 @@
|
||||
/proc/power_restore_quick()
|
||||
|
||||
priority_announce("All SMESs on [station_name()] have been recharged. We apologize for the inconvenience.", "Power Systems Nominal", 'sound/AI/poweron.ogg')
|
||||
for(var/obj/machinery/power/smes/S in machines)
|
||||
for(var/obj/machinery/power/smes/S in GLOB.machines)
|
||||
if(S.z != ZLEVEL_STATION)
|
||||
continue
|
||||
S.charge = S.capacity
|
||||
|
||||
@@ -53,14 +53,14 @@
|
||||
///Checks to see if the game can be setup and ran with the current number of players or whatnot.
|
||||
/datum/game_mode/proc/can_start()
|
||||
var/playerC = 0
|
||||
for(var/mob/dead/new_player/player in player_list)
|
||||
for(var/mob/dead/new_player/player in GLOB.player_list)
|
||||
if((player.client)&&(player.ready))
|
||||
playerC++
|
||||
if(!Debug2)
|
||||
if(!GLOB.Debug2)
|
||||
if(playerC < required_players || (maximum_players >= 0 && playerC > maximum_players))
|
||||
return 0
|
||||
antag_candidates = get_players_for_role(antag_flag)
|
||||
if(!Debug2)
|
||||
if(!GLOB.Debug2)
|
||||
if(antag_candidates.len < required_enemies)
|
||||
return 0
|
||||
return 1
|
||||
@@ -82,17 +82,17 @@
|
||||
display_roundstart_logout_report()
|
||||
|
||||
feedback_set_details("round_start","[time2text(world.realtime)]")
|
||||
if(ticker && ticker.mode)
|
||||
feedback_set_details("game_mode","[ticker.mode]")
|
||||
if(revdata.commit)
|
||||
feedback_set_details("revision","[revdata.commit]")
|
||||
if(SSticker && SSticker.mode)
|
||||
feedback_set_details("game_mode","[SSticker.mode]")
|
||||
if(GLOB.revdata.commit)
|
||||
feedback_set_details("revision","[GLOB.revdata.commit]")
|
||||
feedback_set_details("server_ip","[world.internet_address]:[world.port]")
|
||||
if(report)
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept(0)
|
||||
generate_station_goals()
|
||||
start_state = new /datum/station_state()
|
||||
start_state.count(1)
|
||||
GLOB.start_state = new /datum/station_state()
|
||||
GLOB.start_state.count(1)
|
||||
return 1
|
||||
|
||||
|
||||
@@ -107,10 +107,10 @@
|
||||
/datum/game_mode/proc/convert_roundtype()
|
||||
var/list/living_crew = list()
|
||||
|
||||
for(var/mob/Player in mob_list)
|
||||
for(var/mob/Player in GLOB.mob_list)
|
||||
if(Player.mind && Player.stat != DEAD && !isnewplayer(Player) &&!isbrain(Player))
|
||||
living_crew += Player
|
||||
if(living_crew.len / joined_player_list.len <= config.midround_antag_life_check) //If a lot of the player base died, we start fresh
|
||||
if(living_crew.len / GLOB.joined_player_list.len <= config.midround_antag_life_check) //If a lot of the player base died, we start fresh
|
||||
message_admins("Convert_roundtype failed due to too many dead people. Limit is [config.midround_antag_life_check * 100]% living crew")
|
||||
return null
|
||||
|
||||
@@ -159,7 +159,7 @@
|
||||
message_admins("The roundtype will be converted. If you have other plans for the station or feel the station is too messed up to inhabit <A HREF='?_src_=holder;toggle_midround_antag=\ref[usr]'>stop the creation of antags</A> or <A HREF='?_src_=holder;end_round=\ref[usr]'>end the round now</A>.")
|
||||
|
||||
spawn(rand(600,1800)) //somewhere between 1 and 3 minutes from now
|
||||
if(!config.midround_antag[ticker.mode.config_tag])
|
||||
if(!config.midround_antag[SSticker.mode.config_tag])
|
||||
round_converted = 0
|
||||
return 1
|
||||
for(var/mob/living/carbon/human/H in antag_candidates)
|
||||
@@ -169,12 +169,12 @@
|
||||
return 1
|
||||
|
||||
|
||||
///Called by the gameticker
|
||||
///Called by the gameSSticker
|
||||
/datum/game_mode/process()
|
||||
return 0
|
||||
|
||||
|
||||
/datum/game_mode/proc/check_finished() //to be called by ticker
|
||||
/datum/game_mode/proc/check_finished() //to be called by SSticker
|
||||
if(replacementmode && round_converted == 2)
|
||||
return replacementmode.check_finished()
|
||||
if(SSshuttle.emergency && (SSshuttle.emergency.mode == SHUTTLE_ENDGAME))
|
||||
@@ -183,7 +183,7 @@
|
||||
return TRUE
|
||||
if(!round_converted && (!config.continuous[config_tag] || (config.continuous[config_tag] && config.midround_antag[config_tag]))) //Non-continuous or continous with replacement antags
|
||||
if(!continuous_sanity_checked) //make sure we have antags to be checking in the first place
|
||||
for(var/mob/Player in mob_list)
|
||||
for(var/mob/Player in GLOB.mob_list)
|
||||
if(Player.mind)
|
||||
if(Player.mind.special_role)
|
||||
continuous_sanity_checked = 1
|
||||
@@ -199,7 +199,7 @@
|
||||
if(living_antag_player && living_antag_player.mind && isliving(living_antag_player) && living_antag_player.stat != DEAD && !isnewplayer(living_antag_player) &&!isbrain(living_antag_player))
|
||||
return 0 //A resource saver: once we find someone who has to die for all antags to be dead, we can just keep checking them, cycling over everyone only when we lose our mark.
|
||||
|
||||
for(var/mob/Player in living_mob_list)
|
||||
for(var/mob/Player in GLOB.living_mob_list)
|
||||
if(Player.mind && Player.stat != DEAD && !isnewplayer(Player) &&!isbrain(Player))
|
||||
if(Player.mind.special_role) //Someone's still antaging!
|
||||
living_antag_player = Player
|
||||
@@ -228,7 +228,7 @@
|
||||
var/escaped_humans = 0
|
||||
var/escaped_total = 0
|
||||
|
||||
for(var/mob/M in player_list)
|
||||
for(var/mob/M in GLOB.player_list)
|
||||
if(M.client)
|
||||
clients++
|
||||
if(ishuman(M))
|
||||
@@ -291,7 +291,7 @@
|
||||
|
||||
print_command_report(intercepttext, "Central Command Status Summary", announce=FALSE)
|
||||
priority_announce("A summary has been copied and printed to all communications consoles.", "Enemy communication intercepted. Security level elevated.", 'sound/AI/intercept.ogg')
|
||||
if(security_level < SEC_LEVEL_BLUE)
|
||||
if(GLOB.security_level < SEC_LEVEL_BLUE)
|
||||
set_security_level(SEC_LEVEL_BLUE)
|
||||
|
||||
|
||||
@@ -302,7 +302,7 @@
|
||||
var/datum/mind/applicant = null
|
||||
|
||||
// Ultimate randomizing code right here
|
||||
for(var/mob/dead/new_player/player in player_list)
|
||||
for(var/mob/dead/new_player/player in GLOB.player_list)
|
||||
if(player.client && player.ready)
|
||||
players += player
|
||||
|
||||
@@ -385,7 +385,7 @@
|
||||
|
||||
/datum/game_mode/proc/num_players()
|
||||
. = 0
|
||||
for(var/mob/dead/new_player/P in player_list)
|
||||
for(var/mob/dead/new_player/P in GLOB.player_list)
|
||||
if(P.client && P.ready)
|
||||
. ++
|
||||
|
||||
@@ -394,8 +394,8 @@
|
||||
///////////////////////////////////
|
||||
/datum/game_mode/proc/get_living_heads()
|
||||
. = list()
|
||||
for(var/mob/living/carbon/human/player in mob_list)
|
||||
if(player.stat != DEAD && player.mind && (player.mind.assigned_role in command_positions))
|
||||
for(var/mob/living/carbon/human/player in GLOB.mob_list)
|
||||
if(player.stat != DEAD && player.mind && (player.mind.assigned_role in GLOB.command_positions))
|
||||
. |= player.mind
|
||||
|
||||
|
||||
@@ -404,8 +404,8 @@
|
||||
////////////////////////////
|
||||
/datum/game_mode/proc/get_all_heads()
|
||||
. = list()
|
||||
for(var/mob/player in mob_list)
|
||||
if(player.mind && (player.mind.assigned_role in command_positions))
|
||||
for(var/mob/player in GLOB.mob_list)
|
||||
if(player.mind && (player.mind.assigned_role in GLOB.command_positions))
|
||||
. |= player.mind
|
||||
|
||||
//////////////////////////////////////////////
|
||||
@@ -413,8 +413,8 @@
|
||||
//////////////////////////////////////////////
|
||||
/datum/game_mode/proc/get_living_sec()
|
||||
. = list()
|
||||
for(var/mob/living/carbon/human/player in mob_list)
|
||||
if(player.stat != DEAD && player.mind && (player.mind.assigned_role in security_positions))
|
||||
for(var/mob/living/carbon/human/player in GLOB.mob_list)
|
||||
if(player.stat != DEAD && player.mind && (player.mind.assigned_role in GLOB.security_positions))
|
||||
. |= player.mind
|
||||
|
||||
////////////////////////////////////////
|
||||
@@ -422,8 +422,8 @@
|
||||
////////////////////////////////////////
|
||||
/datum/game_mode/proc/get_all_sec()
|
||||
. = list()
|
||||
for(var/mob/living/carbon/human/player in mob_list)
|
||||
if(player.mind && (player.mind.assigned_role in security_positions))
|
||||
for(var/mob/living/carbon/human/player in GLOB.mob_list)
|
||||
if(player.mind && (player.mind.assigned_role in GLOB.security_positions))
|
||||
. |= player.mind
|
||||
|
||||
//////////////////////////
|
||||
@@ -431,11 +431,11 @@
|
||||
//////////////////////////
|
||||
/proc/display_roundstart_logout_report()
|
||||
var/msg = "<span class='boldnotice'>Roundstart logout report\n\n</span>"
|
||||
for(var/mob/living/L in mob_list)
|
||||
for(var/mob/living/L in GLOB.mob_list)
|
||||
|
||||
if(L.ckey)
|
||||
var/found = 0
|
||||
for(var/client/C in clients)
|
||||
for(var/client/C in GLOB.clients)
|
||||
if(C.ckey == L.ckey)
|
||||
found = 1
|
||||
break
|
||||
@@ -459,7 +459,7 @@
|
||||
continue //Dead
|
||||
|
||||
continue //Happy connected client
|
||||
for(var/mob/dead/observer/D in mob_list)
|
||||
for(var/mob/dead/observer/D in GLOB.mob_list)
|
||||
if(D.mind && D.mind.current == L)
|
||||
if(L.stat == DEAD)
|
||||
if(L.suiciding) //Suicider
|
||||
@@ -477,7 +477,7 @@
|
||||
|
||||
|
||||
|
||||
for(var/mob/M in mob_list)
|
||||
for(var/mob/M in GLOB.mob_list)
|
||||
if(M.client && M.client.holder)
|
||||
to_chat(M, msg)
|
||||
|
||||
@@ -537,9 +537,9 @@
|
||||
M.key = theghost.key
|
||||
|
||||
/datum/game_mode/proc/remove_antag_for_borging(datum/mind/newborgie)
|
||||
ticker.mode.remove_cultist(newborgie, 0, 0)
|
||||
ticker.mode.remove_revolutionary(newborgie, 0)
|
||||
ticker.mode.remove_gangster(newborgie, 0, remove_bosses=1)
|
||||
SSticker.mode.remove_cultist(newborgie, 0, 0)
|
||||
SSticker.mode.remove_revolutionary(newborgie, 0)
|
||||
SSticker.mode.remove_gangster(newborgie, 0, remove_bosses=1)
|
||||
|
||||
/datum/game_mode/proc/generate_station_goals()
|
||||
var/list/possible = list()
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
/obj/machinery/dominator/New()
|
||||
..()
|
||||
set_light(2)
|
||||
poi_list |= src
|
||||
GLOB.poi_list |= src
|
||||
spark_system = new
|
||||
spark_system.set_up(5, 1, src)
|
||||
countdown = new(src)
|
||||
@@ -54,12 +54,12 @@
|
||||
warned = 1
|
||||
var/area/domloc = get_area(loc)
|
||||
gang.message_gangtools("Less than 3 minutes remains in hostile takeover. Defend your dominator at [domloc.map_name]!")
|
||||
for(var/datum/gang/G in ticker.mode.gangs)
|
||||
for(var/datum/gang/G in SSticker.mode.gangs)
|
||||
if(G != gang)
|
||||
G.message_gangtools("WARNING: [gang.name] Gang takeover imminent. Their dominator at [domloc.map_name] must be destroyed!",1,1)
|
||||
|
||||
if(!.)
|
||||
STOP_PROCESSING(SSmachine, src)
|
||||
STOP_PROCESSING(SSmachines, src)
|
||||
|
||||
/obj/machinery/dominator/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0)
|
||||
switch(damage_type)
|
||||
@@ -102,7 +102,7 @@
|
||||
gang.is_dominating = FALSE
|
||||
|
||||
var/takeover_in_progress = 0
|
||||
for(var/datum/gang/G in ticker.mode.gangs)
|
||||
for(var/datum/gang/G in SSticker.mode.gangs)
|
||||
if(G.is_dominating)
|
||||
takeover_in_progress = 1
|
||||
break
|
||||
@@ -122,17 +122,17 @@
|
||||
cut_overlays()
|
||||
operating = 0
|
||||
stat |= BROKEN
|
||||
STOP_PROCESSING(SSmachine, src)
|
||||
STOP_PROCESSING(SSmachines, src)
|
||||
|
||||
/obj/machinery/dominator/Destroy()
|
||||
if(!(stat & BROKEN))
|
||||
set_broken()
|
||||
poi_list.Remove(src)
|
||||
GLOB.poi_list.Remove(src)
|
||||
gang = null
|
||||
qdel(spark_system)
|
||||
qdel(countdown)
|
||||
countdown = null
|
||||
STOP_PROCESSING(SSmachine, src)
|
||||
STOP_PROCESSING(SSmachines, src)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/dominator/emp_act(severity)
|
||||
@@ -146,7 +146,7 @@
|
||||
|
||||
var/datum/gang/tempgang
|
||||
|
||||
if(user.mind in ticker.mode.get_all_gangsters())
|
||||
if(user.mind in SSticker.mode.get_all_gangsters())
|
||||
tempgang = user.mind.gang_datum
|
||||
else
|
||||
examine(user)
|
||||
@@ -161,7 +161,7 @@
|
||||
return
|
||||
|
||||
var/time = round(determine_domination_time(tempgang)/60,0.1)
|
||||
if(alert(user,"With [round((tempgang.territory.len/start_state.num_territories)*100, 1)]% station control, a takeover will require [time] minutes.\nYour gang will be unable to gain influence while it is active.\nThe entire station will likely be alerted to it once it starts.\nYou have [tempgang.dom_attempts] attempt(s) remaining. Are you ready?","Confirm","Ready","Later") == "Ready")
|
||||
if(alert(user,"With [round((tempgang.territory.len/GLOB.start_state.num_territories)*100, 1)]% station control, a takeover will require [time] minutes.\nYour gang will be unable to gain influence while it is active.\nThe entire station will likely be alerted to it once it starts.\nYou have [tempgang.dom_attempts] attempt(s) remaining. Are you ready?","Confirm","Ready","Later") == "Ready")
|
||||
if((tempgang.is_dominating) || !tempgang.dom_attempts || !in_range(src, user) || !isturf(loc))
|
||||
return 0
|
||||
|
||||
@@ -181,9 +181,9 @@
|
||||
countdown.start()
|
||||
|
||||
set_light(3)
|
||||
START_PROCESSING(SSmachine, src)
|
||||
START_PROCESSING(SSmachines, src)
|
||||
|
||||
gang.message_gangtools("Hostile takeover in progress: Estimated [time] minutes until victory.[gang.dom_attempts ? "" : " This is your final attempt."]")
|
||||
for(var/datum/gang/G in ticker.mode.gangs)
|
||||
for(var/datum/gang/G in SSticker.mode.gangs)
|
||||
if(G != gang)
|
||||
G.message_gangtools("Enemy takeover attempt detected in [locname]: Estimated [time] minutes until our defeat.",1,1)
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
//gang.dm
|
||||
//Gang War Game Mode
|
||||
|
||||
var/list/gang_name_pool = list("Clandestine", "Prima", "Zero-G", "Max", "Blasto", "Waffle", "North", "Omni", "Newton", "Cyber", "Donk", "Gene", "Gib", "Tunnel", "Diablo", "Psyke", "Osiron", "Sirius", "Sleeping Carp")
|
||||
var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple")
|
||||
GLOBAL_LIST_INIT(gang_name_pool, list("Clandestine", "Prima", "Zero-G", "Max", "Blasto", "Waffle", "North", "Omni", "Newton", "Cyber", "Donk", "Gene", "Gib", "Tunnel", "Diablo", "Psyke", "Osiron", "Sirius", "Sleeping Carp"))
|
||||
GLOBAL_LIST_INIT(gang_colors_pool, list("red","orange","yellow","green","blue","purple"))
|
||||
|
||||
/datum/game_mode
|
||||
var/list/datum/gang/gangs = list()
|
||||
@@ -248,7 +248,7 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
|
||||
return gang_bosses
|
||||
|
||||
/proc/determine_domination_time(var/datum/gang/G)
|
||||
return max(180,900 - (round((G.territory.len/start_state.num_territories)*100, 1) * 12))
|
||||
return max(180,900 - (round((G.territory.len/GLOB.start_state.num_territories)*100, 1) * 12))
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
//Announces the end of the game with all relavent information stated//
|
||||
@@ -261,15 +261,15 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
|
||||
to_chat(world, "<span class='redtext'>The station was [station_was_nuked ? "destroyed!" : "evacuated before a gang could claim it! The station wins!"]</span><br>")
|
||||
feedback_set_details("round_end_result","loss - gangs failed takeover")
|
||||
|
||||
ticker.news_report = GANG_LOSS
|
||||
SSticker.news_report = GANG_LOSS
|
||||
else
|
||||
to_chat(world, "<span class='redtext'>The [winner.name] Gang successfully performed a hostile takeover of the station!</span><br>")
|
||||
feedback_set_details("round_end_result","win - gang domination complete")
|
||||
|
||||
ticker.news_report = GANG_TAKEOVER
|
||||
SSticker.news_report = GANG_TAKEOVER
|
||||
|
||||
for(var/datum/gang/G in gangs)
|
||||
var/text = "<b>The [G.name] Gang was [winner==G ? "<span class='greenannounce'>victorious</span>" : "<span class='boldannounce'>defeated</span>"] with [round((G.territory.len/start_state.num_territories)*100, 1)]% control of the station!</b>"
|
||||
var/text = "<b>The [G.name] Gang was [winner==G ? "<span class='greenannounce'>victorious</span>" : "<span class='boldannounce'>defeated</span>"] with [round((G.territory.len/GLOB.start_state.num_territories)*100, 1)]% control of the station!</b>"
|
||||
text += "<br>The [G.name] Gang Bosses were:"
|
||||
for(var/datum/mind/boss in G.bosses)
|
||||
text += printplayer(boss, 1)
|
||||
@@ -294,7 +294,7 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
|
||||
/datum/gang_points/process(seconds)
|
||||
var/list/winners = list() //stores the winners if there are any
|
||||
|
||||
for(var/datum/gang/G in ticker.mode.gangs)
|
||||
for(var/datum/gang/G in SSticker.mode.gangs)
|
||||
if(world.time > next_point_time)
|
||||
G.income()
|
||||
|
||||
@@ -311,7 +311,7 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
|
||||
G.domination(0.5)
|
||||
priority_announce("Multiple station takeover attempts have made simultaneously. Conflicting takeover attempts appears to have restarted.","Network Alert")
|
||||
else
|
||||
ticker.mode.explosion_in_progress = 1
|
||||
ticker.station_explosion_cinematic(1)
|
||||
ticker.mode.explosion_in_progress = 0
|
||||
ticker.force_ending = pick(winners)
|
||||
SSticker.mode.explosion_in_progress = 1
|
||||
SSticker.station_explosion_cinematic(1)
|
||||
SSticker.mode.explosion_in_progress = 0
|
||||
SSticker.force_ending = pick(winners)
|
||||
|
||||
@@ -42,13 +42,13 @@
|
||||
)
|
||||
|
||||
/datum/gang/New(loc,gangname)
|
||||
if(!gang_colors_pool.len)
|
||||
if(!GLOB.gang_colors_pool.len)
|
||||
message_admins("WARNING: Maximum number of gangs have been exceeded!")
|
||||
throw EXCEPTION("Maximum number of gangs has been exceeded")
|
||||
return
|
||||
else
|
||||
color = pick(gang_colors_pool)
|
||||
gang_colors_pool -= color
|
||||
color = pick(GLOB.gang_colors_pool)
|
||||
GLOB.gang_colors_pool -= color
|
||||
switch(color)
|
||||
if("red")
|
||||
color_hex = "#DA0000"
|
||||
@@ -63,8 +63,8 @@
|
||||
if("purple")
|
||||
color_hex = "#DA00FF"
|
||||
|
||||
name = (gangname ? gangname : pick(gang_name_pool))
|
||||
gang_name_pool -= name
|
||||
name = (gangname ? gangname : pick(GLOB.gang_name_pool))
|
||||
GLOB.gang_name_pool -= name
|
||||
|
||||
ganghud = new()
|
||||
ganghud.color = color_hex
|
||||
@@ -85,11 +85,11 @@
|
||||
|
||||
/datum/gang/proc/add_gang_hud(datum/mind/recruit_mind)
|
||||
ganghud.join_hud(recruit_mind.current)
|
||||
ticker.mode.set_antag_hud(recruit_mind.current, ((recruit_mind in bosses) ? "gang_boss" : "gangster"))
|
||||
SSticker.mode.set_antag_hud(recruit_mind.current, ((recruit_mind in bosses) ? "gang_boss" : "gangster"))
|
||||
|
||||
/datum/gang/proc/remove_gang_hud(datum/mind/defector_mind)
|
||||
ganghud.leave_hud(defector_mind.current)
|
||||
ticker.mode.set_antag_hud(defector_mind.current, null)
|
||||
SSticker.mode.set_antag_hud(defector_mind.current, null)
|
||||
|
||||
/datum/gang/proc/domination(modifier=1)
|
||||
set_domination_time(determine_domination_time(src) * modifier)
|
||||
@@ -113,7 +113,7 @@
|
||||
return 0
|
||||
|
||||
var/gang_style_list = list("Gang Colors","Black Suits","White Suits","Leather Jackets","Leather Overcoats","Puffer Jackets","Military Jackets","Tactical Turtlenecks","Soviet Uniforms")
|
||||
if(!style && (user.mind in ticker.mode.get_gang_bosses())) //Only the boss gets to pick a style
|
||||
if(!style && (user.mind in SSticker.mode.get_gang_bosses())) //Only the boss gets to pick a style
|
||||
style = input("Pick an outfit style.", "Pick Style") as null|anything in gang_style_list
|
||||
|
||||
if(gangtool.can_use(user) && (gangtool.outfits >= 1))
|
||||
@@ -240,7 +240,7 @@
|
||||
territory_new = list()
|
||||
territory_lost = list()
|
||||
|
||||
var/control = round((territory.len/start_state.num_territories)*100, 1)
|
||||
var/control = round((territory.len/GLOB.start_state.num_territories)*100, 1)
|
||||
message += "Your gang now has <b>[control]% control</b> of the station.<BR>*---------*"
|
||||
message_gangtools(message)
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
if(!istype(M))
|
||||
return
|
||||
if(ishuman(M) && ishuman(user) && M.stat != DEAD)
|
||||
if(user.mind && (user.mind in ticker.mode.get_gang_bosses()))
|
||||
if(user.mind && (user.mind in SSticker.mode.get_gang_bosses()))
|
||||
if(..(M,user,1))
|
||||
if(cooldown)
|
||||
to_chat(user, "<span class='warning'>[src] needs more time to recharge before it can be used.</span>")
|
||||
@@ -23,7 +23,7 @@
|
||||
if(M.client)
|
||||
M.mind_initialize() //give them a mind datum if they don't have one.
|
||||
var/datum/gang/G = user.mind.gang_datum
|
||||
var/recruitable = ticker.mode.add_gangster(M.mind,G)
|
||||
var/recruitable = SSticker.mode.add_gangster(M.mind,G)
|
||||
switch(recruitable)
|
||||
if(2)
|
||||
M.Paralyse(5)
|
||||
|
||||
@@ -16,9 +16,10 @@
|
||||
var/free_pen = 0
|
||||
var/promotable = 0
|
||||
|
||||
/obj/item/device/gangtool/New() //Initialize supply point income if it hasn't already been started
|
||||
if(!ticker.mode.gang_points)
|
||||
ticker.mode.gang_points = new /datum/gang_points(ticker.mode)
|
||||
/obj/item/device/gangtool/Initialize() //Initialize supply point income if it hasn't already been started
|
||||
..()
|
||||
if(!SSticker.mode.gang_points)
|
||||
SSticker.mode.gang_points = new /datum/gang_points(SSticker.mode)
|
||||
|
||||
/obj/item/device/gangtool/attack_self(mob/user)
|
||||
if (!can_use(user))
|
||||
@@ -27,7 +28,7 @@
|
||||
var/dat
|
||||
if(!gang)
|
||||
dat += "This device is not registered.<br><br>"
|
||||
if(user.mind in ticker.mode.get_gang_bosses())
|
||||
if(user.mind in SSticker.mode.get_gang_bosses())
|
||||
if(promotable && user.mind.gang_datum.bosses.len < 3)
|
||||
dat += "Give this device to another member of your organization to use to promote them to Lieutenant.<br><br>"
|
||||
dat += "If this is meant as a spare device for yourself:<br>"
|
||||
@@ -46,9 +47,9 @@
|
||||
|
||||
var/isboss = (user.mind == gang.bosses[1])
|
||||
dat += "Registration: <B>[gang.name] Gang [isboss ? "Boss" : "Lieutenant"]</B><br>"
|
||||
dat += "Organization Size: <B>[gang.gangsters.len + gang.bosses.len]</B> | Station Control: <B>[round((gang.territory.len/start_state.num_territories)*100, 1)]%</B><br>"
|
||||
dat += "Organization Size: <B>[gang.gangsters.len + gang.bosses.len]</B> | Station Control: <B>[round((gang.territory.len/GLOB.start_state.num_territories)*100, 1)]%</B><br>"
|
||||
dat += "Gang Influence: <B>[gang.points]</B><br>"
|
||||
dat += "Time until Influence grows: <B>[(gang.points >= 999) ? ("--:--") : (time2text(ticker.mode.gang_points.next_point_time - world.time, "mm:ss"))]</B><br>"
|
||||
dat += "Time until Influence grows: <B>[(gang.points >= 999) ? ("--:--") : (time2text(SSticker.mode.gang_points.next_point_time - world.time, "mm:ss"))]</B><br>"
|
||||
dat += "<hr>"
|
||||
|
||||
|
||||
@@ -130,7 +131,7 @@
|
||||
for(var/datum/mind/ganger in members)
|
||||
if(ganger.current && (ganger.current.z <= 2) && (ganger.current.stat == CONSCIOUS))
|
||||
to_chat(ganger.current, ping)
|
||||
for(var/mob/M in dead_mob_list)
|
||||
for(var/mob/M in GLOB.dead_mob_list)
|
||||
var/link = FOLLOW_LINK(M, user)
|
||||
to_chat(M, "[link] [ping]")
|
||||
log_game("[key_name(user)] Messaged [gang.name] Gang: [message].")
|
||||
@@ -139,12 +140,12 @@
|
||||
/obj/item/device/gangtool/proc/register_device(mob/user)
|
||||
if(gang) //It's already been registered!
|
||||
return
|
||||
if((promotable && (user.mind in ticker.mode.get_gangsters())) || (user.mind in ticker.mode.get_gang_bosses()))
|
||||
if((promotable && (user.mind in SSticker.mode.get_gangsters())) || (user.mind in SSticker.mode.get_gang_bosses()))
|
||||
gang = user.mind.gang_datum
|
||||
gang.gangtools += src
|
||||
icon_state = "gangtool-[gang.color]"
|
||||
if(!(user.mind in gang.bosses))
|
||||
ticker.mode.remove_gangster(user.mind, 0, 2)
|
||||
SSticker.mode.remove_gangster(user.mind, 0, 2)
|
||||
gang.bosses += user.mind
|
||||
user.mind.gang_datum = gang
|
||||
user.mind.special_role = "[gang.name] Gang Lieutenant"
|
||||
@@ -153,8 +154,8 @@
|
||||
free_pen = 1
|
||||
gang.message_gangtools("[user] has been promoted to Lieutenant.")
|
||||
to_chat(user, "<FONT size=3 color=red><B>You have been promoted to Lieutenant!</B></FONT>")
|
||||
ticker.mode.forge_gang_objectives(user.mind)
|
||||
ticker.mode.greet_gang(user.mind,0)
|
||||
SSticker.mode.forge_gang_objectives(user.mind)
|
||||
SSticker.mode.greet_gang(user.mind,0)
|
||||
to_chat(user, "The <b>Gangtool</b> you registered will allow you to purchase weapons and equipment, and send messages to your gang.")
|
||||
to_chat(user, "Unlike regular gangsters, you may use <b>recruitment pens</b> to add recruits to your gang. Use them on unsuspecting crew members to recruit them. Don't forget to get your one free pen from the gangtool.")
|
||||
else
|
||||
@@ -194,7 +195,7 @@
|
||||
return 0
|
||||
var/datum/station_state/end_state = new /datum/station_state()
|
||||
end_state.count()
|
||||
if((100 * start_state.score(end_state)) < 80) //Shuttle cannot be recalled if the station is too damaged
|
||||
if((100 * GLOB.start_state.score(end_state)) < 80) //Shuttle cannot be recalled if the station is too damaged
|
||||
to_chat(user, "<span class='warning'>\icon[src]Error: Station communication systems compromised. Unable to establish connection.</span>")
|
||||
recalling = 0
|
||||
return 0
|
||||
@@ -227,7 +228,7 @@
|
||||
if(user.mind in gang.bosses)
|
||||
return 1
|
||||
else //If it's not registered, any gangster can use this to register
|
||||
if(user.mind in ticker.mode.get_all_gangsters())
|
||||
if(user.mind in SSticker.mode.get_all_gangsters())
|
||||
return 1
|
||||
|
||||
return 0
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
text += "Although more specific threats are commonplace, you should always remain vigilant for Syndicate agents aboard your station. Syndicate communications have implied that many \
|
||||
Nanotrasen employees are Syndicate agents with hidden memories that may be activated at a moment's notice, so it's possible that these agents might not even know their positions."
|
||||
if("wizard")
|
||||
text += "A dangerous Wizards' Federation individual by the name of [pick(wizard_first)] [pick(wizard_second)] has recently escaped confinement from an unlisted prison facility. This \
|
||||
text += "A dangerous Wizards' Federation individual by the name of [pick(GLOB.wizard_first)] [pick(GLOB.wizard_second)] has recently escaped confinement from an unlisted prison facility. This \
|
||||
man is a dangerous mutant with the ability to alter himself and the world around him by what he and his leaders believe to be magic. If this man attempts an attack on your station, \
|
||||
his execution is highly encouraged, as is the preservation of his body for later study."
|
||||
return text
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user