Raised This Month: $ Target: $400
 0% 

[REQ]removing cafe accounts.....


Post New Thread Reply   
 
Thread Tools Display Modes
sirmoe
Senior Member
Join Date: Mar 2008
Old 05-05-2008 , 19:37   Re: [REQ]removing cafe accounts.....
Reply With Quote #31

Bump, this would be a extremely helpful plugin to have complete
sirmoe is offline
sirmoe
Senior Member
Join Date: Mar 2008
Old 05-10-2008 , 02:11   Re: [REQ]removing cafe accounts.....
Reply With Quote #32

bump bump
sirmoe is offline
V0gelz
Senior Member
Join Date: Jun 2004
Old 05-13-2008 , 11:21   Re: [REQ]removing cafe accounts.....
Reply With Quote #33

ask the asker of the plugin, he maybe can help.
__________________
V0gelz is offline
siosios
SourceMod Donor
Join Date: Jan 2008
Old 05-13-2008 , 18:00   Re: [REQ]removing cafe accounts.....
Reply With Quote #34

i havent gotten any further then it was on the last edit and asked for some pointers on adding a whitelist.cfg/removal.cfg to it to no avail.
siosios is offline
p3tsin
Senior Member
Join Date: Sep 2005
Location: Finland
Old 05-16-2008 , 20:22   Re: [REQ]removing cafe accounts.....
Reply With Quote #35

Fine!

Code:
#include <sourcemod> public Plugin:myinfo = {     name = "Anti Café",     author = "p3tsin",     description = "Anti Café",     version = "1.0.0.0",     url = "" } new String:g_szWhiteListFile[PLATFORM_MAX_PATH] new Handle:g_hWhiteList = INVALID_HANDLE public OnPluginStart() {     BuildPath(Path_SM,g_szWhiteListFile,sizeof g_szWhiteListFile,"configs/anticafe_whitelist.txt") } public OnMapStart() {     if(g_hWhiteList != INVALID_HANDLE) {         CloseHandle(g_hWhiteList)     }     g_hWhiteList = CreateArray(64)     decl Handle:file     if(!FileExists(g_szWhiteListFile)) {         file = OpenFile(g_szWhiteListFile,"wt")         if(file != INVALID_HANDLE) {             WriteFileLine(file,"; List below SteamIDs starting with 777 or 775 that are known not to be cafe accounts.\n")             CloseHandle(file)         }         return     }     file = OpenFile(g_szWhiteListFile,"rt")     if(file != INVALID_HANDLE) {         decl String:data[128], String:steamid[64], len         while(!IsEndOfFile(file) && ReadFileLine(file,data,sizeof data)) {             if(data[0] == ';') {                 continue             }             len = strlen(data)             if(data[len - 1] == '\n') {                 data[--len] = 0             }             if(!len) {                 continue             }             BreakString(data,steamid,sizeof steamid)             if(strncmp(steamid,"STEAM_",6) == 0) {                 PushArrayString(g_hWhiteList,steamid)             }         }         CloseHandle(file)     } } public OnClientAuthorized(client,const String:authid[]) {     //if the SteamID is 7 digits long and the first 3 characters equal "777" or "775"     if(strlen(authid[10]) == 7 && (strncmp(authid[10],"777",3) == 0) || (strncmp(authid[10],"775",3) == 0)) {         if(FindStringInArray(g_hWhiteList,authid) == -1) {             PrintToChatAll("Player %N with SteamID %s has been kicked because of a cafe account. If you would like to be whitelisted please post at www.n00bunlimited.net",client,authid)             ServerCommand("kickid %d \"sorry, no cafe accounts allowed here\"",GetClientUserId(client))         }         else {             PrintToChatAll("Player %N with SteamID %s has been allowed to play here.",client,authid)         }     } }

Untested. List clean SteamIDs in addons/sourcemod/configs/anticafe_whitelist.txt (created if doesnt exist), type in complete IDs and not just the number part.
__________________
plop
p3tsin is offline
siosios
SourceMod Donor
Join Date: Jan 2008
Old 05-17-2008 , 01:15   Re: [REQ]removing cafe accounts.....
Reply With Quote #36

thanks for that.

below is my latest edit of the old code with some new cafe accounts ive had trouble with. (for anyone interested)

7595478
7493810
7573912
7573899
7782733
7265891
7741832


Code:
#define PLUGIN_VERSION "0.1"
 
public Plugin:myinfo = {
    name = "Anti Café",
    author = "V0gelz",
    description = "Anti Café",
    version = PLUGIN_VERSION,
    url = ""
};
 
public OnClientAuthorized(client, const String:authid[]){
//if the SteamID is 8 digits long and the first 3 characters equal "157" or "156"
    if(strlen(authid[10]) == 7 && (strncmp(authid[10], "777", 3)== 0) || (strncmp(authid[10], "775", 3) == 0) || (strncmp(authid[10], "774", 3) == 0) || (strncmp(authid[10], "759", 3) == 0) || (strncmp(authid[10], "757", 3) == 0) || (strncmp(authid[10], "749", 3) == 0) || (strncmp(authid[10], "778", 3) == 0) || (strncmp(authid[10], "726", 3) == 0))
{
        // Here you can add or remove the cafe account steamids you allow on the server.
        if( StrEqual(authid[10], "7750865") || StrEqual(authid[10], "12345678"))
        {
            PrintToServer("Player: %N with Steamid: %s has been allowed to play here.",client,authid);
        }
        else
        {
            ServerCommand("kickid %d", GetClientUserId(client));
            PrintToServer("Player: %N with Steamid: %s  has been kicked because of a cafe account. if you would like to be whitelisted please post at www.n00bunlimited.net",client,authid);
        }
    }
}

