ColourTell
Script function

world.ColourTell

DOC_scripting Read about scripting

Type

Method

Summary

Sends a message to the output window in specified colours - not terminated by a newline

Prototype

void ColourTell(BSTR TextColour, BSTR BackgroundColour, BSTR Text);

DOC_data_types View list of data type meanings


Description

This lets you do a "tell" in a specified colour. It is not transmitted to the world. It is useful for making comments to yourself. The note is NOT automatically terminated by a newline, so you can use ColourTell multiple times on one line (eg. to change colour in mid-line). The note colour is saved and restored, so that the world note colour is unchanged after using this function (however the new colour is used for the tell itself).

eg.

world.ColourTell "red", "blue", "Hello there"

The colour is specified by colour name - you can use the MUSHclient colour picker to see all possible colour names, or type: world.Debug "colours". You can also specify colours in HTML format, like this:

world.ColourTell "#FAEBD7", "#FFB6C1", "Hi there"

If you leave a colour name blank, it is unchanged. Thus you could do this to get red text on the existing background:

world.ColourTell "red", "", "Hello there"


A new line will automatically be started by output from the MUD, or a command that you type being echoed to the output window. You can send a new line yourself by sending vbCRLF (in Visual Basic) or n in Jscript or Perlscript.



VBscript example

world.ColourTell "red", "blue", "Hello "
world.ColourTell "white", "green", "there"



Jscript example

world.ColourTell ("red", "blue", "Hello ");
world.ColourTell ("white", "green", "there");



PerlScript example

$world->ColourTell ("red", "blue", "Hello ");
$world->ColourTell ("white", "green", "there");



Python example

world.ColourTell ("red", "blue", "Hello ")
world.ColourTell ("white", "green", "there")



Lua example

ColourTell ("red", "blue", "Hello there ",
            "white", "green", "everyone")



Lua notes

You can supply any number of arguments, however they must be in groups of three:

* foreground colour
* background colour
* text

The example above shows how you might send two lots of text coloured different ways.



Return value

Nothing.




See Also ...

Topics

DOC_colours Colour management
DOC_defaults Default triggers/aliases/timers/macros/colours

Functions

FNC_AdjustColour AdjustColour (Adjust an RGB colour)
FNC_ANSI ANSI (Generates an ANSI colour sequence)
FNC_BoldColour BoldColour (Gets/sets the RGB colour for one of the 8 ANSI bold colours)
FNC_ColourNameToRGB ColourNameToRGB (Converts a named colour to a RGB colour code.)
FNC_ColourNote ColourNote (Sends a message to the output window in specified colours)
FNC_CustomColourBackground CustomColourBackground (Sets the RGB value for the background of a custom colour)
FNC_CustomColourText CustomColourText (Sets the RGB value for the text of a custom colour)
FNC_GetCustomColourName GetCustomColourName (Gets the name of a custom colour)
FNC_GetMapColour GetMapColour (Returns the mapping for how a particular colour will be displayed)
FNC_MapColour MapColour (Changes the colour mapping - the way colours are displayed)
FNC_MapColourList MapColourList (Returns an array of all the mapped colours)
FNC_NormalColour NormalColour (Gets/sets the RGB colour for one of the 8 ANSI normal colours)
FNC_Note Note (Sends a note to the output window)
FNC_NoteColour NoteColour (Chooses which custom colour will be used for world notes.)
FNC_NoteColourBack NoteColourBack (Chooses which RGB colour will be used for world notes - background colour)
FNC_NoteColourFore NoteColourFore (Chooses which RGB colour will be used for world notes - text colour)
FNC_NoteColourName NoteColourName (Chooses which RGB colour name will be used for world notes - text and background)
FNC_NoteColourRGB NoteColourRGB (Chooses which RGB colour will be used for world notes - text and background)
FNC_NoteStyle NoteStyle (Sets the style for notes)
FNC_PickColour PickColour (Invokes the MUSHclient colour picker dialog)
FNC_RGBColourToName RGBColourToName (Converts an RGB colour code to its equivalent name)
FNC_Send Send (Sends a message to the MUD)
FNC_SetCustomColourName SetCustomColourName (Sets the name of a custom colour)
FNC_Tell Tell (Sends a message to the output window - not terminated by a newline)

(Help topic: function=ColourTell)

DOC_contents Documentation contents page