Legacy Documentation: Version 4.6(go to latest)
Language: English
  • C#
  • JS
  • Boo

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

GenericMenu.AddItem

public function AddItem(content: GUIContent, on: bool, func: MenuFunction): void;

Description

Add an item to the menu.

public function AddItem(content: GUIContent, on: bool, func: MenuFunction2, userData: object): void;

Description

Add an item to the menu.