ill test the whitelist version tonight and see how it holds up. one question are the white listed id's put in one line after another or are the ; seperated?

EDIT: never mind after reading the code i see you have it reading one line at a time

thanks again
siosios

Last edited by siosios; 05-17-2008 at 01:32.
siosios is offline
siosios
SourceMod Donor
Join Date: Jan 2008
Old 05-17-2008 , 20:10   Re: [REQ]removing cafe accounts.....
Reply With Quote #37

Quote:
Originally Posted by p3tsin View Post
Fine!


Code:
Code:
#include <sourcemod>

public Plugin:myinfo = {
    name = "Anti Café",
    author = "p3tsin",
    description = "Anti Café",
    version = "1.0.0.0",
    url = ""
}


new String:g_szWhiteListFile[PLATFORM_MAX_PATH]
new Handle:g_hWhiteList = INVALID_HANDLE

public OnPluginStart() {
    BuildPath(Path_SM,g_szWhiteListFile,sizeof g_szWhiteListFile,"configs/anticafe_whitelist.txt")
}

public OnMapStart() {
    if(g_hWhiteList != INVALID_HANDLE) {
        CloseHandle(g_hWhiteList)
    }

    g_hWhiteList = CreateArray(64)

    decl Handle:file

    if(!FileExists(g_szWhiteListFile)) {
        file = OpenFile(g_szWhiteListFile,"wt")

        if(file != INVALID_HANDLE) {
            WriteFileLine(file,"; List below SteamIDs starting with 777 or 775 that are known not to be cafe accounts.\n")
            CloseHandle(file)
        }

        return
    }

    file = OpenFile(g_szWhiteListFile,"rt")

    if(file != INVALID_HANDLE) {
        decl String:data[128], String:steamid[64], len

        while(!IsEndOfFile(file) && ReadFileLine(file,data,sizeof data)) {
            if(data[0] == ';') {
                continue
            }

            len = strlen(data)

            if(data[len - 1] == '\n') {
                data[--len] = 0
            }

            if(!len) {
                continue
            }

            BreakString(data,steamid,sizeof steamid)

            if(strncmp(steamid,"STEAM_",6) == 0) {
                PushArrayString(g_hWhiteList,steamid)
            }
        }

        CloseHandle(file)
    }
}

public OnClientAuthorized(client,const String:authid[]) {
    //if the SteamID is 7 digits long and the first 3 characters equal "777" or "775"
    if(strlen(authid[10]) == 7 && (strncmp(authid[10],"777",3) == 0) || (strncmp(authid[10],"775",3) == 0)) {
        if(FindStringInArray(g_hWhiteList,authid) == -1) {
            PrintToChatAll("Player %N with SteamID %s has been kicked because of a cafe account. If you would like to be whitelisted please post at www.n00bunlimited.net",client,authid)
            ServerCommand("kickid %d \"sorry, no cafe accounts allowed here\"",GetClientUserId(client))
        }
        else {
            PrintToChatAll("Player %N with SteamID %s has been allowed to play here.",client,authid)
        }
    }
}


Untested. List clean SteamIDs in addons/sourcemod/configs/anticafe_whitelist.txt (created if doesnt exist), type in complete IDs and not just the number part.
this build works flawlessly and if anyone is using the old i recommend upgrading to this one for the whitelist.

only dowfall is still adding the cafe id's into the source code but i can live with that.

thanks again
siosios
siosios is offline
sirmoe
Senior Member
Join Date: Mar 2008
Old 05-21-2008 , 04:55   Re: [REQ]removing cafe accounts.....
Reply With Quote #38

The above blocks all 777 and 775 steamids cafe or not, why not get it to only block the cafe id's in that range by adding a lookup function if id = 777/775 then look up number of games. If Games = greater then 100 then block else allow.
sirmoe is offline
WaLLy3K
Junior Member
Join Date: May 2008
Location: Queensland, Australia.
Old 05-22-2008 , 20:01   Re: [REQ]removing cafe accounts.....
Reply With Quote #39

Found this thread and I have something very interesting.

I have narrowed down common cheat ranges over 25 servers that I (help) operate:
  • STEAM_0:*:725*
  • STEAM_0:*:746*
  • STEAM_0:*:747*
  • STEAM_0:*:748*
  • STEAM_0:*:749*
  • STEAM_0:*:757*
  • STEAM_0:*:758*
  • STEAM_0:*:759*
  • STEAM_0:*:774*
  • STEAM_0:*:775*
  • STEAM_0:*:776*
  • STEAM_0:*:777*
  • STEAM_0:*:778*
However, I don't quite like this method. I have a script that is able to almost accurately detect cafe accounts. There is no pattern matcher though, so I probably shouldn't post up the banlist that I made using the script.
__________________


Last edited by WaLLy3K; 05-23-2008 at 11:26.
WaLLy3K is offline
Send a message via MSN to WaLLy3K
siosios
SourceMod Donor
Join Date: Jan 2008
Old 05-23-2008 , 15:42   Re: [REQ]removing cafe accounts.....
Reply With Quote #40

well its not my preferred way of removing cafe accounts but i have had less problems since i introduced this plugin onto my servers. yes non steam cafe accounts do get kicked but the message added simply asks them to come to my forums and ask to be whitelisted in which a few have.

if someone has a better way of doing it other then what was requested here then by all means please tell us.

thanks
siosios
siosios 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 19:09.


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