Merge branch 'master' of https://github.com/PolarisSS13/Polaris into 3/11/2016_integrated_circuits

This commit is contained in:
Neerti
2016-08-31 20:40:35 -04:00
496 changed files with 8917 additions and 7728 deletions

BIN
btime.dll

Binary file not shown.

BIN
btime.so

Binary file not shown.

View File

@@ -24,7 +24,6 @@
/obj/machinery/atmospherics/unary/freezer/New() /obj/machinery/atmospherics/unary/freezer/New()
..() ..()
initialize_directions = dir initialize_directions = dir
circuit = new circuit(src)
component_parts = list() component_parts = list()
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src) component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
component_parts += new /obj/item/weapon/stock_parts/capacitor(src) component_parts += new /obj/item/weapon/stock_parts/capacitor(src)

View File

@@ -24,7 +24,6 @@
/obj/machinery/atmospherics/unary/heater/New() /obj/machinery/atmospherics/unary/heater/New()
..() ..()
initialize_directions = dir initialize_directions = dir
circuit = new circuit(src)
component_parts = list() component_parts = list()
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src) component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
component_parts += new /obj/item/weapon/stock_parts/capacitor(src) component_parts += new /obj/item/weapon/stock_parts/capacitor(src)

View File

@@ -1,18 +0,0 @@
// Comment this out if the external btime library is unavailable
#define PRECISE_TIMER_AVAILABLE
#ifdef PRECISE_TIMER_AVAILABLE
var/global/__btime__libName = "btime.[world.system_type==MS_WINDOWS?"dll":"so"]"
#define TimeOfHour (__extern__timeofhour)
#define __extern__timeofhour text2num(call(__btime__libName, "gettime")())
/hook/startup/proc/checkbtime()
try
// This will always return 1 unless the btime library cannot be accessed
if(TimeOfHour || 1) return 1
catch(var/exception/e)
log_to_dd("PRECISE_TIMER_AVAILABLE is defined in btime.dm, but calling the btime library failed: [e]")
log_to_dd("This is a fatal error. The world will now shut down.")
del(world)
#else
#define TimeOfHour (world.timeofday % 36000)
#endif

View File

@@ -48,6 +48,7 @@ var/global/defer_powernet_rebuild = 0 // True if net rebuild will be called
#define NETWORK_ROBOTS "Robots" #define NETWORK_ROBOTS "Robots"
#define NETWORK_PRISON "Prison" #define NETWORK_PRISON "Prison"
#define NETWORK_SECURITY "Security" #define NETWORK_SECURITY "Security"
#define NETWORK_INTERROGATION "Interrogation"
#define NETWORK_TELECOM "Tcomsat" #define NETWORK_TELECOM "Tcomsat"
#define NETWORK_THUNDER "Thunderdome" #define NETWORK_THUNDER "Thunderdome"
#define NETWORK_COMMUNICATORS "Communicators" #define NETWORK_COMMUNICATORS "Communicators"

View File

@@ -27,3 +27,6 @@
#define TICKS_IN_DAY 24*60*60*10 #define TICKS_IN_DAY 24*60*60*10
#define TICKS_IN_SECOND 10 #define TICKS_IN_SECOND 10
#define SIMPLE_SIGN(X) ((X) < 0 ? -1 : 1)
#define SIGN(X) ((X) ? SIMPLE_SIGN(X) : 0)

View File

@@ -11,10 +11,9 @@
#define PROCESS_DEFAULT_HANG_ALERT_TIME 600 // 60 seconds #define PROCESS_DEFAULT_HANG_ALERT_TIME 600 // 60 seconds
#define PROCESS_DEFAULT_HANG_RESTART_TIME 900 // 90 seconds #define PROCESS_DEFAULT_HANG_RESTART_TIME 900 // 90 seconds
#define PROCESS_DEFAULT_SCHEDULE_INTERVAL 50 // 50 ticks #define PROCESS_DEFAULT_SCHEDULE_INTERVAL 50 // 50 ticks
#define PROCESS_DEFAULT_SLEEP_INTERVAL 8 // 2 ticks #define PROCESS_DEFAULT_SLEEP_INTERVAL 8 // 1/8th of a tick
#define PROCESS_DEFAULT_CPU_THRESHOLD 90 // 90%
// SCHECK macros // SCHECK macros
// This references src directly to work around a weird bug with try/catch // This references src directly to work around a weird bug with try/catch
#define SCHECK_EVERY(this_many_calls) if(++src.calls_since_last_scheck >= this_many_calls) sleepCheck() #define SCHECK_EVERY(this_many_calls) if(++src.calls_since_last_scheck >= this_many_calls) sleepCheck()
#define SCHECK SCHECK_EVERY(50) #define SCHECK sleepCheck()

View File

@@ -24,8 +24,7 @@
// Languages. // Languages.
#define LANGUAGE_SOL_COMMON "Sol Common" #define LANGUAGE_SOL_COMMON "Sol Common"
#define LANGUAGE_UNATHI "Sinta'unathi" #define LANGUAGE_UNATHI "Sinta'unathi"
#define LANGUAGE_SIIK_MAAS "Siik'maas" #define LANGUAGE_SIIK "Siik"
#define LANGUAGE_SIIK_TAJR "Siik'tajr"
#define LANGUAGE_SKRELLIAN "Skrellian" #define LANGUAGE_SKRELLIAN "Skrellian"
#define LANGUAGE_ROOTSPEAK "Rootspeak" #define LANGUAGE_ROOTSPEAK "Rootspeak"
#define LANGUAGE_TRADEBAND "Tradeband" #define LANGUAGE_TRADEBAND "Tradeband"

View File

@@ -0,0 +1,72 @@
#define ARCHAEO_BOWL 1
#define ARCHAEO_URN 2
#define ARCHAEO_CUTLERY 3
#define ARCHAEO_STATUETTE 4
#define ARCHAEO_INSTRUMENT 5
#define ARCHAEO_KNIFE 6
#define ARCHAEO_COIN 7
#define ARCHAEO_HANDCUFFS 8
#define ARCHAEO_BEARTRAP 9
#define ARCHAEO_LIGHTER 10
#define ARCHAEO_BOX 11
#define ARCHAEO_GASTANK 12
#define ARCHAEO_TOOL 13
#define ARCHAEO_METAL 14
#define ARCHAEO_PEN 15
#define ARCHAEO_CRYSTAL 16
#define ARCHAEO_CULTBLADE 17
#define ARCHAEO_TELEBEACON 18
#define ARCHAEO_CLAYMORE 19
#define ARCHAEO_CULTROBES 20
#define ARCHAEO_SOULSTONE 21
#define ARCHAEO_SHARD 22
#define ARCHAEO_RODS 23
#define ARCHAEO_STOCKPARTS 24
#define ARCHAEO_KATANA 25
#define ARCHAEO_LASER 26
#define ARCHAEO_GUN 27
#define ARCHAEO_UNKNOWN 28
#define ARCHAEO_FOSSIL 29
#define ARCHAEO_SHELL 30
#define ARCHAEO_PLANT 31
#define ARCHAEO_REMAINS_HUMANOID 32
#define ARCHAEO_REMAINS_ROBOT 33
#define ARCHAEO_REMAINS_XENO 34
#define ARCHAEO_GASMASK 35
#define MAX_ARCHAEO 35
#define DIGSITE_GARDEN 1
#define DIGSITE_ANIMAL 2
#define DIGSITE_HOUSE 3
#define DIGSITE_TECHNICAL 4
#define DIGSITE_TEMPLE 5
#define DIGSITE_WAR 6
#define EFFECT_TOUCH 0
#define EFFECT_AURA 1
#define EFFECT_PULSE 2
#define MAX_EFFECT 2
#define TRIGGER_TOUCH 0
#define TRIGGER_WATER 1
#define TRIGGER_ACID 2
#define TRIGGER_VOLATILE 3
#define TRIGGER_TOXIN 4
#define TRIGGER_FORCE 5
#define TRIGGER_ENERGY 6
#define TRIGGER_HEAT 7
#define TRIGGER_COLD 8
#define TRIGGER_PHORON 9
#define TRIGGER_OXY 10
#define TRIGGER_CO2 11
#define TRIGGER_NITRO 12
#define MAX_TRIGGER 12
#define EFFECT_UNKNOWN 0
#define EFFECT_ENERGY 1
#define EFFECT_PSIONIC 2
#define EFFECT_ELECTRO 3
#define EFFECT_PARTICLE 4
#define EFFECT_ORGANIC 5
#define EFFECT_BLUESPACE 6
#define EFFECT_SYNTH 7

View File

@@ -11,24 +11,11 @@
//Returns a list in plain english as a string //Returns a list in plain english as a string
/proc/english_list(var/list/input, nothing_text = "nothing", and_text = " and ", comma_text = ", ", final_comma_text = "" ) /proc/english_list(var/list/input, nothing_text = "nothing", and_text = " and ", comma_text = ", ", final_comma_text = "" )
var/total = input.len switch(input.len)
if (!total) if(0) return nothing_text
return "[nothing_text]" if(1) return "[input[1]]"
else if (total == 1) if(2) return "[input[1]][and_text][input[2]]"
return "[input[1]]" else return "[jointext(input, comma_text, 1, -1)][final_comma_text][and_text][input[input.len]]"
else if (total == 2)
return "[input[1]][and_text][input[2]]"
else
var/output = ""
var/index = 1
while (index < total)
if (index == total - 1)
comma_text = final_comma_text
output += "[input[index]][comma_text]"
index++
return "[output][and_text][input[index]]"
//Returns list element or null. Should prevent "index out of bounds" error. //Returns list element or null. Should prevent "index out of bounds" error.
proc/listgetindex(var/list/list,index) proc/listgetindex(var/list/list,index)

View File

@@ -162,3 +162,24 @@
/proc/key_name_admin(var/whom, var/include_name = 1) /proc/key_name_admin(var/whom, var/include_name = 1)
return key_name(whom, 1, include_name) return key_name(whom, 1, include_name)
// Helper procs for building detailed log lines
/datum/proc/log_info_line()
return "[src] ([type])"
/atom/log_info_line()
var/turf/t = get_turf(src)
if(istype(t))
return "([t]) ([t.x],[t.y],[t.z]) ([t.type])"
else if(loc)
return "([loc]) (0,0,0) ([loc.type])"
else
return "(NULL) (0,0,0) (NULL)"
/mob/log_info_line()
return "[..()] ([ckey])"
/proc/log_info_line(var/datum/d)
if(!istype(d))
return
return d.log_info_line()

View File

@@ -4,17 +4,56 @@
#define MINUTE *600 #define MINUTE *600
#define MINUTES *600 #define MINUTES *600
var/roundstart_hour = 0 #define HOUR *36000
//Returns the world time in english #define HOURS *36000
proc/worldtime2text(time = world.time, timeshift = 1)
if(!roundstart_hour) roundstart_hour = pick(2,7,12,17)
return timeshift ? time2text(time+(36000*roundstart_hour), "hh:mm") : time2text(time, "hh:mm")
proc/worlddate2text() #define DAY *864000
return num2text((text2num(time2text(world.timeofday, "YYYY"))+544)) + "-" + time2text(world.timeofday, "MM-DD") #define DAYS *864000
proc/time_stamp() #define TimeOfGame (get_game_time())
return time2text(world.timeofday, "hh:mm:ss") #define TimeOfTick (world.tick_usage*0.01*world.tick_lag)
/proc/get_game_time()
var/global/time_offset = 0
var/global/last_time = 0
var/global/last_usage = 0
var/wtime = world.time
var/wusage = world.tick_usage * 0.01
if(last_time < wtime && last_usage > 1)
time_offset += last_usage - 1
last_time = wtime
last_usage = wusage
return wtime + (time_offset + wusage) * world.tick_lag
var/roundstart_hour
var/station_date = ""
var/next_station_date_change = 1 DAY
#define duration2stationtime(time) time2text(station_time_in_ticks + time, "hh:mm")
#define worldtime2stationtime(time) time2text(roundstart_hour HOURS + time, "hh:mm")
#define round_duration_in_ticks (round_start_time ? world.time - round_start_time : 0)
#define station_time_in_ticks (roundstart_hour HOURS + round_duration_in_ticks)
/proc/stationtime2text()
return time2text(station_time_in_ticks, "hh:mm")
/proc/stationdate2text()
var/update_time = FALSE
if(station_time_in_ticks > next_station_date_change)
next_station_date_change += 1 DAY
update_time = TRUE
if(!station_date || update_time)
var/extra_days = round(station_time_in_ticks / (1 DAY)) DAYS
var/timeofday = world.timeofday + extra_days
station_date = num2text((text2num(time2text(timeofday, "YYYY"))+544)) + "-" + time2text(timeofday, "MM-DD")
return station_date
/proc/time_stamp()
return time2text(station_time_in_ticks, "hh:mm:ss")
/* Returns 1 if it is the selected month and day */ /* Returns 1 if it is the selected month and day */
proc/isDay(var/month, var/day) proc/isDay(var/month, var/day)
@@ -36,9 +75,7 @@ var/round_start_time = 0
round_start_time = world.time round_start_time = world.time
return 1 return 1
#define round_duration_in_ticks (round_start_time ? world.time - round_start_time : 0) /proc/roundduration2text()
/proc/round_duration_as_text()
if(!round_start_time) if(!round_start_time)
return "00:00" return "00:00"
if(last_round_duration && world.time < next_duration_update) if(last_round_duration && world.time < next_duration_update)
@@ -55,3 +92,12 @@ var/round_start_time = 0
last_round_duration = "[hours]:[mins]" last_round_duration = "[hours]:[mins]"
next_duration_update = world.time + 1 MINUTES next_duration_update = world.time + 1 MINUTES
return last_round_duration return last_round_duration
//Can be useful for things dependent on process timing
/proc/process_schedule_interval(var/process_name)
var/datum/controller/process/process = processScheduler.getProcess(process_name)
return process.schedule_interval
/hook/startup/proc/set_roundstart_hour()
roundstart_hour = pick(2,7,12,17)
return 1

View File

@@ -73,8 +73,8 @@
var/obj/screen/spell/S = spell_objects[i] var/obj/screen/spell/S = spell_objects[i]
var/xpos = x_position + (x_position < 8 ? 1 : -1)*(i%7) var/xpos = x_position + (x_position < 8 ? 1 : -1)*(i%7)
var/ypos = y_position + (y_position < 8 ? round(i/7) : -round(i/7)) var/ypos = y_position + (y_position < 8 ? round(i/7) : -round(i/7))
S.screen_loc = "[encode_screen_X(xpos)]:[x_pix],[encode_screen_Y(ypos)]:[y_pix]"
if(spell_holder && spell_holder.client) if(spell_holder && spell_holder.client)
S.screen_loc = "[encode_screen_X(xpos)]:[x_pix],[encode_screen_Y(ypos)]:[y_pix]"
spell_holder.client.screen += S spell_holder.client.screen += S
S.handle_icon_updates = 1 S.handle_icon_updates = 1

View File

@@ -1,19 +0,0 @@
/**
* _stubs.dm
*
* This file contains constructs that the process scheduler expects to exist
* in a standard ss13 fork.
*/
/**
* logTheThing
*
* In goonstation, this proc writes a message to either the world log or diary.
*
* Blame Keelin.
*/
/proc/logTheThing(type, source, target, text, diaryType)
if(diaryType)
log_debug("Diary: \[[diaryType]:[type]] [text]")
else
log_debug("Log: \[[type]] [text]")

View File

@@ -69,10 +69,10 @@
* recordkeeping vars * recordkeeping vars
*/ */
// Records the time (1/10s timeofday) at which the process last finished sleeping // Records the time (1/10s timeoftick) at which the process last finished sleeping
var/tmp/last_slept = 0 var/tmp/last_slept = 0
// Records the time (1/10s timeofday) at which the process last began running // Records the time (1/10s timeofgame) at which the process last began running
var/tmp/run_start = 0 var/tmp/run_start = 0
// Records the number of times this process has been killed and restarted // Records the number of times this process has been killed and restarted
@@ -106,12 +106,8 @@
last_object = null last_object = null
/datum/controller/process/proc/started() /datum/controller/process/proc/started()
var/timeofhour = TimeOfHour
// Initialize last_slept so we can know when to sleep
last_slept = timeofhour
// Initialize run_start so we can detect hung processes. // Initialize run_start so we can detect hung processes.
run_start = timeofhour run_start = TimeOfGame
// Initialize defer count // Initialize defer count
cpu_defer_count = 0 cpu_defer_count = 0
@@ -163,18 +159,13 @@
setStatus(PROCESS_STATUS_HUNG) setStatus(PROCESS_STATUS_HUNG)
/datum/controller/process/proc/handleHung() /datum/controller/process/proc/handleHung()
var/timeofhour = TimeOfHour
var/datum/lastObj = last_object var/datum/lastObj = last_object
var/lastObjType = "null" var/lastObjType = "null"
if(istype(lastObj)) if(istype(lastObj))
lastObjType = lastObj.type lastObjType = lastObj.type
// If timeofhour has rolled over, then we need to adjust. var/msg = "[name] process hung at tick #[ticks]. Process was unresponsive for [(TimeOfGame - run_start) / 10] seconds and was restarted. Last task: [last_task]. Last Object Type: [lastObjType]"
if (timeofhour < run_start) log_debug(msg)
run_start -= 36000
var/msg = "[name] process hung at tick #[ticks]. Process was unresponsive for [(timeofhour - run_start) / 10] seconds and was restarted. Last task: [last_task]. Last Object Type: [lastObjType]"
logTheThing("debug", null, null, msg)
logTheThing("diary", null, null, msg, "debug")
message_admins(msg) message_admins(msg)
main.restartProcess(src.name) main.restartProcess(src.name)
@@ -182,8 +173,8 @@
/datum/controller/process/proc/kill() /datum/controller/process/proc/kill()
if (!killed) if (!killed)
var/msg = "[name] process was killed at tick #[ticks]." var/msg = "[name] process was killed at tick #[ticks]."
logTheThing("debug", null, null, msg) log_debug(msg)
logTheThing("diary", null, null, msg, "debug") message_admins(msg)
//finished() //finished()
// Allow inheritors to clean up if needed // Allow inheritors to clean up if needed
@@ -208,17 +199,12 @@
if (main.getCurrentTickElapsedTime() > main.timeAllowance) if (main.getCurrentTickElapsedTime() > main.timeAllowance)
sleep(world.tick_lag) sleep(world.tick_lag)
cpu_defer_count++ cpu_defer_count++
last_slept = TimeOfHour last_slept = 0
else else
var/timeofhour = TimeOfHour if (TimeOfTick > last_slept + sleep_interval)
// If timeofhour has rolled over, then we need to adjust.
if (timeofhour < last_slept)
last_slept -= 36000
if (timeofhour > last_slept + sleep_interval)
// If we haven't slept in sleep_interval deciseconds, sleep to allow other work to proceed. // If we haven't slept in sleep_interval deciseconds, sleep to allow other work to proceed.
sleep(0) sleep(0)
last_slept = TimeOfHour last_slept = TimeOfTick
/datum/controller/process/proc/update() /datum/controller/process/proc/update()
// Clear delta // Clear delta
@@ -239,10 +225,7 @@
/datum/controller/process/proc/getElapsedTime() /datum/controller/process/proc/getElapsedTime()
var/timeofhour = TimeOfHour return TimeOfGame - run_start
if (timeofhour < run_start)
return timeofhour - (run_start - 36000)
return timeofhour - run_start
/datum/controller/process/proc/tickDetail() /datum/controller/process/proc/tickDetail()
return return
@@ -343,6 +326,9 @@
stat("[name]", "T#[getTicks()] | AR [averageRunTime] | LR [lastRunTime] | HR [highestRunTime] | D [cpu_defer_count]") stat("[name]", "T#[getTicks()] | AR [averageRunTime] | LR [lastRunTime] | HR [highestRunTime] | D [cpu_defer_count]")
/datum/controller/process/proc/catchException(var/exception/e, var/thrower) /datum/controller/process/proc/catchException(var/exception/e, var/thrower)
if(istype(e)) // Real runtimes go to the real error handler
log_runtime(e, thrower, "Caught by process: [name]")
return
var/etext = "[e]" var/etext = "[e]"
var/eid = "[e]" // Exception ID, for tracking repeated exceptions var/eid = "[e]" // Exception ID, for tracking repeated exceptions
var/ptext = "" // "processing..." text, for what was being processed (if known) var/ptext = "" // "processing..." text, for what was being processed (if known)

View File

@@ -43,8 +43,6 @@ var/global/datum/controller/processScheduler/processScheduler
var/tmp/currentTick = 0 var/tmp/currentTick = 0
var/tmp/currentTickStart = 0
var/tmp/timeAllowance = 0 var/tmp/timeAllowance = 0
var/tmp/cpuAverage = 0 var/tmp/cpuAverage = 0
@@ -247,7 +245,7 @@ var/global/datum/controller/processScheduler/processScheduler
/datum/controller/processScheduler/proc/recordStart(var/datum/controller/process/process, var/time = null) /datum/controller/processScheduler/proc/recordStart(var/datum/controller/process/process, var/time = null)
if (isnull(time)) if (isnull(time))
time = TimeOfHour time = TimeOfGame
last_queued[process] = world.time last_queued[process] = world.time
last_start[process] = time last_start[process] = time
else else
@@ -256,11 +254,7 @@ var/global/datum/controller/processScheduler/processScheduler
/datum/controller/processScheduler/proc/recordEnd(var/datum/controller/process/process, var/time = null) /datum/controller/processScheduler/proc/recordEnd(var/datum/controller/process/process, var/time = null)
if (isnull(time)) if (isnull(time))
time = TimeOfHour time = TimeOfGame
// If world.timeofday has rolled over, then we need to adjust.
if (time < last_start[process])
last_start[process] -= 36000
var/lastRunTime = time - last_start[process] var/lastRunTime = time - last_start[process]
@@ -349,29 +343,23 @@ var/global/datum/controller/processScheduler/processScheduler
updateCurrentTickData() updateCurrentTickData()
return 0 return 0
else else
return TimeOfHour - currentTickStart return TimeOfTick
/datum/controller/processScheduler/proc/updateCurrentTickData() /datum/controller/processScheduler/proc/updateCurrentTickData()
if (world.time > currentTick) if (world.time > currentTick)
// New tick! // New tick!
currentTick = world.time currentTick = world.time
currentTickStart = TimeOfHour
updateTimeAllowance() updateTimeAllowance()
cpuAverage = (world.cpu + cpuAverage + cpuAverage) / 3 cpuAverage = (world.cpu + cpuAverage + cpuAverage) / 3
/datum/controller/processScheduler/proc/updateTimeAllowance() /datum/controller/processScheduler/proc/updateTimeAllowance()
// Time allowance goes down linearly with world.cpu. // Time allowance goes down linearly with world.cpu.
var/tmp/error = cpuAverage - 100 var/tmp/error = cpuAverage - 100
var/tmp/timeAllowanceDelta = sign(error) * -0.5 * world.tick_lag * max(0, 0.001 * abs(error)) var/tmp/timeAllowanceDelta = SIMPLE_SIGN(error) * -0.5 * world.tick_lag * max(0, 0.001 * abs(error))
//timeAllowance = world.tick_lag * min(1, 0.5 * ((200/max(1,cpuAverage)) - 1)) //timeAllowance = world.tick_lag * min(1, 0.5 * ((200/max(1,cpuAverage)) - 1))
timeAllowance = min(timeAllowanceMax, max(0, timeAllowance + timeAllowanceDelta)) timeAllowance = min(timeAllowanceMax, max(0, timeAllowance + timeAllowanceDelta))
/datum/controller/processScheduler/proc/sign(var/x)
if (x == 0)
return 1
return x / abs(x)
/datum/controller/processScheduler/proc/statProcesses() /datum/controller/processScheduler/proc/statProcesses()
if(!isRunning) if(!isRunning)
stat("Processes", "Scheduler not running") stat("Processes", "Scheduler not running")
@@ -380,3 +368,6 @@ var/global/datum/controller/processScheduler/processScheduler
stat(null, "[round(cpuAverage, 0.1)] CPU, [round(timeAllowance, 0.1)/10] TA") stat(null, "[round(cpuAverage, 0.1)] CPU, [round(timeAllowance, 0.1)/10] TA")
for(var/datum/controller/process/p in processes) for(var/datum/controller/process/p in processes)
p.statProcess() p.statProcess()
/datum/controller/processScheduler/proc/getProcess(var/process_name)
return nameToProcessMap[process_name]

View File

@@ -1,56 +0,0 @@
(function ($) {
function setRef(theRef) {
ref = theRef;
}
function jax(action, data) {
if (typeof data === 'undefined')
data = {};
var params = [];
for (var k in data) {
if (data.hasOwnProperty(k)) {
params.push(encodeURIComponent(k) + '=' + encodeURIComponent(data[k]));
}
}
var newLoc = '?src=' + ref + ';action=' + action + ';' + params.join(';');
window.location = newLoc;
}
function requestRefresh(e) {
jax("refresh", null);
}
function handleRefresh(processTable) {
$('#processTable').html(processTable);
initProcessTableButtons();
}
function requestKill(e) {
var button = $(e.currentTarget);
jax("kill", {name: button.data("process-name")});
}
function requestEnable(e) {
var button = $(e.currentTarget);
jax("enable", {name: button.data("process-name")});
}
function requestDisable(e) {
var button = $(e.currentTarget);
jax("disable", {name: button.data("process-name")});
}
function initProcessTableButtons() {
$(".kill-btn").on("click", requestKill);
$(".enable-btn").on("click", requestEnable);
$(".disable-btn").on("click", requestDisable);
}
window.setRef = setRef;
window.handleRefresh = handleRefresh;
$(function() {
initProcessTableButtons();
$('#btn-refresh').on("click", requestRefresh);
});
}(jQuery));

View File

@@ -120,7 +120,7 @@ var/global/list/round_voters = list() // Keeps track of the individuals voting f
if(choices[current_votes[key]] == .) if(choices[current_votes[key]] == .)
round_voters += key // Keep track of who voted for the winning round. round_voters += key // Keep track of who voted for the winning round.
if(mode != VOTE_GAMEMODE || . == "Extended" || ticker.hide_mode == 0) // Announce Extended gamemode, but not other gamemodes if(mode != VOTE_GAMEMODE || . == "Extended" || ticker.hide_mode == 0) // Announce Extended gamemode, but not other gamemodes
text += "<b>Vote Result: [.]</b>" text += "<b>Vote Result: [mode == VOTE_GAMEMODE ? gamemode_names[.] : .]</b>"
else else
text += "<b>The vote has ended.</b>" text += "<b>The vote has ended.</b>"

View File

