Skip to content

Commit 2446a0e

Browse files
committed
added updates from BrickEllis
1 parent bb03ad1 commit 2446a0e

File tree

5 files changed

+11
-10
lines changed

5 files changed

+11
-10
lines changed

src/main/java/org/teachingkidsprogramming/recipes/completed/section02methods/Houses.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ public static void main(String[] args)
1818
drawHouse(height);
1919
// DrawHouse with height 120 (recipe below) --#10
2020
drawHouse(120);
21+
Tortoise.setSpeed(10);
2122
// DrawHouse with height 90 (recipe below) --#12
2223
drawHouse(90);
2324
// DrawHouse with height 20 (recipe below) --#13

src/main/java/org/teachingkidsprogramming/recipes/completed/section04mastery/BackgroundPhoto.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ public class BackgroundPhoto
99
{
1010
public static void main(String[] args)
1111
{
12-
// Set the current picture to this url "http://img2.timeinc.net/ew/dynamic/imgs/101110/sonny-cher_240.jpg" --#1.0
13-
String picture = "http://img2.timeinc.net/ew/dynamic/imgs/101110/sonny-cher_240.jpg";
12+
// Set the current picture to this url "https://usatftw.files.wordpress.com/2017/05/spongebob.jpg?w=1000&h=600&crop=1" --#1.0
13+
String picture = "https://usatftw.files.wordpress.com/2017/05/spongebob.jpg?w=1000&h=600&crop=1";
1414
// Set the background image to the current picture--#1.1
1515
Tortoise.getBackgroundWindow().setBackgroundImage(picture);
1616
Tortoise.show();
@@ -19,8 +19,8 @@ public static void main(String[] args)
1919
// Do the following 75 times --#7.1
2020
for (int i = 0; i < 75; i++)
2121
{
22-
// Set the current pen color to crimson --#6.1
23-
Color penColor = PenColors.Reds.Crimson;
22+
// Set the current pen color to yellow --#6.1
23+
Color penColor = PenColors.Yellows.Yellow;
2424
// Use the current pen color for the line the tortoise draws --#6.2
2525
Tortoise.setPenColor(penColor);
2626
// Increase the length of a side by 1 pixel --#3.0

src/main/java/org/teachingkidsprogramming/recipes/completed/section04mastery/PentagonCrazy.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,10 @@ private static void adjustPen()
3838
Tortoise.setPenColor(ColorWheel.getNextColor());
3939
// Increase the tortoises pen width by 1 --#15
4040
Tortoise.setPenWidth(Tortoise.getPenWidth() + 1.0);
41-
// If the tortoises pen width is greater than 4, then --#17
41+
// If the tortoise's pen width is greater than 4, then --#17
4242
if (Tortoise.getPenWidth() > 4)
4343
{
44-
// Reset it to 1 --#16
44+
// Reset the pen width to 1 --#16
4545
Tortoise.setPenWidth(1);
4646
}
4747
}

src/main/java/org/teachingkidsprogramming/section04mastery/BackgroundPhoto.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ public class BackgroundPhoto
77
@SuppressWarnings("unused")
88
public static void main(String[] args)
99
{
10-
// Set the current picture to this url "http://img2.timeinc.net/ew/dynamic/imgs/101110/sonny-cher_240.jpg" --#1.0
10+
// Set the current picture to this url "https://usatftw.files.wordpress.com/2017/05/spongebob.jpg?w=1000&h=600&crop=1" --#1.0
1111
// Set the background image to the current picture--#1.1
1212
Tortoise.show();
1313
Tortoise.setSpeed(10);
1414
int side = 2;
1515
// Do the following 75 times --#7.1
16-
// Set the current pen color to crimson --#6.1
16+
// Set the current pen color to yellow --#6.1
1717
// Use the current pen color for the line the tortoise draws --#6.2
1818
// Increase the length of a side by 1 pixel --#3.0
1919
// Move the tortoise the length of the current side --#3.1

src/main/java/org/teachingkidsprogramming/section04mastery/PentagonCrazy.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ public static void main(String[] args)
2727
// ------------- Recipe for adjustPen --#9.2
2828
// Change the pen color of the line the tortoise draws to the next color on the color wheel --#6
2929
// Increase the tortoises pen width by 1 --#15
30-
// If the tortoises pen width is greater than 4, then --#17
31-
// Reset it to 1 --#16
30+
// If the tortoise's pen width is greater than 4, then --#17
31+
// Reset the pen width to 1 --#16
3232
// ------------- End of adjustPen recipe --#9.3
3333
//
3434
// The current length of a side is the same as the number of the side you are about to draw ( 1st side = 1 pixel, 2nd side = 2 pixels, etc) --#4.2

0 commit comments

Comments
 (0)