Viewport controls

This commit is contained in:
Dynamitos
2022-11-17 16:47:42 +01:00
parent f635ee2100
commit 4ba0bf3b45
73 changed files with 627 additions and 449 deletions
+31
View File
@@ -0,0 +1,31 @@
#pragma once
#include "Entity.h"
#include "Component/Transform.h"
namespace Seele
{
DECLARE_REF(Actor)
// Actors are entities that are part of the scene hierarchy
// In order for that hierarchy to make sense it requires at least a transform component
class Actor : public Entity
{
public:
Actor(PScene scene);
virtual ~Actor();
PActor getParent();
void addChild(PActor child);
void removeChild(PActor child);
Array<PActor> getChildren();
// Returns a read-only copy of the actors transform
const Component::Transform& getTransform() const;
protected:
//Component::Transform& getTransform();
void setParent(PActor parent);
PActor parent;
Array<PActor> children;
};
DEFINE_REF(Actor)
} // namespace Seele