Create the same Object with different properties

0 favourites
  • 6 posts
From the Asset Store
Adjusting the game screen for different resolutions (Letterbox scale)
  • Hi Constructors,

    How do I create Objects with effect and without effect?

    I have object on the stage let say a ball. I want this object to be duplicated but the duplicated objects has Effect in it and some are not.

    I'm thinking of having two objects and the other object with effect?

    Any advice.

    Thanks,

    -morex

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • One possibility is You could simply have 2 versions of the objects and make both objects fall under the same family. You want more specific details?

  • You could have one object and create multiple instances of it in the editor (ctrl drag object in the layout). Then, either:

    a) disable effect in the properties of one instance.

    b) give object an variable like 'effect', which you can use to see which object should have which effect enabled. Set up events to disable/enable effects for objects based on this variable. You can then use this variable to set effects properly during the play.

  • Thanks keroberos. That is what i'm doing now but I feel it's not the best way.

    vee41, Thanks. I think that's the correct approach but my problem is when i enable the effects, all objects are affected. Do you have a working example to share?

    Thanks,

    -morex

  • Thanks keroberos. That is what i'm doing now but I feel it's not the best way.

    vee41, Thanks. I think that's the correct approach but my problem is when i enable the effects, all objects are affected. Do you have a working example to share?

    Thanks,

    -morex

    Heres a quick demo:

    Evil sprites

    The last event is function you can call to enable/disable effect in certain situations, you could easily adapt something similar to your own project.

  • Awesome example Very nicely done. This is what I have in my mind but I don't know to implement in Construct. Thanks again for your effort and I appreciated it so much.

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