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

#1 2012-06-29 13:44:33

concentrating
New Scratcher
Registered: 2012-06-28
Posts: 19

Scrollx

I am trying to make a platform game which needs scrolling. Could experienced scratchers tell me how.

Offline

 

#2 2012-06-29 14:27:37

sanjayraj
Scratcher
Registered: 2012-03-25
Posts: 500+

Re: Scrollx

you could do something like this:

when gf clicked
forever
if < key [left arrow v] pressed ?>
change [scroll X v] by [4]
end
if < key [right arrow v] pressed ?>
change [scroll X v] by [-4]
end
when gf clicked
forever
set X to ( (scroll X) + [0]) 

Last edited by sanjayraj (2012-06-29 14:30:38)


http://i46.tinypic.com/23sw40j.png

Offline

 

#3 2012-06-29 18:30:43

concentrating
New Scratcher
Registered: 2012-06-28
Posts: 19

Re: Scrollx

Thanks.

Offline

 

#4 2012-06-29 18:55:41

sanjayraj
Scratcher
Registered: 2012-03-25
Posts: 500+

Re: Scrollx

concentrating wrote:

Thanks.

Your welcome!


http://i46.tinypic.com/23sw40j.png

Offline

 

#5 2012-08-08 07:54:49

concentrating
New Scratcher
Registered: 2012-06-28
Posts: 19

Re: Scrollx

[scratchblocks]
when gf clicked
forever
end

Offline

 

#6 2012-08-08 08:02:32

gooeygoo
Scratcher
Registered: 2012-05-07
Posts: 82

Re: Scrollx

concentrating wrote:

when gf clicked
forever
end

Fixed  wink


Play meh games, dont beh shy!!!
http://scratch.mit.edu/users/gooeygoo

Offline

 

#7 2012-08-08 08:19:54

ErnieParke
Scratcher
Registered: 2010-12-03
Posts: 1000+

Re: Scrollx

gooeygoo wrote:

concentrating wrote:

when gf clicked
forever
end

Fixed  wink

You forgot something:

when gf clicked
forever


http://i46.tinypic.com/35ismmc.png

Offline

 

Board footer