Duplicate a layout with its contents

0 favourites
  • 5 posts
From the Asset Store
Plugin Transition Layout C3. Layout opening and closing animation for C3. Quickly set up transitions between lay
  • Hi

    I am wondering if there is a faster way to duplicate a layout with all its contents in the same file without having to manually duplicate all contents, rename and reconnect in the code?

    For example if I have level 1 layout with 10 sprites, their behaviour/fx, related families and code. Can I make level 2 layout duplicating level 1 where the contents of level 1 (sprites, behaviours, fx and families in this example) also are duplicated and connected to the level 2 code automatically?


  • You definitely don't need to duplicate any content. The beauty of Construct is that everything may be reusable - objects, layers, events.

    Two levels in the game can share many resources. For example, layers like background or HUD can be set as Global. This way you only need to create it once on the first layout.

    Add instances of objects, don't clone them! If you have a zombie on level 1 and want to add a zombie on level 2, just drag&drop the same object, don't create Zombie2 sprite.

    Also, set the same event sheet for both layouts. If any events need to be different on level 2 for example, you can add specific conditions, for example "If LevelNumber=2 ....."

  • Thanks Dop2000. Sorry, I forgot to mention one thing in my question. I want to reuse all code and behaviour of the sprites between the layouts but I have to change the images and animation images inside layout 2. Also as i build the new level i may add additional changes to the sprites connected to new level. That’s why i was thinking of a way to duplicate.

  • You can add images for level 2 as animations to the same sprites. But a better option would be using families. For example, if you have different monster sprites on level 1 and 2, add them all to the same Enemies family. Configure instance variables and behaviors on the family. And use the family in all events.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hi Dop2000,

    Thanks I understand what you mean. I have been thinking wrong way. It makes sense and this will also avoid unnecessary duplication.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)