|
@@ -3,6 +3,7 @@ using UnityEngine;
|
|
using System;
|
|
using System;
|
|
using System.Linq;
|
|
using System.Linq;
|
|
using ET;
|
|
using ET;
|
|
|
|
+using static UnityEditor.Progress;
|
|
|
|
|
|
namespace GFGGame
|
|
namespace GFGGame
|
|
{
|
|
{
|
|
@@ -432,12 +433,31 @@ namespace GFGGame
|
|
PutOnDressUpData(DressUpData.CreateDefault());
|
|
PutOnDressUpData(DressUpData.CreateDefault());
|
|
}
|
|
}
|
|
|
|
|
|
- //穿戴一组散件数据(会先脱掉原来的再穿)
|
|
|
|
- public void PutOnItemList(List<int> itemList)
|
|
|
|
|
|
+ //穿戴一组散件数据(会脱掉不包含的部分)
|
|
|
|
+ public void PutOnItemList(List<int> targetItemList)
|
|
{
|
|
{
|
|
- TakeOffAll(false);
|
|
|
|
|
|
+ bool oldIsAction = IsAction;
|
|
|
|
+ _dressUpData.suitId = 0;
|
|
|
|
+ _dressUpData.actionId = 0;
|
|
foreach (int itemID in itemList)
|
|
foreach (int itemID in itemList)
|
|
{
|
|
{
|
|
|
|
+ if(!targetItemList.Contains(itemID))
|
|
|
|
+ {
|
|
|
|
+ //移除不穿的部件
|
|
|
|
+ AddOrRemove(itemID, false, DressUpOption.Remove);
|
|
|
|
+ }
|
|
|
|
+ else if(oldIsAction)
|
|
|
|
+ {
|
|
|
|
+ //当从动画形态切换时
|
|
|
|
+ if (!DressUpMenuItemCfg1Array.Instance.CheckIsSceneType(itemID))
|
|
|
|
+ {
|
|
|
|
+ //对非场景类型移除,重穿
|
|
|
|
+ AddOrRemove(itemID, false, DressUpOption.Remove);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ foreach (int itemID in targetItemList)
|
|
|
|
+ {
|
|
AddOrRemove(itemID, false, DressUpOption.Add);
|
|
AddOrRemove(itemID, false, DressUpOption.Add);
|
|
}
|
|
}
|
|
checkDefaultItem();
|
|
checkDefaultItem();
|