coopgame
Library of tooling and templates used for building games
Example:
from coopgame.gameTemplate import GameTemplate
from coopstructs.vectors import Vector2
import pygame
from coopgame.colors import Color
from coopgame.sprites import RectangleSprite
class MyGame(GameTemplate):
def __init__(self):
super().__init__()
self.sprites = pygame.sprite.Group()
def draw(self, frames):
for entity in self.sprites:
self.screen.blit(entity.surf, entity.rect)
def handle_hover_over(self, mouse_pos_as_vector: Vector2):
pass
def handle_left_click(self):
self.sprites.add(RectangleSprite(self.mouse_pos_as_vector(), Color.BLUE, 10, 10))
def handle_right_click(self):
self.sprites.add(RectangleSprite(self.mouse_pos_as_vector(), Color.RED, 20, 30))
def handle_key_pressed(self, pressed_key):
if pressed_key == pygame.K_r:
self.sprites.empty()
if __name__ == "__main__":
import logging
import loggingConfig
loggingConfig.initLogging(loggingLvl=logging.DEBUG)
game = MyGame()
game.main()
Metadata
Release files for coopgame 1.19
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| coopgame-1.19.tar.gz | 142.8 kB | Without provenance | Details for coopgame-1.19.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| coopgame-1.19-py3-none-any.whl | Python 3 | none | any | Details for coopgame-1.19-py3-none-any.whl |
Total release size: 339.0 kB
Release files / coopgame-1.19.tar.gz
| Download URL | coopgame-1.19.tar.gz |
|---|---|
| Size | 142.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4c8e3cfb7f76ae6cad5770fa813cc2b82317c0b5c5462d9b2252ea2a096bd4df
|
|
BLAKE2b-256 checksum How to use checksums |
0eb61757a0514c8d8a14a850aea16b903036257ff190016785fc0b923b5382fc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.12.3
|
Release files / coopgame-1.19-py3-none-any.whl
| Download URL | coopgame-1.19-py3-none-any.whl |
|---|---|
| Size | 196.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3a5682d4b374e6f169b0f9eb88b185c2d402c0af872edc0600e03653ee317a5c
|
|
BLAKE2b-256 checksum How to use checksums |
3384fce4111a4057a3d2822b763dfd33fdc91bd07be9ec045a168265bdb7b2e6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.12.3
|
Security for coopgame 1.19
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.