Created
September 29, 2016 04:58
-
-
Save CallumHoward/79081b770a5abee152db7e6cca99b342 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void setup() { | |
size(800, 600); | |
smooth(); | |
} | |
void draw() { | |
drawFish(50, 50); | |
} | |
void drawFish(int x, int y) { | |
// draw a fish! | |
noStroke(); | |
fill(#e09a25); // fish colour | |
// x1, y1, x2, y2, x3, y3 | |
triangle(x + 100, y + 100, x + 200, y + 50, x + 200, y + 150); | |
// center x, center y, width, height | |
ellipse(x + 100, y + 100, 120, 100); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment