Posted 13 December 2013 - 11:23 PM
Heyo guys!
So, I was testing some stuff with "x" and "y" positions in a creative world, just to get more used to it. While I was testing, I tried to make something like a horizontal line, no real reason behind it, again, just testing, and for that I needed a "for" loop with a "and" condicional inside it, and I don't even know if that's possible. The big question is, is it? Here's the code.
And also, if you guys have any tips related to using positions in a monitor, or a computer, just tell me, I really need some of those!
See ya!
EDIT: And just so I don't need to create another topic right away, I might as well just use this one.
I'm having a problem with the drawLine command from the paintutils API.
The code: pastebin.com/rqCgGd3n
What I want to do is to draw a horizontal line, starting and x position 1, and y position 1 - So it draws the line right at the top of the screen. But, for some reason, it's filling the whole screen with the color I'm giving, in this case black! I changed the color of the background to white, so, the result should be the white background with a black line on top. But that isn't happening!
Any ideas why?
So, I was testing some stuff with "x" and "y" positions in a creative world, just to get more used to it. While I was testing, I tried to make something like a horizontal line, no real reason behind it, again, just testing, and for that I needed a "for" loop with a "and" condicional inside it, and I don't even know if that's possible. The big question is, is it? Here's the code.
for i = 1,51 and i2 = 1,19 do
term.setCursorPos(i,i2)
print (".")
end
And also, if you guys have any tips related to using positions in a monitor, or a computer, just tell me, I really need some of those!
See ya!
EDIT: And just so I don't need to create another topic right away, I might as well just use this one.
I'm having a problem with the drawLine command from the paintutils API.
The code: pastebin.com/rqCgGd3n
What I want to do is to draw a horizontal line, starting and x position 1, and y position 1 - So it draws the line right at the top of the screen. But, for some reason, it's filling the whole screen with the color I'm giving, in this case black! I changed the color of the background to white, so, the result should be the white background with a black line on top. But that isn't happening!
Any ideas why?
Edited on 13 December 2013 - 10:54 PM