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

[EXTENSION] Socket (3.0.1)


Post New Thread Reply   
 
Thread Tools Display Modes
Twelve-60
Senior Member
Join Date: Aug 2007
Old 03-19-2009 , 18:25   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #121

Okay, well if you need any help testing etc let me know

- Twelve-60
__________________
Twelve-60 is offline
Twelve-60
Senior Member
Join Date: Aug 2007
Old 03-22-2009 , 10:22   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #122

Ok, well I'm letting you know that it may or may not be this extension causing the leak(s). My srcds seems to be effected by different sourcemod versions and different configs, not just this extension.

- Twelve-60
__________________
Twelve-60 is offline
sfPlayer
Senior Member
Join Date: Dec 2007
Location: Germany
Old 03-25-2009 , 15:28   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #123

fixed an issue reported by XenonServers

new version 3 preview attached

Last edited by psychonic; 03-05-2011 at 23:31. Reason: removed attachment due to no source code being available
sfPlayer is offline
Atreus
SourceMod Donor
Join Date: Apr 2005
Location: San Diego, CA
Old 03-31-2009 , 19:11   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #124

Awesome! I'll try out the windows version ASAP

Edit: Did I dream of the windows versoin being released? I'd SWEAR i saw the win version up earlier..

edit again: yeah i did, shit

Last edited by Atreus; 03-31-2009 at 23:38.
Atreus is offline
Send a message via AIM to Atreus Send a message via MSN to Atreus
Kigen
BANNED
Join Date: Feb 2008
Old 04-06-2009 , 12:48   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #125

Can you get a Windows version out sfPlayer?
Kigen is offline
koshmel
Member
Join Date: Nov 2008
Old 04-23-2009 , 10:18   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #126

SocketSetArg. How set String?
koshmel is offline
sfPlayer
Senior Member
Join Date: Dec 2007
Location: Germany
Old 04-23-2009 , 10:49   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #127

You can't use strings directly. Use a datapack or adt_array to wrap it up, handles are just integers and can be used with SocketSetArg.
sfPlayer is offline
koshmel
Member
Join Date: Nov 2008
Old 04-23-2009 , 14:13   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #128

Quote:
Originally Posted by sfPlayer View Post
You can't use strings directly. Use a datapack or adt_array to wrap it up, handles are just integers and can be used with SocketSetArg.
[SM] Native "ReadPackString" reported: DataPack operation is out of bounds.

can you help me?
PHP Code:
#include <sourcemod>
#include <socket>


public OnSocketConnected(Handle:socketany:pack) {
    
decl String:requestStr[400];
    
ReadPackString(pack,requestStr400);
    
PrintToServer("[DEBUG] request:%s",requestStr);
    
SocketSend(socketrequestStr);
}
public 
OnSocketReceive(Handle:socketString:receiveData[], const dataSizeany:hFile) {}
public 
OnSocketDisconnected(Handle:socketany:hFile) {CloseHandle(socket);}
public 
OnSocketError(Handle:socket, const errorType, const errorNumany:hFile
{
    
LogError("socket error %d (errno %d)"errorTypeerrorNum);
    
CloseHandle(socket);
}

public 
OnPluginStart()
{
    
decl String:paramStr[400] ="Some String";
    new 
Handle:pack =CreateDataPack();
    
WritePackString(pack,paramStr);
    new 
Handle:socket SocketCreate(SOCKET_TCPOnSocketError);
    
SocketConnect(socketOnSocketConnectedOnSocketReceiveOnSocketDisconnected,"localhost"80);
    
SocketSetArg(socket,pack);
    return;

koshmel is offline
StevoTVR
Senior Member
Join Date: Oct 2008
Old 04-23-2009 , 14:17   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #129

Quote:
Originally Posted by koshmel View Post
[SM] Native "ReadPackString" reported: DataPack operation is out of bounds.

can you help me?
Add ResetPack before ReadPackString.

http://docs.sourcemod.net/api/index....d=show&id=173&
StevoTVR is offline
koshmel
Member
Join Date: Nov 2008
Old 04-23-2009 , 17:21   Re: [EXTENSION] Socket (2.4.0beta+2.1)
Reply With Quote #130

thx. it works
koshmel 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 06:54.


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