summaryrefslogtreecommitdiffhomepage
path: root/examples/src/core/core_drop_files.c
diff options
context:
space:
mode:
Diffstat (limited to 'examples/src/core/core_drop_files.c')
-rw-r--r--examples/src/core/core_drop_files.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/examples/src/core/core_drop_files.c b/examples/src/core/core_drop_files.c
index 5c1501b..5c3af6a 100644
--- a/examples/src/core/core_drop_files.c
+++ b/examples/src/core/core_drop_files.c
@@ -13,19 +13,19 @@
#include "raylib.h"
-int main()
+int main(void)
{
// Initialization
//--------------------------------------------------------------------------------------
- int screenWidth = 800;
- int screenHeight = 450;
+ const int screenWidth = 800;
+ const int screenHeight = 450;
InitWindow(screenWidth, screenHeight, "raylib [core] example - drop files");
-
+
int count = 0;
char **droppedFiles = { 0 };
-
- SetTargetFPS(60);
+
+ SetTargetFPS(60); // Set our game to run at 60 frames-per-second
//--------------------------------------------------------------------------------------
// Main game loop
@@ -49,15 +49,15 @@ int main()
else
{
DrawText("Dropped files:", 100, 40, 20, DARKGRAY);
-
+
for (int i = 0; i < count; i++)
{
if (i%2 == 0) DrawRectangle(0, 85 + 40*i, screenWidth, 40, Fade(LIGHTGRAY, 0.5f));
else DrawRectangle(0, 85 + 40*i, screenWidth, 40, Fade(LIGHTGRAY, 0.3f));
-
+
DrawText(droppedFiles[i], 120, 100 + 40*i, 10, GRAY);
}
-
+
DrawText("Drop new files...", 100, 110 + 40*count, 20, DARKGRAY);
}
@@ -68,7 +68,7 @@ int main()
// De-Initialization
//--------------------------------------------------------------------------------------
ClearDroppedFiles(); // Clear internal buffers
-
+
CloseWindow(); // Close window and OpenGL context
//--------------------------------------------------------------------------------------