Elevate Engine 1
Loading...
Searching...
No Matches
Elevate::Component Class Referenceabstract

#include <Component.h>

Inheritance diagram for Elevate::Component:
EEObject Elevate::AkBank Elevate::AudioDistanceProbe Elevate::Camera Elevate::Light Elevate::Model Elevate::Rigidbody Elevate::EditorCamera Elevate::DirectionalLight Elevate::PointLight

Public Member Functions

 Component ()=default
 
virtual ~Component ()=default
 
virtual ComponentClone ()=0
 
virtual void CopyFrom (Component *other)=0
 
virtual GameObjectComponentFactory GetFactory () const =0
 
virtual GameObjectComponentDestructor GetDestructor () const =0
 
virtual const void * GetEditorIconHandle () const
 
virtual std::type_index GetTypeIndex () const =0
 
void SetActive (bool newState)
 
bool IsActive ()
 
virtual ComponentLayout GetLayout () const
 
virtual bool RemoveFromGameObject ()
 
virtual std::string GetName () const
 
- Public Member Functions inherited from EEObject
virtual EECategory GetCategory () const
 

Public Attributes

std::function< bool()> RemoveFromGOFunc
 
GameObjectgameObject = nullptr
 

Protected Member Functions

virtual void Init ()
 
virtual void Destroy ()
 
virtual void Update ()
 
virtual void Render ()
 
virtual void RenderInEditor ()
 
virtual void RenderWhenSelected ()
 
virtual void OnSetPosition ()
 
virtual void OnSetRotation ()
 
virtual void OnSetScale ()
 
virtual void OnNotify (Event &event)
 

Protected Attributes

bool m_IsActive = true
 
- Protected Attributes inherited from EEObject
EECategory m_category
 

Friends

class GameObject
 
class Scene
 

Detailed Description

Definition at line 24 of file Component.h.

Constructor & Destructor Documentation

◆ Component()

Elevate::Component::Component ( )
default

◆ ~Component()

virtual Elevate::Component::~Component ( )
virtualdefault

Member Function Documentation

◆ Clone()

virtual Component * Elevate::Component::Clone ( )
pure virtual

◆ CopyFrom()

virtual void Elevate::Component::CopyFrom ( Component other)
pure virtual

◆ Destroy()

virtual void Elevate::Component::Destroy ( )
inlineprotectedvirtual

Reimplemented in Elevate::AudioDistanceProbe, and Elevate::Camera.

Definition at line 58 of file Component.h.

58{}

◆ GetDestructor()

virtual GameObjectComponentDestructor Elevate::Component::GetDestructor ( ) const
pure virtual

◆ GetEditorIconHandle()

virtual const void * Elevate::Component::GetEditorIconHandle ( ) const
inlinevirtual

Definition at line 40 of file Component.h.

40{ return nullptr; }

◆ GetFactory()

virtual GameObjectComponentFactory Elevate::Component::GetFactory ( ) const
pure virtual

◆ GetLayout()

virtual ComponentLayout Elevate::Component::GetLayout ( ) const
inlinevirtual

Definition at line 48 of file Component.h.

48{ return ComponentLayout(GetName(), {}); }
virtual std::string GetName() const
Definition Component.h:52

◆ GetName()

virtual std::string Elevate::Component::GetName ( ) const
inlinevirtual

Definition at line 52 of file Component.h.

52 {
53 return "Unknown Component Name";
54 //return ComponentRegistry::GetName(typeid(*this));
55 }

◆ GetTypeIndex()

virtual std::type_index Elevate::Component::GetTypeIndex ( ) const
pure virtual

◆ Init()

virtual void Elevate::Component::Init ( )
inlineprotectedvirtual

Reimplemented in Elevate::AudioDistanceProbe, Elevate::AkBank, Elevate::EditorCamera, and Elevate::Camera.

Definition at line 57 of file Component.h.

57{}

◆ IsActive()

bool Elevate::Component::IsActive ( )
inline

Definition at line 44 of file Component.h.

44{ return m_IsActive; }

◆ OnNotify()

virtual void Elevate::Component::OnNotify ( Event event)
inlineprotectedvirtual

Reimplemented in Elevate::EditorCamera.

Definition at line 70 of file Component.h.

70{}

◆ OnSetPosition()

virtual void Elevate::Component::OnSetPosition ( )
inlineprotectedvirtual

Definition at line 66 of file Component.h.

66{}

◆ OnSetRotation()

virtual void Elevate::Component::OnSetRotation ( )
inlineprotectedvirtual

Reimplemented in Elevate::Camera.

Definition at line 67 of file Component.h.

67{}

◆ OnSetScale()

virtual void Elevate::Component::OnSetScale ( )
inlineprotectedvirtual

Definition at line 68 of file Component.h.

68{}

◆ RemoveFromGameObject()

virtual bool Elevate::Component::RemoveFromGameObject ( )
inlinevirtual

Definition at line 50 of file Component.h.

50{ return false; }

◆ Render()

virtual void Elevate::Component::Render ( )
inlineprotectedvirtual

Reimplemented in Elevate::Model.

Definition at line 61 of file Component.h.

61{}

◆ RenderInEditor()

virtual void Elevate::Component::RenderInEditor ( )
inlineprotectedvirtual

Definition at line 62 of file Component.h.

62{} // Function that is only called if we are in the editor

◆ RenderWhenSelected()

virtual void Elevate::Component::RenderWhenSelected ( )
inlineprotectedvirtual

Reimplemented in Elevate::Camera.

Definition at line 63 of file Component.h.

63{}

◆ SetActive()

void Elevate::Component::SetActive ( bool  newState)
inline

Definition at line 43 of file Component.h.

43{ m_IsActive = newState; }

◆ Update()

virtual void Elevate::Component::Update ( )
inlineprotectedvirtual

Reimplemented in Elevate::EditorCamera, and Elevate::Rigidbody.

Definition at line 59 of file Component.h.

59{}

Friends And Related Symbol Documentation

◆ GameObject

friend class GameObject
friend

Definition at line 26 of file Component.h.

◆ Scene

friend class Scene
friend

Definition at line 27 of file Component.h.

Member Data Documentation

◆ gameObject

GameObject* Elevate::Component::gameObject = nullptr

Definition at line 73 of file Component.h.

◆ m_IsActive

bool Elevate::Component::m_IsActive = true
protected

Definition at line 75 of file Component.h.

◆ RemoveFromGOFunc

std::function<bool()> Elevate::Component::RemoveFromGOFunc

Definition at line 30 of file Component.h.


The documentation for this class was generated from the following file: