summaryrefslogtreecommitdiffstats
path: root/src/SurfaceTable.h
blob: e1882e69bb5a69622bfafa87ecdf180f45b1f9a4 (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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
#pragma once


enum
{
	SURFACE_0,
	SURFACE_1,
	SURFACE_2,
	SURFACE_3,
	SURFACE_4,
	SURFACE_5,
	SURFACE_6,
	SURFACE_7,
	SURFACE_8,
	SURFACE_9,
	SURFACE_10,
	SURFACE_11,
	SURFACE_12,
	SURFACE_13,
	SURFACE_14,
	SURFACE_15,
	SURFACE_16,
	SURFACE_17,
	SURFACE_18,
	SURFACE_19,
	SURFACE_20,
	SURFACE_21,
	SURFACE_22,
	SURFACE_23,
	SURFACE_24,
	SURFACE_25,
	SURFACE_26,
	SURFACE_27,
	SURFACE_28,
	SURFACE_29,
	SURFACE_30,
	SURFACE_31,
	SURFACE_32,

	NUMSURFACETYPES
};

// From nick
// TODO: check and use this
enum eSurfaceType
{
	SURFACE_DEFAULT,
	SURFACE_TARMAC,
	SURFACE_GRASS,
	SURFACE_DIRT,
	SURFACE_DIRTTRACK,
	SURFACE_PAVEMENT,
	SURFACE_METAL6,
	SURFACE_GLASS,
	SURFACE_SCAFFOLD,
	SURFACE_METAL_DOOR,	// garage door
	SURFACE_BILLBOARD,
	SURFACE_STEEL,		//?
	SURFACE_METAL_POLE,	// ?
	SURFACE_STREET_LIGHT,
	SURFACE_METAL14,
	SURFACE_METAL15,
	SURFACE_METAL_FENCE,
	SURFACE_FLESH,
	SURFACE_SAND,
	SURFACE_PUDDLE,
	SURFACE_WOOD,
	SURFACE_WOOD_BOX,
	SURFACE_WOOD_PLANK,
	SURFACE_TIRE,
	SURFACE_HARD24,
	SURFACE_HEDGE,
	SURFACE_STONE,
	SURFACE_METAL27,
	SURFACE_METAL28,
	SURFACE_RUBBER29,
	SURFACE_LOOSE30,
	SURFACE_BOLLARD,
	SURFACE_GATE,
	SURFACE_SAND33,
	SURFACE_ROAD34,
};

enum
{
	ADHESIVE_RUBBER,
	ADHESIVE_HARD,
	ADHESIVE_ROAD,
	ADHESIVE_LOOSE,
	ADHESIVE_WET,

	NUMADHESIVEGROUPS
};

struct CColPoint;

class CSurfaceTable
{
//	static float ms_aAdhesiveLimitTable[NUMADHESIVEGROUPS][NUMADHESIVEGROUPS];
	static float (*ms_aAdhesiveLimitTable)[NUMADHESIVEGROUPS];
public:
	static void Initialise(char *filename);
	static int GetAdhesionGroup(uint8 surfaceType);
	static float GetWetMultiplier(uint8 surfaceType);
	static float GetAdhesiveLimit(CColPoint &colpoint);
};