Admin teleport update, further admin message fixes

This commit is contained in:
Markolie
2015-08-18 00:54:25 +02:00
parent 23237582a9
commit 4e8bb6d301
34 changed files with 155 additions and 126 deletions
+2 -1
View File
@@ -27,7 +27,8 @@
if( findtext(memo,"<script",1,0) )
return
F[ckey] << "[key] on [time2text(world.realtime,"(DDD) DD MMM hh:mm")]<br>[memo]"
message_admins("[key] set an admin memo:<br>[memo]")
log_admin("[key_name(usr)] set an admin memo:<br>[memo]")
message_admins("[key_name_admin(usr)] set an admin memo:<br>[memo]")
//show all memos
/client/proc/admin_memo_show()
+5 -5
View File
@@ -444,7 +444,7 @@ var/list/admin_verbs_mentor = list(
if(flash_range == null)
return
explosion(epicenter, devastation_range, heavy_impact_range, light_impact_range, flash_range, 1, 1)
message_admins("<span class='adminnotice'>[ckey] creating an admin explosion at [epicenter.loc].</span>")
message_admins("<span class='adminnotice'>[key_name_admin(usr)] creating an admin explosion at [epicenter.loc].</span>")
feedback_add_details("admin_verb","DB") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/give_spell(mob/T as mob in mob_list) // -- Urist
@@ -569,8 +569,8 @@ var/list/admin_verbs_mentor = list(
set category = "Admin"
if(holder)
log_admin("[src] deadmined themself.")
message_admins("[src] deadmined themself.")
log_admin("[key_name(usr)] deadmined themself.")
message_admins("[key_name_admin(usr)] deadmined themself.")
deadmin()
verbs += /client/proc/readmin
deadmins += ckey
@@ -614,8 +614,8 @@ var/list/admin_verbs_mentor = list(
D = new(rank,admin_ranks[rank],ckey)
var/client/C = directory[ckey]
D.associate(C)
message_admins("[src] re-adminned themselves.")
log_admin("[src] re-adminned themselves.")
message_admins("[key_name_admin(usr)] re-adminned themselves.")
log_admin("[key_name(usr)] re-adminned themselves.")
deadmins -= ckey
feedback_add_details("admin_verb","RAS")
return
+1 -1
View File
@@ -17,7 +17,7 @@
if(H.cl == M.client)
qdel(H)
else
message_admins("[key_name(usr)] has entered build mode.")
message_admins("[key_name_admin(usr)] has entered build mode.")
log_admin("[key_name(usr)] has entered build mode.")
M.client.buildmode = 1
M.client.show_popup_menus = 0
+17 -17
View File
@@ -3,7 +3,7 @@
if(usr.client != src.owner || !check_rights(0))
log_admin("[key_name(usr)] tried to use the admin panel without authorization.")
message_admins("[usr.key] has attempted to override the admin panel!")
message_admins("[key_name_admin(usr)] has attempted to override the admin panel!")
return
if(ticker.mode && ticker.mode.check_antagonists_topic(href, href_list))
@@ -124,7 +124,7 @@
if(bancid)
banreason = "[banreason] (CUSTOM CID)"
else
message_admins("Ban process: A mob matching [playermob.ckey] was found at location [playermob.x], [playermob.y], [playermob.z]. Custom ip and computer id fields replaced with the ip and computer id from the located mob")
message_admins("Ban process: A mob matching [playermob.ckey] was found at location [playermob.x], [playermob.y], [playermob.z]. Custom IP and computer id fields replaced with the IP and computer id from the located mob")
DB_ban_record(bantype, playermob, banduration, banreason, banjob, null, banckey, banip, bancid )
@@ -280,7 +280,7 @@
ticker.delay_end = !ticker.delay_end
log_admin("[key_name(usr)] [ticker.delay_end ? "delayed the round end" : "has made the round end normally"].")
message_admins("\blue [key_name(usr)] [ticker.delay_end ? "delayed the round end" : "has made the round end normally"].", 1)
message_admins("\blue [key_name_admin(usr)] [ticker.delay_end ? "delayed the round end" : "has made the round end normally"].", 1)
href_list["secretsadmin"] = "check_antagonist"
else if(href_list["simplemake"])
@@ -1002,8 +1002,8 @@
M << "\red To try to resolve this matter head to [config.banappeals]"
else
M << "\red No ban appeals URL has been set."
log_admin("[usr.client.ckey] has banned [M.ckey].\nReason: [reason]\nThis will be removed in [mins] minutes.")
message_admins("\blue[usr.client.ckey] has banned [M.ckey].\nReason: [reason]\nThis will be removed in [mins] minutes.")
log_admin("[key_name(usr)] has banned [M.ckey].\nReason: [reason]\nThis will be removed in [mins] minutes.")
message_admins("\blue [key_name_admin(usr)] has banned [M.ckey].\nReason: [reason]\nThis will be removed in [mins] minutes.")
del(M.client)
//del(M) // See no reason why to delete mob. Important stuff can be lost. And ban can be lifted before round ends.
@@ -1024,8 +1024,8 @@
else
M << "\red No ban appeals URL has been set."
ban_unban_log_save("[usr.client.ckey] has permabanned [M.ckey]. - Reason: [reason] - This is a permanent ban.")
log_admin("[usr.client.ckey] has banned [M.ckey].\nReason: [reason]\nThis is a permanent ban.")
message_admins("\blue[usr.client.ckey] has banned [M.ckey].\nReason: [reason]\nThis is a permanent ban.")
log_admin("[key_name(usr)] has banned [M.ckey].\nReason: [reason]\nThis is a permanent ban.")
message_admins("\blue[key_name_admin(usr)] has banned [M.ckey].\nReason: [reason]\nThis is a permanent ban.")
feedback_inc("ban_perma",1)
DB_ban_record(BANTYPE_PERMA, M, -1, reason)
@@ -1260,7 +1260,7 @@
return
log_admin("[key_name(usr)] has sent [key_name(M)] back to the Lobby.")
message_admins("[key_name(usr)] has sent [key_name(M)] back to the Lobby.")
message_admins("[key_name_admin(usr)] has sent [key_name_admin(M)] back to the Lobby.")
var/mob/new_player/NP = new()
NP.ckey = M.ckey
@@ -1412,7 +1412,7 @@
L.revive()
message_admins("\red Admin [key_name_admin(usr)] healed / revived [key_name_admin(L)]!", 1)
log_admin("[key_name(usr)] healed / Revived [key_name(L)]")
log_admin("[key_name(usr)] healed / revived [key_name(L)]")
else if(href_list["makeai"])
if(!check_rights(R_SPAWN)) return
@@ -1604,14 +1604,14 @@
H.equip_to_slot_or_del( new /obj/item/weapon/reagent_containers/food/snacks/cookie(H), slot_r_hand )
if(!(istype(H.r_hand,/obj/item/weapon/reagent_containers/food/snacks/cookie)))
log_admin("[key_name(H)] has their hands full, so they did not receive their cookie, spawned by [key_name(src.owner)].")
message_admins("[key_name(H)] has their hands full, so they did not receive their cookie, spawned by [key_name(src.owner)].")
message_admins("[key_name_admin(H)] has their hands full, so they did not receive their cookie, spawned by [key_name_admin(src.owner)].")
return
else
H.update_inv_r_hand()//To ensure the icon appears in the HUD
else
H.update_inv_l_hand()
log_admin("[key_name(H)] got their cookie, spawned by [key_name(src.owner)]")
message_admins("[key_name(H)] got their cookie, spawned by [key_name(src.owner)]")
message_admins("[key_name_admin(H)] got their cookie, spawned by [key_name_admin(src.owner)]")
feedback_inc("admin_cookies_spawned",1)
H << "\blue Your prayers have been answered!! You received the <b>best cookie</b>!"
@@ -1635,8 +1635,8 @@
BSACooldown = 0
M << "You've been hit by bluespace artillery!"
log_admin("[key_name(M)] has been hit by Bluespace Artillery fired by [src.owner]")
message_admins("[key_name(M)] has been hit by Bluespace Artillery fired by [src.owner]")
log_admin("[key_name(M)] has been hit by Bluespace Artillery fired by [key_name(src.owner)]")
message_admins("[key_name_admin(M)] has been hit by Bluespace Artillery fired by [key_name_admin(src.owner)]")
var/obj/effect/stop/S
S = new /obj/effect/stop
@@ -1674,8 +1674,8 @@
if(!input) return
src.owner << "You sent [input] to [H] via a secure channel."
log_admin("[src.owner] replied to [key_name(H)]'s Centcomm message with the message [input].")
message_admins("[src.owner] replied to [key_name(H)]'s Centcom message with: \"[input]\"")
log_admin("[key_name(src.owner)] replied to [key_name(H)]'s Centcomm message with the message [input].")
message_admins("[key_name_admin(src.owner)] replied to [key_name_admin(H)]'s Centcom message with: \"[input]\"")
H << "You hear something crackle in your headset for a moment before a voice speaks. \"Please stand by for a message from Central Command. Message as follows. [input]. Message ends.\""
else if(href_list["SyndicateReply"])
@@ -2392,11 +2392,11 @@
S.long_jump(origin_area, destination_area, transition_area, move_duration)
message_admins("\blue [key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] lasting [move_duration] seconds for the [shuttle_tag] shuttle", 1)
log_admin("[key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] lasting [move_duration] seconds for the [shuttle_tag] shuttle")
log_admin("[key_name(usr)] has initiated a jump from [origin_area] to [destination_area] lasting [move_duration] seconds for the [shuttle_tag] shuttle")
else
S.short_jump(origin_area, destination_area)
message_admins("\blue [key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] for the [shuttle_tag] shuttle", 1)
log_admin("[key_name_admin(usr)] has initiated a jump from [origin_area] to [destination_area] for the [shuttle_tag] shuttle")
log_admin("[key_name(usr)] has initiated a jump from [origin_area] to [destination_area] for the [shuttle_tag] shuttle")
if("moveshuttle")
+47 -32
View File
@@ -1,30 +1,39 @@
/client/proc/Jump(var/area/A in return_sorted_areas())
/client/proc/Jump(area/A in return_sorted_areas())
set name = "Jump to Area"
set desc = "Area to jump to"
set category = "Admin"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
var/list/area_turfs = get_area_turfs(A)
if(area_turfs && area_turfs.len)
usr.loc = pick(area_turfs)
else
src << "That area has no turfs to jump to!"
if(!A)
return
var/list/turfs = list()
for(var/turf/T in A)
if(T.density)
continue
turfs.Add(T)
var/turf/T = pick_n_take(turfs)
if(!T)
src << "Nowhere to jump to!"
return
admin_forcemove(usr, T)
log_admin("[key_name(usr)] jumped to [A]")
message_admins("[key_name_admin(usr)] jumped to [A]", 1)
message_admins("[key_name_admin(usr)] jumped to [A]")
feedback_add_details("admin_verb","JA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/jumptoturf(var/turf/T in world)
set name = "Jump to Turf"
set category = "Admin"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
log_admin("[key_name(usr)] jumped to [T.x],[T.y],[T.z] in [T.loc]")
message_admins("[key_name_admin(usr)] jumped to [T.x],[T.y],[T.z] in [T.loc]", 1)
log_admin("[key_name(usr)] jumped to [T.x], [T.y], [T.z] in [T.loc]")
message_admins("[key_name_admin(usr)] jumped to [T.x], [T.y], [T.z] in [T.loc]", 1)
usr.loc = T
feedback_add_details("admin_verb","JT") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
return
@@ -33,8 +42,7 @@
set category = "Admin"
set name = "Jump to Mob"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
log_admin("[key_name(usr)] jumped to [key_name(M)]")
@@ -44,7 +52,7 @@
var/turf/T = get_turf(M)
if(T && isturf(T))
feedback_add_details("admin_verb","JM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
A.loc = T
admin_forcemove(A, M.loc)
else
A << "This mob is not located in the game world."
@@ -52,8 +60,7 @@
set category = "Admin"
set name = "Jump to Coordinate"
if (!holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
if(src.mob)
@@ -68,8 +75,7 @@
set category = "Admin"
set name = "Jump to Key"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
var/list/keys = list()
@@ -82,20 +88,22 @@
var/mob/M = selection:mob
log_admin("[key_name(usr)] jumped to [key_name(M)]")
message_admins("[key_name_admin(usr)] jumped to [key_name_admin(M)]", 1)
usr.loc = M.loc
admin_forcemove(usr, M.loc)
feedback_add_details("admin_verb","JK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/Getmob(var/mob/M in mob_list)
set category = "Admin"
set name = "Get Mob"
set desc = "Mob to teleport"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
log_admin("[key_name(usr)] teleported [key_name(M)]")
message_admins("[key_name_admin(usr)] teleported [key_name_admin(M)]", 1)
M.loc = get_turf(usr)
admin_forcemove(M, get_turf(usr))
feedback_add_details("admin_verb","GM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/Getkey()
@@ -103,8 +111,7 @@
set name = "Get Key"
set desc = "Key to teleport"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
var/list/keys = list()
@@ -120,19 +127,27 @@
log_admin("[key_name(usr)] teleported [key_name(M)]")
message_admins("[key_name_admin(usr)] teleported [key_name(M)]", 1)
if(M)
M.loc = get_turf(usr)
admin_forcemove(M, get_turf(usr))
usr.loc = M.loc
feedback_add_details("admin_verb","GK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/sendmob(var/mob/M in sortmobs())
set category = "Admin"
set name = "Send Mob"
if(!src.holder)
src << "Only administrators may use this command."
if(!check_rights(R_ADMIN))
return
var/area/A = input(usr, "Pick an area.", "Pick an area") in return_sorted_areas()
if(A)
M.loc = pick(get_area_turfs(A))
admin_forcemove(M, pick(get_area_turfs(A)))
feedback_add_details("admin_verb","SMOB") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
log_admin("[key_name(usr)] teleported [key_name(M)] to [A]")
message_admins("[key_name_admin(usr)] teleported [key_name_admin(M)] to [A]", 1)
message_admins("[key_name_admin(usr)] teleported [key_name_admin(M)] to [A]", 1)
/proc/admin_forcemove(mob/mover, atom/newloc)
mover.loc = newloc
mover.on_forcemove(newloc)
/mob/proc/on_forcemove(atom/newloc)
return
+4 -4
View File
@@ -26,8 +26,8 @@ var/global/list/frozen_mob_list = list()
/mob/living/proc/admin_Freeze(var/client/admin)
if(istype(admin))
src << "<b><font color= red>You have been frozen by <a href='?priv_msg=\ref[admin]'>[admin.key]</a></b></font>"
message_admins("\blue [key_name_admin(admin)] froze [key_name(src)]")
src << "<b><font color= red>You have been frozen by [key_name(admin)]</b></font>"
message_admins("<span class='notice'>[key_name_admin(admin)]</span> froze [key_name_admin(src)]")
log_admin("[key_name(admin)] froze [key_name(src)]")
var/obj/effect/overlay/adminoverlay/AO = new
@@ -42,8 +42,8 @@ var/global/list/frozen_mob_list = list()
/mob/living/proc/admin_unFreeze(var/client/admin)
if(istype(admin))
src << "<b><font color= red>You have been unfrozen by <a href='?priv_msg=\ref[usr.client]'>[key]</a></b></font>"
message_admins("\blue [key_name_admin(admin)] unfroze [key_name(src)]")
src << "<b><font color= red>You have been unfrozen by [key_name(admin)]</b></font>"
message_admins("\blue [key_name_admin(admin)] unfroze [key_name_admin(src)]")
log_admin("[key_name(admin)] unfroze [key_name(src)]")
update_icons()
+2 -2
View File
@@ -11,10 +11,10 @@
if(T)
log_admin("[key_name(usr)] has possessed [O] ([O.type]) at ([T.x], [T.y], [T.z])")
message_admins("[key_name(usr)] has possessed [O] ([O.type]) at ([T.x], [T.y], [T.z])", 1)
message_admins("[key_name_admin(usr)] has possessed [O] ([O.type]) at ([T.x], [T.y], [T.z])", 1)
else
log_admin("[key_name(usr)] has possessed [O] ([O.type]) at an unknown location")
message_admins("[key_name(usr)] has possessed [O] ([O.type]) at an unknown location", 1)
message_admins("[key_name_admin(usr)] has possessed [O] ([O.type]) at an unknown location", 1)
if(!usr.control_object) //If you're not already possessing something...
usr.name_archive = usr.real_name
+6 -10
View File
@@ -107,7 +107,7 @@
return
world << "[msg]"
log_admin("GlobalNarrate: [key_name(usr)] : [msg]")
message_admins("\blue \bold GlobalNarrate: [key_name_admin(usr)] : [msg]<BR>", 1)
message_admins("\blue \bold GlobalNarrate: [key_name_admin(usr)]: [msg]<BR>", 1)
feedback_add_details("admin_verb","GLN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/cmd_admin_direct_narrate(var/mob/M) // Targetted narrate -- TLE
@@ -128,8 +128,8 @@
return
M << msg
log_admin("DirectNarrate: [key_name(usr)] to ([M.name]/[M.key]): [msg]")
message_admins("\blue \bold DirectNarrate: [key_name(usr)] to ([M.name]/[M.key]): [msg]<BR>", 1)
log_admin("DirectNarrate: [key_name(usr)] to ([key_name(M)]): [msg]")
message_admins("\blue \bold DirectNarrate: [key_name_admin(usr)] to ([key_name_admin(M)]): [msg]<BR>", 1)
feedback_add_details("admin_verb","DIRN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/cmd_admin_godmode(mob/M as mob in mob_list)
@@ -472,10 +472,6 @@ Traitors and the like can also be revived with the previous role mostly intact.
If they don't have a mind, they obviously don't have a special role.
*/
//Two variables to properly announce later on.
var/admin = key_name_admin(src)
var/player_key = G_found.key
//Now for special roles and equipment.
switch(new_character.mind.special_role)
if("traitor")
@@ -519,7 +515,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(alert(new_character,"Would you like an active AI to announce this character?",,"No","Yes")=="Yes")
call(/mob/new_player/proc/AnnounceArrival)(new_character, new_character.mind.assigned_role)
message_admins("\blue [admin] has respawned [player_key] as [new_character.real_name].", 1)
message_admins("\blue [key_name_admin(usr)] has respawned [key_name_admin(G_found)] as [new_character.real_name].", 1)
new_character << "You have been fully respawned. Enjoy the game."
@@ -728,8 +724,8 @@ Traitors and the like can also be revived with the previous role mostly intact.
if (heavy || light)
empulse(O, heavy, light)
log_admin("[key_name(usr)] created an EM Pulse ([heavy],[light]) at ([O.x],[O.y],[O.z])")
message_admins("[key_name_admin(usr)] created an EM PUlse ([heavy],[light]) at ([O.x],[O.y],[O.z])", 1)
log_admin("[key_name(usr)] created an EM pulse ([heavy], [light]) at ([O.x],[O.y],[O.z])")
message_admins("[key_name_admin(usr)] created an EM pulse ([heavy], [light]) at ([O.x],[O.y],[O.z])", 1)
feedback_add_details("admin_verb","EMP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
return
+1 -1
View File
@@ -11,7 +11,7 @@
//I've used ticks of 2 before to help with serious singulo lags
if(newtick && newtick <= 2 && newtick > 0)
log_admin("[key_name(src)] has modified world.tick_lag to [newtick]", 0)
message_admins("[key_name(src)] has modified world.tick_lag to [newtick]", 0)
message_admins("[key_name_admin(src)] has modified world.tick_lag to [newtick]", 0)
world.tick_lag = newtick
feedback_add_details("admin_verb","TICKLAG") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!