Exemplo n.º 1
0
        private void onSaveLoaded(object _sender, SaveLoadedEventArgs _e)
        {
            // Load the current color set for the player.
            colorData.loadForPlayer();

            // Discover the IDs of the Prismatic Boots.
            if (jsonAssets != null)
            {
                bootsSheetIndex = jsonAssets.GetObjectId("Prismatic Boots");
                if (bootsSheetIndex != -1)
                {
                    bootsColorIndex = new Boots(bootsSheetIndex).indexInColorSheet.Value;
                }
            }
        }
Exemplo n.º 2
0
 /// <summary>Checks if an item is a lotion type added by this mod.</summary>
 /// <param name="item">The Item (or SDV Object) to check</param>
 /// <returns>true if lotion, false otherwise</returns>
 public bool IsLotion(Item item)
 {
     if (item is StardewValley.Object &&
         !(item as StardewValley.Object).bigCraftable.Value &&
         !(item is Wallpaper) &&
         !(item is Furniture))
     {
         LotionIDs = new int[] {
             JA.GetObjectId(SUNSCREEN_ITEM_NAME),
             JA.GetObjectId(ALOE_GEL_ITEM_NAME)
         };
         if (LotionIDs.Contains(item.ParentSheetIndex))
         {
             return(true);
         }
     }
     return(false);
 }