コード例 #1
0
        /// <summary>
        ///检查装备镶嵌的宝石数量
        /// </summary>
        /// <returns>The equip jewel count.</returns>
        /// <param name="item">Item.</param>
        int CheckEquipJewelCount(ItemFielInfo item)
        {
            int count = 0;

            if (item.GetIfBesetJewel(1))
            {
                count++;
            }
            if (item.GetIfBesetJewel(2))
            {
                count++;
            }
            return(count);
        }
コード例 #2
0
 void OnButtonPress(bool isPressed)
 {
     if (fielInfo.GetIfBesetJewel((int)_holeIndex))
     {
         buttonCallBack.spriteSwithList.ApplyAllItem(p => p.ChangeSprite(isPressed ? 4 : 3));
     }
     else
     {
         buttonCallBack.spriteSwithList.ApplyAllItem(p => p.ChangeSprite(isPressed ? 2 : 1));
     }
     buttonCallBack.BackgroundSwithList.ApplyAllItem(P => P.ChangeSprite(isPressed ? 2 : 1));
 }