How do I Update a List from a XY array

0 favourites
  • 3 posts
From the Asset Store
Fantasy Game includes more than 600 sound effects inspired by hit computer games like World of Warcraft and Diablo.
  • Hi,

    I have some trouble with the communication between an array and a list.

    Basicly what I want is following:

    Player creates a spell with following atributes: name, dmg, element

    these are then saved within an array. X direction are the atributes / each new spell is inserted at the end of Y

    for visual feedback (and spell selection) I want to have a list with one item per spell (Y element) displaying the corresponding atributes.

    So I made an "updatespelllist" function wich is triggered when the array is edited.

    until there everything works fine. when i update the list with fixed XY values it works.

    BUT: I want the list to be updated in the following way:

    for each "array.height" - List: add item with the text "array.at(0, loopindex) & array.at(1, loopindex) & array.at(2, loopindex)

    wich should create an item with the text "name dmg element"

    instead my gets created empty

    Can anyone see where my logic doesnt work?

    Greetings Henning

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I do not know... did I correctly understand what you're trying to do...

    but... <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    capx> https://app.box.com/s/u3yk0dnwuj7402cg9thm39ighzk90ke9

  • Oh sry I kind of messed up in the explanation =D

    Thank you verry much for time. Unfortunately it was not what I was looking for but I managed to solve my own problem.

    Cheers

    Henning

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