-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMildred.h
44 lines (40 loc) · 1.41 KB
/
Mildred.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
// HEADER FILE
// Contains class specification
#pragma once
#include <iostream>
#include <SDL.h>
#include <vector>
#include "MapBoundary.h"
#include "Player.h"
#include "Calc.h"
#include "AssetManager.h"
#include "GUI.h"
class Mildred {
private:
static SDL_Renderer* renderer;
static SDL_Window* window;
static int screenWidth, screenHeight, fieldOfView, viewDistance, frameCount;
static std::vector<MapBoundary>* mapBoundaries;
static Uint64 ticks, prevFps;
public:
static bool isRunning;
static Player* player;
static AssetManager* assetManager;
static void Init();
static void CreateWindow(std::string title, int width, int height);
static void CreateRenderer(int graphicsDeviceIndex);
static void SetRenderDrawColor(Uint8 r, Uint8 g, Uint8 b, Uint8 a);
static void RenderPresent();
static void RenderClear();
static void DrawRect(int width, int height, int x, int y);
static void CreateMapBoundary(int x, int y, int endX, int endY, std::string textureName);
static void DrawMapBoundaries();
static SDL_Renderer* GetRenderer();
static SDL_Window* GetWindow();
static void HandleUserInput();
static void RenderWallSlice(double* lineCollisionPointer, int drawPoint, double rayAngleRad, int lineLenght, int lineStartX, int lineStartY, std::string textureName);
static void CastRays();
static void HandleEvents();
static void DisplayFPS();
static void DrawTempBackground();
};