Olympe Engine 2.0
2D Game Engine with ECS Architecture
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
Olympe::InspectorPanel Class Reference

InspectorPanel - Adaptive inspector panel Displays properties based on current selection context. More...

#include <InspectorPanel.h>

+ Collaboration diagram for Olympe::InspectorPanel:

Public Member Functions

 InspectorPanel ()
 
 ~InspectorPanel ()
 
void Initialize ()
 
void Shutdown ()
 
void Render ()
 
void RenderContent ()
 
void SetSelectedActionNode (const std::string &taskID, const std::string &nodeName, const std::unordered_map< std::string, std::string > &parameters)
 Set the currently selected action node for parameter editing.
 
void ClearSelectedActionNode ()
 Clear the current action node selection.
 
ActionParametersPanelGetActionPanel ()
 Get the action parameters panel (for direct access if needed).
 

Static Public Member Functions

static void SetDebugBlackboard (const LocalBlackboard *bb)
 Register a live LocalBlackboard to display in the inspector.
 
static InspectorPanelGetInstance ()
 Get the active InspectorPanel instance (singleton access).
 
static void SetInstance (InspectorPanel *instance)
 Set the active InspectorPanel instance.
 

Private Member Functions

void RenderNodeInspector ()
 
void RenderEntityInspector ()
 
void RenderAssetFileInspector ()
 
void RenderActionNodeInspector ()
 
void RenderDebugBlackboard ()
 
void RenderComponentProperties (uint64_t entityId, const std::string &componentType)
 
InspectorContext DetermineContext ()
 

Private Attributes

std::unique_ptr< ActionParametersPanelm_actionPanel
 
bool m_hasSelectedAction = false
 

Static Private Attributes

static const LocalBlackboards_DebugBlackboard = nullptr
 
static InspectorPanels_Instance = nullptr
 

Detailed Description

InspectorPanel - Adaptive inspector panel Displays properties based on current selection context.

Runtime debug overlay: Call SetDebugBlackboard() with a pointer to the live LocalBlackboard of the currently executing task graph to make InspectorPanel show its values as an overlay section. Pass nullptr to hide the section. The pointer is not owned and must remain valid for the frame duration.

Definition at line 40 of file InspectorPanel.h.

Constructor & Destructor Documentation

◆ InspectorPanel()

Olympe::InspectorPanel::InspectorPanel ( )

Definition at line 29 of file InspectorPanel.cpp.

◆ ~InspectorPanel()

Olympe::InspectorPanel::~InspectorPanel ( )

Definition at line 35 of file InspectorPanel.cpp.

Member Function Documentation

◆ ClearSelectedActionNode()

void Olympe::InspectorPanel::ClearSelectedActionNode ( )

Clear the current action node selection.

Definition at line 73 of file InspectorPanel.cpp.

References m_actionPanel, and m_hasSelectedAction.

Referenced by RenderActionNodeInspector().

+ Here is the caller graph for this function:

◆ DetermineContext()

InspectorContext Olympe::InspectorPanel::DetermineContext ( )
private

Definition at line 119 of file InspectorPanel.cpp.

References Olympe::AssetFile, Olympe::BlueprintEditor::Get(), Olympe::None, and Olympe::RuntimeEntity.

Referenced by RenderContent().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetActionPanel()

ActionParametersPanel * Olympe::InspectorPanel::GetActionPanel ( )
inline

Get the action parameters panel (for direct access if needed).

Definition at line 87 of file InspectorPanel.h.

References m_actionPanel.

◆ GetInstance()

static InspectorPanel * Olympe::InspectorPanel::GetInstance ( )
inlinestatic

Get the active InspectorPanel instance (singleton access).

Returns nullptr if not initialized.

Definition at line 61 of file InspectorPanel.h.

References s_Instance.

Referenced by Olympe::NodeGraphPanel::HandleNodeInteractions().

+ Here is the caller graph for this function:

◆ Initialize()

void Olympe::InspectorPanel::Initialize ( )

Definition at line 39 of file InspectorPanel.cpp.

References m_actionPanel, and SetInstance().

Referenced by Olympe::BlueprintEditorGUI::Initialize().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Render()

void Olympe::InspectorPanel::Render ( )

Definition at line 53 of file InspectorPanel.cpp.

References RenderContent().

+ Here is the call graph for this function:

◆ RenderActionNodeInspector()

