Raised This Month: $ Target: $400
 0% 

Anty Cheater


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
raizo11
BANNED
Join Date: Dec 2013
Location: https://t.me/pump_upp
Old 06-16-2018 , 05:22   Re: Anty Cheater
Reply With Quote #1

Code:
#include <amxmodx>
#include <amxmisc>
#include <fvault>

#define pluginprefix "[ Knife Protection ]"

new const plugininfo[ ][ ] = {
   "Anti OstroG",
   "1.0",
   "raizo"
}

new const g_vaultname[ ] = "antisteamidchanger";

new steamidchange_logs[ 54 ];

public plugin_init() {
   register_plugin(plugininfo[ 0 ], plugininfo[ 1 ], plugininfo[ 2 ]);
   
   mkdir("addons/amxmodx/logs/steamidchanger");
   format(steamidchange_logs, charsmax(steamidchange_logs), "addons/amxmodx/logs/steamidchanger/steamidchanger.log", steamidchange_logs);
}

public client_connect(client) {
   new szdata[ 35 ];
   if(fvault_get_data(g_vaultname, user_ip(client), szdata, charsmax(szdata))) {
      loadcmd(client);
      if(!equal(user_authid(client), szdata)) {
         kickuser(client);
         return PLUGIN_HANDLED
      }
   }
   else if(!fvault_get_data(g_vaultname, user_ip(client), szdata, charsmax(szdata))) {
      savecmd(client);
      loadcmd(client);
   }
   return PLUGIN_CONTINUE
}

stock kickuser(const index) {
   new szdata[ 35 ];
   
   fvault_get_data(g_vaultname, user_ip(index), szdata, charsmax(szdata));
   
   client_print(index, print_chat, "%s Use Steam Id Changer , Disable Ct-Shield And Join After!", pluginprefix);
   server_cmd("kick #%d ^"%s Steam Id Changer Detected , Enable First Steam Id And Connect  , First Steam Id Is : %s.^"", get_user_userid(index), pluginprefix, szdata);
   log_to_file(steamidchange_logs, "Steam Id Changer Detected Player %s .", user_ip(index));
}

stock user_authid(const index) {
   new authid[ 35 ];
   get_user_authid(index, authid, charsmax(authid));
   return authid;
}

stock user_ip(const index) {
   new ip[ 35 ];
   get_user_ip(index, ip, charsmax(ip), 1);
   return ip;
}

stock savecmd(const index) {
   fvault_set_data(g_vaultname, user_ip(index), user_authid(index));
}

stock loadcmd(const index) {
   fvault_get_data(g_vaultname, user_ip(index), user_authid(index), 34);
}
raizo11 is offline
Send a message via ICQ to raizo11 Send a message via AIM to raizo11 Send a message via MSN to raizo11 Send a message via Yahoo to raizo11 Send a message via Skype™ to raizo11
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 04:37.


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