Пример #1
0
 protected override void Awake()
 {
     base.Awake();
     base.effectColor     = new Color(0f, 0f, 0f, Alpha);
     base.effectDistance  = FixedDistance;
     base.useGraphicAlpha = false;
     base.enabled         = ConfigDevice.DeviceQuality() >= DeviceQualityType.High;
 }
Пример #2
0
 public void setVisible(bool visible)
 {
     if (!this.OverrideLowEndDeviceRestriction && (ConfigDevice.DeviceQuality() <= DeviceQualityType.Med))
     {
         this.SpriteRenderer.enabled = false;
     }
     else
     {
         this.SpriteRenderer.enabled = visible;
     }
 }
Пример #3
0
 public void initialize(TaskPanelItemType type, Content content)
 {
     this.ActiveContent = content;
     this.Type          = type;
     this.IconRectTransform.anchoredPosition = this.ActiveContent.IconOffset;
     RectTransformExtensions.SetSize(this.IconRectTransform, this.ActiveContent.IconSize);
     this.Sparkles.startColor = this.ActiveContent.SparklesColor;
     this.Sparkles.gameObject.SetActive(ConfigDevice.DeviceQuality() >= DeviceQualityType.Med);
     this.Glow.SetActive(ConfigDevice.DeviceQuality() >= DeviceQualityType.Med);
     this.refresh(null, null, 1, content.IconSprite);
 }
Пример #4
0
 public void setVisible(bool visible)
 {
     if (ConfigDevice.DeviceQuality() <= DeviceQualityType.Low)
     {
         this.SpriteRenderer.enabled = false;
         this.Billboard.enabled      = false;
     }
     else
     {
         this.SpriteRenderer.enabled = visible;
         this.Billboard.enabled      = visible;
     }
 }
Пример #5
0
 public void initializeRenderTexture()
 {
     this.releaseRenderTexture();
     if (ConfigDevice.DeviceQuality() <= DeviceQualityType.Low)
     {
         this.RenderTexture = new UnityEngine.RenderTexture(0x200, 0x200, 0x18, RenderTextureFormat.ARGB32);
     }
     else
     {
         this.RenderTexture = new UnityEngine.RenderTexture(0x500, 0x500, 0x18, RenderTextureFormat.ARGB32);
     }
     this.RenderTexture.filterMode = FilterMode.Bilinear;
     this.Camera.targetTexture     = this.RenderTexture;
 }
Пример #6
0
        public void cleanUpForReuse()
        {
            bool flag = false;

            if (this.BannerImage.texture != null)
            {
                UnityEngine.Object.DestroyImmediate(this.BannerImage.texture);
                this.BannerImage.texture = null;
                flag = true;
            }
            if ((ConfigDevice.DeviceQuality() <= DeviceQualityType.Low) && flag)
            {
                Resources.UnloadUnusedAssets();
            }
        }
        protected override void onCleanup()
        {
            bool flag = false;

            if (this.m_inputParameters.DisposableBackgroundTexture != null)
            {
                UnityEngine.Object.Destroy(this.m_inputParameters.DisposableBackgroundTexture);
                this.m_inputParameters.DisposableBackgroundTexture = null;
                this.RawBg.texture = null;
                flag = true;
            }
            if ((ConfigDevice.DeviceQuality() <= DeviceQualityType.Low) && flag)
            {
                Resources.UnloadUnusedAssets();
            }
        }