The One Where I Port Modals

This commit is contained in:
Chompstation Bot
2021-06-30 19:29:34 +00:00
parent 2457a62edd
commit b6e1989a01
468 changed files with 10519 additions and 1808 deletions
+16 -16
View File
@@ -177,14 +177,14 @@
to_chat(usr, "This can only be used on instances of type /obj")
return
var/action_type = alert("Strict type ([O.type]) or type and all subtypes?",,"Strict type","Type and subtypes","Cancel")
var/action_type = tgui_alert(usr, "Strict type ([O.type]) or type and all subtypes?","Type Selection",list("Strict type","Type and subtypes","Cancel"))
if(action_type == "Cancel" || !action_type)
return
if(alert("Are you really sure you want to delete all objects of type [O.type]?",,"Yes","No") != "Yes")
if(tgui_alert(usr, "Are you really sure you want to delete all objects of type [O.type]?","Delete All?",list("Yes","No")) != "Yes")
return
if(alert("Second confirmation required. Delete?",,"Yes","No") != "Yes")
if(tgui_alert(usr, "Second confirmation required. Delete?","REALLY?",list("Yes","No")) != "Yes")
return
var/O_type = O.type
@@ -235,7 +235,7 @@
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(tgui_alert(usr, "Confirm mob type change?","Confirm",list("Transform","Cancel")) != "Transform") return
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
return
@@ -249,7 +249,7 @@
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(tgui_alert(usr, "Confirm mob type change?","Confirm",list("Transform","Cancel")) != "Transform") return
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
return
@@ -263,7 +263,7 @@
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(tgui_alert(usr, "Confirm mob type change?","Confirm",list("Transform","Cancel")) != "Transform") return
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
return
@@ -277,7 +277,7 @@
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(tgui_alert(usr, "Confirm mob type change?","Confirm",list("Transform","Cancel")) != "Transform") return
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
return
@@ -291,7 +291,7 @@
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
var/new_species = tgui_input_list(usr, "Please choose a new species.","Species", GLOB.all_species)
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
@@ -310,7 +310,7 @@
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
var/new_language = tgui_input_list(usr, "Please choose a language to add.","Language", GLOB.all_languages)
if(!new_language)
return
@@ -336,7 +336,7 @@
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
var/datum/language/rem_language = tgui_input_list(usr, "Please choose a language to remove.","Language", H.languages)
if(!rem_language)
return
@@ -372,7 +372,7 @@
possibleverbs -= H.verbs
possibleverbs += "Cancel" // ...And one for the bottom
var/verb = input("Select a verb!", "Verbs",null) as anything in possibleverbs
var/verb = tgui_input_list(usr, "Select a verb!", "Verbs", possibleverbs)
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
return
@@ -389,7 +389,7 @@
if(!istype(H))
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
var/verb = tgui_input_list(usr, "Please choose a verb to remove.","Verbs", H.verbs)
if(!H)
to_chat(usr, "Mob doesn't exist anymore")
return
@@ -406,7 +406,7 @@
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
var/new_organ = tgui_input_list(usr, "Please choose an organ to add.","Organ", subtypesof(/obj/item/organ))
if(!new_organ) return
if(!M)
@@ -428,7 +428,7 @@
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
var/obj/item/organ/rem_organ = tgui_input_list(usr, "Please choose an organ to remove.","Organ", M.internal_organs)
if(!M)
to_chat(usr, "Mob doesn't exist anymore")
@@ -475,7 +475,7 @@
var/Text = href_list["adjustDamage"]
var/amount = input("Deal how much damage to mob? (Negative values here heal)","Adjust [Text]loss",0) as num
var/amount = input(usr, "Deal how much damage to mob? (Negative values here heal)","Adjust [Text]loss",0) as num
if(!L)
to_chat(usr, "Mob doesn't exist anymore")
@@ -508,7 +508,7 @@
var/client/C = value["value"]
if (!C)
return
var/prompt = alert("Do you want to grant [C] access to view this VV window? (they will not be able to edit or change anysrc nor open nested vv windows unless they themselves are an admin)", "Confirm", "Yes", "No")
var/prompt = tgui_alert(usr, "Do you want to grant [C] access to view this VV window? (they will not be able to edit or change anysrc nor open nested vv windows unless they themselves are an admin)", "Confirm", list("Yes", "No"))
if (prompt != "Yes")
return
if(!thing)