@@ -361,7 +361,7 @@
clothes_s = new /icon('icons/mob/uniform.dmi', "virologywhite_s") clothes_s = new /icon('icons/mob/uniform.dmi', "virologywhite_s")
clothes_s.Blend(new /icon('icons/mob/feet.dmi', "white"), ICON_UNDERLAY) clothes_s.Blend(new /icon('icons/mob/feet.dmi', "white"), ICON_UNDERLAY)
clothes_s.Blend(new /icon('icons/mob/suit.dmi', "labcoat_vir_open"), ICON_OVERLAY) clothes_s.Blend(new /icon('icons/mob/suit.dmi', "labcoat_vir_open"), ICON_OVERLAY)
if("Captain") if("Station Administrator")
clothes_s = new /icon('icons/mob/uniform.dmi', "captain_s") clothes_s = new /icon('icons/mob/uniform.dmi', "captain_s")
clothes_s.Blend(new /icon('icons/mob/feet.dmi', "brown"), ICON_UNDERLAY) clothes_s.Blend(new /icon('icons/mob/feet.dmi', "brown"), ICON_UNDERLAY)
if("Head of Security") if("Head of Security")

View File

@@ -1,3 +1,5 @@
//TODO: Make this match current lore
//S'randarr //S'randarr
/datum/locations/s_randarr /datum/locations/s_randarr

View File

@@ -8,6 +8,11 @@
icon_state = "undershirt" icon_state = "undershirt"
has_color = TRUE has_color = TRUE
/datum/category_item/underwear/undershirt/shirt_long
name = "Longsleeve Shirt"
icon_state = "undershirt_long"
has_color = TRUE
/datum/category_item/underwear/undershirt/tank_top /datum/category_item/underwear/undershirt/tank_top
name = "Tank top" name = "Tank top"
icon_state = "tanktop" icon_state = "tanktop"

View File

@@ -9,27 +9,34 @@
*************/ *************/
/datum/category_group/underwear /datum/category_group/underwear
var/sort_order // Lower sort order is applied as icons first var/sort_order // Lower sort order is applied as icons first
var/display_name // For displaying in text
var/gender = NEUTER
datum/category_group/underwear/dd_SortValue() datum/category_group/underwear/dd_SortValue()
return sort_order return sort_order
/datum/category_group/underwear/top /datum/category_group/underwear/top
name = "Underwear, top" name = "Underwear, top"
display_name = "top piece"
sort_order = 1 sort_order = 1
category_item_type = /datum/category_item/underwear/top category_item_type = /datum/category_item/underwear/top
/datum/category_group/underwear/bottom /datum/category_group/underwear/bottom
name = "Underwear, bottom" name = "Underwear, bottom"
display_name = "bottom piece"
sort_order = 2 sort_order = 2
category_item_type = /datum/category_item/underwear/bottom category_item_type = /datum/category_item/underwear/bottom
/datum/category_group/underwear/socks /datum/category_group/underwear/socks
name = "Socks" name = "Socks"
display_name = "socks"
gender = PLURAL
sort_order = 3 sort_order = 3
category_item_type = /datum/category_item/underwear/socks category_item_type = /datum/category_item/underwear/socks
/datum/category_group/underwear/undershirt /datum/category_group/underwear/undershirt
name = "Undershirt" name = "Undershirt"
display_name = "undershirt"
sort_order = 4 // Undershirts currently have the highest sort order because they may cover both underwear and socks. sort_order = 4 // Undershirts currently have the highest sort order because they may cover both underwear and socks.
category_item_type = /datum/category_item/underwear/undershirt category_item_type = /datum/category_item/underwear/undershirt

View File

@@ -61,17 +61,17 @@
/datum/uplink_item/item/badassery/surplus/merc2 /datum/uplink_item/item/badassery/surplus/merc2
name = "Surplus Crate - 240 TC" name = "Surplus Crate - 240 TC"
item_cost = DEFAULT_TELECRYSTAL_AMOUNT * 2 item_cost = DEFAULT_TELECRYSTAL_AMOUNT * 2
item_worth = 360 item_worth = 540
/datum/uplink_item/item/badassery/surplus/merc4 /datum/uplink_item/item/badassery/surplus/merc4
name = "Surplus Crate - 480 TC" name = "Surplus Crate - 480 TC"
item_cost = DEFAULT_TELECRYSTAL_AMOUNT * 4 item_cost = DEFAULT_TELECRYSTAL_AMOUNT * 4
item_worth = 720 item_worth = 1200
/datum/uplink_item/item/badassery/surplus/merc6 /datum/uplink_item/item/badassery/surplus/merc6
name = "Surplus Crate - 720 TC" name = "Surplus Crate - 720 TC"
item_cost = DEFAULT_TELECRYSTAL_AMOUNT * 6 item_cost = DEFAULT_TELECRYSTAL_AMOUNT * 6
item_worth = 1440 item_worth = 1980
/datum/uplink_item/item/badassery/surplus/New() /datum/uplink_item/item/badassery/surplus/New()
..() ..()

View File

@@ -31,10 +31,10 @@
/datum/uplink_item/item/stealth_items/voice /datum/uplink_item/item/stealth_items/voice
name = "Voice Changer" name = "Voice Changer"
item_cost = 30 item_cost = 15
path = /obj/item/clothing/mask/gas/voice path = /obj/item/clothing/mask/gas/voice
/datum/uplink_item/item/stealth_items/camera_floppy /datum/uplink_item/item/stealth_items/camera_floppy
name = "Camera Network Access - Floppy" name = "Camera Network Access - Floppy"
item_cost = 30 item_cost = 15
path = /obj/item/weapon/disk/file/cameras/syndicate path = /obj/item/weapon/disk/file/cameras/syndicate

View File

@@ -26,10 +26,10 @@
/datum/uplink_item/item/stealthy_weapons/cigarette_kit /datum/uplink_item/item/stealthy_weapons/cigarette_kit
name = "Cigarette Kit" name = "Cigarette Kit"
item_cost = 15 item_cost = 10
path = /obj/item/weapon/storage/box/syndie_kit/cigarette path = /obj/item/weapon/storage/box/syndie_kit/cigarette
/datum/uplink_item/item/stealthy_weapons/random_toxin /datum/uplink_item/item/stealthy_weapons/random_toxin
name = "Random Toxin - Beaker" name = "Random Toxin - Beaker"
item_cost = 15 item_cost = 10
path = /obj/item/weapon/storage/box/syndie_kit/toxin path = /obj/item/weapon/storage/box/syndie_kit/toxin

View File

@@ -14,16 +14,78 @@
item_cost = 10 item_cost = 10
path = /obj/item/weapon/storage/toolbox/syndicate path = /obj/item/weapon/storage/toolbox/syndicate
/datum/uplink_item/item/tools/clerical
name = "Morphic Clerical Kit"
item_cost = 10
path = /obj/item/weapon/storage/box/syndie_kit/clerical
/datum/uplink_item/item/tools/encryptionkey_radio
name = "Encrypted Radio Channel Key"
item_cost = 10
path = /obj/item/device/encryptionkey/syndicate
/datum/uplink_item/item/tools/money
name = "Operations Funding"
item_cost = 10
path = /obj/item/weapon/storage/secure/briefcase/money
desc = "A briefcase with 10,000 untraceable thalers for funding your sneaky activities."
/datum/uplink_item/item/tools/plastique /datum/uplink_item/item/tools/plastique
name = "C-4 (Destroys walls)" name = "C-4 (Destroys walls)"
item_cost = 10 item_cost = 10
path = /obj/item/weapon/plastique path = /obj/item/weapon/plastique
/datum/uplink_item/item/tools/duffle
name = "Black Duffle Bag"
item_cost = 10
path = /obj/item/weapon/storage/backpack/dufflebag/syndie
/datum/uplink_item/item/tools/duffle/med
name = "Black Medical Duffle Bag"
path = /obj/item/weapon/storage/backpack/dufflebag/syndie/med
/datum/uplink_item/item/tools/duffle/ammo
name = "Black Ammunition Duffle Bag"
path = /obj/item/weapon/storage/backpack/dufflebag/syndie/ammo
/datum/uplink_item/item/tools/space_suit
name = "Space Suit"
item_cost = 15
path = /obj/item/weapon/storage/box/syndie_kit/space
/datum/uplink_item/item/tools/encryptionkey_binary
name = "Binary Translator Key"
item_cost = 15
path = /obj/item/device/encryptionkey/binary
/datum/uplink_item/item/tools/packagebomb /datum/uplink_item/item/tools/packagebomb
name = "Package Bomb (Small)" name = "Package Bomb (Small)"
item_cost = 20 item_cost = 20
path = /obj/item/weapon/storage/box/syndie_kit/demolitions path = /obj/item/weapon/storage/box/syndie_kit/demolitions
/datum/uplink_item/item/tools/hacking_tool
name = "Door Hacking Tool"
item_cost = 20
path = /obj/item/device/multitool/hacktool
desc = "Appears and functions as a standard multitool until the mode is toggled by applying a screwdriver appropriately. \
When in hacking mode this device will grant full access to any standard airlock within 20 to 40 seconds. \
This device will also be able to immediately access the last 6 to 8 hacked airlocks."
/datum/uplink_item/item/tools/emag
name = "Cryptographic Sequencer"
item_cost = 30
path = /obj/item/weapon/card/emag
/datum/uplink_item/item/tools/thermal
name = "Thermal Imaging Glasses"
item_cost = 30
path = /obj/item/clothing/glasses/thermal/syndi
/datum/uplink_item/item/tools/powersink
name = "Powersink (DANGER!)"
item_cost = 40
path = /obj/item/device/powersink
/datum/uplink_item/item/tools/packagebomb/large /datum/uplink_item/item/tools/packagebomb/large
name = "Package Bomb (Large)" name = "Package Bomb (Large)"
item_cost = 40 item_cost = 40
@@ -36,55 +98,6 @@
path = /obj/item/weapon/storage/box/syndie_kit/demolitions_super_heavy path = /obj/item/weapon/storage/box/syndie_kit/demolitions_super_heavy
*/ */
/datum/uplink_item/item/tools/encryptionkey_radio
name = "Encrypted Radio Channel Key"
item_cost = 20
path = /obj/item/device/encryptionkey/syndicate
/datum/uplink_item/item/tools/hacking_tool
name = "Door Hacking Tool"
item_cost = 20
path = /obj/item/device/multitool/hacktool
desc = "Appears and functions as a standard multitool until the mode is toggled by applying a screwdriver appropriately. \
When in hacking mode this device will grant full access to any standard airlock within 20 to 40 seconds. \
This device will also be able to immediately access the last 6 to 8 hacked airlocks."
/datum/uplink_item/item/tools/encryptionkey_binary
name = "Binary Translator Key"
item_cost = 20
path = /obj/item/device/encryptionkey/binary
/datum/uplink_item/item/tools/emag
name = "Cryptographic Sequencer"
item_cost = 30
path = /obj/item/weapon/card/emag
/datum/uplink_item/item/tools/clerical
name = "Morphic Clerical Kit"
item_cost = 15
path = /obj/item/weapon/storage/box/syndie_kit/clerical
/datum/uplink_item/item/tools/money
name = "Operations Funding"
item_cost = 15
path = /obj/item/weapon/storage/secure/briefcase/money
desc = "A briefcase with 10,000 untraceable thalers for funding your sneaky activities."
/datum/uplink_item/item/tools/space_suit
name = "Space Suit"
item_cost = 15
path = /obj/item/weapon/storage/box/syndie_kit/space
/datum/uplink_item/item/tools/thermal
name = "Thermal Imaging Glasses"
item_cost = 30
path = /obj/item/clothing/glasses/thermal/syndi
/datum/uplink_item/item/tools/powersink
name = "Powersink (DANGER!)"
item_cost = 50
path = /obj/item/device/powersink
/datum/uplink_item/item/tools/ai_module /datum/uplink_item/item/tools/ai_module
name = "Hacked AI Upload Module" name = "Hacked AI Upload Module"
item_cost = 60 item_cost = 60

View File

@@ -11,7 +11,7 @@
/datum/uplink_item/item/visible_weapons/combatknife /datum/uplink_item/item/visible_weapons/combatknife
name = "Combat Knife" name = "Combat Knife"
item_cost = 30 item_cost = 20
path = /obj/item/weapon/material/hatchet/tacknife/combatknife path = /obj/item/weapon/material/hatchet/tacknife/combatknife
/datum/uplink_item/item/visible_weapons/energy_sword /datum/uplink_item/item/visible_weapons/energy_sword

View File

@@ -11,7 +11,7 @@ var/const/AALARM_WIRE_AALARM = 16
/datum/wires/alarm/CanUse(var/mob/living/L) /datum/wires/alarm/CanUse(var/mob/living/L)
var/obj/machinery/alarm/A = holder var/obj/machinery/alarm/A = holder
if(A.wiresexposed) if(A.panel_open)
return 1 return 1
return 0 return 0

View File

@@ -87,7 +87,7 @@ var/global/list/PDA_Manifest = list()
heads[++heads.len] = list("name" = name, "rank" = rank, "active" = isactive) heads[++heads.len] = list("name" = name, "rank" = rank, "active" = isactive)
department = 1 department = 1
depthead = 1 depthead = 1
if(rank=="Captain" && heads.len != 1) if(rank=="Station Administrator" && heads.len != 1)
heads.Swap(1,heads.len) heads.Swap(1,heads.len)
if(real_rank in security_positions) if(real_rank in security_positions)

View File

@@ -50,7 +50,7 @@
var/flags = 0 // Various runtime options. var/flags = 0 // Various runtime options.
// Used for setting appearance. // Used for setting appearance.
var/list/valid_species = list("Unathi","Tajara","Skrell","Human") var/list/valid_species = list("Unathi","Tajara","Skrell","Human","Diona","Teshari")
// Runtime vars. // Runtime vars.
var/datum/mind/leader // Current leader, if any. var/datum/mind/leader // Current leader, if any.

View File

