Click here to Skip to main content
15,881,559 members
Articles / Multimedia / DirectX

Adventures In Abattoirville

Rate me:
Please Sign up or sign in to vote.
5.00/5 (5 votes)
31 Jul 2001MIT5 min read 109K   3.3K   32  
A Maze based game.
// SpriteManager.h: interface for the CSpriteManager class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_SPRITEMANAGER_H__48D20543_2F83_4732_93E8_378A19DC42A0__INCLUDED_)
#define AFX_SPRITEMANAGER_H__48D20543_2F83_4732_93E8_378A19DC42A0__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

class CSpriteManager  
{
public:
	void Destroy();
	int KillSpritesColliWith(CSprite* pSprite);
	bool IsHit(RECT& rc);
	void SetCollAndPathFn(bool (*pfnCollision)(RECT&) ,  void (*pfnFindPath)(CSprite*));
	void RemoveSprite(CSprite *pSprite);
	void Draw(LPDIRECTDRAWSURFACE7 pdds);
	void AddSprite(CSprite* pSprite);
	void Update();
	CSpriteManager();
	virtual ~CSpriteManager();
protected:
	std::list<CSprite*> m_pSpriteList;
	bool (*m_pfnCollision)(RECT& rcRect);
	void (*m_pfnFindPath)(CSprite* pSprite);
};

#endif // !defined(AFX_SPRITEMANAGER_H__48D20543_2F83_4732_93E8_378A19DC42A0__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The MIT License


Written By
Software Developer
United States United States
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions