mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Deprecate the stream operator
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["rename"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
var/new_name = sanitize(input(usr,"What would you like to name this mob?","Input a name",M.real_name) as text|null, MAX_NAME_LEN)
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
var/D = locate(href_list["datumedit"])
|
||||
if(!istype(D,/datum) && !istype(D,/client))
|
||||
usr << "This can only be used on instances of types /client or /datum"
|
||||
to_chat(usr, "This can only be used on instances of types /client or /datum")
|
||||
return
|
||||
|
||||
modify_variables(D, href_list["varnameedit"], 1)
|
||||
@@ -41,7 +41,7 @@
|
||||
|
||||
var/D = locate(href_list["datumchange"])
|
||||
if(!istype(D,/datum) && !istype(D,/client))
|
||||
usr << "This can only be used on instances of types /client or /datum"
|
||||
to_chat(usr, "This can only be used on instances of types /client or /datum")
|
||||
return
|
||||
|
||||
modify_variables(D, href_list["varnamechange"], 0)
|
||||
@@ -51,7 +51,7 @@
|
||||
|
||||
var/atom/A = locate(href_list["datummass"])
|
||||
if(!istype(A))
|
||||
usr << "This can only be used on instances of type /atom"
|
||||
to_chat(usr, "This can only be used on instances of type /atom")
|
||||
return
|
||||
|
||||
cmd_mass_modify_object_variables(A, href_list["varnamemass"])
|
||||
@@ -61,7 +61,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["mob_player_panel"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
src.holder.show_player_panel(M)
|
||||
@@ -72,7 +72,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["give_spell"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
src.give_spell(M)
|
||||
@@ -84,7 +84,7 @@
|
||||
|
||||
var/mob/living/M = locate(href_list["give_modifier"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob/living"
|
||||
to_chat(usr, "This can only be used on instances of type /mob/living")
|
||||
return
|
||||
|
||||
src.admin_give_modifier(M)
|
||||
@@ -95,7 +95,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["give_disease2"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
src.give_disease2(M)
|
||||
@@ -106,7 +106,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["godmode"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
src.cmd_admin_godmode(M)
|
||||
@@ -117,7 +117,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["gib"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
src.cmd_admin_gib(M)
|
||||
@@ -127,7 +127,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["build_mode"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
togglebuildmode(M)
|
||||
@@ -138,7 +138,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["drop_everything"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
if(usr.client)
|
||||
@@ -149,7 +149,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["direct_control"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be used on instances of type /mob"
|
||||
to_chat(usr, "This can only be used on instances of type /mob")
|
||||
return
|
||||
|
||||
if(usr.client)
|
||||
@@ -160,7 +160,7 @@
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["make_skeleton"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be used on instances of type /mob/living/carbon/human"
|
||||
to_chat(usr, "This can only be used on instances of type /mob/living/carbon/human")
|
||||
return
|
||||
|
||||
H.ChangeToSkeleton()
|
||||
@@ -217,7 +217,7 @@
|
||||
|
||||
var/atom/A = locate(href_list["rotatedatum"])
|
||||
if(!istype(A))
|
||||
usr << "This can only be done to instances of type /atom"
|
||||
to_chat(usr, "This can only be done to instances of type /atom")
|
||||
return
|
||||
|
||||
switch(href_list["rotatedir"])
|
||||
@@ -230,12 +230,12 @@
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["makemonkey"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon/human"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon/human")
|
||||
return
|
||||
|
||||
if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform") return
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
holder.Topic(href, list("monkeyone"=href_list["makemonkey"]))
|
||||
|
||||
@@ -244,12 +244,12 @@
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["makerobot"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon/human"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon/human")
|
||||
return
|
||||
|
||||
if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform") return
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
holder.Topic(href, list("makerobot"=href_list["makerobot"]))
|
||||
|
||||
@@ -258,12 +258,12 @@
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["makealien"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon/human"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon/human")
|
||||
return
|
||||
|
||||
if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform") return
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
holder.Topic(href, list("makealien"=href_list["makealien"]))
|
||||
|
||||
@@ -272,12 +272,12 @@
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["makeai"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon/human"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon/human")
|
||||
return
|
||||
|
||||
if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform") return
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
holder.Topic(href, list("makeai"=href_list["makeai"]))
|
||||
|
||||
@@ -286,26 +286,26 @@
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["setspecies"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon/human"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon/human")
|
||||
return
|
||||
|
||||
var/new_species = input("Please choose a new species.","Species",null) as null|anything in GLOB.all_species
|
||||
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
|
||||
if(H.set_species(new_species))
|
||||
usr << "Set species of [H] to [H.species]."
|
||||
to_chat(usr, "Set species of [H] to [H.species].")
|
||||
else
|
||||
usr << "Failed! Something went wrong."
|
||||
to_chat(usr, "Failed! Something went wrong.")
|
||||
|
||||
else if(href_list["addlanguage"])
|
||||
if(!check_rights(R_SPAWN)) return
|
||||
|
||||
var/mob/H = locate(href_list["addlanguage"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob"
|
||||
to_chat(usr, "This can only be done to instances of type /mob")
|
||||
return
|
||||
|
||||
var/new_language = input("Please choose a language to add.","Language",null) as null|anything in GLOB.all_languages
|
||||
@@ -314,24 +314,24 @@
|
||||
return
|
||||
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
|
||||
if(H.add_language(new_language))
|
||||
usr << "Added [new_language] to [H]."
|
||||
to_chat(usr, "Added [new_language] to [H].")
|
||||
else
|
||||
usr << "Mob already knows that language."
|
||||
to_chat(usr, "Mob already knows that language.")
|
||||
|
||||
else if(href_list["remlanguage"])
|
||||
if(!check_rights(R_SPAWN)) return
|
||||
|
||||
var/mob/H = locate(href_list["remlanguage"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob"
|
||||
to_chat(usr, "This can only be done to instances of type /mob")
|
||||
return
|
||||
|
||||
if(!H.languages.len)
|
||||
usr << "This mob knows no languages."
|
||||
to_chat(usr, "This mob knows no languages.")
|
||||
return
|
||||
|
||||
var/datum/language/rem_language = input("Please choose a language to remove.","Language",null) as null|anything in H.languages
|
||||
@@ -340,13 +340,13 @@
|
||||
return
|
||||
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
|
||||
if(H.remove_language(rem_language.name))
|
||||
usr << "Removed [rem_language] from [H]."
|
||||
to_chat(usr, "Removed [rem_language] from [H].")
|
||||
else
|
||||
usr << "Mob doesn't know that language."
|
||||
to_chat(usr, "Mob doesn't know that language.")
|
||||
|
||||
else if(href_list["addverb"])
|
||||
if(!check_rights(R_DEBUG)) return
|
||||
@@ -354,7 +354,7 @@
|
||||
var/mob/living/H = locate(href_list["addverb"])
|
||||
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living")
|
||||
return
|
||||
var/list/possibleverbs = list()
|
||||
possibleverbs += "Cancel" // One for the top...
|
||||
@@ -372,7 +372,7 @@
|
||||
|
||||
var/verb = input("Select a verb!", "Verbs",null) as anything in possibleverbs
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
if(!verb || verb == "Cancel")
|
||||
return
|
||||
@@ -385,11 +385,11 @@
|
||||
var/mob/H = locate(href_list["remverb"])
|
||||
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob"
|
||||
to_chat(usr, "This can only be done to instances of type /mob")
|
||||
return
|
||||
var/verb = input("Please choose a verb to remove.","Verbs",null) as null|anything in H.verbs
|
||||
if(!H)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
if(!verb)
|
||||
return
|
||||
@@ -401,18 +401,18 @@
|
||||
|
||||
var/mob/living/carbon/M = locate(href_list["addorgan"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon")
|
||||
return
|
||||
|
||||
var/new_organ = input("Please choose an organ to add.","Organ",null) as null|anything in typesof(/obj/item/organ)-/obj/item/organ
|
||||
if(!new_organ) return
|
||||
|
||||
if(!M)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
|
||||
if(locate(new_organ) in M.internal_organs)
|
||||
usr << "Mob already has that organ."
|
||||
to_chat(usr, "Mob already has that organ.")
|
||||
return
|
||||
|
||||
new new_organ(M)
|
||||
@@ -423,20 +423,20 @@
|
||||
|
||||
var/mob/living/carbon/M = locate(href_list["remorgan"])
|
||||
if(!istype(M))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon"
|
||||
to_chat(usr, "This can only be done to instances of type /mob/living/carbon")
|
||||
return
|
||||
|
||||
var/obj/item/organ/rem_organ = input("Please choose an organ to remove.","Organ",null) as null|anything in M.internal_organs
|
||||
|
||||
if(!M)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
|
||||
if(!(locate(rem_organ) in M.internal_organs))
|
||||
usr << "Mob does not have that organ."
|
||||
to_chat(usr, "Mob does not have that organ.")
|
||||
return
|
||||
|
||||
usr << "Removed [rem_organ] from [M]."
|
||||
to_chat(usr, "Removed [rem_organ] from [M].")
|
||||
rem_organ.removed()
|
||||
qdel(rem_organ)
|
||||
|
||||
@@ -446,13 +446,13 @@
|
||||
var/mob/H = locate(href_list["fix_nano"])
|
||||
|
||||
if(!istype(H) || !H.client)
|
||||
usr << "This can only be done on mobs with clients"
|
||||
to_chat(usr, "This can only be done on mobs with clients")
|
||||
return
|
||||
|
||||
SSnanoui.send_resources(H.client)
|
||||
|
||||
usr << "Resource files sent"
|
||||
H << "Your NanoUI Resource files have been refreshed"
|
||||
to_chat(usr, "Resource files sent")
|
||||
to_chat(H, "Your NanoUI Resource files have been refreshed")
|
||||
|
||||
log_admin("[key_name(usr)] resent the NanoUI resource files to [key_name(H)] ")
|
||||
|
||||
@@ -461,7 +461,7 @@
|
||||
|
||||
var/mob/M = locate(href_list["regenerateicons"])
|
||||
if(!ismob(M))
|
||||
usr << "This can only be done to instances of type /mob"
|
||||
to_chat(usr, "This can only be done to instances of type /mob")
|
||||
return
|
||||
M.regenerate_icons()
|
||||
|
||||
@@ -476,7 +476,7 @@
|
||||
var/amount = input("Deal how much damage to mob? (Negative values here heal)","Adjust [Text]loss",0) as num
|
||||
|
||||
if(!L)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
to_chat(usr, "Mob doesn't exist anymore")
|
||||
return
|
||||
|
||||
switch(Text)
|
||||
@@ -487,7 +487,7 @@
|
||||
if("brain") L.adjustBrainLoss(amount)
|
||||
if("clone") L.adjustCloneLoss(amount)
|
||||
else
|
||||
usr << "You caused an error. DEBUG: Text:[Text] Mob:[L]"
|
||||
to_chat(usr, "You caused an error. DEBUG: Text:[Text] Mob:[L]")
|
||||
return
|
||||
|
||||
if(amount != 0)
|
||||
|
||||
Reference in New Issue
Block a user