Duplicate Enemies

Get help using Construct 2

Post » Fri Aug 30, 2013 12:01 am

So I'm new to the forums and new to Construct. I've been following tutorials and doing tests on creating a platform game. I went with a Mario theme for testing as it is easy to find artwork, so I don't have to create art while I'm figuring out the engine. I've created a Goomba enemy and when Mario jumps on him he dies.I'm wondering now how I can duplicate this enemy within my level, code and all, so I won't have to re-code every single enemy. Basically is there any way to code an enemy, then just duplicate him over and over to create more instances of that same enemy within the level.

Here's what I have so far.
https://dl.dropboxusercontent.com/u/72974151/MarioTest/index.html
Image
B
47
S
17
G
3
Posts: 206
Reputation: 5,061

Post » Fri Aug 30, 2013 12:07 am

Hold down CTRL and then click on the enemy and drag. It will create a copy.
B
47
S
18
G
84
Posts: 2,271
Reputation: 49,796

Post » Fri Aug 30, 2013 12:11 am

Oh, nice I knew that duplicated the sprites, didn't know the code would work for the duplicates. Well that was easy. Thank you very much.
Image
B
47
S
17
G
3
Posts: 206
Reputation: 5,061

Post » Fri Aug 30, 2013 12:17 am

Code will apply to all of that object type. All behaviours, variables, sprites etc will carry over as well.
B
47
S
18
G
84
Posts: 2,271
Reputation: 49,796


Return to How do I....?

Who is online

Users browsing this forum: RIDETHEPIG and 5 guests