How do set a default reference for a script?

I have the following line of code:

public var showCanvas_ : ShowCanvas;
// Behaviour for fixtures

When inspecting the script within the Project folders, I notice in the Inspector the setting to set a default reference. How do I go about doing that? Whatever I insert there just got reset to none. (There is a game-object with the ShowCanavs script attached to it).

alt text

You can't attach a script to the default references.

If you try to drag in one from the scene, it won't be available when the scene changes so that's disallowed.

If you try to drag one in from the project, it's actually a MonoScript at that point and also won't work.

If you're trying to add some sort of behaviour for runtime, you could try using ScripableObject, which would work as a draggable asset.