Simple Game Library

From OLPC
Revision as of 19:34, 24 April 2007 by 143.107.236.140 (talk) (Starting SGL project)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
SGL
Simple Game Library
Design version .1

SUMMER OF CODE PROJECT: intention of this project is to provide a standard library for high level engines like XOASS. Feel free to edit and discuss.

Design

The mainly objective of this project is to make , in the future, a GUI framework to develop games fast and quickly. This is a bigger project, so to start and using something to ease game production, this project wants to now provide tools and templates for production games in coding way, but they are the base to provide a full featured GUI framework to produce games easily.

Structure:

his project contains some tools, or mods, to provide fast development:

 * Mediakit: Provide easy media objects (MediaAudio, MediaVideo, MediaImage and Text) implement, combining media conversions (like mp3 to ogg or jpeg to png, for an example) with media manipulation (play an audio or a video with a single action, like audio.play() ). Note that PyGame already has pygame.mixer, pygame.movie, pygame.image and pygame.font, this kit just translate into Media objects to ease generalize media types as one type of object, providing easy integration with other kits and a future framework GUI. A XML schema with media properties can also be produced.
 * UIkit: A complete toolkit with buttons, menus, textual displays, widgets and respective properties. Buttons need to have properties like action to perform in click and images to assign. Menus may contain submenus and need to have action too. Textual displays may only position a Media Text object. Widgets is a group of buttons, menus and other components, like File Chooser and Calendar. This toolkit is a collection of these four objects, and more any needed, and can be implemented in XML schema, providing something like Glade does.
 
 * Spritekit: to make a sprite, this tool assigns groups of image frames as actions and give to sprite some actions properties as velocity of animation, collisions objects, interactions with user and scenery. Sprite can be animated or not, providing objects to interact or to control by user, or just background with determined properties. We can compact in tar or tgz format all images of each frame and a XML schema containing all information about sprite.
 
 * Networkit: To provide needed network actions that a game needs: connect to another OLPC laptop, to a server, or to another computer, trade information, and disconnect. This three operations need to be transparent to programmer, so this kit will provide this transparency to programmer. This connection properties can also be stored in a XML file.
 
 * Inputkit: provides transparency to pygame.key (keyboard), pygame.mouse (Mouse) and pygame.joystick (Joystick) operations and manage their actions into a one object, "Input".
 
 * DBkit: provides connection with a database (SQL or a file based), to transit data.
 
 * Scenekit: This is the base for the future framework and for templates. Scenekit can handle Media objects and Sprites, providing a Scene Menu (like a intro screen to select new game or load a game) or a Scene Game (game scene, with sprites, images and videos as background and interactive structures and so on). A Scene Game can has Actors (main actor controlled by user and other actors to interact).
 
 * GeneralGamekit: contains objects inherent to general gaming, like Score, Lives, Clock, Save/Load variables and/or game stat, Question&Answer, High Score and others gaming objects.