Merge pull request #1970 from Ikarrus/adminnotice

Admin Notices
This commit is contained in:
Cheridan
2013-12-08 10:32:45 -08:00
5 changed files with 47 additions and 1 deletions
+19
View File
@@ -537,6 +537,25 @@ var/global/floorIsLava = 0
log_admin("Announce: [key_name(usr)] : [message]")
feedback_add_details("admin_verb","A") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/datum/admins/proc/set_admin_notice()
set category = "Special Verbs"
set name = "Set Admin Notice"
set desc ="Set an announcement that appears to everyone who joins the server. Only lasts this round"
if(!check_rights(0)) return
admin_notice = input(src,"Set a public notice for this round. Everyone who joins the server will see it.\n(Leaving it blank will delete the current notice):","Set Notice",admin_notice) as null|message
switch(admin_notice)
if(null)
return
if("")
message_admins("[key_name(usr)] removed the admin notice.")
log_admin("[key_name(usr)] removed the admin notice:\n[admin_notice]")
return
message_admins("[key_name(usr)] set the admin notice.")
log_admin("[key_name(usr)] set the admin notice:\n[admin_notice]")
world << "\blue <b>Admin Notice:</b>\n \t [admin_notice]"
feedback_add_details("admin_verb","SAN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/datum/admins/proc/toggleooc()
set category = "Server"
set desc="Toggle dis bitch"
+2
View File
@@ -27,6 +27,7 @@ var/list/admin_verbs_admin = list(
/datum/admins/proc/toggleenter, /*toggles whether people can join the current game*/
/datum/admins/proc/toggleguests, /*toggles whether guests can join the current game*/
/datum/admins/proc/announce, /*priority announce something to all clients.*/
/datum/admins/proc/set_admin_notice,/*announcement all clients see when joining the server.*/
/client/proc/admin_ghost, /*allows us to ghost/reenter body at will*/
/client/proc/toggle_view_range, /*changes how far we can see*/
/datum/admins/proc/view_txt_log, /*shows the server log (diary) for today*/
@@ -138,6 +139,7 @@ var/list/admin_verbs_hideable = list(
/datum/admins/proc/toggleenter,
/datum/admins/proc/toggleguests,
/datum/admins/proc/announce,
/datum/admins/proc/set_admin_notice,
/client/proc/admin_ghost,
/client/proc/toggle_view_range,
/datum/admins/proc/view_txt_log,
+3
View File
@@ -3,6 +3,9 @@
if(join_motd)
src << "<div class=\"motd\">[join_motd]</div>"
if(admin_notice)
src << "\blue <b>Admin Notice:</b>\n \t [admin_notice]"
if(!mind)
mind = new /datum/mind(key)
mind.active = 1