Raised This Month: $12 Target: $400
 3% 

[Help] Socket Request


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
pro_on_0
Member
Join Date: Nov 2008
Old 05-31-2010 , 06:14   [Help] Socket Request
Reply With Quote #1

Refer to the topic about Socket

http://forums.alliedmods.net/showthread.php?t=104958

What messages are the
"%c%c%c%c%s" &
"%c%c%c%c%c%s%c"

Code:
public SendRequest( ) { 
 new szOldRequest[ 12 ], szNewRequest[ 26 ], i; 
 format( szOldRequest, 11, "%c%c%c%c%s", 255, 255, 255, 255, "details" ); 
 format( szNewRequest, 25, "%c%c%c%c%c%s%c", 255, 255, 255, 255, 84, "Source Engine Query", 0 ); 
 
// Clear infos 
 g_bServerAlive = false; 
 g_bIsWindows = false; 
 g_strReturn[ HOSTNAME    ][ 0 ] = '^0'; 
 g_strReturn[ MAP         ][ 0 ] = '^0'; 
 g_intReturn[ BOTS        ]      = 0; 
 g_intReturn[ PLAYERS     ]      = 0; 
 g_intReturn[ MAX_PLAYERS ]      = 0; 
 
// Send sockets 
 for( i = -1; i < 4; i++ ) 
    socket_send2( g_iSocket, szOldRequest, 11 ); 
 
 for( i = -1; i < 4; i++ ) 
    socket_send2( g_iSocket, szNewRequest, 25 ); 
 
 set_task( 0.1, "ReceiveInfo", TASK, _, _, "b" ); 
 
 return PLUGIN_CONTINUE; 
} 

Sorry for my poor English

Last edited by pro_on_0; 05-31-2010 at 06:17.
pro_on_0 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 05-31-2010 , 17:51   Re: [Help] Socket Request
Reply With Quote #2

It's formatting the string.

http://www.amxmodx.org/funcwiki.php?go=func&id=49
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
pro_on_0
Member
Join Date: Nov 2008
Old 06-01-2010 , 08:19   Re: [Help] Socket Request
Reply With Quote #3

Quote:
Originally Posted by Exolent[jNr] View Post
I want to know the characters of %c%c%c%c%s & %c%c%c%c%c%s%c
pro_on_0 is offline
Sylwester
Veteran Member
Join Date: Oct 2006
Location: Poland
Old 06-01-2010 , 08:30   Re: [Help] Socket Request
Reply With Quote #4

After formatting the characters in szNewRequest are (just like explained here):
Code:
˙˙˙˙TSource Engine Query
and in szOldRequest (this is old/outdated version):
Code:
˙˙˙˙details
__________________
Impossible is Nothing
Sylwester is offline
pro_on_0
Member
Join Date: Nov 2008
Old 06-04-2010 , 08:47   Re: [Help] Socket Request
Reply With Quote #5

Quote:
Originally Posted by Sylwester View Post
After formatting the characters in szNewRequest are (just like explained here):
Code:
˙˙˙˙TSource Engine Query
and in szOldRequest (this is old/outdated version):
Code:
˙˙˙˙details
OIC
pro_on_0 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:24.


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