Quantcast
Channel: Help! with 2.0 - Twine Forum
Viewing all articles
Browse latest Browse all 1844

Check value in two dimensional array in Harlowe.

$
0
0
Hello, I'm new here.
How can I check value in two dimensional array like: (this obviously don't work for me)

(if: $levelMap[$posX][$posY+1] is > 0)[[Go South]]

The $levelMap is 10 : 10 array:
(set: $levelMap to (a:
[0,0,0,0,0,0,0,0,0,0],
[0,1,1,1,1,1,1,1,1,0],
[0,1,0,0,0,0,0,0,1,0],
[0,1,0,1,1,1,1,0,1,0],
[0,1,0,1,1,1,1,1,1,0],
[0,1,0,0,0,0,0,0,1,0],
[0,1,1,1,1,1,1,1,1,0],
[0,1,0,0,0,0,0,1,1,0],
[0,1,1,1,1,1,1,1,1,0],
[0,0,0,0,0,0,0,0,0,0]))

Viewing all articles
Browse latest Browse all 1844

Trending Articles