{{sellerTotalView > 1 ? __("sellers", {number: sellerTotalView}) : __("seller", {number: sellerTotalView}) }}, {{numTotalView > 1 ? __("items", {number: numTotalView}) : __("item", {number: numTotalView}) }}
free FREE

Change Your Zip Code

Inventory information and delivery speeds may vary for different locations.

Location History

{{email ? __('Got it!') : __('Restock Alert')}}

We will notify you by email when the item back in stock.

Cancel
Yami

Jingdong book

Cocos2d-x学习笔记:完全掌握Lua API与游戏项目开发/未来书库

{{buttonTypePin == 3 ? __("Scan to view more PinGo") : __("Scan to start")}}

Cocos2d-x学习笔记:完全掌握Lua API与游戏项目开发/未来书库

{{__(":people-members", {'people': item.limit_people_count})}} {{ itemCurrency }}{{ item.valid_price }} {{ itemCurrency }}{{ item.invalid_price }} {{ itemDiscount }}
Ends in
{{ itemCurrency }}{{ item.valid_price }}
{{ itemCurrency }}{{ priceFormat(item.valid_price / item.bundle_specification) }}/{{ item.unit }}
{{ itemDiscount }}
{{ itemCurrency }}{{ item.valid_price }} {{ itemCurrency }}{{ priceFormat(item.valid_price / item.bundle_specification) }}/{{ item.unit }} {{ itemCurrency }}{{ item.invalid_price }} {{itemDiscount}}
{{ itemCurrency }}{{ item.valid_price }}
Sale ends in
Sale will starts after Sale ends in
{{ getSeckillDesc(item.seckill_data) }}
{{ __( "Pay with Gift Card to get sale price: :itemCurrency:price", { 'itemCurrency' : itemCurrency, 'price' : (item.giftcard_price ? priceFormat(item.giftcard_price) : '0.00') } ) }} ({{ itemCurrency }}{{ priceFormat(item.giftcard_price / item.bundle_specification) }}/{{ item.unit }}) Details
Best before

Currently unavailable.

We don't know when or if this item will be back in stock.

Unavailable in your area.
Sold Out

Details

Full product details
Editer Recommend

《Cocos2d-x学习笔记》由触控未来CEO李志远主编策划出版,该系列图书由赵志荣、关东升(Cocos CVP)等业内专家根据研发经验及读者学习规律,精心编撰。该系列图书得到了Cocos引擎创始人王哲的鼎力支持,并亲自作序。51CTO学院运营总监曹亚莉、触控爱普众创创始人肖涵泉、火云洞红孩儿卞安,LoopTek公司柯博文CTO通读全书,并写书评推荐。

Content Description

本书系统论述了Cocos2d x Lua API游戏编程和开发技术,内容涵盖Cocos2dx中的核心类、瓦片地图、物理引擎和AudioEngine音频引擎等知识。全书分为16章: 准备开始、Lua语言基础、Cocos2dx Lua API开发环境搭建、Cocos2dx引擎与Lua绑定、游戏中的文字、菜单、精灵、场景与层、动作和动画、用户事件、AudioEngine音频引擎、粒子系统、瓦片地图、物理引擎、Cocos2dx多分辨率屏幕适配,以及手机游戏项目实战。
本书适合作为普通高校计算机、动漫设计、数字媒体等相关专业的游戏开发课程的教材,也适合作为手机游戏开发培训机构的培训教材及广大手机游戏开发者的自学参考用书。

Catalogue

目录

丛书序Ⅲ


序Ⅴ

前言Ⅶ


第1章准备开始


1.1使用实例代码


1.2图示的约定


1.2.1图中的箭头


1.2.2图中的手势


1.2.3图中的圈框


1.2.4类图


第2章Lua语言基础


2.1Lua开发环境搭建


2.1.1安装LDT工具


2.1.2HelloLua实例测试


2.2标识符和保留字


2.2.1标识符


2.2.2保留字


2.3常量和变量


2.3.1常量


2.3.2变量


2.3.3命名规范


2.4注释


2.5Lua数据类型


2.5.1数据类型


2.5.2type函数


2.5.3数据类型转换


2.6运算符


2.6.1算术运算符


2.6.2关系运算符


2.6.3逻辑运算符


2.6.4运算优先级


2.7控制语句


2.7.1分支语句


2.7.2循环语句


2.7.3跳转语句


2.8table类型


2.8.1字典


2.8.2数组


2.9字符串类型


2.9.1字符串截取


2.9.2字符串转换


2.9.3字符串查询


2.9.4字符串格式化


2.10函数


2.10.1使用函数


2.10.2变量作用域


2.10.3多重返回值


2.11闭包函数


2.11.1嵌套函数


2.11.2返回函数


2.11.3使用闭包表达式


2.12Lua中的面向对象


2.12.1Lua中的对象


2.12.2类的实现


本章小结


第3章Cocos2dx Lua API开发环境搭建


3.1搭建环境


3.1.1Cocos引擎下载安装


3.1.2Cocos Framework下载和安装


3.2Cocos Code IDE开发工具


3.2.1安装Cocos Code IDE


3.2.2配置Cocos Code IDE


3.2.3使用Cocos Code IDE调试功能


本章小结


第4章Cocos2dx引擎与Lua绑定


4.1Cocos2d家谱


4.1.1Cocos2dx引擎


4.1.2Cocos2dx绑定Lua


4.2第一个Cocos2dx Lua绑定游戏


4.2.1创建工程


4.2.2Cocos Code IDE中运行


4.2.3工程文件结构


4.2.4重构HelloLua案例


4.3Cocos2dx核心概念


4.3.1导演


4.3.2场景


4.3.3层


4.4Node与Node层级架构


4.4.1Node中重要的操作


4.4.2Node中重要的属性


4.4.3游戏循环与调度


4.5Cocos2dx坐标系


4.5.1UI坐标


4.5.2OpenGL坐标


4.5.3世界坐标和模型坐标


本章小结


第5章游戏中的文字


5.1使用标签


5.1.1Label类


5.1.2Label类实例


5.2位图字体制作


5.2.1Glyph Designer工具


5.2.2使用Glyph Designer制作位图字体


本章小结


第6章菜单


6.1菜单相关类


6.2文本菜单


6.3精灵菜单和图片菜单


6.4开关菜单


本章小结


第7章精灵


7.1Sprite精灵类


7.1.1创建Sprite精灵对象


7.1.2实例: 使用纹理对象创建Sprite对象


7.2精灵的性能优化


7.2.1使用纹理图集


7.2.2使用精灵帧缓存


7.3纹理图集制作


7.3.1TexturePacker工具


7.3.2使用TexturePacker制作纹理图集


本章小结


第8章场景与层


8.1场景与层的关系


8.2场景切换


8.2.1场景切换相关函数


8.2.2场景过渡动画


8.3场景的生命周期


8.3.1生命周期函数


8.3.2多场景切换生命周期


本章小结


第9章动作和动画


9.1动作


9.1.1瞬时动作


9.1.2间隔动作


9.1.3组合动作


9.1.4动作速度控制


9.1.5函数调用


9.2特效


9.2.1网格动作


9.2.2实例: 特效演示


9.3动画


9.3.1帧动画


9.3.2实例: 帧动画使用


本章小结


第10章用户事件


10.1事件处理机制


10.1.1事件分发器


10.1.2触摸事件


10.1.3实例: 单点触摸事件


10.1.4实例: 多点触摸事件


10.1.5键盘事件


10.2加速度计与加速度计事件


10.2.1加速度计


10.2.2加速度计事件


10.2.3实例: 运动的小球


本章小结


第11章AudioEngine音频引擎


11.1Cocos2dx中音频文件


11.1.1音频文件介绍


11.1.2Cocos2dx跨平台音频支持


