Toast Engine
Toggle main menu visibility
Loading...
Searching...
No Matches
world_events.hpp
Go to the documentation of this file.
1
8
9
#pragma once
10
#include "
box.hpp
"
11
12
#include <string>
13
#include <toast/events/event.hpp>
14
#include <
toast/uid.hpp
>
15
16
namespace
toast {
17
class
Node
;
18
}
19
20
namespace
event {
21
22
struct
LoadNode : Event<LoadNode> {
23
explicit
LoadNode(
toast::UID
uid) : uid(uid) { }
24
25
toast::UID
uid;
26
};
27
28
struct
LoadNodeByURI : Event<LoadNodeByURI> {
29
explicit
LoadNodeByURI(std::string uri) : uri(std::move(uri)) { }
30
31
std::string uri;
32
};
33
34
struct
SetWorldRoot : Event<SetWorldRoot> {
35
explicit
SetWorldRoot(
toast::Node
& node) : node(&node) { }
36
37
toast::Node
* node;
38
};
39
40
struct
CacheNode : Event<CacheNode> {
41
explicit
CacheNode(
toast::Node
& node) : node(&node) { }
42
43
toast::Node
* node;
44
};
45
46
struct
DestroyNode : Event<DestroyNode> {
47
explicit
DestroyNode(
toast::Node
& node) : node(&node) { }
48
49
toast::Node
* node;
50
};
51
52
struct
MakeNodeGlobal : Event<MakeNodeGlobal> {
53
explicit
MakeNodeGlobal(
toast::Node
& node) : node(&node) { }
54
55
toast::Node
* node;
56
};
57
58
struct
AttachNode : Event<AttachNode> {
59
explicit
AttachNode(
toast::Node
& node,
toast::Node
& parent) : node(&node), parent(&parent) { }
60
61
toast::Node
* node;
62
toast::Node
* parent;
63
};
64
65
}
box.hpp
pseudo shared pointer for Nodes
toast::Node
Definition
node.hpp:81
toast::UID
Definition
uid.hpp:20
uid.hpp
Unique identifier for everything that exists in our engine.
engine
src
toast
world
world_events.hpp
Generated by
1.17.0