// Decompiled with JetBrains decompiler // Type: Raton.Forms.ClientForms.Dialogs.shareHost // Assembly: Raton, Version=0.4.0.0, Culture=neutral, PublicKeyToken=null // MVID: 36C4E416-7F8D-4D23-930F-B5CCB0D810E7 // Assembly location: C:\Users\user\Desktop\v3.8.0 Deluxe Plugins (v4.0.0) cracked\Raton.exe using DarkModeForms; using Raton.Classes; using Server.Connection; using Stuff; using System; using System.ComponentModel; using System.Drawing; using System.Windows.Forms; #nullable disable namespace Raton.Forms.ClientForms.Dialogs; public class shareHost : Form { private IContainer components; private TextBox textBox1; private Label label1; private Label label2; private TextBoxButton textBoxButton1; private Timer timer1; private TextBox textBox2; public SillyClient SillyClient { get; set; } public shareHost() { this.InitializeComponent(); DarkMode.Start((Form) this); } private void textBoxButton1_Click(object sender, EventArgs e) { if (string.IsNullOrWhiteSpace(this.textBox1.Text) || !int.TryParse(this.textBox2.Text, out int _)) { int num1 = (int) Messenger.MessageBox("Please insert a valid host to share", "Error", icon: MessageBoxIcon.Hand); } else { Pack pack = new Pack(); pack.SetString("Packet", "Share"); pack.SetString("Host", this.textBox1.Text); pack.SetString("Port", this.textBox2.Text); this.SillyClient.Send(pack.Pacc()); int num2 = (int) Messenger.MessageBox("Host shared successfully", "Success", MessageBoxButtons.OK, MessageBoxIcon.Asterisk, true); } } private void shareHost_Load(object sender, EventArgs e) => this.timer1.Start(); private void timer1_Tick(object sender, EventArgs e) { if (this.SillyClient != null && this.SillyClient.isConnected()) return; this.timer1.Stop(); this.Close(); } protected override void Dispose(bool disposing) { if (disposing && this.components != null) this.components.Dispose(); base.Dispose(disposing); } private void InitializeComponent() { this.components = (IContainer) new System.ComponentModel.Container(); ComponentResourceManager componentResourceManager = new ComponentResourceManager(typeof (shareHost)); this.textBox1 = new TextBox(); this.label1 = new Label(); this.label2 = new Label(); this.timer1 = new Timer(this.components); this.textBoxButton1 = new TextBoxButton(); this.textBox2 = new TextBox(); this.SuspendLayout(); this.textBox1.Font = new Font("Microsoft JhengHei", 8.25f, FontStyle.Regular, GraphicsUnit.Point, (byte) 0); this.textBox1.Location = new Point(12, 31 /*0x1F*/); this.textBox1.Name = "textBox1"; this.textBox1.Size = new Size(264, 22); this.textBox1.TabIndex = 0; this.label1.AutoSize = true; this.label1.Font = new Font("Microsoft JhengHei", 8.25f, FontStyle.Regular, GraphicsUnit.Point, (byte) 0); this.label1.Location = new Point(13, 12); this.label1.Name = "label1"; this.label1.Size = new Size(31 /*0x1F*/, 15); this.label1.TabIndex = 2; this.label1.Text = "Host"; this.label2.AutoSize = true; this.label2.Font = new Font("Microsoft JhengHei", 8.25f, FontStyle.Regular, GraphicsUnit.Point, (byte) 0); this.label2.Location = new Point(279, 13); this.label2.Name = "label2"; this.label2.Size = new Size(29, 15); this.label2.TabIndex = 3; this.label2.Text = "Port"; this.timer1.Tick += new EventHandler(this.timer1_Tick); this.textBoxButton1.BackColor = Color.FromArgb(32 /*0x20*/, 32 /*0x20*/, 32 /*0x20*/); this.textBoxButton1.Cursor = Cursors.Hand; this.textBoxButton1.FlatAppearance.BorderSize = 0; this.textBoxButton1.FlatStyle = FlatStyle.Flat; this.textBoxButton1.Font = new Font("Microsoft JhengHei", 9f); this.textBoxButton1.ForeColor = Color.White; this.textBoxButton1.Location = new Point(13, 60); this.textBoxButton1.Name = "textBoxButton1"; this.textBoxButton1.Size = new Size(337, 48 /*0x30*/); this.textBoxButton1.TabIndex = 4; this.textBoxButton1.Text = "Share host"; this.textBoxButton1.UseVisualStyleBackColor = false; this.textBoxButton1.Click += new EventHandler(this.textBoxButton1_Click); this.textBox2.Font = new Font("Microsoft JhengHei", 8.25f, FontStyle.Regular, GraphicsUnit.Point, (byte) 0); this.textBox2.Location = new Point(283, 31 /*0x1F*/); this.textBox2.Name = "textBox2"; this.textBox2.Size = new Size(67, 22); this.textBox2.TabIndex = 5; this.AutoScaleDimensions = new SizeF(6f, 13f); this.AutoScaleMode = AutoScaleMode.Font; this.ClientSize = new Size(363, 132); this.Controls.Add((Control) this.textBox2); this.Controls.Add((Control) this.textBoxButton1); this.Controls.Add((Control) this.textBox1); this.Controls.Add((Control) this.label1); this.Controls.Add((Control) this.label2); this.FormBorderStyle = FormBorderStyle.FixedSingle; this.Icon = (Icon) componentResourceManager.GetObject("$this.Icon"); this.MaximizeBox = false; this.MinimizeBox = false; this.Name = nameof (shareHost); this.StartPosition = FormStartPosition.CenterScreen; this.Text = nameof (shareHost); this.Load += new EventHandler(this.shareHost_Load); this.ResumeLayout(false); this.PerformLayout(); } }