11.2使用AudioEngine引擎


11.2.1音频文件的预处理


11.2.2播放背景音乐


11.2.3停止播放背景音乐


11.3实例: 设置背景音乐与音效


11.3.1GameScene场景实现


11.3.2SettingScene场景实现


本章小结


第12章粒子系统


12.1问题的提出


12.2粒子系统基本概念


12.2.1实例: 打火机


12.2.2粒子发射模式


12.2.3粒子系统属性


12.3Cocos2dx内置粒子系统


12.3.1内置粒子系统


12.3.2实例: 内置粒子系统


12.4自定义粒子系统


12.4.1代码创建


12.4.2plist文件创建


本章小结


第13章瓦片地图


13.1地图性能问题


13.2Cocos2dx Lua中瓦片地图API


13.3使用Tiled地图编辑器


13.3.1新建地图


13.3.2导入瓦片集


13.3.3创建层


13.3.4在普通层上绘制地图


13.3.5在对象层上添加对象


13.4实例: 忍者无敌


13.4.1设计地图


13.4.2程序中加载地图


13.4.3移动精灵


13.4.4检测碰撞


13.4.5滚动地图


本章小结


第14章物理引擎


14.1使用物理引擎


14.1.1物理引擎核心概念


14.1.2物理引擎与精灵关系


14.2Cocos2dx中物理引擎


14.2.1Cocos2dx物理引擎Lua API


14.2.2实例: HelloPhysicsWorld


14.2.3实例: 接触与碰撞检测


14.2.4实例: 使用关节


本章小结


第15章多分辨率屏幕适配


15.1屏幕适配问题的提出


15.2Cocos2dx屏幕适配


15.2.1三种分辨率


15.2.2分辨率适配策略


15.2.3纹理图集资源适配


15.2.4瓦片地图资源适配


本章小结


第16章敏捷开发项目实战——迷失航线手机游戏


16.1迷失航线游戏分析与设计


16.1.1迷失航线故事背景


16.1.2需求分析


16.1.3原型设计


16.1.4游戏脚本


16.2任务1: 游戏工程的创建与初始化


16.2.1迭代1.1: 创建工程


16.2.2迭代1.2: 添加资源文件


16.2.3迭代1.3: 添加常量文件SystemConst.lua


16.2.4迭代1.4: 多分辨率支持


16.3任务2: 创建Loading场景


16.3.1迭代2.1: 添加场景和层


16.3.2迭代2.2: Loading动画


16.3.3迭代2.3: 异步加载纹理缓存


16.4任务3: 创建Home场景


16.4.1迭代3.1: 添加场景和层


16.4.2迭代3.2: 添加菜单


16.5任务4: 创建设置场景


16.6任务5: 创建帮助场景


16.7任务6: 游戏场景实现


16.7.1迭代6.1: 创建敌人精灵


16.7.2迭代6.2: 创建玩家飞机精灵


16.7.3迭代6.3: 创建炮弹精灵


16.7.4迭代6.4: 初始化游戏场景


16.7.5迭代6.5: 游戏场景菜单实现


16.7.6迭代6.6: 玩家飞机发射炮弹


16.7.7迭代6.7: 炮弹与敌人的接触检测


16.7.8迭代6.8: 玩家飞机与敌人的接触检测


16.7.9迭代6.9: 玩家飞机生命值显示


16.7.10迭代6.10: 显示玩家得分情况


16.8任务7: 游戏结束场景


本章小结


Introduction

前言

手机游戏产业的发展越来越火热,很多公司推出了自己的游戏引擎,北京触控科技有限公司的Cocos2dx游戏引擎就是其中的佼佼者,它的优势在于实现了“一个平台开发、多个平台发布”。截止到2016年初,Cocos2dx游戏引擎在全球199个国家和地区有超过40万开发者使用,已经成为全球使用率最高的手机游戏引擎之一。

