SHARE
TWEET

Untitled

a guest May 12th, 2010 116 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. from pyprocessing import *
  2.  
  3. size(900,600)
  4. background(1, 1, 1)
  5. strokeWeight(6)
  6. x1 = 0
  7. y1 = 0
  8. x2 = 0
  9. y2 = 0
  10. x = [0,0,0]
  11. y = [0,0,0]
  12.  
  13. def draw():
  14.     if mouse.pressed:
  15.         x1 = mouse.x
  16.         y1 = mouse.y
  17.         if mouse.pressed:
  18.             x2 = pmouse.x
  19.             y2 = pmouse.y
  20.             stroke(x1,y1,1)
  21.             line(x1, y1, x2, y2)
  22. run()
RAW Paste Data
Top