summaryrefslogtreecommitdiffhomepage
path: root/examples/web/text/text_format_text.c
diff options
context:
space:
mode:
authorraysan5 <[email protected]>2020-12-24 13:26:30 +0100
committerraysan5 <[email protected]>2020-12-24 13:26:30 +0100
commit83ab2cb01746a869b625c9d84fbb4737146b73a9 (patch)
tree010b0794848d863916e5acb4f766ea9e7ecb6e90 /examples/web/text/text_format_text.c
parentd11274dcfcb0f349fba16ab4b83d2b96bcac8d1a (diff)
downloadraylib.com-83ab2cb01746a869b625c9d84fbb4737146b73a9.tar.gz
raylib.com-83ab2cb01746a869b625c9d84fbb4737146b73a9.zip
Updated Web examples to raylib 3.5
Diffstat (limited to 'examples/web/text/text_format_text.c')
-rw-r--r--examples/web/text/text_format_text.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/examples/web/text/text_format_text.c b/examples/web/text/text_format_text.c
index 8896161..05664fb 100644
--- a/examples/web/text/text_format_text.c
+++ b/examples/web/text/text_format_text.c
@@ -40,7 +40,7 @@ int main(void)
InitWindow(screenWidth, screenHeight, "raylib [text] example - text formatting");
#if defined(PLATFORM_WEB)
- emscripten_set_main_loop(UpdateDrawFrame, 0, 1);
+ emscripten_set_main_loop(UpdateDrawFrame, 60, 1);
#else
SetTargetFPS(60); // Set our game to run at 60 frames-per-second
//--------------------------------------------------------------------------------------
@@ -76,13 +76,13 @@ void UpdateDrawFrame(void)
ClearBackground(RAYWHITE);
- DrawText(FormatText("Score: %08i", score), 200, 80, 20, RED);
+ DrawText(TextFormat("Score: %08i", score), 200, 80, 20, RED);
- DrawText(FormatText("HiScore: %08i", hiscore), 200, 120, 20, GREEN);
+ DrawText(TextFormat("HiScore: %08i", hiscore), 200, 120, 20, GREEN);
- DrawText(FormatText("Lives: %02i", lives), 200, 160, 40, BLUE);
+ DrawText(TextFormat("Lives: %02i", lives), 200, 160, 40, BLUE);
- DrawText(FormatText("Elapsed Time: %02.02f ms", GetFrameTime()*1000), 200, 220, 20, BLACK);
+ DrawText(TextFormat("Elapsed Time: %02.02f ms", GetFrameTime()*1000), 200, 220, 20, BLACK);
EndDrawing();
//----------------------------------------------------------------------------------