// Copyright © 2017-2018 Atomic Software, LLC. All Rights Reserved.
// See LICENSE.md for full license information.

using Atom.Core.Networking.Messages;
using Atom.WorldManagerServer.Logic;
using Atom.WorldManagerServer.Services;

namespace Atom.WorldManagerServer.Networking.Messages.Handlers
{
    public static class LocalHandlers
    {
        [MessageHandler(MessageProtocol.NC_LOCAL_REGISTERWORLD_ACK)]
        public static void NC_LOCAL_REGISTERWORLD_ACK(NetworkMessage msg)
        {
            var Success = msg.ReadBoolean();
            LoginServerLogic.DidWorldRegsiter(Success);
        }

        [MessageHandler(MessageProtocol.NC_LOCAL_ADDTRANSFER_CMD)]
        public static void NC_LOCAL_ADDTRANSFER_CMD(NetworkMessage msg)
        {
            var ValidateNew = msg.ReadString(64);
            TransferService.AddTransfer(ValidateNew);
        }
    }
}
