mirror of
https://github.com/Relintai/entity_spell_system.git
synced 2025-04-19 21:33:15 +02:00
Added description to EntityData and ENtityClassData.
This commit is contained in:
parent
99b5981e12
commit
1b8f94b818
@ -22,6 +22,13 @@ void EntityClassData::set_text_name(String value) {
|
||||
_text_name = value;
|
||||
}
|
||||
|
||||
String EntityClassData::get_text_description() {
|
||||
return _text_description;
|
||||
}
|
||||
void EntityClassData::set_text_description(String value) {
|
||||
_text_description = value;
|
||||
}
|
||||
|
||||
Ref<EntityClassData> EntityClassData::get_inherits() {
|
||||
return _inherits;
|
||||
}
|
||||
@ -1047,6 +1054,10 @@ void EntityClassData::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("set_text_name", "value"), &EntityClassData::set_text_name);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::STRING, "text_name"), "set_text_name", "get_text_name");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_text_description"), &EntityClassData::get_text_description);
|
||||
ClassDB::bind_method(D_METHOD("set_text_description", "value"), &EntityClassData::set_text_description);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::STRING, "text_description"), "set_text_description", "get_text_description");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_inherits"), &EntityClassData::get_inherits);
|
||||
ClassDB::bind_method(D_METHOD("set_inherits", "value"), &EntityClassData::set_inherits);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "inherits", PROPERTY_HINT_RESOURCE_TYPE, "EntityClassData"), "set_inherits", "get_inherits");
|
||||
|
@ -36,6 +36,9 @@ public:
|
||||
String get_text_name();
|
||||
void set_text_name(String value);
|
||||
|
||||
String get_text_description();
|
||||
void set_text_description(String value);
|
||||
|
||||
Ref<EntityClassData> get_inherits();
|
||||
void set_inherits(Ref<EntityClassData> value);
|
||||
|
||||
@ -225,6 +228,7 @@ private:
|
||||
int _id;
|
||||
|
||||
String _text_name;
|
||||
String _text_description;
|
||||
|
||||
Ref<EntityClassData> _inherits;
|
||||
|
||||
|
@ -23,6 +23,13 @@ void EntityData::set_text_name(String value) {
|
||||
_text_name = value;
|
||||
}
|
||||
|
||||
String EntityData::get_text_description() {
|
||||
return _text_description;
|
||||
}
|
||||
void EntityData::set_text_description(String value) {
|
||||
_text_description = value;
|
||||
}
|
||||
|
||||
Ref<EntityData> EntityData::get_inherits() {
|
||||
return _inherits;
|
||||
}
|
||||
@ -1160,6 +1167,10 @@ void EntityData::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("set_text_name", "value"), &EntityData::set_text_name);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::STRING, "text_name"), "set_text_name", "get_text_name");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_text_description"), &EntityData::get_text_description);
|
||||
ClassDB::bind_method(D_METHOD("set_text_description", "value"), &EntityData::set_text_description);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::STRING, "text_description"), "set_text_description", "get_text_description");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_money"), &EntityData::get_money);
|
||||
ClassDB::bind_method(D_METHOD("set_money", "value"), &EntityData::set_money);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "money"), "set_money", "get_money");
|
||||
|
@ -43,6 +43,9 @@ public:
|
||||
String get_text_name();
|
||||
void set_text_name(String value);
|
||||
|
||||
String get_text_description();
|
||||
void set_text_description(String value);
|
||||
|
||||
Ref<EntityData> get_inherits();
|
||||
void set_inherits(Ref<EntityData> value);
|
||||
|
||||
@ -244,6 +247,7 @@ private:
|
||||
EntityEnums::EntityController _entity_controller;
|
||||
|
||||
String _text_name;
|
||||
String _text_description;
|
||||
|
||||
int _money;
|
||||
int _bag_size;
|
||||
|
Loading…
Reference in New Issue
Block a user