|
|
@ -17,10 +17,6 @@ |
|
|
|
#include <stdlib.h> |
|
|
|
#include <stdio.h> |
|
|
|
|
|
|
|
#if defined(PLATFORM_ANDROID) |
|
|
|
#include "android_native_app_glue.h" |
|
|
|
#endif |
|
|
|
|
|
|
|
#if defined(PLATFORM_WEB) |
|
|
|
#include <emscripten/emscripten.h> |
|
|
|
#endif |
|
|
@ -55,20 +51,15 @@ static void UpdateDrawFrame(void); // Update and Draw one frame |
|
|
|
//---------------------------------------------------------------------------------- |
|
|
|
// Main entry point |
|
|
|
//---------------------------------------------------------------------------------- |
|
|
|
#if defined(PLATFORM_ANDROID) |
|
|
|
void android_main(struct android_app *app) |
|
|
|
#else |
|
|
|
int main(void) |
|
|
|
#endif |
|
|
|
{ |
|
|
|
// Initialization |
|
|
|
//--------------------------------------------------------- |
|
|
|
#if defined(PLATFORM_ANDROID) |
|
|
|
InitWindow(screenWidth, screenHeight, app); |
|
|
|
#else |
|
|
|
#ifndef PLATFORM_ANDROID |
|
|
|
SetConfigFlags(FLAG_SHOW_LOGO); // | FLAG_FULLSCREEN_MODE); |
|
|
|
InitWindow(screenWidth, screenHeight, "raylib game - transmission mission"); |
|
|
|
#endif |
|
|
|
// Note windowTitle is unused on Android |
|
|
|
InitWindow(screenWidth, screenHeight, "raylib game - transmission mission"); |
|
|
|
|
|
|
|
// Global data loading (assets that must be available in all screens, i.e. fonts) |
|
|
|
InitAudioDevice(); |
|
|
@ -138,9 +129,8 @@ int main(void) |
|
|
|
|
|
|
|
CloseWindow(); // Close window and OpenGL context |
|
|
|
//-------------------------------------------------------------------------------------- |
|
|
|
#if !defined(PLATFORM_ANDROID) |
|
|
|
|
|
|
|
return 0; |
|
|
|
#endif |
|
|
|
} |
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------- |
|
|
@ -462,4 +452,4 @@ void DrawButton(const char *text) |
|
|
|
Vector2 measure = MeasureTextEx(fontMission, text, fontSizeButton, 0); |
|
|
|
Vector2 textPos = {textPositionButton.x - measure.x/2 + 10, textPositionButton.y - measure.y/2 - 10}; |
|
|
|
DrawTextEx(fontMission, text, textPos , fontSizeButton, 0, textColorButton); |
|
|
|
} |
|
|
|
} |