Creating iOS games for beginners

Marin Todorov teaches you how to create an iPhone game easily and simply using Cocos2d

Video Error

We tried several times to play your video but there was an unforeseen error. We have notified our engineers.

Visit to check that Flash is enabled on your browser.

With Flash enabled, please try again in a few minutes or contact support.

  • Lectures 18
  • Video 7 Hours
  • Skill Level All Levels
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion

How taking a course works


Find online courses made by experts from around the world.


Take your courses with you and learn anywhere, anytime.


Learn and practice real-world skills and achieve your goals.

Course Description

Where would we be without the games? Angry Birds, Cut The Rope, Peggle? Each one is as unique as they come, but they're tied together to one simple principle: Cocos2d can make them. Cocos2d is the leading, open-source, royalty-free smartphone game engine. It's easy to use, community-supported, reliable, mature, and over 1500 mobile iOS games have been published using it!

Why is Cocos2D so easy to use? Because you can play a sound effect, animate a flipping sprite, flash some rad custom font, all with just a couple lines of simple, pure Objective C code. No knowledge of OpenGL is required! Rotating, mirroring, parallaxing, scaling, tinting, sliding, jumping, and a Halloween-sackful of other effects are quickly at your fingertips.

In his course, Marin Todorov takes a hands-on approach and walks you step-by-step through the process of building a complete game! After building this game, you'll have all the coding knowledge you need to create the next gaming hit in the App Store!

What are the requirements?

  • You will be expected to have beginner/medium understanding of Objective-C
  • You will need to work on a Mac computer with installed XCode 4.x+
  • You will need to be connected to the Internet

What am I going to get from this course?

  • Over 18 lectures and 7 hours of content!
  • Install and include Cocos2d for iPhone in your projects
  • Understand scene workflow in Cocos2d
  • Work with scene transitions
  • Put image sprites on the screen and manipulate their properties
  • Run animations and actions on your sprites
  • Chain and run simultaneously different actions
  • Build menus in Cocos2d
  • Plan and design a simple game
  • Develop simple games
  • and much more..

What is the target audience?

  • Developers with beginner to medium or higher understanding of Xcode, Objective-C and iPhone programming, who would like to know more about the steps towards creating games with the Cocos2d framework.

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.


Section 1: Introduction to the course

In this short video you will learn about:

- Marin Todorov - the course author

- the material the course will cover

- the complete game project you will have developed by the end of the course

Have a look at the video for more information on the course and Cocos2d! Hope you will decide to take the course!

Section 2: Installing and understanding Cocos2d

Let's start!

I will talk about what Cocos2d is and will provide you a bit of background about it. We'll go trough the installation process and how Cocos2d integrates directly inside your Xcode installation.

To some the lesson might feel a bit too detailed, but for me is important everyone manages to finish the installation and understand well how to use the Cocos2d installation.


In this lesson:

- downloading and installing Cocos2d framework

- creating Cocos2d powered projects in XCode

- what comes in the different Cocos2d project templates


Let's talk about scenes workflow - how the different screens in a game relate, how to navigate between screens. How to create new screens inside your game and how to use fancy transitions to interchange them. 

You're going to learn about the Cocos2d hierarchy and who stays on the top


In this lesson:

- understanding cocos2d hierarchy

- learning about scenes and layers

- using transitions to switch between scenes


I'll talk about some oddities about Cocos2d, namely the coordinate system and the ability to set the sprites' anchor point.

We're going to start loading images from the game project and showing them on the screen and change their appearance. We're take a step further and build menus, so we can have the game reacting to the user tapping the screen of the device:


In this lesson:

- Cocos2d coordinate system and positioning objects on the screen

- loading images and showing sprites on the screen

- creating a menu with different buttons reacting to user taps


We're going to make our sprites move around the screen, rotate and blink! This will already feel much more like game development. We're going to move from simple actions like rotation and movement towards complicated chain actions and running simultaneous actions.

In the end we're going to load frame animation and run it on a sprite of the screen. 


In this lesson:

- make your sprites move, rotate & blink with actions

- run several simultaneous or chained actions 

- run animations on your sprites and combine them with other actions

947.7 kB

This is an XCode project you can download - it contains the source code from the previous lesson - but instead of chickens you have monkeys :)

Download it and unarchive it as we're going to use it as a starting point for the next lesson.

You are encouraged to play with the code and experiment yourself, you already know what is what and who is who, so start playing! 

Here's some ideas: 

1) Have you already tried all the CCSprite's properties for yourself, have you seen the effect of changing them? There's plenty to start with:

- position
- zOrder - you can order your sprites on the Z axis
- skewX, skewY - skew your images
- rotation - rotation of your image in degrees
- scale - scale of the image
- scaleX, scaleY - stretch your image on the x and y axis
- visible - yes or no
- anchorPoint - CGPoint with coords from 0 to 1 (check the lesson again about it)
- flipX, flipY - flips the image
- opacity - from 0 to 255, 0 means invisible

2) give all CCAction classes a try! make this monkey go wild :) Btw - here's a task for you - make the monkey do the moon walk.

And here's a list of the actions you can give a try to:

- CCMoveBy, CCMoveTo - move your images around
- CCJumpBy, CCJumpTo - make your sprites jump
- CCBezierBy, CCBezierTo - make sprites move on bezier paths
- CCScaleBy, CCScaleTo - scale actions
- CCRotateBy, CCRotateTo - rotate sprites
- CCBlink - blink blink
- CCFadeIn, CCFadeOut, CCFadeTo - different fade actions
- CCTintBy, CCTintTo - you can change the tint of your sprites
- CCSpawn - run simultaneous actions
- CCSequence - run a chain of actions one after each other
- CCDelayTime - wait a given amount of seconds
- CCRepeat, CCRepeatForever - repeat the given action
- CCCallFunc - execute given method (obsolete now, just so you know)
- CCCallBlock -  execute the code in the provided code block
- CCAnimate - gets a frame animation and runs it on the given sprite

