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

📄 ast.cpp

📁 基于引擎基础上开发的三维游戏实例“恐怖之战”游戏者可以自爱三维地形上漫游
💻 CPP
字号:
// Ast.cpp: implementation of the CAst class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "MyGame.h"
#include "Ast.h"


#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

CAst::CAst()
{
	size=1;
}

CAst::~CAst()
{

}


int CAst::Draw()
{
	glPushMatrix();
	glDisable(GL_LIGHTING);
	glTranslate(p);
	glRotatef(angle,0,0,1);
	glScalef(size,size,size);
	glBegin(GL_LINE_LOOP);
	glColor3f((GLfloat).7,(GLfloat).6,(GLfloat).6);
	glVertex3f( 1.0, 1.0,0);
	glVertex3f(-1.0, 1.0,0);
	glVertex3f(-1.0,-1.0,0);
	glVertex3f( 1.0,-1.0,0);
	glEnd();
	glEnable(GL_LIGHTING);
	glPopMatrix();
	return 4;
}

void CAst::Hit(CBullet *b, list<CAst *> &AL, list<CGameObj *> &OL)
{

}

⌨️ 快捷键说明

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