Plasma Engine  2.0
Loading...
Searching...
No Matches
HierarchyChangedMessages.h
1#pragma once
2
3#include <Core/World/Declarations.h>
4#include <Foundation/Communication/Message.h>
5
6struct PL_CORE_DLL plMsgParentChanged : public plMessage
7{
8 PL_DECLARE_MESSAGE_TYPE(plMsgParentChanged, plMessage);
9
10 enum class Type
11 {
12 ParentLinked,
13 ParentUnlinked,
14 Invalid
15 };
16
17 Type m_Type = Type::Invalid;
18 plGameObjectHandle m_hParent; // previous or new parent, depending on m_Type
19};
20
21struct PL_CORE_DLL plMsgChildrenChanged : public plMessage
22{
23 PL_DECLARE_MESSAGE_TYPE(plMsgChildrenChanged, plMessage);
24
25 enum class Type
26 {
27 ChildAdded,
28 ChildRemoved
29 };
30
31 Type m_Type;
32 plGameObjectHandle m_hParent;
33 plGameObjectHandle m_hChild;
34};
35
36struct PL_CORE_DLL plMsgComponentsChanged : public plMessage
37{
38 PL_DECLARE_MESSAGE_TYPE(plMsgComponentsChanged, plMessage);
39
40 enum class Type
41 {
42 ComponentAdded,
43 ComponentRemoved,
44 Invalid
45 };
46
47 Type m_Type = Type::Invalid;
48 plGameObjectHandle m_hOwner;
49 plComponentHandle m_hComponent;
50};
Base class for all message types. Each message type has it's own id which is used to dispatch message...
Definition Message.h:22
A handle to a component.
Definition Declarations.h:138
A handle to a game object.
Definition Declarations.h:76
Definition HierarchyChangedMessages.h:22
Definition HierarchyChangedMessages.h:37
Definition HierarchyChangedMessages.h:7