Help - Search - Members - Calendar
Full Version: Amx_restrict
Forum 17B > Counter Strike 1.6 > General discussion
spy-warrior
bonsoir

je recherche pour avoir la commande amx_restrict dans les cvar de amx

http://wiki.amxmodx.org/Configuring_AMX_Mod_X#CVARs_2

amx_restrict on/off ak47

c'est pour les VIPs du serveur

merci
DokTor
Je crois que tu as déjà eu ta réponse sur AM mais dans le doute :

edite le droit admin pour cette commande en la cherchant dans le fichier addons\amxmodx\configs\cmdaccess.ini
spy-warrior
QUOTE (DokTor @ 24/07/2010 - 20:03:24) *
Je crois que tu as déjà eu ta réponse sur AM mais dans le doute :

edite le droit admin pour cette commande en la cherchant dans le fichier addons\amxmodx\configs\cmdaccess.ini


merci c'est bien sa https://forums.alliedmods.net/showthread.php?t=133026

CODE
amx_restrict on ak47
amx_restrict off ak47


toujours pas trouver pour:

je recherche pour avoir la commande mp_startmoney
avec 16000$ dans le shop pour tous les joueurs
DokTor
QUOTE (spy-warrior @ 28/07/2010 - 11:25:47) *
je recherche pour avoir la commande mp_startmoney
avec 16000$ dans le shop pour tous les joueurs


Bah tu fous soit dans server.cfg, soit dans game.cfg, soit dans amx.cfg, la variable :

mp_startmoney 16000

C'est pas compliqué.

server.cfg : exécuté au boot du serveur, éventuellement à chaque chargement de map si la variable mapchangecfgfile est renseignée sur "server.cfg"

game.cfg (à créer au même endroit que server.cfg) est exécuté à chaque chargement de map

amxx.cfg est exécuté 6.3sec après chaque début de map.
spy-warrior
bonsoir
je parle pour avoir toujours les 1600$ au début du rond tous le temps
j'ai vue un plugin amx pour le faire sont nom est (unlimited Ammo)
j'ai pas testé
DokTor
J'utilise ça, ça calque l'argent de début de round sur la variable mp_startmoney :

CODE
/*    Copyright © 2008, ConnorMcLeod

    Round StartMoney is free software;
    you can redistribute it and/or modify it under the terms of the
    GNU General Public License as published by the Free Software Foundation.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Round StartMoney; if not, write to the
    Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.
*/

#include <amxmodx>
#include <fakemeta>

#define VERSION "0.4.0"

#define Money_Amount    1

#define XTRA_OFS_PLAYER    5
#define m_iAccount        115

new g_pCvarStartMoney, g_iStartMoney, gmsgMoney, g_iMhMoney, Float:g_flRoundStartGameTime

public plugin_init()
{
    register_plugin( "Round StartMoney", VERSION, "ConnorMcLeod" )

    register_event("HLTV", "Event_HLTV_New_Round", "a", "1=0", "2=0")

    g_pCvarStartMoney = get_cvar_pointer("mp_startmoney")
    gmsgMoney = get_user_msgid("Money")
}

public Event_HLTV_New_Round()
{
    g_flRoundStartGameTime = get_gametime()
    g_iStartMoney = get_pcvar_num(g_pCvarStartMoney)
    SetMoneyHookStatus( true )
}

public Message_Money(iMsgId, iMsgDest, id)
{
    if( get_gametime() != g_flRoundStartGameTime )
    {
        SetMoneyHookStatus( false )
        return
    }

    new iAmount = get_msg_arg_int(Money_Amount)
    if( iAmount && iAmount < g_iStartMoney )
    {
        set_pdata_int(id, m_iAccount, g_iStartMoney, XTRA_OFS_PLAYER)
        set_msg_arg_int(Money_Amount, ARG_LONG, g_iStartMoney)
    }
}

SetMoneyHookStatus( bool:bActive )
{
    if( bActive )
    {
        if( !g_iMhMoney )
        {
            static const szCallBack[] = "Message_Money"
            g_iMhMoney = register_message(gmsgMoney, szCallBack)
        }
    }
    else
    {
        if( g_iMhMoney )
        {
            unregister_message(gmsgMoney, g_iMhMoney)
            g_iMhMoney = 0
        }
    }
}
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2024 Invision Power Services, Inc.