PraetorRegnum

Line

Mar 12th, 2022
1,058
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.28 KB | None | 0 0
  1. xPos = 155
  2. canvasSize = 310
  3.  
  4. def setup():
  5.     size (canvasSize, canvasSize)
  6.     background(200)
  7.     strokeWeight(3)
  8.     stroke(160, 32, 240)
  9.  
  10. def draw():
  11.     global xPos
  12.     background(200)
  13.     line(xPos, 0, xPos, canvasSize)
  14.     xPos+=1
  15.     if xPos >= canvasSize: xPos = 0
  16.  
Advertisement
Add Comment
Please, Sign In to add comment