summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgordjscott <61287504+gordjscott@users.noreply.github.com>2020-02-20 17:55:28 +0000
committergordjscott <61287504+gordjscott@users.noreply.github.com>2020-02-20 17:55:28 +0000
commitfc733a37ca0a6619cd94da7822d5abe8788f03df (patch)
treecf242c83084a155c03b333f9a13911a77f00d1c7
parent07c55778b7339ad3af4881a3b16532984004f218 (diff)
Created Change the default Player and Rival names (markdown)
-rw-r--r--Change-the-default-Player-and-Rival-names.md121
1 files changed, 121 insertions, 0 deletions
diff --git a/Change-the-default-Player-and-Rival-names.md b/Change-the-default-Player-and-Rival-names.md
new file mode 100644
index 0000000..d4022ad
--- /dev/null
+++ b/Change-the-default-Player-and-Rival-names.md
@@ -0,0 +1,121 @@
+This tutorial describes how to change the default names for the Player and Rival.
+
+This is a very simple edit, and is really more about just finding the relevant code.
+
+## Contents
+
+1. [PLAYER: Changing the default name choices upon New Game][sec-1]
+2. [PLAYER: Changing the default option when no name is typed in][sec-2]
+3. [RIVAL: Changing the default option when no name is typed in][sec-3]
+
+## 1. PLAYER: Changing the default name choices upon New Game
+
+Simply edit the file [data/player_names.asm](../blob/master/data/player_names.asm).
+We'll use the forenames of the male and female _Ghostbusters_ as an example:
+
+```diff
+ ChrisNameMenuHeader:
+ db MENU_BACKUP_TILES ; flags
+ menu_coords 0, 0, 10, TEXTBOX_Y - 1
+ dw .MaleNames
+ db 1 ; ????
+ db 0 ; default option
+; ...
+
+ db "NEW NAME@"
+MalePlayerNameArray:
+- db "CHRIS@"
+- db "MAT@"
+- db "ALLAN@"
+- db "JON@"
++ db "PETER@"
++ db "RAY@"
++ db "EGON@"
++ db "WINSTON@"
+ db 2 ; displacement
+ db " NAME @" ; title
+
+; ...
+
+ db "NEW NAME@"
+FemalePlayerNameArray:
+- db "KRIS@"
+- db "AMANDA@"
+- db "JUANA@"
+- db "JODI@"
++ db "ERIN@"
++ db "ABBY@"
++ db "JILLIAN@"
++ db "PATTY@"
+ db 2 ; displacement
+ db " NAME @" ; title
+```
+
+## 2. PLAYER: Changing the default option when no name is typed in
+
+Currently, if you select the option to type in your own Player name but leave the option blank,
+the name defaults to **CHRIS** (Male) or **KRIS** (Female).
+
+This can be edited in [engine/menus/intro_menu.asm](../blob/master/engine/menus/intro_menu.asm):
+
+```diff
+; ...
+
+NamePlayer:
+ farcall MovePlayerPicRight
+ farcall ShowPlayerNamingChoices
+ ld a, [wMenuCursorY]
+ dec a
+
+; ...
+
+ jr z, .Male
+ ld de, .Kris
+.Male:
+ call InitName
+ ret
+
+.Chris:
+- db "CHRIS@@@@@@"
++ db "PETER@@@@@@"
+.Kris:
+- db "KRIS@@@@@@@"
++ db "ERIN@@@@@@@"
+
+; ...
+```
+
+
+## 3. RIVAL: Changing the default option when no name is typed in
+
+Similarly to the Player, the Rival is called **SILVER** if the naming screen is left blank.
+
+Let's name him after the _Ghostbusters_ villain **WALTER** as an example.
+Edit [engine/events/specials.asm](../blob/master/engine/events/specials.asm):
+
+```diff
+; ...
+
+NameRival:
+ ld b, NAME_RIVAL
+ ld de, wRivalName
+ farcall _NamingScreen
+- ; default to "SILVER"
++ ; default to "WALTER"
+ ld hl, wRivalName
+ ld de, .default
+ call InitName
+ ret
+
+.default
+- db "SILVER@"
++ db "WALTER@"
+
+; ...
+```
+
+That's all that is needed!
+
+[sec-1]: #1-player-changing-the-default-name-choices-upon-new-game
+[sec-2]: #2-player-changing-the-default-option-when-no-name-is-typed-in
+[sec-3]: #3-rival-changing-the-default-option-when-no-name-is-typed-in \ No newline at end of file