Skip to content

Commit 13ce665

Browse files
committed
add 'pixelated' class to sprites/in-rom screenshots (fix #142)
1 parent 8da51f3 commit 13ce665

File tree

5 files changed

+49
-11
lines changed

5 files changed

+49
-11
lines changed

src/part1/palettes.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,11 @@ I put air quotes because "black" isn't true black, and "white" isn't true white.
2626
Further, note that the original Game Boy had shades of green, but the later Game Boy Pocket's screen produced shades of gray instead.
2727
And, even better, the Game Boy Color will automatically colorize games that lack Game Boy Color support!
2828

29-
![Screenshot of our Hello World, automatically colorized by the Game Boy Color](../assets/img/hello_world_autocolor.png)
29+
<img
30+
class="pixelated"
31+
src="../assets/img/hello_world_autocolor.png"
32+
alt="Screenshot of our Hello World, automatically colorized by the Game Boy Color"
33+
/>
3034

3135
All this to say, one shouldn't expect specific colors out of a Game Boy game[^console_detection], just four more or less bright colors.
3236

@@ -86,8 +90,12 @@ We would get thus:
8690
(I'm not giving the value in hexadecimal, use this as an opportunity to exercise your bin-to-hex conversions!)
8791

8892
<figure>
89-
<img src="../assets/img/hello_world_inv.png" alt="Screenshot of the color-inverted Hello World">
90-
<figcaption>If you got it right, it should look like this!</figcaption>
93+
<img
94+
class="pixelated"
95+
src="../assets/img/hello_world_inv.png"
96+
alt="Screenshot of the color-inverted Hello World"
97+
>
98+
<figcaption>If you got it right, it should look like this!</figcaption>
9199
</figure>
92100
93101
If you go to the Tile Viewer and change "Palette" to "Gray", you will notice that the tile data stays the same regardless of how the palette is modified!

src/part1/tilemap.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,11 @@ We will explain this in more detail in Part Ⅱ.
4747
Here we will be able to see the power of tile reuse in full force.
4848
As a convenience and a refresher, here are the tiles our Hello World loads into VRAM:
4949

50-
![Enlarged view of the tiles loaded in VRAM](../assets/img/hello_world_tiles.png)
50+
<img
51+
class="pixelated"
52+
src="../assets/img/hello_world_tiles.png"
53+
alt="Enlarged view of the tiles loaded in VRAM"
54+
/>
5155

5256
You can see that we only loaded a single "blank" tile ($00, the first aka. top-left one), but it can be repeated to cover the whole background at no extra cost!
5357

src/part2/bcd.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ Of course, we still need to call it on impact. To do this, we add a call to `Inc
6464

6565
Before we can display the score we'll need to add some graphics for the numbers 0-9. We already have some ready-made digits for this project, so you can copy [this premade file](https://github.com/gbdev/gb-asm-tutorial/raw/master/unbricked/bcd/digit-tileset.asm), and paste it at the end of your tile set, just before the `TilesEnd` label. Your tile set will look like this:
6666

67-
![Screenshot of tile set with digits added at the end](../assets/part2/img/bcd-tileset.png)
67+
<img src="../assets/part2/img/bcd-tileset.png" alt="Screenshot of tile set with digits added at the end" class="pixelated">
6868

6969
So we can easily remember where the digits start, let's add a constant called `DIGIT_OFFSET` to point us to where the digits are relative to the start of the tile set: `$1A`
7070

src/part2/getting-started.md

Lines changed: 27 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,12 @@ Combining these constants must be done using `|`, the *binary "or"* operator; we
9090
There's one last thing we need before we can build the ROM, and that's the graphics.
9191
We will draw the following screen:
9292

93-
![Layout of unbricked](../assets/part2/img/tilemap.png)
93+
<img
94+
class="pixelated"
95+
src="../assets/part2/img/tilemap.png"
96+
alt="Layout of unbricked"
97+
width="300px"
98+
/>
9499

95100
In `hello-world.asm`, tile data had been written out by hand in hexadecimal; this was to let you see how the sausage is made at the lowest level, but *boy* is it impractical to write!
96101
This time, we will employ a more friendly way, which will let us write each row of pixels more easily.
@@ -125,7 +130,12 @@ $ rgbfix -v -p 0xFF unbricked.gb
125130

126131
If you run this in your emulator, you should see the following:
127132

128-
![Screenshot of our game](../assets/part2/img/screenshot.png)
133+
<img
134+
class="pixelated"
135+
src="../assets/part2/img/screenshot.png"
136+
alt="Screenshot of our game"
137+
width="300px"
138+
/>
129139

130140
That white square seems to be missing!
131141
You may have noticed this comment earlier, somewhere in the tile data:
@@ -139,19 +149,31 @@ You can use one of the following pre-made logos, or try coming up with your own!
139149

140150
- **RGBDS Logo**
141151

142-
![The RGBDS Logo](../assets/part2/img/rgbds.png)
152+
<img
153+
class="pixelated"
154+
src="../assets/part2/img/rgbds.png"
155+
alt="The RGBDS Logo"
156+
/>
143157

144158
[Source](https://github.com/gbdev/gb-asm-tutorial/raw/master/unbricked/getting-started/rgbds.asm)
145159

146160
- **Duck**
147161

148-
![A pixel-art duck](../assets/part2/img/duck.png)
162+
<img
163+
class="pixelated"
164+
src="../assets/part2/img/duck.png"
165+
alt="A pixel-art duck"
166+
/>
149167

150168
[Source](https://github.com/gbdev/gb-asm-tutorial/raw/master/unbricked/getting-started/duck.asm)
151169

152170
- **Tail**
153171

154-
![A silhouette of a tail](../assets/part2/img/tail.png)
172+
<img
173+
class="pixelated"
174+
src="../assets/part2/img/tail.png"
175+
alt="A silhouette of a tail"
176+
/>
155177

156178
[Source](https://github.com/gbdev/gb-asm-tutorial/raw/master/unbricked/getting-started/tail.asm)
157179

src/part2/title-screen.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22

33
Let's make our game more official and give it a title screen! First, copy the tileset and tilemap found [here](https://github.com/gbdev/gb-asm-tutorial/raw/master/unbricked/title-screen/tilemap-titlescreen.asm) and paste it at the end of your code. This will make a title screen that looks like so:
44

5-
![Title Screen](../assets/part2/img/title-screen.png)
5+
<img
6+
class="pixelated"
7+
src="../assets/part2/img/title-screen.png"
8+
alt="Title Screen"
9+
/>
610

711
Then copy and paste the following after waiting for VBlank:
812

0 commit comments

Comments
 (0)