the game where you go into mines and start crafting! but for consoles (forked directly from smartcmd's github)
at main 51 lines 1.4 kB view raw
1#pragma once 2#include "GameRuleDefinition.h" 3#include "ConsoleSchematicFile.h" 4 5class AABB; 6class Vec3; 7class LevelChunk; 8class LevelGenerationOptions; 9class GRFObject; 10 11class ApplySchematicRuleDefinition : public GameRuleDefinition 12{ 13private: 14 LevelGenerationOptions *m_levelGenOptions; 15 wstring m_schematicName; 16 ConsoleSchematicFile *m_schematic; 17 Vec3 *m_location; 18 AABB *m_locationBox; 19 ConsoleSchematicFile::ESchematicRotation m_rotation; 20 int m_dimension; 21 22 __int64 m_totalBlocksChanged; 23 __int64 m_totalBlocksChangedLighting; 24 bool m_completed; 25 26 void updateLocationBox(); 27public: 28 ApplySchematicRuleDefinition(LevelGenerationOptions *levelGenOptions); 29 ~ApplySchematicRuleDefinition(); 30 31 virtual ConsoleGameRules::EGameRuleType getActionType() { return ConsoleGameRules::eGameRuleType_ApplySchematic; } 32 33 virtual void writeAttributes(DataOutputStream *dos, UINT numAttrs); 34 virtual void addAttribute(const wstring &attributeName, const wstring &attributeValue); 35 36 void processSchematic(AABB *chunkBox, LevelChunk *chunk); 37 void processSchematicLighting(AABB *chunkBox, LevelChunk *chunk); 38 39 bool checkIntersects(int x0, int y0, int z0, int x1, int y1, int z1); 40 int getMinY(); 41 42 bool isComplete() { return m_completed; } 43 44 wstring getSchematicName() { return m_schematicName; } 45 46 /** 4J-JEV: 47 * This GameRuleDefinition contains limited game state. 48 * Reset any state to how it should be before a new game. 49 */ 50 void reset(); 51};