コード例 #1
0
        /// <inheritdoc />
        public ReturnCode Run()
        {
            m_CustomAssets = new CustomAssets();
            m_GlobalUsage  = m_DependencyData.GlobalUsage;
            foreach (SceneDependencyInfo sceneInfo in m_DependencyData.SceneInfo.Values)
            {
                m_GlobalUsage |= sceneInfo.globalUsage;
            }

            foreach (CustomContent info in m_Content.CustomAssets)
            {
                if (!m_Tracker.UpdateInfoUnchecked(info.Asset.ToString()))
                {
                    return(ReturnCode.Canceled);
                }

                using (m_Log.ScopedStep(LogLevel.Verbose, "CustomAssetDependency", info.Asset.ToString()))
                    info.Processor(info.Asset, this);
            }

            // Add all the additional global usage for custom assets back into the dependency data result
            // for use in the write serialized file build task
            m_DependencyData.GlobalUsage |= m_CustomUsage;
            return(ReturnCode.Success);
        }
コード例 #2
0
        /// <inheritdoc />
        public ReturnCode Run()
        {
            m_CustomAssets = new CustomAssets();
            m_GlobalUsage  = m_DependencyData.GlobalUsage;
            foreach (SceneDependencyInfo sceneInfo in m_DependencyData.SceneInfo.Values)
            {
                m_GlobalUsage |= sceneInfo.globalUsage;
            }

            foreach (CustomContent info in m_Content.CustomAssets)
            {
                if (!m_Tracker.UpdateInfoUnchecked(info.Asset.ToString()))
                {
                    return(ReturnCode.Canceled);
                }

                info.Processor(info.Asset, this);
            }
            return(ReturnCode.Success);
        }