Tag: pygame

Python/Pygame port of TennisForTwo: first videogame ever (1958)

The history of videogames is very interesting issue, and the title of the  “first videogame of all time”  was always very disputed. In spite of the existence of a protovideogame called Cathode Ray Tube Amusement Device (1947) and other examples

Posted in Electronics, Historic, Programming, Python Tagged with: , , , , ,

Python + Box 2D + Pygame demo: Bumper cars

from Box2D import * import pygame, sys, math, random from pygame.locals import * # set up pygame-box2d constants car_x_size=3 car_y_size=1 pillar_height=15.0 pygame_box2d_ratio=10.0 ground_height=10.0 pygame_screen_x=500 pygame_screen_y=400 margin=0.0 # set up pygame pygame.init() # set up the window windowSurface = pygame.display.set_mode((pygame_screen_x, pygame_screen_y))

Posted in Programming, Python Tagged with: , , ,

Box2D: Physics Engine for Games

from Box2D import * import pygame, sys, math, random from pygame.locals import * # set up pygame-box2d constants box_size=0.9 pillar_height=15.0 pygame_box2d_ratio=10.0 ground_height=10.0 pygame_screen_x=500 pygame_screen_y=400 # set up pygame pygame.init() # set up the window windowSurface = pygame.display.set_mode((pygame_screen_x, pygame_screen_y)) pygame.display.set_caption(‘Box2D and

Posted in Programming, Python Tagged with: , ,

Python Stochastic 2D OpenGL Cutted Fractal Tree

My objective is create a 3D OpenGL Fractal Tree, but I’m just starting to learn OpenGL, so first thing I did was porting the code from Python Pygame primitives to python 2D OpenGL.   from OpenGL.GL import * from OpenGL.GLU

Posted in OpenGL, Programming, Python Tagged with: , , , , ,
%d bloggers like this: