Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
6581 | leency | 1 | -- Draw isometric grid - Copyright 2010 Paulo Silva |
2 | -- This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License. See |
||
3 | w,h=getpicturesize(); |
||
4 | ok,gsiz,ik=inputbox("draw isometric grid","size",16,0,128,5,"colour",1,0,255,6); |
||
5 | if ok==true then |
||
6 | for y=0,h-1,gsiz do |
||
7 | for x=0,w-1,1 do |
||
8 | putpicturepixel(x,y+(x/2)%gsiz,ik); |
||
9 | end;end |
||
10 | for y=0,h-1,gsiz do |
||
11 | for x=0,w-1,1 do |
||
12 | putpicturepixel(x+((gsiz/2)-1),y+(gsiz-1)-((x/2)%gsiz),ik); |
||
13 | end;end;end |