chore: moved macros.h to modules/
This commit is contained in:
parent
78433f1514
commit
a61b52806a
5 changed files with 21 additions and 4 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
#include "character.h"
|
#include "character.h"
|
||||||
#include "authority/macros.h"
|
|
||||||
#include "core/config/engine.h"
|
#include "core/config/engine.h"
|
||||||
|
#include "macros.h"
|
||||||
|
|
||||||
void CharacterData::_bind_methods() {
|
void CharacterData::_bind_methods() {
|
||||||
BIND_PROPERTY(Variant::FLOAT, speed);
|
BIND_PROPERTY(Variant::FLOAT, speed);
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "authority/macros.h"
|
|
||||||
#include "core/io/resource.h"
|
#include "core/io/resource.h"
|
||||||
#include "core/templates/hash_set.h"
|
#include "core/templates/hash_set.h"
|
||||||
|
#include "macros.h"
|
||||||
#include "scene/3d/physics/character_body_3d.h"
|
#include "scene/3d/physics/character_body_3d.h"
|
||||||
|
|
||||||
class CharacterData : public Resource {
|
class CharacterData : public Resource {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "authority/macros.h"
|
#include "macros.h"
|
||||||
#include "scene/3d/marker_3d.h"
|
#include "scene/3d/marker_3d.h"
|
||||||
class Character;
|
class Character;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "authority/character.h"
|
#include "authority/character.h"
|
||||||
#include "authority/macros.h"
|
|
||||||
#include "authority/nav_marker.h"
|
#include "authority/nav_marker.h"
|
||||||
|
#include "macros.h"
|
||||||
|
|
||||||
class PlayerCharacter : public Character {
|
class PlayerCharacter : public Character {
|
||||||
GDCLASS(PlayerCharacter, Character);
|
GDCLASS(PlayerCharacter, Character);
|
||||||
|
|
|
||||||
|
|
@ -25,4 +25,21 @@
|
||||||
this->m_property = value; \
|
this->m_property = value; \
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define GET_SET_FNS_EX(m_type, m_property, m_ex) \
|
||||||
|
m_type get_##m_property() const { \
|
||||||
|
return this->m_property; \
|
||||||
|
} \
|
||||||
|
void set_##m_property(m_type value) { \
|
||||||
|
m_ex; \
|
||||||
|
this->m_property = value; \
|
||||||
|
}
|
||||||
|
|
||||||
|
#define __VA_ARGS__STRING(...) String(#__VA_ARGS__)
|
||||||
|
|
||||||
|
#define GDENUM(M_Name, ...) \
|
||||||
|
enum M_Name { __VA_ARGS__ }; \
|
||||||
|
static String M_Name##_hint() { \
|
||||||
|
return __VA_ARGS__STRING(__VA_ARGS__); \
|
||||||
|
}
|
||||||
|
|
||||||
#endif // !GODOT_EXTRA_MACROS_H
|
#endif // !GODOT_EXTRA_MACROS_H
|
||||||
Loading…
Add table
Add a link
Reference in a new issue