You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

729 lines
31 KiB

  1. /datum/admins/proc/Secrets()
  2. if(!check_rights(0))
  3. return
  4. var/list/dat = list("<B>The first rule of adminbuse is: you don't talk about the adminbuse.</B><HR>")
  5. dat +={"
  6. <B>General Secrets</B><BR>
  7. <BR>
  8. <A href='?src=[REF(src)];[HrefToken()];secrets=admin_log'>Admin Log</A><BR>
  9. <A href='?src=[REF(src)];[HrefToken()];secrets=show_admins'>Show Admin List</A><BR>
  10. <BR>
  11. "}
  12. if(check_rights(R_ADMIN,0))
  13. dat += {"
  14. <B>Admin Secrets</B><BR>
  15. <BR>
  16. <A href='?src=[REF(src)];[HrefToken()];secrets=clear_virus'>Cure all diseases currently in existence</A><BR>
  17. <A href='?src=[REF(src)];[HrefToken()];secrets=list_bombers'>Bombing List</A><BR>
  18. <A href='?src=[REF(src)];[HrefToken()];secrets=list_signalers'>Show last [length(GLOB.lastsignalers)] signalers</A><BR>
  19. <A href='?src=[REF(src)];[HrefToken()];secrets=list_lawchanges'>Show last [length(GLOB.lawchanges)] law changes</A><BR>
  20. <A href='?src=[REF(src)];[HrefToken()];secrets=showailaws'>Show AI Laws</A><BR>
  21. <A href='?src=[REF(src)];[HrefToken()];secrets=showgm'>Show Game Mode</A><BR>
  22. <A href='?src=[REF(src)];[HrefToken()];secrets=manifest'>Show Crew Manifest</A><BR>
  23. <A href='?src=[REF(src)];[HrefToken()];secrets=DNA'>List DNA (Blood)</A><BR>
  24. <A href='?src=[REF(src)];[HrefToken()];secrets=fingerprints'>List Fingerprints</A><BR>
  25. <A href='?src=[REF(src)];[HrefToken()];secrets=ctfbutton'>Enable/Disable CTF</A><BR><BR>
  26. <A href='?src=[REF(src)];[HrefToken()];secrets=tdomereset'>Reset Thunderdome to default state</A><BR>
  27. <A href='?src=[REF(src)];[HrefToken()];secrets=set_name'>Rename Station Name</A><BR>
  28. <A href='?src=[REF(src)];[HrefToken()];secrets=reset_name'>Reset Station Name</A><BR>
  29. <A href='?src=[REF(src)];[HrefToken()];secrets=night_shift_set'>Set Night Shift Mode</A><BR>
  30. <BR>
  31. <B>Shuttles</B><BR>
  32. <BR>
  33. <A href='?src=[REF(src)];[HrefToken()];secrets=moveferry'>Move Ferry</A><BR>
  34. <A href='?src=[REF(src)];[HrefToken()];secrets=togglearrivals'>Toggle Arrivals Ferry</A><BR>
  35. <A href='?src=[REF(src)];[HrefToken()];secrets=moveminingshuttle'>Move Mining Shuttle</A><BR>
  36. <A href='?src=[REF(src)];[HrefToken()];secrets=movelaborshuttle'>Move Labor Shuttle</A><BR>
  37. <BR>
  38. "}
  39. if(check_rights(R_FUN,0))
  40. dat += {"
  41. <B>Fun Secrets</B><BR>
  42. <BR>
  43. <A href='?src=[REF(src)];[HrefToken()];secrets=virus'>Trigger a Virus Outbreak</A><BR>
  44. <A href='?src=[REF(src)];[HrefToken()];secrets=monkey'>Turn all humans into monkeys</A><BR>
  45. <A href='?src=[REF(src)];[HrefToken()];secrets=anime'>Chinese Cartoons</A><BR>
  46. <A href='?src=[REF(src)];[HrefToken()];secrets=allspecies'>Change the species of all humans</A><BR>
  47. <A href='?src=[REF(src)];[HrefToken()];secrets=power'>Make all areas powered</A><BR>
  48. <A href='?src=[REF(src)];[HrefToken()];secrets=unpower'>Make all areas unpowered</A><BR>
  49. <A href='?src=[REF(src)];[HrefToken()];secrets=quickpower'>Power all SMES</A><BR>
  50. <A href='?src=[REF(src)];[HrefToken()];secrets=tripleAI'>Triple AI mode (needs to be used in the lobby)</A><BR>
  51. <A href='?src=[REF(src)];[HrefToken()];secrets=traitor_all'>Everyone is the traitor</A><BR>
  52. <A href='?src=[REF(src)];[HrefToken()];secrets=guns'>Summon Guns</A><BR>
  53. <A href='?src=[REF(src)];[HrefToken()];secrets=magic'>Summon Magic</A><BR>
  54. <A href='?src=[REF(src)];[HrefToken()];secrets=events'>Summon Events (Toggle)</A><BR>
  55. <A href='?src=[REF(src)];[HrefToken()];secrets=onlyone'>There can only be one!</A><BR>
  56. <A href='?src=[REF(src)];[HrefToken()];secrets=delayed_onlyone'>There can only be one! (40-second delay)</A><BR>
  57. <A href='?src=[REF(src)];[HrefToken()];secrets=retardify'>Make all players retarded</A><BR>
  58. <A href='?src=[REF(src)];[HrefToken()];secrets=eagles'>Egalitarian Station Mode</A><BR>
  59. <A href='?src=[REF(src)];[HrefToken()];secrets=ancap'>Anarcho-Capitalist Station Mode</A><BR>
  60. <A href='?src=[REF(src)];[HrefToken()];secrets=blackout'>Break all lights</A><BR>
  61. <A href='?src=[REF(src)];[HrefToken()];secrets=whiteout'>Fix all lights</A><BR>
  62. <A href='?src=[REF(src)];[HrefToken()];secrets=floorlava'>The floor is lava! (DANGEROUS: extremely lame)</A><BR>
  63. <A href='?src=[REF(src)];[HrefToken()];secrets=customportal'>Spawn a custom portal storm</A><BR>
  64. <BR>
  65. <A href='?src=[REF(src)];[HrefToken()];secrets=changebombcap'>Change bomb cap</A><BR>
  66. <A href='?src=[REF(src)];[HrefToken()];secrets=masspurrbation'>Mass Purrbation</A><BR>
  67. <A href='?src=[REF(src)];[HrefToken()];secrets=massremovepurrbation'>Mass Remove Purrbation</A><BR>
  68. <A href='?src=[REF(src)];[HrefToken()];secrets=massimmerse'>Fully Immerse Everyone</A><BR>
  69. <A href='?src=[REF(src)];[HrefToken()];secrets=unmassimmerse'>Un-Fully Immerse Everyone</A><BR>
  70. "}
  71. dat += "<BR>"
  72. if(check_rights(R_DEBUG,0))
  73. dat += {"
  74. <B>Security Level Elevated</B><BR>
  75. <BR>
  76. <A href='?src=[REF(src)];[HrefToken()];secrets=maint_access_engiebrig'>Change all maintenance doors to engie/brig access only</A><BR>
  77. <A href='?src=[REF(src)];[HrefToken()];secrets=maint_access_brig'>Change all maintenance doors to brig access only</A><BR>
  78. <A href='?src=[REF(src)];[HrefToken()];secrets=infinite_sec'>Remove cap on security officers</A><BR>
  79. <BR>
  80. "}
  81. usr << browse(dat.Join(), "window=secrets")
  82. return
  83. /datum/admins/proc/Secrets_topic(item,href_list)
  84. var/datum/round_event/E
  85. var/ok = 0
  86. switch(item)
  87. if("admin_log")
  88. var/dat = "<B>Admin Log<HR></B>"
  89. for(var/l in GLOB.admin_log)
  90. dat += "<li>[l]</li>"
  91. if(!GLOB.admin_log.len)
  92. dat += "No-one has done anything this round!"
  93. usr << browse(dat, "window=admin_log")
  94. if("show_admins")
  95. var/dat = "<B>Current admins:</B><HR>"
  96. if(GLOB.admin_datums)
  97. for(var/ckey in GLOB.admin_datums)
  98. var/datum/admins/D = GLOB.admin_datums[ckey]
  99. dat += "[ckey] - [D.rank.name]<br>"
  100. usr << browse(dat, "window=showadmins;size=600x500")
  101. if("tdomereset")
  102. if(!check_rights(R_ADMIN))
  103. return
  104. var/delete_mobs = alert("Clear all mobs?","Confirm","Yes","No","Cancel")
  105. if(delete_mobs == "Cancel")
  106. return
  107. log_admin("[key_name(usr)] reset the thunderdome to default with delete_mobs==[delete_mobs].", 1)
  108. message_admins("<span class='adminnotice'>[key_name_admin(usr)] reset the thunderdome to default with delete_mobs==[delete_mobs].</span>")
  109. var/area/thunderdome = GLOB.areas_by_type[/area/tdome/arena]
  110. if(delete_mobs == "Yes")
  111. for(var/mob/living/mob in thunderdome)
  112. qdel(mob) //Clear mobs
  113. for(var/obj/obj in thunderdome)
  114. if(!istype(obj, /obj/machinery/camera) && !istype(obj, /obj/effect/abstract/proximity_checker))
  115. qdel(obj) //Clear objects
  116. var/area/template = GLOB.areas_by_type[/area/tdome/arena_source]
  117. template.copy_contents_to(thunderdome)
  118. if("clear_virus")
  119. var/choice = input("Are you sure you want to cure all disease?") in list("Yes", "Cancel")
  120. if(choice == "Yes")
  121. message_admins("[key_name_admin(usr)] has cured all diseases.")
  122. for(var/thing in SSdisease.active_diseases)
  123. var/datum/disease/D = thing
  124. D.cure(0)
  125. if("set_name")
  126. if(!check_rights(R_ADMIN))
  127. return
  128. var/new_name = input(usr, "Please input a new name for the station.", "What?", "") as text|null
  129. if(!new_name)
  130. return
  131. set_station_name(new_name)
  132. log_admin("[key_name(usr)] renamed the station to \"[new_name]\".")
  133. message_admins("<span class='adminnotice'>[key_name_admin(usr)] renamed the station to: [new_name].</span>")
  134. priority_announce("[command_name()] has renamed the station to \"[new_name]\".")
  135. if("night_shift_set")
  136. if(!check_rights(R_ADMIN))
  137. return
  138. var/val = alert(usr, "What do you want to set night shift to? This will override the automatic system until set to automatic again.", "Night Shift", "On", "Off", "Automatic")
  139. switch(val)
  140. if("Automatic")
  141. if(CONFIG_GET(flag/enable_night_shifts))
  142. SSnightshift.can_fire = TRUE
  143. SSnightshift.fire()
  144. else
  145. SSnightshift.update_nightshift(FALSE, TRUE)
  146. if("On")
  147. SSnightshift.can_fire = FALSE
  148. SSnightshift.update_nightshift(TRUE, TRUE)
  149. if("Off")
  150. SSnightshift.can_fire = FALSE
  151. SSnightshift.update_nightshift(FALSE, TRUE)
  152. if("reset_name")
  153. if(!check_rights(R_ADMIN))
  154. return
  155. var/new_name = new_station_name()
  156. set_station_name(new_name)
  157. log_admin("[key_name(usr)] reset the station name.")
  158. message_admins("<span class='adminnotice'>[key_name_admin(usr)] reset the station name.</span>")
  159. priority_announce("[command_name()] has renamed the station to \"[new_name]\".")
  160. if("list_bombers")
  161. if(!check_rights(R_ADMIN))
  162. return
  163. var/dat = "<B>Bombing List</B><HR>"
  164. for(var/l in GLOB.bombers)
  165. dat += text("[l]<BR>")
  166. usr << browse(dat, "window=bombers")
  167. if("list_signalers")
  168. if(!check_rights(R_ADMIN))
  169. return
  170. var/dat = "<B>Showing last [length(GLOB.lastsignalers)] signalers.</B><HR>"
  171. for(var/sig in GLOB.lastsignalers)
  172. dat += "[sig]<BR>"
  173. usr << browse(dat, "window=lastsignalers;size=800x500")
  174. if("list_lawchanges")
  175. if(!check_rights(R_ADMIN))
  176. return
  177. var/dat = "<B>Showing last [length(GLOB.lawchanges)] law changes.</B><HR>"
  178. for(var/sig in GLOB.lawchanges)
  179. dat += "[sig]<BR>"
  180. usr << browse(dat, "window=lawchanges;size=800x500")
  181. if("moveminingshuttle")
  182. if(!check_rights(R_ADMIN))
  183. return
  184. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Send Mining Shuttle"))
  185. if(!SSshuttle.toggleShuttle("mining","mining_home","mining_away"))
  186. message_admins("[key_name_admin(usr)] moved mining shuttle")
  187. log_admin("[key_name(usr)] moved the mining shuttle")
  188. if("movelaborshuttle")
  189. if(!check_rights(R_ADMIN))
  190. return
  191. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Send Labor Shuttle"))
  192. if(!SSshuttle.toggleShuttle("laborcamp","laborcamp_home","laborcamp_away"))
  193. message_admins("[key_name_admin(usr)] moved labor shuttle")
  194. log_admin("[key_name(usr)] moved the labor shuttle")
  195. if("moveferry")
  196. if(!check_rights(R_ADMIN))
  197. return
  198. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Send CentCom Ferry"))
  199. if(!SSshuttle.toggleShuttle("ferry","ferry_home","ferry_away"))
  200. message_admins("[key_name_admin(usr)] moved the CentCom ferry")
  201. log_admin("[key_name(usr)] moved the CentCom ferry")
  202. if("togglearrivals")
  203. if(!check_rights(R_ADMIN))
  204. return
  205. var/obj/docking_port/mobile/arrivals/A = SSshuttle.arrivals
  206. if(A)
  207. var/new_perma = !A.perma_docked
  208. A.perma_docked = new_perma
  209. SSblackbox.record_feedback("nested tally", "admin_toggle", 1, list("Permadock Arrivals Shuttle", "[new_perma ? "Enabled" : "Disabled"]"))
  210. message_admins("[key_name_admin(usr)] [new_perma ? "stopped" : "started"] the arrivals shuttle")
  211. log_admin("[key_name(usr)] [new_perma ? "stopped" : "started"] the arrivals shuttle")
  212. else
  213. to_chat(usr, "<span class='admin'>There is no arrivals shuttle.</span>", confidential = TRUE)
  214. if("showailaws")
  215. if(!check_rights(R_ADMIN))
  216. return
  217. output_ai_laws()
  218. if("showgm")
  219. if(!check_rights(R_ADMIN))
  220. return
  221. if(!SSticker.HasRoundStarted())
  222. alert("The game hasn't started yet!")
  223. else if (SSticker.mode)
  224. alert("The game mode is [SSticker.mode.name]")
  225. else alert("For some reason there's a SSticker, but not a game mode")
  226. if("manifest")
  227. if(!check_rights(R_ADMIN))
  228. return
  229. var/dat = "<B>Showing Crew Manifest.</B><HR>"
  230. dat += "<table cellspacing=5><tr><th>Name</th><th>Position</th></tr>"
  231. for(var/datum/data/record/t in GLOB.data_core.general)
  232. dat += "<tr><td>[t.fields["name"]]</td><td>[t.fields["rank"]]</td></tr>"
  233. dat += "</table>"
  234. usr << browse(dat, "window=manifest;size=440x410")
  235. if("DNA")
  236. if(!check_rights(R_ADMIN))
  237. return
  238. var/dat = "<B>Showing DNA from blood.</B><HR>"
  239. dat += "<table cellspacing=5><tr><th>Name</th><th>DNA</th><th>Blood Type</th></tr>"
  240. for(var/i in GLOB.human_list)
  241. var/mob/living/carbon/human/H = i
  242. if(H.ckey)
  243. dat += "<tr><td>[H]</td><td>[H.dna.unique_enzymes]</td><td>[H.dna.blood_type]</td></tr>"
  244. dat += "</table>"
  245. usr << browse(dat, "window=DNA;size=440x410")
  246. if("fingerprints")
  247. if(!check_rights(R_ADMIN))
  248. return
  249. var/dat = "<B>Showing Fingerprints.</B><HR>"
  250. dat += "<table cellspacing=5><tr><th>Name</th><th>Fingerprints</th></tr>"
  251. for(var/i in GLOB.human_list)
  252. var/mob/living/carbon/human/H = i
  253. if(H.ckey)
  254. dat += "<tr><td>[H]</td><td>[md5(H.dna.uni_identity)]</td></tr>"
  255. dat += "</table>"
  256. usr << browse(dat, "window=fingerprints;size=440x410")
  257. if("monkey")
  258. if(!check_rights(R_FUN))
  259. return
  260. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Monkeyize All Humans"))
  261. for(var/i in GLOB.human_list)
  262. var/mob/living/carbon/human/H = i
  263. INVOKE_ASYNC(H, /mob/living/carbon.proc/monkeyize)
  264. ok = 1
  265. if("allspecies")
  266. if(!check_rights(R_FUN))
  267. return
  268. var/result = input(usr, "Please choose a new species","Species") as null|anything in GLOB.species_list
  269. if(result)
  270. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Mass Species Change", "[result]"))
  271. log_admin("[key_name(usr)] turned all humans into [result]", 1)
  272. message_admins("\blue [key_name_admin(usr)] turned all humans into [result]")
  273. var/newtype = GLOB.species_list[result]
  274. for(var/i in GLOB.human_list)
  275. var/mob/living/carbon/human/H = i
  276. H.set_species(newtype)
  277. if("tripleAI")
  278. if(!check_rights(R_FUN))
  279. return
  280. usr.client.triple_ai()
  281. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Triple AI"))
  282. if("power")
  283. if(!check_rights(R_FUN))
  284. return
  285. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Power All APCs"))
  286. log_admin("[key_name(usr)] made all areas powered", 1)
  287. message_admins("<span class='adminnotice'>[key_name_admin(usr)] made all areas powered</span>")
  288. power_restore()
  289. if("unpower")
  290. if(!check_rights(R_FUN))
  291. return
  292. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Depower All APCs"))
  293. log_admin("[key_name(usr)] made all areas unpowered", 1)
  294. message_admins("<span class='adminnotice'>[key_name_admin(usr)] made all areas unpowered</span>")
  295. power_failure()
  296. if("quickpower")
  297. if(!check_rights(R_FUN))
  298. return
  299. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Power All SMESs"))
  300. log_admin("[key_name(usr)] made all SMESs powered", 1)
  301. message_admins("<span class='adminnotice'>[key_name_admin(usr)] made all SMESs powered</span>")
  302. power_restore_quick()
  303. if("traitor_all")
  304. if(!check_rights(R_FUN))
  305. return
  306. if(!SSticker.HasRoundStarted())
  307. alert("The game hasn't started yet!")
  308. return
  309. var/objective = stripped_input(usr, "Enter an objective")
  310. if(!objective)
  311. return
  312. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Traitor All", "[objective]"))
  313. for(var/mob/living/H in GLOB.player_list)
  314. if(!(ishuman(H)||istype(H, /mob/living/silicon/)))
  315. continue
  316. if(H.stat == DEAD || !H.mind || ispAI(H))
  317. continue
  318. if(is_special_character(H))
  319. continue
  320. var/datum/antagonist/traitor/T = new()
  321. T.give_objectives = FALSE
  322. var/datum/objective/new_objective = new
  323. new_objective.owner = H
  324. new_objective.explanation_text = objective
  325. T.add_objective(new_objective)
  326. H.mind.add_antag_datum(T)
  327. message_admins("<span class='adminnotice'>[key_name_admin(usr)] used everyone is a traitor secret. Objective is [objective]</span>")
  328. log_admin("[key_name(usr)] used everyone is a traitor secret. Objective is [objective]")
  329. if("changebombcap")
  330. if(!check_rights(R_FUN))
  331. return
  332. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Bomb Cap"))
  333. var/newBombCap = input(usr,"What would you like the new bomb cap to be. (entered as the light damage range (the 3rd number in common (1,2,3) notation)) Must be above 4)", "New Bomb Cap", GLOB.MAX_EX_LIGHT_RANGE) as num|null
  334. if (!CONFIG_SET(number/bombcap, newBombCap))
  335. return
  336. message_admins("<span class='boldannounce'>[key_name_admin(usr)] changed the bomb cap to [GLOB.MAX_EX_DEVESTATION_RANGE], [GLOB.MAX_EX_HEAVY_RANGE], [GLOB.MAX_EX_LIGHT_RANGE]</span>")
  337. log_admin("[key_name(usr)] changed the bomb cap to [GLOB.MAX_EX_DEVESTATION_RANGE], [GLOB.MAX_EX_HEAVY_RANGE], [GLOB.MAX_EX_LIGHT_RANGE]")
  338. if("blackout")
  339. if(!check_rights(R_FUN))
  340. return
  341. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Break All Lights"))
  342. message_admins("[key_name_admin(usr)] broke all lights")
  343. for(var/obj/machinery/light/L in GLOB.machines)
  344. L.break_light_tube()
  345. if("anime")
  346. if(!check_rights(R_FUN))
  347. return
  348. var/animetype = alert("Would you like to have the clothes be changed?",,"Yes","No","Cancel")
  349. var/droptype
  350. if(animetype =="Yes")
  351. droptype = alert("Make the uniforms Nodrop?",,"Yes","No","Cancel")
  352. if(animetype == "Cancel" || droptype == "Cancel")
  353. return
  354. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Chinese Cartoons"))
  355. message_admins("[key_name_admin(usr)] made everything kawaii.")
  356. for(var/i in GLOB.human_list)
  357. var/mob/living/carbon/human/H = i
  358. SEND_SOUND(H, sound('sound/ai/animes.ogg'))
  359. if(H.dna.species.id == "human")
  360. if(H.dna.features["tail_human"] == "None" || H.dna.features["ears"] == "None")
  361. var/obj/item/organ/ears/cat/ears = new
  362. var/obj/item/organ/tail/cat/tail = new
  363. ears.Insert(H, drop_if_replaced=FALSE)
  364. tail.Insert(H, drop_if_replaced=FALSE)
  365. var/list/honorifics = list("[MALE]" = list("kun"), "[FEMALE]" = list("chan","tan"), "[NEUTER]" = list("san"), "[PLURAL]" = list("san")) //John Robust -> Robust-kun
  366. var/list/names = splittext(H.real_name," ")
  367. var/forename = names.len > 1 ? names[2] : names[1]
  368. var/newname = "[forename]-[pick(honorifics["[H.gender]"])]"
  369. H.fully_replace_character_name(H.real_name,newname)
  370. H.update_mutant_bodyparts()
  371. if(animetype == "Yes")
  372. var/seifuku = pick(typesof(/obj/item/clothing/under/costume/schoolgirl))
  373. var/obj/item/clothing/under/costume/schoolgirl/I = new seifuku
  374. var/olduniform = H.w_uniform
  375. H.temporarilyRemoveItemFromInventory(H.w_uniform, TRUE, FALSE)
  376. H.equip_to_slot_or_del(I, ITEM_SLOT_ICLOTHING)
  377. qdel(olduniform)
  378. if(droptype == "Yes")
  379. ADD_TRAIT(I, TRAIT_NODROP, ADMIN_TRAIT)
  380. else
  381. to_chat(H, "<span class='warning'>You're not kawaii enough for this!</span>", confidential = TRUE)
  382. if("whiteout")
  383. if(!check_rights(R_FUN))
  384. return
  385. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Fix All Lights"))
  386. message_admins("[key_name_admin(usr)] fixed all lights")
  387. for(var/obj/machinery/light/L in GLOB.machines)
  388. L.fix()
  389. if("floorlava")
  390. SSweather.run_weather(/datum/weather/floor_is_lava)
  391. if("virus")
  392. if(!check_rights(R_FUN))
  393. return
  394. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Virus Outbreak"))
  395. switch(alert("Do you want this to be a random disease or do you have something in mind?",,"Make Your Own","Random","Choose"))
  396. if("Make Your Own")
  397. AdminCreateVirus(usr.client)
  398. if("Random")
  399. var/datum/round_event_control/disease_outbreak/DC = locate(/datum/round_event_control/disease_outbreak) in SSevents.control
  400. E = DC.runEvent()
  401. if("Choose")
  402. var/virus = input("Choose the virus to spread", "BIOHAZARD") as null|anything in sortList(typesof(/datum/disease), /proc/cmp_typepaths_asc)
  403. var/datum/round_event_control/disease_outbreak/DC = locate(/datum/round_event_control/disease_outbreak) in SSevents.control
  404. var/datum/round_event/disease_outbreak/DO = DC.runEvent()
  405. DO.virus_type = virus
  406. E = DO
  407. if("retardify")
  408. if(!check_rights(R_FUN))
  409. return
  410. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Mass Braindamage"))
  411. for(var/mob/living/carbon/human/H in GLOB.player_list)
  412. to_chat(H, "<span class='boldannounce'>You suddenly feel stupid.</span>", confidential = TRUE)
  413. H.adjustOrganLoss(ORGAN_SLOT_BRAIN, 60, 80)
  414. message_admins("[key_name_admin(usr)] made everybody retarded")
  415. if("eagles")//SCRAW
  416. if(!check_rights(R_FUN))
  417. return
  418. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Egalitarian Station"))
  419. for(var/obj/machinery/door/airlock/W in GLOB.machines)
  420. if(is_station_level(W.z) && !istype(get_area(W), /area/bridge) && !istype(get_area(W), /area/crew_quarters) && !istype(get_area(W), /area/security/prison))
  421. W.req_access = list()
  422. message_admins("[key_name_admin(usr)] activated Egalitarian Station mode")
  423. priority_announce("CentCom airlock control override activated. Please take this time to get acquainted with your coworkers.", null, 'sound/ai/commandreport.ogg')
  424. if("ancap")
  425. if(!check_rights(R_FUN))
  426. return
  427. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Anarcho-capitalist Station"))
  428. SSeconomy.full_ancap = !SSeconomy.full_ancap
  429. message_admins("[key_name_admin(usr)] toggled Anarcho-capitalist mode")
  430. if(SSeconomy.full_ancap)
  431. priority_announce("The NAP is now in full effect.", null, 'sound/ai/commandreport.ogg')
  432. else
  433. priority_announce("The NAP has been revoked.", null, 'sound/ai/commandreport.ogg')
  434. if("guns")
  435. if(!check_rights(R_FUN))
  436. return
  437. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Guns"))
  438. var/survivor_probability = 0
  439. switch(alert("Do you want this to create survivors antagonists?",,"No Antags","Some Antags","All Antags!"))
  440. if("Some Antags")
  441. survivor_probability = 25
  442. if("All Antags!")
  443. survivor_probability = 100
  444. rightandwrong(SUMMON_GUNS, usr, survivor_probability)
  445. if("magic")
  446. if(!check_rights(R_FUN))
  447. return
  448. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Magic"))
  449. var/survivor_probability = 0
  450. switch(alert("Do you want this to create survivors antagonists?",,"No Antags","Some Antags","All Antags!"))
  451. if("Some Antags")
  452. survivor_probability = 25
  453. if("All Antags!")
  454. survivor_probability = 100
  455. rightandwrong(SUMMON_MAGIC, usr, survivor_probability)
  456. if("events")
  457. if(!check_rights(R_FUN))
  458. return
  459. if(!SSevents.wizardmode)
  460. if(alert("Do you want to toggle summon events on?",,"Yes","No") == "Yes")
  461. summonevents()
  462. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Events", "Activate"))
  463. else
  464. switch(alert("What would you like to do?",,"Intensify Summon Events","Turn Off Summon Events","Nothing"))
  465. if("Intensify Summon Events")
  466. summonevents()
  467. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Events", "Intensify"))
  468. if("Turn Off Summon Events")
  469. SSevents.toggleWizardmode()
  470. SSevents.resetFrequency()
  471. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Events", "Disable"))
  472. if("dorf")
  473. if(!check_rights(R_FUN))
  474. return
  475. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Dwarf Beards"))
  476. for(var/i in GLOB.human_list)
  477. var/mob/living/carbon/human/B = i
  478. B.facial_hairstyle = "Dward Beard"
  479. B.update_hair()
  480. message_admins("[key_name_admin(usr)] activated dorf mode")
  481. if("onlyone")
  482. if(!check_rights(R_FUN))
  483. return
  484. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("There Can Be Only One"))
  485. usr.client.only_one()
  486. sound_to_playing_players('sound/misc/highlander.ogg')
  487. if("delayed_onlyone")
  488. if(!check_rights(R_FUN))
  489. return
  490. SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("There Can Be Only One"))
  491. usr.client.only_one_delayed()
  492. sound_to_playing_players('sound/misc/highlander_delayed.ogg')
  493. if("maint_access_brig")
  494. if(!check_rights(R_DEBUG))
  495. return
  496. for(var/obj/machinery/door/airlock/maintenance/M in GLOB.machines)
  497. M.check_access()
  498. if (ACCESS_MAINT_TUNNELS in M.req_access)
  499. M.req_access = list(ACCESS_BRIG)
  500. message_admins("[key_name_admin(usr)] made all maint doors brig access-only.")
  501. if("maint_access_engiebrig")
  502. if(!check_rights(R_DEBUG))
  503. return
  504. for(var/obj/machinery/door/airlock/maintenance/M in GLOB.machines)
  505. M.check_access()
  506. if (ACCESS_MAINT_TUNNELS in M.req_access)
  507. M.req_access = list()
  508. M.req_one_access = list(ACCESS_BRIG,ACCESS_ENGINE)
  509. message_admins("[key_name_admin(usr)] made all maint doors engineering and brig access-only.")
  510. if("infinite_sec")
  511. if(!check_rights(R_DEBUG))
  512. return
  513. var/datum/job/J = SSjob.GetJob("Security Officer")
  514. if(!J)
  515. return
  516. J.total_positions = -1
  517. J.spawn_positions = -1
  518. message_admins("[key_name_admin(usr)] has removed the cap on security officers.")
  519. if("ctfbutton")
  520. if(!check_rights(R_ADMIN))
  521. return
  522. toggle_all_ctf(usr)
  523. if("masspurrbation")
  524. if(!check_rights(R_FUN))
  525. return
  526. mass_purrbation()
  527. message_admins("[key_name_admin(usr)] has put everyone on \
  528. purrbation!")
  529. log_admin("[key_name(usr)] has put everyone on purrbation.")
  530. if("massremovepurrbation")
  531. if(!check_rights(R_FUN))
  532. return
  533. mass_remove_purrbation()
  534. message_admins("[key_name_admin(usr)] has removed everyone from \
  535. purrbation.")
  536. log_admin("[key_name(usr)] has removed everyone from purrbation.")
  537. if("massimmerse")
  538. if(!check_rights(R_FUN))
  539. return
  540. mass_immerse()
  541. message_admins("[key_name_admin(usr)] has Fully Immersed \
  542. everyone!")
  543. log_admin("[key_name(usr)] has Fully Immersed everyone.")
  544. if("unmassimmerse")
  545. if(!check_rights(R_FUN))
  546. return
  547. mass_immerse(remove=TRUE)
  548. message_admins("[key_name_admin(usr)] has Un-Fully Immersed \
  549. everyone!")
  550. log_admin("[key_name(usr)] has Un-Fully Immersed everyone.")
  551. if("customportal")
  552. if(!check_rights(R_FUN))
  553. return
  554. var/list/settings = list(
  555. "mainsettings" = list(
  556. "typepath" = list("desc" = "Path to spawn", "type" = "datum", "path" = "/mob/living", "subtypesonly" = TRUE, "value" = /mob/living/simple_animal/hostile/poison/bees),
  557. "humanoutfit" = list("desc" = "Outfit if human", "type" = "datum", "path" = "/datum/outfit", "subtypesonly" = TRUE, "value" = /datum/outfit),
  558. "amount" = list("desc" = "Number per portal", "type" = "number", "value" = 1),
  559. "portalnum" = list("desc" = "Number of total portals", "type" = "number", "value" = 10),
  560. "offerghosts" = list("desc" = "Get ghosts to play mobs", "type" = "boolean", "value" = "No"),
  561. "minplayers" = list("desc" = "Minimum number of ghosts", "type" = "number", "value" = 1),
  562. "playersonly" = list("desc" = "Only spawn ghost-controlled mobs", "type" = "boolean", "value" = "No"),
  563. "ghostpoll" = list("desc" = "Ghost poll question", "type" = "string", "value" = "Do you want to play as %TYPE% portal invader?"),
  564. "delay" = list("desc" = "Time between portals, in deciseconds", "type" = "number", "value" = 50),
  565. "color" = list("desc" = "Portal color", "type" = "color", "value" = "#00FF00"),
  566. "playlightning" = list("desc" = "Play lightning sounds on announcement", "type" = "boolean", "value" = "Yes"),
  567. "announce_players" = list("desc" = "Make an announcement", "type" = "boolean", "value" = "Yes"),
  568. "announcement" = list("desc" = "Announcement", "type" = "string", "value" = "Massive bluespace anomaly detected en route to %STATION%. Brace for impact."),
  569. )
  570. )
  571. message_admins("[key_name(usr)] is creating a custom portal storm...")
  572. var/list/prefreturn = presentpreflikepicker(usr,"Customize Portal Storm", "Customize Portal Storm", Button1="Ok", width = 600, StealFocus = 1,Timeout = 0, settings=settings)
  573. if (prefreturn["button"] == 1)
  574. var/list/prefs = settings["mainsettings"]
  575. if (prefs["amount"]["value"] < 1 || prefs["portalnum"]["value"] < 1)
  576. to_chat(usr, "<span class='warning'>Number of portals and mobs to spawn must be at least 1.</span>", confidential = TRUE)
  577. return
  578. var/mob/pathToSpawn = prefs["typepath"]["value"]
  579. if (!ispath(pathToSpawn))
  580. pathToSpawn = text2path(pathToSpawn)
  581. if (!ispath(pathToSpawn))
  582. to_chat(usr, "<span class='notice'>Invalid path [pathToSpawn].</span>", confidential = TRUE)
  583. return
  584. var/list/candidates = list()
  585. if (prefs["offerghosts"]["value"] == "Yes")
  586. candidates = pollGhostCandidates(replacetext(prefs["ghostpoll"]["value"], "%TYPE%", initial(pathToSpawn.name)), ROLE_TRAITOR)
  587. if (prefs["playersonly"]["value"] == "Yes" && length(candidates) < prefs["minplayers"]["value"])
  588. message_admins("Not enough players signed up to create a portal storm, the minimum was [prefs["minplayers"]["value"]] and the number of signups [length(candidates)]")
  589. return
  590. if (prefs["announce_players"]["value"] == "Yes")
  591. portalAnnounce(prefs["announcement"]["value"], (prefs["playlightning"]["value"] == "Yes" ? TRUE : FALSE))
  592. var/mutable_appearance/storm = mutable_appearance('icons/obj/tesla_engine/energy_ball.dmi', "energy_ball_fast", FLY_LAYER)
  593. storm.color = prefs["color"]["value"]
  594. message_admins("[key_name_admin(usr)] has created a customized portal storm that will spawn [prefs["portalnum"]["value"]] portals, each of them spawning [prefs["amount"]["value"]] of [pathToSpawn]")
  595. log_admin("[key_name(usr)] has created a customized portal storm that will spawn [prefs["portalnum"]["value"]] portals, each of them spawning [prefs["amount"]["value"]] of [pathToSpawn]")
  596. var/outfit = prefs["humanoutfit"]["value"]
  597. if (!ispath(outfit))
  598. outfit = text2path(outfit)
  599. for (var/i in 1 to prefs["portalnum"]["value"])
  600. if (length(candidates)) // if we're spawning players, gotta be a little tricky and also not spawn players on top of NPCs
  601. var/ghostcandidates = list()
  602. for (var/j in 1 to min(prefs["amount"]["value"], length(candidates)))
  603. ghostcandidates += pick_n_take(candidates)
  604. addtimer(CALLBACK(GLOBAL_PROC, .proc/doPortalSpawn, get_random_station_turf(), pathToSpawn, length(ghostcandidates), storm, ghostcandidates, outfit), i*prefs["delay"]["value"])
  605. else if (prefs["playersonly"]["value"] != "Yes")
  606. addtimer(CALLBACK(GLOBAL_PROC, .proc/doPortalSpawn, get_random_station_turf(), pathToSpawn, prefs["amount"]["value"], storm, null, outfit), i*prefs["delay"]["value"])
  607. if(E)
  608. E.processing = FALSE
  609. if(E.announceWhen>0)
  610. switch(alert(usr, "Would you like to alert the crew?", "Alert", "Yes", "No", "Cancel"))
  611. if("Yes")
  612. E.announceChance = 100
  613. if("Cancel")
  614. E.kill()
  615. return
  616. if("No")
  617. E.announceChance = 0
  618. E.processing = TRUE
  619. if (usr)
  620. log_admin("[key_name(usr)] used secret [item]")
  621. if (ok)
  622. to_chat(world, text("<B>A secret has been activated by []!</B>", usr.key), confidential = TRUE)
  623. /proc/portalAnnounce(announcement, playlightning)
  624. set waitfor = 0
  625. if (playlightning)
  626. sound_to_playing_players('sound/magic/lightning_chargeup.ogg')
  627. sleep(80)
  628. priority_announce(replacetext(announcement, "%STATION%", station_name()))
  629. if (playlightning)
  630. sleep(20)
  631. sound_to_playing_players('sound/magic/lightningbolt.ogg')
  632. /proc/doPortalSpawn(turf/loc, mobtype, numtospawn, portal_appearance, players, humanoutfit)
  633. for (var/i in 1 to numtospawn)
  634. var/mob/spawnedMob = new mobtype(loc)
  635. if (length(players))
  636. var/mob/chosen = players[1]
  637. if (chosen.client)
  638. chosen.client.prefs.copy_to(spawnedMob)
  639. spawnedMob.key = chosen.key
  640. players -= chosen
  641. if (ishuman(spawnedMob) && ispath(humanoutfit, /datum/outfit))
  642. var/mob/living/carbon/human/H = spawnedMob
  643. H.equipOutfit(humanoutfit)
  644. var/turf/T = get_step(loc, SOUTHWEST)
  645. flick_overlay_static(portal_appearance, T, 15)
  646. playsound(T, 'sound/magic/lightningbolt.ogg', rand(80, 100), TRUE)