Easiest way to make multiple levels?

Get help using Construct 2

Post » Mon Oct 10, 2011 7:55 am

It seems good, but that is a lot of work (it seems all objects have to be placed by code), and when I have 80 or so objects... And I only get one layer. Perhaps Ashley or Tom could let us know the way it was intended to work...
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Tue Oct 11, 2011 9:47 pm

This is still bugging me... Since I will have many objects and relatively few levels (within the levels, not much is to be changed, just walls and the like) I suppose I am not too concerned about updating new/changed objects.

A 'duplicate layout' option would be nice, I suppose...
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Tue Oct 11, 2011 10:34 pm

There's a "hack" to duplicate layout.

Save your project as a folder (or open your capx in a zip program like winzip or 7zip and extract the files to some folder).
In the folder "Layouts" go and make a copy of the layout you wish to duplicate (ex "Layout 1.xml")
Rename the copy (ex: "Layout 2.xml")
In the file itself, change the name in between the <name></name> tags.
(ex "<name>Layout 2</name>")

Go back to the root folder and open your .caproj in the notepad.
Look for the line:
<layout-folder expanded="1">

Right after you should have:
<layout>Layout 1.xml</layout>

Copy this line and paste it right after (with the same indentation). Rename to the name you gave to the layout copy earlier (ex: "Layout 2.xml")

Save the .caproj, open it in C2, you should have a clone of the previous layout standing in your Layouts folder. This layout is currently aimed to use the same event sheet as the original layout.

It's a bit hacky, so be sure to make backups of your projects before using it and use at your own risks ^^.
Kyatric2011-10-12 08:10:33
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 7,000
Reputation: 57,795

Post » Wed Oct 12, 2011 6:24 am

Hmm, seems fine I suppose. Funny how all the methods for simply making more levels seem so... convoluted...

I tried your method and I got an error (layout name "layout 1" is being used by more than one layout).

sqiddster2011-10-12 07:41:47
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Wed Oct 12, 2011 12:45 pm

[QUOTE=sqiddster]I tried your method and I got an error (layout name "layout 1" is being used by more than one layout).[/QUOTE]
The error is telling you what the problem is! You can't have two layouts with the same name. Make sure you edit the <name> tag of the second layout.Ashley2011-10-12 12:46:26
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Wed Oct 12, 2011 1:34 pm

I have used the copying the xml's and editing them and that works great, what i have done and am still doing on my latest game is similar to an earlier post, if you have a game that uses most of the same objects and conditions for each level, then globals is what i use, and i leave one level open and simple COPY and PASTE, and if i want the same graphic/object but to change some behaviours etc i use CLONE OBJECT TYPE.

As for the Events, i create GROUPS such as CONTROLS, COLLISIONS, CONDITIONS, DEBUG etc then you can just copy and paste them into your new Event Sheets,

Also it's worth noting i rename all Layouts and Event Sheets to match for easier and faster editing and bug finding.

That way everything is nice neat and tidy and easy to understand.tonycrew2011-10-12 13:36:52
B
40
S
14
G
11
Posts: 243
Reputation: 9,432

Post » Sat Oct 15, 2011 7:52 am

You should make the walls randomly generated
B
2
G
1
Posts: 3
Reputation: 558

Post » Sat May 12, 2012 1:34 am

Does the actual "Duplicate" option, when you right click a layout override this "hack"?
B
6
S
1
Posts: 54
Reputation: 958

Post » Sat May 12, 2012 1:40 am

   I just right click on a layout in the projects windows and duplicate.
B
23
S
7
Posts: 79
Reputation: 2,215

Post » Sat May 12, 2012 1:59 am

Yeah, that's what I was talking about. This thread is from Oct 2011, so I was just making sure, as I was having some issues.
B
6
S
1
Posts: 54
Reputation: 958

PreviousNext

Return to How do I....?

Who is online

Users browsing this forum: 99Instances2Go, abdalghani, Marxally and 27 guests