备份CatanBuilding瘦身独立工程
This commit is contained in:
40
Assets/Scripts/UI/Social/Friend/FriendAddItemData.cs
Normal file
40
Assets/Scripts/UI/Social/Friend/FriendAddItemData.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
namespace game
|
||||
{
|
||||
public class FriendAddItemData
|
||||
{
|
||||
public int Type = 0;
|
||||
public BFriendInfo FriendInfo = null;
|
||||
public int Extra = 0;
|
||||
|
||||
public bool EqualsPlayFabId(FriendAddItemData data)
|
||||
{
|
||||
if (this.FriendInfo == data.FriendInfo) return true;
|
||||
if (this.FriendInfo != null && data.FriendInfo != null && this.FriendInfo.PlayFabId == data.FriendInfo.PlayFabId)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public bool Equals(FriendAddItemData data)
|
||||
{
|
||||
if (this.Type != data.Type || this.Extra != data.Extra) return false;
|
||||
if (this.FriendInfo == data.FriendInfo) return true;
|
||||
if (this.FriendInfo != null && data.FriendInfo != null)
|
||||
{
|
||||
if (this.FriendInfo.Level == data.FriendInfo.Level && this.FriendInfo.AvatarUrl == data.FriendInfo.AvatarUrl
|
||||
&& this.FriendInfo.DisplayName == data.FriendInfo.DisplayName && this.FriendInfo.PlayFabId == data.FriendInfo.PlayFabId)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user