Cerere plugin: Shop [JB].

Categoria cu cereri de pluginuri si nu numai.

Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com

Forum rules
Accesează link-ul pentru a putea vedea regulile forumului

Daca doriti sa vi se modifice un plugin, va rugam postati aici .
Post Reply
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

26 Nov 2013, 09:56

Salut, am și eu mare nevoie de un shop pentru T. Shop-ul să conțină:

250HP - 8000$.
Viteză (450) - 12000$.
Gravitație (650) - 8000$.
Rangă (cuțit care ia 200HP din prima) - 10000$.
NoClip pentru 5 secunde - 16000$.
Rapidserver
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

27 Nov 2013, 10:59

Sus! :D
User avatar
eNd.
Membru, skill +1
Membru, skill +1
Posts: 236
Joined: 19 Jan 2013, 21:18
Detinator Steam: Da
CS Status: Whoa...
SteamID: skitaila03
Has thanked: 18 times
Been thanked: 79 times

27 Nov 2013, 12:20

Poftim , nu ti-am pus si lang ca nu am avut timp....
Sper ca e ceea ce vrei.
| Afiseaza codul
[code]/* Plugin generated by AMXX-Studio */

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

#pragma semicolon 1
#define MAX_PLAYERS 32

static const Author[ ] = "eNd.";
static const Plugin[ ] = "Name";
static const TAG[ ] = "[JB]";
enum _: g_Cvars
{
	cvar_health_cost,
	cvar_speed_cost,
	cvar_gravity_cost,
	cvar_knife_cost,
	cvar_noclip_cost,
	cvar_health_amount,
	cvar_speed_amount,
	cvar_gravity_amount,
	cvar_damage_amount,
	cvar_time_amount,
	cvar_max_use
}
new \
	g_AllCvars	[ g_Cvars ] 		,
	g_UseTime	[MAX_PLAYERS + 1][6]	,
	g_Ability	[MAX_PLAYERS + 1][3]	;

new const CrowbarModels[][] = { "models/p_crowbar.mdl", "models/v_crowbar.mdl" };

public plugin_init() {
   	register_plugin(Plugin, "0.1", Author);
   
   	register_dictionary("jailbreak.txt");
   
   	register_clcmd("say","hook_say");
   	register_clcmd("say_team","hook_say");
   
   	RegisterHam(Ham_Spawn, "player", "Player_Spawn", 1);
	RegisterHam(Ham_TakeDamage, "player", "Player_Damage");
	register_event("CurWeapon", "CurWeapon", "be", "1=1");

}
public plugin_precache()
{
	g_AllCvars[ cvar_health_cost ] = register_cvar("shop_health_cost", "8000");
	g_AllCvars[ cvar_speed_cost ] = register_cvar("shop_speed_cost", "12000");
	g_AllCvars[ cvar_gravity_cost ] = register_cvar("shop_gravity_cost", "8000");
	g_AllCvars[ cvar_knife_cost ] = register_cvar("shop_knife_cost", "10000");
	g_AllCvars[ cvar_noclip_cost ] = register_cvar("shop_noclip_cost", "16000");
	
	g_AllCvars[ cvar_health_amount ] = register_cvar("shop_health_amount", "150");
	g_AllCvars[ cvar_speed_amount ] = register_cvar("shop_speed_amount", "200");
	g_AllCvars[ cvar_gravity_amount ] = register_cvar("shop_gravity_amount", "650:800");
	g_AllCvars[ cvar_damage_amount ] = register_cvar("shop_damage_amount", "200");
	g_AllCvars[ cvar_time_amount ] = register_cvar("shop_time_amount", "5");
	g_AllCvars[ cvar_max_use ] = register_cvar("shop_max_use", "1");

	static i;
	for(i = 0; i < sizeof(CrowbarModels); i++)
		precache_model(CrowbarModels);
}

public Player_Spawn(const iPlayer)
{
	if( is_user_alive( iPlayer ) )
	{
		g_UseTime[iPlayer][1] = 0;
		g_UseTime[iPlayer][2] = 0;
		g_UseTime[iPlayer][3] = 0;
		g_UseTime[iPlayer][4] = 0;
		g_UseTime[iPlayer][5] = 0;
		g_Ability[iPlayer][1] = 0;
		g_Ability[iPlayer][2] = 0;

	}
	return PLUGIN_HANDLED;
}
public CurWeapon(id)
{
	new szWeapon = get_user_weapon( id );

	if(is_user_alive( id ))
	{

		if(g_Ability[1][id] )
		{
				
			new iSpeed = get_pcvar_num(g_AllCvars[cvar_speed_amount]); 
			set_user_maxspeed( id , get_user_maxspeed( id ) + iSpeed);
		}
	
		if(szWeapon == CSW_KNIFE && g_Ability[2][id] )
		{
			set_pev( id , pev_viewmodel2, CrowbarModels[1]);
			set_pev( id , pev_weaponmodel2, CrowbarModels[0]);
		}
			
	}
	return PLUGIN_HANDLED;   
}
public Player_Damage(iVictim, iInflictor, iAttacker, Float:fDamage, iDamageBits )
{
	if(is_user_alive(iAttacker))
	{
		if(g_Ability[2][iAttacker] && iInflictor == iAttacker && get_user_weapon(iAttacker) == CSW_KNIFE)
		{
			new iDmg = get_pcvar_num(g_AllCvars[cvar_damage_amount]); 
			SetHamParamFloat( 4, fDamage + iDmg);
		}
	}
}
public hook_say(id)
{
   static szArg[192];
   
   read_args(szArg, sizeof(szArg) - 1);
   
   remove_quotes(szArg);

   if( equal( szArg, "/shop", 5) )
   {         
	if( !is_user_alive( id ) )
	{	
		ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_CANT_BUY");
		return PLUGIN_HANDLED;
	}
	switch( cs_get_user_team( id ) )
      	{
		case CS_TEAM_CT:
		{
			ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_CANT_BUY");
			return PLUGIN_HANDLED;
		}

		case CS_TEAM_T:
		{
			replace( szArg , sizeof( szArg ) - 1, "/", "" );
      			set_task(1.0, "Shop_Task", id);
		}
	}

   }
   
   return PLUGIN_CONTINUE;
}

#define g_dShop 5
static const g_iShop[g_dShop][] =
{
   "SHOP_MENU_1",
   "SHOP_MENU_2",
   "SHOP_MENU_3",
   "SHOP_MENU_4",
   "SHOP_MENU_5"
};

public Shop_Task(id)
{
   new szText[256];
   formatex(szText, charsmax(szText), "%L", LANG_SERVER, "SHOP_TITLE");
   new iShop = menu_create(szText, "Shop_submenu");
   
   new iNumber[5], szOption[40];
   for( new i = 0; i < g_dShop; i++ ) {
      num_to_str(i+1, iNumber, 4);
      formatex(szOption, 39, "%L", LANG_SERVER, g_iShop);
      menu_additem(iShop, szOption, iNumber);
   }
   
   menu_setprop(iShop ,MPROP_EXIT, MEXIT_NEVER);
   menu_display(id, iShop, 0);
   
   return PLUGIN_HANDLED;
}
public Shop_submenu(id, iShop, item)
{
   	if(item == MENU_EXIT)
   	{
      		menu_destroy(iShop);
      		return PLUGIN_HANDLED;
   	}
	new iMoney = cs_get_user_money(id);
	new iHealth  = get_pcvar_num(g_AllCvars[cvar_health_cost]);
	new iSpeed  = get_pcvar_num(g_AllCvars[cvar_speed_cost]);
	new iGravity  = get_pcvar_num(g_AllCvars[cvar_gravity_cost]);
	new iKnife  = get_pcvar_num(g_AllCvars[cvar_knife_cost]);
	new iNoclip  = get_pcvar_num(g_AllCvars[cvar_noclip_cost]);
	new iUse  = get_pcvar_num(g_AllCvars[cvar_max_use]);
   	new data[7], name[64];
   	new access, callback;
   	menu_item_getinfo(iShop, item, access, data, charsmax(data), name, charsmax(name), callback);
   
   	new key = str_to_num(data);
   	switch(key)
   	{
      		case 1:
      		{
			if(g_UseTime[ id ] [ 1 ] < iUse)
			{
				if((iMoney-iHealth) < 0)
				{
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_NO_MONEY");
					return PLUGIN_HANDLED;
				}
				else
				{
					new iHealthA = get_pcvar_num(g_AllCvars[cvar_health_amount]); 
					g_UseTime[id][1] ++;
					cs_set_user_money( id, iMoney );
					set_user_health(id, get_user_health(id) + iHealthA);
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_BUYED_HP");
				}
			}
			else if(g_UseTime[ id ] [ 1 ] == iUse)
			{
				
				ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), iUse, LANG_SERVER, "SHOP_MAX_USE");
				return PLUGIN_HANDLED;
				
			}
      		}
      		case 2:
      		{
			if(g_UseTime[ id ] [ 2 ] < iUse)
			{
				if((iMoney-iSpeed) < 0)
				{
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_NO_MONEY");
					return PLUGIN_HANDLED;
				}
				else
				{
					new iSpeedA = get_pcvar_num(g_AllCvars[cvar_speed_amount]); 
					g_UseTime[id][2] ++;
					g_Ability[id][1] = 1;
					cs_set_user_money( id, iMoney );
					set_user_maxspeed(id, get_user_maxspeed(id) + iSpeedA);
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_BUYED_SPEED");
				}
			}
			else if(g_UseTime[ id ] [ 2 ] == iUse)
			{
				
				ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), iUse, LANG_SERVER, "SHOP_MAX_USE");
				return PLUGIN_HANDLED;
				
			}
		
		}
      		case 3:
      		{
			if(g_UseTime[ id ] [ 3 ] < iUse)
			{
				if((iMoney-iGravity) < 0)
				{
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_NO_MONEY");
					return PLUGIN_HANDLED;
				}
				else
				{

					g_UseTime[id][3] ++;
					cs_set_user_money( id, iMoney );
					set_user_gravity(id, get_pcvar_float(g_AllCvars[cvar_gravity_amount]));
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_BUYED_GRAVITY");
				}
      			}
			else if(g_UseTime[ id ] [ 3 ] == iUse)
			{
				
				ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), iUse, LANG_SERVER, "SHOP_MAX_USE");
				return PLUGIN_HANDLED;
				
			}
		}
      		case 4:
      		{
			if(g_UseTime[ id ] [ 4 ] < iUse)
			{
				if((iMoney-iKnife) < 0)
				{
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_NO_MONEY");
					return PLUGIN_HANDLED;
				}
				else
				{
					g_UseTime[id][4] ++;
					cs_set_user_money( id, iMoney );
					g_Ability[id][2] = 1;
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_BUYED_CROWBAR");
				}
			}
			else if(g_UseTime[ id ] [ 4 ] == iUse)
			{
				
				ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), iUse, LANG_SERVER, "SHOP_MAX_USE");
				return PLUGIN_HANDLED;
				
			}
		}
      		case 5:
      		{
			if(g_UseTime[ id ] [ 5 ] < iUse)
			{
				if((iMoney-iNoclip) < 0)
				{
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_NO_MONEY");
					return PLUGIN_HANDLED;
				}
				else
				{
					g_UseTime[id][5] ++;
					cs_set_user_money( id, iMoney );
					set_user_noclip(id , 1);
					set_task(get_pcvar_float(g_AllCvars[cvar_time_amount]), "remove_noclip", id);
					ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_BUYED_NOCLIP");
				}	
			}
			else if(g_UseTime[ id ] [ 5 ] == iUse)
			{
				
				ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), iUse, LANG_SERVER, "SHOP_MAX_USE");
				return PLUGIN_HANDLED;
				
			}
      		}
   	}
   	return PLUGIN_CONTINUE;
}
public remove_noclip(id)
{
	remove_task(id);
	set_user_noclip(id, 0);
	ColorChat(id, GREEN, "%s^x03 %s^x01 %L",TAG, szName(id), LANG_SERVER, "SHOP_NOCLIP_OVER");
	return PLUGIN_HANDLED;
}

