5133p39 16 Posted March 20, 2009 (edited) I am trying to add new item to the main command menu. To create the new item is easy:<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class RscMainMenu { Â access = ReadAndWrite; Â title = $STR_COMMAND; Â atomic = 0; Â vocabulary = ""; Â class Items { Â Â Â ... Â Â Â ... Â Â Â class MyNewItem { Â Â Â Â title = "MUJ TEST"; Â Â Â Â key = 12; Â Â Â Â character = "-"; Â Â Â Â command = "Hint ""Test"";"; Â Â Â Â speechId = 0; Â Â Â }; Â }; } The only problem is that the <span style='color:blue'>command</span> is executed immediately after the main menu is displayed, instead of executing only after the item is activated (by pressing the coresponding key defined by the <span style='color:blue'>key</span> inside the menu item definition). Any ideas? Yes, i know i could use the action menu or radio, but i want this to work instantly (defined from my addon's config.cpp, not from some script which would add the new action/radio option). The purpose is to have easy access to some debug/test functions when i am testing my addons/missions. Maybe some of you seen my any gear addon, i am working on a new version which allows teleporting, spawning vehicles/units, free/unit camera, executing code, etc., and i want to be able to activate the main dialog after activating the new menu item. Edited April 11, 2009 by W0lle Share this post Link to post Share on other sites
.kju 3245 Posted March 20, 2009 what about XEH pre init? Share this post Link to post Share on other sites