From 800574414e0cbae3c66d698cf0f37e4a6f0dba01 Mon Sep 17 00:00:00 2001 From: Erthilo Date: Sat, 2 Jun 2012 22:09:00 +0100 Subject: [PATCH] Flavor text and records fixes. They can be longer than 40 characters. --- code/modules/mob/new_player/preferences.dm | 26 ++++++++-------------- 1 file changed, 9 insertions(+), 17 deletions(-) diff --git a/code/modules/mob/new_player/preferences.dm b/code/modules/mob/new_player/preferences.dm index e810b05b301..06267f4cbbe 100644 --- a/code/modules/mob/new_player/preferences.dm +++ b/code/modules/mob/new_player/preferences.dm @@ -407,16 +407,16 @@ datum/preferences HTML += "Medical Records
" if(lentext(med_record) <= 40) - HTML += "
[med_record]
" + HTML += "[med_record]" else - HTML += "
[copytext(med_record, 1, 37)]...
" + HTML += "[copytext(med_record, 1, 37)]..." - HTML += "Security Records
" + HTML += "

Security Records
" if(lentext(sec_record) <= 40) - HTML += "
[sec_record]
" + HTML += "[sec_record]
" else - HTML += "
[copytext(sec_record, 1, 37)]...
" + HTML += "[copytext(sec_record, 1, 37)]...
" HTML += "
" HTML += "\[Done\]" @@ -707,7 +707,7 @@ datum/preferences if(link_tags["OOC"]) var/tempnote = "" - tempnote = copytext(sanitize(input(user, "Please enter your OOC Notes!:", "OOC notes" , metadata) as text),1,MAX_MESSAGE_LEN) + tempnote = copytext(sanitize(input(user, "Please enter your OOC Notes!:", "OOC notes" , metadata) as text),1,1000) if(tempnote) metadata = tempnote return @@ -924,7 +924,7 @@ datum/preferences be_random_name = !be_random_name if(link_tags["flavor_text"]) - var/msg = copytext(sanitize(input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(flavor_text)) as message),1,MAX_NAME_LEN) + var/msg = copytext(sanitize(input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(flavor_text)) as message),1,1000) if(msg != null) msg = html_encode(msg) @@ -1035,7 +1035,7 @@ datum/preferences user << browse(null, "window=records") if(link_tags["med_record"]) - var/medmsg = copytext(sanitize(input(usr,"Set your medical notes here.","Medical Records",html_decode(med_record)) as message),1,MAX_NAME_LEN) + var/medmsg = copytext(sanitize(input(usr,"Set your medical notes here.","Medical Records",html_decode(med_record)) as message),1,2000) if(medmsg != null) medmsg = html_encode(medmsg) @@ -1044,7 +1044,7 @@ datum/preferences SetRecords(user) if(link_tags["sec_record"]) - var/secmsg = copytext(sanitize(input(usr,"Set your security notes here.","Security Records",html_decode(sec_record)) as message),1,MAX_NAME_LEN) + var/secmsg = copytext(sanitize(input(usr,"Set your security notes here.","Security Records",html_decode(sec_record)) as message),1,2000) if(secmsg != null) secmsg = html_encode(secmsg) @@ -1052,14 +1052,6 @@ datum/preferences sec_record = secmsg SetRecords(user) - if(link_tags["flavor_text"]) - var/msg = copytext(sanitize(input(usr,"Set the flavor text in your 'examine' verb. This can also be used for OOC notes and preferences!","Flavor Text",html_decode(flavor_text)) as message),1,MAX_NAME_LEN) - - if(msg != null) - msg = html_encode(msg) - - flavor_text = msg - ShowChoices(user) proc/copy_to(mob/living/carbon/human/character, safety = 0)