summaryrefslogtreecommitdiffstats
path: root/src/graphics/common/terrain.h
diff options
context:
space:
mode:
authorPiotr Dziwinski <piotrdz@gmail.com>2012-06-11 17:28:27 +0200
committerPiotr Dziwinski <piotrdz@gmail.com>2012-06-11 17:28:27 +0200
commita8665d204255b4b0ad9ae6982f77ecd5e053c1b6 (patch)
tree5f7e58785f5175e7f067ffaf8f96d16272c92d1e /src/graphics/common/terrain.h
parent8ffdf2583e4ea77731490dcaad51dbc08d7f26fa (diff)
downloadcolobot-a8665d204255b4b0ad9ae6982f77ecd5e053c1b6.tar.gz
colobot-a8665d204255b4b0ad9ae6982f77ecd5e053c1b6.tar.bz2
colobot-a8665d204255b4b0ad9ae6982f77ecd5e053c1b6.zip
Changed #defined constants to consts; typedef struct -> struct
Diffstat (limited to 'src/graphics/common/terrain.h')
-rw-r--r--src/graphics/common/terrain.h29
1 files changed, 13 insertions, 16 deletions
diff --git a/src/graphics/common/terrain.h b/src/graphics/common/terrain.h
index 50f5612..1ea5a6a 100644
--- a/src/graphics/common/terrain.h
+++ b/src/graphics/common/terrain.h
@@ -19,6 +19,7 @@
#pragma once
+#include "math/old/math3d.h"
#include "graphics/d3d/d3dengine.h"
@@ -28,7 +29,7 @@ class CWater;
-#define FLATLIMIT (5.0f*PI/180.0f)
+const float FLATLIMIT = (5.0f*PI/180.0f);
enum TerrainRes
@@ -44,9 +45,9 @@ enum TerrainRes
};
-#define MAXBUILDINGLEVEL 100
+const int MAXBUILDINGLEVEL = 100;
-typedef struct
+struct BuildingLevel
{
D3DVECTOR center;
float factor;
@@ -58,40 +59,36 @@ typedef struct
float bboxMaxX;
float bboxMinZ;
float bboxMaxZ;
-}
-BuildingLevel;
+};
-#define MAXMATTERRAIN 100
+const int MAXMATTERRAIN = 100;
-typedef struct
+struct TerrainMaterial
{
short id;
char texName[20];
float u,v;
float hardness;
char mat[4]; // up, right, down, left
-}
-TerrainMaterial;
+};
-typedef struct
+struct DotLevel
{
short id;
char mat[4]; // up, right, down, left
-}
-DotLevel;
+};
-#define MAXFLYINGLIMIT 10
+const int MAXFLYINGLIMIT = 10;
-typedef struct
+struct FlyingLimit
{
D3DVECTOR center;
float extRadius;
float intRadius;
float maxHeight;
-}
-FlyingLimit;
+};