Yeah I'm making a map creator where you can make a map for my linear array visually. basiclly you click on the legend then you click on td you want the tile in and eventually I will make it so you click generate and bam it gives you an array. I diverge from my point here's the script in action:
http://www.cyberpunkgame.0nyx.com/map.html
Yeah and the problem is since I can't create the images on-the-fly that're in a table I figured I'd have to use z-index to stack them. but position absolute puts them absolutely outta the table. I dunno here's the code:
HTML Code:<html> <head> <script type="text/javascript"> <!-- var legendvalue //across document.write('<table border="1" cellspacing="0" cellpadding="0"><tr>'); //make table rows for(i=1;i<201;i++){ if(i==21 || i==41 || i==61 || i==81 || i==101 || i==121|| i==141 || i==161 || i==181 || i==201){ document.write('</tr><tr>'); } //create td's 200 to be exact document.write('<td height="25" width="25" ><img id="concrete'+ i +'" src="concrete.jpg" style="position:absolute;z-index:1"><img id="block'+ i +'" src="block.bmp" style="position:absolute;z-index:2"></td>'); } document.write('</table>'); function setup(thevalue){ legendvalue = thevalue; } //--> </script> </head> <body> <table cellpadding="0" cellspacing="0" border="1"> <tr> <td> ..::Legend::.. </td> </tr> <tr> <td> <img src="concrete.jpg" onclick="setup(1)"> <img src="block.bmp" onclick="setup(2)"> </td> </tr> </table> </body> </html>



Reply With Quote

Bookmarks