Cerere plugin vip

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
HalogekT3Kz
Membru, skill 0
Membru, skill 0
Posts: 10
Joined: 20 Nov 2019, 23:05
Detinator Steam: Nu
CS Status: Citesc forumul eXtreamCS.com...!
Fond eXtream: 0

28 Nov 2019, 21:17

Plugin Cerut:Plugin pentru vip
Descriere (adica ce face el mai exact):as dori un plugin de vip gold si vip silver ,la vip gold sa dea ak47+deagle+grenade ,m4a1+deagle_grenade ,awp+deagle+grenade sa fie double jump si parasuta ,iar la vip silver ak47+deagle+grenade ,m4a1+deagle_grenade si double jump(si sa apara in tab cu vip)
Serverul ruleaza (HLDS/ReHLDS):ReHLDS
Versiune AMX Mod X:-
Modul Serverului:Clasic
eXtreamSHOP
User avatar
1TAP GOD
Membru, skill 0
Membru, skill 0
Posts: 78
Joined: 02 Sep 2018, 23:20
Detinator Steam: Da
CS Status: Be The Best And Fuck The Rest
SteamID: assasinssmdfk
Fond eXtream: 0
Been thanked: 1 time
Contact:

29 Nov 2019, 15:21

Nu am testat pluginul,este facut din mai multe parti :)

Code: Select all

#include <amxmodx>
#include <cstrike>
#include <fun>
#include <engine>
#include <hamsandwich>
#include <amxmisc>
#include <fakemeta>

const PRIMARY_WEAPONS_BIT_SUM = (1<<CSW_SCOUT)|(1<<CSW_XM1014)|(1<<CSW_MAC10)|(1<<CSW_AUG)|(1<<CSW_UMP45)|(1<<CSW_SG550)|(1<<CSW_GALIL)|(1<<CSW_FAMAS)|(1<<CSW_AWP)|(1<<CSW_MP5NAVY)|(1<<CSW_M249)|(1<<CSW_M3)|(1<<CSW_M4A1)|(1<<CSW_TMP)|(1<<CSW_G3SG1)|(1<<CSW_SG552)|(1<<CSW_AK47)|(1<<CSW_P90);
const SECONDARY_WEAPONS_BIT_SUM = (1<<CSW_P228)|(1<<CSW_ELITE)|(1<<CSW_FIVESEVEN)|(1<<CSW_USP)|(1<<CSW_GLOCK18)|(1<<CSW_DEAGLE);

#define ADMIN_GOLD	ADMIN_LEVEL_H
#define ADMIN_SILVER	ADMIN_LEVEL_G
#define SCOREATTRIB_NONE    0
#define SCOREATTRIB_DEAD    ( 1 << 0 )
#define SCOREATTRIB_BOMB    ( 1 << 1 )
#define SCOREATTRIB_VIP     ( 1 << 2 )
new bool:g_iRunda[ 33 ], bool:g_iRound[ 33 ];

new const GoldTag[] = "[!gGold!teamVip!y]"
new const SilverTag[] = "[!gSilver!teamVip!y]"
new jumpnum[33] = 0
new bool:dojump[33] = false

public plugin_init () {
	RegisterHam(Ham_Spawn, "player", "cmdSpawn", 1);
	register_logevent("RoundStart", 2, "1=Round_Start")
	register_message(get_user_msgid( "ScoreAttrib" ), "MessageScoreAttrib");	

}
public client_putinserver(id)
{
	jumpnum[id] = 0
	dojump[id] = false
}

public client_disconnect(id)
{
	jumpnum[id] = 0
	dojump[id] = false
}

