This site requires JavaScript, please enable it in your browser!
Greenfoot back

Report as inappropriate.

Entity1037 presents ...


Collision Physics (Gravity) 1.2.3


Left Click: fling ball

Right click: add/remove ball

S: toggle shadow imagery

G: toggle gravity

Arrow Keys: change gravity direction

P.S..: Feel free to use this engine if you'd like.

7779 views / 1407 in the last 7 days

13 votes | 1 in the last 7 days

Tags: mouse simulation physics with-source

This scenario is a member of: Reusable actors & support classes

open in greenfoot
Your browser does not support the canvas tag.


mhhmm would be a nice project i could sit at :)


No seriously, how would that work??


getting the distance between the sphere centers via pythagoras. and then get the angle of collision to get the protection vector i think, but just my theorem


Ooooh, I never thought of that. Cool! I'll probably leave you to do it though. This physics engine I made is mainly for non-realistic video games like Megaman or Zelda. I wouldn't really have a use to make something like that.


By that I mean a 360 degree hit detection engine.


get a realistic collision detection of balls even with bounce and maybe also with friction would be nice if i get such a thing working
A new version of this scenario was uploaded on Tue May 20 18:03:38 UTC 2014 *collisions now detect for colored pixels of images instead of actor's themselves
A new version of this scenario was uploaded on Wed Jul 23 04:06:16 UTC 2014 +Added frame skipping


That's cool.
A new version of this scenario was uploaded on Fri Aug 29 20:41:56 UTC 2014 *Cut amount of detection lines down to 5 for each direction (greatly reducing lag).

See all comments

Want to leave a comment? You must first log in.

Who likes this?

TheLostCode pnchn Excelsior JasonZhu lordhershey bourne ShoutToUs RUMMAKER sametguzelgun nightwingx13 BobcotttheThinker FlyingRabidUnicornPig SPower