Ejemplo n.º 1
0
        public EndlessGame(IClientWindowSizeProvider windowSizeProvider,
                           IGraphicsDeviceRepository graphicsDeviceRepository,
                           IControlSetRepository controlSetRepository,
                           IControlSetFactory controlSetFactory,
                           ITestModeLauncher testModeLauncher,
                           IPubFileLoadActions pubFileLoadActions,
                           ILoggerProvider loggerProvider,
                           IChatBubbleTextureProvider chatBubbleTextureProvider)
        {
            _graphicsDeviceRepository  = graphicsDeviceRepository;
            _controlSetRepository      = controlSetRepository;
            _controlSetFactory         = controlSetFactory;
            _testModeLauncher          = testModeLauncher;
            _pubFileLoadActions        = pubFileLoadActions;
            _loggerProvider            = loggerProvider;
            _chatBubbleTextureProvider = chatBubbleTextureProvider;

            _graphicsDeviceManager = new GraphicsDeviceManager(this)
            {
                PreferredBackBufferWidth  = windowSizeProvider.Width,
                PreferredBackBufferHeight = windowSizeProvider.Height
            };

            Content.RootDirectory = "Content";
        }
Ejemplo n.º 2
0
        public ChatBubble(string message,
                          bool isGroupChat,
                          IHaveChatBubble referenceRenderer,
                          IChatBubbleTextureProvider chatBubbleTextureProvider)
        {
            _isGroupChat               = isGroupChat;
            _referenceRenderer         = referenceRenderer;
            _chatBubbleTextureProvider = chatBubbleTextureProvider;

            _textLabel = new XNALabel(Constants.FontSize08pt5)
            {
                Visible   = true,
                TextWidth = 165,
                TextAlign = LabelAlignment.MiddleCenter,
                ForeColor = Color.Black,
                AutoSize  = true,
                Text      = message
            };
            _textLabel.Initialize(); //todo: figure out if this needs to be removed from game components

            _drawLocation = Vector2.Zero;
            _startTime    = DateTime.Now;

            SetLabelDrawPosition();
        }
 public OtherCharacterEventSubscriber(IChatBubbleActions chatBubbleActions,
                                      IChatBubbleRepository chatBubbleRepository,
                                      IChatBubbleTextureProvider chatBubbleTextureProvider,
                                      ICharacterRendererProvider characterRendererProvider)
 {
     _chatBubbleActions         = chatBubbleActions;
     _chatBubbleRepository      = chatBubbleRepository;
     _chatBubbleTextureProvider = chatBubbleTextureProvider;
     _characterRendererProvider = characterRendererProvider;
 }
Ejemplo n.º 4
0
 public NPCActions(IHudControlProvider hudControlProvider,
                   INPCStateCache npcStateCache,
                   INPCRendererRepository npcRendererRepository,
                   IChatBubbleRepository chatBubbleRepository,
                   IChatBubbleTextureProvider chatBubbleTextureProvider)
 {
     _hudControlProvider        = hudControlProvider;
     _npcStateCache             = npcStateCache;
     _npcRendererRepository     = npcRendererRepository;
     _chatBubbleRepository      = chatBubbleRepository;
     _chatBubbleTextureProvider = chatBubbleTextureProvider;
 }
Ejemplo n.º 5
0
 public ChatBubbleActions(IChatBubbleRepository chatBubbleRepository,
                          IChatProcessor chatProcessor,
                          IChatTypeCalculator chatTypeCalculator,
                          ICharacterRendererProvider characterRendererProvider,
                          IChatBubbleTextureProvider chatBubbleTextureProvider)
 {
     _chatBubbleRepository      = chatBubbleRepository;
     _chatProcessor             = chatProcessor;
     _chatTypeCalculator        = chatTypeCalculator;
     _characterRendererProvider = characterRendererProvider;
     _chatBubbleTextureProvider = chatBubbleTextureProvider;
 }
Ejemplo n.º 6
0
 public ChatBubble(string message,
                   IHaveChatBubble referenceRenderer,
                   IChatBubbleTextureProvider chatBubbleTextureProvider)
     : this(message, false, referenceRenderer, chatBubbleTextureProvider)
 {
 }