diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/gdnative/SCsub | 4 | ||||
-rw-r--r-- | modules/visual_script/visual_script_nodes.cpp | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/modules/gdnative/SCsub b/modules/gdnative/SCsub index 54d0672a5b..f5a593cf4e 100644 --- a/modules/gdnative/SCsub +++ b/modules/gdnative/SCsub @@ -245,7 +245,7 @@ if ARGUMENTS.get('gdnative_wrapper', False): gd_wrapper_env = env.Clone() gd_wrapper_env.Append(CPPPATH=['#modules/gdnative/include/']) - # I think this doesn't work on MSVC yet... - gd_wrapper_env.Append(CCFLAGS=['-fPIC']) + if not env.msvc: + gd_wrapper_env.Append(CCFLAGS=['-fPIC']) gd_wrapper_env.Library("#bin/gdnative_wrapper_code", [gensource]) diff --git a/modules/visual_script/visual_script_nodes.cpp b/modules/visual_script/visual_script_nodes.cpp index 05ff629d1b..95ad7256b3 100644 --- a/modules/visual_script/visual_script_nodes.cpp +++ b/modules/visual_script/visual_script_nodes.cpp @@ -1064,9 +1064,9 @@ void VisualScriptConstant::set_constant_type(Variant::Type p_type) { return; type = p_type; - ports_changed_notify(); Variant::CallError ce; value = Variant::construct(type, NULL, 0, ce); + ports_changed_notify(); _change_notify(); } @@ -1111,7 +1111,7 @@ void VisualScriptConstant::_bind_methods() { } ADD_PROPERTY(PropertyInfo(Variant::INT, "type", PROPERTY_HINT_ENUM, argt), "set_constant_type", "get_constant_type"); - ADD_PROPERTY(PropertyInfo(Variant::NIL, "value", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NIL_IS_VARIANT), "set_constant_value", "get_constant_value"); + ADD_PROPERTY(PropertyInfo(Variant::NIL, "value", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NIL_IS_VARIANT | PROPERTY_USAGE_DEFAULT), "set_constant_value", "get_constant_value"); } class VisualScriptNodeInstanceConstant : public VisualScriptNodeInstance { |