Skeetendo

’Cause all games were better on the GBC

You are not logged in.

#1 2019-08-07 21:51:31

Anonymous
Member
Registered: 2019-02-23
Post 16/24

Pokemon Red/Blue Adding New Moves

I have just finished my ROM hack of Pokemon Red called Pokemon INSANE Red Version. I want to add new moves in my next release.

For example adding the move Icicle Spear by making it have the Fury Attack battle animation.

Another example is the move Flame Wheel which could use the Fire Spin battle animation.

I have played a very awesome hack of Pokemon Red called Pokemon Brown and I have noticed that the author added new moves by replacing unused glitched moves.

I want to know how to add new moves with Gold Finger and how to find out what exact byte contains that new move.

For example the exact byte that contains the move Sludge is byte 7C.

I have tried adding a new move via pokered disassembly but I keep getting an error when I run the make command.

Last edited by Anonymous (2019-08-08 16:17:55)

Offline

#2 2019-08-13 03:40:14

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,139/1,143

Re: Pokemon Red/Blue Adding New Moves

Adding entirely new moves via hex editing would be extremely tedious and error-prone.

Once you spend some time to get comfortable with the disassembly and get comfortable with how to approach "make" errors, then the disassembly becomes a much much more effective way to make a rom hack.

You can post your make error here and we can work through it.

Offline

#3 2019-08-14 20:06:44

Anonymous
Member
Registered: 2019-02-23
Post 17/24

Re: Pokemon Red/Blue Adding New Moves

Danny-E 33 wrote:

Adding entirely new moves via hex editing would be extremely tedious and error-prone.

Once you spend some time to get comfortable with the disassembly and get comfortable with how to approach "make" errors, then the disassembly becomes a much much more effective way to make a rom hack.

You can post your make error here and we can work through it.

For example I want to add the move Octazooka this is the error I keep getting.

By the way I am using Cygwin to make the pokered rom.

This is the error I get when I run the make command.

rgblink -d -n pokered.sym -l pokered.link -o pokered.gbc audio_red.o main_red.o text_red.o wram_red.o
error: Unknown symbol 'OCTAZOOKA'
make: *** [Makefile:68: pokered.gbc] Error 1

Last edited by Anonymous (2019-08-14 20:08:26)

Offline

#4 2019-08-17 18:16:13

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,140/1,143

Re: Pokemon Red/Blue Adding New Moves

In that case, it looks like you still need to add "OCTAZOOKA" to constants/move_constants.asm

Offline

#5 2019-08-18 01:08:10

Anonymous
Member
Registered: 2019-02-23
Post 20/24

Re: Pokemon Red/Blue Adding New Moves

Danny-E 33 wrote:

In that case, it looks like you still need to add "OCTAZOOKA" to constants/move_constants.asm

UPDATE: There is one thing that did work out fine I did not get an error compiling the rom.

There is one other modification I did to determine if the move Octazooka existed where I edited the evos_moves.asm file.

I edited Squirtles learned moves by making it learn Octazooka at level 8 instead of the move Bubble which it learns in the original games.

This is the change I made to the file.

SquirtleEvosMoves:
; Evolutions
db EV_LEVEL, 16, WARTORTLE
db 0
; Learnset
db 8, OCTAZOOKA
db 15, WATER_GUN
db 22, BITE
db 28, WITHDRAW
db 35, SKULL_BASH
db 42, HYDRO_PUMP
db 0

I opened the pokered.gbc rom in VisualBoyAdvance emulator and leveled up Squirtle to level 8.

I was hoping it would learn the move Octazooka but it learns the move Struggle instead.

Can you please tell me what caused that to happen.

Offline

#6 2019-08-18 02:22:14

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,141/1,143

Re: Pokemon Red/Blue Adding New Moves

Did you add the name string for "OCTAZOOKA" in text/move_names.asm? Keep in mind the order in this file must match the order in constants/move_constants.asm

Offline

#7 2019-08-18 15:29:14

Anonymous
Member
Registered: 2019-02-23
Post 21/24

