CTT/Server/Hotfix/Game/Handler/Pet/C2M_GetPetActionRewordHandl...

27 lines
716 B
C#
Executable File

using System;
using System.Collections.Generic;
using Cal.DataTable;
namespace ET
{
[ActorMessageHandler]
public class C2M_GetPetActionRewordHandler : AMActorLocationRpcHandler<Unit, C2M_GetPetActionReword, M2C_GetPetActionReword>
{
protected override async ETTask Run(Unit unit, C2M_GetPetActionReword request, M2C_GetPetActionReword response, Action reply)
{
Pet pet = unit.GetComponent<Pet>();
string ret = pet.GetActionReword();
if (ret != null)
{
response.Message = ret;
reply();
return;
}
reply();
await ETTask.CompletedTask;
}
}
}