using Server;
using Server.Config;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml;

namespace PdkFriendServer.GlobalManager
{
    public class MyFactory : ServerUtilFactory
    {
        public override Server.GlobalManager GetGlobalManager()
        {
            return new GameSeverManager();
        }

        public override object Produce(string ObjectName)
        {
            switch (ObjectName)
            {
                case "GameInfo":
                    return new GameSerInfo();
                case "castleInfo":
                    return new CastleSerInfo();
                case "tingInfo":
                    return new TingSerInfo();
                case "deskInfo":
                    return new DeskSerInfo();
            }
            return null;
        }

        public override Server.GlobalManager.MessageProcessor CreateMessageProcessor()
        {
            return new GameBase.GameMessageProcessor();
        }
        
    }
}
