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

#1 2009-12-12 16:20:59

Yeyoxcore
Scratcher
Registered: 2009-10-06
Posts: 6

need help whit ball game!!

I'm making a game, fighting between balls, with the angle of view from above, (NO force of gravity) in which they can play up to 3 players:

[IMG] http://img228.imageshack.us/img228/7495/50462979.th.png [/ IMG]



balls have each chosen according to an acceleration, if you press the up the velociadad in x. and if it stops pressing down on x / 2. but I can not make a system where when collision with another ball or playing against the walls or blue according rebound was due, and if it hits the ball bouncing enemy push you apart.


I hope that will help me



and sorry for bad English


EYE: e seen muchso tutorials but they all have the angle as playing Mario Bros style. I need to move sideways, as if no jump.

Offline

 

#2 2009-12-12 16:39:24

Magnie
Scratcher
Registered: 2007-12-12
Posts: 1000+

Re: need help whit ball game!!

This should be in "All About Scratch"  smile

Offline

 

#3 2009-12-17 04:24:18

sparks
Community Moderator
Registered: 2008-11-05
Posts: 1000+

Re: need help whit ball game!!

Hi, I'll have a go at answering your question, but I've never actually tried this type of project myself. I reckon you could use the "if touching edge, bounce" block to change the direction while still keeping the velocity of the ball for the walls. To do this, you might have to assign the velocity to a variable in general, rather than to a single axes. However, for the collision with another ball (which, by the way, is a great idea) I can't think of a method for making them bounce of each other at an angle proportionate to the angle the two balls hit - only that they bounce off each other, moving in the opposite direction totheir original velocity. (use "if touching <other ball> then point in direction (direction -1)" to achieve that". I can suggest that you ask Paddle2See or the-whiz as they are both very mathematically oriented programmers and may already have come up with the scripting you need.

Hope that helps - good luck with the game.

Sparks.


http://img541.imageshack.us/img541/7563/scratchbetabanner.png

Offline

 

Board footer