# Bos Wars Scripting API: User Interface (UI)

Bos Wars FAQ PREV NEXT LUA Index

DefineButton DefineButtonStyle DefineCheckboxStyle DefineCursor DefineMenu DefineMenuGraphics DefineMenuItem DefinePanelContents DefineUI DefineViewports SetGameCursor

## Intro - Introduction to UI functions and variables

Everything around the user interface.

## Functions

### DefineButton({tag1 = value1, tag2 value2, ...})

Define a button in the button panel show during the game. Possible tags:

Pos = number
  Position number.

      0 1 2
      3 4 5
      6 7 8

Level = number
  Visible when in this button level (0 default, 9 cancel-only)
Icon = "icon-name"
  Name of the icon to display.
Action = "action"
  Action to perform when the button is clicked. Can be any of the following:
  "move"
    The unit moves to location
  "stop"
    the unit stops. Orders queue is also erased. The unit wait for order but can react by itself.
  "attack"
    The unit attacks target. if target is a unit then it attacks only the unit. If target is a position, it will move to location by attacking any opponent on the way.
  "repair"
    The unit will repair the target unit.
  "harvest"
    The unit will harvest the ressources.
  "button"
    FIXME. Need Value = number.
  "build"
    The unit will build the unit (building structure)
  "train-unit"
    The unit trains an unit. Generally use for building to create news units. Need Value = "unit-name".
  "patrol"
    The unit patrol between target position and current position and attack any opponent on the way.
  "stand-ground"
    The unit doesn't move. The unit stay at its location until it receives a new order.
  "attack-ground"
    The unit attack a location. Usefull for unit with spalsh damage.
  "return-goods"
    The unit with ressources return goods.
  "cast-spell"
    The unit cast a spell. Need Value = "spell-name"
  "unload"
    The unit unload unit inside of itself. Usefull for transporter or bunkers.
  "cancel"
    FIXME : difference between cancels.
  "cancel-train-unit"
    FIXME
  "cancel-build"
    FIXME
Value = arg
  Optional value associated with the action.
Allowed = "check-name"
  Optional check to see if a button is allowed. Can be any of the following:
  "check-true"
    No restriction on this button.
  "check-false"
    this button is forbidden. FIXME : ? to be removed. What is its usage ?
  "check-units-or"
    this button is available if at least one of the unit are available. Need AllowArg = {"unit-name1", "unit-name2"}
  "check-units-and"
    FIXME
  "check-network"
    Button is available only if network is available too.
  "check-no-network"
    Button is available only if network is not available.
  "check-no-work"
    FIXME
  "check-attack"
    FIXME
AllowArg = {"arg1", ...}
  Optional argument used by the allowed function.
Key = "char"
  Shortcut key for the button. (FE "c" for key 'c' or "\27" for Escape)
Hint = "string"
  Hint to be displayed for the button.
ForUnit = {"unit-name1", ...} or {"*"}
  List of units the button applies to, or {"*"} for all units.

#### Example

    DefineButton( { Pos = 8, Level = 0, Icon = "icon-build-advanced",
      Action = "button", Value = 2,
      Allowed = "check-units-or", AllowArg = {"unit-elven-lumber-mill", "unit-keep"},
      Key = "v", Hint = "BUILD AD~!VANCED STRUCTURE",
      ForUnit = {"unit-peasant"} } )

### DefineButtonStyle(style, {tag = value, ...})

Define a button style. Possible tags:

Size = {x, y}
  Size of the button.
Font = font-name
  Name of the font to use.
TextNormalColor = color, TextReverseColor = color
  Color to use for the normal and reverse text.
TextAlign = align
  Align the text. Possible values are "Left", "Right", and "Center".
TextPos = {posx, posy}
  Set the position of the text relative to the upper left corner of the image.
