Loading a prefab from script

public static string playerPrefab = "/GameStuff/Prefabs/PlayerPrefab";

Object pl = Network.Instantiate(Resources.Load(playerPrefab),
            new Vector3(0, 0, 0), Quaternion.identity, 0);

The only error I am getting is NullReferenceException, I figure this means that Resources.Load is unable to find my prefab, which is located in \Assets\Resources\GameStuff\Prefabs\PlayerPrefab.prefab. I've tried with \ instead of / etc.

Did you try putting .prefab on the file name? "/GameStuff/Prefabs/PlayerPrefab.prefab";

Try removing the leading slash in your path. "GameStuff/Prefabs/PlayerPrefab". You should not need to add the .prefab to PlayerPrefab.

if you want to load a prefab from script the complete code is given below

Object myPrefab ;

myPrefab =Resource.Load(“coin”);
//load the prefab .here coin is my prefab name and it is located at resources folder

//if you want to create the instance then
instantiate(myPrefab);