static public GameObject loadNIFFromFile(string nifFile, string kfm, string kfb) { GameObject nifmodel = NIFLoader.loadNIFFromFile(nifFile, true); AnimatedNif nif = nifmodel.AddComponent <AnimatedNif>(); nif.setParams(AssetDatabaseInst.DB, nifFile, kfm, kfb); nif.setSkeletonRoot(nifmodel); return(nifmodel); }
static public GameObject loadNIF(long key) { Model model = load7305(AssetDatabaseInst.DB, key); GameObject nifmodel = NIFLoader.loadNIF(model.nifFile, true); AnimatedNif nif = nifmodel.AddComponent <AnimatedNif>(); nif.setParams(AssetDatabaseInst.DB, model.nifFile, model.kfmFile, model.kfbFile); nif.setSkeletonRoot(nifmodel); return(nifmodel); }