Re: Pokemon Red/Blue Adding New Moves

Danny-E 33 wrote:

Did you add the name string for "OCTAZOOKA" in text/move_names.asm? Keep in mind the order in this file must match the order in constants/move_constants.asm

Ok so this is what I did with the two files

I wont show you the whole asm file because it would become a big thread

This is what I did in move_constants.asm

const FURY_SWIPES  ; 9a
const BONEMERANG   ; 9b
const REST         ; 9c
const ROCK_SLIDE   ; 9d
const HYPER_FANG   ; 9e
const SHARPEN      ; 9f
const CONVERSION   ; a0
const TRI_ATTACK   ; a1
const SUPER_FANG   ; a2
const SLASH        ; a3
const SUBSTITUTE   ; a4
const OCTAZOOKA    ; a5


This is what I did in move_names.asm

db "ACID ARMOR@"
db "CRABHAMMER@"
db "EXPLOSION@"
db "FURY SWIPES@"
db "BONEMERANG@"
db "REST@"
db "ROCK SLIDE@"
db "HYPER FANG@"
db "SHARPEN@"
db "CONVERSION@"
db "TRI ATTACK@"
db "SUPER FANG@"
db "SLASH@"
db "SUBSTITUTE@"
db "STRUGGLE@"
db "OCTAZOOKA@"

I put Octazooka after the move Struggle

I leveled Squirtle up to level 8 and it learned Struggle.

I put Octazooka after Struggle in moves.asm

I made it have the Sludge battle animation.

move SUPER_FANG,   SUPER_FANG_EFFECT,            1, NORMAL,    90, 10
move SLASH,        NO_ADDITIONAL_EFFECT,        70, NORMAL,   100, 20
move SUBSTITUTE,   SUBSTITUTE_EFFECT,            0, NORMAL,   100, 10
move STRUGGLE,     RECOIL_EFFECT,               50, NORMAL,   100, 10
move OCTAZOOKA,    POISON_SIDE_EFFECT2,         65, WATER,    100, 20

Offline

#8 2019-08-18 19:00:56

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,142/1,143

Re: Pokemon Red/Blue Adding New Moves

As I mentioned, the order in text/move_names.asm must match the order in constants/move_constants.asm

Look at what you have:

const SLASH        ; a3
const SUBSTITUTE   ; a4
const OCTAZOOKA    ; a5
db "SLASH@"
db "SUBSTITUTE@"
db "STRUGGLE@"
db "OCTAZOOKA@"

You need to update text/move_names.asm to this:

db "SLASH@"
db "SUBSTITUTE@"
db "OCTAZOOKA@"
db "STRUGGLE@"

You should also update data/moves.asm to this:

move SUPER_FANG,   SUPER_FANG_EFFECT,            1, NORMAL,    90, 10
move SLASH,        NO_ADDITIONAL_EFFECT,        70, NORMAL,   100, 20
move SUBSTITUTE,   SUBSTITUTE_EFFECT,            0, NORMAL,   100, 10
move OCTAZOOKA,    POISON_SIDE_EFFECT2,         65, WATER,    100, 20
move STRUGGLE,     RECOIL_EFFECT,               50, NORMAL,   100, 10

You put OCTAZOOKA after SUBSTITUTE in the constants list, so it needs to come after SUBSTITUTE in all other lists.
It's probably best that STRUGGLE stays at the end of the list because it's a bit of a special case.

Offline

#9 2019-08-19 19:29:54

Anonymous
Member
Registered: 2019-02-23
Post 22/24

Re: Pokemon Red/Blue Adding New Moves

There is one thing that did turn out fine

Squirtle learned Octazooka in level 8

When I used Octazooka on a wild Pokemon it uses the Struggle battle animation instead of the Sludge battle animation

Another bug that happened is when the battle animation where the trainers Pokemon comes out gets changed to the battle animation where the trainer is blocking the Pokeball

If you want a visual explanation then you can watch the video to see what the bug looks like: https://www.youtube.com/watch?v=yU4Kmehgpes

