/tg/ 4/14 (#367)
* outside code stuff * defines, helpers, etc * everything not module * modules * compiled fixes + missing sounds
This commit is contained in:
@@ -162,9 +162,7 @@
|
||||
used = 1
|
||||
var/mob/dead/observer/theghost = pick(nuke_candidates)
|
||||
spawn_antag(theghost.client, get_turf(src), "syndieborg")
|
||||
var/datum/effect_system/spark_spread/S = new /datum/effect_system/spark_spread
|
||||
S.set_up(4, 1, src)
|
||||
S.start()
|
||||
do_sparks(4, TRUE, src)
|
||||
qdel(src)
|
||||
else
|
||||
to_chat(user, "<span class='warning'>Unable to connect to Syndicate command. Please wait and try again later or use the teleporter on your uplink to get your points refunded.</span>")
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
var/point_rate = 2
|
||||
|
||||
|
||||
/obj/structure/blob/core/New(loc, client/new_overmind = null, new_rate = 2, placed = 0)
|
||||
/obj/structure/blob/core/Initialize(mapload, client/new_overmind = null, new_rate = 2, placed = 0)
|
||||
GLOB.blob_cores += src
|
||||
START_PROCESSING(SSobj, src)
|
||||
GLOB.poi_list |= src
|
||||
@@ -25,7 +25,7 @@
|
||||
if(overmind)
|
||||
update_icon()
|
||||
point_rate = new_rate
|
||||
..()
|
||||
. = ..()
|
||||
|
||||
/obj/structure/blob/core/scannerreport()
|
||||
return "Directs the blob's expansion, gradually expands, and sustains nearby blob spores and blobbernauts."
|
||||
|
||||
@@ -10,10 +10,10 @@
|
||||
point_return = 25
|
||||
|
||||
|
||||
/obj/structure/blob/node/New(loc)
|
||||
/obj/structure/blob/node/Initialize()
|
||||
GLOB.blob_nodes += src
|
||||
START_PROCESSING(SSobj, src)
|
||||
..()
|
||||
. = ..()
|
||||
|
||||
/obj/structure/blob/node/scannerreport()
|
||||
return "Gradually expands and sustains nearby blob spores and blobbernauts."
|
||||
|
||||
@@ -21,14 +21,14 @@
|
||||
var/mob/camera/blob/overmind
|
||||
|
||||
|
||||
/obj/structure/blob/New(loc)
|
||||
/obj/structure/blob/Initialize()
|
||||
var/area/Ablob = get_area(loc)
|
||||
if(Ablob.blob_allowed) //Is this area allowed for winning as blob?
|
||||
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()
|
||||
if(atmosblock)
|
||||
CanAtmosPass = ATMOS_PASS_NO
|
||||
@@ -99,7 +99,7 @@
|
||||
var/list/blobs_to_affect = list()
|
||||
for(var/obj/structure/blob/B in urange(claim_range, src, 1))
|
||||
blobs_to_affect += B
|
||||
shuffle(blobs_to_affect)
|
||||
shuffle_inplace(blobs_to_affect)
|
||||
for(var/L in blobs_to_affect)
|
||||
var/obj/structure/blob/B = L
|
||||
if(!B.overmind && !istype(B, /obj/structure/blob/core) && prob(30))
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
// divided by healing_ticks to get heal/tick
|
||||
var/total_healing = 100
|
||||
|
||||
/obj/effect/proc_holder/changeling/fleshmend/New()
|
||||
..()
|
||||
/obj/effect/proc_holder/changeling/fleshmend/Initialize()
|
||||
. = ..()
|
||||
START_PROCESSING(SSobj, src)
|
||||
|
||||
/obj/effect/proc_holder/changeling/fleshmend/Destroy()
|
||||
|
||||
@@ -162,8 +162,8 @@
|
||||
sharpness = IS_SHARP
|
||||
var/can_drop = FALSE
|
||||
|
||||
/obj/item/weapon/melee/arm_blade/New(location,silent,synthetic)
|
||||
..()
|
||||
/obj/item/weapon/melee/arm_blade/Initialize(mapload,silent,synthetic)
|
||||
. = ..()
|
||||
if(ismob(loc) && !silent)
|
||||
loc.visible_message("<span class='warning'>A grotesque blade forms around [loc.name]\'s arm!</span>", "<span class='warning'>Our arm twists and mutates, transforming it into a deadly blade.</span>", "<span class='italics'>You hear organic matter ripping and tearing!</span>")
|
||||
if(synthetic)
|
||||
@@ -240,8 +240,8 @@
|
||||
throw_range = 0
|
||||
throw_speed = 0
|
||||
|
||||
/obj/item/weapon/gun/magic/tentacle/New(location,silent)
|
||||
..()
|
||||
/obj/item/weapon/gun/magic/tentacle/Initialize(mapload, silent)
|
||||
. = ..()
|
||||
if(ismob(loc))
|
||||
if(!silent)
|
||||
loc.visible_message("<span class='warning'>[loc.name]\'s arm starts stretching inhumanly!</span>", "<span class='warning'>Our arm twists and mutates, transforming it into a tentacle.</span>", "<span class='italics'>You hear organic matter ripping and tearing!</span>")
|
||||
@@ -266,9 +266,9 @@
|
||||
firing_effect_type = null
|
||||
var/obj/item/weapon/gun/magic/tentacle/gun //the item that shot it
|
||||
|
||||
/obj/item/ammo_casing/magic/tentacle/New(obj/item/weapon/gun/magic/tentacle/tentacle_gun)
|
||||
gun = tentacle_gun
|
||||
..()
|
||||
/obj/item/ammo_casing/magic/tentacle/Initialize()
|
||||
gun = loc
|
||||
. = ..()
|
||||
|
||||
/obj/item/ammo_casing/magic/tentacle/Destroy()
|
||||
gun = null
|
||||
@@ -285,9 +285,9 @@
|
||||
var/chain
|
||||
var/obj/item/ammo_casing/magic/tentacle/source //the item that shot it
|
||||
|
||||
/obj/item/projectile/tentacle/New(obj/item/ammo_casing/magic/tentacle/tentacle_casing)
|
||||
source = tentacle_casing
|
||||
..()
|
||||
/obj/item/projectile/tentacle/Initialize()
|
||||
source = loc
|
||||
. = ..()
|
||||
|
||||
/obj/item/projectile/tentacle/fire(setAngle)
|
||||
if(firer)
|
||||
@@ -407,8 +407,8 @@
|
||||
|
||||
var/remaining_uses //Set by the changeling ability.
|
||||
|
||||
/obj/item/weapon/shield/changeling/New()
|
||||
..()
|
||||
/obj/item/weapon/shield/changeling/Initialize()
|
||||
. = ..()
|
||||
if(ismob(loc))
|
||||
loc.visible_message("<span class='warning'>The end of [loc.name]\'s hand inflates rapidly, forming a huge shield-like mass!</span>", "<span class='warning'>We inflate our hand into a strong shield.</span>", "<span class='italics'>You hear organic matter ripping and tearing!</span>")
|
||||
|
||||
@@ -452,8 +452,8 @@
|
||||
allowed = list(/obj/item/device/flashlight, /obj/item/weapon/tank/internals/emergency_oxygen, /obj/item/weapon/tank/internals/oxygen)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 90, acid = 90) //No armor at all.
|
||||
|
||||
/obj/item/clothing/suit/space/changeling/New()
|
||||
..()
|
||||
/obj/item/clothing/suit/space/changeling/Initialize()
|
||||
. = ..()
|
||||
if(ismob(loc))
|
||||
loc.visible_message("<span class='warning'>[loc.name]\'s flesh rapidly inflates, forming a bloated mass around their body!</span>", "<span class='warning'>We inflate our flesh, creating a spaceproof suit!</span>", "<span class='italics'>You hear organic matter ripping and tearing!</span>")
|
||||
START_PROCESSING(SSobj, src)
|
||||
@@ -501,8 +501,8 @@
|
||||
cold_protection = 0
|
||||
heat_protection = 0
|
||||
|
||||
/obj/item/clothing/suit/armor/changeling/New()
|
||||
..()
|
||||
/obj/item/clothing/suit/armor/changeling/Initialize()
|
||||
. = ..()
|
||||
if(ismob(loc))
|
||||
loc.visible_message("<span class='warning'>[loc.name]\'s flesh turns black, quickly transforming into a hard, chitinous mass!</span>", "<span class='warning'>We harden our flesh, creating a suit of armor!</span>", "<span class='italics'>You hear organic matter ripping and tearing!</span>")
|
||||
|
||||
|
||||
@@ -21,10 +21,8 @@
|
||||
if(!charge && !panel_open)
|
||||
panel_open = TRUE
|
||||
icon_state = "[initial(icon_state)]-o"
|
||||
var/datum/effect_system/spark_spread/spks = new(get_turf(src))
|
||||
spks.set_up(10, 0, get_turf(src))
|
||||
spks.start()
|
||||
visible_message("<span class='warning'>[src]'s panel flies open with a flurry of spark</span>")
|
||||
do_sparks(10, FALSE, src)
|
||||
visible_message("<span class='warning'>[src]'s panel flies open with a flurry of sparks!</span>")
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/stock_parts/cell/power_drain(clockcult_user)
|
||||
|
||||
@@ -124,7 +124,7 @@ structure_check() searches for nearby cultist structures required for the invoca
|
||||
if(allow_excess_invokers)
|
||||
chanters += invokers
|
||||
else
|
||||
shuffle(invokers)
|
||||
shuffle_inplace(invokers)
|
||||
for(var/i in 1 to req_cultists)
|
||||
var/L = pick_n_take(invokers)
|
||||
if(L)
|
||||
|
||||
@@ -50,12 +50,16 @@
|
||||
|
||||
/datum/game_mode/devil/post_setup()
|
||||
for(var/datum/mind/devil in devils)
|
||||
spawn(rand(10,100))
|
||||
finalize_devil(devil, TRUE)
|
||||
spawn(100)
|
||||
add_devil_objectives(devil, objective_count) //This has to be in a separate loop, as we need devil names to be generated before we give objectives in devil agent.
|
||||
devil.announceDevilLaws()
|
||||
devil.announce_objectives()
|
||||
post_setup_finalize(devil)
|
||||
modePlayer += devils
|
||||
..()
|
||||
return 1
|
||||
|
||||
/datum/game_mode/devil/proc/post_setup_finalize(datum/mind/devil)
|
||||
set waitfor = FALSE
|
||||
sleep(rand(10,100))
|
||||
finalize_devil(devil, TRUE)
|
||||
sleep(100)
|
||||
add_devil_objectives(devil, objective_count) //This has to be in a separate loop, as we need devil names to be generated before we give objectives in devil agent.
|
||||
devil.announceDevilLaws()
|
||||
devil.announce_objectives()
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
|
||||
/datum/game_mode/proc/finalize_devil(datum/mind/devil_mind, ascendable = FALSE)
|
||||
|
||||
set waitfor = FALSE
|
||||
var/trueName= randomDevilName()
|
||||
|
||||
devil_mind.devilinfo = devilInfo(trueName, 1)
|
||||
@@ -39,14 +39,14 @@
|
||||
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)
|
||||
devil_mind.devilinfo.update_hud()
|
||||
if(devil_mind.assigned_role == "Clown" && ishuman(devil_mind.current))
|
||||
var/mob/living/carbon/human/S = devil_mind.current
|
||||
to_chat(S, "<span class='notice'>Your infernal nature has allowed you to overcome your clownishness.</span>")
|
||||
S.dna.remove_mutation(CLOWNMUT)
|
||||
if(issilicon(devil_mind.current))
|
||||
add_law_sixsixsix(devil_mind.current)
|
||||
sleep(10)
|
||||
devil_mind.devilinfo.update_hud()
|
||||
if(devil_mind.assigned_role == "Clown" && ishuman(devil_mind.current))
|
||||
var/mob/living/carbon/human/S = devil_mind.current
|
||||
to_chat(S, "<span class='notice'>Your infernal nature has allowed you to overcome your clownishness.</span>")
|
||||
S.dna.remove_mutation(CLOWNMUT)
|
||||
|
||||
/datum/game_mode/proc/add_devil_objectives(datum/mind/devil_mind, quantity)
|
||||
var/list/validtypes = list(/datum/objective/devil/soulquantity, /datum/objective/devil/soulquality, /datum/objective/devil/sintouch, /datum/objective/devil/buy_target)
|
||||
|
||||
@@ -60,8 +60,7 @@
|
||||
stat = DEAD
|
||||
..(gibbed)
|
||||
drop_all_held_items()
|
||||
spawn (0)
|
||||
mind.devilinfo.beginResurrectionCheck(src)
|
||||
INVOKE_ASYNC(mind.devilinfo, /datum/devilinfo/proc/beginResurrectionCheck, src)
|
||||
|
||||
|
||||
/mob/living/carbon/true_devil/examine(mob/user)
|
||||
|
||||
@@ -75,11 +75,10 @@
|
||||
|
||||
|
||||
///Everyone should now be on the station and have their normal gear. This is the place to give the special roles extra things
|
||||
/datum/game_mode/proc/post_setup(report=0) //Gamemodes can override the intercept report. Passing a 1 as the argument will force a report.
|
||||
/datum/game_mode/proc/post_setup(report) //Gamemodes can override the intercept report. Passing TRUE as the argument will force a report.
|
||||
if(!report)
|
||||
report = config.intercept
|
||||
spawn (ROUNDSTART_LOGOUT_REPORT_TIME)
|
||||
display_roundstart_logout_report()
|
||||
addtimer(CALLBACK(GLOBAL_PROC, .proc/display_roundstart_logout_report), ROUNDSTART_LOGOUT_REPORT_TIME)
|
||||
|
||||
feedback_set_details("round_start","[time2text(world.realtime)]")
|
||||
if(SSticker && SSticker.mode)
|
||||
@@ -88,8 +87,7 @@
|
||||
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)
|
||||
addtimer(CALLBACK(src, .proc/send_intercept, 0), rand(waittime_l, waittime_h))
|
||||
generate_station_goals()
|
||||
GLOB.start_state = new /datum/station_state()
|
||||
GLOB.start_state.count(1)
|
||||
@@ -105,6 +103,7 @@
|
||||
|
||||
///Allows rounds to basically be "rerolled" should the initial premise fall through. Also known as mulligan antags.
|
||||
/datum/game_mode/proc/convert_roundtype()
|
||||
set waitfor = FALSE
|
||||
var/list/living_crew = list()
|
||||
|
||||
for(var/mob/Player in GLOB.mob_list)
|
||||
@@ -158,15 +157,16 @@
|
||||
|
||||
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[SSticker.mode.config_tag])
|
||||
round_converted = 0
|
||||
return 1
|
||||
for(var/mob/living/carbon/human/H in antag_candidates)
|
||||
replacementmode.make_antag_chance(H)
|
||||
round_converted = 2
|
||||
message_admins("-- IMPORTANT: The roundtype has been converted to [replacementmode.name], antagonists may have been created! --")
|
||||
return 1
|
||||
. = 1
|
||||
sleep(rand(600,1800))
|
||||
//somewhere between 1 and 3 minutes from now
|
||||
if(!config.midround_antag[SSticker.mode.config_tag])
|
||||
round_converted = 0
|
||||
return 1
|
||||
for(var/mob/living/carbon/human/H in antag_candidates)
|
||||
replacementmode.make_antag_chance(H)
|
||||
round_converted = 2
|
||||
message_admins("-- IMPORTANT: The roundtype has been converted to [replacementmode.name], antagonists may have been created! --")
|
||||
|
||||
|
||||
///Called by the gameSSticker
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
set_light(2)
|
||||
GLOB.poi_list |= src
|
||||
spark_system = new
|
||||
spark_system.set_up(5, 1, src)
|
||||
spark_system.set_up(5, TRUE, src)
|
||||
countdown = new(src)
|
||||
|
||||
/obj/machinery/dominator/examine(mob/user)
|
||||
@@ -129,9 +129,8 @@
|
||||
set_broken()
|
||||
GLOB.poi_list.Remove(src)
|
||||
gang = null
|
||||
qdel(spark_system)
|
||||
qdel(countdown)
|
||||
countdown = null
|
||||
QDEL_NULL(spark_system)
|
||||
QDEL_NULL(countdown)
|
||||
STOP_PROCESSING(SSmachines, src)
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -73,15 +73,16 @@ GLOBAL_LIST_INIT(gang_colors_pool, list("red","orange","yellow","green","blue","
|
||||
|
||||
|
||||
/datum/game_mode/gang/post_setup()
|
||||
spawn(rand(10,100))
|
||||
for(var/datum/gang/G in gangs)
|
||||
for(var/datum/mind/boss_mind in G.bosses)
|
||||
G.add_gang_hud(boss_mind)
|
||||
forge_gang_objectives(boss_mind)
|
||||
greet_gang(boss_mind)
|
||||
equip_gang(boss_mind.current,G)
|
||||
modePlayer += boss_mind
|
||||
set waitfor = FALSE
|
||||
..()
|
||||
sleep(rand(10,100))
|
||||
for(var/datum/gang/G in gangs)
|
||||
for(var/datum/mind/boss_mind in G.bosses)
|
||||
G.add_gang_hud(boss_mind)
|
||||
forge_gang_objectives(boss_mind)
|
||||
greet_gang(boss_mind)
|
||||
equip_gang(boss_mind.current,G)
|
||||
modePlayer += boss_mind
|
||||
|
||||
|
||||
/datum/game_mode/proc/forge_gang_objectives(datum/mind/boss_mind)
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
..()
|
||||
|
||||
/obj/item/weapon/pen/gang/proc/cooldown(datum/gang/gang)
|
||||
set waitfor = FALSE
|
||||
var/cooldown_time = 600+(600*gang.bosses.len) // 1recruiter=2mins, 2recruiters=3mins, 3recruiters=4mins
|
||||
|
||||
cooldown = 1
|
||||
@@ -52,8 +53,8 @@
|
||||
|
||||
if(charges)
|
||||
cooldown_time = 50
|
||||
spawn(cooldown_time)
|
||||
cooldown = 0
|
||||
icon_state = "pen"
|
||||
var/mob/M = get(src, /mob)
|
||||
to_chat(M, "<span class='notice'>\icon[src] [src][(src.loc == M)?(""):(" in your [src.loc]")] vibrates softly. It is ready to be used again.</span>")
|
||||
sleep(cooldown_time)
|
||||
cooldown = 0
|
||||
icon_state = "pen"
|
||||
var/mob/M = get(src, /mob)
|
||||
to_chat(M, "<span class='notice'>\icon[src] [src][(src.loc == M)?(""):(" in your [src.loc]")] vibrates softly. It is ready to be used again.</span>")
|
||||
|
||||
@@ -192,19 +192,20 @@
|
||||
set category = "Malfunction"
|
||||
set name = "Destroy RCDs"
|
||||
set desc = "Detonate all RCDs on the station, while sparing onboard cyborg RCDs."
|
||||
set waitfor = FALSE
|
||||
|
||||
if(!canUseTopic() || malf_cooldown)
|
||||
return
|
||||
|
||||
for(var/I in GLOB.rcd_list)
|
||||
if(!istype(I, /obj/item/weapon/rcd/borg)) //Ensures that cyborg RCDs are spared.
|
||||
var/obj/item/weapon/rcd/RCD = I
|
||||
if(!istype(I, /obj/item/weapon/construction/rcd/borg)) //Ensures that cyborg RCDs are spared.
|
||||
var/obj/item/weapon/construction/rcd/RCD = I
|
||||
RCD.detonate_pulse()
|
||||
|
||||
to_chat(src, "<span class='warning'>RCD detonation pulse emitted.</span>")
|
||||
malf_cooldown = 1
|
||||
spawn(100)
|
||||
malf_cooldown = 0
|
||||
malf_cooldown = TRUE
|
||||
sleep(100)
|
||||
malf_cooldown = FALSE
|
||||
|
||||
/datum/AI_Module/large/mecha_domination
|
||||
module_name = "Viral Mech Domination"
|
||||
|
||||
@@ -1072,4 +1072,4 @@ GLOBAL_VAR_INIT(total_borer_hosts_needed, 10)
|
||||
|
||||
/datum/action/innate/borer/jumpstart_host/Activate()
|
||||
var/mob/living/simple_animal/borer/B = owner
|
||||
B.jumpstart()
|
||||
B.jumpstart()
|
||||
@@ -218,7 +218,7 @@ GLOBAL_VAR_INIT(hsboxspawn, TRUE)
|
||||
if("hsbrcd")
|
||||
if(!GLOB.hsboxspawn) return
|
||||
|
||||
new/obj/item/weapon/rcd/combat(usr.loc)
|
||||
new/obj/item/weapon/construction/rcd/combat(usr.loc)
|
||||
|
||||
//
|
||||
// New sandbox airlock maker
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
// As soon as we get 3 or 4 extra latejoin traitors, make them traitors and kill each other.
|
||||
if(late_joining_list.len >= rand(3, 4))
|
||||
// True randomness
|
||||
shuffle(late_joining_list)
|
||||
shuffle_inplace(late_joining_list)
|
||||
// Reset the target_list, it'll be used again in force_traitor_objectives
|
||||
target_list = list()
|
||||
|
||||
|
||||
@@ -329,7 +329,7 @@
|
||||
if("cyborg")
|
||||
for(var/X in M.bodyparts)
|
||||
var/obj/item/bodypart/affecting = X
|
||||
affecting.change_bodypart_status(BODYPART_ROBOTIC)
|
||||
affecting.change_bodypart_status(BODYPART_ROBOTIC, FALSE, TRUE)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/eyepatch(M), slot_glasses)
|
||||
M.put_in_hands_or_del(sword)
|
||||
|
||||
|
||||
@@ -117,7 +117,7 @@
|
||||
mages_made--
|
||||
return
|
||||
else
|
||||
shuffle(candidates)
|
||||
shuffle_inplace(candidates)
|
||||
for(var/mob/i in candidates)
|
||||
if(!i || !i.client) continue //Dont bother removing them from the list since we only grab one wizard
|
||||
|
||||
|
||||
Reference in New Issue
Block a user