VEX Engine
Retro looking game engine made in vulkan mostly because i wanted to understand it better.
Loading...
Searching...
No Matches
vex::DeleteCommand Class Reference

Saves Delete action command. More...

#include <EditorCommands.hpp>

Inheritance diagram for vex::DeleteCommand:
vex::ICommand

Public Member Functions

 DeleteCommand (vex::Engine &engine, std::vector< vex::GameObject * > rootsToDelete)
 Serialized object data for deletion.
void Execute () override
 Executes the delete command.
void Undo () override
 Undos the delete command with saved/serialized data.

Private Member Functions

void GatherHierarchy (vex::GameObject *obj, std::vector< vex::GameObject * > &outList)
 Gather scene hierarhy for later rebuild.

Private Attributes

vex::Enginem_engine
std::string m_sceneName
std::vector< SerializedObjectm_serializedData
std::vector< vex::Entitym_runtimeIDs

Detailed Description

Saves Delete action command.

Definition at line 79 of file EditorCommands.hpp.

Constructor & Destructor Documentation

◆ DeleteCommand()

vex::DeleteCommand::DeleteCommand ( vex::Engine & engine,
std::vector< vex::GameObject * > rootsToDelete )
inline

Serialized object data for deletion.

Definition at line 107 of file EditorCommands.hpp.

Member Function Documentation

◆ Execute()

void vex::DeleteCommand::Execute ( )
inlineoverridevirtual

Executes the delete command.

Implements vex::ICommand.

Definition at line 145 of file EditorCommands.hpp.

◆ GatherHierarchy()

void vex::DeleteCommand::GatherHierarchy ( vex::GameObject * obj,
std::vector< vex::GameObject * > & outList )
inlineprivate

Gather scene hierarhy for later rebuild.

Definition at line 88 of file EditorCommands.hpp.

◆ Undo()

void vex::DeleteCommand::Undo ( )
inlineoverridevirtual

Undos the delete command with saved/serialized data.

Implements vex::ICommand.

Definition at line 169 of file EditorCommands.hpp.

Member Data Documentation

◆ m_engine

vex::Engine& vex::DeleteCommand::m_engine
private

Definition at line 80 of file EditorCommands.hpp.

◆ m_runtimeIDs

std::vector<vex::Entity> vex::DeleteCommand::m_runtimeIDs
private

Definition at line 85 of file EditorCommands.hpp.

◆ m_sceneName

std::string vex::DeleteCommand::m_sceneName
private

Definition at line 81 of file EditorCommands.hpp.

◆ m_serializedData

std::vector<SerializedObject> vex::DeleteCommand::m_serializedData
private

Definition at line 83 of file EditorCommands.hpp.


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