public GoldMenu( id )
{	
	if(g_iRunda[id])
	{
		Chat_Color(id, "%sAi folosit deja odata,incearca runda urmatoare",GoldTag)
		return 1
	}
	static menu;
	menu = menu_create ("\yVIPMENU\r Gold","menu_gold");
	
	menu_additem(menu, "AK47+Deagle+Grenƒazi", "1");
	menu_additem(menu, "M4A1+Deagle+Grenƒazi", "2");
	menu_additem(menu, "Awp+Deagle+Grenƒazi", "3");

	
	menu_setprop ( menu, MPROP_NUMBER_COLOR,"\y");
	menu_setprop ( menu, MPROP_EXIT, MEXIT_ALL );
	
	menu_display ( id, menu, 0 );
	return 0;
}

public menu_gold ( id, menu, item )
{
	if ( item == MENU_EXIT )
	{
		menu_destroy ( menu );
		return 1;
	}
	
	new data [ 6 ], szName [ 64 ];
	new access, callback;
	
	menu_item_getinfo ( menu, item, access, data, charsmax ( data ), szName, charsmax ( szName ), callback );
	
	new key = str_to_num ( data );
	
	switch ( key )
	{
		case 1:
			{
				drop_weapons(id, 1);
				drop_weapons(id, 2);
				give_item(id, "weapon_knife");
				give_item(id, "weapon_ak47");
				give_item(id, "weapon_deagle");
				give_item(id, "weapon_hegrenade");
				give_item(id, "weapon_flashbang");
				cs_set_user_bpammo(id, CSW_HEGRENADE, 1);
				cs_set_user_bpammo(id, CSW_FLASHBANG, 2);
				cs_set_user_bpammo(id, CSW_AK47, 90);
				cs_set_user_bpammo(id, CSW_DEAGLE, 35);
				Chat_Color(id, "%sAi ales !nAk47!g+!nDeagle!g+!nSet grenazi!n.",GoldTag)
				
			}   
			
			case 2:
			{
				drop_weapons(id, 1);
				drop_weapons(id, 2);
				give_item(id, "weapon_knife");
				give_item(id, "weapon_m4a1");
				give_item(id, "weapon_deagle");
				give_item(id, "weapon_hegrenade");
				give_item(id, "weapon_flashbang");
				cs_set_user_bpammo(id, CSW_HEGRENADE, 1);
				cs_set_user_bpammo(id, CSW_FLASHBANG, 2);
				cs_set_user_bpammo(id, CSW_M4A1, 90);
				cs_set_user_bpammo(id, CSW_DEAGLE, 35);
                                     Chat_Color(id, "%sAi ales !nM4A1!g+!nDeagle!g+!nSet grenazi!n.",GoldTag)		
			}
			
			case 3:
			{
				drop_weapons(id, 1);
				drop_weapons(id, 2);
				give_item(id, "weapon_knife");
				give_item(id, "weapon_awp");
				give_item(id, "weapon_deagle");
				give_item(id, "weapon_hegrenade");
				give_item(id, "weapon_flashbang");
				give_item(id, "weapon_smokegrenade");
				cs_set_user_bpammo(id, CSW_FLASHBANG, 2);
				cs_set_user_bpammo(id, CSW_AWP, 30);
				cs_set_user_bpammo(id, CSW_DEAGLE, 35);
                                    Chat_Color(id, "%sAi ales !nAWP!g+!nDeagle!g+!nSet grenazi!n.",GoldTag)
		         }    		
	}
	menu_destroy ( menu );
	return 1;
}

public cmdSpawn(id) {
	if(get_user_flags(id) & ADMIN_GOLD && is_user_alive(id))
	{
		GoldMenu(id)
		set_user_armor(id, 150)
		set_user_health(id, 120)
		cs_set_user_bpammo(id, CSW_FLASHBANG, 2)
	}
	else if(get_user_flags(id) & ADMIN_SILVER && is_user_alive(id))
	{
		SilverMenu(id)
		set_user_armor(id, 120)
		set_user_health(id, 100)
	}
} 

