Page 1 of 1

how make a ball bounce of wall constantly

PostPosted: Sun Oct 03, 2010 6:16 am
by smoothie
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.

Re: how make a ball bounce of wall constantly

PostPosted: Sun Oct 03, 2010 7:38 am
by lcl
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

Re: how make a ball bounce of wall constantly

PostPosted: Sun Oct 03, 2010 8:09 am
by smoothie
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

Re: how make a ball bounce of wall constantly

PostPosted: Sun Oct 03, 2010 8:23 am
by lcl
Ok, do this:

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


:D

Re: how make a ball bounce of wall constantly

PostPosted: Sun Oct 03, 2010 8:36 am
by smoothie
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.