@@ -14,7 +14,8 @@
if(!preserve_appearance && (flags & ANTAG_SET_APPEARANCE)) if(!preserve_appearance && (flags & ANTAG_SET_APPEARANCE))
spawn(3) spawn(3)
var/mob/living/carbon/human/H = player.current var/mob/living/carbon/human/H = player.current
if(istype(H)) H.change_appearance(APPEARANCE_ALL, H.loc, H, valid_species, state = z_state) if(istype(H))
H.change_appearance(APPEARANCE_ALL, H.loc, H, species_whitelist = valid_species, state = z_state)
return player.current return player.current
/datum/antagonist/proc/update_access(var/mob/living/player) /datum/antagonist/proc/update_access(var/mob/living/player)

View File

@@ -6,7 +6,7 @@ var/datum/antagonist/mutineer/mutineers
role_text_plural = "Mutineers" role_text_plural = "Mutineers"
id = MODE_MUTINEER id = MODE_MUTINEER
antag_indicator = "mutineer" antag_indicator = "mutineer"
restricted_jobs = list("Captain") restricted_jobs = list("Station Administrator")
/datum/antagonist/mutineer/New(var/no_reference) /datum/antagonist/mutineer/New(var/no_reference)
..() ..()
@@ -39,7 +39,7 @@ var/datum/antagonist/mutineer/mutineers
proc/get_head_loyalist_candidates() proc/get_head_loyalist_candidates()
var/list/candidates[0] var/list/candidates[0]
for(var/mob/loyalist in player_list) for(var/mob/loyalist in player_list)
if(loyalist.mind && loyalist.mind.assigned_role == "Captain") if(loyalist.mind && loyalist.mind.assigned_role == "Station Administrator")
candidates.Add(loyalist.mind) candidates.Add(loyalist.mind)
return candidates return candidates
@@ -47,7 +47,7 @@ var/datum/antagonist/mutineer/mutineers
var/list/candidates[0] var/list/candidates[0]
for(var/mob/mutineer in player_list) for(var/mob/mutineer in player_list)
if(mutineer.client.prefs.be_special & BE_MUTINEER) if(mutineer.client.prefs.be_special & BE_MUTINEER)
for(var/job in command_positions - "Captain") for(var/job in command_positions - "Station Administrator")
if(mutineer.mind && mutineer.mind.assigned_role == job) if(mutineer.mind && mutineer.mind.assigned_role == job)
candidates.Add(mutineer.mind) candidates.Add(mutineer.mind)
return candidates return candidates

View File

@@ -13,7 +13,7 @@ var/datum/antagonist/ert/ert
and before taking extreme actions, please try to also contact the administration! \ and before taking extreme actions, please try to also contact the administration! \
Think through your actions and make the roleplay immersive! <b>Please remember all \ Think through your actions and make the roleplay immersive! <b>Please remember all \
rules aside from those without explicit exceptions apply to the ERT.</b>" rules aside from those without explicit exceptions apply to the ERT.</b>"
leader_welcome_text = "As leader of the Emergency Response Team, you answer only to the Company, and have authority to override the Captain where it is necessary to achieve your mission goals. It is recommended that you attempt to cooperate with the captain where possible, however." leader_welcome_text = "As leader of the Emergency Response Team, you answer only to the Company, and have authority to override the Station Administrator where it is necessary to achieve your mission goals. It is recommended that you attempt to cooperate with the Station Administrator where possible, however."
landmark_id = "Response Team" landmark_id = "Response Team"
id_type = /obj/item/weapon/card/id/centcom/ERT id_type = /obj/item/weapon/card/id/centcom/ERT

View File

@@ -60,7 +60,7 @@ var/datum/antagonist/raider/raiders
/obj/item/clothing/suit/storage/toggle/hoodie, /obj/item/clothing/suit/storage/toggle/hoodie,
/obj/item/clothing/suit/storage/toggle/hoodie/black, /obj/item/clothing/suit/storage/toggle/hoodie/black,
/obj/item/clothing/suit/unathi/mantle, /obj/item/clothing/suit/unathi/mantle,
/obj/item/clothing/suit/poncho, /obj/item/clothing/accessory/poncho,
) )
var/list/raider_guns = list( var/list/raider_guns = list(

View File

@@ -6,7 +6,7 @@
bantype = "changeling" bantype = "changeling"
feedback_tag = "changeling_objective" feedback_tag = "changeling_objective"
restricted_jobs = list("AI", "Cyborg") restricted_jobs = list("AI", "Cyborg")
protected_jobs = list("Security Officer", "Warden", "Detective", "Head of Security", "Captain") protected_jobs = list("Security Officer", "Warden", "Detective", "Head of Security", "Station Administrator")
welcome_text = "Use say \"#g message\" to communicate with your fellow changelings. Remember: you get all of their absorbed DNA if you absorb them." welcome_text = "Use say \"#g message\" to communicate with your fellow changelings. Remember: you get all of their absorbed DNA if you absorb them."
flags = ANTAG_SUSPICIOUS | ANTAG_RANDSPAWN | ANTAG_VOTABLE flags = ANTAG_SUSPICIOUS | ANTAG_RANDSPAWN | ANTAG_VOTABLE
antaghud_indicator = "hudchangeling" antaghud_indicator = "hudchangeling"

View File

@@ -11,7 +11,7 @@ var/datum/antagonist/cultist/cult
role_text = "Cultist" role_text = "Cultist"
role_text_plural = "Cultists" role_text_plural = "Cultists"
bantype = "cultist" bantype = "cultist"
restricted_jobs = list("Chaplain","AI", "Cyborg", "Internal Affairs Agent", "Head of Security", "Captain") restricted_jobs = list("Chaplain","AI", "Cyborg", "Internal Affairs Agent", "Head of Security", "Station Administrator")
protected_jobs = list("Security Officer", "Warden", "Detective") protected_jobs = list("Security Officer", "Warden", "Detective")
role_type = BE_CULTIST role_type = BE_CULTIST
feedback_tag = "cult_objective" feedback_tag = "cult_objective"

View File

@@ -29,7 +29,7 @@ var/datum/antagonist/revolutionary/revs
faction_indicator = "rev" faction_indicator = "rev"
faction_invisible = 1 faction_invisible = 1
restricted_jobs = list("Internal Affairs Agent", "AI", "Cyborg","Captain", "Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer") restricted_jobs = list("Internal Affairs Agent", "AI", "Cyborg", "Station Administrator", "Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer")
protected_jobs = list("Security Officer", "Warden", "Detective") protected_jobs = list("Security Officer", "Warden", "Detective")
/datum/antagonist/revolutionary/New() /datum/antagonist/revolutionary/New()

View File

@@ -3,7 +3,7 @@ var/datum/antagonist/traitor/traitors
// Inherits most of its vars from the base datum. // Inherits most of its vars from the base datum.
/datum/antagonist/traitor /datum/antagonist/traitor
id = MODE_TRAITOR id = MODE_TRAITOR
protected_jobs = list("Security Officer", "Warden", "Detective", "Internal Affairs Agent", "Head of Security", "Captain") protected_jobs = list("Security Officer", "Warden", "Detective", "Internal Affairs Agent", "Head of Security", "Station Administrator")
flags = ANTAG_SUSPICIOUS | ANTAG_RANDSPAWN | ANTAG_VOTABLE flags = ANTAG_SUSPICIOUS | ANTAG_RANDSPAWN | ANTAG_VOTABLE
/datum/antagonist/traitor/auto /datum/antagonist/traitor/auto

View File

@@ -1137,7 +1137,7 @@ area/space/atmosalert()
sound_env = MEDIUM_SOFTFLOOR sound_env = MEDIUM_SOFTFLOOR
/area/crew_quarters/captain /area/crew_quarters/captain
name = "\improper Command - Captain's Office" name = "\improper Command - Station Administrator's Office"
icon_state = "captain" icon_state = "captain"
sound_env = MEDIUM_SOFTFLOOR sound_env = MEDIUM_SOFTFLOOR

View File

@@ -12,7 +12,7 @@
certain though... there is never just one of them. Good luck." certain though... there is never just one of them. Good luck."
config_tag = "changeling" config_tag = "changeling"
required_players = 2 required_players = 2
required_players_secret = 5 required_players_secret = 3
required_enemies = 1 required_enemies = 1
end_on_antag_death = 0 end_on_antag_death = 0
antag_scaling_coeff = 10 antag_scaling_coeff = 10

View File

@@ -2,7 +2,7 @@
name = "Organic Space Suit" name = "Organic Space Suit"
desc = "We grow an organic suit to protect ourselves from space exposure." desc = "We grow an organic suit to protect ourselves from space exposure."
helptext = "To remove the suit, use the ability again." helptext = "To remove the suit, use the ability again."
ability_icon_state = "ling_space_suit" ability_icon_state = "lingspacesuit"
genomecost = 1 genomecost = 1
verbpath = /mob/proc/changeling_spacesuit verbpath = /mob/proc/changeling_spacesuit
@@ -17,7 +17,7 @@
name = "Chitinous Spacearmor" name = "Chitinous Spacearmor"
desc = "We turn our skin into tough chitin to protect us from damage and space exposure." desc = "We turn our skin into tough chitin to protect us from damage and space exposure."
helptext = "To remove the armor, use the ability again." helptext = "To remove the armor, use the ability again."
ability_icon_state = "ling_armor" ability_icon_state = "lingarmor"
genomecost = 3 genomecost = 3
verbpath = /mob/proc/changeling_spacearmor verbpath = /mob/proc/changeling_spacearmor
@@ -34,7 +34,6 @@
/obj/item/clothing/suit/space/changeling /obj/item/clothing/suit/space/changeling
name = "flesh mass" name = "flesh mass"
icon_state = "lingspacesuit" icon_state = "lingspacesuit"
item_state = "lingspacehelmet"
desc = "A huge, bulky mass of pressure and temperature-resistant organic tissue, evolved to facilitate space travel." desc = "A huge, bulky mass of pressure and temperature-resistant organic tissue, evolved to facilitate space travel."
flags = STOPPRESSUREDAMAGE //Not THICKMATERIAL because it's organic tissue, so if somebody tries to inject something into it, flags = STOPPRESSUREDAMAGE //Not THICKMATERIAL because it's organic tissue, so if somebody tries to inject something into it,
//it still ends up in your blood. (also balance but muh fluff) //it still ends up in your blood. (also balance but muh fluff)
@@ -55,7 +54,6 @@
/obj/item/clothing/head/helmet/space/changeling /obj/item/clothing/head/helmet/space/changeling
name = "flesh mass" name = "flesh mass"
icon_state = "lingspacehelmet" icon_state = "lingspacehelmet"
item_state = "lingspacehelmet"
desc = "A covering of pressure and temperature-resistant organic tissue with a glass-like chitin front." desc = "A covering of pressure and temperature-resistant organic tissue with a glass-like chitin front."
flags = BLOCKHAIR | STOPPRESSUREDAMAGE //Again, no THICKMATERIAL. flags = BLOCKHAIR | STOPPRESSUREDAMAGE //Again, no THICKMATERIAL.
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0) armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0)

View File

@@ -33,6 +33,7 @@
C.adjustCloneLoss(-healing_amount) C.adjustCloneLoss(-healing_amount)
C.adjustBrainLoss(-healing_amount) C.adjustBrainLoss(-healing_amount)
C.restore_blood() C.restore_blood()
C.species.create_organs(C)
C.restore_all_organs() C.restore_all_organs()
C.blinded = 0 C.blinded = 0
C.eye_blind = 0 C.eye_blind = 0

View File

@@ -27,16 +27,19 @@
C.radiation = 0 C.radiation = 0
C.heal_overall_damage(C.getBruteLoss(), C.getFireLoss()) C.heal_overall_damage(C.getBruteLoss(), C.getFireLoss())
C.reagents.clear_reagents() C.reagents.clear_reagents()
C.restore_all_organs(ignore_prosthetic_prefs=1) //Covers things like fractures and other things not covered by the above.
if(ishuman(C)) if(ishuman(C))
var/mob/living/carbon/human/H = src var/mob/living/carbon/human/H = src
H.species.create_organs(H)
H.restore_all_organs(ignore_prosthetic_prefs=1) //Covers things like fractures and other things not covered by the above.
H.restore_blood() H.restore_blood()
H.mutations.Remove(HUSK) H.mutations.Remove(HUSK)
H.status_flags -= DISFIGURED H.status_flags -= DISFIGURED
H.update_body(1) H.update_body(1)
for(var/limb in H.organs_by_name) for(var/limb in H.organs_by_name)
var/obj/item/organ/external/current_limb = H.organs_by_name[limb] var/obj/item/organ/external/current_limb = H.organs_by_name[limb]
current_limb.undislocate() if(current_limb)
current_limb.undislocate()
current_limb.open = 0
C.halloss = 0 C.halloss = 0
C.shock_stage = 0 //Pain C.shock_stage = 0 //Pain

View File

@@ -2,15 +2,30 @@
name = "Self Respiration" name = "Self Respiration"
desc = "We evolve our body to no longer require drawing oxygen from the atmosphere." desc = "We evolve our body to no longer require drawing oxygen from the atmosphere."
helptext = "We will no longer require internals, and we cannot inhale any gas, including harmful ones." helptext = "We will no longer require internals, and we cannot inhale any gas, including harmful ones."
ability_icon_state = "ling_toggle_breath"
genomecost = 0 genomecost = 0
isVerb = 0
verbpath = /mob/proc/changeling_self_respiration verbpath = /mob/proc/changeling_self_respiration
//No breathing required //No breathing required
/mob/proc/changeling_self_respiration() /mob/proc/changeling_self_respiration()
set category = "Changeling"
set name = "Toggle Breathing"
set desc = "We choose whether or not to breathe."
var/datum/changeling/changeling = changeling_power(0,0,100,UNCONSCIOUS)
if(!changeling)
return 0
if(istype(src,/mob/living/carbon)) if(istype(src,/mob/living/carbon))
var/mob/living/carbon/C = src var/mob/living/carbon/C = src
C.does_not_breathe = 1 if(C.suiciding)
src << "<span class='notice'>We stop breathing, as we no longer need to.</span>" src << "You're committing suicide, this isn't going to work."
return 1 return 0
if(C.does_not_breathe == 0)
C.does_not_breathe = 1
src << "<span class='notice'>We stop breathing, as we no longer need to.</span>"
return 1
else
C.does_not_breathe = 0
src << "<span class='notice'>We resume breathing, as we now need to again.</span>"
return 0 return 0

View File

@@ -4,7 +4,7 @@
extended_round_description = "The station has been infiltrated by a fanatical group of death-cultists! They will use powers from beyond your comprehension to subvert you to their cause and ultimately please their gods through sacrificial summons and physical immolation! Try to survive!" extended_round_description = "The station has been infiltrated by a fanatical group of death-cultists! They will use powers from beyond your comprehension to subvert you to their cause and ultimately please their gods through sacrificial summons and physical immolation! Try to survive!"
config_tag = "cult" config_tag = "cult"
required_players = 5 required_players = 5
required_players_secret = 10 required_players_secret = 5
required_enemies = 3 required_enemies = 3
end_on_antag_death = 0 end_on_antag_death = 0
antag_tags = list(MODE_CULTIST) antag_tags = list(MODE_CULTIST)

View File

@@ -301,9 +301,9 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is
M.add_ion_law("HUMANS NEED TO EAT [what2pref] [what2] TO SURVIVE") M.add_ion_law("HUMANS NEED TO EAT [what2pref] [what2] TO SURVIVE")
if(5) if(5)
M << "<br>" M << "<br>"
M << "<span class='danger'>THE CAPTAIN, HOP AND HOS ARE [who2]...LAWS UPDATED</span>" M << "<span class='danger'>THE STATION ADMINISTRATOR, HOP AND HOS ARE [who2]...LAWS UPDATED</span>"
M << "<br>" M << "<br>"
M.add_ion_law("THE CAPTAIN, HOP AND HOS ARE [who2]") M.add_ion_law("THE STATION ADMINISTRATOR, HOP AND HOS ARE [who2]")
if(6) if(6)
M << "<br>" M << "<br>"
M << "<span class='danger'>THE STATION IS BUILT FOR [who2]...LAWS UPDATED</span>" M << "<span class='danger'>THE STATION IS BUILT FOR [who2]...LAWS UPDATED</span>"

View File

@@ -34,9 +34,6 @@ var/global/list/Holiday = list() //Holidays are lists now, so we can have more t
switch(DD) switch(DD)
if(1) if(1)
Holiday["New Years's Day"] = "The day of the new solar year on Sol." Holiday["New Years's Day"] = "The day of the new solar year on Sol."
if(10)
Holiday["Messa's Day"] = "A Tajaran holiday. It takes place on the shortest day of the year on \
Ahdomai, and is named after Messa, the Tajaran deity of Change."
if(12) if(12)
Holiday["Vertalliq-Qerr"] = "Vertalliq-Qerr, translated to mean 'Festival of the Royals', is a \ Holiday["Vertalliq-Qerr"] = "Vertalliq-Qerr, translated to mean 'Festival of the Royals', is a \
Skrell holiday that celebrates the Qerr-Katish and all they have provided for the rest of Skrell society, \ Skrell holiday that celebrates the Qerr-Katish and all they have provided for the rest of Skrell society, \
@@ -79,9 +76,6 @@ var/global/list/Holiday = list() //Holidays are lists now, so we can have more t
Holiday["April Fool's Day"] = "An old holiday that endevours one to pull pranks and spread hoaxes on their friends." Holiday["April Fool's Day"] = "An old holiday that endevours one to pull pranks and spread hoaxes on their friends."
if(YY == 18) if(YY == 18)
Holiday["Easter"] = "" Holiday["Easter"] = ""
if(7)
Holiday["Tajaran Independence Day"] = "A Tajaran holiday celebrating their independence by winning the \
war against the Slavemasters, the former ruling elite that went known as 'The Overseers'."
if(8) if(8)
if(YY == 15) if(YY == 15)
Holiday["Easter"] = "" Holiday["Easter"] = ""
@@ -123,9 +117,11 @@ var/global/list/Holiday = list() //Holidays are lists now, so we can have more t
if(8) //Aug if(8) //Aug
switch(DD) switch(DD)
if(10) // if(10)
Holiday["S'randarr's Day"] = "A Tajaran holiday that occurs on the longest day of the year in summer, \ // Holiday["S'randarr's Day"] = "A Tajaran holiday that occurs on the longest day of the year in summer, \
on Ahdomai. It is named after the Tajaran deity of Light, and huge celebrations are common." // on Ahdomai. It is named after the Tajaran deity of Light, and huge celebrations are common."
if(27)
Holiday["Forgiveness Day"] = "A time to forgive and be forgiven."
if(9) //Sep if(9) //Sep
switch(DD) switch(DD)

View File

@@ -288,7 +288,7 @@ var/global/datum/controller/gameticker/ticker
var/captainless=1 var/captainless=1
for(var/mob/living/carbon/human/player in player_list) for(var/mob/living/carbon/human/player in player_list)
if(player && player.mind && player.mind.assigned_role) if(player && player.mind && player.mind.assigned_role)
if(player.mind.assigned_role == "Captain") if(player.mind.assigned_role == "Station Administrator")
captainless=0 captainless=0
if(!player_is_antag(player.mind, only_offstation_roles = 1)) if(!player_is_antag(player.mind, only_offstation_roles = 1))
job_master.EquipRank(player, player.mind.assigned_role, 0) job_master.EquipRank(player, player.mind.assigned_role, 0)
@@ -297,7 +297,7 @@ var/global/datum/controller/gameticker/ticker
if(captainless) if(captainless)
for(var/mob/M in player_list) for(var/mob/M in player_list)
if(!istype(M,/mob/new_player)) if(!istype(M,/mob/new_player))
M << "Captainship not forced on anyone." M << "Station Administratorship not forced on anyone."
proc/process() proc/process()

View File

@@ -4,7 +4,7 @@
extended_round_description = "The AI will attempt to hack the APCs around the station in order to gain as much control as possible." extended_round_description = "The AI will attempt to hack the APCs around the station in order to gain as much control as possible."
config_tag = "malfunction" config_tag = "malfunction"
required_players = 2 required_players = 2
required_players_secret = 7 required_players_secret = 2
required_enemies = 1 required_enemies = 1
end_on_antag_death = 0 end_on_antag_death = 0
auto_recall_shuttle = 0 auto_recall_shuttle = 0

View File

@@ -10,7 +10,7 @@
only hope this unknown assassin isn't here for you." only hope this unknown assassin isn't here for you."
config_tag = "ninja" config_tag = "ninja"
required_players = 1 required_players = 1
required_players_secret = 6 required_players_secret = 3
required_enemies = 1 required_enemies = 1
end_on_antag_death = 0 end_on_antag_death = 0
antag_tags = list(MODE_NINJA) antag_tags = list(MODE_NINJA)

View File

@@ -13,7 +13,7 @@ var/list/nuke_disks = list()
attempts of robbery, fraud and other malicious actions." attempts of robbery, fraud and other malicious actions."
config_tag = "mercenary" config_tag = "mercenary"
required_players = 15 required_players = 15
required_players_secret = 20 // 20 players - 5 players to be the nuke ops = 15 players remaining required_players_secret = 15
required_enemies = 1 required_enemies = 1
end_on_antag_death = 0 end_on_antag_death = 0
var/nuke_off_station = 0 //Used for tracking if the syndies actually haul the nuke to the station var/nuke_off_station = 0 //Used for tracking if the syndies actually haul the nuke to the station

View File

@@ -8,6 +8,5 @@
required_enemies = 3 required_enemies = 3
auto_recall_shuttle = 0 //un-wanted on polaris auto_recall_shuttle = 0 //un-wanted on polaris
end_on_antag_death = 0 end_on_antag_death = 0
shuttle_delay = 3
antag_tags = list(MODE_REVOLUTIONARY, MODE_LOYALIST) antag_tags = list(MODE_REVOLUTIONARY, MODE_LOYALIST)
require_all_templates = 1 require_all_templates = 1

View File

@@ -1,8 +1,13 @@
#define ALL_SPELLS "All"
#define OFFENSIVE_SPELLS "Offensive"
#define DEFENSIVE_SPELLS "Defensive"
#define UTILITY_SPELLS "Utility"
#define SUPPORT_SPELLS "Support"
var/list/all_technomancer_spells = typesof(/datum/technomancer/spell) - /datum/technomancer/spell var/list/all_technomancer_spells = typesof(/datum/technomancer/spell) - /datum/technomancer/spell
var/list/all_technomancer_equipment = typesof(/datum/technomancer/equipment) - /datum/technomancer/equipment var/list/all_technomancer_equipment = typesof(/datum/technomancer/equipment) - /datum/technomancer/equipment
var/list/all_technomancer_consumables = typesof(/datum/technomancer/consumable) - /datum/technomancer/consumable var/list/all_technomancer_consumables = typesof(/datum/technomancer/consumable) - /datum/technomancer/consumable
var/list/all_technomancer_assistance = typesof(/datum/technomancer/assistance) - /datum/technomancer/assistance var/list/all_technomancer_assistance = typesof(/datum/technomancer/assistance) - /datum/technomancer/assistance
var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datum/technomancer/presets
/datum/technomancer /datum/technomancer
var/name = "technomancer thing" var/name = "technomancer thing"
@@ -13,6 +18,9 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
var/obj_path = null var/obj_path = null
var/ability_icon_state = null var/ability_icon_state = null
/datum/technomancer/spell
var/category = ALL_SPELLS
/obj/item/weapon/technomancer_catalog /obj/item/weapon/technomancer_catalog
name = "catalog" name = "catalog"
desc = "A \"book\" featuring a holographic display, metal cover, and miniaturized teleportation device, allowing the user to \ desc = "A \"book\" featuring a holographic display, metal cover, and miniaturized teleportation device, allowing the user to \
@@ -27,8 +35,8 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
var/list/equipment_instances = list() var/list/equipment_instances = list()
var/list/consumable_instances = list() var/list/consumable_instances = list()
var/list/assistance_instances = list() var/list/assistance_instances = list()
var/list/preset_instances = list()
var/tab = 0 var/tab = 0
var/spell_tab = ALL_SPELLS
var/show_scepter_text = 0 var/show_scepter_text = 0
/obj/item/weapon/technomancer_catalog/apprentice /obj/item/weapon/technomancer_catalog/apprentice
@@ -72,15 +80,23 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
if(!assistance_instances.len) if(!assistance_instances.len)
for(var/A in all_technomancer_assistance) for(var/A in all_technomancer_assistance)
assistance_instances += new A() assistance_instances += new A()
if(!preset_instances.len)
for(var/P in all_technomancer_presets)
preset_instances += new P()
/obj/item/weapon/technomancer_catalog/apprentice/set_up() /obj/item/weapon/technomancer_catalog/apprentice/set_up()
..() ..()
for(var/datum/technomancer/assistance/apprentice/A in assistance_instances) for(var/datum/technomancer/assistance/apprentice/A in assistance_instances)
assistance_instances.Remove(A) assistance_instances.Remove(A)
// Proc: show_categories()
// Parameters: 1 (category - the category link to display)
// Description: Shows an href link to go to a spell subcategory if the category is not already selected, otherwise is bold, to reduce
// code duplicating.
/obj/item/weapon/technomancer_catalog/proc/show_categories(var/category)
if(category)
if(spell_tab != category)
return "<a href='byond://?src=\ref[src];spell_category=[category]'>[category]</a>"
else
return "<b>[category]</b>"
// Proc: attack_self() // Proc: attack_self()
// Parameters: 1 (user - the mob clicking on the catelog) // Parameters: 1 (user - the mob clicking on the catelog)
// Description: Shows an HTML window, to buy equipment and spells, if the user is the legitimate owner. Otherwise it cannot be used. // Description: Shows an HTML window, to buy equipment and spells, if the user is the legitimate owner. Otherwise it cannot be used.
@@ -100,13 +116,17 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
dat += "<align='center'><b>Functions</b> | " dat += "<align='center'><b>Functions</b> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a></align><br>"
dat += "<a href='byond://?src=\ref[src];tab_choice=4'>Presets</a></align><br>"
dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>" dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>"
dat += "<a href='byond://?src=\ref[src];refund_functions=1'>Refund Functions</a><br><br>" dat += "<a href='byond://?src=\ref[src];refund_functions=1'>Refund Functions</a><br><br>"
for(var/datum/technomancer/spell in spell_instances)
dat += "[show_categories(ALL_SPELLS)] | [show_categories(OFFENSIVE_SPELLS)] | [show_categories(DEFENSIVE_SPELLS)] | \
[show_categories(UTILITY_SPELLS)] | [show_categories(SUPPORT_SPELLS)]<br>"
for(var/datum/technomancer/spell/spell in spell_instances)
if(spell.hidden) if(spell.hidden)
continue continue
if(spell_tab != ALL_SPELLS && spell.category != spell_tab)
continue
dat += "<b>[spell.name]</b><br>" dat += "<b>[spell.name]</b><br>"
dat += "<i>[spell.desc]</i><br>" dat += "<i>[spell.desc]</i><br>"
if(show_scepter_text) if(show_scepter_text)
@@ -123,8 +143,7 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | " dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | "
dat += "<b>Equipment</b> | " dat += "<b>Equipment</b> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a></align><br>"
dat += "<a href='byond://?src=\ref[src];tab_choice=4'>Presets</a></align><br>"
dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>" dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>"
for(var/datum/technomancer/equipment/E in equipment_instances) for(var/datum/technomancer/equipment/E in equipment_instances)
dat += "<b>[E.name]</b><br>" dat += "<b>[E.name]</b><br>"
@@ -141,8 +160,7 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | " dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | "
dat += "<b>Consumables</b> | " dat += "<b>Consumables</b> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a></align><br>"
dat += "<a href='byond://?src=\ref[src];tab_choice=4'>Presets</a></align><br>"
dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>" dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>"
for(var/datum/technomancer/consumable/C in consumable_instances) for(var/datum/technomancer/consumable/C in consumable_instances)
dat += "<b>[C.name]</b><br>" dat += "<b>[C.name]</b><br>"
@@ -159,8 +177,7 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | " dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | " dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | "
dat += "<b>Assistance</b> | " dat += "<b>Assistance</b></align><br>"
dat += "<a href='byond://?src=\ref[src];tab_choice=4'>Presets</a></align><br>"
dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>" dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>"
for(var/datum/technomancer/assistance/A in assistance_instances) for(var/datum/technomancer/assistance/A in assistance_instances)
dat += "<b>[A.name]</b><br>" dat += "<b>[A.name]</b><br>"
@@ -171,24 +188,6 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
dat += "<font color='red'><b>Cannot afford!</b></font><br><br>" dat += "<font color='red'><b>Cannot afford!</b></font><br><br>"
user << browse(dat, "window=radio") user << browse(dat, "window=radio")
onclose(user, "radio") onclose(user, "radio")
if(4) //Presets
var/dat = ""
user.set_machine(src)
dat += "<align='center'><a href='byond://?src=\ref[src];tab_choice=0'>Functions</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=1'>Equipment</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=2'>Consumables</a> | "
dat += "<a href='byond://?src=\ref[src];tab_choice=3'>Assistance</a> | "
dat += "<b>Presets</b></align><br>"
dat += "You currently have a budget of <b>[budget]/[max_budget]</b>.<br><br>"
for(var/datum/technomancer/presets/P in preset_instances)
dat += "<b>[P.name]</b><br>"
dat += "<i>[P.desc]</i><br>"
if(P.cost <= budget)
dat += "<a href='byond://?src=\ref[src];spell_choice=[P.name]'>Purchase</a> ([P.cost])<br><br>"
else
dat += "<font color='red'><b>Cannot afford!</b></font><br><br>"
user << browse(dat, "window=radio")
onclose(user, "radio")
// Proc: Topic() // Proc: Topic()
// Parameters: 2 (href - don't know, href_list - the choice that the person using the interface above clicked on.) // Parameters: 2 (href - don't know, href_list - the choice that the person using the interface above clicked on.)
@@ -210,6 +209,8 @@ var/list/all_technomancer_presets = typesof(/datum/technomancer/presets) - /datu
H.set_machine(src) H.set_machine(src)
if(href_list["tab_choice"]) if(href_list["tab_choice"])
tab = text2num(href_list["tab_choice"]) tab = text2num(href_list["tab_choice"])
if(href_list["spell_category"])
spell_tab = href_list["spell_category"]
if(href_list["spell_choice"]) if(href_list["spell_choice"])
var/datum/technomancer/new_spell = null var/datum/technomancer/new_spell = null
//Locate the spell. //Locate the spell.

