Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void button1_Click(object sender, EventArgs e)
- {
- IPHostEntry host = null;
- host = Dns.GetHostEntry(entered_ip);
- foreach (IPAddress address in host.AddressList)
- {
- IPEndPoint ipe = new IPEndPoint(address, 7779);
- Socket samp = new Socket(ipe.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
- samp.Connect(ipe);
- if (samp.Connected)
- {
- enable_anticheat();
- Process.Start("samp://" + entered_ip + ":" + entered_port);
- break;
- }
- else
- {
- continue;
- }
- }
- }
- private void Form1_FormClosing(object sender, FormClosingEventArgs e)
- {
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement