Sanitizes input

Follows similar procedure to setting custom race name in the character setup panel.
This commit is contained in:
KeenShayne
2021-08-21 00:59:08 -04:00
parent c488222abe
commit 87d998dad0
@@ -92,7 +92,8 @@
if(can_change(APPEARANCE_RACE) && (params["race"] in valid_species))
if(target.change_species(params["race"]))
if(params["race"] == "Custom Species")
target.custom_species = input(usr,"Custom Species name:","Species Name")
target.custom_species = sanitize(input(usr, "Input custom species name:",
"Custom Species Name") as null|text, MAX_NAME_LEN)
cut_data()
generate_data(usr)
changed_hook(APPEARANCECHANGER_CHANGED_RACE)