为了推动Cocos2dx游戏引擎在我国高校与相关行业的应用与普及,提高相关专业人才培养及游戏产业发展的水平,进一步提高普通高校计算机、动漫设计、数字媒体等专业游戏类课程的教学质量,满足各大高校不断增长的人才培养需求、教学改革与课程改革要求,北京触控科技有限公司与清华大学出版社立项开展了《未来书库》的建设工作。我有幸受触控教育部门之邀,专门为广大高校师生、培训机构及有志于从事Cocos2dx游戏开发的读者撰写此书。

Cocos2dx游戏引擎提供了三种语言(C++/JavaScript/Lua)的API,开发者可以根据自己的技术背景选择不同语言。本书专门论述Lua语言API,并以游戏项目开发的实例,抛砖引玉,教会读者动手实践。

关于源代码

为了更好地为广大读者提供服务,我们专门为本书建立了一个网站https://www.51work6.com/book/cocos3.php,大家可以查看相关出版进度,并对书中内容发表评论,提出宝贵意见。

勘误与支持

我们在网站https://www.51work6.com/book/cocos3.php中建立了一个勘误专区,及时地把书中的问题、失误和纠正反馈给广大读者。如果您在阅读本书过程中,发现了任何问题,可以在网上留言,可以发送电子邮件到eorient@sina.com,也可以在新浪微博中与我们联系: @tony_关东升。我们会在第一时间回复您。

本书主要由赵志荣、关东升执笔撰写。此外,智捷课堂的赵浩丞、赵大羽、关锦华也参与了部分内容的编写工作。在此感谢触控教育部门的李志远和清华大学出版社的盛东亮给我们提供了宝贵的意见。感谢我的家人容忍我的忙碌,以及对我的关心和照顾,使我能抽出这么多时间,投入全部精力地专心编写此书。

由于时间仓促,书中难免存在不妥之处,请读者谅解,并提出宝贵意见。

赵志荣关东升

2016年1月于北京


Specifications

Brand Jingdong book
Brand Origin China

Disclaimer

Product packaging, specifications and price are subject to change without notice. All information about the products on our website is provided for information purposes only. Please always read labels, warnings and directions provided with the product before use.

View Full Terms of Use
Add to favorites
{{ $isZh ? coupon.coupon_name_sub : coupon.coupon_ename_sub | formatCurrency }}
{{__("Buy Directly")}} {{ itemCurrency }}{{ item.directly_price }}
Quantity
{{ quantity }}
{{ instockMsg }}
{{ limitText }}
{{buttonTypePin == 3 ? __("Scan to view more PinGo") : __("Scan to start")}}
Sold by JD@CHINA
Ship to
{{ __("Ship to United States only") }}
Free shipping over 69
Genuine guarantee

Added to Cart

Keep Shopping

More to Consider

{{ item.brand_name }}

{{ item.item_name }}

{{ item.currency }}{{ item.market_price }}

{{ item.currency }}{{ item.unit_price }}

{{ item.currency }}{{ item.unit_price }}

Coupons

{{ coupon.coupon_name_new | formatCurrency }}
Clip Clipped Over
{{ getCouponDescStr(coupon) }}
{{ coupon.use_time_desc }}
Expires soon {{ formatTime(coupon.use_end_time) }}

Share this item with friends

Cancel

Yami Gift Card

Get this exclusive deal when paying with gift card

Terms and Conditions

Gift card deals are special offers for selected products;

The gift card deals will automatically be activated if a customer uses gift card balance at check out and the balance is sufficient to pay for the total price of the shopping cart products with gift card deals;

You will not be able to activate the gift card deals if you choose other payment methods besides gift card. The products will be purchased at their normal prices;

If your account balance is not enough to pay for the products with gift card deals, you can choose to reload your gift card balance by clicking on the Reload button at either shopping cart page or check out page;

Products that have gift card deals can be recognized by a special symbol showing 'GC Deal';

For any additional questions or concerns, please contact our customer service;

Yamibuy reserves the right of final interpretation.

