public void ChangeData(PacketStructUnit unitData, GlobalDefine.PartyCharaIndex partyCharaIndex, PacketStructUnit[] partyUnits) { PartyMemberStatusListItemContext selectUnitStatus = UnitStatusParams.Find(value => value.PartyCharaIndex == partyCharaIndex); SetUnitData(ref selectUnitStatus, unitData, partyUnits); UpdateOtherMemberStatus(partyCharaIndex, partyUnits); SetStatusParam(); }
private void UpdateOtherMemberStatus(GlobalDefine.PartyCharaIndex changeCharaIndex, PacketStructUnit[] partyUnits) { for (var i = (int)GlobalDefine.PartyCharaIndex.LEADER; i < partyUnits.Length; i++) { var charaIndex = (GlobalDefine.PartyCharaIndex)i; if (changeCharaIndex == charaIndex) { continue; } var selectUnitStatus = UnitStatusParams.Find(value => value.PartyCharaIndex == charaIndex); SetUnitData(ref selectUnitStatus, partyUnits[i], partyUnits); } }