Synchronet v3.19b-Win32 (install) has been released (Jan-2022).

You can donate to the Synchronet project using PayPal.

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
module:xtrnmenu [2021/02/03 20:40] – updates for v3 mlongmodule:xtrnmenu [2021/02/13 13:08] (current) – [External Program Menu] Pluralize digital man
Line 1: Line 1:
-====== Xtrn Menu Mod by mlong ======+====== External Programs Menu ======
  
 For any issues, contact mlong on IRC, dove-net at mlong@INREALM or innerrealmbbs.us For any issues, contact mlong on IRC, dove-net at mlong@INREALM or innerrealmbbs.us
Line 5: Line 5:
 ===== Introduction ===== ===== Introduction =====
  
-The Custom External Menu Mod lets you define any number of custom external menus and have those menus link to other custom external menus, external section menus, external programs, or custom commands. You can also choose alpha-numeric inputs for the menu items (except Q), and sort several ways. In addition, you can fully customize the look of each menu and menu item. The mod also supports "game server mode" in which it can act as its own shell.+The XtrnMenu Mod is a loadable module replacement for xtrn_sec.js which lets you
 +  * define any number of custom external menus and have those menus link to other custom external menus, external section menus, external programs, or custom commands 
 +  * choose alpha-numeric inputs for the menu items (except Q), and sort several ways 
 +  * fully customize the look of each menu and menu item 
 +  * use keyboard arrow nav, mouse, esc, etcwith lightbar 
 +  * track launches and time and use this to power web stats as well as special menus 
 +  * search for any for door 
 +  * have a favorites menu that the user manages 
 +  * provide a game-only shell if you desire (gamesrv) 
 +  * use built in commands for feedback, mail, chat, text files, file area, etc. 
  
 ===== Installation ===== ===== Installation =====
  
-  - Get the latest files from the git repo +1. Get the latest files from the git repo 
-  Set the Loadable Module to 'xtrnmenu'+ 
 +2. Set the Loadable Module to 'xtrnmenu'
     -/sbbs/exec/scfg     -/sbbs/exec/scfg
     -Choose System     -Choose System
Line 17: Line 28:
     -Enter "xtrnmenu"     -Enter "xtrnmenu"
     -NOTE: If you ever want to switch back to stock, switch it to "xtrn_sec"     -NOTE: If you ever want to switch back to stock, switch it to "xtrn_sec"
-  - Now you will need to create your menus. +3. Now you will need to create your menus. 
     - Run "/sbbs/exec/jsexec /sbbs/exec/xtrnmenucfg.js" (if you are in the exec dir, just run ./jsexec xtrnmenucfg)     - Run "/sbbs/exec/jsexec /sbbs/exec/xtrnmenucfg.js" (if you are in the exec dir, just run ./jsexec xtrnmenucfg)
     - The first time you run it, it will create the main menu (a custom menu with the id of 'main')     - The first time you run it, it will create the main menu (a custom menu with the id of 'main')
     - Click on Edit Items and start adding your items to the main menu. Select the target type first (custom menu, standard built-in section menu, external program, special menu, or custom command) and then you can choose the actual target (where it points to). You can escape back to the start screen to add more custom menus     - Click on Edit Items and start adding your items to the main menu. Select the target type first (custom menu, standard built-in section menu, external program, special menu, or custom command) and then you can choose the actual target (where it points to). You can escape back to the start screen to add more custom menus
     - When you are done, press ESC to exit and save the config. This creates a file called /sbbs/ctrl/xtrnmenu.cfg. This is a JSON file you can make by hand, but using the editor is the preferred way of maintaining it.     - When you are done, press ESC to exit and save the config. This creates a file called /sbbs/ctrl/xtrnmenu.cfg. This is a JSON file you can make by hand, but using the editor is the preferred way of maintaining it.
-  - To use game stats, special menus, and favorites, you will need to enable JSON service. Add this to our ctrl/json-service.ini and restart services:+4. To use game stats, special menus, and favorites, you will need to enable JSON service. Add this to our ctrl/json-service.ini and restart services:
 <code> <code>
 [xtrnmenu] [xtrnmenu]
 dir=../data/ dir=../data/
 </code> </code>
-  - If you would like to use the web interface, copy the files from xtrn/xtrnmenu into your webv4/pages directory+Then add this to modopts.ini under [xtrn_sec]: 
 +<code> 
 +eval_before_exec=js.exec("xtrnmenu.js",{},"pre",prog.code); 
 +eval_after_exec=js.exec("xtrnmenu.js",{},"post",prog.code); 
 +</code> 
 +5. If you would like to use the web interface, copy the files from xtrn/xtrnmenu into your webv4/pages directory
 You also need to modify the stock 003-games.xjs or you will have two Games menus: You also need to modify the stock 003-games.xjs or you will have two Games menus:
 <code> <code>
Line 37: Line 53:
 This mod will not affect any shells that create their own external menus, most notably lbshell (Deuce's Lightbar Shell). For these shells, they will just see your section menus This mod will not affect any shells that create their own external menus, most notably lbshell (Deuce's Lightbar Shell). For these shells, they will just see your section menus
  
 +The mod does not handle scrolling. You need to ensure that you do not have more menu items or external programs in a section than can be displayed in one screen (with header/footer/prompt)
 ===== xtrnmenucfg.js ===== ===== xtrnmenucfg.js =====
  
Line 212: Line 229:
 === Single Item Appearance Options === === Single Item Appearance Options ===
  
-To change the look of a single item inside of a menu, create it within the [xtrnmenu:ID] section with a key of EXTERNALID-multicolumn_fmt or EXTERNALID-singlecolumn_format (these are the only two settings you can change) like this: +To change the look of a single item inside of a menu, create it within the [xtrnmenu:ID] section with a key of EXTERNALID-OPTION, like this:
 <code> <code>
-[xtrnmenu:genre+[xtrnmenu:wordgame
-    multicolumn_fmt: \1n\1y[\1h%2s\1n\1y] \1y%-32.32s \1h +boggle-multicolumn_fmt: \1n\1w[\1r\1h%2s\1n\1w] [test] \1m%-25.25s \1h 
-    singlecolumn_fmt: \1n\1y[\1h%2s\1n\1y] \1y%-32.32s \1h +boggle-singlecolumn_fmt: \1n\1w[\1r\1h%2s\1n\1w] [test] \1m%-25.25s \1h 
-    lord-multicolumn_fmt: \1n\1g[\1h%2s\1n\1g] \1g%-32.32s \1h +boggle-multicolumn_fmt_inverse: \1n\1w[\1r\1h%2s\1n\1w[test] \x015\1w%-25.25s \1h 
-    lord-singlecolumn_fmt: \1n\1g[\1h%2s\1n\1g] \1g%-32.32s \1h+boggle-singlecolumn_fmt_inverse: \1n\1w[\1r\1h%2s\1n\1w[test] \x015\1w%-25.25s \1h
 </code> </code>