Difference between revisions of "Modules/game"

From MSX Game Library

< Modules

(Created page with "{{MODULE |name=game |category=Gameplay |dependency1=vdp |dependency2=bios |dependency3= |sample1=s_game |sample2= |sample3= }}")
 
 
Line 2: Line 2:
 
|name=game
 
|name=game
 
|category=Gameplay
 
|category=Gameplay
 +
|image=raw.githubusercontent.com/aoineko-fr/MSXgl/main/engine/doc/img/sample_game.png
 
|dependency1=vdp
 
|dependency1=vdp
 
|dependency2=bios
 
|dependency2=bios

Latest revision as of 01:01, 13 January 2024

game

Code: game.h

Category: Gameplay

Dependencies:

Samples:

The game module handle program architecture, from program initialization, to update synchronization on the screen display, and features a task management system.

Usage

To use this module, include "game.h" in your source code, and add "game" to the modules list (LibModules) in your project's configuration file (project_config.js).


Samples

See module use cases in the sample programs:

Settings

Library configuration (msxgl_config.h):

// Game state setting
#define GAME_USE_STATE		TRUE	// Add state machine features
#define GAME_USE_VSYNC		TRUE	// Add vertical synchronization features
#define GAME_USE_LOOP		TRUE	// Add game main loop with call to v-synch and state

Dependencies

Dependency on other modules:

Documentation