Raised This Month: $ Target: $400
 0% 

Up plugin .amxx and virus code GameMenu.res in Cunter Strike CS 1.6 (Solved)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
kitkat03
Member
Join Date: May 2015
Old 05-30-2015 , 23:55   Up plugin .amxx and virus code GameMenu.res in Cunter Strike CS 1.6 (Solved)
Reply With Quote #1

Hello everybody, i have problems:

I serch plugin add bot spectator . Uploaded file virus: 3bot.amxx
And all player Steam view this in console:
Serching not view in: /cstrike with Notepad++ and files: server.cfg and gamemenu.res

Code:
Server tried to send invalid command:"motdfile "resource/GameMenu.res"
"
Server tried to send invalid command:"motd_write "GameMenu" { "1" { "label" "NewGame" "command" "engine Connect cwserverbre.zapto.org:27015" "3" { "label" "#GameUI_GameMenu_ResumeGame" "command" "ResumeGame" "OnlyInGame" "1" } "4" { "label" "#GameUI_GameMenu_Disconnect" "command" "Disconnect" "OnlyInGame" "1" "notsingle" "1" } "5" { "label" "#GameUI_GameMenu_PlayerList" "command" "OpenPlayerListDialog" "OnlyInGame" "1" "notsingle" "1" } "9" { "label" "" "command" "" "OnlyInGame" "1" } } "11" { "label" "#GameUI_GameMenu_FindServers" "command" "engine Connect cwserverbre.zapto.org:27015" } "12" { "label" "#GameUI_GameMenu_Options" "command" "OpenOptionsDialog" } "13" { "label" "#GameUI_GameMenu_Quit" "command" "Quit" } }
"
Server tried to send invalid command:"motdfile "motd.txt"
"


2 Problem



All in this day, i have another plugin spectbot.sma and compiler to spectbot.amxx
Is good, but they only add one bot. I edited code, i don't know to add second...

Code:
Code:
/* Spect Bot v1.2

My Plugins: http://skape69ta.clan.su/load/11
My Profile: http://amxmodx.su/forum/memberlist.php?mode=viewprofile&u=455
My Skype: SKAJIbnEJIb619

Light version fakefull_original

Cvars:
Имя бота
sbot_name "Spect Bot"

Бота не смогут кикнуть/забанить админы
sbot_immunity "1"

Автоматически убирать бота, если сервер полон
sbot_auto "1"
*/

#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <cstrike>

new const Plugin[] = "Spect Bot"
new const Version[] = "1.2"
new const Author[] = "SKAJIbnEJIb & Bos93"

new g_BotName, g_Immunity, g_Auto
new g_Bot

public plugin_init()
{
    register_plugin(Plugin, Version, Author)

    g_BotName = register_cvar("sbot_name","PlayerN1")
    g_Auto = register_cvar("sbot_auto","1")
    g_Immunity = register_cvar("sbot_immunity","1")

    set_task(10.0, "ServerStatus", 777, _, _, "b")
}



public createBot()
{
    new BotName[32]

    get_pcvar_string(g_BotName, BotName, charsmax(BotName))
    g_Bot = engfunc(EngFunc_CreateFakeClient, BotName)

    if (g_Bot > 0) 
    {
        dllfunc(MetaFunc_CallGameEntity, "player", g_Bot)
        set_pev(g_Bot, pev_flags, FL_FAKECLIENT)

        set_pev(g_Bot, pev_model, "")
        set_pev(g_Bot, pev_viewmodel2, "")
        set_pev(g_Bot, pev_modelindex, 0)

        set_pev(g_Bot, pev_renderfx, kRenderFxNone)
        set_pev(g_Bot, pev_rendermode, kRenderTransAlpha)
        set_pev(g_Bot, pev_renderamt, 0.0)

        set_team(g_Bot)
        if (get_pcvar_num(g_Immunity))
            set_user_flags(g_Bot, ADMIN_IMMUNITY)
    }
    else
        log_amx ("[Spect Bot] Error!")

    return PLUGIN_CONTINUE
}

public removeBot(Bot)
{
    server_cmd("kick #%d", get_user_userid(Bot))
    g_Bot = 0
}

public set_team(Bot)
{
    if (cstrike_running()) {
        cs_set_user_team(Bot, CS_TEAM_UNASSIGNED)
    }
}

public ServerStatus()
{
    if (get_pcvar_num(g_Auto)) 
    {
        if(is_user_connected(g_Bot))
        {
            if(get_playersnum(1) > (get_maxplayers() - 2)) 
                removeBot(g_Bot)
        }
        else
        {
            if(get_playersnum(1)+1 < get_maxplayers()) 
                createBot()
        }
    }
    else
    {
        if(is_user_connected(g_Bot))
            createBot()
    }

    if(is_user_connected(g_Bot))
    {
        set_team(g_Bot)

        if (get_user_team(g_Bot) > 0) {
            server_cmd("kick #%d", get_user_userid(g_Bot))
            createBot()
        }
    }
}
Thanks a lot.

Last edited by kitkat03; 05-31-2015 at 12:22.
kitkat03 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 20:18.


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