Sold by Yami

Service Guarantee

Yami Free Shipping over $49
Yami Easy Returns
Yami Ships from United States

Shipping

  • United States

    Standard Shipping is $5.99 (Excluding Alaska & Hawaii). Free on orders of $49 or more.

    Local Express is $5.99 (Available in Parts of CA, NJ, MA & PA). Free on orders of $49 or more.

    2-Day Express (Includes Alaska & Hawaii) starts at $19.99.

Return Policy

Yami is committed to provide our customers with a peace of mind when purchasing from us. Most items shipped from Yamibuy.com can be returned within 30 days of receipt of shipment (For Food, Beverages, Snacks, Dry Goods, Health supplements, Fresh Grocery and Perishables Goods, within 7 days of receipt of shipment due to damages or quality issues; To ensure that every customer receives safe and high-quality products, we do not provide refunds or returns for beauty products once they have been opened or used, except in the case of quality issues; Some products may have different policies or requirements associated with them, please see below for products under special categories, or contact Yami Customer Service for further assistance).
Thank you for your understanding and support.

Learn More

Sold by Yami

Terms and Conditions of Yami E-Gift Card

If you choose “Redeem automatically” as your delivery method, your gift card balance will be reload automatically after your order has been processed successfully;

If you choose “Send to Email”as your delivery method, the card number and CVV will be sent to the email address automatically;

Any user can use the card number and CVV to redeem the gift card, please keep your gift card information safely. If you have any trouble receiving email, please contact Yami customer service;

Yami gift card can be used to purchase both Yami owned or Marketplace products;

Yami gift card will never expire;

Yami gift card balance does not have to be used up at once;

All rights reserved by Yami.

Return Policy

Gift card that has already been consumed is non-refundable.

Sold by JD@CHINA

Service Guarantee

Yami Free Shipping over $49
Yami Easy Returns
Yami Ships from United States

Shipping

  • United States

    Standard Shipping is $5.99 (Excluding Alaska & Hawaii). Free on orders of $49 or more.

    Local Express is $5.99 (Available in Parts of CA, NJ, MA & PA). Free on orders of $49 or more.

    2-Day Express (Includes Alaska & Hawaii) starts at $19.99.

Return Policy

You may return product within 30 days upon receiving the product. Items returned must be new in it's original packing, including the original invoice for the purchase. Customer return product at their own expense.

Sold by JD@CHINA

Service Guarantee

Yami Cross-store Free Shipping over $69
Yami 30-days Return

Yami-China FC

Yami has a consolidation warehouse in China which collects multiple sellers’ packages and combines to one order. Our Yami consolidation warehouse will directly ship the packages to your door. Cross-store free shipping over $69.

Return Policy

You may return products within 30 days upon receiving the products. Sellers take responsibilities for any wrong shipment or missing items. Packing needs to be unopened for any other than quality issues return. We promise to pack carefully, but because goods are taking long journey to destinations, simple damages to packaging may occur. Any damages not causing internal goods quality problems are not allowed to return. If you open the package and any quality problem is found, please contact customer service within three days after receipt of goods.

Shipping Information

Yami Consolidation Service Shipping Fee $9.99(Free shipping over $69)

Sellers in China will ship their orders within 1-2 business days once the order is placed. Packages are sent to our consolidation warehouse in China and combined there. Our Yami consolidation warehouse will directly ship the packages to you via UPS. The average time for UPS to ship from China to the United States is about 10 working days and it can be traced using the tracking number. Due to the pandemic, the delivery time may be delayed by about 5 days. The package needs to be signed by the guest. If the receipt is not signed, the customer shall bear the risk of loss of the package.

Sold by JD@CHINA

Service Guarantee

Free shipping over 69
Genuine guarantee

Shipping

Yami Consolidated Shipping $9.99(Free shipping over $69)


