Skip to content

Simulate the behavior of the gravitation between bodies.

License

Notifications You must be signed in to change notification settings

MoritzLue24/Gravitator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gravitator

Simulate the behavior of the gravitation between bodies.

Requirements

  • pygame==2.1.2
  • VectorUtils==1.3.4

Usage

  • Install python
  • Set up virtualenv, if you want to
  • Install pip packages with pip install -r requirements.txt
  • Run with python python Gravitator

Controls

  • Press and hold Leftclick to create a body.
  • Press and hold Rightclick
  • Press Backspace to remove the last body.
  • Press c to remove all bodies.
  • Press Esc to pause / continue.

Scripts

If you are running a custom script, you can use everything, that is inside the Gravitator.Application class. Make sure to write self. infront of the variables and methods you are using.