Register to post in forums, or Log in to your existing account
 

 Related 
Contents
Feature Reference
  Aliases
  Macros
  Variables
  Functions
  Classes
  Triggers
  Buttons
  Gauges
  Paths
  Menus
  Events
  Modules
  Windows
  Packages
  Shared Package Library
  Package Editor
  Docked Windows
  Customizeable Toolbars
  Sessions
  Expressions
  Automapper Module
  Database Module
  Syntax Checking
  Tab Completion
  Status items
  Preferences
  Simutronics Support
  Pueblo Emulation
  Keyboard shortcuts
  MXP
  Threads
  ATCP
  Script Debugger
  Timestamps
  Lua Scripting
Related Links:
  Package Editor
  Terminology
  Modules
  Copy an existing package
Windows [[cmud_windows]] 
A Window is a visual screen that can contain buttons, MUD output, a command line, and a status bar.

A Window contains Class folders, and other settings such as aliases, triggers, macros, etc. These settings can only be accessed by the package that contains the window.

Example

Take a look at your default session package. Just open your session Offline and click the Settings button in the toolbar to open the Package Editor. In the "tree-view" on the left, you will see the contents of the current package, which starts with a Window object at the top. This is the main window that displays the output from the MUD.

Novice users will normally just have a single Window within the default package for your MUD session. But a package can actually contain many different windows. For example, you might create other windows to capture text from various "chat channels" on your MUD.

A new chat window

When playing a MUD, there is a lot of text being displayed, especially in combat. If someone else playing the MUD sends you a message, it's easy for it to get lost.

One common way to improve this is to create a separate window to contain all of the messages send to you by other players. Typically, when you receive a message from another player, it will look something like this:

Zugg tells you 'Hi there!'

To grab this text and send it to another window, you use the #CAPTURE command in a trigger. Like this:

#TRIGGER {* tells you '*'} {#CAPTURE Tells}

In this case, we are telling CMUD to send any line that matches the pattern "* tells you '*'" to a window called "Tells". The #CAPTURE command will automatically create the window if it doesn't already exist. Also, by default, the new window will not have a command line or status bar. You can change these options in the Package Editor or by right-clicking the window and selecting Window Options.

You can also create a new window within a script using the #WINDOW command.

Window network connections

By default, the initial Window object is set to use the main session network connection. However, each Window can actually have it's own network connection. In the Package Editor, select the Window object and you will see three options for the network connection:
  • No network connection
  • Use main session network connection
  • Override network connection
If you select the Override option, you can enter a different hostname and port. This allows you to create multiple windows connected to different hosts or MUDs.

The easy way to create a new window with a new network connection is to just use the File/New Connection menu option, or the New Connection option from the Sessions drop-down menu. It will prompt you to enter a host and port and will then create a new window connected to that host.
Viewer Comments [0 - Post your comments]

Jump to:  

© 2009 Zugg Software. Hosted by Wolfpaw.net