AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Approved Plugins (https://forums.alliedmods.net/forumdisplay.php?f=8)
-   -   Adminbot-MXX (Clan War Plugin) - By Syam (https://forums.alliedmods.net/showthread.php?t=4143)

redmist 08-14-2004 02:34

Quote:

Make sure you have the correct HLTV RCON password set.
Admin Password for HLTV is fine. I've tried other war scripts and they have no problems RCONing HLTV though they use the old 0.9.8 upd.dll

I could be wrong, but to me it seems like the new code using basic sockets simply doesn't work.

EGRES 08-14-2004 04:31

rcon is ok :o)) adminbot works fine..... it is only "cosmetic" issue

redmist 08-14-2004 06:14

So you're able to record HLTV demos using this plugin? I'd like to see that... :roll:

EGRES 08-14-2004 06:48

i'll check that when i have time (using this system for LANparty)

rompom7 08-15-2004 07:50

Quote:

Originally Posted by redmist
So you're able to record HLTV demos using this plugin? I'd like to see that... :roll:

Ok, before you go and make any more rudely remarked cristisms, please help me debug.

What happens when you put
Code:

nxn_match <team-a> <team-b> <map> <maxrounds> <password> [match_id] [hltv_ip] [hltv_port] [hltv_rcon]
into console, after HLTV is running and connected to your server.

redmist 08-16-2004 05:15

It says '[AMX] Match Loaded' and everything appears to be working fine. As soon as both teams type 'ready' the server locks up. If I disable HLTV, the script runs fine (although for some reason the scores are stuck in the middle of the screen for the whole match)

I've done a little debugging myself and the problem seems to occur in the hltv_rcon section of the code. The socket open command works fine but as soon as a socket_recv is issued, the server locks up.

I'm also working away trying to fix this so I'll post here when/if I find out anything useful.

Not being rude, just a little frustrated after trying to get it to work. Sorry :)

rompom7 08-16-2004 09:19

Thats ok, I understand how it feels when something doesn't work as planned.

Well, I'm guessing its something wrong with this: -
Code:

socket_recv(hltv_address,rcv,255)
socket_recv(hltv_address,snd,255)

The original code looked like this: -
Code:

query_udp_msg(hltv_address,rcv,255,snd)
I am not entirely sure how to use the sockets and UDP module, as you probably can already tell :oops:

If someone can explain to me what I am doing wrong I would be very greatful. If you need the orginal .sma I can send as well.

redmist 08-23-2004 09:20

Well, I've finally come up with some working HLTV rcon code for the sockets module...it seems to work fine.

Code:
public hltv_rcon_cmd(cmd[]) {     new hltv_address = 0         new error         new hltv_cvar_ip[15]     new hltv_cvar_port     new hltv_cvar_rcon[20]         new rconid[13]     new rcv[256],snd[256]     // hltv ip/port/password     get_cvar_string("nxn_hltv_ip",hltv_cvar_ip,15)     hltv_cvar_port = get_cvar_num("nxn_hltv_port")     get_cvar_string("nxn_hltv_rcon",hltv_cvar_rcon,20)     // Connect to HLTV Proxy     hltv_address = socket_open(hltv_cvar_ip, hltv_cvar_port, SOCKET_UDP, error)     if (error != 0) {         server_print("HLTV Proxy Connection Failed - error %i",error)         return PLUGIN_CONTINUE     }     //send challenge rcon and receive response     setc(snd,4,0xff)     copy(snd[4],255,"challenge rcon")     setc(snd[18],1,'^n')     socket_send(hltv_address,snd,255)     socket_recv(hltv_address,rcv,255)     // get hltv rcon challenge number from response     copy(rconid,12,rcv[19])     replace(rconid,255,"^n","")         // send rcon command and close socket     setc(snd,255,0x00)     setc(snd,4,0xff)     format(snd[4],255,"rcon %s ^"%s^" %s^n",rconid,hltv_cvar_rcon,cmd)     socket_send(hltv_address,snd,255)     socket_close(hltv_address)     return PLUGIN_CONTINUE }

*UPDATED - Now includes error checking and closes socket correctly

xtreme2490 08-23-2004 11:05

how can i select a second map ?
Can this tool do a auto team change after x rounds ?

rompom7 08-24-2004 03:44

Quote:

Originally Posted by xtreme2490
how can i select a second map ?
Can this tool do a auto team change after x rounds ?

You have to set up 2 fights I believe. I am not sure about the auto team change, you will have to look yourself. (Unless anyone else knows for sure)


All times are GMT -4. The time now is 16:10.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.