-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSceneIntro.pde
72 lines (51 loc) · 1.43 KB
/
SceneIntro.pde
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
class SceneIntro extends Scene {
PImage illustration;
SceneIntro() {
super();
illustration = loadImage("img/png/start_illustration.png");
}
@Override
void draw() {
super.draw();
// STATIC ELEMENTS (these do not get pushed into the elements ArrayList)
String buffer;
// Heading Background
pushStyle();
fill(colPrimary);
rect(0, 184, 591, 171);
beginShape();
vertex(591, 184);
vertex(591, 355);
vertex(738, 133);
endShape(CLOSE);
popStyle();
// Heading Text
pushStyle();
fill(colBright);
textFont(fontHeading);
textAlign(LEFT, TOP);
textLeading(fontHeadingSize * defaultLineHeight);
buffer = "Was macht die \bBrennstoffzelle so \bumweltfreundlich, und wie genau funktioniert sie überhaupt?";
textExt(buffer, 32, 205, 543, fontHeadingBold);
popStyle();
// Footnote
pushStyle();
fill(colText);
textFont(fontBody);
textAlign(LEFT, TOP);
textLeading(fontBodySize * defaultLineHeight);
buffer = "\bFelix \bBastian\nInteraktive Werkzeuge\nProf. Ralph Tille\nWintersemester 2019/-20";
textExt(buffer, 32, 664, 320, fontBodyBold);
popStyle();
// Illustration
image(illustration, 409, 292, 612, 503);
// Navigation Hints
pushStyle();
fill(colText);
textFont(fontBodyBold);
textAlign(LEFT, TOP);
text("Zeig’s mir!", 743, 91);
text("Weiß ich!", 939, 91);
popStyle();
}
}