ISInterface:AddAlias

From Lavish Software Wiki
Jump to navigation Jump to search

Syntax

  • bool AddAlias(char *Replace, char *With)

Purpose

An alias is something that means the same as another, also meaning "also known as" (alias 'aka'). In the LavishScript context, an alias is a way to make your own name for a command, possibly customizing the parameters along the way.

Usage

Parameters

  • char *Replace
[in]String to be replaced by With
  • char *With
[in]String to replace the Replace text with

Return Value

Returns true on success, false on failure

Examples

Example code
void ISXTest::RegisterAliases()
{
    pISInterface->AddAlias("Hi","echo Hi bob! How was work? What are you going to do tonight?");
    pISInterface->AddAlias("pipforegroundsize","WindowSize -rescale -viewable ${Display.Width}x${Display.Height}");
}

See Also