Raised This Month: $ Target: $400
 0% 

Multithreading in AMX MOD X


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
01101101
BANNED
Join Date: Nov 2009
Location: 9`su 09`n0n7e`r0f76a
Old 08-15-2010 , 11:15   Multithreading in AMX MOD X
Reply With Quote #1

Yes, lets say I gotta do something which takes long time, and I don't want the server to freeze lag, te same way SQLx uses ThreadedQuery. Is this possible?
01101101 is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-15-2010 , 11:54   Re: Multithreading in AMX MOD X
Reply With Quote #2

Explain what you're trying to do and the code that you have. It is possible that your code can be optimized.
__________________
Bugsy is offline
01101101
BANNED
Join Date: Nov 2009
Location: 9`su 09`n0n7e`r0f76a
Old 08-15-2010 , 12:40   Re: Multithreading in AMX MOD X
Reply With Quote #3

Quote:
Originally Posted by Bugsy View Post
Explain what you're trying to do and the code that you have. It is possible that your code can be optimized.
Nothing concrete, it's mainly for educational purposes, but lets say as an example, sort 100000 rows

Last edited by 01101101; 08-15-2010 at 13:35.
01101101 is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 08-15-2010 , 12:54   Re: Multithreading in AMX MOD X
Reply With Quote #4

In that particular case you have SortCustom natives.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
01101101
BANNED
Join Date: Nov 2009
Location: 9`su 09`n0n7e`r0f76a
Old 08-15-2010 , 13:36   Re: Multithreading in AMX MOD X
Reply With Quote #5

Well, but except in particular natives, you can't work in a separate thread. That was the main question
01101101 is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 08-15-2010 , 17:27   Re: Multithreading in AMX MOD X
Reply With Quote #6

HLDS is not a threaded application.
__________________
fysiks is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 08-15-2010 , 19:55   Re: Multithreading in AMX MOD X
Reply With Quote #7

Quote:
Originally Posted by fysiks View Post
HLDS is not a threaded application.
This always confused me. How does SQLX work (I don't understand threading much).

Also, the source of HLDS is.. around. Looking through it, there's a million classes that refer to "CWorkerThread"
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
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 21:57.


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