Camera follow player and 2 windows

main
Cameron Murphy Reikes 2 years ago
parent 387a09bcc2
commit e5cd725fc8

@ -18,6 +18,7 @@ struct Body
sgp_point old_position;
sgp_vec2 acceleration;
};
struct GameState
{
struct Player
@ -135,9 +136,9 @@ void frame(void)
sgp_clear();
// Drawing in world space now
// sgp_translate(gs.player.body.position.x, gs.player.body.position.y);
sgp_translate(width / 2, height / 2);
sgp_scale_at(300.0f + funval, 300.0f + funval, 0.0f, 0.0f);
sgp_translate(-gs.player.body.position.x, -gs.player.body.position.y);
sgp_set_color(1.0f, 1.0f, 1.0f, 1.0f);
sgp_draw_filled_rect(100.0f, 100.0f, 400.0f, 400.0f);

@ -7,8 +7,12 @@ SetWorkingDir, %A_ScriptDir%
^+b::
WinKill, Flight
Sleep, 20
WinKill, Flight
Sleep, 20
WinKill, Flight
WinActivate, flightbuild
If WinActive("flightbuild")
{
Send, build_debug.bat && flight.exe{Enter}
Send, build_debug.bat && START /B flight.exe && flight.exe{Enter}
}
Loading…
Cancel
Save