how make a ball bounce of wall constantly

Game Editor comments and discussion.

how make a ball bounce of wall constantly

Postby smoothie » Sun Oct 03, 2010 6:16 am

so do any of you awesome people feel like helping noob like me. if you do could you please tell me how to make ball constantly just bounce of walls in a box with no gravity because when i try to do it the ball just does nothing so i have to get a canvas for it bounce off of but it dosent last for long. i do this making the clossion with the canvas and make it big enough so ball bounces around inside. but i have but a frame around the erea where i want the ball to bounce and i dont want to have to use the canvas because then ball get too fast and fly's out of the erea where its ment to be in.
User avatar
smoothie
 
Posts: 32
Joined: Sat Oct 02, 2010 11:51 am
Score: 0 Give a positive score

Re: how make a ball bounce of wall constantly

Postby lcl » Sun Oct 03, 2010 7:38 am

You have the area as animaation on some actor, am I right?

If you have, you can do it like this.
Ball - add action - collision anu side or area, repeat: yes.
Physical response - set numbers like this: 1, 1, 1, 1.

This should work. :D
User avatar
lcl
 
Posts: 2339
Joined: Thu Mar 25, 2010 5:55 pm
Location: Finland
Score: 276 Give a positive score

Re: how make a ball bounce of wall constantly

Postby smoothie » Sun Oct 03, 2010 8:09 am

thanks the collision worked but the ball just sits there is was wondering could you tell me how to make it go at sertain speed so when the game starts lets say 5. i want it to go in a random diretcion from 0 to 360 decgress
User avatar
smoothie
 
Posts: 32
Joined: Sat Oct 02, 2010 11:51 am
Score: 0 Give a positive score

Re: how make a ball bounce of wall constantly

Postby lcl » Sun Oct 03, 2010 8:23 am

Ok, do this:

Ball - create actor - script editor:
Code: Select all
angle = rand(360);
directional_velocity = 5;


:D
User avatar
lcl
 
Posts: 2339
Joined: Thu Mar 25, 2010 5:55 pm
Location: Finland
Score: 276 Give a positive score

Re: how make a ball bounce of wall constantly

Postby smoothie » Sun Oct 03, 2010 8:36 am

thanks for that it help a lot and worked the way i wanted it to. i love game editor its an awesome program and the language actually makes sense and i have so far always gotten the answers ive wanted and theyve worked just the way i want them too so thank you every one for your answers. before i came and found game editor i was a game maker user and their languge did'nt make much sense and when ever i looked for answers i never got them so im so glad i found game editor. im not going to ever go back to it because game editor is so much better and its free game maker isn't. so thankyou everyone

by the way is it possible to get rid of the white or what ever coloured box around a sprite when ever you make or cut out one in game editor.
User avatar
smoothie
 
Posts: 32
Joined: Sat Oct 02, 2010 11:51 am
Score: 0 Give a positive score


Return to GE - General

Who is online

Users browsing this forum: No registered users and 1 guest

cron