HoldItCore.Stall.Alert C# (CSharp) Method

Alert() public method

public Alert ( int incrementValue, string reason ) : void
incrementValue int
reason string
return void
        public void Alert(int incrementValue, string reason)
        {
            ScoreAlert alert = new ScoreAlert();
            this.alertPanel.Children.Add(alert);

            alert.Alert = incrementValue;
            alert.Description = reason;
        }

Usage Example

示例#1
0
文件: Level.cs 项目: ibdknox/swred
 public void ScoreStallChoice(Stall stall)
 {
     int neighbors = this.GetNeighborCount(stall);
     if (neighbors > 0)
     {
         this.AdjustScore(neighbors * (-15));
         stall.Alert(neighbors * (-15), "Pee foul!");
     }
 }