Default = {tag = value, ...}, Hover = {}, Selected = {}, Clicked = {}, Disabled = {}
  Set attributes for when the mouse is over the button (Hover), the button is Selected, Clicked, Disabled, or the Default setting. Possible tags:
  File = file
    The filename.
  Size = size
    The size of the image (only needed when using an image with multiple frames).
  Frame = frame
    Select the frame number from an image (only needed when using an image with multiple frames).
  TextNormalColor = color, TextReverseColor = color
    Color to use for the normal and reverse text (overrides the main colors).
  TextPos = {x, y}
    Display the text at this position (overrides the main position).
  Border = { Color = color, Size = size}
    Draw a border with the specified color and size.

#### Example

    DefineButtonStyle("main", {
      Size = {128, 20},
      Font = "game",
      TextNormalColor = "yellow",
      TextReverseColor = "white",
      TextAlign = "Center",
      TextPos = {64, 4},
      Default = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 4,
      },
      Hover = {
        TextNormalColor = "white",
      },
      Selected = {
        Border = {
          Color = {252, 252, 0}, Size = 1,
        },
      },
      Clicked = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 5,
        TextNormalColor = "white",
        TextPos = {66, 6},
      },
      Disabled = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 3,
        TextNormalColor = "grey",
        TextReverseColor = "grey",
      },
    })

### DefineCheckboxStyle(style, {tag = value, ...})

Define a checkbox style. Possible tags:

Size = {x, y}
  Size of the button.
Font = font-name
  Name of the font to use.
TextNormalColor = color, TextReverseColor = color
  Color to use for the normal and reverse text.
TextAlign = align
  Align the text. Possible values are "Left", "Right", and "Center".
TextPos = {posx, posy}
  Set the position of the text relative to the upper left corner of the image.
Default = {tag = value, ...}, Hover = {}, Selected = {}, Clicked = {}, Disabled = {}, Checked = {}, CheckedHover = {}, CheckedSelected = {}, CheckedClicked = {}, CheckedDisabled = {}
  Set attributes for when the mouse is over the checkbox (Hover), the checkbox is Selected, Clicked, Disabled, the Default setting, and for when the checkbox is Checked. Possible tags:
  File = file
    The filename.
  Size = size
    The size of the image (only needed when using an image with multiple frames).
  Frame = frame
    Select the frame number from an image (only needed when using an image with multiple frames).
  TextNormalColor = color, TextReverseColor = color
    Color to use for the normal and reverse text (overrides the main colors).
  TextPos = {x, y}
    Display the text at this position (overrides the main position).
  Border = { Color = color, Size = size}
    Draw a border with the specified color and size.

#### Example

    DefineCheckboxStyle("round", {
      Size = {19, 19},
      Font = "game",
      TextNormalColor = "yellow",
      TextReverseColor = "white",
      TextAlign = "Left",
      TextPos = {24, 4},
      Default = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 19,
      },
      Hover = {
        TextNormalColor = "white",
      },
      Selected = {
        Border = {
          Color = {252, 252, 0}, Size = 1,
        },
      },
      Disabled = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 18,
      },
      Clicked = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 20,
        TextNormalColor = "white",
      },
      Checked = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 21,
      },
      CheckedHover = {
        TextNormalColor = "white",
      },
      CheckedSelected = {
        Border = {
          Color = {252, 252, 0}, Size = 1,
        },
      },
      CheckedClicked = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 22,
        TextNormalColor = "white",
      },
      CheckedDisabled = {
        File = "ui/buttons_1.png", Size = {300, 144}, Frame = 18,
      },
    })

### DefineCursor({tag = value, ...})

Define a cursor.

Name = "ident"
  Unique identifier of the cursor, used to reference it in config files and during startup.
Race = "race-name" or "any"
  Race to use this cursor with or "any" to use with any race.

Possible tags:

File = "icon-file"
  Path to the image graphic.
HotSpot = {x, y}
  Hot spot of the cursor in pixels. Relative to the sprite origin {0, 0}. The hot spot of a cursor is the point to which Bos Wars refers in tracking the cursor's position.
Size = {width, height}
  Size of the cursor in pixels.
Rate = millisecond
  Rate of changing the frames if using an animated cursor. The "rate" tells the engine how many milliseconds to hold each frame of the animation.

Note: Name, File and Size must be filled.

#### Example

    DefineCursor({
      Name = "cursor-cross",
      Race = "any",
      File = "ui/cursors/small_green_cross.png",
      HotSpot = {8,  8},
      Size = {18, 18}})

### DefineMenu("tag1", value1, ...)

FIXME: incomplete docu
Possible tags:

"geometry", {x, y, width, height}
  Position and size of the menu.
"name", "menu-name"
  Name of this menu.
"panel", "panel-name" or "none"
  Panel name (FIXME: how is it used?).
"default", number
  Initial selected item number
"init", "function_name"
  FIXME (function = "save-replay-init" or "scen-select-init" ? )
"exit", "function_name"
  FIXME ("speed-options-exit" or "load-game-exit" ? )
"netaction", "menu-action"
  FIXME: which are menu-action ?

"terminate-net-connect"
  FIXME

#### Example

    -- menu-sound-options
    DefineMenu("name", "menu-sound-options", "geometry", {224, 64, 352, 352},
      "panel", "panel5", "default", 23)

### DefineMenuGraphics({{"tag", value, ...}, ...})

Define the menu graphics for each of the races. FIXME : 1st graph is the 1st race ? ... Explain better

"file", "filename"
  Path to the file containing the menu graphics.
"size", {width, height}
  Width and height of an image in the menu graphic.

#### Example

    DefineMenuGraphics({
      {"file", "ui/buttons_1.png", "size", {300, 144}},
      {"file", "ui/buttons_2.png", "size", {300, 144}}})

### DefineMenuItem("tag1", value1, ...)

Add an item to a menu. This could be any item, it depends on the tags used.
FIXME: incomplete docu

"pos", {x, y}
  position of menuitem (FIXME abolute, or relative to something ?)
"menu", "menu-name"
  Menu this item belongs to.
"transparent"
  FIXME. No value
"flags", {"value",...}
  FIXME
  "active"
    FIXME
  "clicked"
    FIXME
  "selected"
    FIXME
  "disabled"
    FIXME
"font", "font-name"
  Use "game", "small", "large", "small-title", "large-title", "user1", "user2", "user3", "user4", "user5"
type, {arg_type}
  type could be :

"text", {values, ...}
  The item is a text label.
  The value is a list of tags, allowed tags:
  "align", "left" or "right" or "center"
    aligns text respectively at left, right or center.
  "caption", "text"
    The text.
  "func", "function-name"
    C handler. FIXME: when called?
  "color-normal", "color-name"
    FIXME.
  "color-reverse", "color-name"
    FIXME.
For example:

       "text", {"caption", "Connecting to server",
                "align", "center"}

"button" = {values, ...}
  The item is a button.
  The value is a list of tags like:
  "caption", "text"
    The text.
  "color-normal", "color-name"
    FIXME.
  "color-reverse", "color-name"
    FIXME.
  "hotkey", "key"
    A string like "f8". FIXME
  "func", "function-name" or Lua function
    Called when a button is clicked
  "style", style-name
    Complete list of possible styles-name: FIXME (not all for buttons)
    "main"
      FIXME
    "network"
      FIXME
    "gm-half"
      FIXME
    "132"
      FIXME
    "gm-full"
      FIXME
    "gem-round"
      FIXME
    "gem-square"
      FIXME
    "up-arrow"
      FIXME
    "down-arrow"
      FIXME
    "left-arrow"
      FIXME
    "right-arrow"
      FIXME
    "s-knob"
      FIXME
    "s-vcont"
      FIXME
    "s-hcont"
      FIXME
    "pulldown"
      FIXME
    "vthin"
      FIXME
    "folder"
      FIXME
    "sc-gem-round"
      FIXME
    "sc-gem-square"
      FIXME
    "sc-up-arrow"
      FIXME
    "sc-down-arrow"
      FIXME
    "sc-left-arrow"
      FIXME
    "sc-right-arrow"
      FIXME
    "sc-s-knob"
      FIXME
    "sc-s-vcont"
      FIXME
    "sc-s-hcont"
      FIXME
    "sc-pulldown"
      FIXME
    "sc-button-left"
      FIXME
    "sc-button"
      FIXME
    "sc-button-right"
      FIXME
    FIXME: describe them
Example.

        "button", {"size",  {224, 27},
                   "caption", "~!Surrender",
                   "hotkey", "s",
                   "func", "surrender-confirm-menu"
                   "style", "gm-full"}

"pulldown"
  The item is a pulldown menu.
  "size" = (width, height)
    Dimensions.
  "options", {"string1", "string2", ...}
    A list of strings to select from.
  "color-normal", "color-name"
    FIXME.
  "color-reverse", "color-name"
    FIXME.
  "func", function-name
    C handler. FIXME: when called?
  "state", "passive"
    FIXME
  "default", number
    An integer for the default selection id, starting with 0.
  "current", number
    An integer for the current selection id, starting with 0.
  "style" = style-name
    see above. FIXME which are available ?
Example:

        "pulldown", {"size", {152, 20},
                     "style", "pulldown",
                     "func", "null",
                     "options", {"Forest", "Winter", "Wasteland", "Orc Swamp"},
                     "default, 0, -- "Forest"
                     "current", 0} -- "Forest"

"listbox"
  The item is a list box.
  Allowed tags:
  "size" = (width, height)
    Dimensions.
  "func", function-name
    C handler. FIXME: when called?
  "handler", function-name
    C handler. FIXME: when is it called?
  "retopt", function-name
    C handler to retrieve the list of options, I guess. FIXME
  "startline", number
    For scrolling, I guess. Probably only used in savegames. FIXME
  "nlines", number
    Number of lines.
  "default", number
    An integer for the default selection id, starting with 0.
  "current", number
    An integer for the current selection id, starting with 0.
  "style" = style-name
    see above. FIXME which are available ?
  "color-normal", "color-name"
    FIXME.
  "color-reverse", "color-name"
    FIXME.
Example:

        "listbox", {"size", {288, 108},
                    "style", "pulldown",
                    "func", "scen-select-lb-action",
                    "retopt", "scen-select-lb-retrieve",
                    "handler", "scen-select-ok",
                    "nlines", 6}

"vslider" or "hslider", {values}
  The item is a vertical (or horizontal) slider.
  Allowed tags: size default current style (see above) and:
  "size" = (width, height)
    Dimensions.
  "func", function-name
    C handler. FIXME: when called?
  "handler", function-name
    C handler. FIXME: when is it called?
  "flags", "up" or "down" or "left" or "right" or "knob" or "cont"
    FIXME: never seen this used.
  "default", number
    An integer for the default selection id, starting with 0.
  "current", number
    An integer for the current selection id, starting with 0.
  "style" = style-name
    see above. FIXME which are available ?
  Examples:

        "vslider", {"size", {18, 108},
                    "func", "editor-main-load-vs-action",
                    "handler", "editor-main-load-ok"}

        "hslider", {"size", {198, 18},
                    "func", "master-volume-hs-action",
                    "handler", "scen-select-ok"}

"drawfunc", function-name
  The item is drawn from a C function.
  Example:

          DefineMenuItem("pos", {0, 0}, "font", "game", "init", "game-setup-init",
            "drawfunc", "game-draw-func",
            "menu" "menu-custom-game")

  FIXME.
