If I were to launch srcds.exe with some command line args is it possible to read them in Lua? So for example when a server start I could parse a unique instance ID to that server (Not the only reason I need it though)?
maybe a convar archived?
I would love to read rcon passwords too
[QUOTE=Kevlon;50252851]I would love to read rcon passwords too[/QUOTE]
wot? I was trying to create something that automaticly started and stopped servers, But each server needed a unique ID each time they start and the best way i could think to parse it would be in the command line?
[QUOTE=Kevlon;50252851]I would love to read rcon passwords too[/QUOTE]
If someone is able to run Lua on your server, you're already fucked.
[QUOTE=0V3RR1D3;50252952]wot? I was trying to create something that automaticly started and stopped servers, But each server needed a unique ID each time they start and the best way i could think to parse it would be in the command line?[/QUOTE]
do it like other systems do, add them in a sql database and give them an auto-increment var as ID, and then set it inside your lua config.
[QUOTE=whitestar;50253908]do it like other systems do, add them in a sql database and give them an auto-increment var as ID, and then set it inside your lua config.[/QUOTE]
What I do on my multi-server system thing is basically this. I give each server a set port - then add the port to a database and give the server an ACTUAL unique id.
Eg.
id int, address varchar(255), active int
1 XXX.XXX.XXX.XXX:27020 1
Then on server startup, query the database and get their unique ID.
[QUOTE=Semajnad;50254096]What I do on my multi-server system thing is basically this. I give each server a set port - then add the port to a database and give the server an ACTUAL unique id.
Eg.
id int, address varchar(255), active int
1 XXX.XXX.XXX.XXX:27020 1
Then on server startup, query the database and get their unique ID.[/QUOTE]
That's what I was looking for, Your the man. Thanks.
Sorry, you need to Log In to post a reply to this thread.