TrailFrag.h
上传用户:henghua
上传日期:2007-11-14
资源大小:7655k
文件大小:1k
- #ifndef _TRAILFRAG_
- #define _TRAILFRAG_
- #include "comman.h"
- struct Particle
- {
- D3DXVECTOR3 pos;
- D3DXVECTOR3 vel;
- int frames;
- D3DXCOLOR clrDiffuse;
- float roty;
- float rotz;
- Particle *next;
- };
- class TrailFrag
- {
- public:
- TrailFrag(LPDIRECT3DDEVICE9 device, int life, int texnum);
- ~TrailFrag();
- bool Init();
- void Update();
- void Render();
- inline void renderFrag();
- inline void newFrag(D3DXVECTOR3 pos, D3DXVECTOR3 vel, float , float);
- void newFrag(float , float , float , float , float , float, float, float );
- bool AddTexture(char *, int t);
- Particle *head;
- Particle *trail;
- private:
- LPDIRECT3DTEXTURE9 *textures;
- int texnum;
- int life;
- LPDIRECT3DVERTEXBUFFER9 v_frag;
- LPDIRECT3DINDEXBUFFER9 i_frag;
- LPDIRECT3DDEVICE9 device;
- };
- #endif