This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2008-06-29 21:37:34

Bluestribute
Scratcher
Registered: 2008-01-24
Posts: 1000+

[Key Pressed] Block

I have seen this, and I would agree. I was think, and why not make a block called [Key Pressed]? Whatever key is pressed, [Key Pressed] would switch to that. [Key Pressed] would be used for those typewriter games. You would say forever, switch to costume [key Pressed]. And maybe (since your costumes might be called 1,2,3 etc) each key on the keyboard would get a value, like A=1, B=2, Space=27, etc, so you can use it with any thing.


http://img247.imageshack.us/img247/1204/bluestributett4.jpg
That's my PSN ID. I know tons of COD4 glitches. Add me as your friend. Oh, and get a headset

Offline

 

#2 2008-06-30 06:04:56

s_federici
Scratcher
Registered: 2007-12-18
Posts: 500+

Re: [Key Pressed] Block

Do you mean the last key pressed? I guess this is fine. Maybe it should be also possible to reset the key, so repetitions of a key will be easily detected?

Offline

 

#3 2008-06-30 11:42:19

bigB
Scratcher
Registered: 2007-06-09
Posts: 100+

Re: [Key Pressed] Block

so would both '1' and 'A' set the variable to 1?


http://scratch.mit.edu/projects/bigB/260981 Draw to Text
http://scratch.mit.edu/projects/bigB/181829 3D Stunt Flyer

Offline

 

#4 2008-06-30 11:43:12

Bluestribute
Scratcher
Registered: 2008-01-24
Posts: 1000+

Re: [Key Pressed] Block

bigB wrote:

so would both '1' and 'A' set the variable to 1?

If they did that, they would need to figure all that stuff out. I just thought of using it for making easier word processors


http://img247.imageshack.us/img247/1204/bluestributett4.jpg
That's my PSN ID. I know tons of COD4 glitches. Add me as your friend. Oh, and get a headset

Offline

 

#5 2008-06-30 12:01:41

bigB
Scratcher
Registered: 2007-06-09
Posts: 100+

Re: [Key Pressed] Block

i think half the point of making a word processor on scratch is to be able to boast about how long your attention span is.


http://scratch.mit.edu/projects/bigB/260981 Draw to Text
http://scratch.mit.edu/projects/bigB/181829 3D Stunt Flyer

Offline

 

#6 2008-06-30 12:02:59

Bluestribute
Scratcher
Registered: 2008-01-24
Posts: 1000+

Re: [Key Pressed] Block

bigB wrote:

i think half the point of making a word processor on scratch is to be able to boast about how long your attention span is.

lol. But I was going to try something else that remembers what you wrote and types it back to you. But that'd be 26 scripts for typing and than 26 scripts of remembering like 27 different colors (space is a color).

Last edited by Bluestribute (2008-06-30 12:03:52)


http://img247.imageshack.us/img247/1204/bluestributett4.jpg
That's my PSN ID. I know tons of COD4 glitches. Add me as your friend. Oh, and get a headset

Offline

 

#7 2008-06-30 12:14:23

bigB
Scratcher
Registered: 2007-06-09
Posts: 100+

Re: [Key Pressed] Block

that would be good but your right it would be a lot of work at the moment.


http://scratch.mit.edu/projects/bigB/260981 Draw to Text
http://scratch.mit.edu/projects/bigB/181829 3D Stunt Flyer

Offline

 

#8 2008-06-30 12:27:01

JSO
Community Moderator
Registered: 2007-06-23
Posts: 1000+

Re: [Key Pressed] Block

I agree this is a good suggestion. however, [key pressed] should return an ASCII value. That is probably the easiest to use.


http://oi48.tinypic.com/2v1q0e9.jpg

Offline

 

#9 2008-06-30 13:09:50

bigB
Scratcher
Registered: 2007-06-09
Posts: 100+

Re: [Key Pressed] Block

what is an ASCII value?


http://scratch.mit.edu/projects/bigB/260981 Draw to Text
http://scratch.mit.edu/projects/bigB/181829 3D Stunt Flyer

Offline

 

#10 2008-06-30 14:09:49

Paddle2See
Scratch Team
Registered: 2007-10-27
Posts: 1000+

Re: [Key Pressed] Block

bigB wrote:

what is an ASCII value?

It is a standard set of codes for the keyboard keys.  See the Wikipedia link below

http://en.wikipedia.org/wiki/ASCII


http://i39.tinypic.com/2nav6o7.gif

Offline

 

#11 2008-07-03 11:44:25

fullmoon
Retired Community Moderator
Registered: 2007-06-04
Posts: 1000+

Re: [Key Pressed] Block

ASCII? Are you trying to kill us? Just wait until they implement strings, nobody wants to memorize 255 values. Besides, Scratch only supports a few keys.


http://i302.photobucket.com/albums/nn100/fullmoon32/wow.jpg

Offline

 

#12 2008-07-03 12:10:59

registeel
Scratcher
Registered: 2008-04-27
Posts: 500+

Re: [Key Pressed] Block

What... do you mean like if <key[ any ]pressed?>

Offline

 

Board footer