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

#1 2009-03-09 10:23:11

chadders09
Scratcher
Registered: 2009-03-09
Posts: 3

Help with if else block

Hi am trying to make a simple shootout game to demonstrate the if else block to students.  Can you tell me why it still displays 'miss' when the ball hits the goal.
This is a segmant of the code I am using:

[blocks]
<when[space  ]key pressed>
<if><touching[goal]
<say[ goal ]for( 2 )secs>
<else> <say[ miss ]for( 2 )secs>

[/blocks]

Thanks in advance  smile

Offline

 

#2 2009-03-09 10:27:39

chadders09
Scratcher
Registered: 2009-03-09
Posts: 3

Re: Help with if else block

Forget last message, have figured it out  smile

Offline

 

#3 2009-03-09 13:21:32

yambanshee
Scratcher
Registered: 2007-11-06
Posts: 500+

Re: Help with if else block

im guessing because its the for 2 seconds part. try just using <say[ goal ]

Offline

 

Board footer