mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-25 14:00:18 +01:00
Repath a bunch of things to /mob/abstract childtypes (#4111)
* Repaths eyes, observers, dview, and new_players to /mob/abstract subtypes. * Adds /mob/abstract, a base type for 'abstract' mobs that aren't meant to be directly affected by the game world.
This commit is contained in:
@@ -46,7 +46,7 @@ proc/admin_notice(var/message, var/rights)
|
||||
body += " played by <b>[M.client]</b> "
|
||||
body += "\[<A href='?src=\ref[src];editrights=show'>[M.client.holder ? M.client.holder.rank : "Player"]</A>\]"
|
||||
|
||||
if(istype(M, /mob/new_player))
|
||||
if(istype(M, /mob/abstract/new_player))
|
||||
body += " <B>Hasn't Entered Game</B> "
|
||||
else
|
||||
body += " \[<A href='?src=\ref[src];revive=\ref[M]'>Heal</A>\] "
|
||||
@@ -92,7 +92,7 @@ proc/admin_notice(var/message, var/rights)
|
||||
"}
|
||||
|
||||
if (M.client)
|
||||
if(!istype(M, /mob/new_player))
|
||||
if(!istype(M, /mob/abstract/new_player))
|
||||
body += "<br><br>"
|
||||
body += "<b>Transformation:</b>"
|
||||
body += "<br>"
|
||||
@@ -1243,7 +1243,7 @@ proc/admin_notice(var/message, var/rights)
|
||||
|
||||
//Returns 1 to let the dragdrop code know we are trapping this event
|
||||
//Returns 0 if we don't plan to trap the event
|
||||
/datum/admins/proc/cmd_ghost_drag(var/mob/dead/observer/frommob, var/mob/living/tomob)
|
||||
/datum/admins/proc/cmd_ghost_drag(var/mob/abstract/observer/frommob, var/mob/living/tomob)
|
||||
if(!istype(frommob))
|
||||
return //Extra sanity check to make sure only observers are shoved into things
|
||||
|
||||
|
||||
@@ -461,9 +461,9 @@ var/list/admin_verbs_cciaa = list(
|
||||
set category = "Admin"
|
||||
set name = "Aghost"
|
||||
if(!holder) return
|
||||
if(istype(mob,/mob/dead/observer))
|
||||
if(istype(mob,/mob/abstract/observer))
|
||||
//re-enter
|
||||
var/mob/dead/observer/ghost = mob
|
||||
var/mob/abstract/observer/ghost = mob
|
||||
if(ghost.can_reenter_corpse)
|
||||
ghost.reenter_corpse()
|
||||
else
|
||||
@@ -472,12 +472,12 @@ var/list/admin_verbs_cciaa = list(
|
||||
|
||||
feedback_add_details("admin_verb","P") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
else if(istype(mob,/mob/new_player))
|
||||
else if(istype(mob,/mob/abstract/new_player))
|
||||
src << "<font color='red'>Error: Aghost: Can't admin-ghost whilst in the lobby. Join or Observe first.</font>"
|
||||
else
|
||||
//ghostize
|
||||
var/mob/body = mob
|
||||
var/mob/dead/observer/ghost = body.ghostize(1)
|
||||
var/mob/abstract/observer/ghost = body.ghostize(1)
|
||||
ghost.admin_ghosted = 1
|
||||
if(body)
|
||||
body.teleop = ghost
|
||||
|
||||
@@ -258,7 +258,7 @@
|
||||
else
|
||||
M_job = "Living"
|
||||
|
||||
else if(istype(M,/mob/new_player))
|
||||
else if(istype(M,/mob/abstract/new_player))
|
||||
M_job = "New player"
|
||||
|
||||
else if(isobserver(M))
|
||||
@@ -339,7 +339,7 @@
|
||||
dat += "<td>[M.real_name]</td>"
|
||||
else if(istype(M, /mob/living/silicon/pai))
|
||||
dat += "<td>pAI</td>"
|
||||
else if(istype(M, /mob/new_player))
|
||||
else if(istype(M, /mob/abstract/new_player))
|
||||
dat += "<td>New Player</td>"
|
||||
else if(isobserver(M))
|
||||
dat += "<td>Ghost</td>"
|
||||
|
||||
@@ -279,7 +279,7 @@
|
||||
message_admins("<span class='notice'>[key_name_admin(usr)] has used rudimentary transformation on [key_name_admin(M)]. Transforming to [href_list["simplemake"]]; deletemob=[delmob]</span>", 1)
|
||||
|
||||
switch(href_list["simplemake"])
|
||||
if("observer") M.change_mob_type( /mob/dead/observer , null, null, delmob )
|
||||
if("observer") M.change_mob_type( /mob/abstract/observer , null, null, delmob )
|
||||
if("larva") M.change_mob_type( /mob/living/carbon/alien/larva , null, null, delmob )
|
||||
if("nymph") M.change_mob_type( /mob/living/carbon/alien/diona , null, null, delmob )
|
||||
if("human") M.change_mob_type( /mob/living/carbon/human , null, null, delmob, href_list["species"])
|
||||
@@ -801,8 +801,8 @@
|
||||
if(!check_rights(R_SPAWN)) return
|
||||
|
||||
var/mob/M = locate(href_list["makeanimal"])
|
||||
if(istype(M, /mob/new_player))
|
||||
usr << "This cannot be used on instances of type /mob/new_player"
|
||||
if(istype(M, /mob/abstract/new_player))
|
||||
usr << "This cannot be used on instances of type /mob/abstract/new_player"
|
||||
return
|
||||
|
||||
usr.client.cmd_admin_animalize(M)
|
||||
@@ -1627,7 +1627,7 @@ mob/living/silicon/ai/can_centcom_reply()
|
||||
if(client && eyeobj)
|
||||
return "|<A HREF='?[source];adminplayerobservejump=\ref[eyeobj]'>EYE</A>"
|
||||
|
||||
/mob/dead/observer/extra_admin_link(var/source)
|
||||
/mob/abstract/observer/extra_admin_link(var/source)
|
||||
if(mind && mind.current)
|
||||
return "|<A HREF='?[source];adminplayerobservejump=\ref[mind.current]'>BDY</A>"
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/mob/proc/on_mob_jump()
|
||||
return
|
||||
|
||||
/mob/dead/observer/on_mob_jump()
|
||||
/mob/abstract/observer/on_mob_jump()
|
||||
stop_following()
|
||||
|
||||
/client/proc/Jump(var/area/A in all_areas)
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
var/list/client/targets[0]
|
||||
for(var/client/T)
|
||||
if(T.mob)
|
||||
if(istype(T.mob, /mob/new_player))
|
||||
if(istype(T.mob, /mob/abstract/new_player))
|
||||
targets["(New Player) - [T]"] = T
|
||||
else if(istype(T.mob, /mob/dead/observer))
|
||||
else if(istype(T.mob, /mob/abstract/observer))
|
||||
targets["[T.mob.name](Ghost) - [T]"] = T
|
||||
else
|
||||
targets["[T.mob.real_name](as [T.mob.name]) - [T]"] = T
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
set name = "AOOC"
|
||||
set desc = "Antagonist OOC"
|
||||
|
||||
if (istype(src.mob, /mob/dead/observer) && !check_rights(R_ADMIN|R_MOD|R_CCIAA, 0))
|
||||
if (istype(src.mob, /mob/abstract/observer) && !check_rights(R_ADMIN|R_MOD|R_CCIAA, 0))
|
||||
src << "<span class='warning'>You cannot use AOOC while ghosting/observing!</span>"
|
||||
return
|
||||
|
||||
|
||||
@@ -169,7 +169,7 @@
|
||||
if(client.holder && client.holder.original_mob)
|
||||
client.holder.original_mob.key = key
|
||||
else
|
||||
var/mob/dead/observer/ghost = new(src) //Transfer safety to observer spawning proc.
|
||||
var/mob/abstract/observer/ghost = new(src) //Transfer safety to observer spawning proc.
|
||||
ghost.key = key
|
||||
ghost.mind.name = "[ghost.key] BSTech"
|
||||
ghost.name = "[ghost.key] BSTech"
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
alert("That mob doesn't seem to exist, close the panel and try again.")
|
||||
return
|
||||
|
||||
if(istype(M, /mob/new_player))
|
||||
if(istype(M, /mob/abstract/new_player))
|
||||
alert("The mob must not be a new_player.")
|
||||
return
|
||||
|
||||
@@ -203,7 +203,7 @@
|
||||
set name = "Del-All"
|
||||
|
||||
// to prevent REALLY stupid deletions
|
||||
var/blocked = list(/obj, /mob, /mob/living, /mob/living/carbon, /mob/living/carbon/human, /mob/dead, /mob/dead/observer, /mob/living/silicon, /mob/living/silicon/robot, /mob/living/silicon/ai)
|
||||
var/blocked = list(/obj, /mob, /mob/living, /mob/living/carbon, /mob/living/carbon/human, /mob/abstract, /mob/abstract/observer, /mob/living/silicon, /mob/living/silicon/robot, /mob/living/silicon/ai)
|
||||
var/hsbitem = input(usr, "Choose an object to delete.", "Delete:") as null|anything in typesof(/obj) + typesof(/mob) - blocked
|
||||
if(hsbitem)
|
||||
for(var/atom/O in world)
|
||||
@@ -271,7 +271,7 @@
|
||||
if(alert("This mob is being controlled by [M.ckey]. Are you sure you wish to assume control of it? [M.ckey] will be made a ghost.",,"Yes","No") != "Yes")
|
||||
return
|
||||
else
|
||||
var/mob/dead/observer/ghost = new/mob/dead/observer(M,1)
|
||||
var/mob/abstract/observer/ghost = new/mob/abstract/observer(M,1)
|
||||
ghost.ckey = M.ckey
|
||||
message_admins("<span class='notice'>[key_name_admin(usr)] assumed direct control of [M].</span>", 1)
|
||||
log_admin("[key_name(usr)] assumed direct control of [M].",admin_key=key_name(usr))
|
||||
|
||||
@@ -238,7 +238,7 @@ proc/get_ghosts(var/notify = 0,var/what = 2, var/client/C = null)
|
||||
var/list/ghosts = list()
|
||||
var/list/sortmob = sortAtom(mob_list) // get the mob list.
|
||||
var/any=0
|
||||
for(var/mob/dead/observer/M in sortmob)
|
||||
for(var/mob/abstract/observer/M in sortmob)
|
||||
mobs.Add(M) //filter it where it's only ghosts
|
||||
any = 1 //if no ghosts show up, any will just be 0
|
||||
if(!any)
|
||||
@@ -268,7 +268,7 @@ proc/get_ghosts(var/notify = 0,var/what = 2, var/client/C = null)
|
||||
src << "Hrm, appears you didn't select a ghost" // Sanity check, if no ghosts in the list we don't want to edit a null variable and cause a runtime error.
|
||||
return
|
||||
|
||||
var/mob/dead/observer/G = ghosts[target]
|
||||
var/mob/abstract/observer/G = ghosts[target]
|
||||
if(G.has_enabled_antagHUD && config.antag_hud_restricted)
|
||||
var/response = alert(src, "Are you sure you wish to allow this individual to play?","Ghost has used AntagHUD","Yes","No")
|
||||
if(response == "No") return
|
||||
@@ -306,9 +306,9 @@ proc/get_ghosts(var/notify = 0,var/what = 2, var/client/C = null)
|
||||
src << "Only administrators may use this command."
|
||||
var/action=""
|
||||
if(config.antag_hud_allowed)
|
||||
for(var/mob/dead/observer/g in get_ghosts())
|
||||
for(var/mob/abstract/observer/g in get_ghosts())
|
||||
if(!g.client.holder) //Remove the verb from non-admin ghosts
|
||||
g.verbs -= /mob/dead/observer/verb/toggle_antagHUD
|
||||
g.verbs -= /mob/abstract/observer/verb/toggle_antagHUD
|
||||
if(g.antagHUD)
|
||||
g.antagHUD = 0 // Disable it on those that have it enabled
|
||||
g.has_enabled_antagHUD = 2 // We'll allow them to respawn
|
||||
@@ -317,9 +317,9 @@ proc/get_ghosts(var/notify = 0,var/what = 2, var/client/C = null)
|
||||
src << "<span class='danger'>AntagHUD usage has been disabled.</span>"
|
||||
action = "disabled"
|
||||
else
|
||||
for(var/mob/dead/observer/g in get_ghosts())
|
||||
for(var/mob/abstract/observer/g in get_ghosts())
|
||||
if(!g.client.holder) // Add the verb back for all non-admin ghosts
|
||||
g.verbs += /mob/dead/observer/verb/toggle_antagHUD
|
||||
g.verbs += /mob/abstract/observer/verb/toggle_antagHUD
|
||||
g << "<span class='notice'><B>The Administrator has enabled AntagHUD.</B></span>" // Notify all observers they can now use AntagHUD
|
||||
config.antag_hud_allowed = 1
|
||||
action = "enabled"
|
||||
@@ -339,13 +339,13 @@ proc/get_ghosts(var/notify = 0,var/what = 2, var/client/C = null)
|
||||
src << "Only administrators may use this command."
|
||||
var/action=""
|
||||
if(config.antag_hud_restricted)
|
||||
for(var/mob/dead/observer/g in get_ghosts())
|
||||
for(var/mob/abstract/observer/g in get_ghosts())
|
||||
g << "<span class='notice'><B>The administrator has lifted restrictions on joining the round if you use AntagHUD</B></span>"
|
||||
action = "lifted restrictions"
|
||||
config.antag_hud_restricted = 0
|
||||
src << "<span class='notice'><B>AntagHUD restrictions have been lifted</B></span>"
|
||||
else
|
||||
for(var/mob/dead/observer/g in get_ghosts())
|
||||
for(var/mob/abstract/observer/g in get_ghosts())
|
||||
g << "<span class='danger'>The administrator has placed restrictions on joining the round if you use AntagHUD</span>"
|
||||
g << "<span class='danger'>Your AntagHUD has been disabled, you may choose to re-enabled it but will be under restrictions </span>"
|
||||
g.antagHUD = 0
|
||||
@@ -373,8 +373,8 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
if(!input)
|
||||
return
|
||||
|
||||
var/mob/dead/observer/G_found
|
||||
for(var/mob/dead/observer/G in player_list)
|
||||
var/mob/abstract/observer/G_found
|
||||
for(var/mob/abstract/observer/G in player_list)
|
||||
if(G.ckey == input)
|
||||
G_found = G
|
||||
break
|
||||
@@ -597,8 +597,8 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
if (action == "No")
|
||||
return
|
||||
|
||||
if (istype(O, /mob/dead/observer))
|
||||
var/mob/dead/observer/M = O
|
||||
if (istype(O, /mob/abstract/observer))
|
||||
var/mob/abstract/observer/M = O
|
||||
if (M.client && alert(src, "They are still connected. Are you sure, they will loose connection.", "Confirmation", "Yes", "No") != "Yes")
|
||||
return
|
||||
log_admin("[key_name(usr)] deleted [O] at ([O.x],[O.y],[O.z])",admin_key=key_name(usr))
|
||||
@@ -693,7 +693,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
log_admin("[key_name(usr)] has gibbed [key_name(M)]",admin_key=key_name(usr),ckey=key_name(M))
|
||||
message_admins("[key_name_admin(usr)] has gibbed [key_name_admin(M)]", 1)
|
||||
|
||||
if(istype(M, /mob/dead/observer))
|
||||
if(istype(M, /mob/abstract/observer))
|
||||
gibs(M.loc, M.viruses)
|
||||
return
|
||||
|
||||
@@ -706,7 +706,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
|
||||
var/confirm = alert(src, "You sure?", "Confirm", "Yes", "No")
|
||||
if(confirm == "Yes")
|
||||
if (istype(mob, /mob/dead/observer)) // so they don't spam gibs everywhere
|
||||
if (istype(mob, /mob/abstract/observer)) // so they don't spam gibs everywhere
|
||||
return
|
||||
else
|
||||
mob.gib()
|
||||
|
||||
Reference in New Issue
Block a user