Inheritance: MetroFramework.Controls.MetroUserControl, IAddonTab
		public ConsoleTab()
		{
			Reference = this;
			InitializeComponent();

			MinecraftOutputHandler.OutputParsed += PrintOutput;
			ProcessHandler.ServerStarting += HandleServerStart;
			ProcessHandler.ServerStopped += HandleServerStop;
			CIConsoleInput.CommandSent += HandleCommandSent;
			PlayerHandler.PlayerListAddition += HandlePlayerAddition;
			PlayerHandler.PlayerListDeletion += HandlePlayerDeletion;

			MCCOut.MessageColorInfo = Color.FromArgb(Config.ReadInt("console", "color_info", Color.Blue.ToArgb()));
			MCCOut.MessageColorPlayerAction =
				Color.FromArgb(Config.ReadInt("console", "color_playeraction", Color.DarkGreen.ToArgb()));
			MCCOut.MessageColorSevere = Color.FromArgb(Config.ReadInt("console", "color_severe", Color.DarkRed.ToArgb()));
			MCCOut.MessageColorWarning =
				Color.FromArgb(Config.ReadInt("console", "color_warning", Color.DarkOrange.ToArgb()));

			MCCOut.ShowDate = Config.ReadBool("console", "date", false);
			MCCOut.ShowTime = Config.ReadBool("console", "time", true);

			imgListPlayerFaces.Images.Clear();
			imgListPlayerFaces.Images.Add("default", Resources.player_face);

			MCCOut.Autoscroll = Config.ReadBool("console", "autoscroll", true);
		}
Exemple #2
0
        public ConsoleTab()
        {
            Reference = this;
            InitializeComponent();

            MinecraftOutputHandler.OutputParsed += PrintOutput;
            ProcessHandler.ServerStarting       += HandleServerStart;
            ProcessHandler.ServerStopped        += HandleServerStop;
            CIConsoleInput.CommandSent          += HandleCommandSent;
            PlayerHandler.PlayerListAddition    += HandlePlayerAddition;
            PlayerHandler.PlayerListDeletion    += HandlePlayerDeletion;

            MCCOut.MessageColorInfo         = Color.FromArgb(Config.ReadInt("console", "color_info", Color.Blue.ToArgb()));
            MCCOut.MessageColorPlayerAction =
                Color.FromArgb(Config.ReadInt("console", "color_playeraction", Color.DarkGreen.ToArgb()));
            MCCOut.MessageColorSevere  = Color.FromArgb(Config.ReadInt("console", "color_severe", Color.DarkRed.ToArgb()));
            MCCOut.MessageColorWarning =
                Color.FromArgb(Config.ReadInt("console", "color_warning", Color.DarkOrange.ToArgb()));

            MCCOut.ShowDate = Config.ReadBool("console", "date", false);
            MCCOut.ShowTime = Config.ReadBool("console", "time", true);

            imgListPlayerFaces.Images.Clear();
            imgListPlayerFaces.Images.Add("default", Resources.player_face);

            MCCOut.Autoscroll = Config.ReadBool("console", "autoscroll", true);

            CIConsoleInput.AddAutocompleteSource(PlayerHandler.GetOnlinePlayerNames);
            CIConsoleInput.AddAutocompleteSource(GetKnownCommands);
        }
Exemple #3
0
 /// <summary>
 ///     Initialize all functions and the tabcontrol
 /// </summary>
 public void Initialize()
 {
     TabPage = new ConsoleTab {
         Text = Name, ParentAddon = this
     };
     ConfigPage = new ConsoleSettings();
 }
Exemple #4
0
		/// <summary>
		///     Initialize all functions and the tabcontrol
		/// </summary>
		public void Initialize()
		{
			TabPage = new ConsoleTab {Text = Name, ParentAddon = this};
			ConfigPage = new ConsoleSettings();
		}