Hi,
hlds cstrike crashes at startup when connecting to a hltv through socket_open.
hlds starts up just fine as long as i dont have the hltv process running on the remote server. As soon as i start it and try to start hlds the server just hangs right after mapchange when it starts connecting to the hltv.
here is the amxx code im using
PHP Code:
#define HLTV "1.2.3.4"
new hltv_port;
new hltv_stat;
hltv_port = FETCHING_A_PORT_FROM_MYSQL;
public hltv_reset()
{
new socket = 0;
new error;
new rconid[13];
new rcv[256];
new snd[256];
new rconPass[32];
// Connect to server
socket = socket_open(HLTV, hltv_port, SOCKET_UDP, error);
if (error != 0)
{
server_print("[%s]%s HLTV Record :: Connection to HLTV %s:%s failed.",log_time(), SERVER_PREFIX, HLTV, hltv_port);
} else {
//send challenge rcon and receive response
setc(snd,4,0xff);
copy(snd[4],255,"challenge rcon");
setc(snd[18],1,'^n');
socket_send(socket,snd,255);
socket_recv(socket,rcv,255);
// get rcon challenge number from response
copy(rconid,12,rcv[19]);
replace(rconid,255,"^n","");
rconPass = "asdasd";
// set rcon command
setc(snd,255,0x00);
setc(snd,4,0xff);
format(snd[4],255,"rcon %s %s stoprecording",rconid,rconPass);
// send rcon command and close socket
socket_send(socket,snd,255);
socket_close(socket);
}
No logs or anything :/
Thankful for all the help i can get on this issue.