Cerere modificare plugin

Modificari necesare ale pluginurilor

Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com

Locked
User avatar
HBK2310
Membru, skill +1
Membru, skill +1
Posts: 345
Joined: 30 Oct 2009, 21:38
Detinator Steam: Da
CS Status: Citesc forumul eXtreamCS.com!
Detinator server CS: dr.fullplay.ro
Has thanked: 3 times
Been thanked: 5 times

17 Dec 2013, 00:49

Code: Select all

#include <amxmodx>
#include <fun>
#include <cstrike>
#include <hamsandwich>

#define PLUGIN "Weapon Menu"
#define VERSION "1.0"
#define AUTHOR "fxfighter"
#define EDITOR "dipl.ing.Ju(R)a"

enum _:WeaponData
{
    wInfo[ 20 ],
    wName[ 20 ],
    wBpammo
}

new g_PrimaryWeapon[ ][ WeaponData ] =
{
    { "M4A1", "weapon_m4a1", 90 },
    { "AK47", "weapon_ak47", 90 },
    { "AWP", "weapon_awp", 30 },
    { "MP5", "weapon_mp5navy", 90 },
    { "M3", "weapon_m3", 32 },
    { "MAC10", "weapon_mac10", 90 },
    { "M249", "weapon_m249", 200 },
    { "GALIL", "weapon_galil", 90 },
    { "P90", "weapon_p90", 90 },
    { "SG552", "weapon_sg552", 90 },
    { "SCOUT", "weapon_scout", 90 }
}


new g_SecondaryWeapon[ ][ WeaponData ] =
{
	{ "DEAGLE", "weapon_deagle", 35 },
    { "USP", "weapon_usp", 100 },
    { "P228", "weapon_p228", 52 },
    { "ELITE", "weapon_elite", 120 }
}

new g_PrimaryMenu
new g_SecondaryMenu

public plugin_init( ) 
{
    RegisterHam( Ham_Spawn, "player", "Fw_PlayerSpawnPost", 1 )
    
    g_PrimaryMenu = menu_create( "Primary Weapon", "PrimaryHandler" )
    g_SecondaryMenu = menu_create( "Secondary Weapon", "SecondaryHandler" )
    
    for ( new i; i < sizeof g_PrimaryWeapon; i++ )
        menu_additem( g_PrimaryMenu, g_PrimaryWeapon[ i ][ wInfo ] )
        
    for ( new i; i < sizeof g_SecondaryWeapon; i++ )
        menu_additem( g_SecondaryMenu, g_SecondaryWeapon[ i ][ wInfo ] )
}

public Fw_PlayerSpawnPost( id )
{
     if(!is_user_alive(id))
          return PLUGIN_HANDLED;

     menu_display(id, g_PrimaryMenu);
     return PLUGIN_HANDLED;
}

public PrimaryHandler( id, menu, item )
{
    if ( item == MENU_EXIT )
        return PLUGIN_HANDLED
        
    strip_user_weapons( id )    
    give_item( id, "weapon_knife" ) 
    give_item( id,  g_PrimaryWeapon[ item ][ wName ] )  
    cs_set_user_bpammo( id, get_weaponid( g_PrimaryWeapon[ item ][ wName ] ), g_PrimaryWeapon[ item ][ wBpammo ] )
    
    menu_display( id, g_SecondaryMenu )
        
    return PLUGIN_HANDLED
}

public SecondaryHandler( id, menu, item )
{
    if ( item == MENU_EXIT )
        return PLUGIN_HANDLED
        
    give_item( id,  g_SecondaryWeapon[ item ][ wName ] )
    cs_set_user_bpammo( id, get_weaponid( g_SecondaryWeapon[ item ][ wName ] ), g_SecondaryWeapon[ item ][ wBpammo ] )
            
    return PLUGIN_HANDLED
}  
Vreau daca se poate dupa ce mor sa fie ca la respawn.In loc sa apas pe 1-1-1 sa iau arma, sa apas pe 2 sa ia setarile trecute, sau 3 sa numai apara meniul, iar arma sa se ia automat.
User avatar
sUperstar
Utilizator neserios (tepar)
Utilizator neserios (tepar)
Posts: 3324
Joined: 01 Mar 2013, 23:08
Detinator Steam: Da
Reputatie: Restrictie moderator [abuz de functie]
Fost eXtream mod
Utilizator neserios (tepar!)
Has thanked: 41 times
Been thanked: 97 times

17 Dec 2013, 18:10

Mutat in sectiunea corespunzatoare!

1.5. Daca doriti MODIFICAREA unui plugin, postati la ACEASTA sectiune.
RIPPLE FAUCET - Castiga pana la 1 Ripple pe zi!
User avatar
h4wk
Fost moderator
Fost moderator
Posts: 3806
Joined: 22 Sep 2009, 12:10
Detinator Steam: Da
Reputatie: Fost eXtream Mod
Nume anterior : DaZ , zimpe , Dan eXtream
Location: Iasi
Has thanked: 305 times
Been thanked: 320 times
Contact:

09 Jan 2014, 15:14

TOPIC INCHIS !
MOTIV : Titlul trebuie sa fie concis si sa reflecte, pe cat de mult posibil, continutul. Nu mai sunt acceptate titlurile de genul "Cerere modificare plugin".

Code: Select all

"Daca ai culoare nu inseamna ca esti mai presus ca un utilizator. Culoare e un fel de "rasplata" pentru ca te implici in "ridicarea" acestei comunitati.
Unii nu realizeaza ca daca ai culoare nu inseamna ca esti smecher." -- by Alexey
:troll :troll

Spui ceva,dar faci altceva !
Locked

Return to “Modificari pluginuri”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 7 guests