diff options
| author | Andy Maloney <asmaloney@gmail.com> | 2022-11-16 16:43:44 -0500 |
|---|---|---|
| committer | Andy Maloney <asmaloney@gmail.com> | 2022-11-16 16:43:44 -0500 |
| commit | fbf7f7bc36f3aa81500ce70bec22ee48206c6b4e (patch) | |
| tree | 36d6ba191d0be222415f82539609b705b18e54ab /test/src | |
| parent | dc38c7243262b6b73b527d6e3bbadfea30197a7a (diff) | |
| download | redot-cpp-fbf7f7bc36f3aa81500ce70bec22ee48206c6b4e.tar.gz | |
Fix some type warnings in example
Diffstat (limited to 'test/src')
| -rw-r--r-- | test/src/example.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/src/example.cpp b/test/src/example.cpp index 890319d..3e10f32 100644 --- a/test/src/example.cpp +++ b/test/src/example.cpp @@ -40,7 +40,7 @@ void Example::_notification(int p_what) { bool Example::_set(const StringName &p_name, const Variant &p_value) { String name = p_name; if (name.begins_with("dproperty")) { - int index = name.get_slicec('_', 1).to_int(); + int64_t index = name.get_slicec('_', 1).to_int(); dprop[index] = p_value; return true; } @@ -54,7 +54,7 @@ bool Example::_set(const StringName &p_name, const Variant &p_value) { bool Example::_get(const StringName &p_name, Variant &r_ret) const { String name = p_name; if (name.begins_with("dproperty")) { - int index = name.get_slicec('_', 1).to_int(); + int64_t index = name.get_slicec('_', 1).to_int(); r_ret = dprop[index]; return true; } @@ -66,7 +66,7 @@ bool Example::_get(const StringName &p_name, Variant &r_ret) const { } String Example::_to_string() const { - return "[ GDExtension::Example <--> Instance ID:" + itos(get_instance_id()) + " ]"; + return "[ GDExtension::Example <--> Instance ID:" + uitos(get_instance_id()) + " ]"; } void Example::_get_property_list(List<PropertyInfo> *p_list) const { |
