:HELP: MAINT

This commit is contained in:
Poojawa
2018-03-18 11:26:00 -05:00
parent 796e22beac
commit acfee53a98
18 changed files with 244 additions and 63 deletions
@@ -131,25 +131,25 @@
restricted_roles = list("Chief Engineer","Atmospheric Technician","Station Engineer","Warden","Detective","Security Officer","Head of Security","Cargo Technician", "Shaft Miner", "Quartermaster")
//Hats!
/datum/gear/hat/job_trek/cap
/datum/gear/hat/job_trek
name = "Federation Officer's Cap"
category = slot_head
path = /obj/item/clothing/head/caphat/formal/fedcover
restricted_roles = list("Captain","Head of Personnel")
/datum/gear/hat/job_trek/cap/medisci
/datum/gear/hat/job_trek/medisci
name = "Federation Officer's Cap"
category = slot_head
path = /obj/item/clothing/head/caphat/formal/fedcover/medsci
restricted_roles = list("Chief Medical Officer","Medical Doctor","Chemist","Virologist","Geneticist","Research Director","Scientist", "Roboticist")
/datum/gear/hat/job_trek/cap/eng
/datum/gear/hat/job_trek/eng
name = "Federation Officer's Cap"
category = slot_head
path = /obj/item/clothing/head/caphat/formal/fedcover/eng
restricted_roles = list("Chief Engineer","Atmospheric Technician","Station Engineer","Warden","Detective","Security Officer","Head of Security","Cargo Technician", "Shaft Miner", "Quartermaster")
/datum/gear/hat/job_trek/cap/sec
/datum/gear/hat/job_trek/sec
name = "Federation Officer's Cap"
category = slot_head
path = /obj/item/clothing/head/caphat/formal/fedcover/sec
@@ -12,7 +12,11 @@
var/arousable = TRUE
var/widescreenpref = TRUE
var/autostand = TRUE
var/toggleeatingnoise = TRUE
var/toggledigestionnoise = TRUE
var/hound_sleeper = TRUE
max_save_slots = 10
var/cit_toggles = TOGGLES_CITADEL
features = list("mcolor" = "FFF",
"tail_lizard" = "Smooth",
"tail_human" = "None",
@@ -86,13 +90,10 @@
..()
LAZYINITLIST(chosen_gear)
/datum/preferences/proc/add_citadel_choices(dat)
if(current_tab == 2)
update_preview_icon(nude=TRUE)
else
update_preview_icon(nude=FALSE)
/datum/preferences/proc/add_citadel_choices(.)
return dat
return .
/datum/preferences/proc/process_citadel_link(mob/user, list/href_list)
if(href_list["task"] == "input")
@@ -357,10 +358,9 @@
features["vag_color"] = sanitize_hexcolor(new_vagcolor)
else
user << "<span class='danger'>Invalid color. Your color is not bright enough.</span>"
if("input")
else
switch(href_list["preference"])
//genital code
if("genital_colour")
switch(features["genitals_use_skintone"])
@@ -473,8 +473,7 @@
features["exhibitionist"] = TRUE
else
features["exhibitionist"] = FALSE
else
switch(href_list["preference"])
if("widescreenpref")
widescreenpref = !widescreenpref
user.client.change_view(CONFIG_GET(string/default_view))
@@ -514,7 +513,7 @@
if(i == href_list["select_category"])
gear_tab = i
if(href_list["toggle_gear_path"])
var/datum/gear/G = GLOB.loadout_items[gear_tab][html_decode(href_list["toggle_gear_path"])]
var/datum/gear/G = GLOB.loadout_items[gear_tab][href_list["toggle_gear_path"]]
if(!G)
return
var/toggle = text2num(href_list["toggle_gear"])
@@ -525,9 +524,6 @@
if(!is_loadout_slot_available(G.category))
to_chat(user, "<span class='danger'>You cannot take this loadout, as you've already chosen too many of the same category!</span>")
return
if(G.ckeywhitelist && G.ckeywhitelist.len && !(user.ckey in G.ckeywhitelist))
to_chat(user, "<span class='danger'>This is an item intended for donator use only. You are not authorized to use this item.</span>")
return
if(gear_points >= initial(G.cost))
LAZYADD(chosen_gear, G.type)
gear_points -= initial(G.cost)
@@ -535,6 +531,7 @@
/datum/preferences/proc/citadel_dat_replace(current_tab)
var/mob/user
//This proc is for menus other than game pref and char pref
. = "<center>"
@@ -550,25 +547,26 @@
. += "</center>"
. += "<HR>"
if(current_tab == 0)
if(current_tab == 1)
. += "<table><tr><td width='340px' height='300px' valign='top'>"
. += "<h2>Citadel Preferences</h2>"
. += "<b>Arousal:</b><a href='?_src_=prefs;preference=arousable'>[arousable == TRUE ? "Enabled" : "Disabled"]</a><BR>"
. += "<b>Exhibitionist:</b><a href='?_src_=prefs;preference=exhibitionist'>[features["exhibitionist"] == TRUE ? "Yes" : "No"]</a><BR>"
// game prefs
if(current_tab == 1)
//VORE SOUNDS
. += "<b>Hear Vore Sounds:</b> <a href='?_src_=prefs;preference=toggleeatingnoise'>[(toggles & EATING_NOISES) ? "Yes" : "No"]</a><br>"
. += "<b>Hear Vore Digestion Sounds:</b> <a href='?_src_=prefs;preference=toggledigestionnoise'>[(toggles & DIGESTION_NOISES) ? "Yes" : "No"]</a><br>"
. += "<b>Allow MediHound sleeper:</b> <a href='?_src_=prefs;preference=hound_sleeper'>[(cit_toggles & MEDIHOUND_SLEEPER) ? "Yes" : "No"]</a><br>"
. += "<b>Hear Vore Sounds:</b> <a href='?_src_=prefs;preference=toggleeatingnoise'>[(cit_toggles & EATING_NOISES) ? "Yes" : "No"]</a><br>"
. += "<b>Hear Vore Digestion Sounds:</b> <a href='?_src_=prefs;preference=toggledigestionnoise'>[(cit_toggles & DIGESTION_NOISES) ? "Yes" : "No"]</a><br>"
. += "<b>Widescreen:</b> <a href='?_src_=prefs;preference=widescreenpref'>[widescreenpref ? "Enabled ([CONFIG_GET(string/default_view)])" : "Disabled (15x15)"]</a><br>"
. += "<b>Auto stand:</b> <a href='?_src_=prefs;preference=autostand'>[autostand ? "Enabled" : "Disabled"]</a><br>"
. += "<b>Screen Shake:</b> <a href='?_src_=prefs;preference=screenshake'>[(screenshake==100) ? "Full" : ((screenshake==0) ? "None" : "[screenshake]")]</a><br>"
if (user && user.client && !user.client.prefs.screenshake==0)
. += "<b>Damage Screen Shake:</b> <a href='?_src_=prefs;preference=damagescreenshake'>[(damagescreenshake==1) ? "On" : ((damagescreenshake==0) ? "Off" : "Only when down")]</a><br>"
. += "</td></tr></table>"
//Character Appearance
if(current_tab == 2)
. += "<table><tr><td width='340px' height='300px' valign='top'>"
. += "<div class='statusDisplay'><img src=previewicon.png width=[preview_icon.Width()] height=[preview_icon.Height()]></div><br>"
. += "<div class='statusDisplay'><img src=previewicondatpng width=[preview_icon.Width()] height=[preview_icon.Height()]></div><br>"
. += "<a href='?_src_=prefs;preference=flavor_text;task=input'><b>Set Flavor Text</b></a><br>"
if(lentext(features["flavor_text"]) <= 40)
if(!lentext(features["flavor_text"]))
@@ -695,6 +693,7 @@
. += "</td>"
*/
. += "</td></tr></table>"
if(current_tab == 3)
if(!gear_tab)
gear_tab = GLOB.loadout_items[1]
@@ -767,7 +766,7 @@
datum/preferences/copy_to(mob/living/carbon/human/character, icon_updates = 1)
..()
character.give_genitals(TRUE)
character.flavor_text = features["flavor_text"] //Let's update their flavor_text at least initially
character.flavor_text = features["flavor_text"] //Let's up.e their flavor_text at least initially
character.canbearoused = arousable
if(icon_updates)
character.update_genitals()
@@ -1,6 +1,9 @@
/datum/preferences/proc/cit_character_pref_load(savefile/S)
//ipcs
S["feature_ipc_screen"] >> features["ipc_screen"]
//Citadel toggles
S["cit_toggles"] >> cit_toggles
features["ipc_screen"] = sanitize_inlist(features["ipc_screen"], GLOB.ipc_screens_list)
//Citadel
@@ -11,6 +14,7 @@
features["mcolor3"] = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F")
features["mcolor2"] = sanitize_hexcolor(features["mcolor2"], 3, 0)
features["mcolor3"] = sanitize_hexcolor(features["mcolor3"], 3, 0)
cit_toggles = sanitize_integer(toggles, 0, 65535, initial(toggles))
//gear loadout
var/text_to_load
@@ -69,6 +73,8 @@
//flavor text
WRITE_FILE(S["feature_flavor_text"], features["flavor_text"])
WRITE_FILE(S["cit_toggles"], cit_toggles)
//gear loadout
if(islist(chosen_gear))
if(chosen_gear.len)
@@ -2,35 +2,35 @@ TOGGLE_CHECKBOX(/datum/verbs/menu/Settings/Sound, toggleeatingnoise)()
set name = "Toggle Eating Noises"
set category = "Preferences"
set desc = "Hear Eating noises"
usr.client.prefs.toggles ^= EATING_NOISES
usr.client.prefs.cit_toggles ^= EATING_NOISES
usr.client.prefs.save_preferences()
usr.stop_sound_channel(CHANNEL_PRED)
to_chat(usr, "You will [(usr.client.prefs.toggles & EATING_NOISES) ? "now" : "no longer"] hear eating noises.")
to_chat(usr, "You will [(usr.client.prefs.cit_toggles & EATING_NOISES) ? "now" : "no longer"] hear eating noises.")
/datum/verbs/menu/Settings/Sound/toggleeatingnoise/Get_checked(client/C)
return !(C.prefs.toggles & EATING_NOISES)
return C.prefs.cit_toggles & EATING_NOISES
TOGGLE_CHECKBOX(/datum/verbs/menu/Settings/Sound, toggledigestionnoise)()
set name = "Toggle Digestion Noises"
set category = "Preferences"
set desc = "Hear digestive noises"
usr.client.prefs.toggles ^= DIGESTION_NOISES
usr.client.prefs.cit_toggles ^= DIGESTION_NOISES
usr.client.prefs.save_preferences()
usr.stop_sound_channel(CHANNEL_DIGEST)
to_chat(usr, "You will [(usr.client.prefs.toggles & DIGESTION_NOISES) ? "now" : "no longer"] hear digestion noises.")
to_chat(usr, "You will [(usr.client.prefs.cit_toggles & DIGESTION_NOISES) ? "now" : "no longer"] hear digestion noises.")
/datum/verbs/menu/Settings/Sound/toggledigestionnoise/Get_checked(client/C)
return !(C.prefs.toggles & DIGESTION_NOISES)
return C.prefs.cit_toggles & DIGESTION_NOISES
TOGGLE_CHECKBOX(/datum/verbs/menu/Settings/Sound, togglehoundsleeper)()
set name = "Allow/Deny Hound Sleeper"
set category = "Preferences"
set desc = "Allow MediHound Sleepers"
usr.client.prefs.toggles ^= MEDIHOUND_SLEEPER
usr.client.prefs.cit_toggles ^= MEDIHOUND_SLEEPER
usr.client.prefs.save_preferences()
if(usr.client.prefs.toggles & MEDIHOUND_SLEEPER)
if(usr.client.prefs.cit_toggles & MEDIHOUND_SLEEPER)
to_chat(usr, "You will now allow MediHounds to place you in their sleeper.")
else
to_chat(usr, "You will no longer allow MediHounds to place you in their sleeper.")
SSblackbox.record_feedback("nested tally", "preferences_verb", 1, list("Toggle MediHound Sleeper", "[usr.client.prefs.toggles & MEDIHOUND_SLEEPER ? "Enabled" : "Disabled"]")) //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
SSblackbox.record_feedback("nested tally", "preferences_verb", 1, list("Toggle MediHound Sleeper", "[usr.client.prefs.cit_toggles & MEDIHOUND_SLEEPER ? "Enabled" : "Disabled"]")) //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/datum/verbs/menu/Settings/Sound/togglehoundsleeper/Get_checked(client/C)
return C.prefs.toggles & MEDIHOUND_SLEEPER
return C.prefs.cit_toggles & MEDIHOUND_SLEEPER