cocos2d-js | 项目发布到微信小程序和横竖屏设置

栏目: IOS · 发布时间: 7年前

这是官方的教程

Cocos2d-JS 适配、打包微信小游戏教程

——————————————————————————————————————————

进去需要下载两个东西

cocos2d-js | 项目发布到微信小程序和横竖屏设置

解压好微信适配文件,安装好开发者 工具 之后(

注意!:在替换掉framework/html5后需要先发布一下web版本,再导入WeChatGame)

cocos2d-js | 项目发布到微信小程序和横竖屏设置

然后打开微信开发者工具,选择小程序项目

cocos2d-js | 项目发布到微信小程序和横竖屏设置

然后,选择小程序、选择项目目录为你的.../publish/html文件夹

cocos2d-js | 项目发布到微信小程序和横竖屏设置

最后确定,就可以进行模拟微信端调试了

——————————————————————————————————————————

微信发布版默认横屏,要切换横屏需要修改game.json文件,portrait为竖屏

cocos2d-js | 项目发布到微信小程序和横竖屏设置

微信小程序和小游戏都需要已备案的合法域名才可以上传代码。

具体配置在微信开放平台上。

# 微信中的js规范和cocos不同,使用chipmunk需要再导出一下

cocos2d-js | 解决在微信小程序中使用chipmunk报错gameThirdScriptError cp is not defined ReferenceError: cp is not d

--------------------- 

作者:Prpr_Saber 

原文:https://blog.csdn.net/u011607490/article/details/81459928 


以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Introduction to the Design and Analysis of Algorithms

Introduction to the Design and Analysis of Algorithms

Anany Levitin / Addison Wesley / 2006-2-24 / USD 122.00

Based on a Based on a new classification of algorithm design techniques and a clear delineation of analysis methods, "Introduction to the Design and Analysis of Algorithms" presents the subject in a c......一起来看看 《Introduction to the Design and Analysis of Algorithms》 这本书的介绍吧!

RGB转16进制工具
RGB转16进制工具

RGB HEX 互转工具

UNIX 时间戳转换
UNIX 时间戳转换

UNIX 时间戳转换

HSV CMYK 转换工具
HSV CMYK 转换工具

HSV CMYK互换工具