Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2019
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.80 KB | None | 0 0
  1.  
  2. speed(0)
  3. bgcolor((0,235,260,0.5))
  4. penup()
  5. x=-290
  6. y=100
  7. setposition(x,y)
  8. r=220
  9. setposition(-200,0)
  10.  
  11. #this function makes the sky
  12. def rectangle(color_choice):
  13. begin_fill()
  14. color(color_choice)
  15. for i in range(8):
  16. forward(400)
  17. left(90)
  18. end_fill()
  19. left(90)
  20. forward(13)
  21. right(90)
  22.  
  23.  
  24. for i in range(16):
  25. r=r-10
  26. rectangle((r,225,255))
  27.  
  28.  
  29.  
  30.  
  31.  
  32. penup()
  33. setposition(-190,150)
  34.  
  35. def clouds(size):
  36. for i in range(4):
  37. pendown()
  38. right(180)
  39. color("white")
  40. begin_fill()
  41. backward(size)
  42. right(90)
  43. circle(size/9,100,0)
  44. right(90)
  45. circle(size/5,120,0)
  46. right(90)
  47. circle(size/6,146,0)
  48. right(90)
  49. circle(size/1.9,30,0)
  50. end_fill()
  51. right(216)
  52. size=size-10
  53. forward(size)
  54. def theclouds():
  55. clouds(60)
  56. penup()
  57. setposition(-50,140)
  58. clouds(30)
  59. clouds(60)
  60. penup()
  61. setposition(-200,100)
  62. clouds(80)
  63. penup()
  64. setposition(-10, 180)
  65. clouds(30)
  66. penup()
  67. setposition(0,0)
  68.  
  69. theclouds()
  70.  
  71.  
  72.  
  73. def cloud_mountain(size):
  74. for i in range(4):
  75. pendown()
  76. right(180)
  77. color("white")
  78. begin_fill()
  79. backward(size)
  80. right(90)
  81. circle(size/9,100,0)
  82. right(90)
  83. circle(size/5,120,0)
  84. right(90)
  85. circle(size/6,146,0)
  86. right(90)
  87. circle(size/1.9,30,0)
  88. end_fill()
  89. right(216)
  90. size=size-10
  91. forward(size)
  92. def themountainclouds():
  93. penup()
  94. home()
  95. setposition(-10,10)
  96. pendown()
  97. cloud_mountain(50)
  98. penup()
  99. home()
  100. setposition(-100,10)
  101. pendown()
  102. cloud_mountain(40)
  103. penup()
  104. home()
  105. setposition(110,10)
  106. pendown()
  107. cloud_mountain(60)
  108.  
  109. themountainclouds()
  110.  
  111.  
  112.  
  113.  
  114.  
  115. speed(0)
  116. penup()
  117. setposition(-200,0)
  118.  
  119. r=200
  120. def rectanglerefl(color_choice):
  121. begin_fill()
  122. color(color_choice)
  123. for i in range(8):
  124. forward(400)
  125. right(90)
  126. end_fill()
  127. right(90)
  128. forward(13)
  129. left(90)
  130.  
  131.  
  132. for i in range(16):
  133. r=r-10
  134. rectanglerefl((r,225,255))
  135.  
  136. penup()
  137. setposition(-190,-150)
  138.  
  139. def cloudsrefl(size):
  140. for i in range(4):
  141. pendown()
  142. right(180)
  143. color("white")
  144. begin_fill()
  145. backward(size)
  146. left(90)
  147. circle(size/9,-100,0)
  148. left(90)
  149. circle(size/5,-120,0)
  150. left(90)
  151. circle(size/6,-146,0)
  152. left(90)
  153. circle(size/1.9,-30,0)
  154. end_fill()
  155. left(216)
  156. size=size-10
  157. backward(size)
  158. def thecloudsrefl():
  159. cloudsrefl(60)
  160. penup()
  161. setposition(-50,-140)
  162. cloudsrefl(30)
  163. cloudsrefl(60)
  164. penup()
  165. setposition(-200,-100)
  166. cloudsrefl(80)
  167. penup()
  168. setposition(-10, -180)
  169. cloudsrefl(30)
  170. penup()
  171. setposition(0,0)
  172.  
  173. thecloudsrefl()
  174.  
  175.  
  176.  
  177. def cloud_mountainrefl(size):
  178. for i in range(4):
  179. pendown()
  180. right(180)
  181. color("white")
  182. begin_fill()
  183. backward(size)
  184. right(90)
  185. circle(size/9,100,0)
  186. right(90)
  187. circle(size/5,120,0)
  188. right(90)
  189. circle(size/6,146,0)
  190. right(90)
  191. circle(size/1.9,30,0)
  192. end_fill()
  193. right(216)
  194. size=size-10
  195. forward(size)
  196. def themountaincloudsrefl():
  197. penup()
  198. home()
  199. setposition(-10,10)
  200. pendown()
  201. cloud_mountainrefl(50)
  202. penup()
  203. home()
  204. setposition(-100,10)
  205. pendown()
  206. cloud_mountainrefl(40)
  207. penup()
  208. home()
  209. setposition(110,10)
  210. pendown()
  211. cloud_mountainrefl(60)
  212.  
  213. themountaincloudsrefl()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement