Raised This Month: $ Target: $400
 0% 

Plugin error after steam update!


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
arenac4
Member
Join Date: Nov 2011
Old 03-10-2013 , 06:11   Plugin error after steam update!
Reply With Quote #1

Hello,

I get this error when I use command amx_ss and plugin doesn`t work anymore, this problem is since last steam update. This is a improved version of amx_ss plugin to discover players that use AntiSS, but the author is unknown.
What must be changed in .sma?
Error:
Code:
Server tried to send invalid command:"toggleconsole;snapshot;toggleconsole;wait;wait;kill
"
A signed screenshot has been executed on you by Admin HiT
Plugin source:
Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fakemeta>

#define PLUGIN "myforum.com Signed Screenshot"
#define VERSION "1.0"
#define AUTHOR "ThE_ChOSeN_OnE"

new _screen_hp[33]

public plugin_init(){
    register_plugin(PLUGIN, VERSION, AUTHOR);
    register_concmd("amx_ss","cmdScreen",ADMIN_KICK,"<nick or #userid> - Advanced screenshot with protection against Anti-SS")
}
public cmdScreen(id,level,cid){
    if(!cmd_access(id,level,cid,2)){
        return PLUGIN_HANDLED
    }
    new arg1[32],target,task[2],timestamp[32],name[32],name2[32],ip[32],str_host[32]
    read_argv(1,arg1,31)
    target = cmd_target(id,arg1,CMDTARGET_NO_BOTS | CMDTARGET_ALLOW_SELF | CMDTARGET_ONLY_ALIVE)
    if(!target) return PLUGIN_HANDLED
    if(task_exists(target+333131) || task_exists(target+333132)){
        client_print(id,print_console,"[myforum.com] %s is already being screenshoted",name2)
        return PLUGIN_HANDLED
    }
    get_time("%m/%d/%Y - %H:%M:%S",timestamp,31)
    get_user_name(id,name,31)
    get_user_name(target,name2,31)
    get_user_ip(target,ip,31,1)
    //format_for_steam(id,name)
    get_cvar_string("hostname",str_host,31)
    task[0] = target
    task[1] = id
    set_pev(target,pev_takedamage,DAMAGE_NO)
    _screen_hp[target] = pev(target,pev_health)
    set_pev(target, pev_health, 255.0)
    client_print(id,print_console,"[myforum.com] myforum.com Screenshot -> Nickname '%s' | IP '%s'",name2,ip)
    color_print(0,0,"!team[myforum.com] !ySigned screenshot taken on player !team%s !yby Admin !team%s",name2,name)
    color_print(0,target,"!teamServer: !g%s",str_host)
    color_print(0,target,"!teamName: !g%s !y- !teamIP: !g%s",name2,ip)
    color_print(0,target,"!yA signed screenshot has been executed on you by Admin !team%s",name)
    color_print(0,target,"!teamForum: !gwww.myforum.com")
    color_print(0,target,"!team[%s]",timestamp)
    client_print(target,print_console,"|____ myforum.com Screenshot ____|")
    client_print(target,print_console,"Server: %s",str_host)
    client_print(target,print_console,"Name: %s - IP: %s",name2,ip)
    client_print(target,print_console,"A signed screenshot has been executed on you by Admin %s",name)
    client_print(target,print_console,"Post the screenshot on our forum!",name)
    client_print(target,print_console,"Forum: www.myforum.com")
    client_cmd(target,"stop")
    set_task(0.1,"screen_sign",target+333131,task,2)
    set_task(1.0,"screen_sign_remove",target+333132,task,1)
    log_amx("[www.myforum.com] Signed screenshot taken on player %s by Admin %s",name2,name)
    return PLUGIN_HANDLED
}
public screen_sign(task[2]){
    new target,admin
    target = task[0]; admin = task[1]
    if(!is_user_connected(target) || !is_user_connected(admin)){
        return PLUGIN_HANDLED
    }
    client_cmd(target,"toggleconsole;snapshot;toggleconsole;wait;wait;kill")
    cs_set_user_team(target,CS_TEAM_SPECTATOR)
    return PLUGIN_CONTINUE
}
public screen_sign_remove(task[1]){
    new target
    target = task[0]
    if(!is_user_connected(target)){
        return PLUGIN_HANDLED
    }
    set_pev(target,pev_health,float(_screen_hp[target]))
    set_pev(target,pev_takedamage,DAMAGE_AIM)    
    color_print(0,target,"!team_ End of Screenshot _")
    return PLUGIN_CONTINUE
}

stock color_print(admin=0,const id,const input[],any:...){
    new count = 1,players[32]
    new msg[191]
    vformat(msg,190,input,4)
    replace_all(msg,190,"!g","^4")
    replace_all(msg,190,"!y","^1")
    replace_all(msg,190,"!team","^3")
    if(id) players[0] = id; else get_players(players,count,"ch");{
        for(new i=0; i < count; i++){
            if(is_user_connected(players[i])){
                if(admin==1 && !is_user_admin(players[i]))
                    continue;
                message_begin(MSG_ONE_UNRELIABLE,get_user_msgid("SayText"),_,players[i])  
                write_byte(players[i])
                write_string(msg)
                message_end()
            }
        }
    }
}

Last edited by arenac4; 03-10-2013 at 10:14.
arenac4 is offline
jimaway
Heeeere's Jimmy!
Join Date: Jan 2009
Location: Estonia
Old 03-10-2013 , 07:05   Re: Plugin error after steam update!
Reply With Quote #2

it can't be fixed, most of commands sent by server are now blocked
jimaway is offline
arenac4
Member
Join Date: Nov 2011
Old 03-10-2013 , 07:41   Re: Plugin error after steam update!
Reply With Quote #3

I found on google that valve restricted "kill" command, help me please to recode this plugin using "user_kill"

Thanks a lot!

Something like this I think

Code:
user_kill(target,1);
cs_set_user_team(target,CS_TEAM_SPECTATOR);

Last edited by arenac4; 03-10-2013 at 10:10.
arenac4 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 21:35.


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