Raised This Month: $ Target: $400
 0% 

Need help with weapon menu!


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
BottleCaps
New Member
Join Date: Jun 2010
Old 06-17-2010 , 04:41   Need help with weapon menu!
Reply With Quote #1

I cannot seem to get the scout, but the other weapon in the code, i can.Please solve this problem :l Code is below

#include <amxmodx>
#include <amxmisc>
#include <fun>
public plugin_init()
{
register_plugin("Menu Demo", "1.0", "BAILOPAN")
new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2
register_menucmd(register_menuid("Which Weapon?"), keys, "giveWeapon")
register_clcmd("say /gunme", "showWeaponMenu")
}
public showWeaponMenu(id)
{
new menu[192]
new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2

format(menu, 191, "Which Weapon?^n^n1. AK47^n2. M4A1^n3. Scout")
show_menu(id, keys, menu)
return PLUGIN_HANDLED
}

//Our menu function will get the player id and the key they pressed
public giveWeapon(id, key)
{
//key will start at zero
if (key == 0)
{
give_item(id, "weapon_ak47")
} else if (key == 1) {
give_item(id, "weapon_m4a1")
} else if (key == 2) {
give_item(id, "CSW_Scout")
}
}
BottleCaps is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 06-17-2010 , 07:31   Re: Need help with weapon menu!
Reply With Quote #2

PHP Code:
give_item(id"CSW_Scout"

PHP Code:
give_item(id"weapon_scout"
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
Reply



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 14:50.


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