Chat Paginate

The Chat Paginate task is available for scripts to use to simply display lists to a player in a paginated view.

The view supports players clicking on a previous and next page as well as more information about each list item.

To use this view, simply run drustcraft.chat_paginate with the following definitions:

Item

Detail

1

List title

2

Page to display

3

List of items as a list_single

4

Command to call for previous/next page [optional]

The page number will be appended to the end of the command.

5

Command to call for item information [optional]

The item will be appended to the end of the command.

# To display a list of server permission groups with the following options:
# Title = Groups
# Page number = First definition or 1 if not existant
# Group is <server.permission_groups> included as a list_single
# Run the command "/group list <page-number>" on prev/next page click
# Run the command "/group info <item>" on item information click
- define page_no:<[1]||1>
- run drustcraft.chat_pagination 'def:<list[Groups|<[page_no]>].include_single[<server.permission_groups>].include[group list|group info]>'