Game: Map Design Considerations 游戏地图设计指南
依据前文伏击战场景手稿, 用Tile Studio "草草"制作出该场景的地图:
生成的C源码:
#ifndef _open_war_1Gfx_c
#define _open_war_1Gfx_c #ifndef _GFX_BITMAP_DATA
#define _GFX_BITMAP_DATA
/* structure with bitmap data */
typedef struct GFX_BITMAP_DATA
{
char * BitmapIdentifier;
int BitmapWidth;
int BitmapHeight;
int TileWidth;
int TileHeight;
int TileCountX;
int TileCountY;
int TransparentX;
int TransparentY;
int Sequences;
int ** SequenceData;
int * SequenceLength;
int * SequencePosition;
int * SequenceCounter; } GFX_BITMAP_DATA;
#endif #ifndef _GFX_EMPTY
#define _GFX_EMPTY
static int Empty[] = {0};
#endif /* tile sequences */ int Tiles1SeqLength[] =
{
-1
}; int Tiles1SeqPosition[0 + 1];
int Tiles1SeqCounter[0 + 1]; int * Tiles1Sequences[] =
{
Empty
}; #define Gfxtile_set_2Map1MapWidth (25)
#define Gfxtile_set_2Map1MapHeight (18) signed short tile_set_2Map1MapData[18][25] =
{{ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 4, 1,
1},
{ 1, 1, 1, 1, 1, 5, 6, 1, 1, 1, 1, 1, 1, 1, 5, 5, 6, 1, 1, 1, 2, 3, 4, 1, 1},
{ 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 5, 6, 1, 7, 7, 1, 2, 2, 2, 2, 3, 4, 1, 1},
{ 1, 1, 5, 6, 1, 1, 1, 1, 5, 6, 1, 7, 1, 5, 6, 1, 1, 2, 8, 8, 8, 8, 4, 1, 1},
{ 1, 1, 7, 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 7, 1, 1, 1, 2, 8, 4, 4, 4, 4, 1, 1},
{ 1, 1, 1, 1, 5, 6, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 8, 4, 1, 1, 1, 1, 1},
{ 1, 1, 1, 1, 7, 1, 1, 1, 1, 1,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,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}}; /* tile sequences */ int tile_set_2SeqLength[] =
{
-1
}; int tile_set_2SeqPosition[0 + 1];
int tile_set_2SeqCounter[0 + 1]; int * tile_set_2Sequences[] =
{
Empty
}; /* tile sequences */ int objsSeqLength[] =
{
-1
}; int objsSeqPosition[0 + 1];
int objsSeqCounter[0 + 1]; int * objsSequences[] =
{
Empty
}; /* bitmap data */
const struct GFX_BITMAP_DATA GfxTiles1Bitmap =
{ "Tiles1", 320, 32, 32, 32,
10, 1, 81, 1, 0,
&Tiles1Sequences[0], &Tiles1SeqLength[0],
&Tiles1SeqPosition[0], &Tiles1SeqCounter[0]
}; const struct GFX_BITMAP_DATA Gfxtile_set_2Bitmap =
{ "tile_set_2", 320, 32, 32, 32,
10, 1, 81, 1, 0,
&tile_set_2Sequences[0], &tile_set_2SeqLength[0],
&tile_set_2SeqPosition[0], &tile_set_2SeqCounter[0]
}; const struct GFX_BITMAP_DATA GfxobjsBitmap =
{ "objs", 320, 32, 32, 32,
10, 1, 81, 1, 0,
&objsSequences[0], &objsSeqLength[0],
&objsSeqPosition[0], &objsSeqCounter[0]
}; #endif
如你也是地图制作初学者,可以看看:Game: Map Design Considerations 游戏地图设计指南,希望对你有帮助。
Enjoy~
Mars
August 4,2013
Any to share, e-me: mars.fu@foxmail.com
Game: Map Design Considerations 游戏地图设计指南的更多相关文章
- 新版MATERIAL DESIGN 官方动效指南(一)
Google 刚发布了新版Material Design 官方动效指南,全文包括三个部分:为什么说动效很重要?如何制作优秀的Material Design动效及转场动画,动效的意义.新鲜热辣收好不谢! ...
- ogre 3d游戏开发框架指南
ogre 3d游戏开发框架指南pdf 附光盘代码 http://www.ddooo.com/softdown/74228.htm OGRE3D游戏开发框架指南.pdf http://vdisk.wei ...
- Egret HTML5游戏开发指南
Egret HTML5游戏开发指南 下载地址:https://pan.baidu.com/s/1fuxllvmRhWXoWDwH4gxN9g 关注微信公众号获取提取码: 输入:egrt 获取提取码
- 《Amazon Aurora: Design Considerations for High Throughput Cloud-Native Relational Databases》论文总结
Aurora总结 说明:本文为论文 <Amazon Aurora: Design Considerations for High Throughput Cloud-Native Relation ...
- 新版MATERIAL DESIGN 官方动效指南(二)
继上一篇,本文继续第二部分,从动效的速度.动态持续时间.通用持续时间和缓动曲线4个部分,教你创建平滑一致的Material Design 动效.再系统的干货都比不上官方的动效指南,西瓜就在这,赶紧来捡 ...
- Multiprocessor Operating System Design Considerations SYMMETRIC MULTIPROCESSORS
COMPUTER ORGANIZATION AND ARCHITECTURE DESIGNING FOR PERFORMANCE NINTH EDITION An SMP operating syst ...
- 新版MATERIAL DESIGN 官方动效指南(三)
运动 Material design 的动效会被类似真实世界中的力的影响,类似重力. 物体在屏幕内的运动 屏幕内物体在两点之间的运动,是沿着一条自然.凹陷的弧线.屏幕上所有的运动都可以使用标准曲线. ...
- Amazon Aurora: Design Considerations for High Throughput Cloud-Native Relational Databases
INTRODUCTION In modern distributed cloud services, resilience and scalability are increasingly ach ...
- ARM Cortex Design Considerations for Debug
JTAG was the traditional mechanism for debug connections for ARM7/9 parts, but with the Cortex-M fam ...
随机推荐
- PHP正则表达式匹配中文字符
网上有很多类似的文章,但往往都不能用 所以记录一下 preg_match_all("/([\x{4e00}-\x{9fa5}])/u", $input, $match); 注意:限 ...
- erlang 常用函数
os:getpid() 获得erl.exe的进程表示符 application:start(appname, Type), Type == permanent 表示一个应用死了,其它应用全部死掉 ...
- 服务器之间建立oracle之间的关联语句
create public database link DBLINK_WZGTAMS CONNECT TO WZGTAMS identified by WZGTAMS using ' (DESCRIP ...
- 创建类模式(四):原型(Prototype)
定义 用原型实例指定创建对象的种类,并且通过拷贝这些原型创建新的对象. 原型模式允许一个对象再创建另外一个可定制的对象,根本无需知道任何如何创建的细节,工作原理是:通过将一个原型对象传给那个要发动创建 ...
- 通过SimpleAction显示一个listview
private void simpleAction1_Execute(object sender, SimpleActionExecuteEventArgs e) { IObjectSpace os ...
- DISCUZ X2更换域名注意事项
国内私募机构九鼎控股打造APP,来就送 20元现金领取地址:http://jdb.jiudingcapital.com/phone.html内部邀请码:C8E245J (不写邀请码,没有现金送)国内私 ...
- MyEclipse 8.5 开发环境配置,汉化,Aptana2.0插件,SVN 插件,Flex Builder 3/4 插件安装(转载)
转载地址http://elf8848.iteye.com/blog/630864 下载MyEclipse 8.5 可以通过代理http://www.proxyie.cn/访问MyEclipse的官方网 ...
- PL/pgSQL多输出参数例子
例子一,不带returns: postgres=# CREATE FUNCTION sum_n_product(x int, y int, OUT sum int, OUT prod int) AS ...
- 关闭IE窗口
$a=(New-Object -comObject Shell.Application).Windows() ($a|?{$_.locationname -eq "人力与人才信息管理系统&q ...
- 使用visual studio 2013 快速搭建phonegap开发环境
前一段时间开发了一款简单的Phonegap应用,遇到了很多坑,其中有一个坑就是在搭建开发环境上.由于Phonegap 2.x 与3.x 区别比较大,导致了开发环境也有所不同.2.x 是这样的http: ...