You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Modification class has some functions related to loading resources from the outside.
ModItem.LoadSprite(stringPath,intPixelsPerUnit=10,FilterModefilterMode=FilterMode.Point);// Used for loading spriteModItem.LoadTexture(stringPath,FilterModefilterMode=FilterMode.Point);// Used for loading textureModItem.LoadSound(stringpath);//Used for loading sound (AudioClip)// Note that arguments with '=' sign can be omitted.
Instantiating
Actually, this is not really instantiating, for real instantiating you still need this:
Instantiate(someObject)
but, you can create object inside your code by using this:
physObject=ModItem.CreatePhysicalObject(stringname,Spritesprite);// And this will return gameObject, which you can use in your purposes