示例#1
0
        public void SetSilver(int count)
        {
            int oldCount = silver;

            silver = count;
            if (oldCount != silver)
            {
                RavenhillEvents.OnPlayerSilverChanged(oldCount, silver);
            }
        }
示例#2
0
        private void AddSilverImpl(int count)
        {
            int oldCount = silver;

            silver += count;
            if (oldCount != silver)
            {
                RavenhillEvents.OnPlayerSilverChanged(oldCount, silver);
            }
        }
示例#3
0
 public void RemoveSilver(int count)
 {
     if (silver >= count)
     {
         int oldSilver = silver;
         silver -= count;
         if (oldSilver != silver)
         {
             RavenhillEvents.OnPlayerSilverChanged(oldSilver, silver);
         }
     }
 }