stock szName(id)
{
   new sz_Name[33];
   
   get_user_name(id, sz_Name, charsmax(sz_Name));
   
   return sz_Name;
}[/code]
Image
ImageImage
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

27 Nov 2013, 20:08

Și de unde iau lang?
User avatar
eNd.
Membru, skill +1
Membru, skill +1
Posts: 236
Joined: 19 Jan 2013, 21:18
Detinator Steam: Da
CS Status: Whoa...
SteamID: skitaila03
Has thanked: 18 times
Been thanked: 79 times

28 Nov 2013, 17:35

| Afiseaza codul
[code][en]

SHOP_CANT_BUY = nu poti cumpara.
SHOP_NO_MONEY = nu ai destui bani.
SHOP_BUYED_HP = ai cumparat hp.
SHOP_BUYED_SPEED = ai cumparat speed.
SHOP_BUYED_GRAVITY = ai cumparat gravity.
SHOP_BUYED_CROWBAR = ai cumparat crowbar.
SHOP_BUYED_NOCLIP = ai cumparat noclip.
SHOP_MAX_USE = ai cumparat deja de %d ori.
SHOP_NOCLIP_OVER = nu mai ai noclip.
SHOP_TITLE = Shop
SHOP_MENU_1 = Viata
SHOP_MENU_2 = Viteza
SHOP_MENU_3 = Gravitatie
SHOP_MENU_4 = Ranga
SHOP_MENU_5 = Noclip[/code]
Image
ImageImage
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

28 Nov 2013, 18:39

Oarecum e ok, dar gravitație nu e bună pentru că atunci când sar nici măcar nu sare. Atunci când cumpăr NoClip nu îmi ia din bani, la fel și la viteză/gravitație.
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

30 Nov 2013, 09:11

UP, am nevoie.
munir
Membru eXtream
Membru eXtream
Posts: 3193
Joined: 30 Aug 2012, 21:16
Detinator Steam: Da
CS Status: Fost scripter
Detinator server CS: Nu
SteamID: -
Reputatie: Fost super moderator
Restrictie schimbare nume
Nume anterior: falseq, cruyff
Location: Bucuresti
Has thanked: 335 times
Been thanked: 570 times
Contact:

30 Nov 2013, 11:22

| Afiseaza codul
#include < amxmodx >
#include < fun >
#include < cstrike >

#define PLUGIN_NAME "JB Shop"
#define PLUGIN_VERSION "1.0"
#define PLUGIN_AUTHOR "cruyff"

new g_Menu;

new bool:g_Speed[ 33 ];

public plugin_init( )
{
	register_plugin( PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR );
	
	register_clcmd( "say /shop", "Func_Shop" );
	register_clcmd( "say .shop", "Func_Shop" );
	
	register_logevent( "Func_RoundStart", 2, "1=Round_Start" );
	
	register_event( "CurWeapon", "Func_CurWeapon", "be", "1=1" );
}

public plugin_cfg( )
{
	g_Menu = menu_create( "\w[\yJB\w] \rShop\y:", "Func_ShopHandler" );
	
	menu_additem( g_Menu, "\w250\rHP\w \y[\r8000\w$\y]", "1", 0 );
	menu_additem( g_Menu, "\wViteza \y[\r12000\w$\y]", "2", 0 );
	menu_additem( g_Menu, "\wGravitate \y[\r8000\w$\y]", "3", 0 );
	menu_additem( g_Menu, "\wNoclip \y[\r16000\w$\y]", "4", 0 );
}

public Func_RoundStart( )
{
	new iPlayers[ 32 ], iNum;
	get_players( iPlayers, iNum, "c" );
	
	for( new i = 0; i < iNum; i++ )
	{
		g_Speed[ iPlayers[ i ] ] = false;
	}
}

