-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdefinitions.hpp
More file actions
54 lines (45 loc) · 1.47 KB
/
Copy pathdefinitions.hpp
File metadata and controls
54 lines (45 loc) · 1.47 KB
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
44
45
46
47
48
49
50
51
52
53
54
//Author: Nathan Jodoin
//CSCE2110 - SimCity
//Recitation Section 213 - Group 6
//General definitions the need to be included almost everywhere.
#ifndef _DEFINITIONS_HPP_
#define _DEFINITIONS_HPP_
#include <utility>
#include <vector>
#include <list>
#include <iostream>
#include <iomanip>
#include <fstream>
// class includes here
// avoid functional includes here
#include "zone.cpp" // Author: Nathan
#include "populated.cpp" // Author: Nathan
#include "unpopZones.cpp" // Author: Nathan
#include "residential.cpp" // Author: Nathan
#include "industrial.cpp" // Author: Nathan
#include "commercial.cpp" // Author: Nathan
// type definition for the Map type, the primary working datastructure
typedef struct Map
{
// a 2D vector of zone* which represents the map
std::vector< std::vector<zone*> > map_grid;
// X and Y size of the map, useful for other functions, primarily bounding
int x_size;
int y_size;
// data members for the simulation settings, read in from the config file
int refresh_rate;
int max_time;
} Map;
// type def for the second primary data structure, the zlist is a struct of 3
// populated* vectors representing each of the class types which needs to be check for
// population update conditions in an ordered manner, these are sorted
typedef struct z_list
{
//residential zone list
std::vector<populated *> res;
//industrial zone list
std::vector<populated *> ind;
//commerical zone list
std::vector<populated*> com;
} z_list;
#endif