-
Notifications
You must be signed in to change notification settings - Fork 29
Configuration
Martin Cohen edited this page Dec 1, 2016
·
1 revision
Punity provides a lot of configuration parameters, that are by-default set to most common use and fastest way to results. However, if you find yourself wanting to change the defaults, take a look into macro configuration at the beginning of punity.h.
Note that any changes to the macros should be made before you include punity.h:
// Turn off OpenGL.
#define PUN_OPENGL 0
// Change storage bank capacity to 64MB.
#define PUN_STORAGE_CAPACITY megabytes(64)
// Change recorder key to F10.
#define PUN_FEATURE_RECORDER_KEY KEY_F10
// ...
#define PUNITY_IMPLEMENTATION
#include "punity.h"
Init function currently only allows for customization of window (frame) size and scale. The implementation simply defers creating window to after init()
is called and then uses properties in CONFIG->window
to set it up. Also see Window for more info.
int
init()
{
// Change frame size to 480x270 with scale 3.
CORE->window.width = 480;
CORE->window.height = 270;
CORE->window.scale_normal = 3;
}