Pulse Works Studio
Parse Error: Preload file "res://player.tscn" does not exist.
preload() requires a real file at that res:// path when the script is parsed.
Cause
The analyzer resolves a constant preload path immediately. If ResourceLoader cannot see the file, you get this error rather than a null at runtime. A renamed, unsaved, or wrong-case path fails the same way. Use load() only when the path is chosen at runtime.
Fix
const PLAYER := preload("res://actors/player.tscn")
func spawn_player(parent: Node) -> Node:
var node := PLAYER.instantiate()
parent.add_child(node)
return node
Related
Godot Dev Tools is a Pulse Works Studio project. All error explainers.