52 posts
Posted 30 December 2013 - 10:18 PM
After a very long hiatus, I have decided to return to toying around with ComputerCraft programs. I want to modify the game 'tunnel' to use filled in white pixels on a normal (non-colour) computer. I know that it's possible (the stock worm program does it), but I can't figure out how to get paintutils to do it.
Sorry if this is a painfully stupid question.
892 posts
Location
Where you'd least expect it.
Posted 30 December 2013 - 11:53 PM
If you want to make a filled in white pixel, then simply write a space while the background color is white. To do this, use this snippet:
term.setBackgroundColor(colors.white) --#Set the color to white
term.write(" ") --#Write a space
term.setBackgroundColor(colors.black) --#Assuming the background color of the game is black.
To check if the computer is color (advanced) or not, use term.isColor(). It returns true if the computer is color, and false if it isn't.
Edited on 30 December 2013 - 10:56 PM
1281 posts
Posted 31 December 2013 - 06:54 AM
to do it with paintutils you simply do paintutils.drawPixel(pointX,pointZ,colors.white). If you want lines you can do paintutils.drawLine aswell, jsut give it 2 sets of coordinates.