myobject.h

来自「很好的一个游戏源代码」· C头文件 代码 · 共 29 行

H
29
字号
// MyObject.h: interface for the CMyObject class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_MYOBJECT_H__9939D471_C570_11D4_A7CC_EA7F379C1C5F__INCLUDED_)
#define AFX_MYOBJECT_H__9939D471_C570_11D4_A7CC_EA7F379C1C5F__INCLUDED_

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

class CMyObject : public CObject  
{
public:
	CPoint GetPos()		{ return m_ptPos;	}
	virtual CRect GetRect()=0;
	virtual bool Draw(CDC* pDC, bool bPause)=0;
	bool IsSubmarine()	{ return m_bSubmarine; }
	CMyObject();
	virtual ~CMyObject();

protected:
	CPoint m_ptPos;
	bool m_bSubmarine;

};

#endif // !defined(AFX_MYOBJECT_H__9939D471_C570_11D4_A7CC_EA7F379C1C5F__INCLUDED_)

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?