Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2019
265
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 2.25 KB | None | 0 0
  1. speed(0)
  2. bgcolor((0,235,260,0.5))
  3. penup()
  4. x=-290
  5. y=100
  6. setposition(x,y)
  7. r=220
  8. setposition(-200,0)
  9.  
  10. #this function makes the sky
  11. def rectangle(color_choice):
  12.     begin_fill()
  13.     color(color_choice)
  14.     for i in range(8):
  15.         forward(400)
  16.         left(90)
  17.     end_fill()
  18.     left(90)
  19.     forward(13)
  20.     right(90)
  21.    
  22.    
  23. for i in range(16):    
  24.     r=r-10
  25.     rectangle((r,225,255))
  26.    
  27.  
  28.    
  29.    
  30.  
  31. penup()
  32. setposition(-190,150)
  33.  
  34. def clouds(size):
  35.     for i in range(4):
  36.         pendown()
  37.         right(180)
  38.         color("white")
  39.         begin_fill()
  40.         backward(size)
  41.         right(90)
  42.         circle(size/9,100,0)
  43.         right(90)
  44.         circle(size/5,120,0)
  45.         right(90)
  46.         circle(size/6,146,0)
  47.         right(90)
  48.         circle(size/1.9,30,0)
  49.         end_fill()
  50.         right(216)
  51.         size=size-10        
  52.         forward(size)
  53. def theclouds():
  54.     clouds(60)
  55.     penup()
  56.     setposition(-50,140)
  57.     clouds(30)
  58.     clouds(60)
  59.     penup()
  60.     setposition(-200,100)
  61.     clouds(80)
  62.     penup()
  63.     setposition(-10, 180)
  64.     clouds(30)
  65.     penup()
  66.     setposition(0,0)
  67.    
  68. theclouds()
  69.  
  70.  
  71.  
  72. def cloud_mountain(size):
  73.     for i in range(4):
  74.         pendown()
  75.         right(180)
  76.         color("white")
  77.         begin_fill()
  78.         backward(size)
  79.         right(90)
  80.         circle(size/9,100,0)
  81.         right(90)
  82.         circle(size/5,120,0)
  83.         right(90)
  84.         circle(size/6,146,0)
  85.         right(90)
  86.         circle(size/1.9,30,0)
  87.         end_fill()
  88.         right(216)
  89.         size=size-10        
  90.         forward(size)
  91. def themountainclouds():
  92.     penup()
  93.     home()
  94.     setposition(-10,10)
  95.     pendown()
  96.     cloud_mountain(50)
  97.     penup()
  98.     home()
  99.     setposition(-100,10)
  100.     pendown()
  101.     cloud_mountain(40)
  102.     penup()
  103.     home()
  104.     setposition(110,10)
  105.     pendown()
  106.     cloud_mountain(60)
  107.    
  108. themountainclouds()
  109.  
  110.  
  111.  
  112.  
  113.  
  114. speed(0)
  115. penup()
  116. setposition(-200,0)
  117.  
  118. r=200
  119. def rectanglerefl(color_choice):
  120.     begin_fill()
  121.     color(color_choice)
  122.     for i in range(8):
  123.         forward(400)
  124.         right(90)
  125.     end_fill()
  126.     right(90)
  127.     forward(13)
  128.     left(90)
  129.    
  130.    
  131. for i in range(16):    
  132.     r=r-10
  133.     rectanglerefl((r,225,255))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement