Visuel notes

This commit is contained in:
Crizomb 2025-06-13 21:31:16 +02:00
parent e2fb0d911a
commit 05f8b11dec
14 changed files with 137 additions and 50 deletions

View file

@ -10,7 +10,7 @@ TEST(NoteFileTest, Yes) { EXPECT_EQ(0, 0); }
TEST(NoteTileTest, CreateTile) {
NoteTile::clear();
NoteTile::create(2.0f, 0.5f, NotePlaceEnum::Right);
NoteTile::create(2.0f, 0.5f, NotePlaceEnum::Right, 0.0);
EXPECT_FLOAT_EQ(NoteTile::getExistingTiles()[0]->getPlayTime(), 2.0f);
EXPECT_FLOAT_EQ(NoteTile::getExistingTiles()[0]->getGoodInterval(), 0.5f);
EXPECT_EQ(NoteTile::getExistingTiles()[0]->getPlace(), NotePlaceEnum::Right);
@ -21,9 +21,9 @@ TEST(NoteTileTest, CreateTile) {
// est negatif est divisé par 2, voir checkPress
TEST(NoteTileTest, CheckGoodPress) {
NoteTile::clear();
NoteTile::create(2.0f, 0.5f, NotePlaceEnum::Right);
NoteTile::create(3.0f, 0.5f, NotePlaceEnum::Middle);
NoteTile::create(0.5f, 0.2f, NotePlaceEnum::Left);
NoteTile::create(2.0f, 0.5f, NotePlaceEnum::Right, 0.0);
NoteTile::create(3.0f, 0.5f, NotePlaceEnum::Middle, 0.0);
NoteTile::create(0.5f, 0.2f, NotePlaceEnum::Left, 0.0);
EXPECT_FALSE(NoteTile::checkPress(1.0f, NotePlaceEnum::Left));
EXPECT_FALSE(NoteTile::checkPress(0.7f, NotePlaceEnum::Left));