How do I insert in array ?

Just started using Construct 2? Post your questions here

Post » Tue Mar 18, 2014 10:04 am

Hi!
I'm having some dificulties in create a 2D array.
I need something like this:
Product - Price - Quantity
ball - 10 - 2
sword - 3 - 5

How can i insert this in an array ?
B
11
S
3
Posts: 39
Reputation: 814

Post » Tue Mar 18, 2014 10:33 am

From : https://www.scirra.com/manual/108/array

Set at XY
Write a value at a position in the array. Indices are zero-based. Writing to values outside the array has no effect. If Set at X is used, the Y and Z indices are 0. If Set at XY is used, the Z index is 0.

So for ball
Set at x = 0, y =0, value = "ball"
Set at x= 0, y= 1, value = 10
...
B
39
S
15
G
5
Posts: 295
Reputation: 6,089

Post » Tue Mar 18, 2014 4:53 pm

Ok, thanks ;)
B
11
S
3
Posts: 39
Reputation: 814


Return to Beginner's Questions

Who is online

Users browsing this forum: No registered users and 3 guests