public SilverMenu ( id )
{
	if(g_iRound[id])
	{
		Chat_Color(id, "%sAi folosit deja odata,incearca runda urmatoare",SilverTag)
		return 1;
	}
	
	static menu;
	menu = menu_create ("\yVIPMENU\r Silver","menu_silver");
	
	menu_additem(menu, "AK47+Deagle+Grenƒazi", "1");
	menu_additem(menu, "M4A1+Deagle+Grenƒazi", "2");

	menu_setprop ( menu, MPROP_NUMBER_COLOR,"\y");
	menu_setprop ( menu, MPROP_EXIT, MEXIT_ALL );
	
	menu_display ( id, menu, 0 );
	return 0;
}

public menu_silver ( id, menu, item )
{
	if ( item == MENU_EXIT )
	{
		menu_destroy ( menu );
		return 1;
	}
	
	new data [ 6 ], szName [ 64 ];
	new access, callback;
	
	menu_item_getinfo ( menu, item, access, data, charsmax ( data ), szName, charsmax ( szName ), callback );
	
	new key = str_to_num ( data );
	
	switch ( key )
	{
		case 1:
			{
				drop_weapons(id, 1);
				drop_weapons(id, 2);
				give_item(id, "weapon_knife");
				give_item(id, "weapon_ak47");
				give_item(id, "weapon_deagle");
				give_item(id, "weapon_hegrenade");
				give_item(id, "weapon_flashbang");
				cs_set_user_bpammo(id, CSW_HEGRENADE, 1);
				cs_set_user_bpammo(id, CSW_FLASHBANG, 2);
				cs_set_user_bpammo(id, CSW_AK47, 90);
				cs_set_user_bpammo(id, CSW_DEAGLE, 35);
                                    Chat_Color(id, "%sAi ales !nAk47!g+!nDeagle!g+!nSet grenazi!n.",SilverTag)
			}   
			
			case 2:
			{
				drop_weapons(id, 1);
				drop_weapons(id, 2);
				give_item(id, "weapon_knife");
				give_item(id, "weapon_m4a1");
				give_item(id, "weapon_deagle");
				give_item(id, "weapon_hegrenade");
				give_item(id, "weapon_flashbang");
				cs_set_user_bpammo(id, CSW_HEGRENADE, 1);
				cs_set_user_bpammo(id, CSW_FLASHBANG, 2);
				cs_set_user_bpammo(id, CSW_M4A1, 90);
				cs_set_user_bpammo(id, CSW_DEAGLE, 35);
                                    Chat_Color(id, "%sAi ales !nAk47!g+!nDeagle!g+!nSet grenazi!n.",SilverTag)
		 }
			
	}
	menu_destroy ( menu );
	return 1;
}

public RoundStart( )
{
	new iPlayers[32], iNum;
	get_players( iPlayers, iNum)
	for( new i = 0; i < iNum;i++ )
	{
		g_iRunda[ iPlayers[ i ] ] = false;
		g_iRound[ iPlayers[ i ] ] = false;
	}
}
public client_PreThink(id)
{
	if(!is_user_alive(id) || !(get_user_flags(id) & ADMIN_GOLD)) 
		return 1;
		
	new Float:fallspeed = 100.0 * -1.0
	new BUTTON = get_user_button(id);
	new OLDBUTON = get_user_oldbutton(id);
	new JUMP_VIP = 1;

	if((BUTTON & IN_JUMP) && !(get_entity_flags(id) & FL_ONGROUND) && !(OLDBUTON & IN_JUMP))
	{
		if(jumpnum[id] < JUMP_VIP)
		{
			dojump[id] = true;
			jumpnum[id]++
		}
	}

	if((BUTTON & IN_JUMP) && (get_entity_flags(id) & FL_ONGROUND))
	{
		jumpnum[id] = 0;
	}
	
		if(BUTTON & IN_USE) 
		{
			new Float:velocity[3];
			entity_get_vector(id, EV_VEC_velocity, velocity);
		
			if(velocity[2] < 0.0) 
			{
				entity_set_int(id, EV_INT_sequence, 3);
				entity_set_int(id, EV_INT_gaitsequence, 1);
				entity_set_float(id, EV_FL_frame, 1.0);
				entity_set_float(id, EV_FL_framerate, 1.0);

				velocity[2] = (velocity[2] + 40.0 < fallspeed) ? velocity[2] + 40.0 : fallspeed;
				entity_set_vector(id, EV_VEC_velocity, velocity);
			}
		}
}

