aboutsummaryrefslogtreecommitdiffstats
path: root/src/map.h
blob: 30a182c329e02e26aeb0fa15f378fc3232f0f221 (plain) (blame)
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
#include "utils.h"
#include "settings.h"

#ifndef MAP_H
#define MAP_H

#define MAP_ZOOM_MIN 0.5
#define MAP_ZOOM_MAX 30.0

#define BLACKOUT_WIDTH 100
#define BLACKOUT_HEIGHT 100
#define BLACKOUT_AREA 18.0

#define MAP_UTILITY_POLE_LINE_COLOR (Color){0, 0, 0, 127}

typedef struct {
  Rectangle rect;
  RenderTexture render;
  RenderTexture blackout;
  Camera2D camera;
  Texture texture;
  Vector2 playerPosition;
  bool isEnabled;
  bool isFullSize;
} Map;

void initMap(Map* map, const World* world, const Settings* settings);
void updateMap(Map* map, Game* game);
void closeMap(Map* map);

#endif