Beispiel #1
0
        // Token: 0x060038AD RID: 14509 RVA: 0x00102674 File Offset: 0x00100874
        public override void Draw()
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_Draw_hotfix != null)
            {
                this.m_Draw_hotfix.call(new object[]
                {
                    this
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            Colori color = this.m_team.GetColor();

            if (this.m_configDataFlyObjectInfo.TrackType == TrackType.TrackType_Parabolic)
            {
                Vector2i p;
                Fix64    z;
                this.ComputeParabolicPosition((Fix64)((long)(this.m_life - 1)), out p, out z);
                Vector2i p2;
                Fix64    z2;
                this.ComputeParabolicPosition((Fix64)((long)this.m_life), out p2, out z2);
                this.Combat.Listener.DrawLine(p, z, p2, z2, color);
            }
            else
            {
                Fix64    t  = (Fix64)((long)(this.m_life - 1)) / (Fix64)((long)this.m_lifeMax);
                Fix64    t2 = (Fix64)((long)this.m_life) / (Fix64)((long)this.m_lifeMax);
                Vector2i p3 = Vector2i.Lerp(this.m_startPosition, this.m_endPosition, t);
                Vector2i p4 = Vector2i.Lerp(this.m_startPosition, this.m_endPosition, t2);
                Fix64    z3 = MathUtility.Lerp((Fix64)((long)this.m_startZ), (Fix64)((long)this.m_endZ), t);
                Fix64    z4 = MathUtility.Lerp((Fix64)((long)this.m_startZ), (Fix64)((long)this.m_endZ), t2);
                this.Combat.Listener.DrawLine(p3, z3, p4, z4, color);
            }
        }
Beispiel #2
0
        public Gatto(Colori colore)
        {
            ((IGatto)this).Colore = colore;
              if (colore == Colori.Nero)
            this.AmanoLAcqua = true;

              switch (colore)
              {
            case Colori.Nero:
              this.AmanoLAcqua = true; break;
            default: this.AmanoLAcqua = false; break;
              }

              switch (colore)
              {
            case Colori.Nero:
            case Colori.Bianco:
              this.AmanoLAcqua = true;
              break;

            case Colori.Giallo:
            case Colori.Tigrato:
            default:
              this.AmanoLAcqua = false;
              break;
              }
        }
Beispiel #3
0
        // Token: 0x060097F7 RID: 38903 RVA: 0x002B6340 File Offset: 0x002B4540
        public void TickGraphic(float dt)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_TickGraphicSingle_hotfix != null)
            {
                this.m_TickGraphicSingle_hotfix.call(new object[]
                {
                    this,
                    dt
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            Vector2 a    = this.m_battle.GridPositionToWorldPosition(this.m_position);
            int     num  = this.m_battle.ArenaBattleInfo.m_battlefieldInfo.Width / 2;
            int     num2 = this.m_direction;

            if (num2 == 0)
            {
                num2 = ((this.m_position.x > num) ? -1 : 1);
            }
            for (int i = 0; i < this.m_graphics.Length; i++)
            {
                if (this.m_graphics[i] != null)
                {
                    this.m_graphics[i].SetPosition(this.ComputeGraphicPosition(a + this.GetGraphicOffset(i, num2)));
                    this.m_graphics[i].SetDirection(num2);
                }
            }
            if (this.m_tweenColorTime > 0f)
            {
                this.m_tweenColorTime -= dt;
                if (this.m_tweenColorTime < 0f)
                {
                    this.m_tweenColorTime = 0f;
                }
                Colori color = Colori.Lerp(this.m_tweenToColor, this.m_tweenFromColor, this.m_tweenColorTime / 0.1f);
                foreach (GenericGraphic genericGraphic in this.m_graphics)
                {
                    if (genericGraphic != null)
                    {
                        genericGraphic.SetColor(color);
                    }
                }
            }
            foreach (GenericGraphic genericGraphic2 in this.m_graphics)
            {
                if (genericGraphic2 != null)
                {
                    genericGraphic2.Tick(dt);
                }
            }
        }
Beispiel #4
0
 // Token: 0x060097F6 RID: 38902 RVA: 0x002B62B0 File Offset: 0x002B44B0
 public void TweenColor(Colori c)
 {
     if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_TweenColorColori_hotfix != null)
     {
         this.m_TweenColorColori_hotfix.call(new object[]
         {
             this,
             c
         });
         return;
     }
     BJLuaObjHelper.IsSkipLuaHotfix = false;
     this.m_tweenFromColor          = this.m_tweenToColor;
     this.m_tweenToColor            = c;
     this.m_tweenColorTime          = 0.1f;
 }
        // Token: 0x06008C71 RID: 35953 RVA: 0x0028FEC4 File Offset: 0x0028E0C4
        public void SetStatus(WayPointStatus status)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_SetStatusWayPointStatus_hotfix != null)
            {
                this.m_SetStatusWayPointStatus_hotfix.call(new object[]
                {
                    this,
                    status
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            this.m_status = status;
            Colori color;

            if (status == WayPointStatus.Close || status == WayPointStatus.Open)
            {
                color = new Colori(150, 150, 150, byte.MaxValue);
            }
            else
            {
                color = new Colori(byte.MaxValue, byte.MaxValue, byte.MaxValue, byte.MaxValue);
            }
            bool flag = status != WayPointStatus.Close;

            if (this.m_graphic != null)
            {
                this.m_graphic.SetVisible(flag);
                this.m_graphic.SetColor(color);
            }
            if (this.m_uiController != null)
            {
                this.m_uiController.gameObject.SetActive(flag);
                this.m_uiController.SetStatus(status);
            }
        }