mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-29 23:17:28 +01:00
Merge branch 'master' into editable-fat
This commit is contained in:
@@ -763,7 +763,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
|
||||
var/max_length = 50
|
||||
|
||||
var/message = sanitize(input(usr, "Write a message. It cannot be longer than [max_length] characters.","Blood writing", ""))
|
||||
var/message = sanitize(tgui_input_text(usr, "Write a message. It cannot be longer than [max_length] characters.","Blood writing", "", max_length))
|
||||
|
||||
if (message)
|
||||
|
||||
@@ -928,7 +928,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
var/mob/living/M = tgui_input_list(src, "Select who to whisper to:", "Whisper to?", options)
|
||||
if(!M)
|
||||
return 0
|
||||
var/msg = sanitize(input(src, "Message:", "Spectral Whisper") as text|null)
|
||||
var/msg = sanitize(tgui_input_text(src, "Message:", "Spectral Whisper"))
|
||||
if(msg)
|
||||
log_say("(SPECWHISP to [key_name(M)]): [msg]", src)
|
||||
to_chat(M, "<span class='warning'> You hear a strange, unidentifiable voice in your head... <font color='purple'>[msg]</font></span>")
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
var/input
|
||||
if(!message)
|
||||
input = sanitize_or_reflect(input(src, "Choose an emote to display.") as text|null, src) //VOREStation Edit - Reflect too long messages, within reason
|
||||
input = sanitize_or_reflect(tgui_input_text(src, "Choose an emote to display."), src) //VOREStation Edit - Reflect too long messages, within reason
|
||||
else
|
||||
input = message
|
||||
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
|
||||
/obj/item/weapon/secbot_assembly/ed209_assembly/slime/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob) // Here in the event it's added into a PoI or some such. Standard construction relies on the standard ED up until taser.
|
||||
if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, usr) && src.loc != usr)
|
||||
|
||||
@@ -263,7 +263,7 @@
|
||||
qdel(src)
|
||||
|
||||
else if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, usr) && src.loc != usr)
|
||||
|
||||
@@ -87,7 +87,7 @@
|
||||
..()
|
||||
|
||||
if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, usr) && src.loc != usr)
|
||||
|
||||
@@ -121,7 +121,7 @@
|
||||
..()
|
||||
|
||||
if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, usr) && src.loc != usr)
|
||||
|
||||
@@ -409,7 +409,7 @@
|
||||
qdel(src)
|
||||
|
||||
else if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = input(user, "Enter new robot name", name, created_name) as text
|
||||
var/t = tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN)
|
||||
t = sanitize(t, MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
|
||||
@@ -382,7 +382,7 @@
|
||||
user.drop_from_inventory(src)
|
||||
qdel(src)
|
||||
else if (istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, user) && loc != user)
|
||||
@@ -412,7 +412,7 @@
|
||||
user.drop_from_inventory(src)
|
||||
qdel(src)
|
||||
else if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, user) && loc != user)
|
||||
|
||||
@@ -535,7 +535,7 @@
|
||||
/obj/item/weapon/firstaid_arm_assembly/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
..()
|
||||
if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, usr) && loc != usr)
|
||||
|
||||
@@ -472,7 +472,7 @@
|
||||
qdel(src)
|
||||
|
||||
else if(istype(W, /obj/item/weapon/pen))
|
||||
var/t = sanitizeSafe(input(user, "Enter new robot name", name, created_name), MAX_NAME_LEN)
|
||||
var/t = sanitizeSafe(tgui_input_text(user, "Enter new robot name", name, created_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(!t)
|
||||
return
|
||||
if(!in_range(src, user) && loc != user)
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
if(mind)
|
||||
mind.transfer_to(adult)
|
||||
if (can_namepick_as_adult)
|
||||
var/newname = sanitize(input(adult, "You have become an adult. Choose a name for yourself.", "Adult Name") as null|text, MAX_NAME_LEN)
|
||||
var/newname = sanitize(tgui_input_text(adult, "You have become an adult. Choose a name for yourself.", "Adult Name", null, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
|
||||
if(!newname)
|
||||
adult.fully_replace_character_name(name, "[src.adult_name] ([instance_num])")
|
||||
|
||||
@@ -297,7 +297,7 @@ var/list/_simple_mob_default_emotes = list(
|
||||
|
||||
var/datum/gender/T = gender_datums[get_visible_gender()]
|
||||
|
||||
pose = sanitize(input(usr, "This is [src]. [T.he]...", "Pose", null) as text)
|
||||
pose = sanitize(tgui_input_text(usr, "This is [src]. [T.he]...", "Pose", null))
|
||||
|
||||
/mob/living/carbon/human/verb/set_flavor()
|
||||
set name = "Set Flavour Text"
|
||||
|
||||
@@ -76,22 +76,12 @@
|
||||
BP_L_LEG = skip_body & EXAMINE_SKIPLEGS,
|
||||
BP_R_LEG = skip_body & EXAMINE_SKIPLEGS)
|
||||
|
||||
var/datum/gender/T = gender_datums[get_visible_gender()]
|
||||
var/gender_hidden = (skip_gear & EXAMINE_SKIPJUMPSUIT) && (skip_body & EXAMINE_SKIPFACE)
|
||||
var/gender_key = get_visible_gender(user, gender_hidden)
|
||||
|
||||
if((skip_gear & EXAMINE_SKIPJUMPSUIT) && (skip_body & EXAMINE_SKIPFACE)) //big suits/masks/helmets make it hard to tell their gender
|
||||
T = gender_datums[PLURAL]
|
||||
|
||||
else if(species && species.ambiguous_genders)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(H.species && !istype(species, H.species))
|
||||
T = gender_datums[PLURAL]// Species with ambiguous_genders will not show their true gender upon examine if the examiner is not also the same species.
|
||||
if(!(issilicon(user) || isobserver(user))) // Ghosts and borgs are all knowing
|
||||
T = gender_datums[PLURAL]
|
||||
|
||||
if(!T)
|
||||
// Just in case someone VVs the gender to something strange. It'll runtime anyway when it hits usages, better to CRASH() now with a helpful message.
|
||||
CRASH("Gender datum was null; key was '[((skip_gear & EXAMINE_SKIPJUMPSUIT) && (skip_body & EXAMINE_SKIPFACE)) ? PLURAL : gender]'")
|
||||
var/datum/gender/T = gender_datums[gender_key]
|
||||
if (!T)
|
||||
CRASH({"Null gender datum on examine: mob="[src]",hidden="[gender_hidden]",key="[gender_key]",bio="[gender]",id="[identifying_gender]""})
|
||||
|
||||
var/name_ender = ""
|
||||
if(!((skip_gear & EXAMINE_SKIPJUMPSUIT) && (skip_body & EXAMINE_SKIPFACE)))
|
||||
@@ -144,7 +134,7 @@
|
||||
LAZYADD(pocket_msg, r_store_message)
|
||||
if(LAZYLEN(pocket_msg))
|
||||
tie_msg += " Near the waist it has [english_list(pocket_msg)]."
|
||||
|
||||
|
||||
if(w_uniform.blood_DNA)
|
||||
msg += "<span class='warning'>[T.He] [T.is] wearing [bicon(w_uniform)] [w_uniform.gender==PLURAL?"some":"a"] [(w_uniform.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [w_uniform.name]![tie_msg]</span>"
|
||||
else
|
||||
|
||||
@@ -438,7 +438,7 @@
|
||||
for (var/datum/data/record/R in data_core.security)
|
||||
if (R.fields["id"] == E.fields["id"])
|
||||
if(hasHUD(usr,"security"))
|
||||
var/t1 = sanitize(input(usr, "Add Comment:", "Sec. records", null, null) as message)
|
||||
var/t1 = sanitize(tgui_input_text(usr, "Add Comment:", "Sec. records", null, null, multiline = TRUE))
|
||||
if ( !(t1) || usr.stat || usr.restrained() || !(hasHUD(usr,"security")) )
|
||||
return
|
||||
var/counter = 1
|
||||
@@ -555,7 +555,7 @@
|
||||
for (var/datum/data/record/R in data_core.medical)
|
||||
if (R.fields["id"] == E.fields["id"])
|
||||
if(hasHUD(usr,"medical"))
|
||||
var/t1 = sanitize(input(usr, "Add Comment:", "Med. records", null, null) as message)
|
||||
var/t1 = sanitize(tgui_input_text(usr, "Add Comment:", "Med. records", null, null, multiline = TRUE))
|
||||
if ( !(t1) || usr.stat || usr.restrained() || !(hasHUD(usr,"medical")) )
|
||||
return
|
||||
var/counter = 1
|
||||
@@ -587,11 +587,11 @@
|
||||
src << browse(null, "window=flavor_changes")
|
||||
return
|
||||
if("general")
|
||||
var/msg = sanitize(input(usr,"Update the general description of your character. This will be shown regardless of clothing.","Flavor Text",html_decode(flavor_texts[href_list["flavor_change"]])) as message, extra = 0) //VOREStation Edit: separating out OOC notes
|
||||
var/msg = sanitize(tgui_input_text(usr,"Update the general description of your character. This will be shown regardless of clothing.","Flavor Text",html_decode(flavor_texts[href_list["flavor_change"]]), multiline = TRUE), extra = 0) //VOREStation Edit: separating out OOC notes
|
||||
flavor_texts[href_list["flavor_change"]] = msg
|
||||
return
|
||||
else
|
||||
var/msg = sanitize(input(usr,"Update the flavor text for your [href_list["flavor_change"]].","Flavor Text",html_decode(flavor_texts[href_list["flavor_change"]])) as message, extra = 0)
|
||||
var/msg = sanitize(tgui_input_text(usr,"Update the flavor text for your [href_list["flavor_change"]].","Flavor Text",html_decode(flavor_texts[href_list["flavor_change"]]), multiline = TRUE), extra = 0)
|
||||
flavor_texts[href_list["flavor_change"]] = msg
|
||||
set_flavor()
|
||||
return
|
||||
@@ -807,7 +807,7 @@
|
||||
if (isnull(target))
|
||||
return
|
||||
|
||||
var/say = sanitize(input(usr, "What do you wish to say"))
|
||||
var/say = sanitize(tgui_input_text(usr, "What do you wish to say"))
|
||||
if(mRemotetalk in target.mutations)
|
||||
target.show_message("<font color='blue'> You hear [src.real_name]'s voice: [say]</font>")
|
||||
else
|
||||
@@ -854,13 +854,25 @@
|
||||
remoteview_target = null
|
||||
reset_view(0)
|
||||
|
||||
/mob/living/carbon/human/get_visible_gender()
|
||||
if(wear_suit && wear_suit.flags_inv & HIDEJUMPSUIT && ((head && head.flags_inv & HIDEMASK) || wear_mask))
|
||||
return PLURAL //plural is the gender-neutral default
|
||||
if(species)
|
||||
if(species.ambiguous_genders)
|
||||
return PLURAL // regardless of what you're wearing, your gender can't be figured out
|
||||
return get_gender()
|
||||
/mob/living/carbon/human/get_visible_gender(mob/user, force)
|
||||
switch(force)
|
||||
if(VISIBLE_GENDER_FORCE_PLURAL)
|
||||
return PLURAL
|
||||
if(VISIBLE_GENDER_FORCE_IDENTIFYING)
|
||||
return get_gender()
|
||||
if(VISIBLE_GENDER_FORCE_BIOLOGICAL)
|
||||
return gender
|
||||
else
|
||||
if((wear_mask || (head?.flags_inv & HIDEMASK)) && (wear_suit?.flags_inv & HIDEJUMPSUIT))
|
||||
return PLURAL
|
||||
if(species?.ambiguous_genders && user)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/human = user
|
||||
if(!istype(human.species, species))
|
||||
return PLURAL
|
||||
else if(!isobserver(user) && !issilicon(user))
|
||||
return PLURAL
|
||||
return get_gender()
|
||||
|
||||
/mob/living/carbon/human/proc/increase_germ_level(n)
|
||||
if(gloves)
|
||||
@@ -1205,7 +1217,7 @@
|
||||
|
||||
var/max_length = bloody_hands * 30 //tweeter style
|
||||
|
||||
var/message = sanitize(input(usr, "Write a message. It cannot be longer than [max_length] characters.","Blood writing", ""))
|
||||
var/message = sanitize(tgui_input_text(usr, "Write a message. It cannot be longer than [max_length] characters.","Blood writing", ""))
|
||||
|
||||
if (message)
|
||||
var/used_blood_amount = round(length(message) / 30, 1)
|
||||
|
||||
@@ -170,7 +170,7 @@
|
||||
|
||||
// Wind makes it easier or harder to move, depending on if you're with or against the wind.
|
||||
// I don't like that so I'm commenting it out :)
|
||||
// VOREstation Edit Start
|
||||
// VOREstation Edit Start
|
||||
/*
|
||||
if((T.is_outdoors()) && (T.z <= SSplanets.z_to_planet.len))
|
||||
var/datum/planet/P = SSplanets.z_to_planet[z]
|
||||
@@ -292,5 +292,5 @@
|
||||
|
||||
/mob/living/carbon/human/set_dir(var/new_dir)
|
||||
. = ..()
|
||||
if(. && species.tail)
|
||||
if(. && (species.tail || tail_style))
|
||||
update_tail_showing()
|
||||
@@ -94,7 +94,7 @@
|
||||
|
||||
if(!target) return
|
||||
|
||||
text = input(usr, "What would you like to say?", "Speak to creature", null, null)
|
||||
text = tgui_input_text(usr, "What would you like to say?", "Speak to creature", null, null)
|
||||
|
||||
text = sanitize(text)
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
set desc = "Whisper silently to someone over a distance."
|
||||
set category = "Abilities"
|
||||
|
||||
var/msg = sanitize(input(usr, "Message:", "Psychic Whisper") as text|null)
|
||||
var/msg = sanitize(tgui_input_text(usr, "Message:", "Psychic Whisper"))
|
||||
if(msg)
|
||||
log_say("(PWHISPER to [key_name(M)]) [msg]", src)
|
||||
to_chat(M, "<font color='green'>You hear a strange, alien voice in your head... <i>[msg]</i></font>")
|
||||
|
||||
@@ -215,7 +215,7 @@
|
||||
to_chat(src,"<span class='warning'>You can't process [substance]!</span>")
|
||||
return //Only a few things matter, the rest are best not cluttering the lists.
|
||||
|
||||
var/howmuch = input(src,"How much do you want to store? (0-[matstack.get_amount()])","Select amount") as null|num
|
||||
var/howmuch = tgui_input_number(src,"How much do you want to store? (0-[matstack.get_amount()])","Select amount",null,matstack.get_amount(),0)
|
||||
if(!howmuch || matstack != get_active_hand() || howmuch > matstack.get_amount())
|
||||
return //Quietly fail
|
||||
|
||||
@@ -295,7 +295,7 @@
|
||||
return
|
||||
|
||||
var/nagmessage = "Adjust your mass to be a size between 25 to 200% (or between 1 to 600% in dorms area). Up-sizing consumes metal, downsizing returns metal."
|
||||
var/new_size = input(user, nagmessage, "Pick a Size", user.size_multiplier*100) as num|null
|
||||
var/new_size = tgui_input_number(user, nagmessage, "Pick a Size", user.size_multiplier*100, 600, 1)
|
||||
if(!new_size || !size_range_check(new_size))
|
||||
return
|
||||
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
to_chat(src, "<span class='alium'>Their plasma vessel is missing.</span>")
|
||||
return
|
||||
|
||||
var/amount = input(usr, "Amount:", "Transfer Plasma to [M]") as num
|
||||
var/amount = tgui_input_number(usr, "Amount:", "Transfer Plasma to [M]")
|
||||
if (amount)
|
||||
amount = abs(round(amount))
|
||||
if(check_alien_ability(amount,0,O_PLASMA))
|
||||
|
||||
@@ -90,7 +90,7 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
|
||||
#define L_HAND_LAYER 28 //Left-hand item
|
||||
#define R_HAND_LAYER 29 //Right-hand item
|
||||
#define WING_LAYER 30 //Wings or protrusions over the suit.
|
||||
#define TAIL_LAYER_ALT 31 //Modified tail-sprite layer. Tend to be larger.
|
||||
#define TAIL_NORTH_LAYER_ALT 31 //Modified tail-sprite layer. Tend to be larger.
|
||||
#define MODIFIER_EFFECTS_LAYER 32 //Effects drawn by modifiers
|
||||
#define FIRE_LAYER 33 //'Mob on fire' overlay layer
|
||||
#define MOB_WATER_LAYER 34 //'Mob submerged' overlay layer
|
||||
@@ -98,7 +98,7 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
|
||||
#define TOTAL_LAYERS 35 //VOREStation edit. <---- KEEP THIS UPDATED, should always equal the highest number here, used to initialize a list.
|
||||
//////////////////////////////////
|
||||
|
||||
#define GET_TAIL_LAYER (dir == NORTH ? TAIL_NORTH_LAYER : TAIL_SOUTH_LAYER)
|
||||
#define GET_TAIL_LAYER (dir == SOUTH ? TAIL_SOUTH_LAYER : TAIL_NORTH_LAYER)
|
||||
|
||||
/mob/living/carbon/human
|
||||
var/list/overlays_standing[TOTAL_LAYERS]
|
||||
@@ -836,7 +836,7 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
|
||||
suit_sprite = INV_SUIT_DEF_ICON
|
||||
|
||||
var/icon/c_mask = null
|
||||
var/tail_is_rendered = (overlays_standing[TAIL_NORTH_LAYER] || overlays_standing[TAIL_SOUTH_LAYER])
|
||||
var/tail_is_rendered = (overlays_standing[TAIL_NORTH_LAYER] || overlays_standing[TAIL_NORTH_LAYER_ALT] || overlays_standing[TAIL_SOUTH_LAYER])
|
||||
var/valid_clip_mask = tail_style?.clip_mask
|
||||
|
||||
if(tail_is_rendered && valid_clip_mask && !(istype(suit) && suit.taurized)) //Clip the lower half of the suit off using the tail's clip mask for taurs since taur bodies aren't hidden.
|
||||
@@ -954,9 +954,12 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
|
||||
return
|
||||
|
||||
remove_layer(TAIL_NORTH_LAYER)
|
||||
remove_layer(TAIL_NORTH_LAYER_ALT)
|
||||
remove_layer(TAIL_SOUTH_LAYER)
|
||||
|
||||
var tail_layer = GET_TAIL_LAYER
|
||||
var/tail_layer = GET_TAIL_LAYER
|
||||
if(tail_alt && tail_layer == TAIL_NORTH_LAYER)
|
||||
tail_layer = TAIL_NORTH_LAYER_ALT
|
||||
|
||||
var/image/tail_image = get_tail_image()
|
||||
if(tail_image)
|
||||
@@ -996,9 +999,12 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
|
||||
|
||||
/mob/living/carbon/human/proc/set_tail_state(var/t_state)
|
||||
var/tail_layer = GET_TAIL_LAYER
|
||||
if(tail_alt && tail_layer == TAIL_NORTH_LAYER)
|
||||
tail_layer = TAIL_NORTH_LAYER_ALT
|
||||
var/image/tail_overlay = overlays_standing[tail_layer]
|
||||
|
||||
remove_layer(TAIL_NORTH_LAYER)
|
||||
remove_layer(TAIL_NORTH_LAYER_ALT)
|
||||
remove_layer(TAIL_SOUTH_LAYER)
|
||||
|
||||
if(tail_overlay)
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
return
|
||||
|
||||
if(status_flags & HIDING)
|
||||
reveal("<span class='notice'>You have stopped hiding.</span>")
|
||||
reveal(FALSE, "<span class='notice'>You have stopped hiding.</span>")
|
||||
else
|
||||
status_flags |= HIDING
|
||||
layer = HIDING_LAYER //Just above cables with their 2.44
|
||||
|
||||
@@ -12,13 +12,13 @@
|
||||
var/sayselect = tgui_alert(src, "Which say-verb do you wish to customize?", "Select Verb", list("Say","Whisper","Ask (?)","Exclaim/Shout/Yell (!)","Cancel"))
|
||||
|
||||
if(sayselect == "Say")
|
||||
custom_say = lowertext(sanitize(input(usr, "This word or phrase will appear instead of 'says': [src] says, \"Hi.\"", "Custom Say", null) as text))
|
||||
custom_say = lowertext(sanitize(tgui_input_text(usr, "This word or phrase will appear instead of 'says': [src] says, \"Hi.\"", "Custom Say", null)))
|
||||
else if(sayselect == "Whisper")
|
||||
custom_whisper = lowertext(sanitize(input(usr, "This word or phrase will appear instead of 'whispers': [src] whispers, \"Hi...\"", "Custom Whisper", null) as text))
|
||||
custom_whisper = lowertext(sanitize(tgui_input_text(usr, "This word or phrase will appear instead of 'whispers': [src] whispers, \"Hi...\"", "Custom Whisper", null)))
|
||||
else if(sayselect == "Ask (?)")
|
||||
custom_ask = lowertext(sanitize(input(usr, "This word or phrase will appear instead of 'asks': [src] asks, \"Hi?\"", "Custom Ask", null) as text))
|
||||
custom_ask = lowertext(sanitize(tgui_input_text(usr, "This word or phrase will appear instead of 'asks': [src] asks, \"Hi?\"", "Custom Ask", null)))
|
||||
else if(sayselect == "Exclaim/Shout/Yell (!)")
|
||||
custom_exclaim = lowertext(sanitize(input(usr, "This word or phrase will appear instead of 'exclaims', 'shouts' or 'yells': [src] exclaims, \"Hi!\"", "Custom Exclaim", null) as text))
|
||||
custom_exclaim = lowertext(sanitize(tgui_input_text(usr, "This word or phrase will appear instead of 'exclaims', 'shouts' or 'yells': [src] exclaims, \"Hi!\"", "Custom Exclaim", null)))
|
||||
else
|
||||
return
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
set desc = "Sets OOC notes about yourself or your RP preferences or status."
|
||||
set category = "OOC"
|
||||
|
||||
var/new_metadata = sanitize(input(usr, "Enter any information you'd like others to see, such as Roleplay-preferences. This will not be saved permanently, only for this round.", "Game Preference" , html_decode(ooc_notes)) as message, extra = 0)
|
||||
var/new_metadata = sanitize(tgui_input_text(usr, "Enter any information you'd like others to see, such as Roleplay-preferences. This will not be saved permanently, only for this round.", "Game Preference" , html_decode(ooc_notes), multiline = TRUE), extra = 0)
|
||||
if(new_metadata && CanUseTopic(usr))
|
||||
ooc_notes = new_metadata
|
||||
to_chat(usr, "OOC notes updated.")
|
||||
|
||||
@@ -363,7 +363,7 @@ var/list/ai_verbs_default = list(
|
||||
if(message_cooldown)
|
||||
to_chat(src, "Please allow one minute to pass between announcements.")
|
||||
return
|
||||
var/input = input(usr, "Please write a message to announce to the station crew.", "A.I. Announcement")
|
||||
var/input = tgui_input_text(usr, "Please write a message to announce to the station crew.", "A.I. Announcement")
|
||||
if(!input)
|
||||
return
|
||||
|
||||
@@ -418,7 +418,7 @@ var/list/ai_verbs_default = list(
|
||||
if(emergency_message_cooldown)
|
||||
to_chat(usr, "<span class='warning'>Arrays recycling. Please stand by.</span>")
|
||||
return
|
||||
var/input = sanitize(input(usr, "Please choose a message to transmit to [using_map.boss_short] via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response. There is a 30 second delay before you may send another message, be clear, full and concise.", "To abort, send an empty message.", ""))
|
||||
var/input = sanitize(tgui_input_text(usr, "Please choose a message to transmit to [using_map.boss_short] via quantum entanglement. Please be aware that this process is very expensive, and abuse will lead to... termination. Transmission does not guarantee a response. There is a 30 second delay before you may send another message, be clear, full and concise.", "To abort, send an empty message.", ""))
|
||||
if(!input)
|
||||
return
|
||||
CentCom_announce(input, usr)
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
icon = 'icons/mob/pai_vr.dmi'
|
||||
softfall = TRUE
|
||||
var/eye_glow = TRUE
|
||||
var/hide_glow = FALSE
|
||||
var/image/eye_layer = null // Holds the eye overlay.
|
||||
var/eye_color = "#00ff0d"
|
||||
var/global/list/wide_chassis = list(
|
||||
@@ -46,7 +47,6 @@
|
||||
/mob/living/silicon/pai/Initialize()
|
||||
. = ..()
|
||||
|
||||
verbs |= /mob/living/proc/hide
|
||||
verbs |= /mob/proc/dominate_predator
|
||||
verbs |= /mob/living/proc/dominate_prey
|
||||
verbs |= /mob/living/proc/set_size
|
||||
@@ -147,10 +147,11 @@
|
||||
set category = "pAI Commands"
|
||||
set name = "Toggle Eye Glow"
|
||||
if(chassis in allows_eye_color)
|
||||
if(eye_glow)
|
||||
if(eye_glow && !hide_glow)
|
||||
eye_glow = FALSE
|
||||
else
|
||||
eye_glow = TRUE
|
||||
hide_glow = FALSE
|
||||
update_icon()
|
||||
else
|
||||
to_chat(src, "Your selected chassis cannot modify its eye glow!")
|
||||
@@ -182,7 +183,7 @@
|
||||
eye_layer = image(icon, "[icon_state]-eyes")
|
||||
eye_layer.appearance_flags = appearance_flags
|
||||
eye_layer.color = eye_color
|
||||
if(eye_glow)
|
||||
if(eye_glow && !hide_glow)
|
||||
eye_layer.plane = PLANE_LIGHTING_ABOVE
|
||||
add_overlay(eye_layer)
|
||||
|
||||
@@ -363,3 +364,70 @@
|
||||
return 0
|
||||
gender = new_gender_identity
|
||||
return 1
|
||||
|
||||
/mob/living/silicon/pai/verb/pai_hide()
|
||||
set name = "Hide"
|
||||
set desc = "Allows to hide beneath tables or certain items. Toggled on or off."
|
||||
set category = "Abilities"
|
||||
|
||||
hide()
|
||||
if(status_flags & HIDING)
|
||||
hide_glow = TRUE
|
||||
else
|
||||
hide_glow = FALSE
|
||||
update_icon()
|
||||
|
||||
/mob/living/silicon/pai/verb/screen_message(message as text|null)
|
||||
set category = "pAI Commands"
|
||||
set name = "Screen Message"
|
||||
set desc = "Allows you to display a message on your screen. This will show up in the chat of anyone who is holding your card."
|
||||
|
||||
if (src.client)
|
||||
if(client.prefs.muted & MUTE_IC)
|
||||
to_chat(src, "<span class='warning'>You cannot speak in IC (muted).</span>")
|
||||
return
|
||||
if(loc != card)
|
||||
to_chat(src, "<span class='warning'>Your message won't be visible while unfolded!</span>")
|
||||
if (!message)
|
||||
message = tgui_input_text(src, "Enter text you would like to show on your screen.","Screen Message")
|
||||
message = sanitize_or_reflect(message,src)
|
||||
if (!message)
|
||||
return
|
||||
message = capitalize(message)
|
||||
if (stat == DEAD)
|
||||
return
|
||||
card.screen_msg = message
|
||||
var/logmsg = "(CARD SCREEN)[message]"
|
||||
log_say(logmsg,src)
|
||||
to_chat(src, "<span class='cult'>You print a message to your screen, \"[message]\"</span>")
|
||||
if(isliving(card.loc))
|
||||
var/mob/living/L = card.loc
|
||||
if(L.client)
|
||||
to_chat(L, "<span class='cult'>[src.name]'s screen prints, \"[message]\"</span>")
|
||||
else return
|
||||
else if(isbelly(card.loc))
|
||||
var/obj/belly/b = card.loc
|
||||
if(b.owner.client)
|
||||
to_chat(b.owner, "<span class='cult'>[src.name]'s screen prints, \"[message]\"</span>")
|
||||
else return
|
||||
else if(istype(card.loc, /obj/item/device/pda))
|
||||
var/obj/item/device/pda/p = card.loc
|
||||
if(isliving(p.loc))
|
||||
var/mob/living/L = p.loc
|
||||
if(L.client)
|
||||
to_chat(L, "<span class='cult'>[src.name]'s screen prints, \"[message]\"</span>")
|
||||
else return
|
||||
else if(isbelly(p.loc))
|
||||
var/obj/belly/b = card.loc
|
||||
if(b.owner.client)
|
||||
to_chat(b.owner, "<span class='cult'>[src.name]'s screen prints, \"[message]\"</span>")
|
||||
else return
|
||||
else return
|
||||
else return
|
||||
to_chat(src, "<span class='notice'>Your message was relayed.</span>")
|
||||
for (var/mob/G in player_list)
|
||||
if (istype(G, /mob/new_player))
|
||||
continue
|
||||
else if(isobserver(G) && G.is_preference_enabled(/datum/client_preference/ghost_ears))
|
||||
if(is_preference_enabled(/datum/client_preference/whisubtle_vis) || G.client.holder)
|
||||
to_chat(G, "<span class='cult'>[src.name]'s screen prints, \"[message]\"</span>")
|
||||
|
||||
@@ -69,19 +69,19 @@ var/datum/paiController/paiController // Global handler for pAI candidates
|
||||
|
||||
switch(option)
|
||||
if("name")
|
||||
t = sanitizeSafe(input(usr, "Enter a name for your pAI", "pAI Name", candidate.name) as text, MAX_NAME_LEN)
|
||||
t = sanitizeSafe(tgui_input_text(usr, "Enter a name for your pAI", "pAI Name", candidate.name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(t)
|
||||
candidate.name = t
|
||||
if("desc")
|
||||
t = input(usr, "Enter a description for your pAI", "pAI Description", candidate.description) as message
|
||||
t = tgui_input_text(usr, "Enter a description for your pAI", "pAI Description", candidate.description, multiline = TRUE)
|
||||
if(t)
|
||||
candidate.description = sanitize(t)
|
||||
if("role")
|
||||
t = input(usr, "Enter a role for your pAI", "pAI Role", candidate.role) as text
|
||||
t = tgui_input_text(usr, "Enter a role for your pAI", "pAI Role", candidate.role)
|
||||
if(t)
|
||||
candidate.role = sanitize(t)
|
||||
if("ooc")
|
||||
t = input(usr, "Enter any OOC comments", "pAI OOC Comments", candidate.comments) as message
|
||||
t = tgui_input_text(usr, "Enter any OOC comments", "pAI OOC Comments", candidate.comments, multiline = TRUE)
|
||||
if(t)
|
||||
candidate.comments = sanitize(t)
|
||||
if("save")
|
||||
|
||||
@@ -353,7 +353,7 @@
|
||||
|
||||
spawn(0)
|
||||
var/newname
|
||||
newname = sanitizeSafe(input(src,"You are a robot. Enter a name, or leave blank for the default name.", "Name change","") as text, MAX_NAME_LEN)
|
||||
newname = sanitizeSafe(tgui_input_text(src,"You are a robot. Enter a name, or leave blank for the default name.", "Name change","", MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if (newname)
|
||||
custom_name = newname
|
||||
sprite_name = newname
|
||||
|
||||
@@ -300,7 +300,7 @@
|
||||
/obj/item/weapon/pen/robopen/proc/RenamePaper(mob/user, obj/item/weapon/paper/paper)
|
||||
if ( !user || !paper )
|
||||
return
|
||||
var/n_name = sanitizeSafe(input(user, "What would you like to label the paper?", "Paper Labelling", null) as text, 32)
|
||||
var/n_name = sanitizeSafe(tgui_input_text(user, "What would you like to label the paper?", "Paper Labelling", null, 32), 32)
|
||||
if ( !user || !paper )
|
||||
return
|
||||
|
||||
|
||||
@@ -259,14 +259,14 @@
|
||||
set desc = "Sets a description which will be shown when someone examines you."
|
||||
set category = "IC"
|
||||
|
||||
pose = sanitize(input(usr, "This is [src]. It is...", "Pose", null) as text)
|
||||
pose = sanitize(tgui_input_text(usr, "This is [src]. It is...", "Pose", null))
|
||||
|
||||
/mob/living/silicon/verb/set_flavor()
|
||||
set name = "Set Flavour Text"
|
||||
set desc = "Sets an extended description of your character's features."
|
||||
set category = "IC"
|
||||
|
||||
flavor_text = sanitize(input(usr, "Please enter your new flavour text.", "Flavour text", null) as text)
|
||||
flavor_text = sanitize(tgui_input_text(usr, "Please enter your new flavour text.", "Flavour text", null))
|
||||
|
||||
/mob/living/silicon/binarycheck()
|
||||
return 1
|
||||
|
||||
@@ -213,6 +213,7 @@
|
||||
// Since they have bellies, add verbs to toggle settings on them.
|
||||
verbs |= /mob/living/simple_mob/proc/toggle_digestion
|
||||
verbs |= /mob/living/simple_mob/proc/toggle_fancygurgle
|
||||
verbs |= /mob/living/proc/vertical_nom
|
||||
|
||||
//A much more detailed version of the default /living implementation
|
||||
var/obj/belly/B = new /obj/belly(src)
|
||||
|
||||
@@ -257,7 +257,7 @@ var/list/_cat_default_emotes = list(
|
||||
if(named)
|
||||
to_chat(user, "<span class='notice'>\The [name] already has a name!</span>")
|
||||
else
|
||||
var/tmp_name = sanitizeSafe(input(user, "Give \the [name] a name", "Name"), MAX_NAME_LEN)
|
||||
var/tmp_name = sanitizeSafe(tgui_input_text(user, "Give \the [name] a name", "Name", null, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(length(tmp_name) > 50)
|
||||
to_chat(user, "<span class='notice'>The name can be at most 50 characters long.</span>")
|
||||
else
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
to_chat(src, "<span class='userdanger'>You've already set your name. Ask an admin to toggle \"nameset\" to 0 if you really must.</span>")
|
||||
return
|
||||
var/newname
|
||||
newname = sanitizeSafe(input(src,"Set your name. You only get to do this once. Max 52 chars.", "Name set","") as text, MAX_NAME_LEN)
|
||||
newname = sanitizeSafe(tgui_input_text(src,"Set your name. You only get to do this once. Max 52 chars.", "Name set","", MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if (newname)
|
||||
name = newname
|
||||
voice_name = newname
|
||||
@@ -30,7 +30,7 @@
|
||||
set desc = "Set your description."
|
||||
set category = "Abilities"
|
||||
var/newdesc
|
||||
newdesc = sanitizeSafe(input(src,"Set your description. Max 4096 chars.", "Description set","") as text, MAX_MESSAGE_LEN)
|
||||
newdesc = sanitizeSafe(tgui_input_text(src,"Set your description. Max 4096 chars.", "Description set",""), MAX_MESSAGE_LEN)
|
||||
if(newdesc)
|
||||
desc = newdesc
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
set desc = "Changes your name."
|
||||
set src = usr
|
||||
|
||||
var/new_name = sanitizeSafe(input(src, "Who would you like to be now?", "Communicator", src.client.prefs.real_name) as text, MAX_NAME_LEN)
|
||||
var/new_name = sanitizeSafe(tgui_input_text(src, "Who would you like to be now?", "Communicator", src.client.prefs.real_name, MAX_NAME_LEN), MAX_NAME_LEN)
|
||||
if(new_name)
|
||||
if(comm)
|
||||
comm.visible_message("<span class='notice'>[bicon(comm)] [src.name] has left, and now you see [new_name].</span>")
|
||||
|
||||
@@ -293,7 +293,7 @@
|
||||
set src in usr
|
||||
if(usr != src)
|
||||
to_chat(usr, "No.")
|
||||
var/msg = sanitize(input(usr,"Set the flavor text in your 'examine' verb.","Flavor Text",html_decode(flavor_text)) as message|null, extra = 0) //VOREStation Edit: separating out OOC notes
|
||||
var/msg = sanitize(tgui_input_text(usr,"Set the flavor text in your 'examine' verb.","Flavor Text",html_decode(flavor_text), multiline = TRUE), extra = 0) //VOREStation Edit: separating out OOC notes
|
||||
|
||||
if(msg != null)
|
||||
flavor_text = msg
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
return
|
||||
|
||||
if(!new_type)
|
||||
new_type = input(usr, "Mob type path:", "Mob type") as text|null
|
||||
new_type = tgui_input_text(usr, "Mob type path:", "Mob type")
|
||||
|
||||
if(istext(new_type))
|
||||
new_type = text2path(new_type)
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
var/input
|
||||
if(!message)
|
||||
input = sanitize_or_reflect(input(src,"Choose an emote to display.") as text|null, src)
|
||||
input = sanitize_or_reflect(tgui_input_text(src,"Choose an emote to display."), src)
|
||||
else
|
||||
input = message
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
to_chat(src, "<span class='warning'>You cannot speak in IC (muted).</span>")
|
||||
return
|
||||
if (!message)
|
||||
message = input(usr, "Type a message to say.","Psay") as text|null
|
||||
message = tgui_input_text(usr, "Type a message to say.","Psay")
|
||||
message = sanitize_or_reflect(message,src)
|
||||
if (!message)
|
||||
return
|
||||
@@ -204,7 +204,7 @@
|
||||
to_chat(src, "<span class='warning'>You cannot speak in IC (muted).</span>")
|
||||
return
|
||||
if (!message)
|
||||
message = input(usr, "Type a message to emote.","Pme") as text|null
|
||||
message = tgui_input_text(usr, "Type a message to emote.","Pme")
|
||||
message = sanitize_or_reflect(message,src)
|
||||
if (!message)
|
||||
return
|
||||
|
||||
@@ -40,11 +40,7 @@
|
||||
set hidden = 1
|
||||
|
||||
set_typing_indicator(TRUE)
|
||||
var/message
|
||||
if(usr.client.prefs.tgui_input_mode)
|
||||
message = tgui_input_text(usr, "Type your message:", "Say")
|
||||
else
|
||||
message = input(usr, "Type your message:", "Say") as text
|
||||
var/message = tgui_input_text(usr, "Type your message:", "Say")
|
||||
set_typing_indicator(FALSE)
|
||||
|
||||
if(message)
|
||||
@@ -55,11 +51,7 @@
|
||||
set hidden = 1
|
||||
|
||||
set_typing_indicator(TRUE)
|
||||
var/message
|
||||
if(usr.client.prefs.tgui_input_mode)
|
||||
message = tgui_input_message(usr, "Type your message:", "Emote")
|
||||
else
|
||||
message = input(usr, "Type your message:", "Emote") as message
|
||||
var/message = tgui_input_text(usr, "Type your message:", "Emote", multiline = TRUE)
|
||||
set_typing_indicator(FALSE)
|
||||
|
||||
if(message)
|
||||
@@ -70,11 +62,7 @@
|
||||
set name = ".Whisper"
|
||||
set hidden = 1
|
||||
|
||||
var/message
|
||||
if(usr.client.prefs.tgui_input_mode)
|
||||
message = tgui_input_text(usr, "Type your message:", "Whisper")
|
||||
else
|
||||
message = input(usr, "Type your message:", "Whisper") as text
|
||||
var/message = tgui_input_text(usr, "Type your message:", "Whisper")
|
||||
|
||||
if(message)
|
||||
whisper(message)
|
||||
@@ -83,11 +71,7 @@
|
||||
set name = ".Subtle"
|
||||
set hidden = 1
|
||||
|
||||
var/message
|
||||
if(usr.client.prefs.tgui_input_mode)
|
||||
message = tgui_input_message(usr, "Type your message:", "Subtle")
|
||||
else
|
||||
message = input(usr, "Type your message:", "Subtle") as message
|
||||
var/message = tgui_input_text(usr, "Type your message:", "Subtle", multiline = TRUE)
|
||||
|
||||
if(message)
|
||||
me_verb_subtle(message)
|
||||
|
||||
Reference in New Issue
Block a user