2010-11-20 10:37:14 +00:00
|
|
|
/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
|
|
|
|
/* If you are missing that file, acquire a complete release at teeworlds.com. */
|
2010-05-29 07:25:38 +00:00
|
|
|
#ifndef GAME_CLIENT_COMPONENTS_FLOW_H
|
|
|
|
#define GAME_CLIENT_COMPONENTS_FLOW_H
|
|
|
|
#include <base/vmath.h>
|
|
|
|
#include <game/client/component.h>
|
|
|
|
|
|
|
|
class CFlow : public CComponent
|
|
|
|
{
|
|
|
|
struct CCell
|
|
|
|
{
|
|
|
|
vec2 m_Vel;
|
|
|
|
};
|
|
|
|
|
|
|
|
CCell *m_pCells;
|
|
|
|
int m_Height;
|
|
|
|
int m_Width;
|
|
|
|
int m_Spacing;
|
2011-04-13 18:37:12 +00:00
|
|
|
|
2010-05-29 07:25:38 +00:00
|
|
|
void DbgRender();
|
|
|
|
void Init();
|
|
|
|
public:
|
|
|
|
CFlow();
|
2011-04-13 18:37:12 +00:00
|
|
|
|
2010-05-29 07:25:38 +00:00
|
|
|
vec2 Get(vec2 Pos);
|
|
|
|
void Add(vec2 Pos, vec2 Vel, float Size);
|
|
|
|
void Update();
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|