资源简介
cocos2d-x的塔防实现,只实现了基本的建造,出怪,打怪,其他需要的自己完善,图片不是很好看。

代码片段和文件信息
#include “AppDelegate.h“
#include “cocos2d.h“
#include “SimpleAudioEngine.h“
using namespace CocosDenshion;
#include “HelloWorldScene.h“
#include “CCEGLView.h“
USING_NS_CC;
AppDelegate::AppDelegate()
{
}
AppDelegate::~AppDelegate()
{
SimpleAudioEngine::end();
}
bool AppDelegate::initInstance()
{
bool bRet = false;
do
{
#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32)
// Initialize OpenGLView instance that release by CCDirector when application terminate.
// The HelloWorld is designed as HVGA.
CCEGLView * pMainWnd = new CCEGLView();
CC_BREAK_IF(! pMainWnd
|| ! pMainWnd->Create(TEXT(“cocos2d: Hello World“) 800 480));
#endif // CC_PLATFORM_WIN32
#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS)
// OpenGLView initialized in testsAppDelegate.mm on ios platform nothing need to do here.
#endif // CC_PLATFORM_IOS
#if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID)
// OpenGLView initialized in HelloWorld/android/jni/helloworld/main.cpp
// the default setting is to create a fullscreen view
// if you want to use auto-scale please enable view->create(320480) in main.cpp
// if the resources under ‘/sdcard“ or other writeable path set it.
// warning: the audio source should in assets/
// cocos2d::CCFileUtils::setResourcePath(“/sdcard“);
#endif // CC_PLATFORM_ANDROID
#if (CC_TARGET_PLATFORM == CC_PLATFORM_WOPHONE)
// Initialize OpenGLView instance that release by CCDirector when application terminate.
// The HelloWorld is designed as HVGA.
CCEGLView* pMainWnd = new CCEGLView(this);
CC_BREAK_IF(! pMainWnd || ! pMainWnd->Create(320480 WM_WINDOW_ROTATE_MODE_CW));
#ifndef _TRANZDA_VM_
// on wophone emulator we copy resources files to Work7/NEWPLUS/TDA_DATA/Data/ folder instead of zip file
cocos2d::CCFileUtils::setResource(“HelloWorld.zip“);
#endif
#endif // CC_PLATFORM_WOPHONE
#if (CC_TARGET_PLATFORM == CC_PLATFORM_MARMALADE)
// MaxAksenov said it‘s NOT a very elegant solution. I agree haha
CCDirector::sharedDirector()->setDeviceOrientation(kCCDeviceOrientationLandscapeLeft);
#endif
#if (CC_TARGET_PLATFORM == CC_PLATFORM_LINUX)
// Initialize OpenGLView instance that release by CCDirector when application terminate.
// The HelloWorld is designed as HVGA.
CCEGLView * pMainWnd = new CCEGLView();
CC_BREAK_IF(! pMainWnd
|| ! pMainWnd->Create(“cocos2d: Hello World“ 800 480480 320));
CCFileUtils::setResourcePath(“../Resource/“);
#endif // CC_PLATFORM_LINUX
#if (CC_TARGET_PLATFORM == CC_PLATFORM_BADA)
CCEGLView * pMainWnd = new CCEGLView();
CC_BREAK_IF(! pMainWnd|| ! pMainWnd->Create(this 480 320));
pMainWnd->setDeviceOrientation(Osp::Ui::ORIENTATION_LANDSCAPE);
CCFileUtils::setResourcePath(“/Res/“);
#endif // CC_PLATFORM_BADA
#if (CC_TARGET_PLATFORM == CC_PLATFORM_QNX)
CCEGLView * pMainWnd = new CCEGLView();
CC_BREAK_IF(! pMainWnd|| ! pMainWnd->Create(4
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 4360 2013-03-21 17:18 WIN_TD\Classes\AppDelegate.cpp
文件 1129 2013-01-05 10:29 WIN_TD\Classes\AppDelegate.h
文件 2019 2013-01-06 09:21 WIN_TD\Classes\BeginScene.cpp
文件 391 2013-01-05 14:40 WIN_TD\Classes\BeginScene.h
文件 1341 2013-01-06 13:34 WIN_TD\Classes\CanBuildTurretMenu.cpp
文件 528 2013-01-05 17:25 WIN_TD\Classes\CanBuildTurretMenu.h
....... 0 2009-08-31 02:32 WIN_TD\Classes\CheckpointScene.cpp
....... 0 2009-08-31 02:32 WIN_TD\Classes\CheckpointScene.h
文件 2117 2013-01-09 15:54 WIN_TD\Classes\Common.cpp
文件 787 2013-01-09 15:54 WIN_TD\Classes\Common.h
文件 3374 2013-01-05 13:54 WIN_TD\Classes\HelloWorldScene.cpp
文件 664 2013-01-05 13:50 WIN_TD\Classes\HelloWorldScene.h
文件 1635 2013-01-07 15:08 WIN_TD\Classes\MonsterSprite.cpp
文件 841 2013-01-07 11:44 WIN_TD\Classes\MonsterSprite.h
文件 1394 2013-01-09 16:06 WIN_TD\Classes\RunGameScene.cpp
文件 337 2013-01-09 15:57 WIN_TD\Classes\RunGameScene.h
文件 9950 2013-01-09 17:25 WIN_TD\Classes\TiledMap.cpp
文件 1604 2013-01-09 16:15 WIN_TD\Classes\TiledMap.h
文件 3041 2013-01-09 17:21 WIN_TD\Classes\TurretSprite.cpp
文件 955 2013-01-07 15:06 WIN_TD\Classes\TurretSprite.h
文件 94417 2013-03-21 17:18 WIN_TD\Debug.win32\AppDelegate.obj
文件 103119 2013-01-09 17:23 WIN_TD\Debug.win32\ba
文件 110259 2013-01-09 15:57 WIN_TD\Debug.win32\BeginScene.obj
文件 88865 2013-01-09 16:17 WIN_TD\Debug.win32\CanBuildTurretMenu.obj
文件 1827 2013-01-05 15:14 WIN_TD\Debug.win32\CheckpointScene.obj
文件 13994 2013-03-21 17:18 WIN_TD\Debug.win32\cl.command.1.tlog
文件 387346 2013-03-21 17:18 WIN_TD\Debug.win32\CL.read.1.tlog
文件 15272 2013-03-21 17:18 WIN_TD\Debug.win32\CL.write.1.tlog
文件 86073 2013-01-09 15:57 WIN_TD\Debug.win32\Common.obj
文件 107004 2013-01-05 14:41 WIN_TD\Debug.win32\HelloWorldScene.obj
............此处省略182个文件信息
- 上一篇:微信拼图小游戏
- 下一篇:灰色建模系统免费软件
相关资源
- flash3.0小游戏
- Scrach 欢乐狙击手.sb2
- linux应用层的华容道游戏源代码
- 小鸡快跑游戏.
- [易语言]游戏多开例程
- 贪吃蛇游戏设计(汇编语言)
- VC 游戏编程—附源代码
- C 纸牌游戏——21点
- 分享 mud 文字游戏 源码
- c 制作的RPG小游戏
- 五子棋游戏实现悔棋功能
- 找不同FLASH游戏源码
- planeGame飞机游戏
- 拼图游戏源代码 powerbuilder 9.0实例
- 解决WPE进不了游戏的最佳方法(闭屏
- linux扫雷游戏代码
- 多线程实例:桌面智能弹球小游戏
- “猜数字”游戏 算法破解
- OpenGL-3D坦克模拟
- 联机版井字棋源码
- 拼图游戏(可自由选择难度)
- 扫雷(MVC架构)
- 解封SHOW 51VV 9158 封机器码类游戏机
- scratch穿越迷宫.sb2
- 小鱼捉迷藏Scratch小游戏
- GlowtoolsA-wdf网易游戏wdf查看及解包
- 游戏音频图像提取工具GARbro
- OPENGL实现世界上最小的3D游戏
- Scrach3.0 跳一跳小游戏
- js 迷宫小游戏源码
评论
共有 条评论