Can you please tell me how to change battle animations using the disassembly and how to fix the bug.

Last edited by Anonymous (2019-08-19 19:45:25)

Offline

#10 2019-08-19 21:48:49

Rangi
Member
Registered: 2016-05-09
Post 900/902

Re: Pokemon Red/Blue Adding New Moves

Update data/animations.asm the same way you updated data/moves.asm. No need to write your own animation, you can reuse an existing one.


Pokémon Polished Crystal (src): v2.2.0
Pokémon Red★/Blue★: Space World Edition (src): 2018-08-19
Polished Map (src): pokecrystal/pokered map, tileset and palette editor: v4.3.1

Offline

#11 2019-08-20 02:47:34

Anonymous
Member
Registered: 2019-02-23
Post 23/24

Re: Pokemon Red/Blue Adding New Moves

Danny-E 33 wrote:

Adding entirely new moves via hex editing would be extremely tedious and error-prone.

Once you spend some time to get comfortable with the disassembly and get comfortable with how to approach "make" errors, then the disassembly becomes a much much more effective way to make a rom hack.

You can post your make error here and we can work through it.


Rangi wrote:

Update data/animations.asm the same way you updated data/moves.asm. No need to write your own animation, you can reuse an existing one.

Thank you so much for helping me with adding new moves via disassembly. The current version of my hack of Pokemon Red is Beta 0.3. Note I only use the pokered disassembly to guide me with ROM hacking. I do not use it to make a ROM hack. All the changes I made in my hack of Pokemon Red such as editing Pokemon movesets, Pokemon front sprites, Player front and back sprites, editing NPC text etc was all done through a hex editor. The hex editor I use which has good ROM hacking features is Gold Finger. This hex editor gives you the option of opening a .tbl file which makes it easy to decode the whole ROM. I always make back-up copies of my ROM just in case some kind of error happens.

Offline

#12 2019-08-20 11:52:09

Rangi
Member
Registered: 2016-05-09
Post 901/902

Re: Pokemon Red/Blue Adding New Moves

Anonymous wrote:

Thank you so much for helping me with adding new moves via disassembly. The current version of my hack of Pokemon Red is Beta 0.3. Note I only use the pokered disassembly to guide me with ROM hacking. I do not use it to make a ROM hack. All the changes I made in my hack of Pokemon Red such as editing Pokemon movesets, Pokemon front sprites, Player front and back sprites, editing NPC text etc was all done through a hex editor. The hex editor I use which has good ROM hacking features is Gold Finger. This hex editor gives you the option of opening a .tbl file which makes it easy to decode the whole ROM. I always make back-up copies of my ROM just in case some kind of error happens.

You've probably heard it before, but: just use the disassembly directly. However long it takes to port the changes you've already made, I'll bet it takes longer to deal with binary hacking limitations.

Anyway: you can't just add an extra dw pointer to the AttackAnimationPointers list, because unlike disassembly, it wouldn't automatically shift everything down; the final pointer in the list, "dw ZigZagScreenAnim", would end up overwriting "ZigZagScreenAnim" right below it. Luckily, there's one unused animation, "UnusedAnim". So: Copy the bytes of ZigZagScreenAnim to the first bytes of UnusedAnim; change "dw ZigZagScreenAnim" to "dw UnusedAnim"; insert the two bytes of "dw BubbleBeamAnim" right above "dw StruggleAnim"; and delete the first two bytes of the original ZigZagScreenAnim ("db SE_WAVY_SCREEN, $FF").

You'll end up with the new AttackAnimationPointers list, a stray "db $FF" left over from ZigZagScreenAnim, and then all of the animations, with the first three bytes of UnusedAnim replaced by ZigZagScreenAnim's "db SE_WAVY_SCREEN, $FF, $FF".


Pokémon Polished Crystal (src): v2.2.0
Pokémon Red★/Blue★: Space World Edition (src): 2018-08-19
Polished Map (src): pokecrystal/pokered map, tileset and palette editor: v4.3.1

Offline

#13 2019-08-20 17:40:49

