This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

[REQ] Weapons menu


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Visan15
Junior Member
Join Date: Apr 2012
Old 05-15-2024 , 15:54   [REQ] Weapons menu
Reply With Quote #1

Hello , i found this plugin made by OciXCrom and i want to do few settings if somebody can help.

P.S original had AWP as well but i deleted.

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

new g_iMenu

public plugin_init()
{
	register_plugin("Weapons Menu", "1.0", "OciXCrom")
	RegisterHam(Ham_Spawn, "player", "OnPlayerSpawn", 1)
	CreateMenu()
}

CreateMenu()
{
	g_iMenu = menu_create("Select your \rweapons\y!", "Menu_Handler")
	menu_additem(g_iMenu, "\wAK47 \y+ \wDeagle")
	menu_additem(g_iMenu, "\wM4A1 \y+ \wDeagle")
	
}

public OnPlayerSpawn(id)
{
	if(!is_user_alive(id))
		return

	menu_display(id, g_iMenu)
}

public Menu_Handler(id, iMenu, iItem)
{
	switch(iItem)
	{
		case MENU_EXIT: return
		case 0:
		{
			give_item(id, "weapon_ak47")
			cs_set_user_bpammo(id, CSW_AK47, 90)
		}
		case 1:
		{
			give_item(id, "weapon_m4a1")
			cs_set_user_bpammo(id, CSW_M4A1, 90)
		}
		
	}

	give_item(id, "weapon_deagle")
	cs_set_user_bpammo(id, CSW_DEAGLE, 35)

	

	if(cs_get_user_team(id) == CS_TEAM_CT)
		give_item(id, "item_thighpack")
}

1. Menu weapons last for 10s
2. You can't carry more then 1 primary and 1 secondary wep. (now you can have 2-3 primary).

Or if exist a similar plugin , can somebody link me ? already had a lot of search on google.

Thank you .

Last edited by Visan15; 06-12-2024 at 13:26.
Visan15 is offline
 



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 10:26.


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