Grindstone Game Engine v0.2.0
An open source game engine and toolkit.
Loading...
Searching...
No Matches
SceneLoaderJson.hpp
1#pragma once
2
3#include <string>
4#include <map>
5#include <entt/entt.hpp>
6#include <rapidjson/document.h>
7
8#include <Common/ResourcePipeline/Uuid.hpp>
9
10#include "../ECS/Entity.hpp"
11#include "../Reflection/TypeDescriptorStruct.hpp"
12
13namespace Grindstone {
14 namespace SceneManagement {
15 class Scene;
16
18 public:
20 private:
21 bool Load(Grindstone::Uuid uuid);
22 void ProcessMeta();
23 void ProcessEntities();
24
25 void ProcessEntity(rapidjson::Value& entity);
26 void ProcessComponent(ECS::Entity entity, rapidjson::Value& component);
27 void ProcessComponentParameter(
28 ECS::Entity entity,
29 void* componentPtr,
31 const char* parameterKey,
32 rapidjson::Value& parameter
33 );
34 void ParseMember(void* memberPtr, Reflection::TypeDescriptor* member, rapidjson::Value& parameter);
35 void ParseArray(void* memberPtr, Reflection::TypeDescriptor* member, rapidjson::Value& parameter);
36 private:
37 Scene* scene;
38 rapidjson::Document document;
40 };
41 }
42}
Definition Entity.hpp:14
Definition SceneLoaderJson.hpp:17
Definition Scene.hpp:21
Definition Uuid.hpp:6
Definition TypeDescriptorStruct.hpp:9
Definition TypeDescriptor.hpp:6