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

#1 2013-01-04 13:08:13

Tbtemplex97
Scratcher
Registered: 2011-11-12
Posts: 100+

Layers

in my project, i have a major mproblem where the layers are messed up.

e.g if you go infront of 1 tree you can see through to another tree, this is a problem with scratch and is there any way to make the layers go to front from the closest to you?


Online Status: http://blocks.scratchr.org/API.php?action=onlineStatus&user=Tbtemplex97
Darkspace Coming Soon!, Try the Singleplayer Demo

Offline

 

#2 2013-01-04 15:39:14

BLU_Spy
Scratcher
Registered: 2012-01-05
Posts: 1000+

Re: Layers

Try using those blocks:

go to front
go back ( ) layers

They're on the 'Looks' section.  wink

Last edited by BLU_Spy (2013-01-04 15:39:36)


I HAVE SWITCHED ACCOUNTS! My new username is NoxSpooth.

Offline

 

#3 2013-01-04 17:47:40

Tbtemplex97
Scratcher
Registered: 2011-11-12
Posts: 100+

Re: Layers

The game im talking about is a 3d engine and you cant just use go to front, you need the different sprites to change layers dependant on where you are.


Online Status: http://blocks.scratchr.org/API.php?action=onlineStatus&user=Tbtemplex97
Darkspace Coming Soon!, Try the Singleplayer Demo

Offline

 

#4 2013-01-04 20:10:15

Kileymeister
Scratcher
Registered: 2008-04-17
Posts: 1000+

Re: Layers

You can make sprites constantly go to the front then move back enough layers to be behind the main sprite, for example if the main character sprite is near the first layer you can do this:

http://i50.tinypic.com/2rm2zrt.gif

Now if the sprite is behind the player, it will move behind it, but when it isn't behind the player, it will just go to the front.

Scratch renders graphical changes only after the script has been completed, so it won't actually be at the front before it moves back if it's behind the player (although you might see it flash if you don't run it in presentation mode/online).

Last edited by Kileymeister (2013-01-04 20:12:29)


I'm back, and showcasing two new* projects!  Click left or right on the image below to see!
http://img109.imageshack.us/img109/7905/part1l.pnghttp://img859.imageshack.us/img859/6417/part2bf.png

Offline

 

Board footer