• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Windows fullscreen toggle not working with physics enabled

L

Lorp

Guest
Can't toggle windows full-screen

I have two identical games with a persistent game object in each of the first rooms. full-screen toggle works on the game without physics and doesn't on the one with. I'm not sure this is the problem but it's the only difference I haven't check because it breaks the game when I turn it off.

I used the code below and all the functionality work with the exception of full-screen. if I spam f1 by using "keyboard_check(vk_f1)", I get the following windows errors:

1. win32 function failed: HRESULT:0x8007000e call: at line 369 in file\Graphics_DisplayM.cpp

2. win32 function failed: HRESULT:0x887a0001
call: g_SwapChain ->GetBuffer at line 524 in file\Graphics_DisplayM.cpp

3.win32 function failed: HRESULT:0x80070057
call: GR_D3D_Device->CreateRenderTargetView at line 527 in file/Graphics_DisplayM.cpp

how do I fix this?

create
window_set_fullscreen(true); //start in full-screen

step
if(keyboard_check(vk_escape) or gamepad_button_check(0,gp_start)){
game_end();
}

if(keyboard_check_pressed(vk_f1)){
if(window_get_fullscreen() == true){
window_set_fullscreen(false);
} else {
window_set_fullscreen(true);
}
}

if(keyboard_check(vk_enter)){
game_restart();
}
 
L

Lorp

Guest
I manages to try without physics, the problem is still there. I created a fresh file and the code works. As far as I can tell, the glitching file is "special".
 
Top