BiomGenerator.h 800 B

1234567891011121314151617181920212223242526272829303132
  1. #pragma once
  2. #include <Either.h>
  3. #include <ReferenceCounter.h>
  4. #include "GenerationTemplate.h"
  5. class Block;
  6. class Noise;
  7. class BiomGenerator : public virtual Framework::ReferenceCounter
  8. {
  9. private:
  10. Framework::RCArray<GenerationTemplate> templates;
  11. protected:
  12. void addTemplateGenerator(GenerationTemplate* gTemplate);
  13. public:
  14. BiomGenerator();
  15. virtual Framework::Either<Block*, int> generateSurfaceBlock(
  16. int x, int y, int z)
  17. = 0;
  18. virtual Framework::Either<Block*, int> generateBelowSurfaceBlock(
  19. int x, int y, int z)
  20. = 0;
  21. virtual Framework::Either<Block*, int> generateCaveBlock(
  22. int x, int y, int z)
  23. = 0;
  24. virtual Noise* zHeightMapNoise(int seed) = 0;
  25. const Framework::RCArray<GenerationTemplate>& getTemplates();
  26. };