Elin Modding Docs Doc
Loading...
Searching...
No Matches
BaseMapGen.cs
1using System;
2using NoiseSystem;
3
4// Token: 0x0200066B RID: 1643
5public class BaseMapGen : GenBounds
6{
7 // Token: 0x17000D13 RID: 3347
8 // (get) Token: 0x06002E0C RID: 11788 RVA: 0x00101973 File Offset: 0x000FFB73
9 public bool extraBiome
10 {
11 get
12 {
13 return this.biomeProfiles.Length > 3;
14 }
15 }
16
17 // Token: 0x06002E0D RID: 11789 RVA: 0x00101980 File Offset: 0x000FFB80
18 public void SetSize(int size, int _poiSize)
19 {
20 this.Size = size;
21 if (this.map.poiMap == null || this.Size != POIMap.mapSize)
22 {
23 this.map.poiMap = new POIMap();
24 this.map.poiMap.Init(this.Size, _poiSize);
25 }
26 }
27
28 // Token: 0x06002E0E RID: 11790 RVA: 0x001019D8 File Offset: 0x000FFBD8
29 public void Generate(ZoneBlueprint _bp)
30 {
31 BiomeProfile.Init();
32 this.bp = _bp;
33 this.zone = this.bp.zone;
34 this.zp = this.bp.zoneProfile;
35 this.map = this.bp.map;
36 this.OX = this.zp.offsetX;
37 this.OZ = this.zp.offsetZ;
38 this.blockHeight = this.zp.blockHeight;
39 this.hSetting = this.zp.height;
40 MapGenVariation mapGenVariation = this.variation = this.bp.genSetting.variation;
41 this.layerHeight = mapGenVariation.layerHeight;
42 this.layerRiver = mapGenVariation.layerRiver;
43 this.layerStratum = mapGenVariation.layerStratum;
44 this.layerBiome = mapGenVariation.layerBiome;
45 this.biomeProfiles = mapGenVariation.biomeProfiles;
46 this.biomeShore = mapGenVariation.biomeShore;
47 this.biomeWater = mapGenVariation.biomeWater;
48 this.biomeSand = EClass.core.refs.biomes.Sand;
49 this.GenerateTerrain();
50 if (this.zp.indoor)
51 {
52 this.map.config.bg = MapBG.None;
53 this.map.config.indoor = true;
54 }
55 if (this.map.config.idSceneProfile.IsEmpty())
56 {
57 this.map.config.idSceneProfile = this.zp.idSceneProfile.IsEmpty(this.zp.indoor ? "indoor" : null);
58 }
59 this.map.config.bg = this.zp.mapBG;
60 }
61
62 // Token: 0x06002E0F RID: 11791 RVA: 0x00101B8C File Offset: 0x000FFD8C
63 protected virtual void GenerateTerrain()
64 {
65 this.OnGenerateTerrain();
66 }
67
68 // Token: 0x06002E10 RID: 11792 RVA: 0x00101B95 File Offset: 0x000FFD95
69 protected virtual bool OnGenerateTerrain()
70 {
71 return false;
72 }
73
74 // Token: 0x04001A1D RID: 6685
75 public static string err;
76
77 // Token: 0x04001A1E RID: 6686
78 [NonSerialized]
79 public NoiseLayer layerHeight;
80
81 // Token: 0x04001A1F RID: 6687
82 [NonSerialized]
83 public NoiseLayer layerRiver;
84
85 // Token: 0x04001A20 RID: 6688
86 [NonSerialized]
87 public NoiseLayer layerStratum;
88
89 // Token: 0x04001A21 RID: 6689
90 [NonSerialized]
91 public NoiseLayer layerBiome;
92
93 // Token: 0x04001A22 RID: 6690
94 [NonSerialized]
95 public BiomeProfile[] biomeProfiles;
96
97 // Token: 0x04001A23 RID: 6691
98 [NonSerialized]
99 public BiomeProfile biomeShore;
100
101 // Token: 0x04001A24 RID: 6692
102 [NonSerialized]
103 public BiomeProfile biomeSand;
104
105 // Token: 0x04001A25 RID: 6693
106 [NonSerialized]
107 public BiomeProfile biomeWater;
108
109 // Token: 0x04001A26 RID: 6694
110 [NonSerialized]
111 public Crawler[] crawlers;
112
113 // Token: 0x04001A27 RID: 6695
114 [NonSerialized]
115 protected bool skipWater;
116
117 // Token: 0x04001A28 RID: 6696
118 [NonSerialized]
119 public ZoneBlueprint bp;
120
121 // Token: 0x04001A29 RID: 6697
122 [NonSerialized]
123 public ZoneProfile zp;
124
125 // Token: 0x04001A2A RID: 6698
126 [NonSerialized]
127 protected float[,] heights1;
128
129 // Token: 0x04001A2B RID: 6699
130 [NonSerialized]
131 protected float[,] heights2;
132
133 // Token: 0x04001A2C RID: 6700
134 [NonSerialized]
135 protected float[,] heights3;
136
137 // Token: 0x04001A2D RID: 6701
138 [NonSerialized]
139 protected float[,] waters;
140
141 // Token: 0x04001A2E RID: 6702
142 [NonSerialized]
143 protected float[,] heights3d;
144
145 // Token: 0x04001A2F RID: 6703
146 [NonSerialized]
147 public int blockHeight;
148
149 // Token: 0x04001A30 RID: 6704
150 [NonSerialized]
151 public int seed;
152
153 // Token: 0x04001A31 RID: 6705
154 [NonSerialized]
155 public int lastSize;
156
157 // Token: 0x04001A32 RID: 6706
158 [NonSerialized]
159 public int OX;
160
161 // Token: 0x04001A33 RID: 6707
162 [NonSerialized]
163 public int OZ;
164
165 // Token: 0x04001A34 RID: 6708
166 [NonSerialized]
167 protected float waterCount;
168
169 // Token: 0x04001A35 RID: 6709
170 [NonSerialized]
171 public BiomeProfile[,] biomes;
172
173 // Token: 0x04001A36 RID: 6710
174 [NonSerialized]
175 public bool[,] subBiomes;
176
177 // Token: 0x04001A37 RID: 6711
178 [NonSerialized]
179 public MapGenVariation variation;
180
181 // Token: 0x04001A38 RID: 6712
182 [NonSerialized]
183 public MapHeight hSetting;
184}