-
-
Notifications
You must be signed in to change notification settings - Fork 56
Adds title screen section to tutorial #137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
ed44d69
Adds title screen section to tutorial
wilkersonrdevon fc705b9
Merge pull request #1 from wilkersonrdevon/feature/title-screen
Les-Wet b492b80
Merge branch 'gbdev:master' into feature/title-screen
Les-Wet e2f0d99
Make title screen code buildable
Les-Wet aae5cc2
Change to Memcopy usage
Les-Wet e6b08b7
Added title screen text and assets
Les-Wet 27fe08e
Update src/part2/title-screen.md
avivace File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| # Title Screen | ||
|
|
||
| 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: | ||
|
|
||
|  | ||
|
|
||
| Then copy and paste the following after [waiting for VBlank](./getting-started.md): | ||
|
avivace marked this conversation as resolved.
Outdated
|
||
|
|
||
| ```rgbasm,linenos,start={{#line_no_of "" ../../unbricked/title-screen/main.asm:title_screen}} | ||
| {{#include ../../unbricked/title-screen/main.asm:title_screen}} | ||
| ``` | ||
| Note that we are using our `Memcopy` function from the [Functions](./functions.md) lesson! Isn't it handy to have reusable code? We are also using our `UpdateKeys` function from the [Input](./input.md) lesson to determine when to stop displaying the title screen and move on to the game itself. To do so, we loop until the start button has been pressed. | ||
|
|
||
| And just like that we have ourselves a title screen! | ||
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| #!/bin/sh | ||
|
|
||
| rgbasm -o main.o main.asm | ||
| rgbasm -o input.o input.asm | ||
| rgblink -o unbricked.gb main.o input.o | ||
| rgbfix -v -p 0xFF unbricked.gb |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this supposed to point to a specific point in Getting Started? We do introduce the VBlank waiting there but it's not "explicitly" explained yet (it's in fact said we will explain it later )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There wasn't a handy header to jump to but I was indeed referring to this section:
I can't actually find another point in the tutorial where this is discussed however. Should I leave the link as is, link to the pan docs, or remove the link altogether? Maybe we should file an issue to determine where we should discuss VBlank in more detail as the tutorial suggests we will?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say we remove the link for now and we open an issue about having a more complete introduction/explication of what VBlank is etc, maybe even in that Getting Started. Once that is done maybe when VBlank is mentioned we can link to that.