View File

@@ -82,8 +82,7 @@
/obj/item/weapon/storage/belt/holding /obj/item/weapon/storage/belt/holding
name = "Belt of Holding" name = "Belt of Holding"
desc = "Can hold more than you'd expect." desc = "Can hold more than you'd expect."
icon_state = "emsbelt" icon_state = "ems"
item_state = "emsbelt"
max_w_class = 3 // Can hold normal sized items. max_w_class = 3 // Can hold normal sized items.
storage_slots = 14 // Twice the capacity of a typical belt. storage_slots = 14 // Twice the capacity of a typical belt.
max_storage_space = 42 max_storage_space = 42

View File

@@ -212,4 +212,4 @@
outgoing_instability = outgoing_instability * armor_factor outgoing_instability = outgoing_instability * armor_factor
H.adjust_instability(outgoing_instability) H.adjust_instability(outgoing_instability)
set_light(distance, distance, l_color = "#C26DDE") set_light(distance, distance * 2, l_color = "#C26DDE")

View File

@@ -4,6 +4,7 @@
far away from the caster. Failing that, it may inhibit those entities in some form." far away from the caster. Failing that, it may inhibit those entities in some form."
cost = 40 cost = 40
obj_path = /obj/item/weapon/spell/abjuration obj_path = /obj/item/weapon/spell/abjuration
category = UTILITY_SPELLS
/obj/item/weapon/spell/abjuration /obj/item/weapon/spell/abjuration
name = "abjuration" name = "abjuration"

View File

@@ -4,6 +4,7 @@
will grab them automatically." will grab them automatically."
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/apportation obj_path = /obj/item/weapon/spell/apportation
category = UTILITY_SPELLS
/obj/item/weapon/spell/apportation /obj/item/weapon/spell/apportation
name = "apportation" name = "apportation"

View File

@@ -6,6 +6,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/audible_deception obj_path = /obj/item/weapon/spell/audible_deception
ability_icon_state = "tech_audibledeception" ability_icon_state = "tech_audibledeception"
category = UTILITY_SPELLS
/obj/item/weapon/spell/audible_deception /obj/item/weapon/spell/audible_deception
name = "audible deception" name = "audible deception"

View File

@@ -4,6 +4,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/aura/biomed obj_path = /obj/item/weapon/spell/aura/biomed
ability_icon_state = "tech_biomedaura" ability_icon_state = "tech_biomedaura"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/aura/biomed /obj/item/weapon/spell/aura/biomed
name = "restoration aura" name = "restoration aura"

View File

@@ -7,6 +7,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/aura/fire obj_path = /obj/item/weapon/spell/aura/fire
ability_icon_state = "tech_fireaura" ability_icon_state = "tech_fireaura"
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/aura/fire /obj/item/weapon/spell/aura/fire
name = "Fire Storm" name = "Fire Storm"
@@ -20,7 +21,6 @@
qdel(src) qdel(src)
var/list/nearby_things = range(4,owner) var/list/nearby_things = range(4,owner)
var/fire_prob = 10
var/temp_change = 25 var/temp_change = 25
var/temp_cap = 500 var/temp_cap = 500
var/fire_power = 2 var/fire_power = 2
@@ -28,7 +28,6 @@
if(check_for_scepter()) if(check_for_scepter())
temp_change = 50 temp_change = 50
temp_cap = 700 temp_cap = 700
fire_prob = 25
fire_power = 4 fire_power = 4
for(var/mob/living/carbon/human/H in nearby_things) for(var/mob/living/carbon/human/H in nearby_things)
if(is_ally(H)) if(is_ally(H))
@@ -41,16 +40,11 @@
turf_check: turf_check:
for(var/turf/simulated/T in nearby_things) for(var/turf/simulated/T in nearby_things)
if(prob(fire_prob)) if(prob(30))
for(var/mob/living/carbon/human/H in T) for(var/mob/living/carbon/human/H in T)
if(is_ally(H)) if(is_ally(H))
continue turf_check continue turf_check
T.hotspot_expose(1000, 50, 1) T.hotspot_expose(1000, 50, 1)
T.create_fire(fire_power) T.create_fire(fire_power)
// //We use hotspot_expose() to allow firesuits to protect from this aura.
// var/turf/location = get_turf(H)
// location.hotspot_expose(1000, 50, 1)
owner.adjust_instability(1) owner.adjust_instability(1)

View File

@@ -6,6 +6,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/aura/frost obj_path = /obj/item/weapon/spell/aura/frost
ability_icon_state = "tech_frostaura" ability_icon_state = "tech_frostaura"
category = DEFENSIVE_SPELLS // Scepter-less frost aura is nonlethal.
/obj/item/weapon/spell/aura/frost /obj/item/weapon/spell/aura/frost
name = "chilling aura" name = "chilling aura"
@@ -35,8 +36,4 @@
var/cold_factor = abs(protection - 1) var/cold_factor = abs(protection - 1)
H.bodytemperature = max( (H.bodytemperature - temp_change) * cold_factor, temp_cap) H.bodytemperature = max( (H.bodytemperature - temp_change) * cold_factor, temp_cap)
// //We use hotspot_expose() to allow firesuits to protect from this aura.
// var/turf/location = get_turf(H)
// location.hotspot_expose(1, 50, 1)
owner.adjust_instability(1) owner.adjust_instability(1)

View File

@@ -4,6 +4,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/aura/shock obj_path = /obj/item/weapon/spell/aura/shock
ability_icon_state = "tech_shockaura" ability_icon_state = "tech_shockaura"
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/aura/shock /obj/item/weapon/spell/aura/shock
name = "electric aura" name = "electric aura"

View File

@@ -5,6 +5,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/aura/unstable obj_path = /obj/item/weapon/spell/aura/unstable
ability_icon_state = "tech_unstableaura" ability_icon_state = "tech_unstableaura"
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/aura/unstable /obj/item/weapon/spell/aura/unstable
name = "degen aura" name = "degen aura"

View File

@@ -5,6 +5,7 @@
enhancement_desc = "Blink distance is increased greatly." enhancement_desc = "Blink distance is increased greatly."
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/blink obj_path = /obj/item/weapon/spell/blink
category = UTILITY_SPELLS
/obj/item/weapon/spell/blink /obj/item/weapon/spell/blink
name = "blink" name = "blink"

View File

@@ -4,6 +4,7 @@
useful to trick someone into believing you're casting a different spell, or perhaps just for fun." useful to trick someone into believing you're casting a different spell, or perhaps just for fun."
cost = 25 cost = 25
obj_path = /obj/item/weapon/spell/chroma obj_path = /obj/item/weapon/spell/chroma
category = UTILITY_SPELLS
/obj/item/weapon/spell/chroma /obj/item/weapon/spell/chroma
name = "chroma" name = "chroma"

View File

@@ -5,6 +5,7 @@
ability_icon_state = "tech_condensation" ability_icon_state = "tech_condensation"
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/condensation obj_path = /obj/item/weapon/spell/condensation
category = UTILITY_SPELLS
/obj/item/weapon/spell/condensation /obj/item/weapon/spell/condensation
name = "condensation" name = "condensation"

View File

@@ -7,6 +7,7 @@
around the entity is merely a hologram used to allow the user to know if the creature is safe or not." around the entity is merely a hologram used to allow the user to know if the creature is safe or not."
cost = 200 cost = 200
obj_path = /obj/item/weapon/spell/control obj_path = /obj/item/weapon/spell/control
category = UTILITY_SPELLS
/mob/living/carbon/human/proc/technomancer_control() /mob/living/carbon/human/proc/technomancer_control()
place_spell_in_hand(/obj/item/weapon/spell/control) place_spell_in_hand(/obj/item/weapon/spell/control)

View File

@@ -6,6 +6,7 @@
cost = 25 cost = 25
obj_path = /obj/item/weapon/spell/dispel obj_path = /obj/item/weapon/spell/dispel
ability_icon_state = "tech_dispel" ability_icon_state = "tech_dispel"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/dispel /obj/item/weapon/spell/dispel
name = "dispel" name = "dispel"

View File

@@ -7,6 +7,7 @@
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/energy_siphon obj_path = /obj/item/weapon/spell/energy_siphon
ability_icon_state = "tech_energysiphon" ability_icon_state = "tech_energysiphon"
category = UTILITY_SPELLS
/obj/item/weapon/spell/energy_siphon /obj/item/weapon/spell/energy_siphon
name = "energy siphon" name = "energy siphon"

View File

@@ -4,6 +4,7 @@
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/flame_tongue obj_path = /obj/item/weapon/spell/flame_tongue
ability_icon_state = "tech_flametongue" ability_icon_state = "tech_flametongue"
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/flame_tongue /obj/item/weapon/spell/flame_tongue
name = "flame tongue" name = "flame tongue"

View File

