This was written as an example for a fellow member in the forums to show how to populate a playing card with data.
I have attached an example .Capx.
<== It can found on the left hand side of this tutorial:
What does it use?
project files Array Spritefont System Expressions Instance Variables
Instructions for usage is simple
Click the button on left to randomly draw a card.
Special Cosmetics.
Shows current card and total card
Shows card image using current card instance variable
The first card is a placeholder an is not included in shuffle (random(1,numbercards)
Numbercards is the array.width
Remember array counts 0 as 1 so you will notice for displaying total cards as a number I array.width - 1
Also I am using 2 dimensional array as I wanted to group card data together. Open json to get a better idea.
I also used instance variables, this is not needed, it was more to show a point of view of the data being retrieved.
NOTE:
This is filed under Capx Examples and the attached capx is the tutorial itself. It is merely as an example, and not a finished product. It is merely for demonstration purposes.