We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

Multiple properties per object

Home Forums General Questions Multiple properties per object

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #54892
    tsvetan
    Participant

    Hi! I want to ask what’s the best approach (if possible) to create an object with multiple properties. For example, I have “Car” or list of objects “Cars” and I want to set its properties like name, speed, health, position (vector3), etc.?

    Then ofc I would like to access these properties.

    Thanks in advance! :)

    #54895
    kdv
    Participant

    Use dictionaries for this purpose.

    Puzzles and JS. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of meaning at all.

    #54901
    tsvetan
    Participant

    Great example! Thank you very much :good:

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.