Re: Structs
- Posted by irv Jun 19, 2019
- 4108 views
Things like this are often necessary and useful. So the dot notation shouldn't really stop at a single level:
point = {integer x, integer y) critter.position = point critter.position.x = 10 critter.position.y = 20 critter.position = {20,20} critter.position += {50,40} critter.path = repeat(critter.position,10) -- i.e. an array in which you could store the last 10 locations