Erwan
- Added new bonus system for victories. Unlock and bonuses need to be tested :/
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
#ifndef _CREDITS_H_
|
||||
#define _CREDITS_H_
|
||||
|
||||
|
||||
#include <vector>
|
||||
#include <string>
|
||||
#include <JGE.h>
|
||||
#include <JLBFont.h>
|
||||
#include "../include/Player.h"
|
||||
class GameApp;
|
||||
|
||||
using namespace std;
|
||||
|
||||
|
||||
class CreditBonus{
|
||||
public:
|
||||
int value;
|
||||
string text;
|
||||
CreditBonus(int _value, string _text);
|
||||
void Render(float x, float y, JLBFont * font);
|
||||
};
|
||||
|
||||
class Credits{
|
||||
private:
|
||||
int isDifficultyUnlocked();
|
||||
int isMomirUnlocked();
|
||||
public:
|
||||
int value;
|
||||
Player * p1, *p2;
|
||||
GameApp * app;
|
||||
int showMsg;
|
||||
int unlocked;
|
||||
JQuad * unlockedQuad;
|
||||
JTexture * unlockedTex;
|
||||
vector<CreditBonus *> bonus;
|
||||
Credits();
|
||||
~Credits();
|
||||
void compute(Player * _p1, Player * _p2, GameApp * _app);
|
||||
void Render();
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -34,6 +34,7 @@ class GameObserver{
|
||||
|
||||
|
||||
public:
|
||||
int turn;
|
||||
int targetListIsSet(MTGCardInstance * card);
|
||||
PhaseRing * phaseRing;
|
||||
int cancelCurrentAction();
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#ifdef TESTSUITE
|
||||
class TestSuite;
|
||||
#endif
|
||||
class Credits;
|
||||
|
||||
class GameStateDuel: public GameState, public JGuiListener
|
||||
{
|
||||
@@ -18,7 +19,7 @@ class GameStateDuel: public GameState, public JGuiListener
|
||||
#ifdef TESTSUITE
|
||||
TestSuite * testSuite;
|
||||
#endif
|
||||
int showMsg;
|
||||
Credits * credits;
|
||||
int mGamePhase;
|
||||
Player * mCurrentPlayer;
|
||||
Player * mPlayers[2];
|
||||
@@ -29,11 +30,8 @@ class GameStateDuel: public GameState, public JGuiListener
|
||||
SimpleMenu * menu;
|
||||
JLBFont* mFont, *opponentMenuFont;
|
||||
int nbAIDecks;
|
||||
int unlocked;
|
||||
JQuad * unlockedQuad;
|
||||
JTexture * unlockedTex;
|
||||
int isDifficultyUnlocked();
|
||||
int isMomirUnlocked();
|
||||
|
||||
|
||||
void loadPlayer(int playerId, int decknb = 0, int isAI = 0);
|
||||
void loadPlayerMomir(int playerId, int isAI);
|
||||
public:
|
||||
|
||||
Reference in New Issue
Block a user