- Home /
How to design a static prefab class.
Heys,
I wanted to created a static prefab class, as prefab reference for all of my scripts, like:
static class Prefab
{
public static Transform prefab1;
public static Transform prefab2;
...
public static Transform getPrefab(string name)
{
...
return prefab;
}
}
but there is no way to link a Transform/Rigidbody to a static class member, so how to do it?
(Oh and please do not come with Singeltons, thats no solution)
Cheers
Comment
Your answer
