persona-3-dual
A DS demake of Persona 3
Loading...
Searching...
No Matches
StationView.cpp
Go to the documentation of this file.
1#include "StationView.hpp"
2#include "data/audioDb.hpp"
3#include "events/UIEvents.hpp"
4
8
13
15{
17 camConfig.initialAngle = ae::q20_12_t{1.5708f} * ae::q20_12_t{2};
18 camConfig.distance = ae::q20_12_t{1.0};
19 camConfig.height = height + ae::q20_12_t{0.6};
20 camConfig.lookAhead = ae::q20_12_t{0.2};
21 camConfig.angleIncrement = ae::q20_12_t{0.05};
22 camConfig.isRotationLocked = true;
23}
24
26{
27 movement->configureMovement(MovementConfig(STATION_MAP_WIDTH,
28 STATION_MAP_HEIGHT,
29 &station_map[0][0],
31 dbEntry->worldOffsetX,
32 dbEntry->worldOffsetZ,
34 speed,
35 height,
38}
39
41{
42 switch (tile)
43 {
45 {
47 }
48 default:
49 {
50 break;
51 }
52 }
53
55}
56
62
64{
66
68 setupMenuHUD("Station");
69
70 std::array<UIScreen*, 5> screens = {menuHUDScreen, pauseMenuScreen};
71 std::array<UIMenu*, 10> menus = {pauseMenuCmpt};
72
73 ae::broadcastEvent(Event::ConfigureUIScreen{bgSub, bgMain, &oamSub, &oamMain, screens});
74 ae::broadcastEvent(Event::ConfigureUIMenu{textSub, menus});
75}
TileType
ViewState
Definition StateTypes.hpp:4
Events for UISystem.
std::array< int, 2 > bgMain
MenuHUDScreen * menuHUDScreen
MusicComponent * musicCmpt
const EnvironmentDbEntry * dbEntry
MovementComponent * movement
Event::ConfigureCamera camConfig
uint16_t * textVideoBuffer
std::array< int, 3 > bgSub
const ae::q20_12_t tileSize
void setupPauseMenu()
Sets up the pause menu.
uint16_t * textVideoBufferSub
PauseMenu * pauseMenuCmpt
TextComponent * text
void setupMenuHUD(const std::string &location)
Sets up the menu HUD.
TextComponent * textSub
PauseMenuScreen * pauseMenuScreen
void setupMusic() override
const Point2D< ae::q20_12_t > characterTranslate
void setupText() override
void setupCamera() override
const Point2D< ae::q20_12_t > characterSize
void setupUI() override
void setupMovement() override
ViewState onTileCheck(TileType tile, u32 pressed) override
const ae::q20_12_t speed
const ae::q20_12_t height
const ae::q20_12_t characterFacingAngle
All parameters needed to configure UIMenus.
Definition UIEvents.hpp:52
All parameters needed to configure UIScreens.
Definition UIEvents.hpp:22
A struct that holds initial config values for the MovementComponent.
A struct that holds initial config values for the TextComponent.