Cuberite
A lightweight, fast and extensible game server for Minecraft
DungeonRoomsFinisher.h
Go to the documentation of this file.
1 
2 // DungeonRoomsFinisher.h
3 
4 // Declares the cDungeonRoomsFinisher class representing the finisher that generates dungeon rooms
5 
6 
7 
8 
9 
10 #pragma once
11 
12 #include "GridStructGen.h"
13 #include "../ProbabDistrib.h"
14 
15 
16 
17 
18 
20  public cGridStructGen
21 {
23 
24 public:
25 
30  cDungeonRoomsFinisher(cTerrainShapeGen & a_ShapeGen, int a_Seed, int a_GridSize, int a_MaxSize, int a_MinSize, const AString & a_HeightDistrib);
31 
32 protected:
33 
36 
39 
42 
45 
46 
47  // cGridStructGen overrides:
48  virtual cStructurePtr CreateStructure(int a_GridX, int a_GridZ, int a_OriginX, int a_OriginZ) override;
49 } ;
std::string AString
Definition: StringUtils.h:11
The interface that a terrain shape generator must implement A terrain shape generator takes chunk coo...
virtual cStructurePtr CreateStructure(int a_GridX, int a_GridZ, int a_OriginX, int a_OriginZ) override
Create a new structure at the specified gridpoint.
cProbabDistrib m_HeightProbability
The height probability distribution to make the spawners more common in layers 10 - 40,...
cDungeonRoomsFinisher(cTerrainShapeGen &a_ShapeGen, int a_Seed, int a_GridSize, int a_MaxSize, int a_MinSize, const AString &a_HeightDistrib)
Creates a new dungeon room finisher.
cTerrainShapeGen & m_ShapeGen
The shape gen that is used for limiting the rooms' Y coords.
int m_MaxHalfSize
Maximum half-size (from center to wall) of the dungeon room's inner (air) area.
int m_MinHalfSize
Minimum half-size (from center to wall) of the dungeon room's inner (air) area.
Generates structures in a semi-random grid.
Definition: GridStructGen.h:46
std::shared_ptr< cStructure > cStructurePtr
Definition: GridStructGen.h:77
cGridStructGen(int a_Seed, int a_GridSizeX, int a_GridSizeZ, int a_MaxOffsetX, int a_MaxOffsetZ, int a_MaxStructureSizeX, int a_MaxStructureSizeZ, size_t a_MaxCacheSize)