|
1 registered members (7th_zorro),
529
guests, and 2
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: pass multidimensional array to function
[Re: yorisimo]
#173445
12/18/07 05:36
12/18/07 05:36
|
Joined: Oct 2006
Posts: 175
Gumby22don
Member
|
Member
Joined: Oct 2006
Posts: 175
|
lite-c still doesn't support [x][y] multi-dimensioned arrays. You need to use [x*max_y + y] - whether you make a custom function to take the x,y and return the single address, or just use that formula all the time is up to you. Check the manual Don have a great day
|
|
|
Re: pass multidimensional array to function
[Re: Gumby22don]
#173447
12/18/07 21:55
12/18/07 21:55
|
Joined: Mar 2007
Posts: 197
yorisimo
OP
Member
|
OP
Member
Joined: Mar 2007
Posts: 197
|
from the manual: Quote:
LC In lite-C, you can also define and address multidimensional arrays by using several indices:
var heightmap[10][20];... heightmap[j][k] = 10; // j = 0..9, k = 0..19
Lite-C does support this. And I have used this method. However, I can't seem to pass it to a function.
Last edited by yorisimo; 12/18/07 21:56.
|
|
|
Re: pass multidimensional array to function
[Re: Gumby22don]
#463899
01/04/17 20:14
01/04/17 20:14
|
Joined: Jan 2017
Posts: 2
vas
Guest
|
Guest
Joined: Jan 2017
Posts: 2
|
lite-c still doesn't support [x][y] multi-dimensioned arrays. You need to use [x*max_y + y] - whether you make a custom function to take the x,y and return the single address So, is there any improvement in lite-c multi-dimensioned arrays?
Last edited by vas; 01/04/17 20:14.
|
|
|
|
|
|