using System; using System.Collections.Generic; namespace ET { [ActorMessageHandler] public class C2M_StartPetPlayHandler : AMActorLocationRpcHandler { protected override async ETTask Run(Unit unit, C2M_StartPetPlay request, M2C_StartPetPlay response, Action reply) { Pet pet = unit.GetComponent(); string ret = pet.Play(); if (ret != null) { response.Message = ret; reply(); return; } reply(); await ETTask.CompletedTask; } } }