DacWizard/src/main/java/jme3utilities/minie/wizard/Model.java
/**
     * Attempt to load a C-G model. The file-system path must have been
     * previously set. If successful, rootSpatial and linkedBones are
     * initialized. Otherwise, rootSpatial==null and loadException is set.
     */
Attempt to load a C-G model. The file-system path must have been
previously set. If successful, rootSpatial and linkedBones are
initialized. Otherwise, rootSpatial==null and loadException is set.
Attempt to load a C - G model . The file - system path must have been previously set . If successful rootSpatial and linkedBones are initialized . Otherwise rootSpatial == null and loadException is set .
void load() {
        int numComponents = filePathComponents.length;
        if (numComponents == 0) {
            throw new RuntimeException("File-system path not set.");
        }
        unload();
        String assetRoot = assetRoot();
        String assetPath = assetPath();
        Locators.save();
        Locators.unregisterAll();
        Locators.registerFilesystem(assetRoot);
        Locators.registerDefault();
        AssetManager assetManager = Locators.getAssetManager();
        assetManager.clearCache();
        try {
            rootSpatial = assetManager.loadModel(assetPath);
            loadException = null;
        } catch (Exception exception) {
            rootSpatial = null;
            loadException = exception;
        }
        Locators.restore();
        if (rootSpatial != null) {
            ragdoll = removeDac();
            recalculateInitTransform();
            recalculateInfluence();
            int numBones = countBones();
            BitSet bitset = new BitSet(numBones); 
            if (ragdoll != null) {
                for (int boneIndex = 0; boneIndex < numBones; ++boneIndex) {
                    String name = boneName(boneIndex);
                    if (ragdoll.hasBoneLink(name)) {
                        bitset.set(boneIndex);
                    }
                }
            }
            setLinkedBones(bitset);
        }
    }
void load ( ) { int numComponents = filePathComponents . length ; if ( numComponents == 0 ) { throw new RuntimeException ( "File-system path not set." ) ; } unload ( ) ; String assetRoot = assetRoot ( ) ; String assetPath = assetPath ( ) ; Locators . save ( ) ; Locators . unregisterAll ( ) ; Locators . registerFilesystem ( assetRoot ) ; Locators . registerDefault ( ) ; AssetManager assetManager = Locators . getAssetManager ( ) ; assetManager . clearCache ( ) ; try { rootSpatial = assetManager . loadModel ( assetPath ) ; loadException = null ; } catch ( Exception exception ) { rootSpatial = null ; loadException = exception ; } Locators . restore ( ) ; if ( rootSpatial != null ) { ragdoll = removeDac ( ) ; recalculateInitTransform ( ) ; recalculateInfluence ( ) ; int numBones = countBones ( ) ; BitSet bitset = new BitSet ( numBones ) ; if ( ragdoll != null ) { for ( int boneIndex = 0 ; boneIndex < numBones ; ++ boneIndex ) { String name = boneName ( boneIndex ) ; if ( ragdoll . hasBoneLink ( name ) ) { bitset . set ( boneIndex ) ; } } } setLinkedBones ( bitset ) ; } }
Attempt to load a C-G model.
Attempt to load a C - G model .
// empty set
