void Give(Good good, int num)
 {
     if (storePattern == StorePattern.resource)
     {
         if (resourceManagerScript.TrySetGameElementEnable(good.item.name, true))
         {
             if (resourceManagerScript.TryChangeGameElementValue(good.item.name, num * good.item.value))
             {
                 resourceManagerScript.Notify();
                 Toast.Pop("你买了" + good.item.name + " * " + num * good.item.value);
             }
         }
         else
         {
             resourceManagerScript.TrySetGameElementEnable(good.item.name, false);
         }
     }
     else if (storePattern == StorePattern.build)
     {
         if (good.item is Shelter)
         {
             if (HRManagerScript.TryAddMaxHRNum((good.item as Shelter).capacity * num))
             {
                 HRManagerScript.Notify();
                 Toast.Pop("你买了" + good.item.name + " * " + num);
                 GameEventPublisher.Publish(((Building)good.item).activatingBuildingInfo);
             }
         }
         if (good.item is ProductionBuilding)
         {
             ProductionBuilding building = good.item as ProductionBuilding;
             if (HRManagerScript.TrySetGameElementEnable(building.staffName, true))
             {
                 HRManagerScript.Notify();
                 Toast.Pop("你买了" + good.item.name + " * " + num);
                 GameEventPublisher.Publish(((Building)good.item).activatingBuildingInfo);
             }
         }
     }
     else if (storePattern == StorePattern.battle)
     {
         if (good.item is BattleUnit)
         {
             if (battleUnitManagerScript.TryChangeMilitaryCamp(good.item.name, num))
             {
                 battleUnitManagerScript.Notify();
                 Toast.Pop("你买了" + good.item.name + " * " + num);
             }
         }
     }
 }
 void HarvestInfo()
 {
     harvestInfoStringBuilder.Remove(0, harvestInfoStringBuilder.Length);
     foreach (string key in harvestDictKeyList)
     {
         int value = 0;
         harvestDict.TryGetValue(key, out value);
         if (value != 0)
         {
             harvestInfoStringBuilder.Append(key).Append(" ");
             harvestInfoStringBuilder.Append(value.ToString("+#;-#;0"));
             harvestInfoStringBuilder.Append(" ");
         }
     }
     if (harvestInfoStringBuilder.Length > 1)
     {
         harvestInfoStringBuilder.Remove(harvestInfoStringBuilder.Length - 1, 1);
         string info = harvestInfoStringBuilder.ToString();
         Toast.Pop(info);
         GameEventPublisher.Publish(info);
     }
 }