Seller will ship the orders within 1-2 business days. The logistics time limit is expected to be 7-15 working days. In case of customs clearance, the delivery time will be extended by 3-7 days. The final receipt date is subject to the information of the postal company.

Yami Points information

All items are excluding from any promotion or points events on Yamibuy.com

Return Policy

You may return product within 30 days upon receiving the product. Items returned must be new in it's original packing, including the original invoice for the purchase. Customer return product at their own expense.

Yami

Download the Yami App

Back Top

Recommended for You

About the brand

Jingdong book

为您推荐

Yami
欣葉
2种选择
欣叶 御大福 芋头麻薯 180g

周销量 600+

$1.66 $1.99 83折
Yami
欣葉
2种选择
欣叶 御大福 芋头麻薯 180g

周销量 600+

$1.66 $1.99 83折
Yami
欣葉
2种选择
欣叶 御大福 芋头麻薯 180g

周销量 600+

$1.66 $1.99 83折
Yami
欣葉
2种选择
欣叶 御大福 芋头麻薯 180g

周销量 600+

$1.66 $1.99 83折
Yami
欣葉
2种选择
欣叶 御大福 芋头麻薯 180g

周销量 600+

$1.66 $1.99 83折
Yami
欣葉
2种选择
欣叶 御大福 芋头麻薯 180g

周销量 600+

$1.66 $1.99 83折

Reviews{{'('+ commentList.posts_count + ')'}}

Have your say. Be the first to help other guests.

Write a review
{{ totalRating }} Write a review
  • {{i}} star

    {{i}} stars

    {{ parseInt(commentRatingList[i]) }}%

Yami Yami
{{ comment.user_name }}

{{ showTranslate(comment) }}Show Less

{{ strLimit(comment,800) }}Show more

Show Original

{{ comment.content }}

Yami
Show All

{{ formatTime(comment.in_dtm) }} VERIFIED PURCHASE {{groupData}}

{{ comment.likes_count }} {{ comment.likes_count }} {{ comment.reply_count }} {{comment.in_user==uid ? __('Delete') : __('Report')}}
Yami Yami
{{ comment.user_name }}

{{ showTranslate(comment) }}Show Less

{{ strLimit(comment,800) }}Show more

Show Original

{{ comment.content }}

Yami
Show All

{{ formatTime(comment.in_dtm) }} VERIFIED PURCHASE {{groupData}}

{{ comment.likes_count }} {{ comment.likes_count }} {{ comment.reply_count }} {{comment.in_user==uid ? __('Delete') : __('Report')}}

No related comment~

Review

Yami Yami

{{ showTranslate(commentDetails) }}Show Less

{{ strLimit(commentDetails,800) }}Show more

Show Original

{{ commentDetails.content }}

Yami
Show All

{{ formatTime(commentDetails.in_dtm) }} VERIFIED PURCHASE {{groupData}}

{{ commentDetails.likes_count }} {{ commentDetails.likes_count }} {{ commentDetails.reply_count }} {{commentDetails.in_user==uid ? __('Delete') : __('Report')}}

Please write at least one word

Comments{{'(' + replyList.length + ')'}}

Yami Yami

{{ showTranslate(reply) }}Show Less

{{ strLimit(reply,800) }}Show more

Show Original

{{ reply.reply_content }}

{{ formatTime(reply.reply_in_dtm) }}

{{ reply.reply_likes_count }} {{ reply.reply_likes_count }} {{ reply.reply_reply_count }} {{reply.reply_in_user==uid ? __('Delete') : __('Report')}}

Please write at least one word

Cancel

That’s all the comments so far!

Write a review
How would you rate this item?

Please add your comment.

  • A nice nickname will make your comments more popular!
  • The nickname in your account will be changed to the same as here.
Thanks for your review
Our community rely on great reviews like yours to find the best of Asia.

Report

If you find this content inappropriate and think it should be removed from the Yami.com site, let us know please.

Cancel

Are you sure to delete your review?

Cancel

You’ve Recently Viewed

About the brand

Jingdong book