| | 1 | | using System; |
| | 2 | | using UnityEngine; |
| | 3 | |
|
| | 4 | | public class FriendsHandler : IFriendTrackerHandler |
| | 5 | | { |
| | 6 | | public event Action<UserProfile, Color> OnFriendAddedEvent; |
| | 7 | | public event Action<UserProfile> OnFriendRemovedEvent; |
| | 8 | |
|
| | 9 | | private readonly IMapDataView mapInfoHandler; |
| | 10 | |
|
| 0 | 11 | | public FriendsHandler(IMapDataView mapInfoHandler) { this.mapInfoHandler = mapInfoHandler; } |
| | 12 | |
|
| 0 | 13 | | public void OnFriendAdded(UserProfile profile, Color backgroundColor) { OnFriendAddedEvent?.Invoke(profile, backgrou |
| | 14 | |
|
| 0 | 15 | | public void OnFriendRemoved(UserProfile profile) { OnFriendRemovedEvent?.Invoke(profile); } |
| | 16 | |
|
| 0 | 17 | | public bool ContainCoords(Vector2Int coords) { return mapInfoHandler.ContainCoords(coords); } |
| | 18 | | } |