Anonymous
Member
Registered: 2019-02-23
Post 24/24

Re: Pokemon Red/Blue Adding New Moves

Rangi wrote:

You've probably heard it before, but: just use the disassembly directly. However long it takes to port the changes you've already made, I'll bet it takes longer to deal with binary hacking limitations.

Anyway: you can't just add an extra dw pointer to the AttackAnimationPointers list, because unlike disassembly, it wouldn't automatically shift everything down; the final pointer in the list, "dw ZigZagScreenAnim", would end up overwriting "ZigZagScreenAnim" right below it. Luckily, there's one unused animation, "UnusedAnim". So: Copy the bytes of ZigZagScreenAnim to the first bytes of UnusedAnim; change "dw ZigZagScreenAnim" to "dw UnusedAnim"; insert the two bytes of "dw BubbleBeamAnim" right above "dw StruggleAnim"; and delete the first two bytes of the original ZigZagScreenAnim ("db SE_WAVY_SCREEN, $FF").

You'll end up with the new AttackAnimationPointers list, a stray "db $FF" left over from ZigZagScreenAnim, and then all of the animations, with the first three bytes of UnusedAnim replaced by ZigZagScreenAnim's "db SE_WAVY_SCREEN, $FF, $FF".

I'm really sorry if what I said was wrong. Maybe you were right after all.

I tried to add another move via disassembly

This is what I did in moves.asm

move TRI_ATTACK,   NO_ADDITIONAL_EFFECT,        80, NORMAL,   100, 10
move SUPER_FANG,   SUPER_FANG_EFFECT,            1, NORMAL,    90, 10
move SLASH,        NO_ADDITIONAL_EFFECT,        70, NORMAL,   100, 20
move SUBSTITUTE,   SUBSTITUTE_EFFECT,            0, NORMAL,   100, 10
move OCTAZOOKA,    POISON_SIDE_EFFECT2,         65, WATER,    100, 20
move SHADOW_BALL,  SPECIAL_DOWN_SIDE_EFFECT,    90, GHOST,    100, 15
move STRUGGLE,     RECOIL_EFFECT,               50, NORMAL,   100, 10

I added Shadow Ball in move_names.asm

db "TRI ATTACK@"
db "SUPER FANG@"
db "SLASH@"
db "SUBSTITUTE@"
db "OCTAZOOKA@"
db "SHADOW BALL@"
db "STRUGGLE@"

I made it have the existing Confuse Ray battle animation in animation.asm

SuperFangAnim:
db SE_DARK_SCREEN_PALETTE, $48
db $46,$A1,$04
db SE_RESET_SCREEN_PALETTE, $FF
db $FF

SlashAnim:
db $06,$A2,$0F
db $FF

SubstituteAnim:
db SE_SLIDE_MON_OFF, $A3
db $08,$FF,$47
db SE_SUBSTITUTE_MON, $FF
db $FF

OctazookaAnim:
db $46,$7B,$13
db $46,$7B,$14
db $FF

ShadowBallAnim:
db SE_DARK_SCREEN_PALETTE, $6C
db $46,$FF,$3E
db SE_RESET_SCREEN_PALETTE, $FF
db $FF


I added Shadow Ball after Octazooka in move_constants.asm

const TRI_ATTACK   ; a1
const SUPER_FANG   ; a2
const SLASH        ; a3
const SUBSTITUTE   ; a4
const OCTAZOOKA    ; a5
const SHADOW_BALL  ; a6

I did all the steps but now Shadow Ball now uses the Struggle battle animation

Offline

#14 2019-08-20 23:26:21

Danny-E 33
Administrator
Registered: 2012-06-09
Post 1,143/1,143

Re: Pokemon Red/Blue Adding New Moves

Did you update the table of animation pointers at the top of data/animations.asm too? Like:

AttackAnimationPointers:
    [...]
    [...]
    [...]
    dw SubstituteAnim
    dw OctazookaAnim
    dw ShadowBallAnim
    dw StruggleAnim

Offline

Board footer

Powered by FluxBB