For more information on actions and example you can head to :

Section 3: Your first game - "Monkey Trampoline"

Building on the chicken example from Lesson 5 we're going to replace the chicken with a sweet monkey. We're going to talk about planning a game, defining the game goals and how to approach coding the game logic.

By the end of this lesson you will have developed your first game!


In this lesson:

- planning a simple game

- bringing it all together - buttons, animations and logic

- running a simple game

934.3 kB

Here you can download the source code of the game Monkey Trampoline.

Exercise to try:

- add a "You loose" screen and make it appear when the player reaches -3 points (negative 3 points)

- add buttons to re-start the game from the win and loose screens

- make the new monkeys fall from the sky into their starting position

Section 4: Deeper into Cocos2d with the "Numbers Match" game
3.7 MB

This is an archive containing all the images and sounds we are going to use to build our big project - Numbers Match. Do download this file on your computer before heading to Lesson 10 where we'll start designing and coding the game


We're going to go over the Numbers match game project - the scenes flow and the basic layout of the gameplay screen. I'm going to showcase the assets prepared for the project and after some house-cleaning inside the default Cocos2d template we're going to start coding.

Generally throughout the Numbers match project I'm going to go a bit faster trough the code - usually pasting in methods and then explaining what's going on inside the code. This will allow me to keep the length of the tutorial to a sane length - once you finish the course you are welcome to re-watch these videos while you tingle with the code of the complete project. 


In this lesson:

- planning the Numbers Match game

- setting up the project and importing assets

- beginning the TileSprite class which will take care of a single tile in the game


We're going to implement the game controller - the MatchManager class, which by using the nearly ready TileSprite class will by the end of the lesson be able to show the tile set on the screen.

To keep momentum we're going to alternate the workflow with adding the about screen.


In this lesson:

- creating a super-flexible game controller which can be used in many different tile matching games

- showing the tile set on the screen

- adding a second scene to the game, which is pushed over the gameplay scene instead of replacing it


We're going to create our custom action to flip around the tiles and touch shortly on the CCAction mechanics; we're going to accept touches from from the player and via the match manager pass them to the tapped tiles. We're going to implement the logic behind marking the matching tiles and finally show the winning sequence - animation, sound + the option to restart the game.


In this lesson:

- using the orbit camera action for 3d flip effect and writing a custom Cocos2d action

- implementing the logic dispatching touches to tiles and the complete game 

- coding the animation and effects to reward the player when he/she opens all matching tiles


In this lesson you'll go trough the last remaining tasks to really polish the game. The game will be complete and running by the half of the lesson. 

In the second half I'll take you trough some tricks I'm using when developing games, namely: producing hi-res and low-res graphics for your game in half the time, preparing your audio for use on the iPhone and cocos2d, showcase a couple of web sites where you can find free art and free music to use in your games.

Thanks a lot for taking the course! Leave comments and feedback, so I can take them in account when producing my next course.

To get in touch with me visit my blog:

Best wishes, Marin Todorov


In this lesson:

- implementing the hints logic and finish the Numbers Match game

- going over how to import audio in your game and how to bulk produce retina and non-retina graphics

- showcasing few web resources you might find useful when you create your own games

4.3 MB

Here you can download the complete source code and the project assets of the Numbers Match project.

I wish you lots of fun time with the game and lots of luck and success on the App Store.

Section 5: Bonus game - "Bubble Pop"
1.9 MB

In this chapter we're going to create a new fun game called "Bubble Pop".

Please before proceeding to the video lesson - download and unarchive the "" file and have it at hand for the next lesson.


I tell you about the game we're about to create, we import the game assets (download the zip from Lesson 15, do that before starting with this video) and dive into coding the game layout and implementing a game timer.


In this lesson:

  1. plan the game and import the game assets
  2. implement the game timer
  3. create a cusom CCMenuItemImage class for our bubbles

I continue on the Bubble Pop project by implenting the bubbles logic, finishing the complete game with loose and win scenarious, and in the end add audio effects and in-game music.


In this lesson:

  1. dynamically add menu items - our custom baloon buttons
  2. manage cocos2d node's children
  3. add in-game music
2.7 MB

And here is the complete Bubble Pop game XCode project, which you can download and play around with.

Thanks for attending Cocos2d101 and let me know if you would like to see anything in particular added to the course, I might be adding some new stuff in the future again.

Instructor Biography

Marin Todorov, Independent iOS dev and publisher

Marin Todorov is an independent iOS developer and publisher with 10 fun and innovative titles released on the App Store. He's got experience in developing software on many different platforms- on the desktop, in the cloud and at present the iPhone. Marin was a university teacher for several years and also wrote a textbook on programming related to his course. He has published numerous technical articles in print and online media; his last larger contribution were a couple of articles on security and bundled databases to a book from Adobe and O'Reilly.

Marin is also very active in the iOS developer community - he's regularly writing in his blog about iPhone development and the App Store in general: ; he also sometimes writes guest posts and tutorials on other popular websites.

Join the biggest student community


Hours of video content


Course Enrollments




Average Rating
  1. 5 Stars
  2. 4 Stars
  3. 3 Stars
  4. 2 Stars
  5. 1 Star
Ready to start learning?
Preview This Course