PyPlayGround

Powered by
SourceForge.net Logo
Pathfinding Movement Control Battles Other


What's PyPlayground?

PyPlayground is an environment for developing algorithms involving movement in a space of up to three dimensions using Python.

PyPlayground provides a framework to develope your algorithms in, and an environment to test them.
It is scenario oriented: Each algorithm is a computer-controlled player (robot) running within a set of rules defining its starting state, its set of possible operations, whether a certain operation is legal within the given context, and what terms must be met in order for the run to be "successful". Several robots can run togther within the same scenario, using a turn-based or time-based operation division. Each robot is essentially built for a specific scenario. It is still possible, however, for robots to function correctly within two different scenarios, if the two scenarios provide the same set of operations.

Why should I use it?

If you are developing algorithms that involve movement in space, or can be translated into movement in space, PyPlayground can be a helpful tool.
Think of it as a controlled environment to let your algorithms run in, with tools availible to visually test and debug them. You can make them run slower, faster, get statistics, etc..

Such algorithms include:

Of course, you could write it on your own, but it's a lot of work, and it would be a waste of time. The main idea is that a single visualisation environment should be adequate for a large range of algorithms.

How do I use it?

From the user's view-point, PyPlayground is a framework. Each object, such as the scenario, the map, and the robots, are object skeletons (interfaces) that the programmer must fill (implement) in order to have a working scene.
Once these are set-up, the scenario can be run using the user interface supplied by PyPlayground, and the user can watch his robots "play", alone or together, according to the algorithms he supplied them.

Status

PyPlayground is still partially under planning, and the coding stages are very early. It would probably be of little use for you at its current state.
However, if you like this idea and wish to contribute, you are always welcomed to join the project!
Feel free to contact me at: erez27@gmail.com,
or thru sourceforge (my user-name is erezsh).

Screenshots

Everyone likes screenshots, so I'll show you some.
The following screenshots are taken from the pygame gui, which is currently just the map, without any controls. That will change in time.
These screenshots belong to the experimental Gravity Pathfinder:



Legend:
  • Grey - unpassable location
  • Green - destination
  • Blue - path travelled


I'll do even better and also show you an animated gif,
this is how the current GUI looks like while the pathfinder is running:

   

For more information about pathfinding or about the Gravity Pathfinder, check out the page about pathfinding!





Page hits: