• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
server launcher help
#1
i want to put in this code server password so when player connects through button that launcher (.exe) writes password for him



Code:

? ? ? private void button1_Click(object sender, EventArgs e)

? ? ? ?{

? ? ? ? ? ?System.Diagnostics.Process.Start("samp://75.127.13.245:7780");

? ? ? ?}
  Reply
#2
?Qu??
  Reply
#3
One topic is enough.
  Reply
#4
This is not?what launcher is meant to do. Launcher should inject samp.dll into gta_sa.exe process, not call samp?link.
@dakyskye everywhere
  Reply
#5
You could always launch samp.exe and pass the following parameters:

-h <IP> -p <PORT> -n <NAME> -z <PASSWORD>



example:

samp.exe -h 127.0.0.1 -p 7777 -n Josh -z MyL33tP4ssw0rd
  Reply
#6
(2019-07-13, 08:53 PM)Josh Wrote: You could always launch samp.exe and pass the following parameters:

-h <IP> -p <PORT> -n <NAME> -z <PASSWORD>



example:

samp.exe -h 127.0.0.1 -p 7777 -n Josh -z MyL33tP4ssw0rd



That is incorrect. If command line arguments are given, "samp.exe" treats the first command line argument (separated by white space) as an IPv4 address with port separated by ":", if specified. If it fails to parse the command line argument string, it will still launch San Andreas Multiplayer and attempts to connect to ":7777", which is an invalid server IP address.



Code:
samp.exe -c -h 1.2.3.4 -p 1234 -n WTF

results in

[Image: unknown.png]



where

Code:
sampcmd.exe -c -h 1.2.3.4 -p 1234 -n WTF

results in

[Image: unknown.png]



Note that "-c" (empty RCON password) is required to make it work, because why wouldn't it just be optional instead?

"sampcmd" just copies the command line arguments to the GTA San Andreas process, so "samp.dll" can parse them.
[Image: github-samp-icon.png]
  Reply
#7
[Image: tAY3wmW.png]



That works fine then.

samp.exe 127.0.0.1:777 -n Legend -z MyL33tP4ssw0rd -c
  Reply


Forum Jump: