Construct 3 suggestions & ideas

Suggest and vote on ideas for Construct 3! Please note this is only one aspect of planning. We do not guarantee any features here will be implemented, even if they are top-voted ideas. The aim is just to collect feedback. Remember to search for existing submissions before adding an idea, describe your ideas as comprehensively as possible, and vote for plausible ideas that are well thought out. Please see our full guidelines on suggesting features.

50 VOTE

Family inheritance

This should be usefull in achieving tree connection between objects. 
For example - Family "Animals" -> defines some vars that are generic (height, weight etc..) and then you make Family "Dogs" that inherits Animals and it already contains the vars that Animals have + you can add more vars that are specific to Dogs. You can also continue that way.
Also -> you would create a function for example "Eat" In Animals and every inherited object would have "Eat" function. Therefore it would be helpfull really to create trees of objects without writing same code xx times. 

  • Guest
  • Apr 5 2017
  • No status
  • Apr 18, 2017

    Admin Response

    This needs a fairly thorough review of the engine to investigate its feasibility. As such, we'll leave this idea as "needs review".

  • Attach files
  • Salman_Shh commented
    April 05, 2017 18:57

    This would be super useful!

  • Guest commented
    April 18, 2017 16:23

    Good.  It might be a good consideration for the new runtime though since it's  still not in development :) 

     

  • mumu64 mumu commented
    September 18, 2018 09:46

    The example you gave with vars, is what I already do with families: I make the object a member of the families that it belongs to. 

    Wouldn't that also be the case with the function? Because, in my example, I added the object to the "animal" and "dog" families, so it also can use the Animal function. 

    If I am wrong, I am looking forward to your explanation.

  • mumu64 mumu commented
    September 19, 2018 14:48

    To add to my previous comment: I now have encountered a situation where I need to do something to a family, that also can use variables that the "main" family has. So I will upvote this idea. :)

  • RhapsodyInGeek commented
    09 Jan 20:18

    This can be solved pretty easily by the "Pick by UID" condition.

    You have 2 Sprites "Corgi" and "Mastiff", who are part of Family "ANIMALS" and Family "DOGS", inheriting both of their variables and events. Then let's say there's a Sprite "Calico" that is a part of Family "ANIMALS" and Family "CATS". Let's say we add Line Of Sight to ANIMALS, giving Corgi, Mastiff, and Calico the behavior. Then let's give DOGS the boolean "Bark", so now Corgi and Mastiff have Bark but Calico does not. Now we want our DOGS to Bark whenever they see Calico, and any future CATS we may add.

     

    +ANIMALS.LOS has line of sight to CATS

    +DOGS.UID = ANIMALS.UID

    -> Set DOGS.Bark to True