Skip to main content

Floating Hippo is a simple, abstracted, and easy to use library for 2D simulations using Pymunk and Pygames.

Project description

logo

Floating Hippo

Floating Hippo is a simple, abstracted, and easy to use library for 2D simulations using Pymunk and Pygames.

Note: This library is still in development and is not ready for use. We are looking for contributors to help us finish this project 🙂

Installation 🪄

pip install floating-hippo

Usage 📖

Simple example of a simulation dropping balls on a |_| shaped platform on mouse click using Floating Hippo.

Code 👇

from floating_hippo import Simulation

# Width and Height of the window
WIDTH,HEIGHT = 800,600

# Create a simulation
simulation = Simulation(WIDTH,HEIGHT,caption="Test",gravity=(0,1000))

# Create a segment shape like |_|
simulation.create_segment((100,100),(100,500))
simulation.create_segment((100,500),(600,500))
simulation.create_segment((600,500),(600,100))

@simulation.events.add_event("mousebuttondown")
def on_click(event,*args,**kwargs):
    simulation.create_ball(event.pos)

if __name__ == "__main__":
    simulation.run()

falling_balls_floating_hippo - Made with Clipchamp

Contributing 🤝

Contributions, issues and feature requests are welcome!

Show your support ⭐️

Give a ⭐️ if this project helped you!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

floating_hippo-0.0.10-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file floating_hippo-0.0.10-py3-none-any.whl.

File metadata

File hashes

Hashes for floating_hippo-0.0.10-py3-none-any.whl
Algorithm Hash digest
SHA256 3db4d965900ffccaff4a7b555330979aa20c32b5b35737c36a08c7edeaf09a39
MD5 5555b90af3468fa497cdec26c31c9fd4
BLAKE2b-256 948671c7b84c0fbbd0cd5d77ebfd4e1d9261791acae8403c2c6fcac2ef285002

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page