|
Post by zenkrye on Nov 8, 2017 23:59:13 GMT
I am new to LUA but I think I just have a simple issue with syntax.
I am trying to pass a variable to the Type Method. I am trying to build a table with coordinates and then loop through the table. When I use a static value the call works as expected.
type(Location(265, 368),"295")
But when I try to change it to a table value or variable I get an error:
tbl = {{295,59}, {290,62}, {293,61}}
type(Location(265, 368),tbl[1][1])
x = tbl[1][1]
type(Location(265, 368),x)
Any suggestions would be greatly appreciated.
|
|
|
Post by AnkuLua on Nov 9, 2017 0:39:29 GMT
The second variable of type() should be string. change tbl to tbl = {{"295","59"}, {"290","62"}, {"293","61"}}
|
|
|
Post by zenkrye on Nov 9, 2017 2:52:03 GMT
Thank you, that was the simple issue that I was missing.
|
|