Here ya all go, its even in a function.
I don't want to think about a timer based backspace, so when you hit backspace, it'll all be gone. So, that's for you guys to figure out.
sync on
global txt$
do
cls
` Call Function with a question of Hi :
text 5,5,txtinput("HI :", 10)
sync
loop
function txtinput(question$, max)
` If you hit, enter, or backspace or if you hit more than allowed
if scancode() <> 156 and scancode()<>54 and scancode() <> 14 and len(txt$) < max
` Make the current keypresses from Windows added to the string
txt$=txt$+ entry$()
` Clear that current keypresses
clear entry buffer
else
` If not, then clear it anyway.
clear entry buffer
` Did you hit backspace?
if scancode()=14
` delete one of the right of the string
txt$=left$(txt$,len(txt$)-1)
endif
endif
` Add up the text
final$ = question$+txt$
` Spit out the results
endfunction final$
Your mom has been erased by a mod from you telling too many "your mom" jokes.
