resonance 1.0.1
Loading...
Searching...
No Matches
soloscreenanim.h
Go to the documentation of this file.
1#pragma once
2
3#include <vector>
4
5#include "game/screenanim.h"
6#include "game/tnlarena.h"
7
8namespace Rnd {
9class Mat;
10} // namespace Rnd
11
22class SoloScreenAnim : public ScreenAnim {
23public:
34 SoloScreenAnim(const std::vector<TnlArena::ScreenMesh> *pScreens, Rnd::Mat *pPlayerMat);
35
40 virtual ~SoloScreenAnim();
41
52 virtual void SetFrame(float flFrame);
53
64 virtual void SetLevel(int nLevel);
65
66private:
67 // Ticks each material of level 2 stays on the screens.
68 float mPeriod;
69 // The period SetFrame() last applied. Starts at -10000.
70 int mPhase;
71 int mLevel;
72 Rnd::Mat *mPlayerMat;
73 // `noise.mat`, or null.
74 Rnd::Mat *mNoiseMat;
75 const std::vector<TnlArena::ScreenMesh> *mScreens;
76};
Surface description a Rnd::Mesh draws with.
Definition mat.h:36
Animation of the arena screens that TnlArena drives.
Definition screenanim.h:14
virtual void SetLevel(int nLevel)
Clamp the level to 0 through 2 and apply a changed one.
virtual void SetFrame(float flFrame)
Alternate the materials at level 2.
SoloScreenAnim(const std::vector< TnlArena::ScreenMesh > *pScreens, Rnd::Mat *pPlayerMat)
Record the screens and the player's material, and resolve noise.mat.
virtual ~SoloScreenAnim()
The rendering engine.
Definition animhelper.h:3