public Func_Shop( id )
{
	if( get_user_team( id ) == 1 )
	{
		menu_display( id, g_Menu, 0 );
	}
}

public Func_ShopHandler( id, menu, item )
{
	switch( item )
	{
		case 0:
		{
			if( cs_get_user_money( id ) < 8000 )
			{
				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 8000 );
			}
			
			else
			{
				set_user_health( id, get_user_health( id ) + 250 );
				
				cs_set_user_money( id, cs_get_user_money( id ) - 8000 );
				
				client_print( id, print_chat, "Ai primit %i HP.", 250 );
			}
		}
		
		case 1:
		{
			if( cs_get_user_money( id ) < 12000 )
			{
				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 12000 );
			}
			
			else
			{
				set_user_maxspeed( id, 450.0 );
				
				cs_set_user_money( id, cs_get_user_money( id ) - 12000 );
				
				client_print( id, print_chat, "Ai primit %i Speed.", 450 );
				
				g_Speed[ id ] = true;
			}
		}		
		
		case 2:
		{
			if( cs_get_user_money( id ) < 8000 )
			{
				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 8000 );
			}
			
			else
			{				
				cs_set_user_money( id, cs_get_user_money( id ) - 8000 );
				
				client_print( id, print_chat, "Ai primit %i Gravity.", 650 );
			}
		}		
		
		case 3:
		{
			if( cs_get_user_money( id ) < 16000 )
			{
				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 16000 );
			}
			
			else
			{
				set_task( 5.0, "Func_RemoveNoClip", id );
				
				cs_set_user_money( id, cs_get_user_money( id ) - 16000 );
				
				client_print( id, print_chat, "Ai primit %i secunde de no-clip", 5 );
			}
		}
	}
}

public Func_RemoveNoClip( id )
{
	set_user_noclip( id, 0 );
	
	client_print( id, print_chat, "Numai ai no-clip." );
}

public Func_CurWeapon( id )
{
	if( g_Speed[ id ] )
		set_user_maxspeed( id, 450.0 );
}
Nu ti-am adaugat ranga. (zoinx) Netestat.
Retras
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

30 Nov 2013, 17:29

Nu funcționează No Clip.
munir
Membru eXtream
Membru eXtream
Posts: 3193
Joined: 30 Aug 2012, 21:16
Detinator Steam: Da
CS Status: Fost scripter
Detinator server CS: Nu
SteamID: -
Reputatie: Fost super moderator
Restrictie schimbare nume
Nume anterior: falseq, cruyff
Location: Bucuresti
Has thanked: 335 times
Been thanked: 570 times
Contact:

30 Nov 2013, 17:47

