CS.RIN.RU - Steam Underground Community
http://cs.rin.ru/forum/

[Release] dproto - double protocol for HL1 based games [ARCHIVE]
http://cs.rin.ru/forum/viewtopic.php?f=15&t=52728
Page 10 of 114

Author:  Nyerk! [ Thursday, 18 Jun 2009, 10:50 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Reitak: YES, your server must be updated, but with dproto can also 47 protocol players join
Servers must be updated anyway, idk what about clients (serverbrowser in revemu doenst fully work, but i hope it will be fixed)

Author:  Flasher [ Thursday, 18 Jun 2009, 12:57 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Reitak
This is just planning of moving from old protocol to new. I doesn't think that 47 protocol will die in nearest year.

Author:  styler_RO [ Thursday, 18 Jun 2009, 14:27 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Quote:
supermega

Reuploaded (ns_name_prefix.amxx): http://www.sendspace.com/file/8bok74
CVAR:
amx_ns_prefix "[Non-Steam] "

can u make (personalize) to change prefix players name in [P48] or [P47] ? depends by protocols.
ty!

Author:  Reitak [ Thursday, 18 Jun 2009, 15:00 ]
Post subject:  Re: dproto - double protocol for HL1 based games

i think, this is very very hard convince player to download new patch p48 or new cs game with new patch. i have 7 servers cstrike.mystiq.org but this servers are for both protocol (but problem is with favorites), but few months ago i have only for p47 servers and servers were full, then i change it to p48 and i had 1 server with 5 players, another servers were empty 1 month !!!
then i use dproto and my servers are full (favorites work nice), now is problem with favorites and my servers are full 80-90%.

BUT !!! When everybody make on server this http://i44.tinypic.com/atramg.jpg , i think these ads make p47 players download patch, because it will certainly interfere during playing.

Things with prefix is for nothing !! Players p47 must something abolishing during playing, not prefix

Author:  0xCAFE23 [ Thursday, 18 Jun 2009, 18:59 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Running server with eSTEAMATiON support i get this error:

Quote:
terminate called after throwing an instance of 'common::CNamedArgsUndefinedNameException'
what(): Tried to read undefined arg name: GeneralDirectoryServer_FindServerIPAddrPorts
./hlds_run: line 321: 21829 Aborted $HL_CMD


Without eSTEAMATiON everithing works fine.

Author:  crp [ Friday, 19 Jun 2009, 10:55 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Ok here is another version of prot 48 download. it will show message that you need to type /download. if user type "/download" then a download screen will popup to him and start to download cs 1.6 prot 48. Its even better because some noobz dont even boter to go in forum and search there where is the download link.

  1.  
  2. #include <amxmodx>
  3. #include <amxmisc>
  4. #include <fakemeta>
  5.  
  6. #define PLUGIN "Automatic prot48 download"
  7. #define VERSION "1.0"
  8. #define AUTHOR "crp"
  9.  
  10. #define MSG_DELAY 6.0  
  11. #define MAX_CLIENTS 32
  12.  
  13. new const g_sMessage[] = "[prot48] Type ^"/download^" in chat to download Counter-Strike 1.6 prot48 !";
  14. new bool:g_bFirst_connect[ MAX_CLIENTS + 1 ];
  15.  
  16. public plugin_init() {
  17.    
  18.     register_cvar ( "prot48_dl", VERSION, FCVAR_SERVER );
  19.     register_plugin(PLUGIN, VERSION, AUTHOR);
  20.     register_clcmd("say /download","_show_dl");
  21.     register_event("ResetHUD","eHud_reset","be");
  22. }
  23.  
  24. public _show_dl(id)
  25. {
  26.         show_motd(id,"http://your.direct.link.do.download./cs.prot.48.rar","title");
  27.        
  28.     return 1;
  29. }
  30.  
  31. public client_putinserver(id) g_bFirst_connect[id] = true;
  32. public client_disconnect (id) g_bFirst_connect[id] = false;
  33.  
  34. public eHud_reset(id)
  35. {
  36.     if( !g_bFirst_connect[id] )
  37.             return;
  38.  
  39.     g_bFirst_connect[id] = false;
  40.     set_task( MSG_DELAY,"PrintDelayed",id);
  41. }
  42.  
  43. public PrintDelayed(id)
  44. {
  45.     client_print(id,print_chat,"%s",g_sMessage);
  46. }
  47.  


Need to edit this line
  1. show_motd(id,"http://your.direct.link.do.download./cs.prot.48.rar","title");

Author:  tepy [ Friday, 19 Jun 2009, 14:21 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Crock

thanks a lot

Author:  k-noon [ Saturday, 20 Jun 2009, 03:02 ]
Post subject:  Re: dproto - double protocol for HL1 based games

I came here to thank you for this stuff, i'm using this for a few days and everything is working fine, thank you.

:ROFL:

Author:  ineya [ Saturday, 20 Jun 2009, 03:54 ]
Post subject:  Re: dproto - double protocol for HL1 based games

GoD2.0 wrote:
Crock wrote:
GoD2.0, whoops, i forgot to remove this code... btw this redirection method are not usable for steam clients, so subserver becomes useless


I worked around a little bit with the code for redirect and found a method that works for both steam and non-steam clients. I post the code below for subserver.cpp:

  1. void CSubServer::ParseConnect(char* buf, int len, unsigned int ip, unsigned int port) {
  2.     char* cbuf = buf + 4;
  3.     char SBuf[1500];
  4.     in_addr ina;
  5.     int res;
  6.     if (len < 11) return;
  7.     if (strncmp(cbuf, "connect", 7)) return;
  8.     cbuf = SBuf;
  9.     SIN_SET_ADDR(&ina, ip);
  10.     res = sprintf(cbuf, "%c%c%c%c%c %d \"%s:%d\" %d", 0xFF, 0xFF, 0xFF, 0xFF, 'B', 1, inet_ntoa(ina), port, 0);
  11.     cbuf += res;
  12.  
  13.     res = cbuf - SBuf;
  14.     SendData(SBuf, res, ip, port);
  15.  
  16.     cbuf = SBuf;
  17.     res = sprintf(cbuf, "%c%c%c%c%c%c%c%c", 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0);
  18.     cbuf += res;
  19.  
  20.     res = sprintf(cbuf, "%c%s", 0x9, "echo \"* Redirecting...\"; ");
  21.     cbuf += res;
  22.  
  23.     res = sprintf(cbuf, "%s\n", ExecCmd);
  24.     cbuf += res + 1;
  25.  
  26.     res = cbuf - SBuf;
  27.     while (res % 4) {
  28.         SBuf[res++] = 1;
  29.     }
  30.  
  31.     Munge2((int*)(SBuf+8), res-8, 0);
  32.     SendData(SBuf, res, ip, port);
  33. }


If i can be of help with other things please do not hesitate to PM me :)

Thank you!
I just tried this and redirection works for Steam as well, good job!

Author:  RPG [ Saturday, 20 Jun 2009, 10:51 ]
Post subject:  Re: dproto - double protocol for HL1 based games

ineya wrote:
GoD2.0 wrote:
Crock wrote:
GoD2.0, whoops, i forgot to remove this code... btw this redirection method are not usable for steam clients, so subserver becomes useless


I worked around a little bit with the code for redirect and found a method that works for both steam and non-steam clients. I post the code below for subserver.cpp:

  1. void CSubServer::ParseConnect(char* buf, int len, unsigned int ip, unsigned int port) {
  2.     char* cbuf = buf + 4;
  3.     char SBuf[1500];
  4.     in_addr ina;
  5.     int res;
  6.     if (len < 11) return;
  7.     if (strncmp(cbuf, "connect", 7)) return;
  8.     cbuf = SBuf;
  9.     SIN_SET_ADDR(&ina, ip);
  10.     res = sprintf(cbuf, "%c%c%c%c%c %d \"%s:%d\" %d", 0xFF, 0xFF, 0xFF, 0xFF, 'B', 1, inet_ntoa(ina), port, 0);
  11.     cbuf += res;
  12.  
  13.     res = cbuf - SBuf;
  14.     SendData(SBuf, res, ip, port);
  15.  
  16.     cbuf = SBuf;
  17.     res = sprintf(cbuf, "%c%c%c%c%c%c%c%c", 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0);
  18.     cbuf += res;
  19.  
  20.     res = sprintf(cbuf, "%c%s", 0x9, "echo \"* Redirecting...\"; ");
  21.     cbuf += res;
  22.  
  23.     res = sprintf(cbuf, "%s\n", ExecCmd);
  24.     cbuf += res + 1;
  25.  
  26.     res = cbuf - SBuf;
  27.     while (res % 4) {
  28.         SBuf[res++] = 1;
  29.     }
  30.  
  31.     Munge2((int*)(SBuf+8), res-8, 0);
  32.     SendData(SBuf, res, ip, port);
  33. }


If i can be of help with other things please do not hesitate to PM me :)

Thank you!
I just tried this and redirection works for Steam as well, good job!

Can someone post the win \ dproto.dll with working Subserver redirect?
It's not working for me in dproto 0.2.6.

Author:  imSpartan [ Saturday, 20 Jun 2009, 10:55 ]
Post subject:  Re: dproto - double protocol for HL1 based games

Does dproto + esteamation ban id work?

-- Edit --

Ban working for dproto + eSteamation.
Use amxbans. ::D

Author:  iggy_bus [ Saturday, 20 Jun 2009, 15:22 ]
Post subject:  Re: dproto - double protocol for HL1 based games

dproto works ok for me except every day around 3-5 in the morning server crashes.

I find this message in console last:

./hlds_run: line 321: 31737 Segmentation fault $HL_CMD

Author:  ineya [ Saturday, 20 Jun 2009, 20:38 ]
Post subject:  Re: dproto - double protocol for HL1 based games

ineya wrote:
I made few experiments today regarding this issue. From what I've seen, the request packet (TSource Engine Query) is same for steam/nonsteam P47 and P48 clients, but each expects different reply. This is the main problem, because you don't know who are you communicating with.
So if I get request from client, I replied with 2 answers, one that P47 would expect and one which new steam client would expect. Unfortunetly it didn't work, and it seems client will make its decision based on first reply which arrives.

I revisited this idea again.
I'm running dproto using the old protocol. I wrote a library, which I load before hlds starts, and I rewrote sendto function with my own implementaion in this way:
if I detect that response to server info query is about to be sent, I do:
send faulty packet
send reply using old proto
send reply using new proto

and I can see my server from NS P47 client, NS P48 client and latest STEAM P48 client :-).

If you would like to try (and test this early version for linux) here is a link:
http://lambdacore.info/libt_a.zip

This is inside:
libt
libt/libt.so
hlds_run

hlds_run is my version and these are changes I made to load libt:
  1.  
  2. --- a/hlds_run
  3. +++ b/hlds_run
  4. @@ -357,7 +357,7 @@ run() {
  5.                         update
  6.  
  7.                         # Run the server
  8. -                       $HL_CMD
  9. +                       env LD_PRELOAD=libt/libt.so $HL_CMD
  10.                         retval=$?
  11.                         if test $retval -eq 0 && test -z "$AUTO_UPDATE"; then
  12.                                 break; # if 0 is returned then just quit
  13. @@ -377,10 +377,10 @@ run() {
  14.                 # Run the server
  15.                 if test -z "$DEBUG"; then
  16.                         # debug not requested we can exec
  17. -                       exec $HL_CMD
  18. +                       env LD_PRELOAD=libt/libt.so exec $HL_CMD
  19.                 else
  20.                         # debug requested we can't exec
  21. -                       $HL_CMD
  22. +                       env LD_PRELOAD=libt/libt.so $HL_CMD
  23.                         debugcore $?
  24.                 fi
  25.         fi
  26.  


If more people find this working, I guess it can become part of some future release of dproto.
I tested this server with 5 different clients I could get, 2 of them were steam.

This is not intended as server promotion, it's a server where I'm currently testing it, if you'd like to see it, but don't want to install it on your server: 217.11.249.92:27205

Author:  Master07 [ Saturday, 20 Jun 2009, 21:23 ]
Post subject:  Re: dproto - double protocol for HL1 based games

ineya, it works, thanks.

Author:  Darkill [ Saturday, 20 Jun 2009, 22:01 ]
Post subject:  Re: dproto - double protocol for HL1 based games

ineya, can you make a windows version? ::D

Thanks!

Page 10 of 114 All times are UTC + 3 hours
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/