Olympe Engine 2.0
2D Game Engine with ECS Architecture
Loading...
Searching...
No Matches
CreateNodeCommand.h
Go to the documentation of this file.
1/**
2 * @file CreateNodeCommand.h
3 * @brief Command for creating a node
4 * @author Olympe Engine
5 * @date 2026-02-18
6 */
7
8#pragma once
9
10#include "../CommandSystem.h"
11#include "../GraphDocument.h"
12
13namespace Olympe {
14namespace NodeGraph {
15
16/**
17 * @class CreateNodeCommand
18 * @brief Creates a new node in the graph
19 */
21public:
22 CreateNodeCommand(GraphDocument* graph, const std::string& nodeType, Vector2 position);
23
24 void Execute() override;
25 void Undo() override;
26 std::string GetDescription() const override;
27
28private:
30 std::string m_nodeType;
33};
34
35} // namespace NodeGraph
36} // namespace Olympe
ComponentTypeID GetComponentTypeID_Static()
Definition ECS_Entity.h:56
Creates a new node in the graph.
void Undo() override
Undo the command.
std::string GetDescription() const override
Get description of the command.
void Execute() override
Execute the command.
Main document class for a node graph.
Base interface for all commands.
< Provides AssetID and INVALID_ASSET_ID