NSMBW-Decomp
A decompilation of New Super Mario Bros. Wii
Loading...
Searching...
No Matches
s_GlobalData.hpp
1
#pragma once
2
3
/**
4
* @brief A templated global data holder class.
5
* @tparam T The class that contains the global data struct.
6
* @unofficial
7
*/
8
template
<
typename
T>
9
class
sGlobalData_c
{
10
public
:
11
static
const
typename
T::GlobalData_t
mData
;
///< @unofficial
12
};
13
14
// Some beautiful template magic to get quick access to the global data of a class.
15
16
template
<
class
T>
17
struct
remove_reference
{
typedef
T type; };
18
template
<
class
T>
19
struct
remove_reference
<T&> {
typedef
T type; };
20
21
#define GLOBAL_DATA sGlobalData_c<remove_reference<decltype(*this)>::type>::mData
sGlobalData_c
A templated global data holder class.
Definition
s_GlobalData.hpp:9
sGlobalData_c::mData
static const T::GlobalData_t mData
Definition
s_GlobalData.hpp:11
remove_reference
Definition
s_GlobalData.hpp:17
include
game
sLib
s_GlobalData.hpp
Made with ❤️ by
CLF78
and
RootCubed
. Logos by
Chasical
and
B1
. Website generated by
Doxygen
1.15.0