Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def fish(x0, y0):
- # Draw a fish:
- # a torso
- penSize(1)
- penColor('black')
- brushColor(193, 204, 202)
- polygon([(x0+30, y0 +34),
- (x0+40, y0 +24),
- (x0+50, y0 +17),
- (x0+60, y0 +13),
- (x0+70, y0 +10),
- (x0+80, y0 +10),
- (x0+90, y0 +11),
- (x0+100, y0 +13),
- (x0+110, y0 +16),
- (x0+100, y0 +25),
- (x0+90, y0 +31),
- (x0+80, y0 +34),
- (x0+70, y0 +36),
- (x0+60, y0 +37),
- (x0+50, y0 +37),
- (x0+40, y0 +36),
- (x0+30, y0 +34)])
- # a tail
- polygon([(x0+10, y0 +59),
- (x0+0, y0 +39),
- (x0+10, y0 +39),
- (x0+20, y0 +38),
- (x0+30, y0 +34)])
- # a fins
- brushColor(222, 167, 167)
- polygon([(x0+60, y0 +13),
- (x0+55, y0 +10),
- (x0+50, y0 +7),
- (x0+40, y0 +4),
- (x0+80, y0 +0),
- (x0+83, y0 +5),
- (x0+80, y0 +10),
- (x0+70, y0 +10)])
- polygon([(x0+89, y0 +32),
- (x0+94, y0 +36),
- (x0+99, y0 +36),
- (x0+87, y0 +44),
- (x0+84, y0 +42),
- (x0+82, y0 +39),
- (x0+80, y0 +34)])
- polygon([(x0+50, y0 +37),
- (x0+49, y0 +40),
- (x0+46, y0 +45),
- (x0+42, y0 +47),
- (x0+59, y0 +47),
- (x0+61, y0 +43),
- (x0+59, y0 +37)])
- ## TODO глаза тоже привязать к x0,y0
- # an eye
- brushColor(121, 121, 243)
- circle(442, 526, 5)
- brushColor(127, 133, 141)
- circle(443, 527, 2)
- penColor(219, 219, 36)
- penSize(2)
- line(439, 525, 441, 527)
- fish(350, 506)
- fish(150, 506)
- fish(350, 206)
Advertisement
Add Comment
Please, Sign In to add comment