Skip to content

Notes

Notes, a static global class, allows access to the on-screen notes and the notebook.

Example function call: Notes.setNotes()

Function Summary

Notebook Functions

Functions that interact with the in-game notebook tabs.

Function Name Description Return  
addNotebookTab( parameters) Adds a notebook tab, returning its index.
editNotebookTab( parameters) Edit an existing Tab in the notebook.
getNotebookTabs() Returns Table containing data on all tabs in the notebook.
removeNotebookTab( index) Remove a notebook tab.

Notes Functions

Functions that interact with the on-screen notes (lower right corner of screen).

Function Name Description Return  
getNotes()
getNotes()
Returns the contents of the on-screen notes section.
setNotes( notes) Replace the text in the notes window with the string.

Function Details

Notebook Function Details

addNotebookTab(...)

Add a new notebook tab. If it failed to create a new tab, a -1 is returned instead. Indexes for notebook tabs begin at 0.

addNotebookTab(parameters)

  • parameters: A Table containing spawning parameters.
    • parameters.title: Title for the new tab.
    • parameters.body: Text to place into the body of the new tab.
      • Optional, defaults to an empty string
    • parameters.color: Player Color for the new tab's color.
      • Optional, defaults to "Grey"
parameters = {
    title = "New Tab",
    body = "Body text example.",
    color = "Grey"
}
Notes.addNotebookTab(parameters)

editNotebookTab(...)

Edit an existing Tab in the notebook. Indexes for notebook tabs begin at 0.

editNotebookTab(parameters)

  • parameters: A Table containing instructions for the notebook edit.
    • parameters.index: Index number for the tab.
    • parameters.title: Title for the tab.
      • Optional, defaults to the current title of the tab begin edited.
    • parameters.body: Text for the body for the tab.
      • Optional, defaults to the current body of the tab begin edited.
    • parameters.color: Player Color for who the tab belongs to.
      • Optional, defaults to the current color of the tab begin edited.
params = {
    index = 5,
    title = "Edited Title",
    body = "This tab was edited via script.",
    color = "Grey"
}
Notes.editNotebookTab(params)

getNotebookTabs()

Returns a Table containing data on all tabs in the notebook. Indexes for notebook tabs begin at 0.

--Example Usage
tabInfo = Notes.getNotebookTabs()
--Example Returned Table
{
    {index=0, title="", body="", color="Grey"},
    {index=1, title="", body="", color="Grey"},
    {index=2, title="", body="", color="Grey"},
}


removeNotebookTab(...)

Remove a notebook tab. Notebook tab indexes begin at 0.

removeNotebookTab(index)

  • index: Index for the tab to remove.
Notes.removeNotebookTab(0)

Notes Function Details

setNotes(...)

Replace the text in the notes window with the string. The notes is an area which displays text in the lower-right corner of the screen.

setNotes(notes)

  • notes: What to place into the notes area.
Notes.setNotes("This appears in the notes section")