Menu Section


Tipmenus can grow quite large, and a useful management tool is grouping them into sections. These sections can be manipulated independently of each other, but all items within are treated communally.


A tipmenu is generally built up through individual sections, themselves containing a number of Menu Item.



Adds the item to the section. Two parameters, name and cost, are required. An optional parameter, handler, is a callback when tipped for; params are passed to handler.

If you only need simple tipmenu items, that is, matching to them but no logic, then only worry about name and cost. If the items require logic however, handlers must be written which do the world.


Clear the section of all items. This is used at the beginning of rebuilding a menu.


Delete an item from the menu. This is generally completely useless, but is used in the Special manager.


Look up the menu item with the specified name.


Print the menu section to chat. User is the user to send the section to. Limit is optional, and is the upper cost limit to print; all items which cost more than the limit will not be printed. Discounted is optional, and defaults to false; if the section is discounted Discount.apply() will be called for each item.


On 2018-12-03 17:36:52 UTC anonymous added:
test test x2