* Change inplay balance.
- Spells now stack three by three.
- Spells try to space a little more.
- Creatures and land stack to the left until they hit the big card,
  at which point they start displaying more compactly. At some point,
  they start using all the screen even if it's under the hand.
This commit is contained in:
jean.chalard
2009-10-11 05:47:31 +00:00
parent 9688d923a7
commit 38d7a96095
4 changed files with 73 additions and 42 deletions

View File

@@ -14,30 +14,29 @@ class GuiPlay : public GuiLayer
protected:
class CardStack {
protected:
unsigned total;
float baseX, baseY;
float x, y;
public:
void reset(float x, float y);
void reset(unsigned total, float x, float y);
void Enstack(CardView*);
void RenderSpell(MTGCardInstance*, iterator begin, iterator end, float x, float y);
};
class HorzStack : public CardStack {
protected:
const float maxWidth;
float maxHeight;
public:
HorzStack(float width = HORZWIDTH);
void reset(float x, float y);
HorzStack();
void reset(unsigned total, float x, float y);
void Render(CardView*, iterator begin, iterator end);
void Enstack(CardView*);
};
class VertStack : public CardStack {
protected:
float maxHeight;
unsigned count;
public:
VertStack(float height = VERTHEIGHT);
VertStack();
void reset(unsigned total, float x, float y);
void Render(CardView*, iterator begin, iterator end);
void Enstack(CardView*);
inline float nextX();
@@ -56,7 +55,7 @@ class GuiPlay : public GuiLayer
void addAttacker(MTGCardInstance*);
void removeAttacker(MTGCardInstance*);
void reset(float x, float y);
BattleField(float width = HORZWIDTH);
BattleField();
void EnstackAttacker(CardView*);
void EnstackBlocker(CardView*);
void Update(float dt);