From 05de7ce6caf441f8b64dd60d1837835f10d06520 Mon Sep 17 00:00:00 2001 From: reduz Date: Fri, 6 Nov 2020 22:29:22 -0300 Subject: Refactored variant setters/getters -Discern between named, indexed and keyed -Get direct access to functions for typed GDScript and GDNative bindings -Small changes to some classes in order to work with the new setget binder --- modules/gdscript/gdscript_function.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'modules/gdscript/gdscript_function.cpp') diff --git a/modules/gdscript/gdscript_function.cpp b/modules/gdscript/gdscript_function.cpp index 1da0e7b4c6..30d0049d47 100644 --- a/modules/gdscript/gdscript_function.cpp +++ b/modules/gdscript/gdscript_function.cpp @@ -620,7 +620,7 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a const StringName *index = &_global_names_ptr[indexname]; bool valid; - dst->set_named(*index, *value, &valid); + dst->set_named(*index, *value, valid); #ifdef DEBUG_ENABLED if (!valid) { @@ -647,10 +647,10 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a bool valid; #ifdef DEBUG_ENABLED //allow better error message in cases where src and dst are the same stack position - Variant ret = src->get_named(*index, &valid); + Variant ret = src->get_named(*index, valid); #else - *dst = src->get_named(*index, &valid); + *dst = src->get_named(*index, valid); #endif #ifdef DEBUG_ENABLED if (!valid) { -- cgit v1.2.3