|
@@ -488,24 +488,24 @@ namespace GFGGame
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- private void CheckRemoveSameType(int type)
|
|
|
+ private void CheckRemoveSameType(int subType)
|
|
|
{
|
|
|
int count = 0;
|
|
|
int firstTeshuId = 0;
|
|
|
for (int i = 0; i < _dressUpData.itemList.Count; i++)
|
|
|
{
|
|
|
int itemID = (int)_dressUpData.itemList[i];
|
|
|
- int subType = ItemUtilCS.GetItemSubType(itemID);
|
|
|
- if (subType == type
|
|
|
- || (type == ConstDressUpItemType.LIAN_YI_QUN && (subType == ConstDressUpItemType.SHANG_YI || subType == ConstDressUpItemType.XIA_ZHUANG || subType == ConstDressUpItemType.NEI_DA))
|
|
|
- || (type == ConstDressUpItemType.SHANG_YI && subType == ConstDressUpItemType.LIAN_YI_QUN)
|
|
|
- || (type == ConstDressUpItemType.XIA_ZHUANG && subType == ConstDressUpItemType.LIAN_YI_QUN)
|
|
|
- || (type == ConstDressUpItemType.NEI_DA && subType == ConstDressUpItemType.LIAN_YI_QUN))
|
|
|
+ int itemSubType = ItemUtilCS.GetItemSubType(itemID);
|
|
|
+ if (itemSubType == subType
|
|
|
+ || (subType == ConstDressUpItemType.LIAN_YI_QUN && (itemSubType == ConstDressUpItemType.SHANG_YI || itemSubType == ConstDressUpItemType.XIA_ZHUANG || itemSubType == ConstDressUpItemType.NEI_DA))
|
|
|
+ || (subType == ConstDressUpItemType.SHANG_YI && itemSubType == ConstDressUpItemType.LIAN_YI_QUN)
|
|
|
+ || (subType == ConstDressUpItemType.XIA_ZHUANG && itemSubType == ConstDressUpItemType.LIAN_YI_QUN)
|
|
|
+ || (subType == ConstDressUpItemType.NEI_DA && itemSubType == ConstDressUpItemType.LIAN_YI_QUN))
|
|
|
{
|
|
|
Remove(itemID);
|
|
|
i--;
|
|
|
}
|
|
|
- if (subType > ConstDressUpItemType.TE_SHU)
|
|
|
+ if (itemSubType > ConstDressUpItemType.TE_SHU)
|
|
|
{
|
|
|
if (count == 0)
|
|
|
{
|
|
@@ -514,7 +514,7 @@ namespace GFGGame
|
|
|
count++;
|
|
|
}
|
|
|
}
|
|
|
- if (type > ConstDressUpItemType.TE_SHU && count >= 3)
|
|
|
+ if (subType > ConstDressUpItemType.TE_SHU && count >= 3)
|
|
|
{
|
|
|
//特殊饰品最多穿三件,第四件会自动顶掉第一件
|
|
|
Remove(firstTeshuId);
|