- It is now possible to have avatars associated to each Deck
- Added SFX
- Added Music files
- Possibility to choose your opponent
- Opponents' difficulty is measured according to their number of victories against a given deck
This commit is contained in:
wagic.the.homebrew
2008-11-24 09:24:47 +00:00
parent a9e70c0bdc
commit 3721247bee
69 changed files with 734 additions and 259 deletions

View File

@@ -2,10 +2,10 @@
#include "../include/SimpleMenuItem.h"
SimpleMenuItem::SimpleMenuItem(int id, JLBFont *font, const char* text, int x, int y, bool hasFocus): JGuiObject(id), mFont(font), mText(text), mX(x), mY(y)
SimpleMenuItem::SimpleMenuItem(int id, JLBFont *font, const char* text, int x, int y, bool hasFocus): JGuiObject(id), mFont(font), mX(x), mY(y)
{
mText = text;
mHasFocus = hasFocus;
mScale = 1.0f;
@@ -20,7 +20,7 @@ SimpleMenuItem::SimpleMenuItem(int id, JLBFont *font, const char* text, int x, i
}
void SimpleMenuItem::Render()
void SimpleMenuItem::RenderWithOffset(float yOffset)
{
mFont->SetScale(mScale);
@@ -29,10 +29,16 @@ void SimpleMenuItem::Render()
{
mFont->SetColor(ARGB(255,255,255,0));
}
mFont->DrawString(mText, mX, mY, JGETEXT_CENTER);
mFont->DrawString(mText.c_str(), mX, mY + yOffset, JGETEXT_CENTER);
mFont->SetScale(1.0f);
}
void SimpleMenuItem::Render()
{
RenderWithOffset(0);
}
void SimpleMenuItem::Update(float dt)
{
if (mScale < mTargetScale)