Merge pull request #51146 from Haskaris/fix-output-port-mismatch

This commit is contained in:
Rémi Verschelde 2022-08-25 21:45:15 +02:00 committed by GitHub
commit d073d10739
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 15 deletions

View File

@ -518,10 +518,10 @@ PropertyInfo VisualScriptBuiltinFunc::get_output_value_port_info(int p_idx) cons
t = Variant::REAL;
} break;
case MATH_ABS: {
t = Variant::NIL;
t = Variant::REAL;
} break;
case MATH_SIGN: {
t = Variant::NIL;
t = Variant::REAL;
} break;
case MATH_POW:
case MATH_LOG:
@ -547,7 +547,6 @@ PropertyInfo VisualScriptBuiltinFunc::get_output_value_port_info(int p_idx) cons
case MATH_MOVE_TOWARD:
case MATH_DECTIME: {
t = Variant::REAL;
} break;
case MATH_RANDOMIZE: {
} break;
@ -584,34 +583,29 @@ PropertyInfo VisualScriptBuiltinFunc::get_output_value_port_info(int p_idx) cons
case LOGIC_MAX:
case LOGIC_MIN:
case LOGIC_CLAMP: {
t = Variant::REAL;
} break;
case LOGIC_NEAREST_PO2: {
t = Variant::NIL;
t = Variant::INT;
} break;
case OBJ_WEAKREF: {
t = Variant::OBJECT;
} break;
case FUNC_FUNCREF: {
t = Variant::OBJECT;
} break;
case TYPE_CONVERT: {
} break;
case TEXT_ORD:
case TYPE_OF: {
t = Variant::INT;
} break;
case TYPE_EXISTS: {
t = Variant::BOOL;
} break;
case TEXT_CHAR:
case TEXT_STR: {
t = Variant::STRING;
} break;
case TEXT_PRINT: {
} break;
@ -630,7 +624,6 @@ PropertyInfo VisualScriptBuiltinFunc::get_output_value_port_info(int p_idx) cons
} else {
t = Variant::BOOL;
}
} break;
case BYTES_TO_VAR: {
if (p_idx == 1) {
@ -1218,10 +1211,6 @@ public:
VisualScriptBuiltinFunc::BuiltinFunc func;
//virtual int get_working_memory_size() const { return 0; }
//virtual bool is_output_port_unsequenced(int p_idx) const { return false; }
//virtual bool get_output_port_unsequenced(int p_idx,Variant* r_value,Variant* p_working_mem,String &r_error) const { return true; }
virtual int step(const Variant **p_inputs, Variant **p_outputs, StartMode p_start_mode, Variant *p_working_mem, Variant::CallError &r_error, String &r_error_str) {
VisualScriptBuiltinFunc::exec_func(func, p_inputs, p_outputs[0], r_error, r_error_str);
return 0;