using System.Collections.Generic;
using XGame.Database;
using XGame.Framework.Data;

namespace FL.Data
{
    public class PlayerService : DataSingleton<PlayerService>
    {
        public void ExchangePartners()
        {
            var all = PartnerTableRepo.GetAll();
            var activePartnerIds = PlayerData.Instance.activePartnerIds;
            var addPartners = new List<int>();
            foreach(var table in all)
            {
                if (activePartnerIds.Contains(table.Id))
                {
                    continue;
                }
                addPartners.Add(table.Id);
            }
            EventSingle.Instance.Notify(EventDefine.GameMainMapExchangePartner, addPartners);
            

        }
    }
}
