Raised This Month: $ Target: $400
 0% 

Return Boolean through multiple Functions


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Xalus
Veteran Member
Join Date: Dec 2009
Location: Belgium
Old 06-07-2014 , 05:30   Re: Return Boolean through multiple Functions
Reply With Quote #2

ThreadQuery is way to slow for such things, try out

PHP Code:
public HasUserCreditWeapon(id, const szConst[]) 

    new 
szSteamId[32]
    
get_user_authid(idszSteamIdcharsmax(szSteamId)) 
    
    new 
Handle:Query SQL_PrepareQuery(MySQL_Connection"SELECT * FROM `%s` WHERE (`%s`.`steamid` = '%s') AND (`%s`.`weap` = '%s');"Table_WeapDataTable_WeapDataszSteamIdTable_WeapDataszConst
    
SQL_Execute(Query)
    
    if(
SQL_NumResults(Query) >= 1
        
g_iTempTrue[id] = true 
    
else 
        
g_iTempTrue[id] = false 

__________________
Retired.

Last edited by Xalus; 06-07-2014 at 05:31.
Xalus is offline
 



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 09:44.


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