world.NoteColour
Chooses which custom colour will be used for world notes.
Prototype
short NoteColour;
Description
You can get or set this to change the colour (number) that the *next* world.note will be displayed in. The valid range is 0 to 16, where 0 is "no change", 1 is custom colour 1, through to 16 for custom colour 16.
If notes are currently being displayed in RGB mode (using NoteColourFore or NoteColourBack) then getting the NoteColour will return -1.
If notes are currently being displayed in RGB mode (using NoteColourFore or NoteColourBack) then setting the NoteColour will switch back to palette mode (the default).
It may be easier to use ColourNote to display notes in a different colour (in a single function) rather than changing the note colour and then doing a Note.
VBscript example
world.notecolour = 15 ' set note colour to use custom colour 15
world.note "This will be in custom colour 15"
world.note world.notecolour ' display current note colour
Jscript example
world.notecolour = 15; // set note colour to use custom colour 15
world.note("This will be in custom colour 15");
world.note(world.notecolour); // display current note colour
PerlScript example
$world->{notecolour} = 15; # set note colour to use custom colour 15
$world->note("This will be in custom colour 15");
$world->note($world->{notecolour}); # display current note colour
Python example
world.notecolour = 15 # set note colour to use custom colour 15
world.note("This will be in custom colour 15")
world.note(world.notecolour) # display current note colour
Lua example
Note (GetNoteColour ())
SetNoteColour (15) -- use custom colour 15
Lua notes
Lua implements this as two functions:
GetNoteColour - gets the note colour
SetNoteColour - sets the note colour
Return value
This is a property. You can use it to find the current note colour.
Related topic
See also
| Function | Description |
|---|---|
| ColourNote | Sends a message to the output window in specified colours |
| ColourTell | Sends a message to the output window in specified colours - not terminated by a newline |
| Note | Sends a note to the output window |
| NoteColourBack | Chooses which RGB colour will be used for world notes - background colour |
| NoteColourFore | Chooses which RGB colour will be used for world notes - text colour |
| NoteColourName | Chooses which RGB colour name will be used for world notes - text and background |
| NoteColourRGB | Chooses which RGB colour will be used for world notes - text and background |
| NoteStyle | Sets the style for notes |
| Tell | Sends a message to the output window - not terminated by a newline |