# Pyticles
Pyticles is a particle system for pygame. It allows you to render particles with velocity and decay rates.
# Classes
Pyticles includes two classes.
Particle(image, screen_coords, velocity, decay_time=5, decay_chance=3)
Engine()
These are what the system is based around.
# Particles
- Particles are simply a class that represents a single particle.
Image is the particle texture.
Screen coordinates represent the position on the screen.
Velocity is how far the particles will go every time the Engine ticks.
Decay time is how many Engine ticks until the particle has a chance to decay ( 1 in decay_chance ). Once there has been twice as many ticks as decay time, the particle will instantly decay.
# Engines
Engines contain sets of particles and have 6 functions. You will only need to use 3. The functions are:
burst(image, particle_count, origin, scatter=1, displacement=1)
draw(particle)
tick(surface)
- Burst releases a burst of particles at a certain point, marked origin.
Scatter is how high the velocity in a certain direction can be.
Particle count is how many particles are released.
Displacement is the furthest away a particle can spawn from the origin.
Image is the particle texture.
Draw will create a single particle, and it takes in a particle class.
Tick takes in a surface to draw to and manage all tasks such as velocity, decay, and drawing.
Release files for pyticles 1.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pyticles-1.0.3.tar.gz | 2.8 kB | Details |
Release files / pyticles-1.0.3.tar.gz
| Download URL | pyticles-1.0.3.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9875ef78a184e7b8f4d9f8150bbf2a67639547f5462dfa60bfe8987ee4fb3092
|
|
BLAKE2b-256 checksum How to use checksums |
dd748d19108d526a80603af277ab7ed4cdf199ec44a9a04c87fb348f1bbd3c26
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.8.3
|