From b68d6344c95418eac96146ab13c159cd2af93741 Mon Sep 17 00:00:00 2001 From: acetheking987 Date: Fri, 6 Sep 2024 13:39:28 +0000 Subject: [PATCH] Update Engine --- Engine.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/Engine.md b/Engine.md index 59aaec4..e283151 100644 --- a/Engine.md +++ b/Engine.md @@ -2,27 +2,29 @@ The engine initializes SDL2, TFF and handles basic functions -## Constructor +## Functions + +### Constructor This initializes SDL2 and creates a window. ` engine = new Engine("Game", 800, 600);` -## startFrame +### startFrame This sets the `frameStart` variable to the output of `SDL_GetTicks()` to be able to adjust framerate. -## render +### render This updates the screen with any changes by running `SDL_RenderPresent(renderer);`. It also automatically delays to reach the desired framerate if necessary. -## clear +### clear This clears the screen with a provided color `engine->clear({ 100, 150, 255, 255 });`, this color is a `SDL_Colour` type. -## Update +### Update This runs all the input updates using the Input class. -## Deconstructor +### Deconstructor This destroys the `renderer` and `window`, It also runs `SDL_Quit()` and `TFF_Quit()`.