⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄

📁 这是一个俄罗斯方块的源代码
💻
字号:
// 俄罗斯方块View.h : interface of the CMyView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_VIEW_H__E43A4958_B3ED_4E87_8608_C5E691D1FFD1__INCLUDED_)
#define AFX_VIEW_H__E43A4958_B3ED_4E87_8608_C5E691D1FFD1__INCLUDED_

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

#include "game.h"

class CMyView : public CView
{
protected: // create from serialization only
	CMyView();
	DECLARE_DYNCREATE(CMyView)

// Attributes
public:
	CMyDoc* GetDocument();
    int CodeFromColor(COLORREF color);
	COLORREF ColorFromCode(int code);
    BOOL TwoWindow;
	BOOL QuickDrop;

	UINT CON_DOWN,CON_LEFT,CON_RIGHT,CON_TURN,CON_PAUSE;
	BOOL SafeFlags;
// Operations
public:
    GAME game;
// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CMyView)
	public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
	//}}AFX_VIRTUAL

// Implementation
public:
	int TempFloor;
	int TempLevel;
	virtual ~CMyView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:

// Generated message map functions
protected:
	//{{AFX_MSG(CMyView)
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg void OnStart();
	afx_msg void OnKeyUp(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnEnd();
	afx_msg void OnInitset();
	afx_msg void OnNomid();
	afx_msg void OnMid1();
	afx_msg void OnMid2();
	afx_msg void OnMid3();
	afx_msg void OnWord();
	afx_msg void OnStandard();
	afx_msg void OnChange();
	afx_msg void OnLoad();
	afx_msg void OnSave();
	afx_msg void OnAppHelp();
	afx_msg void OnDestroy();
	afx_msg void OnSetjoy();
	afx_msg void OnConset();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in 俄罗斯方块View.cpp
inline CMyDoc* CMyView::GetDocument()
   { return (CMyDoc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_VIEW_H__E43A4958_B3ED_4E87_8608_C5E691D1FFD1__INCLUDED_)

⌨️ 快捷键说明

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