move Package

move Package

The classes in this package are designed to be instantiated, setting parameters such as speed of movement or angular velocity, and then assigned to a GameItem’s update attribute.

Every frame, world.update will invoke the update attribute of each item, passing the item, the time, and the dt since the last frame.

These classes, when invoked like this, will modify the position or orientation of the passed item.

newtonian Module

class gloopy.move.newtonian.Newtonian[source]

Bases: object

Add item.velocity to item.position, item.velocity to item.acceleration, and add angular_velocity to item.orientation.

orbit Module

class gloopy.move.orbit.Orbit(center, radius, axis=None, angular_velocity=1, phase=0)[source]

Bases: object

Move item’s position in a circular locus around the given center point, with the given axis, radius and angular_velocity.

class gloopy.move.orbit.WobblyOrbit(center, radius, axis=None, angular_velocity=1, phase=0, wobble_size=0.5, wobble_freq=1)[source]

Bases: gloopy.move.orbit.Orbit

Like an Orbit, but vary the radius size over time

spin Module

class gloopy.move.spin.Spinner(axis, speed=1.0, orientation=None)[source]

Bases: object

Spin the item’s orientation the given axis at the given angular_velocity

class gloopy.move.spin.WobblySpinner(speed=1.0)[source]

Bases: object

Spin the item’s orientation around in a wobbly manner

Table Of Contents

Previous topic

tests Package

Next topic

shapes Package

This Page