"input"
  The item is a text input field.
  Allowed tags: size func style color-normal color-reverse (see above) and:
  "size" = (width, height)
    Dimensions.
  "func", function-name
    C handler, seems to be called when a key is pressed and just checks whether it is RETURN.
  "style" = style-name
    see above. FIXME which are available ?
  "color-normal", "color-name"
    FIXME.
  "color-reverse", "color-name"
    FIXME.
  "maxch", number
    Maximal number of characters. FIXME: never seen this used.
Example:

        "input", {"size", {212, 20},
          "func", "enter-master-action",
          "style", "pulldown"}

"gem"
  The item is a gem.
  Allowed tags: size func style text color-normal color-reverse (see above) and:
  "size" = (width, height)
    Dimensions.
  "func", function-name
    C handler. FIXME: when called?
  "state", "checked" or "unchecked" or "passive" or "invisible"
    FIXME.
  "style" = style-name
    see above. FIXME which are available ?
  "text", "text"
    The text.
  "color-normal", "color-name"
    FIXME.
  "color-reverse", "color-name"
    FIXME.
  "maxch", number
    Maximal number of characters. FIXME: never seen this used.
Example:

      "gem", {"size", {18, 18},
              "text", "640 x 480",
              "state", "unchecked",
              "func", "global-options-resolution-gem",
              "style", "gem-round"}

#### Example

        DefineMenuItem("pos", {16, 288 - 40}, "font", "large",
                       "button", {"size", {224, 27},
                                  "caption", "Return to Game (~<Esc~>)",
                                  "hotkey", "esc",
                                  "func", "game-menu-return",
                                  "style", "gm-full"},
                       "menu", "menu-game")

### DefinePanelContents({flag = value}, ...)

Define panel content when an unit is selected.

Ident = "name"
  identifier of the panel.
Pos = {x, y}
  position of the panel. The other coordonate are relative to this point.
DefaultFont = "font-name"
  Default font used in content if not redefined.
Condition = {flag = value}
  condition to show the panel.
  ShowOnlySelected = Boolean
    if true, show only if unit is selected (not just pointed).
  HideNeutral = Boolean
    if true, hide for neutral units.
  HideAllied = Boolean
    if true, hide for allied units.
  ShowOpponent = Boolean
    if true, show for opponent units.
  Variable = "only", "false", "true"
    For variables defined by DefineVariables(), show info if unit correpond with the criteria
  Flag = "only", "false", "true"
    For flags defined by DefineBoolFlags(), show info if unit correpond with the criteria
