zxl
/
CTT
forked from Cal/CTT
1
0
Fork 0
CTT/Server/Hotfix/Game/Handler/UI/Friend/C2M_HandleAddFriendHandler.cs

21 lines
671 B
C#
Raw Normal View History

2021-04-08 20:09:59 +08:00
using System;
namespace ET
{
[ActorMessageHandler]
public class C2M_HandleAddFriendHandler : AMActorLocationRpcHandler<Unit, C2M_HandleAddFriend, M2C_HandleAddFriend>
{
protected override async ETTask Run(Unit unit, C2M_HandleAddFriend request, M2C_HandleAddFriend response, Action reply)
{
2021-04-11 19:50:39 +08:00
string ret = await FriendComponent.Instance.HandleAddFriend(unit, request.IsAgree, request.Id, response.FriendInfoList,response.RequestInfoList);
2021-04-08 20:09:59 +08:00
if (!ret.Equals(string.Empty))
{
response.Message = ret;
reply();
return;
}
reply();
await ETTask.CompletedTask;
}
}
}