• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            牽著老婆滿街逛

            嚴以律己,寬以待人. 三思而后行.
            GMail/GTalk: yanglinbo#google.com;
            MSN/Email: tx7do#yahoo.com.cn;
            QQ: 3 0 3 3 9 6 9 2 0 .

            Cocos2d-x Visual Studio Android Project

            轉載自:https://blogs.msdn.microsoft.com/vcblog/2016/07/12/cocos2d-x-visual-studio-android-project/

            In the world of game development , Cocos2d is one of the biggest names out there. The open source Cocos2d framework has been the backbone of a vast number of top selling apps and games, provides support for a number of programming languages, and targets a massive variety of devices. Currently, Cocos2d-x (the C++ version of Cocos2d) provides starter projects for Android targets for Eclipse and Android Studio and starter projects for Win32, Windows 8.1,  and Windows 10 targets for Visual Studio. Starting with Visual Studio 2015,  Visual Studio has added in a wealth of support for C++ projects that target not only Windows platforms but Android and iOS platforms as well. With some new Android support added in Visual Studio Update 2, this seemed like the perfect opportunity to allow Cocos2d-x users a chance to utilize Visual Studio’s  incredible editing, debugging, and deployment support for their Android development work. To this end, we’ve provided a starter project that can be dropped in with the Cocos2d basic template projects to allow for a quick start with Android Cocos2d-x development using Visual Studio. This starter project is intended to work with Cocos2d-x version 3.13.1 and will need manual adjustments to work with other versions of Cocos2s-x (there is an older version that works with 3.12 provided at the bottom of this post).

            The first step in this process is to set up a new Cocos2d-x project following the standard pattern.

            First off, download the newest version of Cocos2d-x and unzip the file to your convenient location of choice.

            A1-Download

            Next, take a command prompt and navigate to the Cocos2d-x directory that you unzipped into. From that directory, run setup.py to set up the development environment for Cocos2d-x, making sure that you have python installed on your system first. When the environment is set, the cocos command line tool can be used to create a new empty Cocos2d-x project.

            C:>cocos new MyNewGame –l cpp –d projects

            This command will create a new game directory called MyNewGame in the projects directory. The –l variable indicates that this is a C++ project that we want created. In this new directory, you will see the see the following directory structure.

            B1-CocosDirectories

            This structure breaks down in the following way. The cocos2d directory contains the Cocos2d-x framework code. The engine code, platform- specific code, third party libraries, and things of that nature all go in here. Must of the time you’d hope to not have to change this framework code during development, but the great thing about Cocos2d-x being open source is that all the framework code is right there to debug into and edit if needed. The Classes folder contains the actual user C++ code that contains the code for the game. For the Cocos2d-x example, this is just a super basic scene which puts Hello World text and a static sprite image on a splash screen along with an FPS ticker and a close button. This is the directory where the user is expected to add and work with their game code. The Resources directory contains the various resources that will be a part of the game. Images, resources, music files, models, and all the like go here. And finally we have all the proj.* directories. These directories contain project files for targeting the various platforms that Cocos2d-x supports. These project have only a small amount of platform or  build specific files in them. Most of what these project files do is to reference the platform code in the cocos2d directory, the shared game code in the Classes directory, and the shared game assets in the Resources directory. The nice thing about this layout is that you can switch between various build tools and targets while maintaining the same game code and assets.

            At this point we want to add in our Android targeting Visual Studio project to this layout. This file can be downloaded below:

            proj.visualstudio (Cocos2d-x 3.13.1)

            Move the proj.visualstudio.zip file from where it was downloaded into the main project directory and unzip it side by side with the other project types. Make sure that the solution is located in a proj.visualstudio directory directly under your main game directory. You don’t want the duplicate of the project folder name as this will mess up relative paths for the project so make sure that the Cocos2d.sln file is located under project\MyNewGame\proj.visualstudio.

            Unzipped

            Since we are just unzipping this side by side, we don’t participate in the template project renaming that the cocos command line does for the other project types. As a result, the solution and project files have more general names (Cocos2d.sln instead of MyNewGame.sln), and you’ll have to rename them manually to have them match up. Opening Cocos2d.sln will open up the project in Visual Studio 2015 Update 2. If Update 2 is not installed, then one of the projects will not load, so just right click the project and follow the prompts to update Visual Studio with the needed project types.

            D1-AndroidSolution

            In this solution (I’ve expanded out a few folders for illustration) we have a Visual Studio Android ANT project called Cocos2d. This project contains links to the java platform code in the cocos2d directory as well as to the assets in the Resources directory that need to be included in the apk. The only non-shared code under the src directory is the org.cocos2dx.cpp\AppActivity.java class which extends Cocos2dxActivity and gets the engine up and running on the device. The Cocos2d java project references a Cocos2dcpp shared object project also included in this solution. In the jni directory of this project resides the project- specific main.cpp/h as well as linked files to the AppDelegate and HelloWorldScene files in the project  shared Classes directory. In the cocos directory are links to all the cocos2d C++ framework code from the shared cocos2d directory. At this point you can build your project and deploy it to the device of your choice with Visual Studio debugging support.

            Screenshot_20160120-033612

            cpp-test project screenshots:

            Screenshot_20160120-054802Screenshot_20160120-054838Screenshot_20160120-054952

            This version of proj.visualstudio works with Cocos version 3.12.

            proj.visualstudio (Cocos2d-x 3.12)

            posted on 2016-12-27 16:05 楊粼波 閱讀(380) 評論(0)  編輯 收藏 引用

            久久精品国产精品亜洲毛片| 午夜天堂av天堂久久久| 久久精品国产精品亜洲毛片| 亚洲欧洲精品成人久久曰影片| 东方aⅴ免费观看久久av| 99久久综合狠狠综合久久止| 久久青青草原精品国产不卡| 99精品国产99久久久久久97| 91久久精品国产成人久久| 久久丫忘忧草产品| 久久996热精品xxxx| 久久久久高潮毛片免费全部播放| 久久久久亚洲?V成人无码| 久久精品国产亚洲AV高清热| 久久精品女人天堂AV麻| MM131亚洲国产美女久久| 久久久久亚洲国产| 久久精品成人免费国产片小草| 久久精品国产亚洲精品2020 | 国产综合久久久久久鬼色| 久久综合五月丁香久久激情| 免费观看成人久久网免费观看| 亚洲人成网亚洲欧洲无码久久| 久久久久99精品成人片牛牛影视| 狠狠色丁香久久综合婷婷| 久久久无码精品亚洲日韩按摩| 思思久久99热只有频精品66| 性高朝久久久久久久久久| 久久99精品国产麻豆婷婷| 99久久99久久精品国产| 国产一区二区三区久久精品| 久久久久久亚洲AV无码专区| 无码久久精品国产亚洲Av影片| 久久精品国产2020| 亚洲国产精品无码久久久秋霞2| 久久天天躁狠狠躁夜夜躁2014| 国产精品久久久久久久app| 思思久久99热只有频精品66| 亚洲中文字幕无码久久2020| 亚洲国产另类久久久精品| 精品少妇人妻av无码久久|