Page Menu
Home
Phabricator (Chris)
Search
Configure Global Search
Log In
Files
F620608
main.cpp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
Unknown
Size
490 B
Referenced Files
None
Subscribers
None
main.cpp
View Options
//#include <iostream>
#include
"SDL.h"
#include
"Game.h"
int
main
(
int
argc
,
char
*
argv
[])
{
const
int
FPS
=
60
,
frameDelay
=
1000
/
FPS
;
Uint32
frameStart
;
int
frameTime
;
Game
game
(
false
);
while
(
game
.
running
())
{
frameStart
=
SDL_GetTicks
();
game
.
handleEvents
();
game
.
update
();
frameTime
=
SDL_GetTicks
()
-
frameStart
;
if
(
frameDelay
>
frameTime
)
{
SDL_Delay
(
frameDelay
-
frameTime
);
}
}
return
0
;
}
File Metadata
Details
Attached
Mime Type
text/x-c
Expires
Sat, Nov 14, 6:13 PM (16 h, 21 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
132710
Default Alt Text
main.cpp (490 B)
Attached To
Mode
R74 BloonsTD
Attached
Detach File
Event Timeline