public void ShowBusy(bool b) { if (b) { Readypanel.BackColor = Color.Red; ReadyLabel.Text = "Busy"; } else { Readypanel.BackColor = Color.Lime; ReadyLabel.Text = "Ready"; } Readypanel.Refresh(); ReadyLabel.Refresh(); }
void Activate() { panel.Click += new MouseEventHandler(panel_Click); if (Weapon == null) { UnlockLabel.Hide(); WeaponButton.Hide(); ReadyLabel.Show(); colorTween.Play(); } else { UnlockLabel.Hide(); WeaponButton.Show(); ReadyLabel.Hide(); } }
void Deactivate() { int lvl = 2; switch (WeaponType) { case WeaponType.Melee: lvl = 2; break; case WeaponType.Ranged: lvl = 3; break; case WeaponType.Mortar: lvl = 4; break; } UnlockLabel.Text = "Unlock in level " + lvl; UnlockLabel.Show(); WeaponButton.Hide(); ReadyLabel.Hide(); }