Initial
This commit is contained in:
commit
62d2de747e
1 changed files with 130940 additions and 0 deletions
72
Code blocks projekt/modules/global.h
Normal file
72
Code blocks projekt/modules/global.h
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
#include <stdbool.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#include <wchar.h>
|
||||
#include <locale.h>
|
||||
|
||||
#include <SDL.h>
|
||||
#include <SDL_ttf.h>
|
||||
#include <SDL_gfxPrimitives.h>
|
||||
|
||||
#include "auxiliary/auxFunctions.h"
|
||||
|
||||
#ifndef GLOBAL_H_INCLUDED
|
||||
#define GLOBAL_H_INCLUDED
|
||||
|
||||
#define FPS (int) 50
|
||||
|
||||
float g;
|
||||
|
||||
///<Globális változók>
|
||||
SDL_Surface* screen;
|
||||
TTF_Font* fontSmaller;
|
||||
TTF_Font* fontSmall;
|
||||
TTF_Font* fontSmallBold;
|
||||
TTF_Font* fontLarge;
|
||||
SDL_Surface* text;
|
||||
unsigned char* keys;
|
||||
///</Globális változók>
|
||||
|
||||
|
||||
///<Vektorok>
|
||||
typedef struct vector2D {
|
||||
//1 egység == 1m
|
||||
float x, y;
|
||||
} vector2D;
|
||||
|
||||
typedef struct intVector2D {
|
||||
int x, y;
|
||||
} intVector2D;
|
||||
|
||||
typedef struct vector3D {
|
||||
//1 egység == 1m
|
||||
float x, y, z;
|
||||
} vector3D;
|
||||
///</Vektorok>
|
||||
|
||||
|
||||
///<Színek>
|
||||
typedef struct color {
|
||||
unsigned char r, g, b, a;
|
||||
} color;
|
||||
|
||||
typedef struct colors {
|
||||
color light, normal, dark;
|
||||
} colors;
|
||||
///</Színek>
|
||||
|
||||
|
||||
typedef enum block {
|
||||
air, solid, invisible, treasure
|
||||
} block;
|
||||
|
||||
|
||||
typedef struct renderObject {
|
||||
vector3D position;
|
||||
vector3D size;
|
||||
colors colors;
|
||||
bool doesExist;
|
||||
} renderObject;
|
||||
|
||||
#endif // GLOBAL_H_INCLUDED
|
||||
Loading…
Reference in a new issue