| Afiseaza codul
#include < amxmodx >
    #include < fun >
    #include < cstrike >

    #define PLUGIN_NAME "JB Shop"
    #define PLUGIN_VERSION "1.0"
    #define PLUGIN_AUTHOR "cruyff"

    new g_Menu;

    new bool:g_Speed[ 33 ];

    public plugin_init( )
    {
    	register_plugin( PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR );
    	
    	register_clcmd( "say /shop", "Func_Shop" );
    	register_clcmd( "say .shop", "Func_Shop" );
    	
    	register_logevent( "Func_RoundStart", 2, "1=Round_Start" );
    	
    	register_event( "CurWeapon", "Func_CurWeapon", "be", "1=1" );
    }

    public plugin_cfg( )
    {
    	g_Menu = menu_create( "\w[\yJB\w] \rShop\y:", "Func_ShopHandler" );
    	
    	menu_additem( g_Menu, "\w250\rHP\w \y[\r8000\w$\y]", "1", 0 );
    	menu_additem( g_Menu, "\wViteza \y[\r12000\w$\y]", "2", 0 );
    	menu_additem( g_Menu, "\wGravitate \y[\r8000\w$\y]", "3", 0 );
    	menu_additem( g_Menu, "\wNoclip \y[\r16000\w$\y]", "4", 0 );
    }

    public Func_RoundStart( )
    {
    	new iPlayers[ 32 ], iNum;
    	get_players( iPlayers, iNum, "c" );
    	
    	for( new i = 0; i < iNum; i++ )
    	{
    		g_Speed[ iPlayers[ i ] ] = false;
    	}
    }

    public Func_Shop( id )
    {
    	if( get_user_team( id ) == 1 )
    	{
    		menu_display( id, g_Menu, 0 );
    	}
    }

    public Func_ShopHandler( id, menu, item )
    {
    	switch( item )
    	{
    		case 0:
    		{
    			if( cs_get_user_money( id ) < 8000 )
    			{
    				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 8000 );
    			}
    			
    			else
    			{
    				set_user_health( id, get_user_health( id ) + 250 );
    				
    				cs_set_user_money( id, cs_get_user_money( id ) - 8000 );
    				
    				client_print( id, print_chat, "Ai primit %i HP.", 250 );
    			}
    		}
    		
    		case 1:
    		{
    			if( cs_get_user_money( id ) < 12000 )
    			{
    				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 12000 );
    			}
    			
    			else
    			{
    				set_user_maxspeed( id, 450.0 );
    				
    				cs_set_user_money( id, cs_get_user_money( id ) - 12000 );
    				
    				client_print( id, print_chat, "Ai primit %i Speed.", 450 );
    				
    				g_Speed[ id ] = true;
    			}
    		}		
    		
    		case 2:
    		{
    			if( cs_get_user_money( id ) < 8000 )
    			{
    				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 8000 );
    			}
    			
    			else
    			{				
    				cs_set_user_money( id, cs_get_user_money( id ) - 8000 );
    				
    				client_print( id, print_chat, "Ai primit %i Gravity.", 650 );
    			}
    		}		
    		
    		case 3:
    		{
    			if( cs_get_user_money( id ) < 16000 )
    			{
    				client_print( id, print_chat, "Ai nevoie de %i$ pentru a cumpara acest item.", 16000 );
    			}
    			
    			else
    			{
    				set_task( 5.0, "Func_RemoveNoClip", id );
    				
					set_user_noclip( id, 1 );
					
    				cs_set_user_money( id, cs_get_user_money( id ) - 16000 );
    				
    				client_print( id, print_chat, "Ai primit %i secunde de no-clip", 5 );
    			}
    		}
    	}
    }

    public Func_RemoveNoClip( id )
    {
    	set_user_noclip( id, 0 );
    	
    	client_print( id, print_chat, "Numai ai no-clip." );
    }

    public Func_CurWeapon( id )
    {
    	if( g_Speed[ id ] )
    		set_user_maxspeed( id, 450.0 );
    }
Greseala mea.
Retras
User avatar
roberteeel
Membru eXtream
Membru eXtream
Posts: 4440
Joined: 05 Sep 2012, 10:39
Detinator Steam: Nu
Reputatie: Nick anterior: QAZW, Robert.ultrasFarul, CT 18 ROS
Restrictie schimbare nume
Fost moderator
Fost Membru Club eXtreamCS (doua luni)
Has thanked: 312 times
Been thanked: 357 times

30 Nov 2013, 22:50

E totuși o problemă. După ce expiră No Clip, rămân blocat.
User avatar
Alyn^H3k3r
Membru, skill 0
Membru, skill 0
Posts: 94
Joined: 26 Nov 2013, 18:17
Detinator Steam: Nu
Detinator server CS: Da
Location: Galati
Has thanked: 14 times
Been thanked: 2 times
Contact:

09 Dec 2013, 23:18

QAZW wrote:E totuși o problemă. După ce expiră No Clip, rămân blocat.
Ramai blocat in pereti?
Daca da calculeazati secundele si vezi sa nu te prinzi in nimic dupa ce expira noclip!
Ajut la modificarea/creearea de addons-uri/pluginuri CS1.6 de orice mod, ajutorul meu nu consta in nimic, o fac din pura placere!

ContacT:
Skype: novuslink.h3k3r
Messenger: novuslink.h3k3r
E-mail: novuslink.h3k3r@yahoo.com

Post Reply

Return to “Cereri”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 10 guests