资源简介
这是我2013年暑期工程实践写的,一个人完成,所以有很多瑕疵.代码给大家参考参考,所有的代码都在里面,这是visual studio 2012编写的,语言是C++

代码片段和文件信息
/*
# Copyright © 2013 Shaw 499012219@qq.com
# This file is part of Tank.
# Tank is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation either version 3 of the License or
# (at your option) any later version.
# Tank is distributed in the hope that it will be useful
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Foobar. If not see .
*/
#include “stdafx.h“
#include “Block.h“
Block::Block(short _x short _y short _type bool _throughable):x(_x) y(_y) type(_type) throughable(_throughable)
{
real_x = BLOCK_WIDTH * x;
real_y = BLOCK_WIDTH * y;
}
Block::~Block(void)
{
}
void Block::Draw(HDC &hdc)
{
}
void Block::TransparentPNG(CImage *png)
{
for(int i = 0; i GetWidth(); i++)
{
for(int j = 0; j GetHeight(); j++)
{
unsigned char* pucColor = reinterpret_cast(png->GetPixelAddress(i j));
pucColor[0] = pucColor[0] * pucColor[3] / 255;
pucColor[1] = pucColor[1] * pucColor[3] / 255;
pucColor[2] = pucColor[2] * pucColor[3] / 255;
}
}
}
void Block::Explode()
{}
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2013-08-31 10:34 MyTank-master\
文件 483 2013-08-31 10:34 MyTank-master\.gitattributes
文件 2643 2013-08-31 10:34 MyTank-master\.gitignore
目录 0 2013-08-31 10:34 MyTank-master\Tank\
文件 859 2013-08-31 10:34 MyTank-master\Tank\Tank.sln
目录 0 2013-08-31 10:34 MyTank-master\Tank\Tank\
文件 1411 2013-08-31 10:34 MyTank-master\Tank\Tank\Block.cpp
文件 399 2013-08-31 10:34 MyTank-master\Tank\Tank\Block.h
文件 3389 2013-08-31 10:34 MyTank-master\Tank\Tank\Bullet.cpp
文件 344 2013-08-31 10:34 MyTank-master\Tank\Tank\Bullet.h
文件 7062 2013-08-31 10:34 MyTank-master\Tank\Tank\GTank.cpp
文件 610 2013-08-31 10:34 MyTank-master\Tank\Tank\GTank.h
文件 1481 2013-08-31 10:34 MyTank-master\Tank\Tank\MapBlock.cpp
文件 204 2013-08-31 10:34 MyTank-master\Tank\Tank\MapBlock.h
文件 1288 2013-08-31 10:34 MyTank-master\Tank\Tank\MoveableBlock.cpp
文件 384 2013-08-31 10:34 MyTank-master\Tank\Tank\MoveableBlock.h
文件 2222 2013-08-31 10:34 MyTank-master\Tank\Tank\ReadMe.txt
文件 677 2013-08-31 10:34 MyTank-master\Tank\Tank\Resource.h
文件 16298 2013-08-31 10:34 MyTank-master\Tank\Tank\Tank.cpp
文件 2072 2013-08-31 10:34 MyTank-master\Tank\Tank\Tank.h
文件 2998 2013-08-31 10:34 MyTank-master\Tank\Tank\Tank.ico
文件 6472 2013-08-31 10:34 MyTank-master\Tank\Tank\Tank.rc
文件 5279 2013-08-31 10:34 MyTank-master\Tank\Tank\Tank.vcxproj
文件 2719 2013-08-31 10:34 MyTank-master\Tank\Tank\Tank.vcxproj.filters
目录 0 2013-08-31 10:34 MyTank-master\Tank\Tank\res\
目录 0 2013-08-31 10:34 MyTank-master\Tank\Tank\res\image\
文件 9227 2013-08-31 10:34 MyTank-master\Tank\Tank\res\image\M1.png
文件 9227 2013-08-31 10:34 MyTank-master\Tank\Tank\res\image\M2.png
文件 38578 2013-08-31 10:34 MyTank-master\Tank\Tank\res\image\M3.png
文件 4861 2013-08-31 10:34 MyTank-master\Tank\Tank\res\image\M4.png
文件 182959 2013-08-31 10:34 MyTank-master\Tank\Tank\res\image\M5.png
............此处省略32个文件信息
相关资源
- 猜数字游戏 c语言代码
- 移木块游戏,可以自编自玩,vc6.0编写
- C++纯文字DOS超小RPG游戏
- LINUX下命令行界面的C语言细胞游戏
- VC++MFC小游戏实例教程(实例)+MFC类库
- 用C语言实现的一个打字游戏
- C语言版3D魔方游戏源代码
- 打飞机小游戏57466
- 俄罗斯方块游戏源码(Tetris)
- c++ 猜拳小游戏
- 扫雷游戏.cpp
- 杨中科游戏开发引擎
- 智商超高的中国象棋游戏源码(C++版
- c++ 扫雷游戏源码(控制台)
- C++跑跑卡丁车
- C++“倒忌时”小游戏
- XX游戏客户端源码
- c++小游戏源码.doc
- 基于ege图形的推箱子游戏
- C语言ege贪吃蛇游戏
- C++小游戏4款(源码)
- 推箱子小游戏源码
- 五子棋游戏源码(控制台)
- 猜数字游戏.sb3
- C++贪吃蛇控制台小游戏代码
- 扫雷游戏.cpp(较简单)
- MFC五子棋游戏
- VC++ 大富翁4_大富翁游戏源码
- c++常用游戏算法及数据结构设计
- c++的飞行鸟游戏
评论
共有 条评论