Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

Let's imagine I have a breakout game. I make a level like this:

For columns < max columns
    For rows < max rows
        Create sprite from file, put it on some position based on 
        current column and row, put it into array of objects.

Now, imagine I have 100 levels and I want them to be different. What tools should I use to ease my life? How do I load a level from file? Maybe a plist?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

You can use any format that's convenient to you. plist works fine as you can easily parse it into data-structures without the need of external libraries. Also something like JSON or plain CSV would work. If you write a level-editor yourself, you can use any of these formats.

You don't have to write the level editor yourself though. Since your game is row/column based, a tile editor like Tiled works just fine. Cocos2d directly supports Tiled maps. I guess any other tile-editor will work fine too.

If you don't like Tiled and rather wish to freely position sprites, have a look at CocosBuilder.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.