Raised This Month: $ Target: $400
 0% 

Would need some help.


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
DarlD
Senior Member
Join Date: Aug 2004
Old 10-18-2005 , 00:48   Would need some help.
Reply With Quote #1

Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Buy Health"
#define VERSION "1.0"
#define AUTHOR "Meta"
new mBuyHealth // Menu
new mcbBuyHealth // Menu Callback



public plugin_init() {
	register_plugin(PLUGIN, VERSION, AUTHOR)
	register_menucmd(register_menuid("Buy Health"), keys, "ma_BuyHealth")
	new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2
	register_event("Buy Health", "healthmenu", "be")
	/* Menu Buy Health */
	/* Use menu_display(id, mBuyHealth, 0) to show the menu to an user. */
	mBuyHealth = menu_create("Buy Health", "mh_BuyHealth")
	mcbBuyHealth = menu_makecallback("mcb_BuyHealth")
	menu_additem(mBuyHealth, "Buy 10HP - 100$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	menu_additem(mBuyHealth, "Buy 20HP - 200$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	menu_additem(mBuyHealth, "Buy 30HP - 300$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	menu_additem(mBuyHealth, "Buy 40HP - 400$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	menu_additem(mBuyHealth, "Buy 50HP - 500$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	menu_additem(mBuyHealth, "Buy 100HP - 1000$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	menu_additem(mBuyHealth, "Buy 5000HP - 16000$", "ma_BuyHealth", ADMIN_USER, mcbBuyHealth)
	/* Menu End */

	// Add your code here...
	
}


/* Menu Buy Health */

public mh_BuyHealth(id, menu, item) {
	/* This event is called when someone presses a key on this menu */
}

public ma_BuyHealth(id) {
	/* This event is called when an item was selected */
}

public mcb_BuyHealth(id, menu, item) {
	/* This is the callback-event, here you can set items enabled or disabled. */
	/* If you want to enable an item, use: return ITEM_ENABLED */
	/* If you want to disable an item, use: return ITEM_DISABLED */
}
public healthmenu() {
	
	new menu[192]
         new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2
	
         show_menu(id, keys, menu)
    return PLUGIN_HANDLED
}

so basicly im trying to make a menu in order to buy health, right. i think i got all this programing thing ok but im not sure how to set it all up right, im still missing some key things and i know this code is probably total garbage :S but if anyone could show me where i made mistakes that would be really helpfull, thanks
DarlD is offline
Send a message via MSN to DarlD
 



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 23:52.


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