Families and Variables

0 favourites
  • 4 posts
From the Asset Store
Easily store, modify, read and manipulate colors with Color Variables!
  • Is there any way to make objects from families share variable types, but give them each individual amounts OF that variable?

    Let's say I have 3 bullet types in the family "PlayerShots". I want each to do an individual amount of damage, but I don't want to have to make each enemy have 3 different reactions to said bullets, but instead just subtract their health by the variable in each individual bullet's damage amount.

  • I think I understand you but I'am not %100 sure. I made a game where you buy guns and each upgrade does more damage to the zombies. Better yet if you got an android device run my game and then tell me if thats what your looking for.

    https://play.google.com/store/apps/deta ... ead.nights

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Is there any way to make objects from families share variable types, but give them each individual amounts OF that variable?

    Let's say I have 3 bullet types in the family "PlayerShots". I want each to do an individual amount of damage, but I don't want to have to make each enemy have 3 different reactions to said bullets, but instead just subtract their health by the variable in each individual bullet's damage amount.

    Yes, set the variable on playershots then edit all the members of playershots individually in the editor on the object list, changing the default value of the damage variable for them. Newly spawned instances of all those objects should correctly use the same default values as other bullets of that type.

  • > Is there any way to make objects from families share variable types, but give them each individual amounts OF that variable?

    >

    > Let's say I have 3 bullet types in the family "PlayerShots". I want each to do an individual amount of damage, but I don't want to have to make each enemy have 3 different reactions to said bullets, but instead just subtract their health by the variable in each individual bullet's damage amount.

    >

    Yes, set the variable on playershots then edit all the members of playershots individually in the editor on the object list, changing the default value of the damage variable for them. Newly spawned instances of all those objects should correctly use the same default values as other bullets of that type.

    Welp. I thought that didn't work. I recall a previous time where I tried that and the variables all remained the same for ALL objects in the family. Thread can be closed and locked, I was being silly.

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