summaryrefslogtreecommitdiff
path: root/Remove-the-functionally-redundant-move-grammar-tables.md
diff options
context:
space:
mode:
authorJosh <32826900+ShinyDragonHunter@users.noreply.github.com>2020-10-31 01:04:56 +0000
committerJosh <32826900+ShinyDragonHunter@users.noreply.github.com>2020-10-31 01:04:56 +0000
commitb120b6f7888bb3e6633e32792f7bf76821282020 (patch)
tree94854122e93120ad826927cbd26429c8f6e82b35 /Remove-the-functionally-redundant-move-grammar-tables.md
parent295eed39ca455f00801d0316a905d63e0101262b (diff)
Created Remove the functionally redundant move grammar tables (markdown)
Diffstat (limited to 'Remove-the-functionally-redundant-move-grammar-tables.md')
-rw-r--r--Remove-the-functionally-redundant-move-grammar-tables.md26
1 files changed, 26 insertions, 0 deletions
diff --git a/Remove-the-functionally-redundant-move-grammar-tables.md b/Remove-the-functionally-redundant-move-grammar-tables.md
new file mode 100644
index 0000000..ecad6c7
--- /dev/null
+++ b/Remove-the-functionally-redundant-move-grammar-tables.md
@@ -0,0 +1,26 @@
+In the Japanese releases, there are five ways to say "POKéMON used MOVE!":
+
+* "POKéMONの MOVE つかった!" ("POKéMON used MOVE!")
+* "POKéMONの MOVEした!" ("POKéMON did MOVE!")
+* "POKéMONの MOVE した!" ("POKéMON did MOVE!" for long move names)
+* "POKéMONの MOVE こうげき!" ("POKéMON's MOVE attack!")
+* "POKéMONの MOVE!" ("POKéMON's MOVE!")
+
+
+These are all redundant in the English localization and all the strings have been translated to just “!”.
+This tutorial will show you how to remove them, which saves space and simplifies the code.
+
+Open [src/battle_message.c](https://github.com/pret/pokeemerald/blob/master/src/battle_message.c) and remove the following declarations:
+```c
+static void ChooseMoveUsedParticle
+static void ChooseTypeOfMoveUsedString
+```
+In the same file, look for the functions: `sGrammarMoveUsedTable`, `ChooseMoveUsedParticle` and `ChooseTypeOfMoveUsedString` and remove them completely.
+
+In the function `BufferStringBattle` in src/battle_message.c, remove `ChooseMoveUsedParticle(gBattleTextBuff1);` and `ChooseTypeOfMoveUsedString(gBattleTextBuff2);`
+
+And finally, change `sText_AttackerUsedX` and add an exclamation mark at the end of the string like so:
+```c
+static const u8 sText_AttackerUsedX[] = _("{B_ATK_NAME_WITH_PREFIX} \n{B_BUFF2}!”)
+```
+And that’s it! You have now removed the move grammar tables and functions and also made it easier on resources because now the game won’t go through multiple functions just to print a single exclamation mark present in 5 different text strings. \ No newline at end of file