Raised This Month: $ Target: $400
 0% 

Solved Is User Steam ?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
MagNNusS
Member
Join Date: May 2018
Location: World of Bushi
Old 11-17-2018 , 08:35   Is User Steam ?
Reply With Quote #1

Greetings AlliedModders.
I was looking for some codes that support's steam player's.
But the problem is i founded several codes. And I don't really know which of them works correctly or it's coded good.
I tested some of them, they worked as I thought.
If someone explain witch code can be used and why, i would be really happy.

Codes:
PHP Code:
stock bool:is_user_steam(id
{
        new 
auth[65]
        
get_user_authid(id,auth,64)
        if(
contain(auth"STEAM_0:0:") != -|| contain(auth"STEAM_0:1:") != -1)
        return 
true;
        return 
false;

PHP Code:
stock bool:is_user_steam(id)
{
    static 
dp_pointer
    
if(dp_pointer || (dp_pointer get_cvar_pointer("dp_r_id_provider")))
    {
        
server_cmd("dp_clientinfo %d"id)
        
server_exec()
        return (
get_pcvar_num(dp_pointer) == 2) ? true false
    
}
    return 
false

PHP Code:
stock bool:is_steam(auth[]) 
{
    if(
contain(auth"STEAM_0:0:") != -|| contain(auth"STEAM_0:1:") != -1)
        return 
true;

    return 
false;

PHP Code:
stock bool:is_user_steam(id)
{
        new 
authid[32]; 
        
get_user_authid(idauthid31);
        return 
containi(authid ":") != -true false;

PHP Code:
stock bool:is_steam(auth[]) 
{

    return 
bool:(contain(auth"STEAM_0:0:") != -|| contain(auth"STEAM_0:1:") != -1);

PHP Code:
stock bool:is_user_steam(id)
{
    if(!
is_user_connected(id) || is_user_bot(id) || is_user_hltv(id))
    {
        return -
1;
    }
    
    new 
pos;
    new 
authid[64];
    
get_user_authid(id,authid,63)
    
    if((
pos containi(authid,"VALVE_")) != -|| (pos containi(authid,"ID_LAN")) != -|| (pos containi(authid,"ID_PENDING")) != -|| equal(authid,"STEAM_666:88:666") || (pos containi(authid,"HLTV")) != -)
    {
        return 
false;
    }
    
    new 
ip[64]
    
get_user_ip(id,ip,63,1)
    
    if((
pos containi(authid,ip)) != -)
    {
        return 
false;
    }
    return 
true;

__________________
Just an impractical signature
nothing to see here.

Last edited by MagNNusS; 11-19-2018 at 16:00. Reason: Solved.
MagNNusS 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 07:40.


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