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

#1 2011-07-13 10:40:24

Legolas_Greenleaf
Scratcher
Registered: 2011-06-16
Posts: 86

Sensing in Monochrome Game

I hope this is in the right forum...  So, I am testing my game-making skills in a black-and-white scroller that is in the process of being made.  I have only one problem: How do I get the person to stop falling through the floor?!  This is extremely annoying, and I like my projects to be perfect at best.  (I know, this is sometimes called "perfectionism" and it is just as annoying as the problem I just described sometimes  big_smile  )  So anyways, should I make a sort of bumper sprite that goes to the bottom area of the person?  If so (I can make it go to the bottom, obviously), what scripts should I use to prevent the person from falling through the floor?


http://25.media.tumblr.com/tumblr_m8s5zeoqje1qky8rdo1_250.gif  OPPAN GANGNAM STYLE~

Offline

 

#2 2011-07-13 11:14:25

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

Re: Sensing in Monochrome Game

Have you dabbled with velocity yet?  Now could be a good time to learn if not.

You can try this:  http://i52.tinypic.com/2m6agwk.gif

This way is smooth, but your character may sink a small bit into the floor after falling.  There are methods to correct this, though they make the script more complex.

If you want to see a near perfect collision engine (with no sinking), you can look at and study this project: http://scratch.mit.edu/projects/Kileyme … est/872391


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

 

#3 2011-07-13 19:11:21

hmnwilson
Scratcher
Registered: 2007-07-04
Posts: 1000+

Re: Sensing in Monochrome Game

One of the best platforming engines on the site can be found here: http://scratch.mit.edu/projects/RHY3756547/845502

This uses no color detection, so it'll definitely work for you! All you need to do is import the Player sprite into your project, then copy its scripts into your character. Also, make sure you have a sprite called "Level" so it knows what's solid and what's not.


I'm taking a break from Scratch until 2.0 comes out. Any messages sent between then and now probably won't be read - sorry.
(Oct. 20, 2011)

Offline

 

Board footer