### Godot version

d01ac9c73

### System information

ArchLinux x11

### Issue description

Signal with unbinds[^1] fails to emit in exported project.

[^1]: ![image](https://user-images.githubusercontent.com/70787919/215381688-1df57b26-2ed5-4473-a9dd-54d9c2228567.png)


### Steps to reproduce

- open mrp
- run in editor
- `it worked!` is printed
- export project
- run executable
-  
```c++
ERROR: Error calling from signal 'sig' to callable: 'Node::_on_sig': Method expected 0 arguments, but called with 1.
   at: emit_signalp (core/object/object.cpp:1058)
```

### Minimal reproduction project

[bug.zip](https://github.com/godotengine/godot/files/10531944/bug.zip)

if (n.instance >= 0) {
										Ref<Resource> node_res = node->get(snames[nprops[j].name]);
										if (node_res.is_valid()) {
											node_res->copy_from(res);
											node_res->configure_for_local_scene(node, resources_local_to_scene);
											value = node_res;
										}
									} else {
										HashMap<Ref<Resource>, Ref<Resource>>::Iterator E = resources_local_to_scene.find(res);
										Node *base = i == 0 ? node : ret_nodes[0];
										if (E) {
											value = E->value;
										} else {
											if (p_edit_state == GEN_EDIT_STATE_MAIN) {
												
												res->configure_for_local_scene(base, resources_local_to_scene);
												resources_local_to_scene[res] = res;
											} else {
												
												Ref<Resource> local_dupe = res->duplicate_for_local_scene(base, resources_local_to_scene);
												resources_local_to_scene[res] = local_dupe;
												value = local_dupe;
											}
										}
									}
									
								}
							}
						}