object properties default values

0 favourites
  • 3 posts
From the Asset Store
Welcome! I-Spy (Hidden objects) is an educational puzzle that is more than just seek-and-find activities.
  • when you create an object and give it behaviors what determines what the default settings are if you have multiple of them on your layout?

    I have a situation where I have 1 object on 2 different layouts. If that object has Bullet and set the speed to 400 on one and 200 on the other. When I create a new instance of that object which Bullet Speed will it inherit?

    likewise if I were to have 10 copies of my object on the main layout, then in-game I Create a new one, what will be the one it uses to default its settings from?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Construct picks an arbitrary existing instance to copy the properties from.

    If you have two instances with different properties, and create a new instance at runtime, which should it pick to copy properties from? There's currently no way to tell Construct which one to use as a reference, so it guesses one. It could use either.

    The main idea behind this is that if all your instances use the same properties, new instances get the same properties like you'd expect. If your instances use different properties, you can use actions after creating the instance to set the properties that matter.

  • Ashley okay, that makes sense, thanks for the explanation. I thought maybe if you selected the object from the Project Window it would load the "prefab" of that object's default settings.

    Good to know!

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