yeehaw it's done
This commit is contained in:
@@ -249,7 +249,7 @@ GLOBAL_LIST_INIT(transit_tube_recipes, list(
|
||||
var/datum/asset/assets = get_asset_datum(/datum/asset/spritesheet/pipes)
|
||||
assets.send(user)
|
||||
|
||||
ui = new(user, src, ui_key, "rpd", name, 425, 515, master_ui, state)
|
||||
ui = new(user, src, ui_key, "rpd", name, 425, 472, master_ui, state)
|
||||
ui.open()
|
||||
|
||||
/obj/item/pipe_dispenser/ui_data(mob/user)
|
||||
@@ -316,9 +316,7 @@ GLOBAL_LIST_INIT(transit_tube_recipes, list(
|
||||
playeffect = FALSE
|
||||
if("mode")
|
||||
var/n = text2num(params["mode"])
|
||||
if(n == 2 && !(mode&1) && !(mode&2))
|
||||
mode |= 3
|
||||
else if(mode&n)
|
||||
if(mode & n)
|
||||
mode &= ~n
|
||||
else
|
||||
mode |= n
|
||||
@@ -327,6 +325,7 @@ GLOBAL_LIST_INIT(transit_tube_recipes, list(
|
||||
spark_system.start()
|
||||
effectcooldown = world.time + 100
|
||||
playsound(get_turf(src), 'sound/effects/pop.ogg', 50, 0)
|
||||
return TRUE
|
||||
|
||||
/obj/item/pipe_dispenser/pre_attack(atom/A, mob/user)
|
||||
var/turf/T = get_turf(A)
|
||||
|
||||
@@ -269,14 +269,11 @@ update_label("John Doe", "Clowny")
|
||||
if(isliving(user) && user.mind)
|
||||
if(user.mind.special_role || anyone)
|
||||
if(alert(user, "Action", "Agent ID", "Show", "Forge") == "Forge")
|
||||
var/t = copytext(sanitize(input(user, "What name would you like to put on this card?", "Agent card name", registered_name ? registered_name : (ishuman(user) ? user.real_name : user.name))as text | null),1,26)
|
||||
if(!t || t == "Unknown" || t == "floor" || t == "wall" || t == "r-wall") //Same as mob/dead/new_player/prefrences.dm
|
||||
if (t)
|
||||
alert("Invalid name.")
|
||||
var/input_name = reject_bad_name(stripped_input(user, "What name would you like to put on this card?", "Agent card name", registered_name ? registered_name : (ishuman(user) ? user.real_name : user.name), MAX_NAME_LEN), TRUE)
|
||||
if(!input_name)
|
||||
return
|
||||
registered_name = t
|
||||
|
||||
var/u = copytext(sanitize(input(user, "What occupation would you like to put on this card?\nNote: This will not grant any access levels other than Maintenance.", "Agent card job assignment", "Assistant")as text | null),1,MAX_MESSAGE_LEN)
|
||||
var/u = stripped_input(user, "What occupation would you like to put on this card?\nNote: This will not grant any access levels other than Maintenance.", "Agent card job assignment", "Assistant", MAX_MESSAGE_LEN)
|
||||
if(!u)
|
||||
registered_name = ""
|
||||
return
|
||||
|
||||
@@ -407,7 +407,7 @@
|
||||
to_chat(user, "<span class='notice'>You spray a [temp] on \the [target.name]</span>")
|
||||
|
||||
if(length(text_buffer) > 1)
|
||||
text_buffer = copytext(text_buffer,2)
|
||||
text_buffer = copytext(text_buffer, length(text_buffer[1]) + 1)
|
||||
SStgui.update_uis(src)
|
||||
|
||||
if(post_noise)
|
||||
|
||||
@@ -292,7 +292,7 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
dat += text("ID: <a href='?src=[REF(src)];choice=Authenticate'>[id ? "[id.registered_name], [id.assignment]" : "----------"]")
|
||||
dat += text("<br><a href='?src=[REF(src)];choice=UpdateInfo'>[id ? "Update PDA Info" : ""]</A><br><br>")
|
||||
|
||||
dat += "[STATION_TIME_TIMESTAMP("hh:mm:ss")]<br>" //:[world.time / 100 % 6][world.time / 100 % 10]"
|
||||
dat += "[STATION_TIME_TIMESTAMP("hh:mm:ss", world.time)]<br>" //:[world.time / 100 % 6][world.time / 100 % 10]"
|
||||
dat += "[time2text(world.realtime, "MMM DD")] [GLOB.year_integer]"
|
||||
|
||||
dat += "<br><br>"
|
||||
@@ -641,13 +641,13 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
if("Clear")//Clears messages
|
||||
tnote = null
|
||||
if("Ringtone")
|
||||
var/t = input(U, "Please enter new ringtone", name, ttone) as text
|
||||
var/t = stripped_input(U, "Please enter new ringtone", name, ttone, 20)
|
||||
if(in_range(src, U) && loc == U && t)
|
||||
if(SEND_SIGNAL(src, COMSIG_PDA_CHANGE_RINGTONE, U, t) & COMPONENT_STOP_RINGTONE_CHANGE)
|
||||
U << browse(null, "window=pda")
|
||||
return
|
||||
else
|
||||
ttone = copytext(sanitize(t), 1, 20)
|
||||
ttone = t
|
||||
else
|
||||
U << browse(null, "window=pda")
|
||||
return
|
||||
|
||||
@@ -309,9 +309,14 @@ Code:
|
||||
var/list/S = list(" Off","AOff"," On", " AOn")
|
||||
var/list/chg = list("N","C","F")
|
||||
|
||||
//Neither copytext nor copytext_char is appropriate here; neither 30 UTF-8 code units nor 30 code points equates to 30 columns of output.
|
||||
//Some glyphs are very tall or very wide while others are small or even take up no space at all.
|
||||
//Emojis can take modifiers which are many characters but render as only one glyph.
|
||||
//A proper solution here (as far as Unicode goes, maybe not ideal as far as markup goes, a table would be better)
|
||||
//would be to use <span style="width: NNNpx; overflow: none;">[A.area.name]</span>
|
||||
for(var/obj/machinery/power/apc/A in L)
|
||||
menu += copytext(add_tspace(A.area.name, 30), 1, 30)
|
||||
menu += " [S[A.equipment+1]] [S[A.lighting+1]] [S[A.environ+1]] [add_lspace(DisplayPower(A.lastused_total), 6)] [A.cell ? "[add_lspace(round(A.cell.percent()), 3)]% [chg[A.charging+1]]" : " N/C"]<BR>"
|
||||
menu += copytext_char(add_trailing(A.area.name, 30, " "), 1, 30)
|
||||
menu += " [S[A.equipment+1]] [S[A.lighting+1]] [S[A.environ+1]] [add_leading(DisplayPower(A.lastused_total), 6, " ")] [A.cell ? "[add_leading(round(A.cell.percent()), 3, " ")]% [chg[A.charging+1]]" : " N/C"]<BR>"
|
||||
|
||||
menu += "</FONT></PRE>"
|
||||
|
||||
|
||||
@@ -73,8 +73,10 @@ GLOBAL_LIST_EMPTY(GPS_list)
|
||||
return
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
var/gps_window_height = 300 + GLOB.GPS_list.len * 20 // Variable window height, depending on how many GPS units there are to show
|
||||
ui = new(user, src, ui_key, "gps", "Global Positioning System", 600, gps_window_height, master_ui, state) //width, height
|
||||
// Variable window height, depending on how many GPS units there are
|
||||
// to show, clamped to relatively safe range.
|
||||
var/gps_window_height = CLAMP(325 + GLOB.GPS_list.len * 14, 325, 700)
|
||||
ui = new(user, src, ui_key, "gps", "Global Positioning System", 470, gps_window_height, master_ui, state) //width, height
|
||||
ui.open()
|
||||
|
||||
ui.set_autoupdate(state = updating)
|
||||
@@ -91,6 +93,8 @@ GLOBAL_LIST_EMPTY(GPS_list)
|
||||
|
||||
var/turf/curr = get_turf(src)
|
||||
data["current"] = "[get_area_name(curr, TRUE)] ([curr.x], [curr.y], [curr.z])"
|
||||
data["currentArea"] = "[get_area_name(curr, TRUE)]"
|
||||
data["currentCoords"] = "[curr.x], [curr.y], [curr.z]"
|
||||
|
||||
var/list/signals = list()
|
||||
data["signals"] = list()
|
||||
@@ -104,16 +108,10 @@ GLOBAL_LIST_EMPTY(GPS_list)
|
||||
continue
|
||||
var/list/signal = list()
|
||||
signal["entrytag"] = G.gpstag //Name or 'tag' of the GPS
|
||||
signal["area"] = get_area_name(G, TRUE)
|
||||
signal["coord"] = "[pos.x], [pos.y], [pos.z]"
|
||||
signal["coords"] = "[pos.x], [pos.y], [pos.z]"
|
||||
if(pos.z == curr.z) //Distance/Direction calculations for same z-level only
|
||||
signal["dist"] = max(get_dist(curr, pos), 0) //Distance between the src and remote GPS turfs
|
||||
signal["degrees"] = round(Get_Angle(curr, pos)) //0-360 degree directional bearing, for more precision.
|
||||
var/direction = uppertext(dir2text(get_dir(curr, pos))) //Direction text (East, etc). Not as precise, but still helpful.
|
||||
if(!direction)
|
||||
direction = "CENTER"
|
||||
signal["degrees"] = "N/A"
|
||||
signal["direction"] = direction
|
||||
|
||||
signals += list(signal) //Add this signal to the list of signals
|
||||
data["signals"] = signals
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
if(href_list["reset_radio_short"])
|
||||
pai.unshort_radio()
|
||||
if(href_list["setlaws"])
|
||||
var/newlaws = copytext(sanitize(input("Enter any additional directives you would like your pAI personality to follow. Note that these directives will not override the personality's allegiance to its imprinted master. Conflicting directives will be ignored.", "pAI Directive Configuration", pai.laws.supplied[1]) as message),1,MAX_MESSAGE_LEN)
|
||||
var/newlaws = stripped_multiline_input("Enter any additional directives you would like your pAI personality to follow. Note that these directives will not override the personality's allegiance to its imprinted master. Conflicting directives will be ignored.", "pAI Directive Configuration", MAX_MESSAGE_LEN)
|
||||
if(newlaws && pai)
|
||||
pai.add_supplied_law(0,newlaws)
|
||||
if(href_list["toggle_holo"])
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
var/mob/living/carbon/C = usr
|
||||
if(usr.stat || usr.restrained() || C.back == src)
|
||||
return
|
||||
|
||||
|
||||
if(!usr.canUseTopic(src, BE_CLOSE))
|
||||
usr << browse(null, "window=radio")
|
||||
onclose(usr, "radio")
|
||||
@@ -127,7 +127,7 @@
|
||||
/obj/item/electropack/ui_interact(mob/user)
|
||||
if(!ishuman(user))
|
||||
return
|
||||
|
||||
|
||||
user.set_machine(src)
|
||||
var/dat = {"
|
||||
<TT>
|
||||
@@ -200,14 +200,14 @@ Code:
|
||||
|
||||
/obj/item/electropack/shockcollar/attackby(obj/item/W, mob/user, params) //moves it here because on_click is being bad
|
||||
if(istype(W, /obj/item/pen))
|
||||
var/t = input(user, "Would you like to change the name on the tag?", "Name your new pet", tagname ? tagname : "Spot") as null|text
|
||||
var/t = stripped_input(user, "Would you like to change the name on the tag?", "Name your new pet", tagname ? tagname : "Spot", MAX_NAME_LEN)
|
||||
if(t)
|
||||
tagname = copytext(sanitize(t), 1, MAX_NAME_LEN)
|
||||
name = "[initial(name)] - [tagname]"
|
||||
tagname = t
|
||||
name = "[initial(name)] - [t]"
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/electropack/shockcollar/ui_interact(mob/user) //on_click calls this
|
||||
/obj/item/electropack/shockcollar/ui_interact(mob/user) //on_click calls this
|
||||
var/dat = {"
|
||||
<TT>
|
||||
<B>Frequency/Code</B> for shock collar:<BR>
|
||||
|
||||
@@ -112,7 +112,14 @@
|
||||
. = ..()
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "radio", name, 370, 220 + channels.len * 22, master_ui, state)
|
||||
var/ui_width = 360
|
||||
var/ui_height = 106
|
||||
if(subspace_transmission)
|
||||
if(channels.len > 0)
|
||||
ui_height += 6 + channels.len * 21
|
||||
else
|
||||
ui_height += 24
|
||||
ui = new(user, src, ui_key, "radio", name, ui_width, ui_height, master_ui, state)
|
||||
ui.open()
|
||||
|
||||
/obj/item/radio/ui_data(mob/user)
|
||||
|
||||
@@ -28,7 +28,7 @@ SLIME SCANNER
|
||||
/obj/item/t_scanner/attack_self(mob/user)
|
||||
|
||||
on = !on
|
||||
icon_state = copytext(icon_state, 1, length(icon_state))+"[on]"
|
||||
icon_state = copytext_char(icon_state, 1, -1) + "[on]"
|
||||
|
||||
if(on)
|
||||
START_PROCESSING(SSobj, src)
|
||||
@@ -407,19 +407,17 @@ SLIME SCANNER
|
||||
// Blood Level
|
||||
if(M.has_dna())
|
||||
var/mob/living/carbon/C = M
|
||||
var/blood_id = C.get_blood_id()
|
||||
if(blood_id)
|
||||
var/blood_typepath = C.get_blood_id()
|
||||
if(blood_typepath)
|
||||
if(ishuman(C))
|
||||
if(H.bleed_rate)
|
||||
msg += "<span class='danger'>Subject is bleeding!</span>\n"
|
||||
var/blood_percent = round((C.scan_blood_volume() / (BLOOD_VOLUME_NORMAL * C.blood_ratio))*100)
|
||||
var/blood_type = C.dna.blood_type
|
||||
if(blood_id != ("blood" || "jellyblood"))//special blood substance
|
||||
var/datum/reagent/R = GLOB.chemical_reagents_list[blood_id]
|
||||
if(!(blood_typepath in GLOB.blood_reagent_types))
|
||||
var/datum/reagent/R = GLOB.chemical_reagents_list[blood_typepath]
|
||||
if(R)
|
||||
blood_type = R.name
|
||||
else
|
||||
blood_type = blood_id
|
||||
if(C.scan_blood_volume() <= (BLOOD_VOLUME_SAFE*C.blood_ratio) && C.scan_blood_volume() > (BLOOD_VOLUME_OKAY*C.blood_ratio))
|
||||
msg += "<span class='danger'>LOW blood level [blood_percent] %, [C.scan_blood_volume()] cl,</span> <span class='info'>type: [blood_type]</span>\n"
|
||||
else if(C.scan_blood_volume() <= (BLOOD_VOLUME_OKAY*C.blood_ratio))
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
to_chat(user, "<span class='warning'>[src] was shaken recently, it needs time to settle.</span>")
|
||||
return
|
||||
|
||||
user.visible_message("<span class='notice'>[user] starts shaking [src].</span>", "<span class='notice'>You start shaking [src].</span>", "<span class='italics'>You hear shaking and sloshing.</span>")
|
||||
user.visible_message("<span class='notice'>[user] starts shaking [src].</span>", "<span class='notice'>You start shaking [src].</span>", "<span class='hear'>You hear shaking and sloshing.</span>")
|
||||
|
||||
shaking = TRUE
|
||||
|
||||
@@ -95,16 +95,47 @@
|
||||
// except it actually ASKS THE DEAD (wooooo)
|
||||
|
||||
/obj/item/toy/eightball/haunted
|
||||
shake_time = 150
|
||||
cooldown_time = 1800
|
||||
shake_time = 30 SECONDS
|
||||
cooldown_time = 3 MINUTES
|
||||
flags_1 = HEAR_1
|
||||
var/last_message
|
||||
var/selected_message
|
||||
var/list/votes
|
||||
//these kind of store the same thing but one is easier to work with.
|
||||
var/list/votes = list()
|
||||
var/list/voted = list()
|
||||
var/static/list/haunted_answers = list(
|
||||
"yes" = list(
|
||||
"It is certain",
|
||||
"It is decidedly so",
|
||||
"Without a doubt",
|
||||
"Yes definitely",
|
||||
"You may rely on it",
|
||||
"As I see it, yes",
|
||||
"Most likely",
|
||||
"Outlook good",
|
||||
"Yes",
|
||||
"Signs point to yes"
|
||||
),
|
||||
"maybe" = list(
|
||||
"Reply hazy try again",
|
||||
"Ask again later",
|
||||
"Better not tell you now",
|
||||
"Cannot predict now",
|
||||
"Concentrate and ask again"
|
||||
),
|
||||
"no" = list(
|
||||
"Don't count on it",
|
||||
"My reply is no",
|
||||
"My sources say no",
|
||||
"Outlook not so good",
|
||||
"Very doubtful"
|
||||
)
|
||||
)
|
||||
|
||||
/obj/item/toy/eightball/haunted/Initialize(mapload)
|
||||
. = ..()
|
||||
votes = list()
|
||||
for (var/answer in haunted_answers)
|
||||
votes[answer] = 0
|
||||
GLOB.poi_list |= src
|
||||
|
||||
/obj/item/toy/eightball/haunted/Destroy()
|
||||
@@ -122,7 +153,7 @@
|
||||
interact(user)
|
||||
return ..()
|
||||
|
||||
/obj/item/toy/eightball/haunted/Hear(message, atom/movable/speaker, message_langs, raw_message, radio_freq, spans, message_mode, atom/movable/source)
|
||||
/obj/item/toy/eightball/haunted/Hear(message, atom/movable/speaker, message_langs, raw_message, radio_freq, spans, message_mode)
|
||||
. = ..()
|
||||
last_message = raw_message
|
||||
|
||||
@@ -137,38 +168,31 @@
|
||||
if(isobserver(usr))
|
||||
interact(usr)
|
||||
|
||||
/obj/item/toy/eightball/haunted/proc/get_vote_tallies()
|
||||
var/list/answers = list()
|
||||
for(var/ckey in votes)
|
||||
var/selected = votes[ckey]
|
||||
if(selected in answers)
|
||||
answers[selected]++
|
||||
else
|
||||
answers[selected] = 1
|
||||
|
||||
return answers
|
||||
|
||||
|
||||
/obj/item/toy/eightball/haunted/get_answer()
|
||||
if(!votes.len)
|
||||
return pick(possible_answers)
|
||||
var/top_amount = 0
|
||||
var/top_vote
|
||||
|
||||
var/list/tallied_votes = get_vote_tallies()
|
||||
for(var/vote in votes)
|
||||
var/amount_of_votes = length(votes[vote])
|
||||
if(amount_of_votes > top_amount)
|
||||
top_vote = vote
|
||||
top_amount = amount_of_votes
|
||||
//If one option actually has votes and there's a tie, pick between them 50/50
|
||||
else if(top_amount && amount_of_votes == top_amount && prob(50))
|
||||
top_vote = vote
|
||||
top_amount = amount_of_votes
|
||||
|
||||
// I miss python sorting, then I wouldn't have to muck about with
|
||||
// all this
|
||||
var/most_popular_answer
|
||||
var/most_amount = 0
|
||||
// yes, if there is a tie, there is an arbitary decision
|
||||
// but we never said the spirit world was fair
|
||||
for(var/A in tallied_votes)
|
||||
var/amount = tallied_votes[A]
|
||||
if(amount > most_amount)
|
||||
most_popular_answer = A
|
||||
if(isnull(top_vote))
|
||||
top_vote = pick(votes)
|
||||
|
||||
return most_popular_answer
|
||||
for(var/vote in votes)
|
||||
votes[vote] = 0
|
||||
|
||||
/obj/item/toy/eightball/haunted/ui_interact(mob/user, ui_key="main", datum/tgui/ui=null, force_open=0, datum/tgui/master_ui=null, datum/ui_state/state = GLOB.observer_state)
|
||||
voted.Cut()
|
||||
|
||||
return top_vote
|
||||
|
||||
/obj/item/toy/eightball/haunted/ui_interact(mob/user, ui_key="main", datum/tgui/ui=null, force_open=0, datum/tgui/master_ui=null, datum/ui_state/state = GLOB.always_state)
|
||||
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
@@ -179,21 +203,13 @@
|
||||
var/list/data = list()
|
||||
data["shaking"] = shaking
|
||||
data["question"] = selected_message
|
||||
var/list/tallied_votes = get_vote_tallies()
|
||||
|
||||
data["answers"] = list()
|
||||
|
||||
for(var/pa in possible_answers)
|
||||
for(var/pa in haunted_answers)
|
||||
var/list/L = list()
|
||||
L["answer"] = pa
|
||||
var/amount = 0
|
||||
if(pa in tallied_votes)
|
||||
amount = tallied_votes[pa]
|
||||
L["amount"] = amount
|
||||
var/selected = FALSE
|
||||
if(votes[user.ckey] == pa)
|
||||
selected = TRUE
|
||||
L["selected"] = selected
|
||||
L["amount"] = votes[pa]
|
||||
L["selected"] = voted[user.ckey]
|
||||
|
||||
data["answers"] += list(L)
|
||||
return data
|
||||
@@ -206,8 +222,11 @@
|
||||
switch(action)
|
||||
if("vote")
|
||||
var/selected_answer = params["answer"]
|
||||
if(!(selected_answer in possible_answers))
|
||||
if(!(selected_answer in haunted_answers))
|
||||
return
|
||||
if(user.ckey in voted)
|
||||
return
|
||||
else
|
||||
votes[user.ckey] = selected_answer
|
||||
. = TRUE
|
||||
votes[selected_answer] += 1
|
||||
voted[user.ckey] = selected_answer
|
||||
. = TRUE
|
||||
@@ -34,12 +34,12 @@
|
||||
|
||||
/obj/item/grenade/proc/clown_check(mob/living/carbon/human/user)
|
||||
var/clumsy = HAS_TRAIT(user, TRAIT_CLUMSY)
|
||||
if(clumsy && (clumsy_check == GRENADE_CLUMSY_FUMBLE))
|
||||
if(prob(50))
|
||||
if(clumsy)
|
||||
if(clumsy_check == GRENADE_CLUMSY_FUMBLE && prob(50))
|
||||
to_chat(user, "<span class='warning'>Huh? How does this thing work?</span>")
|
||||
preprime(user, 5, FALSE)
|
||||
return FALSE
|
||||
else if(!clumsy && (clumsy_check == GRENADE_NONCLUMSY_FUMBLE))
|
||||
else if(clumsy_check == GRENADE_NONCLUMSY_FUMBLE && !(user.mind && HAS_TRAIT(user.mind, TRAIT_CLOWN_MENTALITY)))
|
||||
to_chat(user, "<span class='warning'>You pull the pin on [src]. Attached to it is a pink ribbon that says, \"<span class='clown'>HONK</span>\"</span>")
|
||||
preprime(user, 5, FALSE)
|
||||
return FALSE
|
||||
|
||||
@@ -92,6 +92,14 @@
|
||||
creation_time = 0
|
||||
max_signs = 3
|
||||
|
||||
/obj/item/holosign_creator/combifan
|
||||
name = "ATMOS holo-combifan projector"
|
||||
desc = "A holographic projector that creates holographic combi-fans that prevent changes in atmosphere and temperature conditions. Somehow."
|
||||
icon_state = "signmaker_atmos"
|
||||
holosign_type = /obj/structure/holosign/barrier/combifan
|
||||
creation_time = 0
|
||||
max_signs = 3
|
||||
|
||||
/obj/item/holosign_creator/medical
|
||||
name = "\improper PENLITE barrier projector"
|
||||
desc = "A holographic projector that creates PENLITE holobarriers. Useful during quarantines since they halt those with malicious diseases."
|
||||
|
||||
@@ -72,20 +72,21 @@
|
||||
display_names += list(initial(A.name) = A)
|
||||
|
||||
var/choice = input(M,"What holy armor kit would you like to order?","Holy Armor Theme") as null|anything in display_names
|
||||
if(QDELETED(src) || !choice || M.stat || !in_range(M, src) || M.restrained() || !M.canmove || GLOB.holy_armor_type)
|
||||
var/turf/T = get_turf(M)
|
||||
if(!T || QDELETED(src) || !choice || M.stat || !in_range(M, src) || M.restrained() || !M.canmove || GLOB.holy_armor_type)
|
||||
return
|
||||
|
||||
var/index = display_names.Find(choice)
|
||||
var/A = holy_armor_list[index]
|
||||
|
||||
GLOB.holy_armor_type = A
|
||||
var/holy_armor_box = new A
|
||||
var/holy_armor_box = new A(T)
|
||||
|
||||
SSblackbox.record_feedback("tally", "chaplain_armor", 1, "[choice]")
|
||||
|
||||
if(holy_armor_box)
|
||||
qdel(src)
|
||||
M.put_in_active_hand(holy_armor_box)///YOU COMPILED
|
||||
M.put_in_hands(holy_armor_box)
|
||||
|
||||
/obj/item/storage/box/holy
|
||||
name = "Templar Kit"
|
||||
|
||||
@@ -77,7 +77,10 @@
|
||||
return TRUE
|
||||
if (user.get_active_held_item())
|
||||
return
|
||||
object.attack_ai(imp_in)
|
||||
if (user.CanReach(object))
|
||||
object.attack_robot(imp_in)
|
||||
else
|
||||
object.attack_ai(imp_in)
|
||||
return TRUE
|
||||
|
||||
/obj/item/implant/hijack/proc/hijack_remotely(obj/machinery/power/apc/apc)
|
||||
@@ -87,6 +90,9 @@
|
||||
if (!do_after(imp_in, 4 SECONDS,target=apc))
|
||||
to_chat(imp_in, "<span class='warning'>Aborting.</span>")
|
||||
return TRUE
|
||||
if (LAZYLEN(imp_in.siliconaccessareas) >= HIJACK_APC_MAX_AMOUNT)
|
||||
to_chat(src,"<span class='warning'>You are connected to too many APCs! Too many more will fry your brain.</span>")
|
||||
return TRUE
|
||||
imp_in.light_power = 2
|
||||
imp_in.light_range = 2
|
||||
imp_in.light_color = COLOR_YELLOW
|
||||
@@ -99,7 +105,7 @@
|
||||
apc.set_hijacked_lighting()
|
||||
imp_in.toggleSiliconAccessArea(apc.area)
|
||||
apc.update_icon()
|
||||
stealthcooldown = world.time + 3 MINUTES
|
||||
stealthcooldown = world.time + 1 MINUTES + 30 SECONDS
|
||||
toggle_eyes()
|
||||
else
|
||||
to_chat(imp_in, "<span class='warning'>Aborting.</span>")
|
||||
|
||||
@@ -154,6 +154,7 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \
|
||||
GLOBAL_LIST_INIT(plasteel_recipes, list ( \
|
||||
new/datum/stack_recipe("AI core", /obj/structure/AIcore, 4, time = 50, one_per_turf = TRUE), \
|
||||
new/datum/stack_recipe("bomb assembly", /obj/machinery/syndicatebomb/empty, 10, time = 50), \
|
||||
new/datum/stack_recipe("crate", /obj/structure/closet/crate, 5, time = 90, one_per_turf = TRUE), \
|
||||
null, \
|
||||
new /datum/stack_recipe_list("airlock assemblies", list( \
|
||||
new/datum/stack_recipe("high security airlock assembly", /obj/structure/door_assembly/door_assembly_highsecurity, 6, time = 50, one_per_turf = 1, on_floor = 1), \
|
||||
|
||||
@@ -399,11 +399,14 @@
|
||||
. = ..()
|
||||
|
||||
/obj/item/stack/proc/copy_evidences(obj/item/stack/from)
|
||||
blood_DNA = from.blood_DNA
|
||||
fingerprints = from.fingerprints
|
||||
fingerprintshidden = from.fingerprintshidden
|
||||
fingerprintslast = from.fingerprintslast
|
||||
//TODO bloody overlay
|
||||
if(from.blood_DNA)
|
||||
blood_DNA = from.blood_DNA.Copy()
|
||||
if(from.fingerprints)
|
||||
fingerprints = from.fingerprints.Copy()
|
||||
if(from.fingerprintshidden)
|
||||
fingerprintshidden = from.fingerprintshidden.Copy()
|
||||
if(from.fingerprintslast)
|
||||
fingerprintslast = from.fingerprintslast
|
||||
|
||||
/obj/item/stack/microwave_act(obj/machinery/microwave/M)
|
||||
if(istype(M) && M.dirty < 100)
|
||||
|
||||
@@ -322,6 +322,26 @@
|
||||
for(var/i in 1 to 5)
|
||||
new /obj/item/grenade/empgrenade(src)
|
||||
|
||||
/obj/item/storage/box/minibombs
|
||||
name = "box of syndicate minibombs"
|
||||
desc = "A box containing 2 highly explosive syndicate minibombs."
|
||||
icon_state = "syndiebox"
|
||||
illustration = "frag"
|
||||
|
||||
/obj/item/storage/box/minibombs/PopulateContents()
|
||||
new /obj/item/grenade/syndieminibomb(src)
|
||||
new /obj/item/grenade/syndieminibomb(src)
|
||||
|
||||
/obj/item/storage/box/bombananas
|
||||
name = "box of bombananas"
|
||||
desc = "A box containing 2 highly explosive bombananas. Discard peel at enemy after consumption."
|
||||
icon_state = "syndiebox"
|
||||
illustration = "frag"
|
||||
|
||||
/obj/item/storage/box/bombananas/PopulateContents()
|
||||
new /obj/item/reagent_containers/food/snacks/grown/banana/bombanana(src)
|
||||
new /obj/item/reagent_containers/food/snacks/grown/banana/bombanana(src)
|
||||
|
||||
/obj/item/storage/box/trackimp
|
||||
name = "boxed tracking implant kit"
|
||||
desc = "Box full of scum-bag tracking utensils."
|
||||
@@ -1267,4 +1287,4 @@
|
||||
|
||||
/obj/item/storage/box/marshmallow/PopulateContents()
|
||||
for (var/i in 1 to 5)
|
||||
new /obj/item/reagent_containers/food/snacks/marshmallow(src)
|
||||
new /obj/item/reagent_containers/food/snacks/marshmallow(src)
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
* Cigarette Box
|
||||
* Cigar Case
|
||||
* Heart Shaped Box w/ Chocolates
|
||||
* Ring Box
|
||||
*/
|
||||
|
||||
/obj/item/storage/fancy
|
||||
@@ -352,3 +353,33 @@
|
||||
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
||||
STR.max_items = 8
|
||||
STR.can_hold = typecacheof(list(/obj/item/reagent_containers/food/snacks/tinychocolate))
|
||||
|
||||
/*
|
||||
* Ring Box
|
||||
*/
|
||||
|
||||
/obj/item/storage/fancy/ringbox
|
||||
name = "ring box"
|
||||
desc = "A tiny box covered in soft red felt made for holding rings."
|
||||
icon = 'icons/obj/ring.dmi'
|
||||
icon_state = "gold ringbox"
|
||||
icon_type = "gold ring"
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
spawn_type = /obj/item/clothing/gloves/ring
|
||||
|
||||
/obj/item/storage/fancy/ringbox/ComponentInitialize()
|
||||
. = ..()
|
||||
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
||||
STR.max_items = 1
|
||||
STR.can_hold = typecacheof(list(/obj/item/clothing/gloves/ring))
|
||||
|
||||
/obj/item/storage/fancy/ringbox/diamond
|
||||
icon_state = "diamond ringbox"
|
||||
icon_type = "diamond ring"
|
||||
spawn_type = /obj/item/clothing/gloves/ring/diamond
|
||||
|
||||
/obj/item/storage/fancy/ringbox/silver
|
||||
icon_state = "silver ringbox"
|
||||
icon_type = "silver ring"
|
||||
spawn_type = /obj/item/clothing/gloves/ring/silver
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
|
||||
/obj/item/storage/toolbox/update_icon()
|
||||
..()
|
||||
cut_overlays()
|
||||
if(blood_DNA && blood_DNA.len)
|
||||
if(length(blood_DNA))
|
||||
add_blood_overlay()
|
||||
if(has_latches)
|
||||
var/icon/I = icon('icons/obj/storage.dmi', latches)
|
||||
@@ -251,16 +251,12 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
|
||||
new /obj/item/ammo_box/a762(src)
|
||||
new /obj/item/ammo_box/a762(src)
|
||||
|
||||
/obj/item/storage/toolbox/gold_real
|
||||
/obj/item/storage/toolbox/plastitanium/gold_real
|
||||
name = "golden toolbox"
|
||||
desc = "A larger then normal toolbox made of gold plated plastitanium."
|
||||
icon_state = "gold"
|
||||
item_state = "toolbox_gold"
|
||||
has_latches = FALSE
|
||||
force = 16 // Less then a spear
|
||||
throwforce = 14
|
||||
throw_speed = 5
|
||||
throw_range = 10
|
||||
|
||||
/obj/item/storage/toolbox/gold_real/PopulateContents()
|
||||
new /obj/item/screwdriver/nuke(src)
|
||||
|
||||
@@ -156,7 +156,7 @@
|
||||
datum/tgui/master_ui = null, datum/ui_state/state = GLOB.hands_state)
|
||||
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "tanks", name, 420, 200, master_ui, state)
|
||||
ui = new(user, src, ui_key, "tanks", name, 400, 120, master_ui, state)
|
||||
ui.open()
|
||||
|
||||
/obj/item/tank/ui_data(mob/user)
|
||||
|
||||
@@ -1244,7 +1244,7 @@
|
||||
|
||||
/obj/item/toy/clockwork_watch/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='info'>Station Time: [STATION_TIME_TIMESTAMP("hh:mm:ss")]"
|
||||
. += "<span class='info'>Station Time: [STATION_TIME_TIMESTAMP("hh:mm:ss", world.time)]"
|
||||
|
||||
/*
|
||||
* Toy Dagger
|
||||
|
||||
@@ -38,9 +38,9 @@
|
||||
wielded = 0
|
||||
if(!isnull(force_unwielded))
|
||||
force = force_unwielded
|
||||
var/sf = findtext(name," (Wielded)")
|
||||
var/sf = findtext(name, " (Wielded)", -10)//10 == length(" (Wielded)")
|
||||
if(sf)
|
||||
name = copytext(name,1,sf)
|
||||
name = copytext(name, 1, sf)
|
||||
else //something wrong
|
||||
name = "[initial(name)]"
|
||||
update_icon()
|
||||
@@ -347,7 +347,6 @@
|
||||
icon_state = "dualsaber[item_color][wielded]"
|
||||
else
|
||||
icon_state = "dualsaber0"
|
||||
|
||||
clean_blood()
|
||||
|
||||
/obj/item/twohanded/dualsaber/attack(mob/target, mob/living/carbon/human/user)
|
||||
|
||||
Reference in New Issue
Block a user