Moved C++ tools out
This commit is contained in:
29
archive/dawntools/prefabtool/PrefabParser.hpp
Normal file
29
archive/dawntools/prefabtool/PrefabParser.hpp
Normal file
@ -0,0 +1,29 @@
|
||||
// Copyright (c) 2023 Dominic Masters
|
||||
//
|
||||
// This software is released under the MIT License.
|
||||
// https://opensource.org/licenses/MIT
|
||||
|
||||
#pragma once
|
||||
#include "util/parser/SceneItemComponentParser.hpp"
|
||||
#include "util/parser/SceneItemParser.hpp"
|
||||
|
||||
namespace Dawn {
|
||||
struct Prefab {
|
||||
struct SceneItemComponentRegistry *registry;
|
||||
struct SceneItem root;
|
||||
std::string name;
|
||||
std::string type;
|
||||
};
|
||||
|
||||
class PrefabParser : public XmlParser<struct Prefab> {
|
||||
protected:
|
||||
std::vector<std::string> getRequiredAttributes() override;
|
||||
std::map<std::string, std::string> getOptionalAttributes() override;
|
||||
int32_t onParse(
|
||||
Xml *node,
|
||||
std::map<std::string, std::string> values,
|
||||
struct Prefab *out,
|
||||
std::string *error
|
||||
) override;
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user