Exemplo n.º 1
0
    /// <summary>
    /// Saves the panel children.
    /// </summary>
    public void SaveSceneNodes()
    {
        m_NodeDataList.Clear();
        switch (saveMethod)
        {
        case SaveMethods.COLLECT_VINO_SCENE_NODES:
/*			ViNoSceneNodeFactory vsfact = spriteFactory as ViNoSceneNodeFactory;
 *                      if( vsfact != null ){
 *                              ViNoSceneSaveUtil.SaveViNoSceneNodes( ref m_NodeDataList ,  spriteFactory );
 *                      }
 *                      break;
 * //*/
        case SaveMethods.TRAVERSE_CHILDREN:
            if (theSavedPanel != null)
            {
                ViNoSceneSaveUtil.SavePanelChildren(theSavedPanel, ref m_NodeDataList, ref spriteFactory);
            }
            else
            {
                Debug.LogError("theSavedPanel not set");
            }
            break;
        }

        // For Saving as Xml...
        m_SceneData.m_DataArray = m_NodeDataList.ToArray();

        m_NodeDataList.Clear();
    }
Exemplo n.º 2
0
    /// <summary>
    /// LOAs the d_ SCEN e_ XM.
    /// </summary>
    /// <param name='vm'>
    /// Vm.
    /// </param>
    public override void LOAD_SCENE_XML(VirtualMachine vm)
    {
        if (ViNoSceneManager.Instance != null)
        {
            // DestroyImmidiate Under the SavedLayer .
            ViNoSceneManager.Instance.DestroyObjectsUnderSavedLayer( );

            // Load XML.
            ViNoSceneSaveUtil.LoadSceneXMLFromTextAssetPath(VirtualMachine.loadedTextLiteralString);
        }
    }