Contents = {flag = value}
  The info to show, and the method associated.
  Pos = {x, y}
    Coordinate to show element. (relatif to Panel' coordinates)
  Condition = {flag = value}
    Extra condition for content itself. Identic as Panel's condition
  More = {"method-name", ExtraData}
    Tell the method to show informations.
    "Text", "texttodisplay" or {flag = value}
      Show simple text "texttodisplay" and after one optional variable.
      Text = StringDesc
        text to display (See StringDesc in Trigger).
      Font = "font-name"
        font to use.
      Centered = boolean
        if true then text is centered on the position.
      Variable = "variable-name"
        Variable name to show. See DefineVariable() for more details.
      Component = "Name" or "Value" or "Max" or "Increase" or "Diff" or "Percent"
        component of value to show. Diff represent Max - value and Percent represent 100 * Value / Max.
      ShowName = boolean
        if true show the name of the unit and no variable information.
      Stat = boolean
        if true and value != Original value, then show original value + diff else show value. Original value is default value with no upgrade.
    "FormatedText", {flag = value, ...}
      Show text with a given format.
      Format = "texttodisplay"
        format of the text. Must have 1 %d (for number)or %s (for string). Use ~< ~> for reverse mode.
      Font = "font-name"
        font to use.
      Variable = "variable-name"
        Variable name to show. See DefineVariable() for more details.
      Component = "Name" or "Value" or "Max" or "Increase" or "Diff" or "Percent"
        component of value to show. Diff represent Max - value and Percent represent 100 * Value / Max.
      Centered = boolean
        if true then text is centered on the position.
    "FormatedText2", {flag = value, ...}
      Similar of FormatedText but with 2 variables.
      Format = "texttodisplay"
        format of the text. Must have 2 %d (for number)or %s (for string). Use ~< ~> for reverse mode.
      Font = "font-name"
        font to use.
      Variable1 = "variable-name"
        1st Variable name to show. See DefineVariable() for more details.
      Variable2 = "variable-name"
        2nd Variable name to show. See DefineVariable() for more details.
      Variable = "variable-name"
        Variable name to show(Assume var1 == var2). See DefineVariable() for more details.
      Component1 = "Name" or "Value" or "Max" or "Increase" or "Diff" or "Percent"
        component of the 1st value to show. Diff represent Max - value and Percent represent 100 * Value / Max.
      Component2 = "Name" or "Value" or "Max" or "Increase" or "Diff" or "Percent"
        component of 2nd value to show. Diff represent Max - value and Percent represent 100 * Value / Max.
      Component = "Name" or "Value" or "Max" or "Increase" or "Diff" or "Percent"
        Assume that component1 == component2.
      Centered = boolean
        if true then text is centered on the position.
    "Icon", {flag = value, ...}
      Draw the icon of a specified unit.
      Unit = "ItSelf" or "Inside" or "Container" or "Worker" or "Goal"
        which unit to draw : itself or first unit inside or its container or the unit which is building it or the goal objective.
    "LifeBar", {flag = value, ...}
      Draw a bar which represent the variable. Change color depend of the percent.
      Variable = "variable-name"
        Variable name to show. See DefineVariable() for more details.
      Height = value
        Height of the bar.
      Width = value
        width of the bar.
    "CompleteBar", {flag = value, ...}
      Draw a bar which represent the variable.
      Variable = "variable-name"
        Variable name to show. See DefineVariable() for more details.
      Height = value
        Height of the bar.
      Width = value
        width of the bar.
      Border = boolean
        if true then add border for the bar.

### DefineUI("race-name", screen-width, screen-height, tag1, value1, tag2, value2, ...)

"race-name"
  FIXME
screen-width, screen-height
  FIXME

All of those tags should be given:

"normal-font-color", "color-name"
  FIXME
"reverse-font-color", "color-name"
  FIXME
"filler", {tag, value, ...}
  FIXME:
  "file", "path"
    FIXME
  "pos", {x, y}
    FIXME
"resource-line", {"file-name", x, y}
  FIXME
  "file-name"
    FIXME
  x, y
    FIXME
"resources", {"ressource-name", {tag, value, ...}, ...}
  "ressource-name" or "food" or "score"
    FIXME
  FIXME
  "file", "file-name"
    FIXME
  "frame", number
    FIXME
  "pos", {x, y}
    FIXME
  "size", {width, height}
    FIXME
  "text-pos", {x, y}
    FIXME
"info-panel", {tag, value, ...}
  "panel", {tag, value}
    FIXME
    "file", "file-name"
      FIXME
    "pos", {x, y}
      FIXME
    "size", {width, height}
      FIXME
  "panels", "panel-ident" or {"panel-ident1", ...}
    Panel ident to show when unit is selected. (see DefinePanels() for more details)
  "selected", {tag, value}
    FIXME
    "single", {tag, value}
      FIXME
      "text", {tag, value}
        FIXME
      "icon", {tag, value}
        FIXME
    "multiple", {tag, value}
      FIXME
      "icons", {{tag, value}, ...}
        FIXME, see above (icon)
      "max-text", {tag, value}
        FIXME, see above (text)
  "training", {tag, value}
    FIXME
    "single", {tag, value}
      FIXME
      "icon", {tag, value}
        FIXME
    "multiple", {tag, value}
      FIXME
      "text", {tag, value}
        FIXME
      "icons", {{tag, value}, ...}
        FIXME, see above (icon)
  "transporting", {tag, value}
    FIXME
    "icons", {{tag, value}, ...}
      FIXME, see above (icon)
  "completed-bar", {tag, value}
    FIXME
    "color", {r, g, b}
      FIXME
    "has-shadow"
      FIXME
"button-panel", {tag, value, ...}
  "panel", {tag, value, ...}
    FIXME
    "file", "filename"
      FIXME
    "pos", {x, y}
      FIXME
  "icon", {tag, value, ...}
    FIXME
    FIXME
      FIXME
"pie-menu", {tag, value, ...}
  "radius", radius
    The radius in pixels of the pie menu.
  "file", "filename"
    The image file for the background of the pie menu.
  "mouse-button", "buttonname"
    Which mouse button pops up the pie menu. Can be "right", "middle" or "left".
"map-area", {"pos", {x, y}, size, {w, h}}
  FIXME
"menu-panel", {tag, value}
  FIXME
  "panel", {tag, value, ...}
    FIXME
    "file", "filename"
      FIXME
    "pos", {x, y}
      FIXME
  type-menu-button, {tag, value, ...}
    type-menu-button is one of the following :
    "menu-button"
      FIXME
    "network-menu-button"
      FIXME
    "network-diplomacy-button"
      FIXME
    And tag and value :
    "caption" , "text"
      FIXME
    "pos", {x, y}
      FIXME
    "style", "style-name"
      FIXME, see above
"minimap", {tag, value}
  There is a minimap panel an the minimap on it. The panel graphic has certain palette restrictions (FIXME: exactly? probably the same as the tileset?).
  "file", filename
    FIXME
  "panel-pos", {x, y}
    FIXME
  "pos", {x, y}
    Pos is the absoloute position of the minimap on the screen (the upper left corner of it).
  "size", {w, h}
    FIXME
  "transparent"
    If you give "transparent", the panel graphic will be displayed on unexplored terrain, black otherwise.
"status-line", {tag, value}
  FIXME
  "file", "file-name"
    FIXME
  "pos", {x, y}
    FIXME
  "text-pos", {x, y}
    FIXME
  "font", "font-name"
    FIXME
"cursors", {tag, name}
  FIXME
  "point", "name"
    FIXME
  "glass", "name"
    FIXME
  "cross", "name"
    FIXME
  "yellow", "name"
    FIXME
  "green", "name"
    FIXME
  "red", "name"
    FIXME
  "scroll", "name"
    FIXME
  "arrow-e" or "arrow-ne" or "arrow-n" or "arrow-nw" or "arrow-w" or "arrow-sw" or "arrow-s" or "arrow-se", "name"
    FIXME
"menu-panels", {"panel-name1", "file1", ...}
  FIXME: this really needs docu or change, if you dig out the requirement of the pictures, write them down here. Example:
"victory-background", "file-name"
  Background image for the victory screen. The image will be scaled.
"defeat-background", "file-name"
  Background image for the victory screen. The image will be scaled.

### DefineViewports("mode", mode, "viewport", {mapx, mapy}, ...)

Define the viewports. Only used in savegames, but could be useful for scenarios.

"mode", number
  Number corresponding to the viewport mode. See the ViewportMode enum. FIXME
"viewport", {mapx, mapy}
  X, Y coordinate of the map tile.

#### Example

    -- Defines the viewports to use mode 1 (split horizontal) with the first
    -- viewport having map coordinates 82,31 and the second having coordinates 64,31.
    DefineViewports("mode", 1, "viewport", {82, 31},
                               "viewport", {64, 31})

### SetGameCursor("cursor-ident")

Set the game cursor.

"cursor-ident"
  Unique identifier of the cursor.

#### Example

    -- Set the game cursor to 'cursor-point'.
    SetGameCursor("cursor-point")

All trademarks and copyrights on this page are owned by their respective owners.