Tardis Tutorial Part 4

This week we wrap up our project. We will focus on the details of the Tardis. The format of this week’s tutorial will be similar to last week in that I will describe the code and then have the code for you to check yours with. After we work on the windows, I will give you the code for the extra details since describing them can get a little confusing.

We with the left side windows. In week 1, we made a variable’s for the window’s width and height. For the x-coordinate, we will use the lRow variable plus window width for the second column and 30 for the 3 column. The y-coordinate will use the row1 variable and then row1 plus the window height or the second row.

Does your code look like this:

drawWindow(lRowX, row1, windowW, windowH);
drawWindow(lRowX + windowW, row1, windowW, windowH);
drawWindow(lRowX + 30, row1, windowW, windowH);
drawWindow(lRowX, row1 + windowH, windowW, windowH);
drawWindow(lRowX + windowW, row1 + windowH, windowW, windowH);
drawWindow(lRowX + 30, row1 + windowH, windowW, windowH);

For the right windows we will the same variables for the width and height. The x-coordinates are the same except they use the rRow instead of the lRow variable. The y-coordinates are the exact same for this set of windows.

Does your code like this:

drawWindow(rRowX, row1, windowW, windowH);
drawWindow(rRowX + windowW, row1, windowW, windowH);
drawWindow(rRowX + 30, row1, windowW, windowH);
drawWindow(rRowX, row1 + windowH, windowW, windowH);
drawWindow(rRowX + windowW, row1 + windowH, windowW, windowH);
drawWindow(rRowX + 30, row1 + windowH, windowW, windowH);

To describe the rest of the details would take a very long time and it would be easier for me to show you since details can get tricky. You can add as much or how little you want.

For the top letters use this code:

fill(255, 255, 255);
textSize(13);
text(“POLICE”, 150, 103);
text(“BOX”, 246, 103);
textSize(6.5);
text(“PUBLIC”,205,98);
text(“Call”, 212, 104);

For the information box on the left door use this code:

drawWindow(lRowX + 5, row2 + 5, panelW -10, panelH – 10);
fill(0,0,0);
textSize(3);
text(“POLICE TELEPOHONE”, lRowX + 7, row2 + 10);
text(“FREE”, lRowX + 18, row2 + 14);
textSize(2.5);
text(“FOR USE OF”, lRowX + 13, row2 + 17);
textSize(3);
text(“PUBLIC”, lRowX + 17, row2 + 20);
textSize(2);
text(“ADVICE & ASSISTANCE”, lRowX + 12, row2 + 25);
text(“OBTAINABLE IMMEDIATELY”, lRowX + 9, row2 + 28);
text(“OFFICERS & CARS”, lRowX + 13, row2 + 32);
text(“RESPOND TO ALL CALLS”, lRowX + 11, row2 + 35);
textSize(3);
text(“PULL TO OPEN”, lRowX + 11, row2 + 39);

For the circle on the right door use this code:

noStroke();
fill(171, 166, 171);
ellipse(rRowX + panelW/2, row2 + panelH/2, 15,15);
fill(26, 25, 26);
ellipse(rRowX + panelW/2, row2 + panelH/2, 10,10);
fill(171,166,171);
ellipse(rRowX + panelW/2, row2 + panelH/2, 5,5);

Leave a Reply

Your email address will not be published. Required fields are marked *