LEVEL3.CPP
资源名称:tc3d.zip [点击查看]
上传用户:abcdshs
上传日期:2007-01-07
资源大小:1858k
文件大小:3k
源码类别:
游戏
开发平台:
Visual C++
- // (C) Copyright 1994-1996 by Anthony J. Carin. All Rights Reserved.
- #include <stdafx.h>
- #include "levels.h"
- #include "antagon.h"
- #include "weapon.h"
- #include "bmpsurf.h"
- level3::level3() : levels()
- {
- Game->SetLevelNum(3);
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.0f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- }
- void level3::draw()
- {
- levels::draw();
- }
- level4::level4() : level3()
- {
- Game->SetLevelNum(4);
- delete numobj;
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.0f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- }
- level5::level5() : level4()
- {
- Game->SetLevelNum(5);
- delete numobj;
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.0f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- }
- level10::level10() : level9()
- {
- Game->SetLevelNum(10);
- delete numobj;
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.4f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- numobj2 = new baseobject(getpath((CString)"levelnm1.img"));
- numobj2->setto(coordinate(-0.4f, 3.0f, 0.0f));
- numobj2->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj2);
- }
- level11::level11() : level10()
- {
- Game->SetLevelNum(11);
- delete numobj;
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.4f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- }
- level12::level12() : level10()
- {
- Game->SetLevelNum(12);
- delete numobj;
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.4f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- }
- lastlevel::lastlevel(short levelnum) : level12()
- {
- Game->SetLevelNum(levelnum);
- delete numobj;
- delete numobj2;
- numobj = new baseobject(getpath((CString)"levelnum.img"));
- numobj->setto(coordinate(0.4f, 3.0f, 0.0f));
- numobj->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj);
- numobj2 = new baseobject(getpath((CString)"levelnm1.img"));
- numobj2->setto(coordinate(-0.4f, 3.0f, 0.0f));
- numobj2->setcolor(RGB(random(256), random(256), random(256)));
- Game->DrawQueue()->add(numobj2);
- }