using GameServer.Handlers.Attributes; using GameServer.Network; using Protocol; namespace GameServer.Handlers; internal class WorldMessageHandler : MessageHandlerBase { public WorldMessageHandler(KcpSession session) : base(session) { // WorldMessageHandler. } [MessageHandler(MessageId.EntityActiveRequest)] public async Task OnEntityActiveRequest(ReadOnlyMemory _) { await Session.Rpc.ReturnAsync(MessageId.EntityActiveResponse, new EntityActiveResponse()); } [MessageHandler(MessageId.EntityOnLandedRequest)] public async Task OnEntityOnLandedRequest(ReadOnlyMemory _) { await Session.Rpc.ReturnAsync(MessageId.EntityOnLandedResponse, new EntityOnLandedResponse()); } [MessageHandler(MessageId.PlayerMotionRequest)] public async Task OnPlayerMotionRequest(ReadOnlyMemory _) { await Session.Rpc.ReturnAsync(MessageId.PlayerMotionResponse, new PlayerMotionResponse()); } [MessageHandler(MessageId.EntityLoadCompleteRequest)] public async Task OnEntityLoadCompleteRequest(ReadOnlyMemory _) { await Session.Rpc.ReturnAsync(MessageId.EntityLoadCompleteResponse, new EntityLoadCompleteResponse()); } [MessageHandler(MessageId.SceneLoadingFinishRequest)] public async Task OnSceneLoadingFinishRequest(ReadOnlyMemory _) { await Session.Rpc.ReturnAsync(MessageId.SceneLoadingFinishResponse, new SceneLoadingFinishResponse()); } [MessageHandler(MessageId.UpdateSceneDateRequest)] public async Task OnUpdateSceneDateRequest(ReadOnlyMemory _) { await Session.Rpc.ReturnAsync(MessageId.UpdateSceneDateResponse, new UpdateSceneDateResponse()); } }