cwClasses panelclient
Panel defined in core/derma/cl_classes.lua
Summary
Methods
Init()client
Sizes the classes menu tab to the menu, creates its list and builds it.
IsButtonVisible()client
Returns whether the classes tab should be shown in the menu.
OnMenuOpened()client
Rebuilds the list when the menu is opened while this tab is active.
OnSelected()client
Rebuilds the list when the tab is selected in the menu.
Paint(w, h)client
Draws the light grey panel background.
PerformLayout(w, h)client
Does nothing; the list lays itself out.
Rebuild()client
Rebuilds the list of classes the local player can see.
Think()client
Rebuilds the list when the local player's class changes.
Methods
Sizes the classes menu tab to the menu, creates its list and builds it.
Returns whether the classes tab should be shown in the menu.
Returns
- Boolean
truewhen the player can see a class other than their current one, otherwisenil
Rebuilds the list when the menu is opened while this tab is active.
Rebuilds the list when the tab is selected in the menu.
Draws the light grey panel background.
Parameters
- w
- h
Does nothing; the list lays itself out.
Parameters
- w
- h
Rebuilds the list of classes the local player can see.
Classes are sorted by wages, highest first, then by name. A class is listed as a cwClassesItem
when the player has access to it and the PlayerCanSeeClass hook allows it.
Rebuilds the list when the local player's class changes.