lennert's Forum Posts

  • It worked!! Thank you so much!!

    And besides that, you finally made me understand the 'for' loop function!

  • A bg thank you for your interesting reply!

    But I don't understand 'loopy' or 'loopx'? Can I find those expressions anywhere? I do know 'loopindex' but nog loopy or loopx...

    -> correction: loopx and loopy are just the names you have given?

    thanks!

  • Hello

    I'm here a again with a new question to search & use data from an array.

    If my array looks like this:

    y0 = 'Name1' 'Name2' 'Name3'

    y1= 'Interest1' 'Interest4' 'Interest2'

    y2= 'Interest2' 'Interest5' 'Interest5'

    y3= 'Interest3' 'Interest1' 'Interest6'

    It's easy to return every interest of a certain name in a text, but is there somebody who can help me with the code to return every name that has the same interest? For example 'Interest1' = 'Name1' & 'Name2'

    Thank in advance for every tip you can give me!

    Lennert

  • Thank you a lot Plinkie, for the extra tip!!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks a lot for your reply!

    So how can I do this correctly? Are those 2 conditions or 1?

    What I understand from your answer is

    • using 'for' condition & using compare size array? But I seems like I'm not using it properly...
  • Hello everyone

    I have a small question about using arrays.

    Is there a way to use elements (values) of certain axe-values in a condition?

    For example all the y-elements at x=3 or all the y-elements except those on x=0?

    Is there an alternative for 'for each element'?

    Thanks in advance!

  • It worked!! wauw!

    Thank you so much Stan.

    In a couple of months, we're maybe going to need a man like you for bigger questions.

    I've seen your post about working with you as a freelancer, since we've some money for a freelancer for our project, I'll keep in touch!

    greetz and thank you

    Lennert

  • Hey I've tried a lot but I can't seem to find a way to write a event using the array for this function:

    The Array is orderd as following:

    X = Name1, Name2, Name3

    Y1= Spec1, Spec2, Spec 3

    Y2 = Spec 4, Spec5, Spec6

    Function:

    Textobject1 chooses randomly one of the three name. (that's no problem afcourse)

    In 2 instances of the same textobject2 I want to display the specs that are listed under the name that has been chosen and displayed in the first textobject1 (using a small loop for textobject2)

    If there is a golden event tip for this one, it would save a headache!

  • Thank you so much for the 2 tips!

    I was trying out the way with the array but using dicitionary seems more logic for this one!

    (I didn't know we could use CSV in it)

  • Hey guys, didn't find a better description for the subject.

    Maybe this is a easy question for Construct users who have experience with storing data

    What I would like to do is the following:

    I have 28 characters (names) and 12 possible 'specs' (words).

    Each character has 4 of these possible 'specs'.

    I would like to use these 2 data rows in both ways:

    • getting every spec of a character
    • getting every character sharing the same spec.

    How can I do this in the most efficient way?

    I presume I have to use an array? What are the events look like for both functions?

    If someone can put me on the right track with some advice, I could find the rest.

    Thanks in advance!

  • Yes! It's working!!

    I've done it just with the repeat-condition (without variable) and I managed to use this loopindex code! Since my objects had to be at certain imagepoints of another sprite, I tried this one for Y-position:

    Sprite.imagepointY((1)+(loopindex+1)))

    So with creating following instances, it will pick next imagepoint.

    Wow, I could not have done this without your examples! I've learned now how I can use this loopindex

    Thank you very very much! and everyone else who gave me advice!!

  • Thank you everyone for your help and responses!

    I never used the loopindex before, it seems like something I need in this case

    but what I still don't understand, is how I can make a reference to a certain position of the first object in the lay out?

    So the position of the first instance of the object is fixed at X,Y

    The following instance is Y+75, the third is at Y + 75 + 75 and so on..

    thanks anyway!

  • Hello there

    I'm still a beginner so maybe this question is easy for a lot of people

    I would like to create a bunch instances of the same object using loop. The position of the first instance is a certain point in the lay-out between each new instance there is a different distance of 75 on the Y-axe.

    I've tried to use loop to make the event efficient but I could'nt manage to find it working...

    Thanks in advance

  • haha, yes, now it works!!

    finally, what a relief

    A huge thank you for your time!

  • Hey Thank you very much for your response!

    I don't that will be the way. (Cause the system condition 'compare 2 values' does'nt pick objects.

    Let me explain the purpose more precisely:

    I have for example 10 different textlines in a php.file.

    One and the same text object is picking out 1 of those textlines randomly.

    For example: in three textlines there is the word "Shooter" like in "You got a new highscore in Shooter"

    Each time there is a textline with the word "Shooter" in, I would like to show a sprite next to the textobject.

    I want to make a condition just for textobject instances with that word, and not comparing text for each of the 3 sentences.

    Thanks for searching a solution with me!

    Lennert