void Olympe::InspectorPanel::RenderActionNodeInspector ( )
private

Definition at line 402 of file InspectorPanel.cpp.

References ClearSelectedActionNode(), GetComponentTypeID_Static(), and m_actionPanel.

Referenced by RenderContent().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ RenderAssetFileInspector()

void Olympe::InspectorPanel::RenderAssetFileInspector ( )
private

◆ RenderComponentProperties()

void Olympe::InspectorPanel::RenderComponentProperties ( uint64_t  entityId,
const std::string &  componentType 
)
private

Definition at line 189 of file InspectorPanel.cpp.

References Olympe::EntityInspectorManager::Get(), Olympe::EntityInspectorManager::GetComponentProperties(), GetComponentTypeID_Static(), and Olympe::EntityInspectorManager::SetComponentProperty().

Referenced by RenderEntityInspector().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ RenderContent()

void Olympe::InspectorPanel::RenderContent ( )

◆ RenderDebugBlackboard()

void Olympe::InspectorPanel::RenderDebugBlackboard ( )
private

Definition at line 352 of file InspectorPanel.cpp.

References Olympe::Bool, Olympe::EntityID, Olympe::Float, GetComponentTypeID_Static(), Olympe::LocalBlackboard::GetValue(), Olympe::LocalBlackboard::GetVariableNames(), Olympe::Int, s_DebugBlackboard, Olympe::String, and Olympe::Vector.

Referenced by RenderContent().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ RenderEntityInspector()

void Olympe::InspectorPanel::RenderEntityInspector ( )
private

◆ RenderNodeInspector()

void Olympe::InspectorPanel::RenderNodeInspector ( )
private

Definition at line 139 of file InspectorPanel.cpp.

Referenced by RenderContent().

+ Here is the caller graph for this function:

◆ SetDebugBlackboard()

void Olympe::InspectorPanel::SetDebugBlackboard ( const LocalBlackboard bb)
static

Register a live LocalBlackboard to display in the inspector.

Parameters
bbPointer to the blackboard (non-owning). nullptr removes it.

Definition at line 24 of file InspectorPanel.cpp.

References GetComponentTypeID_Static(), and s_DebugBlackboard.

Referenced by Olympe::WorldBridge_SetBlackboard().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SetInstance()

static void Olympe::InspectorPanel::SetInstance ( InspectorPanel instance)
inlinestatic

Set the active InspectorPanel instance.

Called internally by Initialize().

Definition at line 67 of file InspectorPanel.h.

References GetComponentTypeID_Static(), and s_Instance.

Referenced by Initialize(), and Shutdown().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SetSelectedActionNode()

void Olympe::InspectorPanel::SetSelectedActionNode ( const std::string &  taskID,
const std::string &  nodeName,
const std::unordered_map< std::string, std::string > &  parameters 
)

Set the currently selected action node for parameter editing.

Parameters
taskIDThe task ID (e.g., "log_message", "patrol_path")
nodeNameThe display name of the node
parametersMap of parameter name -> value

Definition at line 60 of file InspectorPanel.cpp.

References GetComponentTypeID_Static(), m_actionPanel, and m_hasSelectedAction.

+ Here is the call graph for this function:

◆ Shutdown()

void Olympe::InspectorPanel::Shutdown ( )

Definition at line 46 of file InspectorPanel.cpp.

References m_actionPanel, and SetInstance().

Referenced by Olympe::BlueprintEditorGUI::Shutdown().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ m_actionPanel

std::unique_ptr<ActionParametersPanel> Olympe::InspectorPanel::m_actionPanel
private

◆ m_hasSelectedAction

bool Olympe::InspectorPanel::m_hasSelectedAction = false
private

Definition at line 101 of file InspectorPanel.h.

Referenced by ClearSelectedActionNode(), RenderContent(), and SetSelectedActionNode().

◆ s_DebugBlackboard

const LocalBlackboard * Olympe::InspectorPanel::s_DebugBlackboard = nullptr
staticprivate

Definition at line 99 of file InspectorPanel.h.

Referenced by RenderDebugBlackboard(), and SetDebugBlackboard().

◆ s_Instance

InspectorPanel * Olympe::InspectorPanel::s_Instance = nullptr
staticprivate

Definition at line 104 of file InspectorPanel.h.

Referenced by GetInstance(), and SetInstance().


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