diff --git a/Scripts/System/NaturalResourceGenerator.cs b/Scripts/System/NaturalResourceGenerator.cs index 43e0c7a..49d9731 100644 --- a/Scripts/System/NaturalResourceGenerator.cs +++ b/Scripts/System/NaturalResourceGenerator.cs @@ -121,9 +121,9 @@ public partial class NaturalResourceGenerator : Node2D } // Generate stone veins - for (int x = 0; x < ChunkSize; x++) + for (var x = 0; x < ChunkSize; x++) { - for (int y = 0; y < ChunkSize; y++) + for (var y = 0; y < ChunkSize; y++) { var cell = new Vector2I(chunkWorldPos.X + x, chunkWorldPos.Y + y); if (_rng.Randf() < StoneDensity) @@ -131,6 +131,11 @@ public partial class NaturalResourceGenerator : Node2D var veinSize = _rng.RandiRange(MinStoneVeinSize, MaxStoneVeinSize); PlaceVeinInBackground(cell, "stone", veinSize, chunkData.StoneTiles); } + else if (_rng.Randf() < IronDensity) + { + var veinSize = _rng.RandiRange(MinIronVeinSize, MaxIronVeinSize); + PlaceVeinInBackground(cell, "ore_iron", veinSize, chunkData.IronTiles); + } } }