screen_size.X
screen_size.Y
The current screen or window resolution. Cannot be set directly, but will
be changed automatically by video_ functions.
Range:
0 .. 1920
Type:
vector, read-only
Modified with:
video_switch,
video_set
Example:
var video_mode = 6; // startsettings for 640x480
PANEL* logo =
{
bmap = "logo.pcx";
flags = VISIBLE;
}
function center_panel()
{
// Panel in the middle of the screen
logo.pos_x = (screen_size.x - bmap_width(logo.bmap))/2;
logo.pos_y = (screen_size.y - bmap_height(logo.bmap))/2;
}
See also:
video_switch, video_set, video_mode, video_screen