Revert "TGUI alerts, lists, inputs"
This commit is contained in:
@@ -120,7 +120,7 @@
|
||||
|
||||
|
||||
/obj/structure/sign/barsign/proc/pick_sign(mob/user)
|
||||
var/picked_name = tgui_input_list(user, "Available Signage", "Bar Sign", barsigns)
|
||||
var/picked_name = input(user, "Available Signage", "Bar Sign", name) as null|anything in barsigns
|
||||
if(!picked_name)
|
||||
return
|
||||
set_sign(picked_name)
|
||||
|
||||
@@ -40,13 +40,13 @@
|
||||
return TRUE
|
||||
|
||||
/obj/structure/closet/secure_closet/genpop/proc/handle_edit_sentence(mob/user)
|
||||
var/prisoner_name = tgui_input_text(user, "Please input the name of the prisoner.", "Prisoner Name", registered_id.registered_name)
|
||||
var/prisoner_name = input(user, "Please input the name of the prisoner.", "Prisoner Name", registered_id.registered_name) as text|null
|
||||
if(prisoner_name == null | !user.Adjacent(src))
|
||||
return FALSE
|
||||
var/sentence_length = tgui_input_num(user, "Please input the length of their sentence in minutes (0 for perma).", "Sentence Length", registered_id.sentence)
|
||||
var/sentence_length = input(user, "Please input the length of their sentence in minutes (0 for perma).", "Sentence Length", registered_id.sentence) as num|null
|
||||
if(sentence_length == null | !user.Adjacent(src))
|
||||
return FALSE
|
||||
var/crimes = tgui_input_text(user, "Please input their crimes.", "Crimes", registered_id.crime)
|
||||
var/crimes = input(user, "Please input their crimes.", "Crimes", registered_id.crime) as text|null
|
||||
if(crimes == null | !user.Adjacent(src))
|
||||
return FALSE
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
|
||||
if(!broken && locked && registered_id != null)
|
||||
var/name = registered_id.registered_name
|
||||
var/result = tgui_alert(user, "This locker currently contains [name]'s personal belongings ","Locker In Use",list("Reset","Amend ID", "Open"))
|
||||
var/result = alert(user, "This locker currently contains [name]'s personal belongings ","Locker In Use","Reset","Amend ID", "Open")
|
||||
if(!user.Adjacent(src))
|
||||
return
|
||||
if(result == "Reset")
|
||||
|
||||
@@ -470,7 +470,7 @@
|
||||
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, TRUE)
|
||||
return
|
||||
|
||||
var/new_price_input = tgui_input_num(usr,"Set the sale price for this vend-a-tray.","new price",sale_price)
|
||||
var/new_price_input = input(usr,"Set the sale price for this vend-a-tray.","new price",0) as num|null
|
||||
if(isnull(new_price_input) || (payments_acc != potential_acc.registered_account))
|
||||
to_chat(usr, "<span class='warning'>[src] rejects your new price.</span>")
|
||||
return
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
if(!(GLOB.socks_list[H.socks]?.has_color))
|
||||
undergarment_choices -= "Socks Color"
|
||||
|
||||
var/choice = tgui_input_list(H, "Underwear, Undershirt, or Socks?", "Changing", undergarment_choices)
|
||||
var/choice = input(H, "Underwear, Undershirt, or Socks?", "Changing") as null|anything in undergarment_choices
|
||||
if(!H.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
|
||||
return
|
||||
var/dye_undie = FALSE
|
||||
@@ -45,21 +45,21 @@
|
||||
var/dye_socks = FALSE
|
||||
switch(choice)
|
||||
if("Underwear")
|
||||
var/new_undies = tgui_input_list(H, "Select your underwear", "Changing", GLOB.underwear_list)
|
||||
var/new_undies = input(H, "Select your underwear", "Changing") as null|anything in GLOB.underwear_list
|
||||
if(new_undies)
|
||||
H.underwear = new_undies
|
||||
H.saved_underwear = new_undies
|
||||
var/datum/sprite_accessory/underwear/bottom/B = GLOB.underwear_list[new_undies]
|
||||
dye_undie = B?.has_color
|
||||
if("Undershirt")
|
||||
var/new_undershirt = tgui_input_list(H, "Select your undershirt", "Changing", GLOB.undershirt_list)
|
||||
var/new_undershirt = input(H, "Select your undershirt", "Changing") as null|anything in GLOB.undershirt_list
|
||||
if(new_undershirt)
|
||||
H.undershirt = new_undershirt
|
||||
H.saved_undershirt = new_undershirt
|
||||
var/datum/sprite_accessory/underwear/top/T = GLOB.undershirt_list[new_undershirt]
|
||||
dye_shirt = T?.has_color
|
||||
if("Socks")
|
||||
var/new_socks = tgui_input_list(H, "Select your socks", "Changing", GLOB.socks_list)
|
||||
var/new_socks = input(H, "Select your socks", "Changing") as null|anything in GLOB.socks_list
|
||||
if(new_socks)
|
||||
H.socks = new_socks
|
||||
H.saved_socks = new_socks
|
||||
|
||||
@@ -184,7 +184,7 @@
|
||||
|
||||
/obj/effect/mob_spawn/human/golem/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
|
||||
if(isgolem(user) && can_transfer)
|
||||
var/transfer_choice = tgui_alert(user, "Transfer your soul to [src]? (Warning, your old body will die!)",,list("Yes","No"))
|
||||
var/transfer_choice = alert("Transfer your soul to [src]? (Warning, your old body will die!)",,"Yes","No")
|
||||
if(transfer_choice != "Yes" || QDELETED(src) || uses <= 0 || !user.canUseTopic(src, BE_CLOSE, NO_DEXTERY, NO_TK))
|
||||
return
|
||||
log_game("[key_name(user)] golem-swapped into [src]")
|
||||
@@ -742,7 +742,7 @@
|
||||
/datum/action/disguise/Trigger()
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(!currently_disguised)
|
||||
var/user_object_type = tgui_input_list(H, "Disguising as OBJECT or MOB?", "", list("OBJECT", "MOB"))
|
||||
var/user_object_type = input(H, "Disguising as OBJECT or MOB?") as null|anything in list("OBJECT", "MOB")
|
||||
if(user_object_type)
|
||||
var/search_term = stripped_input(H, "Enter the search term")
|
||||
if(search_term)
|
||||
@@ -758,7 +758,7 @@
|
||||
if(!length(filtered_results))
|
||||
to_chat(H, "Nothing matched your search query!")
|
||||
else
|
||||
var/disguise_selection = tgui_input_list(H, "Select item to disguise as", "", filtered_results)
|
||||
var/disguise_selection = input("Select item to disguise as") as null|anything in filtered_results
|
||||
if(disguise_selection)
|
||||
var/atom/disguise_item = disguise_selection
|
||||
var/image/I = image(icon = initial(disguise_item.icon), icon_state = initial(disguise_item.icon_state), loc = H)
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
//handle facial hair (if necessary)
|
||||
if(H.gender != FEMALE)
|
||||
var/new_style = tgui_input_list(user, "Select a facial hair style", "Grooming", GLOB.facial_hair_styles_list)
|
||||
var/new_style = input(user, "Select a facial hair style", "Grooming") as null|anything in GLOB.facial_hair_styles_list
|
||||
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
|
||||
return //no tele-grooming
|
||||
if(new_style)
|
||||
@@ -35,7 +35,7 @@
|
||||
H.facial_hair_style = "Shaved"
|
||||
|
||||
//handle normal hair
|
||||
var/new_style = tgui_input_list(user, "Select a hair style", "Grooming", GLOB.hair_styles_list)
|
||||
var/new_style = input(user, "Select a hair style", "Grooming") as null|anything in GLOB.hair_styles_list
|
||||
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
|
||||
return //no tele-grooming
|
||||
if(new_style)
|
||||
@@ -141,7 +141,7 @@
|
||||
|
||||
var/mob/living/carbon/human/H = user
|
||||
|
||||
var/choice = tgui_input_list(user, "Something to change?", "Magical Grooming", list("name", "race", "gender", "hair", "eyes"))
|
||||
var/choice = input(user, "Something to change?", "Magical Grooming") as null|anything in list("name", "race", "gender", "hair", "eyes")
|
||||
|
||||
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
|
||||
return
|
||||
@@ -163,7 +163,7 @@
|
||||
|
||||
if("race")
|
||||
var/newrace
|
||||
var/racechoice = tgui_input_list(H, "What are we again?", "Race change", choosable_races)
|
||||
var/racechoice = input(H, "What are we again?", "Race change") as null|anything in choosable_races
|
||||
newrace = GLOB.species_list[racechoice]
|
||||
|
||||
if(!newrace)
|
||||
@@ -176,7 +176,7 @@
|
||||
var/list/choices = GLOB.skin_tones
|
||||
if(CONFIG_GET(flag/allow_custom_skintones))
|
||||
choices += "custom"
|
||||
var/new_s_tone = tgui_input_list(H, "Choose your skin tone:", "Race change", choices)
|
||||
var/new_s_tone = input(H, "Choose your skin tone:", "Race change") as null|anything in choices
|
||||
if(new_s_tone)
|
||||
if(new_s_tone == "custom")
|
||||
var/default = H.dna.skin_tone_override || null
|
||||
@@ -214,14 +214,14 @@
|
||||
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
|
||||
return
|
||||
if(H.gender == "male")
|
||||
if(tgui_alert(H, "Become a Witch?", "Confirmation", list("Yes", "No")) == "Yes")
|
||||
if(alert(H, "Become a Witch?", "Confirmation", "Yes", "No") == "Yes")
|
||||
H.gender = "female"
|
||||
to_chat(H, "<span class='notice'>Man, you feel like a woman!</span>")
|
||||
else
|
||||
return
|
||||
|
||||
else
|
||||
if(tgui_alert(H, "Become a Warlock?", "Confirmation", list("Yes", "No")) == "Yes")
|
||||
if(alert(H, "Become a Warlock?", "Confirmation", "Yes", "No") == "Yes")
|
||||
H.gender = "male"
|
||||
to_chat(H, "<span class='notice'>Whoa man, you feel like a man!</span>")
|
||||
else
|
||||
@@ -231,7 +231,7 @@
|
||||
H.update_mutations_overlay() //(hulk male/female)
|
||||
|
||||
if("hair")
|
||||
var/hairchoice = tgui_alert(H, "Hair style or hair color?", "Change Hair", list("Style", "Color"))
|
||||
var/hairchoice = alert(H, "Hair style or hair color?", "Change Hair", "Style", "Color")
|
||||
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
|
||||
return
|
||||
if(hairchoice == "Style") //So you just want to use a mirror then?
|
||||
@@ -249,7 +249,7 @@
|
||||
H.update_hair()
|
||||
|
||||
if(BODY_ZONE_PRECISE_EYES)
|
||||
var/eye_type = tgui_input_list(H, "Choose the eye you want to color", "Eye Color", list("Both Eyes", "Left Eye", "Right Eye"))
|
||||
var/eye_type = input(H, "Choose the eye you want to color", "Eye Color") as null|anything in list("Both Eyes", "Left Eye", "Right Eye")
|
||||
if(eye_type)
|
||||
var/input_color = H.left_eye_color
|
||||
if(eye_type == "Right Eye")
|
||||
|
||||
@@ -159,7 +159,7 @@
|
||||
if (!can_rotate || admin)
|
||||
to_chat(user, "<span class='warning'>The rotation is locked!</span>")
|
||||
return FALSE
|
||||
var/new_angle = tgui_input_num(user, "Input a new angle for primary reflection face.", "Reflector Angle", rotation_angle)
|
||||
var/new_angle = input(user, "Input a new angle for primary reflection face.", "Reflector Angle", rotation_angle) as null|num
|
||||
if(!user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
|
||||
return
|
||||
if(!isnull(new_angle))
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
var/list/sign_types = list("Secure Area", "Biohazard", "High Voltage", "Radiation", "Hard Vacuum Ahead", "Disposal: Leads To Space", "Danger: Fire", "No Smoking", "Medbay", "Science", "Chemistry", \
|
||||
"Hydroponics", "Xenobiology")
|
||||
var/obj/structure/sign/sign_type
|
||||
switch(tgui_input_list(user, "Select a sign type.", "Sign Customization", sign_types))
|
||||
switch(input(user, "Select a sign type.", "Sign Customization") as null|anything in sign_types)
|
||||
if("Blank")
|
||||
sign_type = /obj/structure/sign/basic
|
||||
if("Secure Area")
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
virgin = 0
|
||||
notify_ghosts("Someone has begun playing with a [src.name] in [get_area(src)]!", source = src)
|
||||
|
||||
planchette = tgui_input_list(M, "Choose the letter.", "Seance!", list("A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"))
|
||||
planchette = input("Choose the letter.", "Seance!") as null|anything in list("A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z")
|
||||
if(!planchette || !Adjacent(M) || next_use > world.time)
|
||||
return
|
||||
M.log_message("picked a letter on [src], which was \"[planchette]\".")
|
||||
|
||||
Reference in New Issue
Block a user