StructureCollection.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. #pragma once
  2. #include <functional>
  3. #include "GeneratorTemplate.h"
  4. #include "JsonExpression.h"
  5. #include "Noise.h"
  6. class StructureTemplateCollection : public virtual Framework::ReferenceCounter
  7. {
  8. private:
  9. Noise* activeNoise;
  10. Noise* structureNoise;
  11. double threshold;
  12. Framework::RCArray<GeneratorTemplate> structures;
  13. Framework::Vec3<int> minAffected;
  14. Framework::Vec3<int> maxAffected;
  15. JBoolExpression* condition;
  16. public:
  17. StructureTemplateCollection(
  18. Framework::JSON::JSONValue* zConfig, JExpressionMemory* zMemory);
  19. ~StructureTemplateCollection();
  20. void generateStructures(int x,
  21. int y,
  22. int z,
  23. int dimensionId,
  24. JExpressionMemory* zMemory,
  25. Framework::Vec3<int> minPos,
  26. Framework::Vec3<int> maxPos,
  27. Framework::RCArray<GeneratedStructure>* zResult);
  28. const Framework::RCArray<GeneratorTemplate>& getStructures() const;
  29. Framework::Vec3<int> getMinAffected() const;
  30. Framework::Vec3<int> getMaxAffected() const;
  31. static Framework::JSON::Validator::JSONValidator* getConfigValidator();
  32. };