Making multiple levels for a 2D game

In the games industry, how do the developers make multiple levels for a 2D game, for example cut the rope or angry birds.

I have been wondering this for quite some time and i don’t know how this is done in the games industry. I know about making many scenes and having each one as a level, but to me that technique seems like it will take up a lot of memory, especially for a game that will be on the mobile.

In the games industry is that how it is done? Or is there another technique i don’t know about.

Thanks
APenguin

Usually you just have one scene for “game” and have custom built level editor to create and save them in custom format. When level is loaded runtime you just create the scene based on data.

1 Like

Using one scene makes a lot of sense :). Are there any level editors which you recommend to use for unity? or in general any recommended level editors? Or do i have to make my own. :slight_smile: Thanks

edit: Also just to get myself on a correct understanding. When you say create the scene based on data, do you mean just load the level designed into the scene at runtime?

Usually the level editor is self made for the game so there is no generic editor unless you want to use Unity itself. Unity itself saves a lot of stuff in scenes but you could create simple scripts to export unity scene as your custom format by looping all the game related objects and storing only the data needed to re-create the level runtime.

For Angry birds you could check these to get rough idea whats stored for level


http://www.battlefieldsingleplayer.com/apachethunder/angrybirds/

That first link helped me understand a lot :slight_smile: I think i could create my own level editor in that sense.

However i am not entirely clear what you meant by exporting my unity scene as a custom format.

Do you mean creating a scene using the editor in unity or with my own editor, then exporting or saving that scene as a file which unity reads, such as YAML, then loading that file at runtime. So for example the game would check which level has been chosen, i.e level 57, then load that particular level into the scene.

Well the Unity scene to your custom level format was just example if you don’t want to roll out your custom editor but what ever way to create your level files you choose the key thing is to have one “game” scene which you pass the number or filename of you level and then parse on start and create level setup based on it.

1 Like

Thanks. You have really helped :slight_smile: I will do some more research on how to save a scene as a text file, or YAML file, and then load that file into the scene on start()