summaryrefslogtreecommitdiff
path: root/core/io
diff options
context:
space:
mode:
Diffstat (limited to 'core/io')
-rw-r--r--core/io/marshalls.cpp8
-rw-r--r--core/io/resource_format_binary.cpp8
2 files changed, 8 insertions, 8 deletions
diff --git a/core/io/marshalls.cpp b/core/io/marshalls.cpp
index dccf70ad7a..ceae543ff9 100644
--- a/core/io/marshalls.cpp
+++ b/core/io/marshalls.cpp
@@ -139,8 +139,8 @@ Error decode_variant(Variant &r_variant, const uint8_t *p_buffer, int p_len, int
ERR_FAIL_COND_V(len < (int)4 * 4, ERR_INVALID_DATA);
Rect2 val;
- val.pos.x = decode_float(&buf[0]);
- val.pos.y = decode_float(&buf[4]);
+ val.position.x = decode_float(&buf[0]);
+ val.position.y = decode_float(&buf[4]);
val.size.x = decode_float(&buf[8]);
val.size.y = decode_float(&buf[12]);
r_variant = val;
@@ -861,8 +861,8 @@ Error encode_variant(const Variant &p_variant, uint8_t *r_buffer, int &r_len) {
if (buf) {
Rect2 r2 = p_variant;
- encode_float(r2.pos.x, &buf[0]);
- encode_float(r2.pos.y, &buf[4]);
+ encode_float(r2.position.x, &buf[0]);
+ encode_float(r2.position.y, &buf[4]);
encode_float(r2.size.x, &buf[8]);
encode_float(r2.size.y, &buf[12]);
}
diff --git a/core/io/resource_format_binary.cpp b/core/io/resource_format_binary.cpp
index 26b53c2a31..01cad9d525 100644
--- a/core/io/resource_format_binary.cpp
+++ b/core/io/resource_format_binary.cpp
@@ -155,8 +155,8 @@ Error ResourceInteractiveLoaderBinary::parse_variant(Variant &r_v) {
case VARIANT_RECT2: {
Rect2 v;
- v.pos.x = f->get_real();
- v.pos.y = f->get_real();
+ v.position.x = f->get_real();
+ v.position.y = f->get_real();
v.size.x = f->get_real();
v.size.y = f->get_real();
r_v = v;
@@ -1288,8 +1288,8 @@ void ResourceFormatSaverBinaryInstance::write_variant(const Variant &p_property,
f->store_32(VARIANT_RECT2);
Rect2 val = p_property;
- f->store_real(val.pos.x);
- f->store_real(val.pos.y);
+ f->store_real(val.position.x);
+ f->store_real(val.position.y);
f->store_real(val.size.x);
f->store_real(val.size.y);