Ejemplo n.º 1
0
        //---------------------------------------------------------------------------

        public T Find <T>(ELightAssets asset)
        {
            if (m_LightAssets.ContainsKey(typeof(T)))
            {
                if (m_LightAssets[typeof(T)].ContainsKey(asset))
                {
                    return((T)m_LightAssets[typeof(T)][asset]);
                }
            }
            return(default(T));
        }
Ejemplo n.º 2
0
        //---------------------------------------------------------------------------

        public void Store <T>(ELightAssets type, string path)
        {
            T asset = Content.Load <T>(path);

            if (!m_LightAssets.ContainsKey(typeof(T)))
            {
                m_LightAssets.Add(typeof(T), new Dictionary <ELightAssets, dynamic>());
            }
            if (!m_LightAssets[typeof(T)].ContainsKey(type))
            {
                m_LightAssets[typeof(T)].Add(type, asset);
            }
        }