Object oriented CONSTRUCTion

  • Hi there,

    just wanted to read your opinions on OOP possibilities in construct. What I miss right now (or don't get) is the way of defining custom objects in construct without using plugin API.

  • What kind of customization do you want to do? Can you give an example?

    You can add instance variables and behaviors to objects, which allow a certain level of customization.

    To change the inner workings of an object, or create new object functionality, you need to use the JavaScript SDK and make your own plugins or behaviors.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Are you asking about Construct Classic or Construct 2?

    Construct Classic forum is lower on the page.

    In C2, there are a lot of ways of defining individual objects, we need more details to respond to your question. What do you want to do?

    Also, please search the forums (topright search box), look in the C2 Manual, and check Kyatric's FAQs. Most questions can be quickly and easily answered through those sources.

  • For example, extending sprite class with some custom "methods", which could be accessed through events and actions. As far as I understand behaviour system has exactly this function. May in the feature it will be possible to write nested event logic with visual editor inside an object type, which could be accessed like a method.

    Another example is defining a new/custom class type. But again, behaviours and plugins are the answer.

    May be there are some good practices, how to structure event logic, so it resembles some OOP concepts.

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