Category Archives: cocos2d

cocos2d – HelloWorld in Cocos2d…

After the installation, now we gonna have a look at  HelloWorld program.We are not going to implement any code here.When we create a new project in cocos2d, it automatically builds some code in it.

1.Select File–>New–>Project.

2.A window appears as shown below.

select

3.Select ‘Cocos2d’ and click next.

4.Just run the project.

Output:

iOS Simulator Screen shot 18-May-2013 2.06.30 PM

  • Here a Label with text ‘Hello World’ is displayed.
  • The Numbers displayed below are called as ‘FPS'(Frames Per Second).Number of frames displaying per second.

cocos2d – Installing Cocos2d in Xcode…

Yippee:) So Gaming is always a pleasurable thing.Cocos2d has 2 game engines namely,

  1. Box2d
  2. Chipmunk

While comparing to chipmunk,Bx2d is something added with flavour.OK…

Installing Cocos2d:

1. You can Download COCOS2D latest version from
http://www.cocos2d-iphone.org/download” this link

2. open the terminal and type “cd”

3.Drag your latest version of -> COCOS2D package folder in to your terminal window.

4. Type sudo and open the COCOS2D package folder and drag the “install-templates.sh” file into your terminal     windows and press enter.

6. put your system password to install templates.

Enjoy gaming!!!

cocos2d – Introduction cocos2d…

cocos2d

Cocos2d

It is a framework for building 2D games, demos, and other graphical/interactive applications. It is based on the cocos2d design: it uses the same concepts, but instead of using python it uses objective-c. cocos2d for iPhone is:

  • Easy to use: it uses a familiar API, and comes with lots of examples
  • Fast: it uses the OpenGL ES best practices and optimized data structures
  • Flexible: it is easy to extend, easy to integrate with 3rd party libraries
  • Free: is open source, compatible both with closed and open source games
  • Community supported: cocos2d has an active, big and friendly community (forum, IRC)
  • AppStore approved: More than 2500 AppStore games already use it, including many best seller games.

cocos2d for iPhone supports: iPod TouchiPhoneiPad and OS X

Features:

  • Scene management (workflow)
  • Transitions between scenes
  • Sprites and Sprite Sheets
  • Effects: Lens, Ripple, Waves, Liquid, Twirl, etc.
  • Actions (behaviors):
    • Trasformation Actions: Move, Rotate, Scale, Jump, etc.
    • Composable actions: Sequence, Spawn, Repeat, Reverse
    • Ease Actions: Exp, Sin, Cubic, etc.
    • Misc actions: CallFunc, OrbitCamera
  • Basic menus and buttons
  • Integrated physics engine (both Box2d and Chipmunk)
  • Particle system
  • Text rendering support (variable and fixed width fonts)
  • Texture Atlas support
  • Tile Map support (TMXmaps):
    • Orthogonal maps
    • Isometric maps
    • Hexagonal maps
  • Parallax scrolling support
  • Sound support
  • Streak Motion support
  • Render Texture support
  • High Score server (Cocos Live)
  • Point based API: Supports Retina Display
  • Touch/Accelerometer support (iOS).  Keyboard / Mouse support (Mac)
  • Portrait and Landscape mode (iOS) / Automatic Fullscreen support (Mac)
  • Integrated Pause/Resume
  • Fast Textures:Supports PVRTC textures, 8-bit textures, 16-bit textures and 32-bit textures
  • Language: objective-c
  • OpenGL ES 1.1 based (iOS) / OpenGL 1.5 based (Mac)

courtesy:http://www.cocos2d-iphone.org