fl_gamemaster_panel panelclient
Panel defined in plugin/views/cl_gamemaster_panel.lua
Part of Gamemastery
The gamemaster panel (fl_gamemaster_panel): a scrollable row of cards, one for every
pool character, a button that releases the pool character the local player plays and a
hint. While a card is dragged the whole tab menu fades out of the way so that the world
can be seen, and the card dropped anywhere, over the faded panel too, places its character
in the world where the cursor points; a right click cancels the drag. The panel rebuilds
itself whenever the pool arrives from the server, or once the drag is over when it arrives
during one.
Summary
Methods
Methods
Creates the title, the hint, the release button and the card row, makes the panel and the tab menu take dropped cards and asks the server for the pool.
Stops the tab menu from taking dropped cards once the panel is gone, and brings the menu back if the panel goes away during a drag.
Positions the title, the hint, the release button, the card row and the text shown when the pool is empty.
Parameters
- w Number
- h Number
Recreates a card for every pool character, shows the release button while the local player plays one and the empty text when there are none. Waits until the drag is over while a card is dragged, so that the dragged card is not removed under the cursor.
Fades the tab menu out while a card is dragged so that the world behind it can be seen, and brings it back afterwards, rebuilding the cards if the pool arrived in the meantime.
Parameters
- dragging Boolean
Notices when a card starts or stops being dragged. Watching the drag state rather than the card makes sure the menu comes back even when the card goes away during the drag.