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

#1 2013-04-01 09:06:30

Gamemastr001
New Scratcher
Registered: 2013-01-28
Posts: 1

walls

how do you make the sprite STOP when they touch a wall?????????????

Offline

 

#2 2013-04-01 13:57:17

xlk
Scratcher
Registered: 2013-03-18
Posts: 57

Re: walls

Well, depends if the wall is an image or a sprite.

Here's code for black walls, and for a wall sprite.

when gf clicked
forever
 if <not<touching color [#000000]?>>
  move
 end
end

when gf clicked
forever
 if <not<touching [wall]?>>
  move
 end
end

Offline

 

Board footer