The staff page (fl_staff_list): a scrollable list with a header for every role that has members, the roles with the highest immunity first, and an fl_staff_row for every member. The plugin calls set_members with what the server has sent. Derives from fl_base_panel.

Summary

Methods

Init()client
Creates the scroll panel that holds the list, asks the server for the members and makes the panel known to the plugin.
Lets the list fill the page.
Shows the staff members that the server has sent: recreates the list, grouped by role.
Replaces the list with a single line of text, such as the notice that nobody is staff.

Methods

Creates the scroll panel that holds the list, asks the server for the members and makes the panel known to the plugin.

PANEL:PerformLayout(w, h)

client plugins/admin/plugin/views/cl_staff_list.lua:32

Lets the list fill the page.

Parameters

  • w Number panel width
  • h Number panel height

PANEL:set_members(members)

client plugins/admin/plugin/views/cl_staff_list.lua:57

Shows the staff members that the server has sent: recreates the list, grouped by role. Within a role the members who are on the server come first.

Parameters

  • members List<Map> members with the steam_id, name, role and online fields

PANEL:show_notice(text)

client plugins/admin/plugin/views/cl_staff_list.lua:41

Replaces the list with a single line of text, such as the notice that nobody is staff.

Parameters

  • text String

Defined in