wavelength 1.0.0
Loading...
Searching...
No Matches
netlpadplayerpanel.h
Go to the documentation of this file.
1#pragma once
2
3#include <list>
4
6#include "met/avatarpanel.h"
7#include "met/netlpadpanel.h"
10#include "script/dataarray.h"
12#include "ui/uipanel.h"
13
21public:
23 static constexpr int kNumPlayerButtons = 4;
24
33 NetLPadPlayerPanel(DataArray *pData, const char *pszDir) : AvatarPanel(pData, pszDir) {
34 }
35
43 }
44
54 static UIPanel *New(DataArray *pData, const char *pszDir) {
55 return new NetLPadPlayerPanel(pData, pszDir);
56 }
57
66 bool DispatchPriv(Message *pMsg) override;
67
76 void Enter(bool bForce, float fTime) override;
77
86 void Focus() override;
87
94 void Unfocus() override;
95
104 void Update(std::list<NetLaunchpadPlayer> *pPlayers) override;
105
106private:
116 void ShowPlayer(NetLaunchpadPlayer *pPlayer);
117
126 void UpdateHelp();
127
138 bool HandleFocusChange(UIComponentFocusChangeMsg *pMsg);
139
151 bool HandleJoypad(JoypadInputMsg *pMsg);
152
153 int mReserved104[3]; // +0x104, not yet identified.
154 int mSelected;
155 int mReserved114; // +0x114, not yet identified.
156 AvatarPartSet mReserved118; // +0x118, constructed but not yet seen in use.
157};
AvatarPanel(DataArray *pData, const char *pszDir)
Construct the panel from its script description, showing no Freq.
Parts and colours of a player's avatar, the Freq the Freq maker edits.
Definition avatarpartset.h:23
Reference-counted array of script data nodes.
Definition dataarray.h:20
Message the controller poll sends when a button is pressed or released.
Definition joypadinputmsg.h:23
Base of every event the game passes between a MsgSource and a MsgSink.
Definition message.h:40
Mix-in for a panel of the launchpad screens that shows the players of the online session.
Definition netlpadpanel.h:13
void Unfocus() override
Dim the tab, the background, and the focused button, and show the help of the launchpad.
void Update(std::list< NetLaunchpadPlayer > *pPlayers) override
Show the players on the panel's rows and buttons, and give the focus back to the player who had it,...
static constexpr int kNumPlayerButtons
The number of player buttons.
Definition netlpadplayerpanel.h:23
static UIPanel * New(DataArray *pData, const char *pszDir)
Create a panel from its script description.
Definition netlpadplayerpanel.h:54
NetLPadPlayerPanel(DataArray *pData, const char *pszDir)
Construct the panel from its script description.
Definition netlpadplayerpanel.h:33
bool DispatchPriv(Message *pMsg) override
Route the controller and the focus messages.
void Enter(bool bForce, float fTime) override
Enter with the first player chosen, and dim the panel.
~NetLPadPlayerPanel() override
Destroy the panel.
Definition netlpadplayerpanel.h:42
void Focus() override
Take the focus, light the tab and the background, and show the help of the panel.
Message a panel sends before it moves its focus to another component.
Definition uicomponentfocuschangemsg.h:26
UIPanel(DataArray *pData, const char *pszDir)
Construct a hidden panel from its script description.
The description of one player of the online session this console is in.
Definition netlaunchpadplayer.h:13