- updated intro with better timing and multiple models. Updated menu background model as well and about screen to show megapack units.

This commit is contained in:
Mark Vejvoda
2011-10-12 05:24:30 +00:00
parent f8da775fe0
commit 50ce6eb1ea
5 changed files with 295 additions and 23 deletions

View File

@@ -18,6 +18,10 @@
#include "font.h"
#include "vec.h"
#include "texture.h"
#include "camera.h"
#include "model.h"
#include "randomgen.h"
#include "leak_dumper.h"
using std::vector;
@@ -29,6 +33,10 @@ using Shared::Graphics::Font2D;
using Shared::Graphics::Font3D;
using Shared::Graphics::Texture2D;
using Shared::Graphics::Camera;
using Shared::Graphics::Model;
using Shared::Util::RandomGen;
namespace Glest{ namespace Game{
// =====================================================
@@ -64,7 +72,7 @@ public:
/// ProgramState representing the intro
// =====================================================
class Intro: public ProgramState{
class Intro: public ProgramState {
private:
static int introTime;
static int appearTime;
@@ -78,6 +86,23 @@ private:
int mouseY;
int mouse2d;
//Model *mainModel;
int modelIndex;
vector<Model *> models;
Camera nextCamera;
Camera camera;
Camera lastCamera;
const Camera *targetCamera;
float t;
RandomGen random;
float anim;
float fade;
Vec3f startPosition;
int modelShowTime;
void cleanup();
void renderModelBackground();
public:
Intro(Program *program);
virtual ~Intro();