Skip to content

Commit

Permalink
Update main.c
Browse files Browse the repository at this point in the history
  • Loading branch information
mrbid authored Dec 19, 2023
1 parent bc75f53 commit 490b4f7
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions main.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
const char appTitle[]="Tuxocide";
GLFWwindow* window;
uint winw=1024, winh=768;
float t=0.f, dt=0.f, st=0.f, fc=0.f, lfct=0.f, aspect;
float t=0.f, dt=0.f, lt=0.f, st=0.f, fc=0.f, lfct=0.f, aspect;
double mx,my,lx,ly,ww,wh;

// render state id's
Expand Down Expand Up @@ -214,6 +214,10 @@ void newGame(unsigned int seed)
xrot = 0.f;
ufo_pos = (vec){0.f, 6.f, 0.3f};
ufo_spawnpos = ufo_pos;
tux_nextspawn = 0.f;
akdist = 0.17f;
akreset = 0.f;
lt = 0.f;

for(int i = 0; i < MAX_BULLETS; i++){bullet_pos[i].z = -3.f;}
for(int i = 0; i < MAX_TUX; i++){tux_pos[i].z = -3.f;}
Expand Down Expand Up @@ -251,7 +255,6 @@ void main_loop()
//*************************************
fc++;
glfwPollEvents();
static float lt = 0;
t = (float)glfwGetTime();
dt = t-lt;
lt = t;
Expand Down

0 comments on commit 490b4f7

Please sign in to comment.