dffb7b7972
- editor project - build system fixes - dummy data editor panels mock
33 lines
712 B
C++
33 lines
712 B
C++
#pragma once
|
|
|
|
#include <sophia/frame_info.hpp>
|
|
#include <sophia/ui/panel.hpp>
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
class SceneHierarchyPanel : public sophia::Panel {
|
|
public:
|
|
SceneHierarchyPanel() : Panel{"Scene Hierarchy"} {}
|
|
|
|
void onUpdate(const sophia::FrameInfo& frameInfo) override;
|
|
|
|
private:
|
|
struct Node {
|
|
std::string name;
|
|
std::vector<Node> children;
|
|
};
|
|
|
|
void drawNode(const Node& node);
|
|
|
|
std::vector<Node> nodes = {
|
|
{"Main Camera", {}},
|
|
{"Directional Light", {}},
|
|
{"Ground", {}},
|
|
{"Player", {}},
|
|
{"Enemies", {{"Enemy_01", {}}, {"Enemy_02", {}}, {"Enemy_03", {}}}},
|
|
{"Props", {{"Crate_01", {}}, {"Crate_02", {}}}},
|
|
};
|
|
|
|
std::string selected;
|
|
};
|