public client_PostThink(id)
{
	if(!is_user_alive(id)) 
		return 1;
		
	if(dojump[id] == true)
	{
		new Float: velocity[3];
		entity_get_vector(id, EV_VEC_velocity, velocity)
		velocity[2] = random_float(265.0, 285.0);
		entity_set_vector(id, EV_VEC_velocity, velocity)
		dojump[id] = false;
	}

	return 0;
}
public MessageScoreAttrib(iMsgID, iDest, iReceiver)
{
    new iPlayer = get_msg_arg_int(1);
    if(is_user_connected(iPlayer) && (get_user_flags(iPlayer) &  ADMIN_GOLD))
	{
        set_msg_arg_int(2, ARG_BYTE, is_user_alive(iPlayer) ? SCOREATTRIB_VIP : SCOREATTRIB_DEAD);
         }
	else if(is_user_connected(iPlayer) && (get_user_flags(iPlayer) &  ADMIN_SILVER))
	{
        set_msg_arg_int(2, ARG_BYTE, is_user_alive(iPlayer) ? SCOREATTRIB_VIP : SCOREATTRIB_DEAD);
         }
    
}
stock Chat_Color(const id, const input[], any:...)
{
	new count = 1, players[32]
	static msg[191]
	vformat(msg, 190, input, 3)
	
	replace_all(msg, 190, "!g", "^4")
	replace_all(msg, 190, "!y", "^1")
	replace_all(msg, 190, "!team", "^3")
	
	if (id) players[0] = id; else get_players(players, count, "ch")
	{
	for (new i = 0; i < count; i++)
	{
		if (is_user_connected(players[i]))
		{
			message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players[i])
			write_byte(players[i]);
			write_string(msg);
			message_end();
		}
	}
}
}
stock fm_find_ent_by_owner(entity, const classname[], owner)
{
	while((entity = engfunc(EngFunc_FindEntityByString, entity, "classname", classname)) && pev(entity, pev_owner) != owner) {  }
	return entity;
}

stock drop_weapons(id, dropwhat)
{
	static Weapons[32], Num, i, WeaponID;
	Num = 0;
	get_user_weapons(id, Weapons, Num);
	for(i = 0; i < Num; i ++)
	{
		WeaponID = Weapons[i];
		if((dropwhat == 1 && ((1 << WeaponID) & PRIMARY_WEAPONS_BIT_SUM)) || (dropwhat == 2 && ((1 << WeaponID) & SECONDARY_WEAPONS_BIT_SUM )))
		{
			static DropName[32], WeaponEntity;
			get_weaponname(WeaponID, DropName, charsmax(DropName));
			WeaponEntity = fm_find_ent_by_owner(-1, DropName, id);
			set_pev(WeaponEntity, pev_iuser1, cs_get_user_bpammo (id, WeaponID));
			engclient_cmd(id, "drop", DropName);
			cs_set_user_bpammo(id, WeaponID, 0);
		}
	}
}
Daca vreti ceva da-ti add aici https://steamcommunity.com/id/assasinssmdfk/
HalogekT3Kz
Membru, skill 0
Membru, skill 0
Posts: 10
Joined: 20 Nov 2019, 23:05
Detinator Steam: Nu
CS Status: Citesc forumul eXtreamCS.com...!
Fond eXtream: 0

30 Nov 2019, 19:35

multumesc ,rezolvat
Post Reply

Return to “Cereri”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 16 guests