Skip to content

Commit

Permalink
Add base practice & replay gameplay classes
Browse files Browse the repository at this point in the history
  • Loading branch information
poco0317 committed Jul 30, 2019
1 parent 0fd192d commit 0375254
Show file tree
Hide file tree
Showing 5 changed files with 54 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/Etterna/Screen/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
list(APPEND SCREEN_GAMEPLAY_SRC
"Gameplay/ScreenGameplay.cpp"
"Gameplay/ScreenGameplayNormal.cpp"
"Gameplay/ScreenGameplaySyncMachine.cpp")
"Gameplay/ScreenGameplaySyncMachine.cpp"
"Gameplay/ScreenGameplayReplay.cpp"
"Gameplay/ScreenGameplayPractice.cpp")
list(APPEND SCREEN_GAMEPLAY_HPP
"Gameplay/ScreenGameplay.h"
"Gameplay/ScreenGameplayNormal.h"
"Gameplay/ScreenGameplaySyncMachine.h")
"Gameplay/ScreenGameplaySyncMachine.h"
"Gameplay/ScreenGameplayReplay.h"
"Gameplay/ScreenGameplayPractice.h")

list(APPEND SCREEN_OPTION_SRC
"Options/ScreenOptions.cpp"
Expand Down
12 changes: 12 additions & 0 deletions src/Etterna/Screen/Gameplay/ScreenGameplayPractice.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#include "Etterna/Globals/global.h"
#include "ScreenGameplayPractice.h"
#include "Etterna/Models/Misc/Difficulty.h"

REGISTER_SCREEN_CLASS(ScreenGameplayPractice);

void
ScreenGameplayPractice::FillPlayerInfo(PlayerInfo* playerInfoOut)
{
playerInfoOut->Load(
PLAYER_1, MultiPlayer_Invalid, true, Difficulty_Invalid);
}
12 changes: 12 additions & 0 deletions src/Etterna/Screen/Gameplay/ScreenGameplayPractice.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#ifndef ScreenGameplayPractice_H
#define ScreenGameplayPractice_H

#include "ScreenGameplay.h"

class ScreenGameplayPractice : public ScreenGameplay
{
public:
virtual void FillPlayerInfo(PlayerInfo* playerInfoOut);
};

#endif
12 changes: 12 additions & 0 deletions src/Etterna/Screen/Gameplay/ScreenGameplayReplay.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#include "Etterna/Globals/global.h"
#include "ScreenGameplayReplay.h"
#include "Etterna/Models/Misc/Difficulty.h"

REGISTER_SCREEN_CLASS(ScreenGameplayReplay);

void
ScreenGameplayReplay::FillPlayerInfo(PlayerInfo* playerInfoOut)
{
playerInfoOut->Load(
PLAYER_1, MultiPlayer_Invalid, true, Difficulty_Invalid);
}
12 changes: 12 additions & 0 deletions src/Etterna/Screen/Gameplay/ScreenGameplayReplay.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#ifndef ScreenGameplayReplay_H
#define ScreenGameplayReplay_H

#include "ScreenGameplay.h"

class ScreenGameplayReplay : public ScreenGameplay
{
public:
virtual void FillPlayerInfo(PlayerInfo* playerInfoOut);
};

#endif

0 comments on commit 0375254

Please sign in to comment.