Ejemplo n.º 1
0
        private IEnumerator Init()
        {
            yield return(0);

            ModelEffectManager.Init();  //模型管理初始化处理
            yield return(0);

            HOTween.Init(true, true, true); //初始化hotween;
            yield return(0);

            gameObject.AddComponent <FPS>();//增加FPS显示
        }
Ejemplo n.º 2
0
                    public static ModelEffectManager FromBaseObject(BaseObject baseObj)
                    {
                        if (baseObj == null || baseObj.NativeObject == IntPtr.Zero)
                        {
                            return(null);
                        }
                        ModelEffectManager obj = baseObj as  ModelEffectManager;

                        if (object.Equals(obj, null))
                        {
                            obj = new ModelEffectManager(CreatedWhenConstruct.CWC_NotToCreate);
                            obj.BindNativeObject(baseObj.NativeObject, "CModelEffectManager");
                            obj.IncreaseCast();
                        }

                        return(obj);
                    }
Ejemplo n.º 3
0
 public IEnumerator ShowWarningEffect()
 {
     while (Time.time - _warnStartTime < _timeLength)
     {
         var curColor = new Color
         {
             a = Random.Range(_warnStartColor.a, _warnEndColor.a),
             b = Random.Range(_warnStartColor.b, _warnEndColor.b),
             r = Random.Range(_warnStartColor.r, _warnEndColor.r),
             g = Random.Range(_warnStartColor.g, _warnEndColor.g)
         };
         if (GoCloth == null)
         {
             break;
         }
         ModelEffectManager.ShowSpriteColorEffect(GoCloth, curColor);
         yield return(0);
     }
     ModelEffectManager.RemoveSpriteColorEffect(GoCloth);
     yield return(0);
 }
Ejemplo n.º 4
0
 private IEnumerator ShowModelColorEffect()
 {
     while (Time.time - _startTime < 0.6f)
     {
         var curColor = new Color
         {
             a = Random.Range(_startColor.a, _endColor.a),
             b = Random.Range(_startColor.b, _endColor.b),
             r = Random.Range(_startColor.r, _endColor.r),
             g = Random.Range(_startColor.g, _endColor.g)
         };
         if (GoCloth == null)
         {
             break;
         }
         ModelEffectManager.ShowSpriteColorEffect(GoCloth, curColor);
         yield return(0);
     }
     ModelEffectManager.RemoveSpriteColorEffect(GoCloth);
     yield return(0);
 }
Ejemplo n.º 5
0
        private IEnumerator ShowModelBeAttackedEffect()
        {
            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep1Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep1Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep2Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep2Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.RedEnd);
            while (_keepFrame < 8)
            {
                _keepFrame++;
                yield return(0);
            }
            yield return(0);

            _keepFrame = 0;
            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep2Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep2Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep1Color);
            yield return(0);

            ModelEffectManager.ShowSpriteColorEffect(GoCloth, ColorConst.BeAttackStep1Color);
            yield return(0);

            ModelEffectManager.RemoveSpriteColorEffect(GoCloth);
            yield return(0);
        }
Ejemplo n.º 6
0
 private void UpdateBornEffect()
 {
     _modelAlpha += 0.3f;
     ModelEffectManager.ChangeAlpha(GoCloth, _modelAlpha);
 }
Ejemplo n.º 7
0
 public void RemoveWhiteColor()
 {
     ModelEffectManager.RemovePuleColor(GoCloth);
 }
Ejemplo n.º 8
0
 public void ShowWhiteColor()
 {
     ModelEffectManager.ShowPuleColor(GoCloth);
 }
Ejemplo n.º 9
0
 public void EndModelColorEffect()
 {
     ModelEffectManager.RemoveSpriteColorEffect(GoCloth);
 }
Ejemplo n.º 10
0
                    public BaseObject Create()
                    {
                        ModelEffectManager emptyInstance = new ModelEffectManager(CreatedWhenConstruct.CWC_NotToCreate);

                        return(emptyInstance);
                    }