Raised This Month: $ Target: $400
 0% 

fm_give_item


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
minimiller
Veteran Member
Join Date: Aug 2007
Location: United Kingdom
Old 05-21-2009 , 09:01   Re: fm_give_item
Reply With Quote #4

try this
PHP Code:
/*-----------------------------------------------------------------------------------------------------------------------*/
/*  Script forged by Stewie!                                                                                             */
/*---------------------------------------------------------------------------------------------------------=[ Stewie! ]=-*/

#pragma semicolon 1;

#include <amxmodx>
#include <amxmisc>
#include <fakemeta_util>
#include <hamsandwich>

new PLUG[] = "";
new 
VERS[] = "1.0";
new 
AUTH[] = "Stewie!";

public 
plugin_init()
{
    
register_plugin(PLUGVERSAUTH);
    
register_cvar(PLUGVERSFCVAR_SERVER);

    
RegisterHam(Ham_Spawn"player""player_spawn"1);
}

public 
player_spawn(id)
{
    if(
is_user_alive(id))
    {
        
fm_strip_user_weapons(id);
        
        for(new 
i=1i<get_playersnum(); i++)
        {
            if(
get_user_team(id) == 1//T
            
{
                
fm_give_item(id"weapon_knife");
                
fm_give_item(id"weapon_glock");
            }
            else if(
get_user_team(id) == 2//CT
            
{
                
fm_give_item(id"weapon_knife");
                
fm_give_item(id"weapon_usp");
            }
        }
    }
    
    
give_bomb(random_num(0,get_playersnum()));
    return 
HAM_HANDLED;
}

public 
give_bomb(id)
{
    if(
get_user_team(id) == 2)
    {
        
fm_give_item(id"weapon_c4");
    }
    else
    {
        
give_bomb(random_num(0,get_playersnum()));
    }
    return 
PLUGIN_CONTINUE;

__________________
minimiller is offline
Send a message via MSN to minimiller
 



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 01:29.


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