CampfireParty.Building_Pyre.Tick C# (CSharp) Method

Tick() public method

public Tick ( ) : void
return void
        public override void Tick()
        {
            base.Tick();
            if (this.campfirePartyIsStarted)
            {
                this.lifeTickCounter++;
                if (this.lifeTickCounter >= maxLifeTickCounter)
                {
                    this.Destroy(DestroyMode.Vanish);
                }
                // Update fires textures.
                for (int fireIndex = 0; fireIndex < fireMaxNumber; fireIndex++)
                {
                    if (this.lifeTickCounter >= fireIndex * (maxLifeTickCounter / fireMaxNumber))
                    {
                        this.fireTickCounter[fireIndex]--;
                        if (this.fireTickCounter[fireIndex] <= 0)
                        {
                            this.fireTickCounter[fireIndex] = Rand.Range(5, 15);
                            ChangeFireTexture(ref this.fireTexture[fireIndex]);
                        }

                    }
                }
            }
        }