diff --git a/data/spells/spell.cpp b/data/spells/spell.cpp index fdada80..15939e1 100644 --- a/data/spells/spell.cpp +++ b/data/spells/spell.cpp @@ -752,7 +752,7 @@ void Spell::handle_gcd(Ref info) { Ref gcd = info->get_caster()->get_stat(ESS::get_instance()->stat_get_id("Global Cooldown")); if (gcd.is_valid()) - info->get_caster()->sstart_global_cooldown(gcd->gets_current()); + info->get_caster()->gcd_starts(gcd->gets_current()); } } void Spell::handle_cooldown(Ref info) { @@ -921,7 +921,7 @@ void Spell::_sstart_casting(Ref info) { return; } - if ((get_global_cooldown_enabled() && info->get_caster()->gets_has_global_cooldown()) || + if ((get_global_cooldown_enabled() && info->get_caster()->gcd_hass()) || info->get_caster()->hass_category_cooldown(get_spell_type()) || info->get_caster()->hass_cooldown(get_id())) { return; diff --git a/doc_classes/Entity.xml b/doc_classes/Entity.xml index 27aa5a1..72bc8f4 100644 --- a/doc_classes/Entity.xml +++ b/doc_classes/Entity.xml @@ -1692,7 +1692,7 @@ - + @@ -1970,13 +1970,13 @@ - + - + @@ -2196,13 +2196,13 @@ - + - + @@ -3604,7 +3604,7 @@ - + diff --git a/entities/entity.cpp b/entities/entity.cpp index 74a26ba..25cb2c8 100644 --- a/entities/entity.cpp +++ b/entities/entity.cpp @@ -1523,33 +1523,33 @@ bool Entity::getc_is_dead() { return _c_is_dead; } -bool Entity::getc_has_global_cooldown() { +bool Entity::gcd_hasc() { return _c_gcd >= 0.000000001; } -bool Entity::gets_has_global_cooldown() { +bool Entity::gcd_hass() { return _s_gcd >= 0.000000001; } -bool Entity::getc_global_cooldown() { +float Entity::gcd_getc() { return _c_gcd; } -bool Entity::gets_global_cooldown() { +float Entity::gcd_gets() { return _s_gcd; } -void Entity::sstart_global_cooldown(float value) { +void Entity::gcd_starts(float value) { _s_gcd = value; void son_gcd_started(); emit_signal("sgcd_started", _s_gcd); - ORPC(cstart_global_cooldown, value); + ORPC(gcd_startc, value); } -void Entity::cstart_global_cooldown(float value) { +void Entity::gcd_startc(float value) { _c_gcd = value; void con_gcd_started(); @@ -5751,7 +5751,7 @@ Entity::Entity() { //// Global Cooldown //// - SET_RPC_REMOTE("cstart_global_cooldown"); + SET_RPC_REMOTE("gcd_startc"); //// States //// @@ -7401,12 +7401,12 @@ void Entity::_bind_methods() { ADD_SIGNAL(MethodInfo("cgcd_started", PropertyInfo(Variant::REAL, "value"))); ADD_SIGNAL(MethodInfo("cgcd_finished")); - ClassDB::bind_method(D_METHOD("getc_has_global_cooldown"), &Entity::getc_has_global_cooldown); - ClassDB::bind_method(D_METHOD("gets_has_global_cooldown"), &Entity::gets_has_global_cooldown); - ClassDB::bind_method(D_METHOD("getc_global_cooldown"), &Entity::getc_global_cooldown); - ClassDB::bind_method(D_METHOD("gets_global_cooldown"), &Entity::gets_global_cooldown); - ClassDB::bind_method(D_METHOD("sstart_global_cooldown", "value"), &Entity::sstart_global_cooldown); - ClassDB::bind_method(D_METHOD("cstart_global_cooldown", "value"), &Entity::cstart_global_cooldown); + ClassDB::bind_method(D_METHOD("gcd_hasc"), &Entity::gcd_hasc); + ClassDB::bind_method(D_METHOD("gcd_hass"), &Entity::gcd_hass); + ClassDB::bind_method(D_METHOD("gcd_getc"), &Entity::gcd_getc); + ClassDB::bind_method(D_METHOD("gcd_gets"), &Entity::gcd_gets); + ClassDB::bind_method(D_METHOD("gcd_starts", "value"), &Entity::gcd_starts); + ClassDB::bind_method(D_METHOD("gcd_startc", "value"), &Entity::gcd_startc); //Data ClassDB::bind_method(D_METHOD("adds_data", "data"), &Entity::adds_data); diff --git a/entities/entity.h b/entities/entity.h index 7530e64..8eda29d 100644 --- a/entities/entity.h +++ b/entities/entity.h @@ -417,12 +417,12 @@ public: //// Global Cooldown //// - bool getc_has_global_cooldown(); - bool gets_has_global_cooldown(); - bool getc_global_cooldown(); - bool gets_global_cooldown(); - void sstart_global_cooldown(float value); - void cstart_global_cooldown(float value); + bool gcd_hasc(); + bool gcd_hass(); + float gcd_getc(); + float gcd_gets(); + void gcd_starts(float value); + void gcd_startc(float value); //// States //// int getc_state();