Add a second level?

Get help using Construct 2

Post » Tue Mar 06, 2012 4:16 pm

I understand the functions of what they do and their purpose but I do not understand implementing them into the right areas.
B
8
S
4
G
3
Posts: 69
Reputation: 2,556

Post » Wed Jan 09, 2013 10:28 pm

How can I use more than 1 Event Sheet into a single Layout?
B
12
S
6
G
3
Posts: 100
Reputation: 3,836

Post » Thu Jan 10, 2013 8:34 am

Right click in the layout's event sheet -> include event sheet. You can chain together multiple event sheets in this way. Eg: Level -> game mechanics -> global variables, or score screen -> global variables

Easily my favourite feature in Construct 2.
B
56
S
15
G
10
Posts: 910
Reputation: 11,942

Post » Wed Jan 30, 2013 3:23 pm

I'm new to C2 and game development so apologies if this is a dumb question...

Why would you want to chain Event Sheets together? Is it just so it's easier to navigate or is there a limit to what you can add on a single event sheet? Surely having one event sheet per layout is more straightforward?
B
15
S
4
G
1
Posts: 4
Reputation: 1,476

Post » Wed Jan 30, 2013 3:33 pm

Imagine you have a platform game with many enemies that have their own movement and attack styles. You'd have to copy / paste the enemies' code into each event sheet for each level. After creating 10 levels, what if a bug arises with an enemy? Or you want to add another enemy? You'd have to go through all 10 event sheets.

By having all the enemies in 1 event sheet that you "include" in each level's event sheet, you only have to change or add things in one place and it carries across to all event sheets that include it.

Plus it's easier to read.
B
15
S
5
G
7
Posts: 877
Reputation: 5,650

Post » Wed Jan 30, 2013 3:42 pm

@Featherface - There's a fundamental guideline in all programming that you should never unnecessarily duplicate code. Rather, you write it once, and then call that same code every time you need to perform the particular function it does.

So, if you've coded some event logic that describes how a particular enemy behaves (on an event sheet), and that enemy appears on more than one level (layout), you shouldn't rewrite the behaviour logic on seperate event sheets for each layout. Instead, you write it in one event sheet and include that same event sheet on every layout.
B
8
S
2
G
3
Posts: 83
Reputation: 2,668

Post » Thu Apr 25, 2013 2:10 pm

I'm rediculously slow responding to this but thanks both for the pointers!

Why is that when you find a new hobby, all of a sudden work, wife and family all find reasons to take up more of your time??
B
15
S
4
G
1
Posts: 4
Reputation: 1,476

Post » Thu Apr 25, 2013 3:20 pm

On a side note almost every question on this thread is answered in depth in the tutorials. Best way to learn is to do it and the tutorials will also familiarize yup with the concepts and common methodologies for building your games more efficiently.
B
49
S
11
G
10
Posts: 1,833
Reputation: 14,418

Previous

Return to How do I....?

Who is online

Users browsing this forum: bluemonkey, Khamsou and 21 guests