资源简介
此代码为别踩白块儿源码,采用cocos2d-x-3.0制作。详细文章,可以参考:http://blog.csdn.net/column/details/notouchwhiteblock.html 多谢支持

代码片段和文件信息
#include “AppDelegate.h“
#include “HelloWorldScene.h“
USING_NS_CC;
AppDelegate::AppDelegate() {
}
AppDelegate::~AppDelegate()
{
}
bool AppDelegate::applicationDidFinishLaunching() {
// initialize director
auto director = Director::getInstance();
auto glview = director->getOpenGLView();
if(!glview) {
glview = GLView::create(“My Game“);
director->setOpenGLView(glview);
}
glview->setframeSize(320480);
glview->setDesignResolutionSize(320480ResolutionPolicy::SHOW_ALL);
// turn on display FPS
director->setDisplayStats(false);
// set FPS. the default value is 1.0/60 if you don‘t call this
director->setAnimationInterval(1.0 / 60);
// create a scene. it‘s an autorelease object
auto scene = HelloWorld::createScene();
// run
director->runWithScene(scene);
return true;
}
// This function will be called when the app is inactive. When comes a phone callit‘s be invoked too
void AppDelegate::applicationDidEnterBackground() {
Director::getInstance()->stopAnimation();
// if you use SimpleAudioEngine it must be pause
// SimpleAudioEngine::getInstance()->pauseBackgroundMusic();
}
// this function will be called when the app is active again
void AppDelegate::applicationWillEnterForeground() {
Director::getInstance()->startAnimation();
// if you use SimpleAudioEngine it must resume here
// SimpleAudioEngine::getInstance()->resumeBackgroundMusic();
}
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 1476 2014-05-12 15:35 Classes\AppDelegate.cpp
文件 947 2014-04-01 18:48 Classes\AppDelegate.h
文件 1740 2014-05-09 16:13 Classes\Block.cpp
文件 714 2014-05-09 16:13 Classes\Block.h
文件 3960 2014-05-12 15:40 Classes\HelloWorldScene.cpp
文件 1095 2014-05-12 11:00 Classes\HelloWorldScene.h
目录 0 2014-05-08 18:52 Classes
----------- --------- ---------- ----- ----
9932 7
相关资源
- 智慧工地可视化展板(数据大屏源码
- uni-app电商模板源码
- 有问必答项目 html源码
- 生日祝福html网页源码(特效很多)
- 仿网易音乐源码
- 炫酷科技web大数据可视化投屏源码
- 印象烘培 首页html源码
- 新浪手机新闻网站模板首页html源码
- 表白源码
- 好用的前端+php转盘抽奖源码
- 买菜宝 微信小程序源码(不附服务端
- 表格生成器(html源码)
- 基于vue的商城项目(源码+数据库+文档
- 基于vue的轻社区项目(源码+文档)
- 表白网页款式二源码
- 表白html源码(款式四)
- 简单购物车源码
- 非常漂亮的业务导航源码
- 橙色的综合商城手机版模板html源码
- 家具田园html模板源码
- jQuery蜘蛛纸牌电脑版游戏源码
- NeverGiveUp永不放弃网页小游戏实源码
- vue手机商城前端源码
- 抖音很火的动态表白源码
- 美食网html模板源码
- 网上书店网站系统源码
- 40个H5小游戏完整源码挺好玩的
- HTML5+CSS3实现的图片过滤归类应用特效
- 易语言源码-OFFICE文档转换成HTML
- HTML5游戏平台完整源码
评论
共有 条评论