CPowerUpBrick + CPowerUp exists. Can drop from brick and be grabbed for MultiBall.

This commit is contained in:
PlatinumSkink
2015-09-22 17:55:12 +02:00
parent 2797a0f6c3
commit f6b6f05c37
10 changed files with 275 additions and 33 deletions
+15 -5
View File
@@ -7,24 +7,29 @@
#include "Core/System.h"
#include "Core/CTransform.h"
#include "Core/EventBroker.h"
#include "Core/World.h"
#include "Rendering/CSprite.h"
#include "Rendering/CModel.h"
#include "Game/CBrick.h"
#include "Core/EventBroker.h"
#include "Core/World.h"
#include "Game/CBall.h"
#include "Game/CLife.h"
#include "Game/CPowerUp.h"
#include "Game/EStageCleared.h"
#include "Game/ELifeLost.h"
#include "Game/EResetBall.h"
#include "Game/EScoreEvent.h"
#include "Game/EMultiBall.h"
#include "Game/EGameOver.h"
#include "Game/ECreatePowerUp.h"
#include "Game/Bricks/CPowerUpBrick.h"
#include "Physics/CBoxShape.h"
#include "Physics/CPhysics.h"
#include "Physics/CCircleShape.h"
#include "Physics/ESetImpulse.h"
#include "Physics/EContact.h"
#include "Sound/CCollisionSound.h"
#include "Game/PadSystem.h"
#include <fstream>
#include <iostream>
#include <intrin.h>
@@ -75,6 +80,8 @@ public:
void SetLives(const int& lives) { m_Lives = lives; }
int& PastLives() { return m_PastLives; }
void SetPastLives(const int& pastLives) { m_PastLives = pastLives; }
int& MultiBalls() { return m_MultiBalls; }
void SetMultiBalls(const int& multiBalls) { m_MultiBalls = multiBalls; }
int& Score() { return m_Score; }
void SetScore(const int& score) { m_Score = score; }
int& NumberOfBricks() { return m_NumberOfBricks; }
@@ -93,6 +100,7 @@ private:
bool m_Initialized = false;
int m_Lives = 3;
int m_PastLives = 3;
int m_MultiBalls = 0;
int m_Score = 0;
int m_NumberOfBricks;
int m_Rows = 7;
@@ -104,11 +112,13 @@ private:
dd::EventRelay<LevelSystem, dd::Events::LifeLost> m_ELifeLost;
dd::EventRelay<LevelSystem, dd::Events::ScoreEvent> m_EScoreEvent;
dd::EventRelay<LevelSystem, dd::Events::MultiBall> m_EMultiBall;
dd::EventRelay<LevelSystem, dd::Events::CreatePowerUp> m_ECreatePowerUp;
bool OnContact(const dd::Events::Contact &event);
bool LifeLost(const dd::Events::LifeLost &event);
bool ScoreEvent(const dd::Events::ScoreEvent &event);
bool MultiBall(const dd::Events::MultiBall &event);
bool OnLifeLost(const dd::Events::LifeLost &event);
bool OnScoreEvent(const dd::Events::ScoreEvent &event);
bool OnMultiBall(const dd::Events::MultiBall &event);
bool OnCreatePowerUp(const dd::Events::CreatePowerUp &event);
};
}