public async ETVoid TestActor() { try { M2C_TestActorResponse response = (M2C_TestActorResponse)await SessionComponent.Instance.Session.Call( new C2M_TestActorRequest() { Info = "actor rpc request" }); Log.Info(response.Info); } catch (Exception e) { Log.Error(e); } }
public static async ETVoid TestActor(this OperaComponent self) { try { M2C_TestActorResponse response = (M2C_TestActorResponse)await self.ZoneScene().GetComponent <SessionComponent>().Session.Call( new C2M_TestActorRequest() { Info = "actor rpc request" }); Log.Info(response.Info); } catch (Exception e) { Log.Error(e); } }