wavelength 1.0.0
Loading...
Searching...
No Matches
powerupscreen.h
Go to the documentation of this file.
1#pragma once
2
3#include <vector>
4
5#include "met/freqscreen.h"
6#include "os/string.h"
7#include "script/dataarray.h"
10
18class PowerupScreen : public FreqScreen {
19public:
26 ~PowerupScreen() override = default;
27
35 explicit PowerupScreen(DataArray *pData);
36
47 static UIScreen *New(DataArray *pData) {
48 return new PowerupScreen(pData);
49 }
50
59 bool DispatchPriv(Message *pMsg) override;
60
70 void Enter(UIScreen *pPrevScreen, float fTime) override;
71
82
92
93private:
94 int mLevel;
95 std::vector<String> mLabels;
96};
Reference-counted array of script data nodes.
Definition dataarray.h:20
FreqScreen(DataArray *pData)
Construct a screen from its script description.
Base of every event the game passes between a MsgSource and a MsgSink.
Definition message.h:40
~PowerupScreen() override=default
Destroy the object.
static UIScreen * New(DataArray *pData)
Create a screen from its script description.
Definition powerupscreen.h:47
bool HandleSelect(UIComponentSelectMsg *pMsg)
Record the level shown as the power-up level of the game when the cross button chooses the powerup bu...
PowerupScreen(DataArray *pData)
Construct the screen from its script description.
bool HandleSelectStart(UIComponentSelectStartMsg *pMsg)
Show the previous or the next level when left or right is pressed on the powerup button.
void Enter(UIScreen *pPrevScreen, float fTime) override
Build the label of every power-up level, show the label of the level of the game, and start the entry...
bool DispatchPriv(Message *pMsg) override
Route a chosen button and a press on a button, and pass on every other message.
Message a component sends when the player chooses it.
Definition uicomponentselectmsg.h:28
Message a component sends when the player presses the button that chooses it.
Definition uicomponentselectstartmsg.h:27
UIScreen(DataArray *pData)
Construct a screen from its script description.