How do I export my game?

0 favourites
  • 3 posts
From the Asset Store
Easily generate many levels from a set of pre-built scenes (Construct 3 template)
  • On start layout I want to execute a loop for each of two (or more) existing instances of a text object that each represent a swipe menu.

    This loop starts a second loop with an index, creating the menu items, which are simply more instances of the same objects in a horizontal row right next to where the existing ones are.

    Everything seems to work up to the point where I need the newly created objects to get their names from an instance variable "Items" containing a string. This string is a list of all the items and different of course for each of the pre existing objects, but for some reason all created objects reference the instance variable of the same object, and I can't figure out how to specifically look at each object in the layout and based on that instance's variable "items" create a row of new objects that derive their number and text from that variable.

    I'm having a really hard time understanding the flow of information and picking, even though i keep reading the manual section about how events work over and over.. Any help would be greatly appreciated!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • After the "Create" action, MenuItem object refers to the created instance, not the one picked in the first loop.

    So if you need to copy some settings from that instance into the newly created one, there are two methods:

    1. Use a family. Add MenuItem to a family, and then you can do things like "MenuItem Set Items to MenuItemFamily.Items"

    2. Use local variables for temporarily storing and copying the values:

    Local variable tmpItems
    
    For each MenuItem
     set tmpItems to MenuItem.Items
     Create MenuItem
     MenuItem set Items to tmpItems
    
  • Thank you, dop2000! That works great.

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