GithubHelp home page GithubHelp logo

rh101 / programmers-guide-samples Goto Github PK

View Code? Open in Web Editor NEW

This project forked from chukong/programmers-guide-samples

0.0 2.0 0.0 9.55 MB

Programmers Guide Samples

License: Apache License 2.0

Python 0.26% Makefile 0.50% C++ 54.61% Java 42.38% Objective-C 0.36% Objective-C++ 1.83% C 0.07%

programmers-guide-samples's Introduction

programmers-guide-samples

Conventions used in this book

  • auto is used for creating local variables.
  • using namespace cocos2d; is used to shorten types.
  • each chapter has a compilable source code sample to demonstrate concepts.
  • each chapter should subclass Ref
  • each chapter should do as much work in the constructor. no need for ::init()
  • model the code design after chapter 2's example code. Follow these same conventions.

Prerequisites

  • make sure to drop in the pre-built libraries into libs/. For iOS you should have:
libs/libcocos2d iOS.a

For Android you should have everything if you have the Cocos app installed. If you do not, you can drop the pre-built libraries into libs/ and edit your projects config to reflect this.

For Windows 10 UWP and Windows 8.1 Universal App projects (WinRT Platforms) it is easier to work with the cocos2d-x source. Do the following:

$ cd programmers-guide-samples/cpp
$ git clone https://github.com/cocos2d/cocos2d-x.git cocos2d
$ cd cocos2d
$ git checkout v3.10
$ git submodule update --init
$ download-deps.py

This will setup the cocos2d-x code needed by the Windows 10 and 8.1 projects.

How to compile the samples

iOS:

$ git clone https://github.com/chukong/programmers-guide-samples.git
$ cd programmers-guide-samples/cpp
$ open proj.ios_mac/Programmers\ Guide.xcodeproj/

Android:

$ git clone https://github.com/chukong/programmers-guide-samples.git
$ cd programmers-guide-samples/cpp
$ cd proj.android
$ cocos run -p android

Windows 10 UWP (WinRT Platform):

$ git clone https://github.com/chukong/programmers-guide-samples.git
$ cd programmers-guide-samples/cpp
$ cd proj.win10

1. Open test.sln with VS2015 update 1
2. Select the Debug/x86 configuration
3. Right click on the test project and select Set as StartUp Project from the menu
4. Select Start Debugging from the Debug menu

Windows 8.1 Universal App (WinRT Platform):

$ git clone https://github.com/chukong/programmers-guide-samples.git
$ cd programmers-guide-samples/cpp
$ cd proj.win8.1-universal

1. Open test.sln with VS2015 Update 1 or Visual Studio 2013 Update 4 or 5
2. Select the Debug/x86 configuration
3. Right click on the test project and select Set as StartUp Project from the menu
4. Select Start Debugging from the Debug menu

programmers-guide-samples's People

Contributors

slackmoehrle avatar zilongshanren avatar stammen avatar ricardoquesada avatar wenhailin avatar darkdukey avatar super626 avatar

Watchers

James Cloos avatar RH avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.