Hi,
I am trying to create a card battling game, but I am having some issues moving the data around. Here is what I have:
A Struct of Card data
A data-table created from the struct
2 Enums for elements on the card (as well as other variables)
I have a Card Widget that displays all the data from the struct.
At the start of the game I “Load” all the cards from the data table by creating a card widget for each entry in the data table using the struct information.
(This works as intended for the moment as I have a number on the screen telling me how many items are in my Array of cards)
However When I try to loop through my array of widgets, I can’t seem to find out how to access the elements of the widget.
What I want to do at this moment in time is create a starting deck for a character. So I need to be able to access each widget in the array go to the struct and check the enum for the character, then “copy” the card from the first array in to my new array of Character 1, cards. So that I can have a starting deck for them to play with.
So if anyone knows how when looping through an array of widgets, how to access the variables in that widget I would appreciate it. (They are currently visible and exposed on spawn so I can access them)
Thanks