Merge pull request #4417 from tigercat2000/bay_equipping

Bay/Polaris loadouts
This commit is contained in:
TheDZD
2016-07-02 19:26:21 -04:00
committed by GitHub
26 changed files with 2845 additions and 2125 deletions
@@ -0,0 +1,113 @@
/datum/gear_tweak/proc/get_contents(var/metadata)
return
/datum/gear_tweak/proc/get_metadata(var/user, var/metadata)
return
/datum/gear_tweak/proc/get_default()
return
/datum/gear_tweak/proc/tweak_gear_data(var/metadata, var/datum/gear_data)
return
/datum/gear_tweak/proc/tweak_item(var/obj/item/I, var/metadata)
return
/*
* Color adjustment
*/
var/datum/gear_tweak/color/gear_tweak_free_color_choice = new()
/datum/gear_tweak/color
var/list/valid_colors
/datum/gear_tweak/color/New(var/list/colors)
valid_colors = colors
..()
/datum/gear_tweak/color/get_contents(var/metadata)
return "Color: <font color='[metadata]'>&#9899;</font>"
/datum/gear_tweak/color/get_default()
return valid_colors ? valid_colors[1] : COLOR_GRAY
/datum/gear_tweak/color/get_metadata(var/user, var/metadata)
if(valid_colors)
return input(user, "Choose an item color.", "Character Preference", metadata) as null|anything in valid_colors
return input(user, "Choose an item color.", "Global Preference", metadata) as color|null
/datum/gear_tweak/color/tweak_item(var/obj/item/I, var/metadata)
if(valid_colors && !(metadata in valid_colors))
return
I.color = metadata
/*
* Path adjustment
*/
/datum/gear_tweak/path
var/list/valid_paths
/datum/gear_tweak/path/New(var/list/paths)
valid_paths = paths
..()
/datum/gear_tweak/path/get_contents(var/metadata)
return "Type: [metadata]"
/datum/gear_tweak/path/get_default()
return valid_paths[1]
/datum/gear_tweak/path/get_metadata(var/user, var/metadata)
return input(user, "Choose a type.", "Character Preference", metadata) as null|anything in valid_paths
/datum/gear_tweak/path/tweak_gear_data(var/metadata, var/datum/gear_data/gear_data)
if(!(metadata in valid_paths))
return
gear_data.path = valid_paths[metadata]
/*
* Content adjustment
*/
/datum/gear_tweak/contents
var/list/valid_contents
/datum/gear_tweak/contents/New()
valid_contents = args.Copy()
..()
/datum/gear_tweak/contents/get_contents(var/metadata)
return "Contents: [english_list(metadata, and_text = ", ")]"
/datum/gear_tweak/contents/get_default()
. = list()
for(var/i = 1 to valid_contents.len)
. += "Random"
/datum/gear_tweak/contents/get_metadata(var/user, var/list/metadata)
. = list()
for(var/i = metadata.len to valid_contents.len)
metadata += "Random"
for(var/i = 1 to valid_contents.len)
var/entry = input(user, "Choose an entry.", "Character Preference", metadata[i]) as null|anything in (valid_contents[i] + list("Random", "None"))
if(entry)
. += entry
else
return metadata
/datum/gear_tweak/contents/tweak_item(var/obj/item/I, var/list/metadata)
if(metadata.len != valid_contents.len)
return
for(var/i = 1 to valid_contents.len)
var/path
var/list/contents = valid_contents[i]
if(metadata[i] == "Random")
path = pick(contents)
path = contents[path]
else if(metadata[i] == "None")
continue
else
path = contents[metadata[i]]
new path(I)
@@ -0,0 +1,79 @@
var/list/loadout_categories = list()
var/list/gear_datums = list()
/datum/loadout_category
var/category = ""
var/list/gear = list()
/datum/loadout_category/New(cat)
category = cat
..()
/hook/startup/proc/populate_gear_list()
//create a list of gear datums to sort
for(var/geartype in subtypesof(/datum/gear))
var/datum/gear/G = geartype
var/use_name = initial(G.display_name)
var/use_category = initial(G.sort_category)
if(G == initial(G.subtype_path))
continue
if(!use_name)
error("Loadout - Missing display name: [G]")
continue
if(!initial(G.cost))
error("Loadout - Missing cost: [G]")
continue
if(!initial(G.path))
error("Loadout - Missing path definition: [G]")
continue
if(!loadout_categories[use_category])
loadout_categories[use_category] = new /datum/loadout_category(use_category)
var/datum/loadout_category/LC = loadout_categories[use_category]
gear_datums[use_name] = new geartype
LC.gear[use_name] = gear_datums[use_name]
loadout_categories = sortAssoc(loadout_categories)
for(var/loadout_category in loadout_categories)
var/datum/loadout_category/LC = loadout_categories[loadout_category]
LC.gear = sortAssoc(LC.gear)
return 1
/datum/gear
var/display_name //Name/index. Must be unique.
var/description //Description of this gear. If left blank will default to the description of the pathed item.
var/path //Path to item.
var/cost = 1 //Number of points used. Items in general cost 1 point, storage/armor/gloves/special use costs 2 points.
var/slot //Slot to equip to.
var/list/allowed_roles //Roles that can spawn with this item.
var/whitelisted //Term to check the whitelist for..
var/sort_category = "General"
var/list/gear_tweaks = list() //List of datums which will alter the item after it has been spawned.
var/subtype_path = /datum/gear //for skipping organizational subtypes (optional)
var/subtype_cost_overlap = TRUE //if subtypes can take points at the same time
/datum/gear/New()
..()
if(!description)
var/obj/O = path
description = initial(O.desc)
/datum/gear_data
var/path
var/location
/datum/gear_data/New(npath, nlocation)
path = npath
location = nlocation
/datum/gear/proc/spawn_item(location, metadata)
var/datum/gear_data/gd = new(path, location)
for(var/datum/gear_tweak/gt in gear_tweaks)
gt.tweak_gear_data(metadata["[gt]"], gd)
var/item = new gd.path(gd.location)
for(var/datum/gear_tweak/gt in gear_tweaks)
gt.tweak_item(item, metadata["[gt]"])
return item
@@ -0,0 +1,64 @@
/datum/gear/accessory
subtype_path = /datum/gear/accessory
slot = slot_tie
sort_category = "Accessories"
/datum/gear/accessory/scarf
display_name = "scarf"
path = /obj/item/clothing/accessory/scarf
/datum/gear/accessory/scarf/red
display_name = "scarf, red"
path = /obj/item/clothing/accessory/scarf/red
/datum/gear/accessory/scarf/green
display_name = "scarf, green"
path = /obj/item/clothing/accessory/scarf/green
/datum/gear/accessory/scarf/darkblue
display_name = "scarf, dark blue"
path = /obj/item/clothing/accessory/scarf/darkblue
/datum/gear/accessory/scarf/purple
display_name = "scarf, purple"
path = /obj/item/clothing/accessory/scarf/purple
/datum/gear/accessory/scarf/yellow
display_name = "scarf, yellow"
path = /obj/item/clothing/accessory/scarf/yellow
/datum/gear/accessory/scarf/orange
display_name = "scarf, orange"
path = /obj/item/clothing/accessory/scarf/orange
/datum/gear/accessory/scarf/lightblue
display_name = "scarf, light blue"
path = /obj/item/clothing/accessory/scarf/lightblue
/datum/gear/accessory/scarf/white
display_name = "scarf, white"
path = /obj/item/clothing/accessory/scarf/white
/datum/gear/accessory/scarf/black
display_name = "scarf, black"
path = /obj/item/clothing/accessory/scarf/black
/datum/gear/accessory/scarf/zebra
display_name = "scarf, zebra"
path = /obj/item/clothing/accessory/scarf/zebra
/datum/gear/accessory/scarf/christmas
display_name = "scarf, christmas"
path = /obj/item/clothing/accessory/scarf/christmas
/datum/gear/accessory/scarf/stripedred
display_name = "scarf, striped red"
path = /obj/item/clothing/accessory/stripedredscarf
/datum/gear/accessory/scarf/stripedgreen
display_name = "scarf, striped green"
path = /obj/item/clothing/accessory/stripedgreenscarf
/datum/gear/accessory/scarf/stripedblue
display_name = "scarf, striped blue"
path = /obj/item/clothing/accessory/stripedbluescarf
@@ -0,0 +1,16 @@
/datum/gear/lipstick
display_name = "lipstick, black"
path = /obj/item/weapon/lipstick/black
sort_category = "Cosmetics"
/datum/gear/lipstick/jade
display_name = "lipstick, jade"
path = /obj/item/weapon/lipstick/jade
/datum/gear/lipstick/purple
display_name = "lipstick, purple"
path = /obj/item/weapon/lipstick/purple
/datum/gear/lipstick/red
display_name = "lipstick, red"
path = /obj/item/weapon/lipstick
@@ -0,0 +1,3 @@
/datum/gear/dice
display_name = "d20"
path = /obj/item/weapon/dice/d20
@@ -0,0 +1,99 @@
// Uniform slot
/datum/gear/uniform
subtype_path = /datum/gear/uniform
slot = slot_w_uniform
sort_category = "Uniforms and Casual Dress"
/datum/gear/uniform/skirt
display_name = "skirt"
/datum/gear/uniform/skirt
display_name = "plaid skirt, blue"
path = /obj/item/clothing/under/dress/plaid_blue
/datum/gear/uniform/skirt/purple
display_name = "plaid skirt, purple"
path = /obj/item/clothing/under/dress/plaid_purple
/datum/gear/uniform/skirt/red
display_name = "plaid skirt, red"
path = /obj/item/clothing/under/dress/plaid_red
/datum/gear/uniform/skirt/black
display_name = "skirt, black"
path = /obj/item/clothing/under/blackskirt
/datum/gear/uniform/skirt/job
cost = 3
subtype_path = /datum/gear/uniform/skirt/job
subtype_cost_overlap = FALSE
/datum/gear/uniform/skirt/job/ce
display_name = "skirt, ce"
path = /obj/item/clothing/under/rank/chief_engineer/skirt
allowed_roles = list("Chief Engineer")
/datum/gear/uniform/skirt/job/atmos
display_name = "skirt, atmos"
path = /obj/item/clothing/under/rank/atmospheric_technician/skirt
allowed_roles = list("Chief Engineer","Atmospheric Technician")
/datum/gear/uniform/skirt/job/eng
display_name = "skirt, engineer"
path = /obj/item/clothing/under/rank/engineer/skirt
allowed_roles = list("Chief Engineer","Station Engineer")
/datum/gear/uniform/skirt/job/roboticist
display_name = "skirt, roboticist"
path = /obj/item/clothing/under/rank/roboticist/skirt
allowed_roles = list("Research Director","Roboticist")
/datum/gear/uniform/skirt/job/cmo
display_name = "skirt, cmo"
path = /obj/item/clothing/under/rank/chief_medical_officer
allowed_roles = list("Chief Medical Officer")
/datum/gear/uniform/skirt/job/chem
display_name = "skirt, chemist"
path = /obj/item/clothing/under/rank/chemist/skirt
allowed_roles = list("Chief Medical Officer","Chemist")
/datum/gear/uniform/skirt/job/viro
display_name = "skirt, virologist"
path = /obj/item/clothing/under/rank/virologist/skirt
allowed_roles = list("Chief Medical Officer","Medical Doctor")
/datum/gear/uniform/skirt/job/med
display_name = "skirt, medical"
path = /obj/item/clothing/under/rank/medical/skirt
allowed_roles = list("Chief Medical Officer","Medical Doctor","Chemist","Psychiatrist","Paramedic")
/datum/gear/uniform/skirt/job/sci
display_name = "skirt, scientist"
path = /obj/item/clothing/under/rank/scientist/skirt
allowed_roles = list("Research Director","Scientist")
/datum/gear/uniform/skirt/job/cargo
display_name = "skirt, cargo"
path = /obj/item/clothing/under/rank/cargotech/skirt
allowed_roles = list("Quartermaster","Cargo Technician")
/datum/gear/uniform/skirt/job/qm
display_name = "skirt, QM"
path = /obj/item/clothing/under/rank/cargo/skirt
allowed_roles = list("Quartermaster")
/datum/gear/uniform/skirt/job/warden
display_name = "skirt, warden"
path = /obj/item/clothing/under/rank/warden/skirt
allowed_roles = list("Head of Security", "Warden")
/datum/gear/uniform/skirt/job/security
display_name = "skirt, security"
path = /obj/item/clothing/under/rank/security/skirt
allowed_roles = list("Head of Security", "Warden", "Detective", "Security Officer")
/datum/gear/uniform/skirt/job/head_of_security
display_name = "skirt, hos"
path = /obj/item/clothing/under/rank/head_of_security/skirt
allowed_roles = list("Head of Security")
File diff suppressed because it is too large Load Diff
@@ -158,7 +158,8 @@
nanotrasen_relation,
speciesprefs,
socks,
body_accessory
body_accessory,
gear
FROM [format_table_name("characters")] WHERE ckey='[C.ckey]' AND slot='[slot]'"})
if(!query.Execute())
var/err = query.ErrorMsg()
@@ -236,6 +237,7 @@
//socks
socks = query.item[58]
body_accessory = query.item[59]
gear = params2list(query.item[60])
//Sanitize
metadata = sanitize_text(metadata, initial(metadata))
@@ -298,6 +300,7 @@
if(!player_alt_titles) player_alt_titles = new()
if(!organ_data) src.organ_data = list()
if(!rlimb_data) src.rlimb_data = list()
if(!gear) gear = list()
return 1
@@ -305,12 +308,15 @@
var/organlist
var/rlimblist
var/playertitlelist
var/gearlist
if(!isemptylist(organ_data))
organlist = list2params(organ_data)
if(!isemptylist(rlimb_data))
rlimblist = list2params(rlimb_data)
if(!isemptylist(player_alt_titles))
playertitlelist = list2params(player_alt_titles)
if(!isemptylist(gear))
gearlist = list2params(gear)
var/DBQuery/firstquery = dbcon.NewQuery("SELECT slot FROM [format_table_name("characters")] WHERE ckey='[C.ckey]' ORDER BY slot")
firstquery.Execute()
@@ -374,7 +380,8 @@
nanotrasen_relation='[nanotrasen_relation]',
speciesprefs='[speciesprefs]',
socks='[socks]',
body_accessory='[body_accessory]'
body_accessory='[body_accessory]',
gear='[gearlist]'
WHERE ckey='[C.ckey]'
AND slot='[default_slot]'"}
)
@@ -405,7 +412,7 @@
flavor_text, med_record, sec_record, gen_record,
player_alt_titles,
disabilities, organ_data, rlimb_data, nanotrasen_relation, speciesprefs,
socks, body_accessory)
socks, body_accessory, gear)
VALUES
('[C.ckey]', '[default_slot]', '[sql_sanitize_text(metadata)]', '[sql_sanitize_text(real_name)]', '[be_random_name]','[gender]',
@@ -426,7 +433,7 @@
'[sql_sanitize_text(html_encode(flavor_text))]', '[sql_sanitize_text(html_encode(med_record))]', '[sql_sanitize_text(html_encode(sec_record))]', '[sql_sanitize_text(html_encode(gen_record))]',
'[playertitlelist]',
'[disabilities]', '[organlist]', '[rlimblist]', '[nanotrasen_relation]', '[speciesprefs]',
'[socks]', '[body_accessory]')
'[socks]', '[body_accessory]', '[gearlist]')
"}
)
@@ -1,216 +1,216 @@
//toggles
/client/verb/toggle_ghost_ears()
set name = "Show/Hide GhostEars"
set category = "Preferences"
set desc = ".Toggle Between seeing all mob speech, and only speech of nearby mobs"
prefs.toggles ^= CHAT_GHOSTEARS
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTEARS) ? "see all speech in the world" : "only see speech from nearby mobs"].")
prefs.save_preferences(src)
feedback_add_details("admin_verb","TGE") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_ghost_sight()
set name = "Show/Hide GhostSight"
set category = "Preferences"
set desc = ".Toggle Between seeing all mob emotes, and only emotes of nearby mobs"
prefs.toggles ^= CHAT_GHOSTSIGHT
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTSIGHT) ? "see all emotes in the world" : "only see emotes from nearby mobs"].")
prefs.save_preferences(src)
feedback_add_details("admin_verb","TGS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_ghost_radio()
set name = "Enable/Disable GhostRadio"
set category = "Preferences"
set desc = ".Toggle between hearing all radio chatter, or only from nearby speakers"
prefs.toggles ^= CHAT_GHOSTRADIO
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTRADIO) ? "hear all radio chat in the world" : "only hear from nearby speakers"].")
prefs.save_preferences(src)
feedback_add_details("admin_verb","TGR")
/client/proc/toggle_hear_radio()
set name = "Show/Hide RadioChatter"
set category = "Preferences"
set desc = "Toggle seeing radiochatter from radios and speakers"
if(!holder) return
prefs.toggles ^= CHAT_RADIO
prefs.save_preferences(src)
to_chat(usr, "You will [(prefs.toggles & CHAT_RADIO) ? "now" : "no longer"] see radio chatter from radios or speakers")
feedback_add_details("admin_verb","THR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggleadminhelpsound()
set name = "Hear/Silence Adminhelps"
set category = "Preferences"
set desc = "Toggle hearing a notification when admin PMs are recieved"
if(!holder) return
prefs.sound ^= SOUND_ADMINHELP
prefs.save_preferences(src)
to_chat(usr, "You will [(prefs.sound & SOUND_ADMINHELP) ? "now" : "no longer"] hear a sound when adminhelps arrive.")
feedback_add_details("admin_verb","AHS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/deadchat() // Deadchat toggle is usable by anyone.
set name = "Show/Hide Deadchat"
set category = "Preferences"
set desc ="Toggles seeing deadchat"
prefs.toggles ^= CHAT_DEAD
prefs.save_preferences(src)
if(src.holder)
to_chat(src, "You will [(prefs.toggles & CHAT_DEAD) ? "now" : "no longer"] see deadchat.")
else
to_chat(src, "As a ghost, you will [(prefs.toggles & CHAT_DEAD) ? "now" : "no longer"] see deadchat.")
feedback_add_details("admin_verb","TDV") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/toggleprayers()
set name = "Show/Hide Prayers"
set category = "Preferences"
set desc = "Toggles seeing prayers"
prefs.toggles ^= CHAT_PRAYER
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & CHAT_PRAYER) ? "now" : "no longer"] see prayerchat.")
feedback_add_details("admin_verb","TP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/togglescoreboard()
set name = "Hide/Display End Round Scoreboard"
set category = "Preferences"
set desc = "Toggles displaying end of round scoreboard"
prefs.toggles ^= DISABLE_SCOREBOARD
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & DISABLE_SCOREBOARD) ? "no longer" : "now"] see the end of round scoreboard.")
feedback_add_details("admin_verb","TScoreboard") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/togglekarmareminder()
set name = "Hide/Display End Round Karma Reminder"
set category = "Preferences"
set desc = "Toggles displaying end of round karma reminder"
prefs.toggles ^= DISABLE_KARMA_REMINDER
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & DISABLE_KARMA_REMINDER) ? "no longer" : "now"] see the end of round karma reminder.")
feedback_add_details("admin_verb","TKarmabugger") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggletitlemusic()
set name = "Hear/Silence LobbyMusic"
set category = "Preferences"
set desc = "Toggles hearing the GameLobby music"
prefs.sound ^= SOUND_LOBBY
prefs.save_preferences(src)
if(prefs.sound & SOUND_LOBBY)
to_chat(src, "You will now hear music in the game lobby.")
if(istype(mob, /mob/new_player))
playtitlemusic()
else
to_chat(src, "You will no longer hear music in the game lobby.")
if(istype(mob, /mob/new_player))
src << sound(null, repeat = 0, wait = 0, volume = 85, channel = 1)// stop the jamsz
feedback_add_details("admin_verb","TLobby") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/togglemidis()
set name = "Hear/Silence Midis"
set category = "Preferences"
set desc = "Toggles hearing sounds uploaded by admins"
prefs.sound ^= SOUND_MIDI
prefs.save_preferences(src)
if(prefs.sound & SOUND_MIDI)
to_chat(src, "You will now hear any sounds uploaded by admins.")
else
var/sound/break_sound = sound(null, repeat = 0, wait = 0, channel = 777)
break_sound.priority = 250
src << break_sound//breaks the client's sound output on channel 777
to_chat(src, "You will no longer hear sounds uploaded by admins; any currently playing midis have been disabled.")
feedback_add_details("admin_verb","TMidi") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/listen_ooc()
set name = "Show/Hide OOC"
set category = "Preferences"
set desc = "Toggles seeing OutOfCharacter chat"
prefs.toggles ^= CHAT_OOC
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & CHAT_OOC) ? "now" : "no longer"] see messages on the OOC channel.")
feedback_add_details("admin_verb","TOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/listen_looc()
set name = "Show/Hide LOOC"
set category = "Preferences"
set desc = "Toggles seeing Local OutOfCharacter chat"
prefs.toggles ^= CHAT_LOOC
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & CHAT_LOOC) ? "now" : "no longer"] see messages on the LOOC channel.")
feedback_add_details("admin_verb","TLOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/Toggle_Soundscape() //All new ambience should be added here so it works with this verb until someone better at things comes up with a fix that isn't awful
set name = "Hear/Silence Ambience"
set category = "Preferences"
set desc = "Toggles hearing ambient sound effects"
prefs.sound ^= SOUND_AMBIENCE
prefs.save_preferences(src)
if(prefs.sound & SOUND_AMBIENCE)
to_chat(src, "You will now hear ambient sounds.")
else
to_chat(src, "You will no longer hear ambient sounds.")
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 1)
feedback_add_details("admin_verb","TAmbi") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/Toggle_Buzz() //No more headaches because headphones bump up shipambience.ogg to insanity levels.
set name = "Hear/Silence White Noise"
set category = "Preferences"
set desc = "Toggles hearing ambient white noise"
prefs.sound ^= SOUND_BUZZ
prefs.save_preferences(src)
if(prefs.sound & SOUND_BUZZ)
to_chat(src, "You will now hear ambient white noise.")
else
to_chat(src, "You will no longer hear ambient white noise.")
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 2)
feedback_add_details("admin_verb","TBuzz") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/Toggle_Heartbeat() //to toggle off heartbeat sounds, in case they get too annoying
set name = "Hear/Silence Heartbeat"
set category = "Preferences"
set desc = "Toggles hearing heart beating sound effects"
prefs.sound ^= SOUND_HEARTBEAT
prefs.save_preferences(src)
if(prefs.sound & SOUND_HEARTBEAT)
to_chat(src, "You will now hear heartbeat sounds.")
else
to_chat(src, "You will no longer hear heartbeat sounds.")
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 1)
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 2)
feedback_add_details("admin_verb","Thb") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
// This needs a toggle because you people are awful and spammed terrible music
/client/verb/toggle_instruments()
set name = "Hear/Silence Instruments"
set category = "Preferences"
set desc = "Toggles hearing musical instruments like the violin and piano"
prefs.sound ^= SOUND_INSTRUMENTS
prefs.save_preferences(src)
if(prefs.sound & SOUND_INSTRUMENTS)
to_chat(src, "You will now hear people playing musical instruments.")
else
to_chat(src, "You will no longer hear musical instruments.")
feedback_add_details("admin_verb","TInstru") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_media()
set name = "Hear/Silence Streaming"
set category = "Preferences"
set desc = "Toggle hearing streaming media (radios, jukeboxes, etc)"
prefs.sound ^= SOUND_STREAMING
prefs.save_preferences(src)
to_chat(usr, "You will [(prefs.sound & SOUND_STREAMING) ? "now" : "no longer"] hear streamed media.")
if(!media) return
if(prefs.sound & SOUND_STREAMING)
media.update_music()
else
media.stop_music()
/client/verb/setup_character()
set name = "Game Preferences"
set category = "Preferences"
set desc = "Allows you to access the Setup Character screen. Changes to your character won't take effect until next round, but other changes will."
prefs.current_tab = 1
//toggles
/client/verb/toggle_ghost_ears()
set name = "Show/Hide GhostEars"
set category = "Preferences"
set desc = ".Toggle Between seeing all mob speech, and only speech of nearby mobs"
prefs.toggles ^= CHAT_GHOSTEARS
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTEARS) ? "see all speech in the world" : "only see speech from nearby mobs"].")
prefs.save_preferences(src)
feedback_add_details("admin_verb","TGE") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_ghost_sight()
set name = "Show/Hide GhostSight"
set category = "Preferences"
set desc = ".Toggle Between seeing all mob emotes, and only emotes of nearby mobs"
prefs.toggles ^= CHAT_GHOSTSIGHT
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTSIGHT) ? "see all emotes in the world" : "only see emotes from nearby mobs"].")
prefs.save_preferences(src)
feedback_add_details("admin_verb","TGS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_ghost_radio()
set name = "Enable/Disable GhostRadio"
set category = "Preferences"
set desc = ".Toggle between hearing all radio chatter, or only from nearby speakers"
prefs.toggles ^= CHAT_GHOSTRADIO
to_chat(src, "As a ghost, you will now [(prefs.toggles & CHAT_GHOSTRADIO) ? "hear all radio chat in the world" : "only hear from nearby speakers"].")
prefs.save_preferences(src)
feedback_add_details("admin_verb","TGR")
/client/proc/toggle_hear_radio()
set name = "Show/Hide RadioChatter"
set category = "Preferences"
set desc = "Toggle seeing radiochatter from radios and speakers"
if(!holder) return
prefs.toggles ^= CHAT_RADIO
prefs.save_preferences(src)
to_chat(usr, "You will [(prefs.toggles & CHAT_RADIO) ? "now" : "no longer"] see radio chatter from radios or speakers")
feedback_add_details("admin_verb","THR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggleadminhelpsound()
set name = "Hear/Silence Adminhelps"
set category = "Preferences"
set desc = "Toggle hearing a notification when admin PMs are recieved"
if(!holder) return
prefs.sound ^= SOUND_ADMINHELP
prefs.save_preferences(src)
to_chat(usr, "You will [(prefs.sound & SOUND_ADMINHELP) ? "now" : "no longer"] hear a sound when adminhelps arrive.")
feedback_add_details("admin_verb","AHS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/deadchat() // Deadchat toggle is usable by anyone.
set name = "Show/Hide Deadchat"
set category = "Preferences"
set desc ="Toggles seeing deadchat"
prefs.toggles ^= CHAT_DEAD
prefs.save_preferences(src)
if(src.holder)
to_chat(src, "You will [(prefs.toggles & CHAT_DEAD) ? "now" : "no longer"] see deadchat.")
else
to_chat(src, "As a ghost, you will [(prefs.toggles & CHAT_DEAD) ? "now" : "no longer"] see deadchat.")
feedback_add_details("admin_verb","TDV") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/toggleprayers()
set name = "Show/Hide Prayers"
set category = "Preferences"
set desc = "Toggles seeing prayers"
prefs.toggles ^= CHAT_PRAYER
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & CHAT_PRAYER) ? "now" : "no longer"] see prayerchat.")
feedback_add_details("admin_verb","TP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/togglescoreboard()
set name = "Hide/Display End Round Scoreboard"
set category = "Preferences"
set desc = "Toggles displaying end of round scoreboard"
prefs.toggles ^= DISABLE_SCOREBOARD
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & DISABLE_SCOREBOARD) ? "no longer" : "now"] see the end of round scoreboard.")
feedback_add_details("admin_verb","TScoreboard") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/togglekarmareminder()
set name = "Hide/Display End Round Karma Reminder"
set category = "Preferences"
set desc = "Toggles displaying end of round karma reminder"
prefs.toggles ^= DISABLE_KARMA_REMINDER
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & DISABLE_KARMA_REMINDER) ? "no longer" : "now"] see the end of round karma reminder.")
feedback_add_details("admin_verb","TKarmabugger") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggletitlemusic()
set name = "Hear/Silence LobbyMusic"
set category = "Preferences"
set desc = "Toggles hearing the GameLobby music"
prefs.sound ^= SOUND_LOBBY
prefs.save_preferences(src)
if(prefs.sound & SOUND_LOBBY)
to_chat(src, "You will now hear music in the game lobby.")
if(istype(mob, /mob/new_player))
playtitlemusic()
else
to_chat(src, "You will no longer hear music in the game lobby.")
if(istype(mob, /mob/new_player))
src << sound(null, repeat = 0, wait = 0, volume = 85, channel = 1)// stop the jamsz
feedback_add_details("admin_verb","TLobby") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/togglemidis()
set name = "Hear/Silence Midis"
set category = "Preferences"
set desc = "Toggles hearing sounds uploaded by admins"
prefs.sound ^= SOUND_MIDI
prefs.save_preferences(src)
if(prefs.sound & SOUND_MIDI)
to_chat(src, "You will now hear any sounds uploaded by admins.")
else
var/sound/break_sound = sound(null, repeat = 0, wait = 0, channel = 777)
break_sound.priority = 250
src << break_sound //breaks the client's sound output on channel 777
to_chat(src, "You will no longer hear sounds uploaded by admins; any currently playing midis have been disabled.")
feedback_add_details("admin_verb","TMidi") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/listen_ooc()
set name = "Show/Hide OOC"
set category = "Preferences"
set desc = "Toggles seeing OutOfCharacter chat"
prefs.toggles ^= CHAT_OOC
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & CHAT_OOC) ? "now" : "no longer"] see messages on the OOC channel.")
feedback_add_details("admin_verb","TOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/listen_looc()
set name = "Show/Hide LOOC"
set category = "Preferences"
set desc = "Toggles seeing Local OutOfCharacter chat"
prefs.toggles ^= CHAT_LOOC
prefs.save_preferences(src)
to_chat(src, "You will [(prefs.toggles & CHAT_LOOC) ? "now" : "no longer"] see messages on the LOOC channel.")
feedback_add_details("admin_verb","TLOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/Toggle_Soundscape() //All new ambience should be added here so it works with this verb until someone better at things comes up with a fix that isn't awful
set name = "Hear/Silence Ambience"
set category = "Preferences"
set desc = "Toggles hearing ambient sound effects"
prefs.sound ^= SOUND_AMBIENCE
prefs.save_preferences(src)
if(prefs.sound & SOUND_AMBIENCE)
to_chat(src, "You will now hear ambient sounds.")
else
to_chat(src, "You will no longer hear ambient sounds.")
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 1)
feedback_add_details("admin_verb","TAmbi") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/Toggle_Buzz() //No more headaches because headphones bump up shipambience.ogg to insanity levels.
set name = "Hear/Silence White Noise"
set category = "Preferences"
set desc = "Toggles hearing ambient white noise"
prefs.sound ^= SOUND_BUZZ
prefs.save_preferences(src)
if(prefs.sound & SOUND_BUZZ)
to_chat(src, "You will now hear ambient white noise.")
else
to_chat(src, "You will no longer hear ambient white noise.")
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 2)
feedback_add_details("admin_verb","TBuzz") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/Toggle_Heartbeat() //to toggle off heartbeat sounds, in case they get too annoying
set name = "Hear/Silence Heartbeat"
set category = "Preferences"
set desc = "Toggles hearing heart beating sound effects"
prefs.sound ^= SOUND_HEARTBEAT
prefs.save_preferences(src)
if(prefs.sound & SOUND_HEARTBEAT)
to_chat(src, "You will now hear heartbeat sounds.")
else
to_chat(src, "You will no longer hear heartbeat sounds.")
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 1)
src << sound(null, repeat = 0, wait = 0, volume = 0, channel = 2)
feedback_add_details("admin_verb","Thb") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
// This needs a toggle because you people are awful and spammed terrible music
/client/verb/toggle_instruments()
set name = "Hear/Silence Instruments"
set category = "Preferences"
set desc = "Toggles hearing musical instruments like the violin and piano"
prefs.sound ^= SOUND_INSTRUMENTS
prefs.save_preferences(src)
if(prefs.sound & SOUND_INSTRUMENTS)
to_chat(src, "You will now hear people playing musical instruments.")
else
to_chat(src, "You will no longer hear musical instruments.")
feedback_add_details("admin_verb","TInstru") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_media()
set name = "Hear/Silence Streaming"
set category = "Preferences"
set desc = "Toggle hearing streaming media (radios, jukeboxes, etc)"
prefs.sound ^= SOUND_STREAMING
prefs.save_preferences(src)
to_chat(usr, "You will [(prefs.sound & SOUND_STREAMING) ? "now" : "no longer"] hear streamed media.")
if(!media) return
if(prefs.sound & SOUND_STREAMING)
media.update_music()
else
media.stop_music()
/client/verb/setup_character()
set name = "Game Preferences"
set category = "Preferences"
set desc = "Allows you to access the Setup Character screen. Changes to your character won't take effect until next round, but other changes will."
prefs.current_tab = 1
prefs.ShowChoices(usr)