Discuss Scratch

dor6000
Scratcher
35 posts

Typing system

Hi I'm creating a new game, one of the systems in the game is typing (like word)
how can I program a typing script?
oscarfinley
Scratcher
100+ posts

Typing system

could you just use the question feature, as in:
ask [question] and wait
then check the answer with
if <(answer) = [the correct text]> then

end

f4f?
half my time is spent telling people off for spamming, necroposting, or bumping for no reason
deck26
Scratcher
1000+ posts

Typing system

Otherwise search for text engines to see how others have done this.
dor6000
Scratcher
35 posts

Typing system

oscarfinley wrote:

could you just use the question feature, as in:
ask [question] and wait
then check the answer with
if <(answer) = [the correct text]> then

end
I mean typing like word
dimitrip
Scratcher
500+ posts

Typing system

Hi.

Typing like word could be achieved by creating clones of letters, and putting for each clone (letter), the costume (character) of the letter you typed.
Unfortunately there is a limitation in the nr of clones, so you won't be able typing lots of sentences this way.

Another way, is to use the stamping of a sprite. You make a single sprite like in this project, you choose the correct costume depending on the character typed (here only a, b, c, d, e, i and w work). You then make it move at correct typing position, and you “stamp” your sprite on the background.
Notice: that way, you don't keep any recording of what's been typed. You just “paint” a text.
You'll see a small trick to rubbout the last typed char, with an “eraser” (use the left arrow, NOT the delete key).
Auto and manual line breaks are not handled; it's just an example.

If you want the text to “keep” recorded, you might use a table or a long string, that you might completely redisplay using stamping, at each text editing operation.

Greetz,

Dimitri


For what concerns my own Scratch stuff, it's all provided under Creative Commons level zero license.
dor6000
Scratcher
35 posts

Typing system

Thank you

Last edited by dor6000 (Nov. 15, 2019 15:33:54)

chaoxplayz
Scratcher
6 posts

Typing system

when green flag clicked
forever
if <key [ Ctrl] pressed?> then
Run 5 steps
end
end

Last edited by chaoxplayz (Jan. 11, 2021 16:24:03)

Powered by DjangoBB