MULTIBOXING COMMANDS

Foreground

Permits a hotkey to be triggered only when a particular kind of window is in the foreground.

Syntax

Foreground ( which )

Parameters

Which can be any or daoc.

Examples

The following hotkey can be triggered at any time regardless of which window is in the foreground:

Hotkey ( Ctrl Comma )
{
   Foreground ( any )
   Key ( 7 )
}

The following hotkey can be triggered only when DAOC is in the foreground.

Hotkey ( Ctrl Comma )
{
   Foreground ( daoc )
   Key ( 7 )
}

Instead of writing Foreground in individual hotkeys, you can write it in a Defaults block like this:

Defaults
{
   Foreground ( daoc )
}

When does a hotkey get triggered?

By default, a hotkey gets triggered no matter which window is in the foreground. But what if you want a hotkey to work only when you’re in DAOC? In other words, what if, for example, you want the hotkey to be disabled when you’re clicking on webpages? Here’s how you do it:

hotkey (F7)
{
   foreground ( daoc )
   slash ( "/say Hi boys and girls." )
}

That foreground command means, “Execute this hotkey only when DAOC is the active window.” If you want the opposite behavior — in other words, if you want hotkeys to always execute no matter what window is in the foreground — you can write foreground (any) but any is the default so you don’t have to bother. Just omit foreground completely and you'll get any automatically.

Related

Defaults

This page was first published on November 27, 2017 and last modified on November 27, 2017