@@ -4,6 +4,7 @@
ability_icon_state = "tech_gambit" ability_icon_state = "tech_gambit"
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/gambit obj_path = /obj/item/weapon/spell/gambit
category = UTILITY_SPELLS
/var/global/list/all_technomancer_gambit_spells = typesof(/obj/item/weapon/spell) - list( /var/global/list/all_technomancer_gambit_spells = typesof(/obj/item/weapon/spell) - list(
/obj/item/weapon/spell, /obj/item/weapon/spell,

View File

@@ -5,6 +5,7 @@
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/illusion obj_path = /obj/item/weapon/spell/illusion
ability_icon_state = "tech_illusion" ability_icon_state = "tech_illusion"
category = UTILITY_SPELLS
/obj/item/weapon/spell/illusion /obj/item/weapon/spell/illusion
name = "illusion" name = "illusion"

View File

@@ -5,6 +5,7 @@
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/insert/corona obj_path = /obj/item/weapon/spell/insert/corona
ability_icon_state = "tech_corona" ability_icon_state = "tech_corona"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/corona /obj/item/weapon/spell/insert/corona
name = "corona" name = "corona"

View File

@@ -1,10 +1,11 @@
/datum/technomancer/spell/haste /datum/technomancer/spell/haste
name = "Haste" name = "Haste"
desc = "Allows the target to run at speeds that should not be possible for an ordinary being. For three seconds, the target \ desc = "Allows the target to run at speeds that should not be possible for an ordinary being. For five seconds, the target \
runs extremly fast, and cannot be slowed by any means." runs extremly fast, and cannot be slowed by any means."
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/insert/haste obj_path = /obj/item/weapon/spell/insert/haste
ability_icon_state = "tech_haste" ability_icon_state = "tech_haste"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/haste /obj/item/weapon/spell/insert/haste
name = "haste" name = "haste"
@@ -22,7 +23,7 @@
L.force_max_speed = 1 L.force_max_speed = 1
L << "<span class='notice'>You suddenly find it much easier to move.</span>" L << "<span class='notice'>You suddenly find it much easier to move.</span>"
L.adjust_instability(10) L.adjust_instability(10)
spawn(3 SECONDS) spawn(5 SECONDS)
if(src) if(src)
on_expire() on_expire()

View File

@@ -5,6 +5,7 @@
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/insert/mend_burns obj_path = /obj/item/weapon/spell/insert/mend_burns
ability_icon_state = "tech_mendburns" ability_icon_state = "tech_mendburns"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/mend_burns /obj/item/weapon/spell/insert/mend_burns
name = "mend burns" name = "mend burns"
@@ -19,10 +20,10 @@
spawn(1) spawn(1)
if(ishuman(host)) if(ishuman(host))
var/mob/living/carbon/human/H = host var/mob/living/carbon/human/H = host
for(var/i = 0, i<25,i++) for(var/i = 0, i<5,i++)
if(H) if(H)
H.adjustFireLoss(-1) H.adjustFireLoss(-5)
H.adjust_instability(0.5) H.adjust_instability(2.5)
origin.adjust_instability(0.5) origin.adjust_instability(2.5)
sleep(10) sleep(10)
on_expire() on_expire()

View File

@@ -4,6 +4,7 @@
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/insert/mend_metal obj_path = /obj/item/weapon/spell/insert/mend_metal
ability_icon_state = "tech_mendwounds" ability_icon_state = "tech_mendwounds"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/mend_metal /obj/item/weapon/spell/insert/mend_metal
name = "mend metal" name = "mend metal"
@@ -18,14 +19,14 @@
spawn(1) spawn(1)
if(ishuman(host)) if(ishuman(host))
var/mob/living/carbon/human/H = host var/mob/living/carbon/human/H = host
for(var/i = 0, i<25,i++) for(var/i = 0, i<5,i++)
if(H) if(H)
for(var/obj/item/organ/external/O in H.organs) for(var/obj/item/organ/external/O in H.organs)
if(O.robotic < ORGAN_ROBOT) // Robot parts only. if(O.robotic < ORGAN_ROBOT) // Robot parts only.
continue continue
O.heal_damage(1, 0, internal = 1, robo_repair = 1) O.heal_damage(5, 0, internal = 1, robo_repair = 1)
H.adjust_instability(0.5) H.adjust_instability(2.5)
origin.adjust_instability(0.5) origin.adjust_instability(2.5)
sleep(10) sleep(1 SECOND)
on_expire() on_expire()

View File

@@ -5,6 +5,7 @@
cost = 75 cost = 75
obj_path = /obj/item/weapon/spell/insert/mend_organs obj_path = /obj/item/weapon/spell/insert/mend_organs
ability_icon_state = "tech_mendwounds" ability_icon_state = "tech_mendwounds"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/mend_organs /obj/item/weapon/spell/insert/mend_organs
name = "mend organs" name = "mend organs"
@@ -19,13 +20,13 @@
spawn(1) spawn(1)
if(ishuman(host)) if(ishuman(host))
var/mob/living/carbon/human/H = host var/mob/living/carbon/human/H = host
for(var/i = 0, i<25,i++) for(var/i = 0, i<5,i++)
if(H) if(H)
for(var/obj/item/organ/O in H.internal_organs) for(var/obj/item/organ/O in H.internal_organs)
if(O.damage > 0) if(O.damage > 0)
O.damage = max(O.damage - 0.2, 0) O.damage = max(O.damage - 1, 0)
H.adjust_instability(0.5) H.adjust_instability(2.5)
origin.adjust_instability(0.5) origin.adjust_instability(2.5)
sleep(10) sleep(1 SECOND)
on_expire() on_expire()

View File

@@ -5,6 +5,7 @@
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/insert/mend_wires obj_path = /obj/item/weapon/spell/insert/mend_wires
ability_icon_state = "tech_mendwounds" ability_icon_state = "tech_mendwounds"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/mend_wires /obj/item/weapon/spell/insert/mend_wires
name = "mend wires" name = "mend wires"
@@ -19,14 +20,14 @@
spawn(1) spawn(1)
if(ishuman(host)) if(ishuman(host))
var/mob/living/carbon/human/H = host var/mob/living/carbon/human/H = host
for(var/i = 0, i<25,i++) for(var/i = 0, i<5,i++)
if(H) if(H)
for(var/obj/item/organ/external/O in H.organs) for(var/obj/item/organ/external/O in H.organs)
if(O.robotic < ORGAN_ROBOT) // Robot parts only. if(O.robotic < ORGAN_ROBOT) // Robot parts only.
continue continue
O.heal_damage(0, 1, internal = 1, robo_repair = 1) O.heal_damage(0, 5, internal = 1, robo_repair = 1)
H.adjust_instability(0.5) H.adjust_instability(2.5)
origin.adjust_instability(0.5) origin.adjust_instability(2.5)
sleep(10) sleep(10)
on_expire() on_expire()

View File

@@ -5,6 +5,7 @@
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/insert/mend_wounds obj_path = /obj/item/weapon/spell/insert/mend_wounds
ability_icon_state = "tech_mendwounds" ability_icon_state = "tech_mendwounds"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/mend_wounds /obj/item/weapon/spell/insert/mend_wounds
name = "mend wounds" name = "mend wounds"
@@ -19,10 +20,10 @@
spawn(1) spawn(1)
if(ishuman(host)) if(ishuman(host))
var/mob/living/carbon/human/H = host var/mob/living/carbon/human/H = host
for(var/i = 0, i<25,i++) for(var/i = 0, i<5,i++)
if(H) if(H)
H.adjustBruteLoss(-1) H.adjustBruteLoss(-5)
H.adjust_instability(0.5) H.adjust_instability(2.5)
origin.adjust_instability(0.5) origin.adjust_instability(2.5)
sleep(10) sleep(1 SECOND)
on_expire() on_expire()

View File

@@ -1,10 +1,11 @@
/datum/technomancer/spell/purify /datum/technomancer/spell/purify
name = "Purify" name = "Purify"
desc = "Clenses the body of harmful impurities, such as toxins, radiation, viruses, and such. \ desc = "Clenses the body of harmful impurities, such as toxins, radiation, viruses, genetic damage, and such. \
Instability is split between the target and technomancer, if seperate." Instability is split between the target and technomancer, if seperate."
cost = 25 cost = 25
obj_path = /obj/item/weapon/spell/insert/purify obj_path = /obj/item/weapon/spell/insert/purify
ability_icon_state = "tech_purify" ability_icon_state = "tech_purify"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/purify /obj/item/weapon/spell/insert/purify
name = "purify" name = "purify"
@@ -23,12 +24,12 @@
H.disabilities = 0 H.disabilities = 0
// for(var/datum/disease/D in H.viruses) // for(var/datum/disease/D in H.viruses)
// D.cure() // D.cure()
for(var/i = 0, i<25,i++) for(var/i = 0, i<5,i++)
if(H) if(H)
H.adjustToxLoss(-1) H.adjustToxLoss(-5)
H.adjustCloneLoss(-1) H.adjustCloneLoss(-5)
H.radiation = max(host.radiation - 2, 0) H.radiation = max(host.radiation - 10, 0)
H.adjust_instability(0.5) H.adjust_instability(2.5)
origin.adjust_instability(0.5) origin.adjust_instability(2.5)
sleep(10) sleep(1 SECOND)
on_expire() on_expire()

View File

@@ -1,10 +1,11 @@
/datum/technomancer/spell/repel_missiles /datum/technomancer/spell/repel_missiles
name = "Repel Missiles" name = "Repel Missiles"
desc = "Places a repulsion field around you, which attempts to deflect incoming bullets and lasers, making them 30% less likely \ desc = "Places a repulsion field around you, which attempts to deflect incoming bullets and lasers, making them 30% less likely \
to hit you. The field lasts for two minutes and can be granted to yourself or an ally." to hit you. The field lasts for five minutes and can be granted to yourself or an ally."
cost = 60 cost = 60
obj_path = /obj/item/weapon/spell/insert/repel_missiles obj_path = /obj/item/weapon/spell/insert/repel_missiles
ability_icon_state = "tech_repelmissiles" ability_icon_state = "tech_repelmissiles"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/insert/repel_missiles /obj/item/weapon/spell/insert/repel_missiles
name = "repel missiles" name = "repel missiles"
@@ -21,7 +22,7 @@
var/mob/living/L = host var/mob/living/L = host
L.evasion += 2 L.evasion += 2
L << "<span class='notice'>You have a repulsion field around you, which will attempt to deflect projectiles.</span>" L << "<span class='notice'>You have a repulsion field around you, which will attempt to deflect projectiles.</span>"
spawn(2 MINUTES) spawn(5 MINUTES)
if(src) if(src)
on_expire() on_expire()

View File

@@ -5,6 +5,7 @@
cost = 120 cost = 120
obj_path = /obj/item/weapon/spell/instability_tap obj_path = /obj/item/weapon/spell/instability_tap
ability_icon_state = "tech_instabilitytap" ability_icon_state = "tech_instabilitytap"
category = UTILITY_SPELLS
/obj/item/weapon/spell/instability_tap /obj/item/weapon/spell/instability_tap
name = "instability tap" name = "instability tap"

View File

@@ -6,6 +6,7 @@
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/mark obj_path = /obj/item/weapon/spell/mark
ability_icon_state = "tech_mark" ability_icon_state = "tech_mark"
category = UTILITY_SPELLS
//The object to teleport to when Recall is used. //The object to teleport to when Recall is used.
/obj/effect/mark_spell /obj/effect/mark_spell
@@ -52,6 +53,7 @@
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/recall obj_path = /obj/item/weapon/spell/recall
ability_icon_state = "tech_recall" ability_icon_state = "tech_recall"
category = UTILITY_SPELLS
/obj/item/weapon/spell/recall /obj/item/weapon/spell/recall
name = "recall" name = "recall"

View File

@@ -5,6 +5,7 @@
cost = 70 cost = 70
obj_path = /obj/item/weapon/spell/oxygenate obj_path = /obj/item/weapon/spell/oxygenate
ability_icon_state = "oxygenate" ability_icon_state = "oxygenate"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/oxygenate /obj/item/weapon/spell/oxygenate
name = "oxygenate" name = "oxygenate"

View File

@@ -6,6 +6,7 @@
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/passwall obj_path = /obj/item/weapon/spell/passwall
ability_icon_state = "tech_passwall" ability_icon_state = "tech_passwall"
category = UTILITY_SPELLS
/obj/item/weapon/spell/passwall /obj/item/weapon/spell/passwall
name = "passwall" name = "passwall"
@@ -21,53 +22,55 @@
if(!allowed_to_teleport()) if(!allowed_to_teleport())
user << "<span class='warning'>You can't teleport here!</span>" user << "<span class='warning'>You can't teleport here!</span>"
return 0 return 0
if(isturf(hit_atom)) // if(isturf(hit_atom))
var/turf/T = hit_atom //Turf we touched.
var/turf/our_turf = get_turf(user) //Where we are. var/turf/T = get_turf(hit_atom) //Turf we touched.
if(!T.density) var/turf/our_turf = get_turf(user) //Where we are.
user << "<span class='warning'>Perhaps you should try using passWALL on a wall.</span>" if(!T.density)
if(!T.check_density())
user << "<span class='warning'>Perhaps you should try using passWALL on a wall, or other solid object.</span>"
return 0 return 0
var/direction = get_dir(our_turf, T) var/direction = get_dir(our_turf, T)
var/total_cost = 0 var/total_cost = 0
var/turf/checked_turf = T //Turf we're currently checking for density in the loop below. var/turf/checked_turf = T //Turf we're currently checking for density in the loop below.
var/turf/found_turf = null //Our destination, if one is found. var/turf/found_turf = null //Our destination, if one is found.
var/i = maximum_distance var/i = maximum_distance
visible_message("<span class='info'>[user] rests a hand on \the [T].</span>") visible_message("<span class='info'>[user] rests a hand on \the [hit_atom].</span>")
busy = 1 busy = 1
var/datum/effect/effect/system/spark_spread/spark_system = PoolOrNew(/datum/effect/effect/system/spark_spread) var/datum/effect/effect/system/spark_spread/spark_system = PoolOrNew(/datum/effect/effect/system/spark_spread)
spark_system.set_up(5, 0, our_turf) spark_system.set_up(5, 0, our_turf)
while(i) while(i)
checked_turf = get_step(checked_turf, direction) //Advance in the given direction checked_turf = get_step(checked_turf, direction) //Advance in the given direction
total_cost += check_for_scepter() ? 400 : 800 //Phasing through matter's expensive, you know. total_cost += check_for_scepter() ? 400 : 800 //Phasing through matter's expensive, you know.
i-- i--
if(!checked_turf.density) //If we found a destination (a non-dense turf), then we can stop. if(!checked_turf.density) //If we found a destination (a non-dense turf), then we can stop.
var/dense_objs_on_turf = 0 var/dense_objs_on_turf = 0
for(var/atom/movable/stuff in checked_turf.contents) //Make sure nothing dense is where we want to go, like an airlock or window. for(var/atom/movable/stuff in checked_turf.contents) //Make sure nothing dense is where we want to go, like an airlock or window.
if(stuff.density) if(stuff.density)
dense_objs_on_turf = 1 dense_objs_on_turf = 1
if(!dense_objs_on_turf) //If we found a non-dense turf with nothing dense on it, then that's our destination. if(!dense_objs_on_turf) //If we found a non-dense turf with nothing dense on it, then that's our destination.
found_turf = checked_turf found_turf = checked_turf
break break
sleep(10) sleep(10)
if(found_turf) if(found_turf)
if(user.loc != our_turf) if(user.loc != our_turf)
user << "<span class='warning'>You need to stand still in order to phase through the wall.</span>" user << "<span class='warning'>You need to stand still in order to phase through \the [hit_atom].</span>"
return 0 return 0
if(pay_energy(total_cost) && !user.incapacitated() ) if(pay_energy(total_cost) && !user.incapacitated() )
visible_message("<span class='warning'>[user] appears to phase through \the [T]!</span>") visible_message("<span class='warning'>[user] appears to phase through \the [hit_atom]!</span>")
user << "<span class='info'>You find a destination on the other side of \the [T], and phase through it.</span>" user << "<span class='info'>You find a destination on the other side of \the [hit_atom], and phase through it.</span>"
spark_system.start() spark_system.start()
user.forceMove(found_turf) user.forceMove(found_turf)
qdel(src) qdel(src)
return 1 return 1
else
user << "<span class='warning'>You don't have enough energy to phase through these walls!</span>"
busy = 0
else else
user << "<span class='info'>You weren't able to find an open space to go to.</span>" user << "<span class='warning'>You don't have enough energy to phase through these walls!</span>"
busy = 0 busy = 0
else
user << "<span class='info'>You weren't able to find an open space to go to.</span>"
busy = 0

View File

@@ -4,6 +4,7 @@
draining your powercell." draining your powercell."
cost = 80 cost = 80
obj_path = /obj/item/weapon/spell/phase_shift obj_path = /obj/item/weapon/spell/phase_shift
category = DEFENSIVE_SPELLS
/obj/item/weapon/spell/phase_shift /obj/item/weapon/spell/phase_shift
name = "phase shift" name = "phase shift"

View File

@@ -4,6 +4,7 @@
cost = 150 cost = 150
ability_icon_state = "tech_beam" ability_icon_state = "tech_beam"
obj_path = /obj/item/weapon/spell/projectile/beam obj_path = /obj/item/weapon/spell/projectile/beam
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/projectile/beam /obj/item/weapon/spell/projectile/beam
name = "beam" name = "beam"
@@ -12,12 +13,13 @@
cast_methods = CAST_RANGED cast_methods = CAST_RANGED
aspect = ASPECT_LIGHT aspect = ASPECT_LIGHT
spell_projectile = /obj/item/projectile/beam/blue spell_projectile = /obj/item/projectile/beam/blue
energy_cost_per_shot = 500 energy_cost_per_shot = 400
instability_per_shot = 3 instability_per_shot = 3
cooldown = 10 cooldown = 10
fire_sound = 'sound/weapons/Laser.ogg'
/obj/item/projectile/beam/blue /obj/item/projectile/beam/blue
damage = 20 damage = 30
muzzle_type = /obj/effect/projectile/laser_blue/muzzle muzzle_type = /obj/effect/projectile/laser_blue/muzzle
tracer_type = /obj/effect/projectile/laser_blue/tracer tracer_type = /obj/effect/projectile/laser_blue/tracer

View File

@@ -5,6 +5,7 @@
strike up to four targets, including yourself if conditions allow it to occur." strike up to four targets, including yourself if conditions allow it to occur."
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/projectile/chain_lightning obj_path = /obj/item/weapon/spell/projectile/chain_lightning
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/projectile/chain_lightning /obj/item/weapon/spell/projectile/chain_lightning
name = "chain lightning" name = "chain lightning"
@@ -16,6 +17,7 @@
energy_cost_per_shot = 3000 energy_cost_per_shot = 3000
instability_per_shot = 10 instability_per_shot = 10
cooldown = 20 cooldown = 20
fire_sound = 'sound/weapons/gauss_shoot.ogg'
/obj/item/projectile/beam/chain_lightning /obj/item/projectile/beam/chain_lightning
name = "lightning" name = "lightning"

View File

@@ -4,6 +4,7 @@
that armor designed to protect from blunt force will mitigate this function as well." that armor designed to protect from blunt force will mitigate this function as well."
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/projectile/force_missile obj_path = /obj/item/weapon/spell/projectile/force_missile
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/projectile/force_missile /obj/item/weapon/spell/projectile/force_missile
name = "force missile" name = "force missile"
@@ -12,13 +13,14 @@
cast_methods = CAST_RANGED cast_methods = CAST_RANGED
aspect = ASPECT_FORCE aspect = ASPECT_FORCE
spell_projectile = /obj/item/projectile/force_missile spell_projectile = /obj/item/projectile/force_missile
energy_cost_per_shot = 400 energy_cost_per_shot = 300
instability_per_shot = 2 instability_per_shot = 2
cooldown = 10 cooldown = 5
fire_sound = 'sound/weapons/wave.ogg'
/obj/item/projectile/force_missile /obj/item/projectile/force_missile
name = "force missile" name = "force missile"
icon_state = "force_missile" icon_state = "force_missile"
damage = 20 damage = 25
damage_type = BRUTE damage_type = BRUTE
check_armour = "melee" check_armour = "melee"

View File

@@ -5,6 +5,7 @@
strike." strike."
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/projectile/lightning obj_path = /obj/item/weapon/spell/projectile/lightning
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/projectile/lightning /obj/item/weapon/spell/projectile/lightning
name = "lightning strike" name = "lightning strike"
@@ -16,7 +17,8 @@
energy_cost_per_shot = 2500 energy_cost_per_shot = 2500
instability_per_shot = 10 instability_per_shot = 10
cooldown = 20 cooldown = 20
pre_shot_delay = 20 pre_shot_delay = 10
fire_sound = 'sound/weapons/gauss_shoot.ogg'
/obj/item/projectile/beam/lightning /obj/item/projectile/beam/lightning
name = "lightning" name = "lightning"

View File

@@ -4,6 +4,7 @@
This energy pierces all known armor." This energy pierces all known armor."
cost = 150 cost = 150
obj_path = /obj/item/weapon/spell/projectile/overload obj_path = /obj/item/weapon/spell/projectile/overload
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/projectile/overload /obj/item/weapon/spell/projectile/overload
name = "overload" name = "overload"
@@ -13,27 +14,28 @@
aspect = ASPECT_UNSTABLE aspect = ASPECT_UNSTABLE
spell_projectile = /obj/item/projectile/overload spell_projectile = /obj/item/projectile/overload
energy_cost_per_shot = 0 // Handled later energy_cost_per_shot = 0 // Handled later
instability_per_shot = 15 instability_per_shot = 12
cooldown = 10 cooldown = 10
pre_shot_delay = 4 pre_shot_delay = 4
fire_sound = 'sound/effects/supermatter.ogg'
/obj/item/projectile/overload /obj/item/projectile/overload
name = "overloaded bolt" name = "overloaded bolt"
icon_state = "bluespace" icon_state = "bluespace"
// nodamage = 1 // nodamage = 1
damage_type = BURN damage_type = BURN
check_armour = null armor_penetration = 100
/obj/item/weapon/spell/projectile/overload/on_ranged_cast(atom/hit_atom, mob/living/user) /obj/item/weapon/spell/projectile/overload/on_ranged_cast(atom/hit_atom, mob/living/user)
energy_cost_per_shot = round(core.max_energy * 0.15) energy_cost_per_shot = round(core.max_energy * 0.10)
var/energy_before_firing = core.energy var/energy_before_firing = core.energy
if(set_up(hit_atom, user)) if(set_up(hit_atom, user))
var/obj/item/projectile/overload/P = new spell_projectile(get_turf(user)) var/obj/item/projectile/overload/P = new spell_projectile(get_turf(user))
P.launch(hit_atom) P.launch(hit_atom)
if(check_for_scepter()) if(check_for_scepter())
P.damage = round(energy_before_firing * 0.003) // 3% of their current energy pool. P.damage = round(energy_before_firing * 0.004) // 4% of their current energy pool.
else else
P.damage = round(energy_before_firing * 0.002) // 2% of their current energy pool. P.damage = round(energy_before_firing * 0.003) // 3% of their current energy pool.
owner.adjust_instability(instability_per_shot) owner.adjust_instability(instability_per_shot)
return 1 return 1

View File

@@ -7,12 +7,15 @@
var/energy_cost_per_shot = 0 var/energy_cost_per_shot = 0
var/instability_per_shot = 0 var/instability_per_shot = 0
var/pre_shot_delay = 0 var/pre_shot_delay = 0
var/fire_sound = null
/obj/item/weapon/spell/projectile/on_ranged_cast(atom/hit_atom, mob/living/user) /obj/item/weapon/spell/projectile/on_ranged_cast(atom/hit_atom, mob/living/user)
var/turf/T = get_turf(hit_atom) var/turf/T = get_turf(hit_atom)
if(set_up(hit_atom, user)) if(set_up(hit_atom, user))
var/obj/item/projectile/new_projectile = new spell_projectile(get_turf(user)) var/obj/item/projectile/new_projectile = new spell_projectile(get_turf(user))
new_projectile.launch(T) new_projectile.launch(T)
if(fire_sound)
playsound(get_turf(src), fire_sound, 75, 1)
owner.adjust_instability(instability_per_shot) owner.adjust_instability(instability_per_shot)
return 1 return 1
return 0 return 0
@@ -23,7 +26,7 @@
if(pre_shot_delay) if(pre_shot_delay)
var/image/target_image = image(icon = 'icons/obj/spells.dmi', loc = get_turf(hit_atom), icon_state = "target") var/image/target_image = image(icon = 'icons/obj/spells.dmi', loc = get_turf(hit_atom), icon_state = "target")
user << target_image user << target_image
user.Stun(pre_shot_delay) user.Stun(pre_shot_delay / 10)
sleep(pre_shot_delay) sleep(pre_shot_delay)
qdel(target_image) qdel(target_image)
return 1 return 1

View File

@@ -3,6 +3,7 @@
desc = "Causes you to be very radiant, glowing brightly in visible light, thermal energy, and deadly ionizing radiation." desc = "Causes you to be very radiant, glowing brightly in visible light, thermal energy, and deadly ionizing radiation."
cost = 180 cost = 180
obj_path = /obj/item/weapon/spell/radiance obj_path = /obj/item/weapon/spell/radiance
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/radiance /obj/item/weapon/spell/radiance
name = "radiance" name = "radiance"

View File

@@ -4,6 +4,7 @@
cost = 120 cost = 120
obj_path = /obj/item/weapon/spell/reflect obj_path = /obj/item/weapon/spell/reflect
ability_icon_state = "tech_reflect" ability_icon_state = "tech_reflect"
category = DEFENSIVE_SPELLS
/obj/item/weapon/spell/reflect /obj/item/weapon/spell/reflect
name = "\proper reflect shield" name = "\proper reflect shield"

View File

@@ -6,6 +6,7 @@
cost = 100 cost = 100
obj_path = /obj/item/weapon/spell/resurrect obj_path = /obj/item/weapon/spell/resurrect
ability_icon_state = "tech_resurrect" ability_icon_state = "tech_resurrect"
category = SUPPORT_SPELLS
/obj/item/weapon/spell/resurrect /obj/item/weapon/spell/resurrect
name = "resurrect" name = "resurrect"

View File

@@ -3,6 +3,7 @@
desc = "One of the few functions able to adjust instability, this allows you to take someone else's instability." desc = "One of the few functions able to adjust instability, this allows you to take someone else's instability."
cost = 50 cost = 50
obj_path = /obj/item/weapon/spell/shared_burden obj_path = /obj/item/weapon/spell/shared_burden
category = SUPPORT_SPELLS
/obj/item/weapon/spell/shared_burden /obj/item/weapon/spell/shared_burden
name = "shared burden" name = "shared burden"

View File

@@ -5,6 +5,7 @@
cost = 120 cost = 120
obj_path = /obj/item/weapon/spell/shield obj_path = /obj/item/weapon/spell/shield
ability_icon_state = "tech_shield" ability_icon_state = "tech_shield"
category = DEFENSIVE_SPELLS
/obj/item/weapon/spell/shield /obj/item/weapon/spell/shield
name = "\proper energy shield" name = "\proper energy shield"

View File

@@ -3,6 +3,7 @@
desc = "Disrupts photons moving in a local area, causing darkness to shroud yourself or a position of your choosing." desc = "Disrupts photons moving in a local area, causing darkness to shroud yourself or a position of your choosing."
cost = 30 cost = 30
obj_path = /obj/item/weapon/spell/spawner/darkness obj_path = /obj/item/weapon/spell/spawner/darkness
category = UTILITY_SPELLS
/obj/item/weapon/spell/spawner/darkness /obj/item/weapon/spell/spawner/darkness
name = "darkness" name = "darkness"

View File

@@ -4,6 +4,7 @@
sure to not be close to the disturbance yourself." sure to not be close to the disturbance yourself."
cost = 175 cost = 175
obj_path = /obj/item/weapon/spell/spawner/fire_blast obj_path = /obj/item/weapon/spell/spawner/fire_blast
category = OFFENSIVE_SPELLS
/obj/item/weapon/spell/spawner/fire_blast /obj/item/weapon/spell/spawner/fire_blast
name = "fire blast" name = "fire blast"

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