summaryrefslogtreecommitdiffstats
path: root/src/core/RID.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/RID.cpp')
-rw-r--r--src/core/RID.cpp32
1 files changed, 11 insertions, 21 deletions
diff --git a/src/core/RID.cpp b/src/core/RID.cpp
index aaf8e7a..7ca1e7a 100644
--- a/src/core/RID.cpp
+++ b/src/core/RID.cpp
@@ -6,50 +6,40 @@
namespace godot {
-RID::RID()
-{
+RID::RID() {
godot::api->godot_rid_new(&_godot_rid);
}
-RID::RID(Object *p)
-{
- godot::api->godot_rid_new_with_resource(&_godot_rid, (const godot_object *) p);
+RID::RID(Object *p) {
+ godot::api->godot_rid_new_with_resource(&_godot_rid, (const godot_object *)p);
}
-int32_t RID::get_rid() const
-{
+int32_t RID::get_rid() const {
return godot::api->godot_rid_get_id(&_godot_rid);
}
-bool RID::operator==(const RID & p_other) const
-{
+bool RID::operator==(const RID &p_other) const {
return godot::api->godot_rid_operator_equal(&_godot_rid, &p_other._godot_rid);
}
-bool RID::operator!=(const RID & p_other) const
-{
+bool RID::operator!=(const RID &p_other) const {
return !(*this == p_other);
}
-bool RID::operator<(const RID & p_other) const
-{
+bool RID::operator<(const RID &p_other) const {
return godot::api->godot_rid_operator_less(&_godot_rid, &p_other._godot_rid);
}
-bool RID::operator>(const RID & p_other) const
-{
+bool RID::operator>(const RID &p_other) const {
return !(*this < p_other) && *this != p_other;
}
-bool RID::operator<=(const RID & p_other) const
-{
+bool RID::operator<=(const RID &p_other) const {
return (*this < p_other) || *this == p_other;
}
-bool RID::operator>=(const RID & p_other) const
-{
+bool RID::operator>=(const RID &p_other) const {
return !(*this < p_other);
}
-
-}
+} // namespace godot