LeviLamina
Loading...
Searching...
No Matches
EntityRegistry.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/ecs/EntityId.h"
7#include "mc/deps/game_refs/EnableGetWeakRef.h"
8#include "mc/deps/game_refs/WeakRef.h"
9
10class EntityRegistry : public ::EnableGetWeakRef<::EntityRegistry>,
11 public ::std::enable_shared_from_this<::EntityRegistry> {
12public:
13 // EntityRegistry inner types define
14 using Base = ::entt::basic_registry<::EntityId>;
15
16 using BaseShared = ::std::enable_shared_from_this<::EntityRegistry>;
17
19
20 using EntityInvokeCallbackFunc = ::std::function<void(::EntityId)>;
21
22 using EntityInvokeCallbackPair = ::std::pair<::std::function<void(::EntityId)>, ::std::function<void(::EntityId)>>;
23
24 using EntityInvokeCallbackSig = void(::EntityId);
25
26public:
27 // member variables
28 // NOLINTBEGIN
29 ::ll::TypedStorage<8, 32, ::std::string> mDebugName;
30 ::ll::TypedStorage<8, 304, ::entt::basic_registry<::EntityId>> mRegistry;
31 ::ll::TypedStorage<4, 4, uint> mId;
32 ::ll::TypedStorage<8, 64, ::std::function<void(::EntityId)>> mPreEntityInvoke;
33 ::ll::TypedStorage<8, 64, ::std::function<void(::EntityId)>> mPostEntityInvoke;
34 // NOLINTEND
35
36public:
37 // prevent constructor by default
38 EntityRegistry();
39
40public:
41 // member functions
42 // NOLINTBEGIN
43 MCNAPI explicit EntityRegistry(::std::string identifier);
44
45 MCNAPI ::WeakRef<::EntityRegistry> getWeakRef();
46
47 MCNAPI void postViewEachCount(uint64 count);
48
49 MCNAPI_C ::std::pair<::std::function<void(::EntityId)>, ::std::function<void(::EntityId)>> setEntityInvokeCallbacks(
50 ::std::function<void(::EntityId)>&& preInvoke,
51 ::std::function<void(::EntityId)>&& postInvoke
52 );
53
55 // NOLINTEND
56
57public:
58 // static variables
59 // NOLINTBEGIN
60 MCNAPI static ::std::atomic<uint>& mRegistryCount();
61 // NOLINTEND
62
63public:
64 // constructor thunks
65 // NOLINTBEGIN
66 MCNAPI void* $ctor(::std::string identifier);
67 // NOLINTEND
68
69public:
70 // destructor thunk
71 // NOLINTBEGIN
72 MCNAPI void $dtor();
73 // NOLINTEND
74};
Definition EnableGetWeakRef.h:6
Definition EntityId.h:13
MCAPI ::WeakRef<::EntityRegistry > getWeakRef()
MCAPI void * $ctor(::std::string identifier)
MCAPI ~EntityRegistry()
static MCAPI ::std::atomic< uint > & mRegistryCount()
MCAPI EntityRegistry(::std::string identifier)
MCAPI void postViewEachCount(uint64 count)
MCAPI void $dtor()