PDA

View Full Version : Creating New Battle Animations


Chaos Rush
June 2nd, 2012, 12:43 PM
So I've managed to figure out enough to make decent custom battle animations. So far, I've managed to splice multiple animations together, and to add backgrounds to an animation action.


From what I've figured out so far, there are at least two types of actions:
1) a background
2) a movement of a graphic (requires loading correct graphics)

Note: Everything in this document/tutorial is designed with FireRed in mind. There are pointers within the animation scripts, meaning that unfortunately, these have to be ROM-specific. These will work with FireRed, and only FireRed.

Here's what I've got of the scripting language so far: (credits at bottom of post for people who found these)
------------------------------------------------------------------
00 XX 27 = loads image data, XX is an argument
00 XX 28 = same thing as above, but loads from a different bank of graphics

02 = executes current animation segment
05 = waits for current animation segment to finish
06 = does absolutely nothing
07 = does absolutely nothing
08 = ends the animation script (DO NOT CONFUSE WITH POINTER!!!)

0E XX XX XX 08 = jumps to another animation, continues execution of original script when finished (can be used to combine multiple animations to play right after another)
11 XX XX XX 08 = same as above, haven't figured out the difference yet

19 XX XX = plays a sound

Display a non-scrolling, static background: (note: if you change 17 to 16, then transparency effects will be deactivated)
14 WW 17

Display a scrolling background: (note: if you change 17 to 16, then transparency effects will be deactivated)
14 WW 17 03 2D B8 0B 08 05 04 00 XX 00 YY ZZ 00 FF FF
-WW = selects which background graphics to display

Choose one of these for the WW byte:
00 = Dark-type BG, example: Faint Attack
01 = same as 00
02 = Ghost-type BG, can scroll horizontally, example: Shadow Punch
03 = Psychic-type BG, example: Psychic (EXCEPT IT DOESN'T ANIMATE)
04 = high-impact BG, light coming from top right, example: Focus Punch
05 = high-impact BG, light coming from bottom left
06 = high-impact BG, light coming from top left
07 = Horn Drill BG, can scroll horizontally and vertically, example: Horn Drill
08 = same as 07, but image is mirrored horizontally
09 = high-speed BG, can scroll horizontally, example: Mach Punch
0A = same as 09, but image is mirrored horizontally
0B = Thunder BG, can scroll horizontally, example: Thunder
0C = Guillotine BG, light coming from top right, example: Guillotine
0D = Guillotine BG, light coming from bottom left
0E = Guillotine BG, light coming from top left
0F = Ice-type BG, can scroll horizontally, example: Sheer Cold
10 = Space-oriented BG, can scroll horizontally and vertically, example: Cosmic Power
11 = Seismic Toss/Sky Uppercut BG, can scroll horizontally and vertically, example: Sky Uppercut
12 = Flying-type BG, can scroll horizontally and vertically, example: Sky Attack
13 = same as 12, but image is mirrored horizontally
14 = Aurora Beam BG, can scroll horizontally, example: Aurora Beam
15 = Fissure BG, can scroll horizontally (but it artistically makes no sense to do so), example: Fissure
16 = Silver Wind BG, can scroll horizontally, example: Silver Wind
17 = same as 16, but image is mirrored horizontally
18 = SolarBeam BG, light coming from top right, example: SolarBeam
19 = SolarBeam BG, light coming from bottom left
1A = SolarBeam BG, light coming from top left
-XX = how fast background scrolls horizontally
-YY = how fast background scrolls vertically
-ZZ = not sure but its either 00 or 01

Here is what each background looks like:
00:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/83736fc5.png

01:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/1-1.png

02:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/2-1.png

03:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/3-1.png

04:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/4.png

05:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/5.png

06:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/6.png

07:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/7.png

08:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/8.png

09:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/9.png

0A:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/10.png

0B:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/11.png

0C:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/12.png

0D:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/13.png

0E:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/14.png

0F:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/15.png

10:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/16.png

11:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/17.png

12:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/18.png

13:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/19.png

14:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/20.png

15:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/21.png

16:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/22.png

17:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/23.png

18:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/24.png

19:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/25.png

1A:
http://i1151.photobucket.com/albums/o625/ChaosRush/New%20Attacks/26.png

Judging by unLZ, these backgrounds are simply tilesets+tilemaps. If we could find the table(s), we could theoretically expand them and have custom backgrounds.

To display the Psychic-background correctly, do not use the scrolling background command, instead use the 0E command, using it like this:
0E BB 59 1D 08
This will display the Psychic-type BG, while also animating it correctly.

To end any scrolling background (also works with the Psychic-BG animation):
0E C7 59 1D 08 Usually this is placed at the end of the script. If you're going to place it at the end of the script, make sure you add an extra 08 byte to the end of it, otherwise the game will freeze.

The table for the battle backgrounds starts at 0x3ADE18, and ends at 0x3ADF5B. The format goes like:
[XX XX XX 08] [YY YY YY 08] [ZZ ZZ ZZ 08] XX = pointer to graphics, YY = pointer to palette, ZZ = pointer to tilemap
Repoint and extend it, and you can create custom backgrounds:
http://i47.tinypic.com/2zy8qwi.png

Some other info (remember, these are FireRed offsets):
0x247094 = Attack names
0x250C04 = Attack data
0x4886E8 = Attack description pointers
0x1D65A8 = Battle script pointers
0x1C68F4 = Attack Animation pointers

To find the offset of an animation, follow these instructions:
1. Open up this link: http://bulbapedia.bulbagarden.net/wiki/List_of_moves
2. Find the move you want (for the sake of this example, we'll be using Surf)
3. According to the list, Surf is #57 in the game index
4. Open up Windows Calculator, switch to Programmer mode
5. (make sure the option on the left tab is set to, "Dec") type in 57 (or whatever number your attack is)
6. Click on "Hex"
7. Multiply it by 4
8. Add it by 1C68F4
9. Whatever the sum is, that offset contains the pointer to your animation. Open up a Hex editor, and go to that offset
10. The sum I got was 1C69D8. The bytes there are 01 FA 1C 08. The 08 indicates its a pointer.
11. If you know how to calculate pointers manually, good for you. If you don't, go find a Pointer Calculator on Google or something, or figure out how. With that said, the bytes 01 FA 1C 08 means its pointing to offset 0x1CFA01.
12. 0x1CFA01 is the Surf animation. Congratulations, you found the offset of your animation!

(To figure out when the animation starts and ends, simply make a new attack (assuming you've already looked at Jambo51's thread on adding new moves), and expand the attack animation table, and then paste the data of the Surf animation (or whatever attack) into free space and point one of the new attacks to that data. Then open up VBA, open up its Memory Viewer, and go to that data. Then replace the bytes and the end with FF, and keep testing it until the animation crashes (it should only crash when you change an 08 byte) Once it crashes, open up your hex editor, and go to the offset of the data, then make it look like how it does in VBA's memory viewer, then add an 08 at the end with the hex editor.
Eventually I will post a list of all the animation offsets, I haven't finished typing them all out yet.

Step-by-step example at creating a custom animation:
Example 1: Adding a background to an existing animation

So let's say we wanted to create a 4th Gen move. How about... Night Slash. We'll use Slash with the Dark-type background.

1. Using the steps I showed earlier in this thread, find the offset of whatever animation you want to base it by. The Slash animation is at 0x1caf7b. Insert the Slash animation data into free space, and then go to Night Slash's (or whatever your move is called) slot in the animation table and point to the animation data you just inserted.

2. For anyone else using it off of Slash's animation, this is the hex data for the Slash animation:
00 C7 27 02 A4 35 3E 08 82 03 01 00 F8 FF 00 00 19 81 00 3F 04 04 02 A4 35 3E 08 82 03 01 00 08 00 00 00 03 1D 8B 09 08 02 05 01 00 04 00 00 00 12 00 01 00 19 81 00 3F 05 08Right now, our animation looks exactly like Slash:
http://i46.tinypic.com/2s6o5mc.png

3. Now earlier in this thread, I mentioned the scrolling background animation command. Use it, and set WW as the Dark-BG. Place it at the beginning of the animation, and the Slash animation right afterwords. Our animation data should now look like this:
14 00 16 03 2D B8 0B 08 05 04 00 00 00 00 00 00 FF FF 00 C7 27 02 A4 35 3E 08 82 03 01 00 F8 FF 00 00 19 81 00 3F 04 04 02 A4 35 3E 08 82 03 01 00 08 00 00 00 03 1D 8B 09 08 02 05 01 00 04 00 00 00 12 00 01 00 19 81 00 3F 05 08
http://i45.tinypic.com/ixqqmw.png
Now we got the Dark-background! ...except that it doesn't disappear after the attack is done. That's because we need to add the BG-clear command.

4. As I mentioned earlier, the BG clear command is: 0E C7 59 1D 08. Remove the 08 byte from our current animation (NOT THE BG COMMAND!!!), then add the BG clear command at the end, and add an extra 08 byte to end the animation, otherwise the game will crash. Our script should now look like this:
14 00 16 03 2D B8 0B 08 05 04 00 00 00 00 00 00 FF FF 00 C7 27 02 A4 35 3E 08 82 03 01 00 F8 FF 00 00 19 81 00 3F 04 04 02 A4 35 3E 08 82 03 01 00 08 00 00 00 03 1D 8B 09 08 02 05 01 00 04 00 00 00 12 00 01 00 19 81 00 3F 05 0E C7 59 1D 08 08
http://i50.tinypic.com/33e6h79.png
Now we have a flawless Night Slash animation! And yes, the background will return to normal after execution of the attack.

Just for giggles, you can alter the second byte of the BG command (which also happens to be the second byte of our entire Night Slash animation) to change the background (I referred to it as the WW byte):
http://i50.tinypic.com/2rlycjq.png
(lol Aurora Slash)

http://i48.tinypic.com/1j7ply.png
(lol Twinkle Slash)

And that, is essentially how you take a non-BG animation and add a BG to it.


Example 2: Merging two animations to play right after another
Just find two separate animation hex data, and then remove the 08 byte from the end of one of them (except if its a pointer), then place the data of the second animation right after it. Alternatively, you can use the 0E or 11 command and point directly to it, but this will limit you to merging only 2 animations. By manually placing the data, you can have as many as you want, meaning you can create a move like, "Ridiculous Tackle", and have an animation that has the player Tackling the opponent 6 times.

If there's an 05 byte before the 08 byte, remove it, and then they'll play at the same time (perhaps with a slight delay)

Eventually I'll update this example with an attack called "Ridiculous Tackle" which has the player tackling the opponent 6 times (roflmao)


Right now, this is what we can/can't do:
[x] Add backgrounds to existing animations
[x] Combine multiple animations to play right after another
[ ] Make custom particles (Absorb, Ice Beam, Slash, etc)
[ ] Control how particles move

However, with the first two alone, we can create a whole bunch of decent-looking custom animations anyway.

Credits:
-Jambo51 for explaining how to add new attacks, and the offset of several tables, which helped me test animations
-DoestKnowHowToPlay for already documenting some of the commands
-Darthatron for finding the table containing all the animation command routines, hopefully these can be used to find out what each command does


EDIT: Some useful information found by DoestKnowHowToPlay and dreamengine:
http://www.pokecommunity.com/showpost.php?p=7481054&postcount=32
http://www.pokecommunity.com/showpost.php?p=7485231&postcount=37
http://www.pokecommunity.com/showpost.php?p=7485560&postcount=38

Gamer2020
June 2nd, 2012, 06:54 PM
I added animation repointing to the attack editor in PGE weeks ago but just haven't released the update. There is no need for such complex instructions on repointing :P

Full Metal
June 2nd, 2012, 07:10 PM
Congrats on working things out! (:
Hopefully somebody with more talent than me will figure out the last two abilities. o:

Darthatron
June 2nd, 2012, 07:31 PM
Very nice. :D We could almost make an animation editor with this data. *ponders*

Chaos Rush
June 2nd, 2012, 08:43 PM
I added animation repointing to the attack editor in PGE weeks ago but just haven't released the update. There is no need for such complex instructions on repointing :P
Haha, but because you haven't released it yet, I didn't exactly have a choice. It's the only way I can find the animation offsets, as I have no knowledge of tool making. But I'm glad you're still improving PGE.

Congrats on working things out! (:
Hopefully somebody with more talent than me will figure out the last two abilities. o:
From what I know, particle movement is controlled by the 0E XX XX XX 08 command, so its simply a matter of loading correct graphics and correct movement to match. But I don't even know where to start for custom particle movement :/


I also apologize for the poor quality of the second attack example, I will fix it soon. Also I realized that you can use either the 11 command or the 0E command, and place a pointer right after it to any existing attack animation, allowing you to sequentially do attacks. For instance, if you take the animation data of Tackle, remove the 08 byte at the end of it, then place 0E XX XX XX 08, and say we place the pointer to Earthquake's animation in the XX spots, then Tackle's animation will play the Earthquake animation right after it. This saves a lot of space, since it means you don't have to manually place Earthquake's animation data, it just means you can use the 0E or 11 command and point directly to it.

Gamer2020
June 2nd, 2012, 08:45 PM
Very nice. :D We could almost make an animation editor with this data. *ponders*
I think it would have to be some sort of script editor, that's the only way I see it working.

Darthatron
June 2nd, 2012, 09:27 PM
I think it would have to be some sort of script editor, that's the only way I see it working.

Yes, but with some kind of real-time loading of it would be cool.

Chaos Rush
June 3rd, 2012, 01:55 AM
I'm pretty sure I just found the table containing the Battle BG's at: 0x3ADE18.

The format goes like:
[XX XX XX 08] [YY YY YY 08] [ZZ ZZ ZZ 08]
XX = pointer to graphics
YY = pointer to palette
ZZ = pointer to tilemap

I haven't tried expanding it, but I will tomorrow (or whenever). This means we can use custom backgrounds, that's actually pretty big.

Darthatron
June 3rd, 2012, 06:10 AM
The routines for each of the "commands" for these animations are located in a table at 0x083ADF5C in the ROM. From this, I can say for sure that there are 0x30 commands (0x00-0x2F) and that commands 0x6 and 0x7 do nothing.

With this we can at least see how many parameters each command has.

EDIT1: I here-by name command 0x6 "nop" and command 0x7 "darthnop".

EDIT2:

00:
01:
02:
03: something <word> <byte> <byte2> (<hword> * byte2)
04:
05: waitstate
06: nop
07: nop2
08:
09: playsound <hword ID>
0A:
0B:
0C:
0D:
0F:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
1A:
1B:
1C:
1D:
1E:
1F:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
2A:
2B:
2C:
2D:
2E:
2F:

Edit3: I think when Gamefreak coded this, they set the compiler to "annoy hackers" mode.

NintendoBoyDX
June 3rd, 2012, 07:30 PM
There's probably couple of tables for these image data. Most likely one for backgrounds, and one for "particles". If we can find these we'll be able to expand them and put our own tilemaps and images in...

As far as manipulating them, that'd take some assembly work, unless we could find values like how far data moves across the screen, how many times, etc. That way we could reuse the animation, but with slight alterations.

Edit:
I've found the table of the "particles" / image data. Darth helped me find with researching a bit.
It's at 0x083ACC08, and is arranged in 8 byte entries, like so:
4: word - pointer to image data
2: hword - something to do with size?
2: hword - index number

For example, the first entry...
0x080D02520 - pointer to the bone image, used in bone rush
0x0002 - hword that may have something to do with size? not sure needs more research
0x2710 - hword thats the index number, when calculating, 0x2710 is subtracted from it, no idea why, but 0x2710 is the first one

083AD510 - seems to have the palette entries that each image uses:
4: [pointer to palette]
2: [index number in same format as above]
2: [unknown]

Chaos Rush
June 4th, 2012, 03:23 PM
I can now confirm that it is possible to create custom battle backgrounds by expanding the battle background table:
http://i49.tinypic.com/4trcow.png

http://i47.tinypic.com/2zy8qwi.png
This custom battle background takes up slot 0x1B (which does not exist in the original FireRed rom)

The table starts at 0x3ADE18, and ends at 0x3ADF5B. There's another table right after it, which I mistook as part of the same table, so just remember that it ends at 0x3ADF5B, even though it looks like it doesn't.

I inserted my tileset, palette, and tilemap all with unLZ (I made the tilemap with NTME). Simply insert into free space, then manually point to the offsets you used in your new table with a hex editor.


For anyone that wants to experiment, here is my tileset and tilemap (the palette is included within the tileset because it's indexed). To test it, insert these with unLZ, keep track of the offsets you inserted the tileset, palette, and tilemap, then repoint and expand the table (make sure you don't mistake the table right after it as part of the original table!!! just look at the start and end offsets I gave earlier in this post), then have the new entries in the table point to your tileset, palette, and tilemap, then make a custom battle animation (or edit an existing one) and use the background slot 0x1B. And yes, I designed the graphics so that it can scroll horizontally.

Fahreza
July 29th, 2012, 06:18 PM
Ruby Version Please. I make Hack with Ruby Not Fire Red

FRANKTANK
July 30th, 2012, 02:57 PM
Ruby Version Please. I make Hack with Ruby Not Fire Red
He's not making it specifically for you. Besides, do you know how much work it would take for him to redo all of it for Ruby?

timson733333
July 31st, 2012, 05:51 PM
I'd like to know if it's possible to make a tool to do all of this editing.

Darthatron
July 31st, 2012, 08:48 PM
I'd like to know if it's possible to make a tool to do all of this editing.
Yes it's possible. Just a matter of someone finding the time to do it.

Jambo51
August 1st, 2012, 05:24 AM
Ruby Version Please. I make Hack with Ruby Not Fire Red

He's not making it specifically for you. Besides, do you know how much work it would take for him to redo all of it for Ruby?

Actually, because it's a scripting language, it may well work for Ruby (and Emerald) without any modifications, apart from ROM pointers.

timson733333
August 1st, 2012, 12:18 PM
it may well work for Ruby (and Emerald) without any modifications, apart from ROM pointers.

yay Emerald

But for now, time to pull up the hex editor and try adding some new moves/animations manually. :P

ShadowTails
August 3rd, 2012, 08:33 AM
Am I on to something here?
http://www.youtube.com/watch?v=bRguM5EI09o
I basically just copied and pasted Super Fang over Slash without changing any pointers to see if I had actually found the animation data.

Yeah, embed isn't working...

I'll see if I can play around more with this later and repoint the data. Slash is at 2CD3DB. (or atleast, the data I was playing around with, attempting to copy Substitute over Slash made the game crash, so I just tried the one before it and it worked other than not loading the correct graphics, which obviously it wouldn't since I didn't change any pointers)

timson733333
August 22nd, 2012, 12:59 PM
I compared Slash's code from FireRed with Slash's code from Emerald, and this is what I got:

FireRed:

00 C7 27 02 A4 35 3E 08 82 03 01 00 F8 FF 00 00 19 81 00 3F 04 04 02 A4 35 3E 08 82 03 01 00 08 00 00 00 03 1D 8B 09 08 02 05 01 00 04 00 00 00 12 00 01 00 19 81 00 3F 05 08

Emerald:

00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 08

Since the codes are different, would using the scrolling animation code not work? Or would it have to be tweaked? Problem is, I don't know how to tweak it.

Chaos Rush
August 22nd, 2012, 02:54 PM
I compared Slash's code from FireRed with Slash's code from Emerald, and this is what I got:

FireRed:

00 C7 27 02 A4 35 3E 08 82 03 01 00 F8 FF 00 00 19 81 00 3F 04 04 02 A4 35 3E 08 82 03 01 00 08 00 00 00 03 1D 8B 09 08 02 05 01 00 04 00 00 00 12 00 01 00 19 81 00 3F 05 08

Emerald:

00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 08

Since the codes are different, would using the scrolling animation code not work? Or would it have to be tweaked? Problem is, I don't know how to tweak it.
The codes are exactly the same, except for the pointers. The scrolling animation code I had in the first post is for FireRed, so you would need to find the corresponding Emerald pointers and then replace it, then it should work.

timson733333
August 22nd, 2012, 03:23 PM
The codes are exactly the same, except for the pointers. The scrolling animation code I had in the first post is for FireRed, so you would need to find the corresponding Emerald pointers and then replace it, then it should work.

How would I find them?

Also, I'd like to know whether it's possible to remove a background from an existing animation, like Mach Punch or ExtremeSpeed.

Chaos Rush
August 22nd, 2012, 04:12 PM
How would I find them?

Also, I'd like to know whether it's possible to remove a background from an existing animation, like Mach Punch or ExtremeSpeed.
You could do one of these:

1. Using a hex editor with a search function, such as GoldFinger, search the FireRed code byte-by-byte in an Emerald ROM, but have blank spots where the pointers are. I can guarantee that this is the easiest and fastest way, but you have to know how to use a hex editor.

or

2. Calculate the offsets of the pointers in the FireRed code, go to that offset in a FireRed ROM, and then search the exact same bytes of that offset in an Emerald rom, and then reverse-calculate that offset for Emerald to get a pointer (just write it down in Notepad or MS Word or something), then use a search function to find that new pointer in an Emerald ROM.

MarinoKadame
August 22nd, 2012, 06:05 PM
Anyone tried to do the same thing with BW and B2W2 ?

Mr155555
August 23rd, 2012, 06:12 PM
Can You Do A Video Explaining Everything That Would Be Very Helpful

timson733333
August 23rd, 2012, 06:37 PM
Anyone tried to do the same thing with BW and B2W2 ?

Why would anyone want to add new moves to the games that have all the moves that people want already? I'm pretty sure that B/W and B2/W2 have a completely different hex language than the GBA games, anyways, so it'd be very hard to do.

Also, I recently tried adding the new animations to FireRed. I grabbed the False Swipe animation and pasted your background code for Night Slash before it (because I think that False Swipe's animation fits Night Slash better than regular Slash, but that's just me.) Then, I repointed (using PGE's Attack Editor) to the offset that I pasted the animation code in. It didn't work; it did the animation for Pound instead. So I grabbed the Night Slash code you made and repointed to that instead. Same thing, didn't work. Am I doing something wrong?

Gamer2020
August 24th, 2012, 09:25 AM
Why would anyone want to add new moves to the games that have all the moves that people want already? I'm pretty sure that B/W and B2/W2 have a completely different hex language than the GBA games, anyways, so it'd be very hard to do.

Also, I recently tried adding the new animations to FireRed. I grabbed the False Swipe animation and pasted your background code for Night Slash before it (because I think that False Swipe's animation fits Night Slash better than regular Slash, but that's just me.) Then, I repointed (using PGE's Attack Editor) to the offset that I pasted the animation code in. It didn't work; it did the animation for Pound instead. So I grabbed the Night Slash code you made and repointed to that instead. Same thing, didn't work. Am I doing something wrong?
Double check and make sure AttackAnimationTable=&H1C68F4 is in your roms.ini

timson733333
November 11th, 2012, 06:50 PM
Think I messed up somewhere here. I tried to create the Drain Punch anim by merging Comet Punch and Leech Life. I don't know how to discern where an animation ends, so I probably screwed up something. The code I have is right here, and apologies if it's really bad:

00 97 27 00 9F 27 0A 01 0C 0C 08 11 91 7E 1C 08 B6 7E 1C 08 03 F9 89 09 08 02 05 01 00 03 00 00 00 06 00 01 00 19 84 00 3F 05 0B 01 0D 08 02 08 00 97 27 0A 03 2A 01 0C 0C 08 04 01 02 78 72 3E 08 02 03 EC FF 0F 00 0C 00 05 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 19 AD 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 05 00 01 00 05 02 24 7B 3E 08 02 05 01 00 01 00 00 00 07 00 00 00 05 0E 44 EC 1C 08 05 04 0F 0E C9 56 1D 08 05 02 24 7B 3E 08 02 05 01 00 01 00 07 00 00 00 00 00 05 0B 03 0D 08 00 2F 27 00 41 27 03 DD 9B 0B 08 02 06 02 00 02 00 02 00 00 00 10 00 FB 4B 19 85 00 C0 0E 9E 56 1D 08 05 0E C9 56 1D 08 00 B1 27 00 A3 27 04 01 00 2F 27 00 97 27 0A 03 2A 01 0C 0C 08 04 01 02 78 72 3E 08 02 03 EC FF 0F 00 0C 00 05 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 19 AD 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 05 00 01 00 05 02 24 7B 3E 08 02 05 01 00 01 00 00 00 07 00 00 00 05 0E 44 EC 1C 08 05 04 0F 0E C9 56 1D 08 05 02 24 7B 3E 08 02 05 01 00 01 00 07 00 00 00 00 00 05 0B 03 0D 08 00 2F 27 00 41 27 03 DD 9B 0B 08 02 06 02 00 02 00 02 00 00 00 10 00 FB 4B 19 85 00 C0 0E 9E 56 1D 08 05 0E C9 56 1D 00 B1 27 00 A3 27 04 01 00 2F 27 00 97 27 0A 03 2A 01 0C 0C 08 04 01 02 78 72 3E 08 02 03 EC FF 0F 00 0C 00 05 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 19 AD 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 05 00 01 00 05 02 24 7B 3E 08 02 05 01 00 01 00 00 00 07 00 00 00 05 0E 44 EC 1C 08 05 04 0F 0E C9 56 1D 08 05 02 24 7B 3E 08 02 05 01 00 01 00 07 00 00 00 00 00 05 0B 03 0D 08 00 2F 27 00 41 27 03 DD 9B 0B 08 02 06 02 00 02 00 02 00 00 00 10 00 FB 4B 19 85 00 C0 0E 9E 56 1D 08 05 0E C9 56 1D 08

dreamengine
November 25th, 2012, 10:11 PM
Hi can someone explain to me or point me in the direction of how to import the test background chaos rush gave us? I tried repointing te table and stuff but I ended up with a a very glitched white screen. Also does the background table only have one pointer?

karatekid552
November 27th, 2012, 02:34 PM
For those looking to hack Ruby, I just found the animation pointer table. It is at 0x1C7168. It is probably posted somewhere else, but I've been searching for it for the past hour and couldn't find it.

dreamengine
December 27th, 2012, 05:07 PM
not sure if you know this yet, but for scrolling background command ZZ, 01 and 00 control the direction. As far as I know when you use a move a the background will always scroll right, but if the enemy uses the move the direction can be changed.

00 - background will scroll right when enemy uses the move
01 - background will scroll left when the enemy uses the move

SchokoInc
January 5th, 2013, 09:47 PM
As for particles i don't know if this helps but the code for the purple bubbles coming out at the end of a poison attack is

00 A7 27 00 A6 27 05 04 0F 0E 5B 57 1D 08 05 08

Right now I am searching for the ice-crystals and other part-animations and I will post them all if someone needs them :)

DoesntKnowHowToPlay
January 8th, 2013, 09:50 PM
Some random things I've found while fiddling with the animations recently:

15 17 and 15 16 appear to reset the background to normal.

21 07 XX 00 YY YY YY YY branches to YY YY YY YY if the side the attacker is on matches XX. Mega Punch's custom background operates by placing two of these in a row (with XX = 00 and 01) to branch to subroutines that set the background to the correct one and then return.

0F appears to return to where the initial script left off after a branch.

The first parameter of the 02 command always seems to be a pointer to some animation data- this structure is 24 bytes long.

The first two bytes indicate what image data to use, while the next two bytes indicate the palette. The enumeration for this is the same as that of the 00 command- in order for an effect to work properly, the 00 command must have been called for both of these- otherwise the palette and/or image will not be loaded. While the existing animations appear to always have these be the same, they don't have to be- you can for instance give the Stun Spore seeds Fire Blast's palette this way. For some animations both of these are 00- I believe these are effects that don't use images, such as Earthquake's screen-shaking.

I'm not entirely sure what the rest of the bytes do, but it appears the two pointers after these values contains more image data (I think the dimensions and how it animates, respectively) while the rest of it has to do with how the effect plays out. I've fiddled with it a bit and done some interesting things like these:

http://i.imgur.com/DuOL9.pnghttp://i.imgur.com/GL54F.png
http://i.imgur.com/BuX7r.pnghttp://i.imgur.com/nh2ZO.png

Garuga17
January 8th, 2013, 11:02 PM
I'm new to this hex-editing...

I still don't understand how to know when the animation starts and end, is there any other way? or can someone explain it? D:

Also, i've already point my move to my custom animation(well its slash with the darkcloud BG), but when i tried it out, it didn't work...

and, how do i know the move's animation offset?(for pointing it to my custom animation)

EDIT: i know about the offset now, still don't know about how to figure the start and the end of the animaton though

dreamengine
January 9th, 2013, 12:08 AM
The first two bytes indicate what image data to use, while the next two bytes indicate the palette. The enumeration for this is the same as that of the 00 command- in order for an effect to work properly, the 00 command must have been called for both of these- otherwise the palette and/or image will not be loaded. While the existing animations appear to always have these be the same, they don't have to be- you can for instance give the Stun Spore seeds Fire Blast's palette this way. For some animations both of these are 00- I believe these are effects that don't use images, such as Earthquake's screen-shaking.

I'm not entirely sure what the rest of the bytes do, but it appears the two pointers after these values contains more image data (I think the dimensions and how it animates, respectively) while the rest of it has to do with how the effect plays out. I've fiddled with it a bit and done some interesting things like these:

http://i.imgur.com/DuOL9.pnghttp://i.imgur.com/GL54F.png
http://i.imgur.com/BuX7r.pnghttp://i.imgur.com/nh2ZO.png

I'm sorry I don't understand what byte you are talking about to change the pallete you don't mean one these bytes for example 00 B1 27 when loading something I don't remember what

DoesntKnowHowToPlay
January 9th, 2013, 07:33 AM
I still don't understand how to know when the animation starts and end, is there any other way? or can someone explain it? D:

It begins at where the animation's pointer points to and ends at the 08 command. Since non-terminating 08s are rather common, what I usually do is just grab around x200 bytes, move it into free space, and chop bits off until the game crashes. There's probably a more efficient way to do this but it works. Also note that a few animations (I think Comet Punch) end in jumps instead of 08 commands.

I'm sorry I don't understand what byte you are talking about to change the pallete you don't mean one these bytes for example 00 B1 27 when loading something I don't remember what

This really isn't specific enough for me to help you. The 00 command loads palette and image data. basially, if you change an effect's image or palette data to XX YY, then you'll need to have an 00 XX YY command before the effect gets called, otherwise you'll have either borked image data, a borked palette (solid black), or both. If you've ever broken an animation such that it has solid black rectangles floating around, this is what I'm talking about- avoiding this is why you need the 00 command.

dreamengine
January 9th, 2013, 01:12 PM
[/QUOTE]This really isn't specific enough for me to help you. The 00 command loads palette and image data. basially, if you change an effect's image or palette data to XX YY, then you'll need to have an 00 XX YY command before the effect gets called, otherwise you'll have either borked image data, a borked palette (solid black), or both. If you've ever broken an animation such that it has solid black rectangles floating around, this is what I'm talking about- avoiding this is why you need the 00 command.[/QUOTE]

I'm sorry. Yes I know that if you change those bytes you get the black boxes, that's why I am confused. Originally I thotght you were talking about those bytes. If you could tell me the bytes to change for the green shadow ball that would help because I could figure it out from there because I have not a clue as too which bytes you are referring to. Sorry

DoesntKnowHowToPlay
January 10th, 2013, 05:28 PM
I'm sorry. Yes I know that if you change those bytes you get the black boxes, that's why I am confused. Originally I thotght you were talking about those bytes. If you could tell me the bytes to change for the green shadow ball that would help because I could figure it out from there because I have not a clue as too which bytes you are referring to. Sorry The bytes I'm talking about are the bytes in the effect data, which is not in the battle script proper. It is pointed to by the 02 command, always (as far as I've seen) as the first parameter. The values are usually in the x3EXXXX range- if you're looking around there you're probably in the right place.



That's not what I'm posting to talk about, however. To do colored backgrounds like Giga Drain, insert the following:

02 24 7B 3E 08 02 05 01 00 SS 00 00 00 YY 00 XX XX 05

Where XX XX is the color you want, YY is the intensity (0C for Giga Drain- 10 replaces the background entirely with the given color), and SS is the speed of the transition (01 for Giga Drain, but I imagine Hyper Beam and other attacks use the same logic with a higher value). To revert the background to normal, place the following:

02 24 7B 3E 08 02 05 01 00 SS 00 YY 00 00 00 XX XX 05 0B 03 0D

The values here do not have to be the same, but I'd advise making the color and intensity the same or it will abruptly change at the start of the transition back.

This allows us to accomplish animations that benefit from backgrounds without always having to insert new ones, like so:

http://i.imgur.com/G3p1e.pnghttp://i.imgur.com/6DIim.png

dreamengine
January 10th, 2013, 08:08 PM
The bytes I'm talking about are the bytes in the effect data, which is not in the battle script proper. It is pointed to by the 02 command, always (as far as I've seen) as the first parameter. The values are usually in the x3EXXXX range- if you're looking around there you're probably in the right place.

Well obviously I wasn't looking in the right place. I thought only 11 and 0E pointed to else where. Unfortunately I still haven't found bytes that edit palette what I did do though, (for shadow ball) I went to the offset x3E7608 which got me something, and I thought oh maybe this is what he was talking about. So after the first 2 bytes I tried changing it to something, but only got a pure black shadow ball. :/

Since we're posting useful stuff...

I found that there's a special code or something to use backgrounds that are different depending on if you use the move or if the opponent does because if you use a regular command for example if you try the high power background you'll understand. I came across two pointers, one to use for the scroll flying type background and one for the high power one.

High Power - 0E 89 7D 1C 08
Flying background - 0E CF 59 1D 08

DoesntKnowHowToPlay
January 10th, 2013, 08:31 PM
If you got a pure black shadow ball, then you're probably changing the right bytes- you have to have loaded whatever palette you change it to with the 00 command. For the green ball in the screenshot I gave, I used palette B0 27.

dreamengine
January 10th, 2013, 08:44 PM
If you got a pure black shadow ball, then you're probably changing the right bytes- you have to have loaded whatever palette you change it to with the 00 command. For the green ball in the screenshot I gave, I used palette B0 27.

Ok so I changed just the palette at the x3EXXXX command and got black ball, then i tried changing the palette and the actual ball graphics to 00 B0 27 and I got green box of text O.o

Edit: I know what you mean know and got it. Thanks :)

Chaos Rush
January 10th, 2013, 10:00 PM
@DoesntKnowHowToPlay: Thank you for posting these findings, I will definitely be revising some of my move animations. I will add your info to the first post this weekend.

Garuga17
January 11th, 2013, 06:46 AM
It begins at where the animation's pointer points to and ends at the 08 command. Since non-terminating 08s are rather common, what I usually do is just grab around x200 bytes, move it into free space, and chop bits off until the game crashes. There's probably a more efficient way to do this but it works. Also note that a few animations (I think Comet Punch) end in jumps instead of 08 commands.


Urgh damn you my brain, still not understand D:

When the game crashes? i mean, is it when you do the move, or at the start of the game? and what do you mean by chop the bits off? Dx

Also, people, can you share the move code you guys found so far? it really helped even if it just one or two...(except slash)

dreamengine
January 11th, 2013, 01:03 PM
Urgh damn you my brain, still not understand D:

When the game crashes? i mean, is it when you do the move, or at the start of the game? and what do you mean by chop the bits off? Dx

Also, people, can you share the move code you guys found so far? it really helped even if it just one or two...(except slash)

By crash he means the game resets and goes back to the title screen right after the move animation is completed. By chip off he means change a few bytes at the end to FF and test to see if the animation works. If it works then you need to chip off more bytes, if it freezes then that means you changed too many bytes, but if it resets the game then you changed the right byte. The end of an animation is usually the last 08 byte before an 00 XX 27 command.

Garuga17
January 11th, 2013, 11:48 PM
By crash he means the game resets and goes back to the title screen right after the move animation is completed. By chip off he means change a few bytes at the end to FF and test to see if the animation works. If it works then you need to chip off more bytes, if it freezes then that means you changed too many bytes, but if it resets the game then you changed the right byte. The end of an animation is usually the last 08 byte before an 00 XX 27 command.


Oh! I see now! Thanks a lot, now i understand :D


oh, and i hope chaos rush updates his post, and post more animation offset he knew :3

dreamengine
January 12th, 2013, 09:04 AM
oh, and i hope chaos rush updates his post, and post more animation offset he knew :3

All the animation offsets are in PGE if the offset is correct in your ini

TheOrangePichu
January 13th, 2013, 07:45 PM
The first parameter of the 02 command always seems to be a pointer to some animation data- this structure is 24 bytes long.

The first two bytes indicate what image data to use, while the next two bytes indicate the palette. The enumeration for this is the same as that of the 00 command- in order for an effect to work properly, the 00 command must have been called for both of these- otherwise the palette and/or image will not be loaded. While the existing animations appear to always have these be the same, they don't have to be- you can for instance give the Stun Spore seeds Fire Blast's palette this way. For some animations both of these are 00- I believe these are effects that don't use images, such as Earthquake's screen-shaking.

I'm not entirely sure what the rest of the bytes do, but it appears the two pointers after these values contains more image data (I think the dimensions and how it animates, respectively) while the rest of it has to do with how the effect plays out. I've fiddled with it a bit and done some interesting things like these:

http://i.imgur.com/DuOL9.pnghttp://i.imgur.com/GL54F.png
http://i.imgur.com/BuX7r.pnghttp://i.imgur.com/nh2ZO.png

Interesting, I have been editing moves myself and haven't come across this yet. Could you please clarify on this? I am slightly confused of what a 00 command is.

Also, not sure if this has been discovered, but if you wish to easily find the data for a move, find the animation pointer (I suggest using Gamer2020's PGE Attack Editor for it) and highlight the bytes of the animation until you reach the following bytes together:

08 00 XX 27

This string tells us that an animation has just ended and is moving onto a new on. Make sure to highlight everything up to the 08. DO NOT HIGHLIGHT THE 00 XX 27.

XX refers to, and my guess, the image data for the next animation.

DoesntKnowHowToPlay
January 13th, 2013, 07:59 PM
Interesting, I have been editing moves myself and haven't come across this yet. Could you please clarify on this? I am slightly confused of what a 00 command is.

Also, not sure if this has been discovered, but if you wish to easily find the data for a move, find the animation pointer (I suggest using Gamer2020's PGE Attack Editor for it) and highlight the bytes of the animation until you reach the following bytes together:

08 00 XX 27

This string tells us that an animation has just ended and is moving onto a new on. Make sure to highlight everything up to the 08. DO NOT HIGHLIGHT THE 00 XX 27.

XX refers to, and my guess, the image data for the next animation.

The 00 command is what you are describing in your post- the 00 XX 27 blocks that occur at the start of many animation scripts. It takes the next two bytes as parameters and loads image data. I should warn that they do not occur in *all* animation scripts- Sky Attack, Doom Desire, and Haze are noteworthy exceptions, and some animations use 00 XX 28 instead. Also, it doesn't have to be at the beginning, but that is how every in-game animation that I've looked at that doesn't branch does it.

While I'm here, I've isolated another command- 1C is used for playing a sound repeatedly. It's used in Needle Arm, PoisonPowder, and probably a number of other moves. It takes five bytes- the first two indicate what sound to play, the fourth controls the delay between sounds, and the fifth controls how many times to play the sound. I'm not sure what the third byte is for but it's 3F in all the cases I've looked at.

Delta Nite
January 16th, 2013, 06:16 PM
Let me see if I got it. I'll be using slash's animation code.

00 C7 27 02 A4 35 3E 08 82 03 01 00 F8 FF 00 00 19 81 00 3F 04 04 02 A4 35 3E 08 82 03 01 00 08 00 00 00 03 1D 8B 09 08 02 05 01 00 04 00 00 00 12 00 01 00 19 81 00 3F 05 08

The 00 C7 27 means a new animation will be executed.
02 Indicates that A4 35 3E 08 is the pointer to which animation will be called, and I can't identify the pointer to the pallete... I'm pretty sure it isn't the 82 03 01 00...

romancandle
January 23rd, 2013, 09:20 PM
Okay, hopefully someone can help me with this:

I'm trying to recreate the Elemental Fangs by using the particle from the punches with the bite animation. But I'm just not getting off the ground it as it all seems greek to me. I think I've found the offsets for the animations, but I can't even figure out where they end to remove and start testing them.

Here are the offsets I came up with from the method described in the first post:

Ice Punch: 1CD2e0

Fire Punch: 1D08b5

Bite: 1CE190

I was looking to work on Ice Fang first, but I grabbed Fire Punch too so I could compare the two and see what the difference was (I assumed the difference would be the particles, as they two moves seem identical otherwise). Anyone willing to offer help and/or explain it like I'm five?

SchokoInc
January 26th, 2013, 08:28 PM
well i actually did the same thing myself so i think i could help you :)

at first you copy all the code from the bite-offset and start replacing 08-bytes with FF until the game restarts exactly at the end of the animation :) If the animation plays fine, then you removed a 08-byte that didn't belong to the animation. If it stops midway, it was not the end of the animation and you have to restore it and replace the next 08 byte.
Alternatively in about 99% of all the cases an animation starts with 00 xx 27 or 00 xx 28 meaning you could search for the next 00 xx 27 or 00 xx 28 after your animation so just search for it at offset 1C3190 :) this way saves MUCH time :D

When you got your bite-animation-data just remove the final 08 bite and add the particles you need.

Now for the particles:
To get the thunder particle is quite easy: just remove the first 02 xx xx 3E 08 xx ... you see and all code until the next 02 xx xx 3E 08 so you remove the punching part. Then add the rest of the animation at the end of your bite animation, making them play after each other.

The fire- and ice-particles are harder to get, but if you remember which part you deleted in the thunderpunch animation this shouldn't be a big problem :) if you want to remove the ring of fire/ice in the beginning, just remove everything before the punch except the 00 xx 27 or 00 xx 28 parts as they load the graphics. If you want the ring to play BEFORE the bite, paste the bite animation at the position where you deleted the punch :)

Here is the code for the punchless fire-punch :)
00 9F 27 00 2D 27 00 97 27 0A 03 0C 0C 08 03 F9 A7 0B 08 0A 05 04 00 02 00 00 00 09 00 1F 00 02 E0 5B 3E 08 81 01 00 00 02 E0 5B 3E 08 81 01 40 00 02 E0 5B 3E 08 81 01 80 00 02 E0 5B 3E 08 81 01 C4 00 19 89 00 3F 05 02 10 67 3E 08 82 04 00 00 00 00 01 00 01 00 03 F9 89 09 08 02 05 01 00 00 00 03 00 0F 00 01 00 (paste the bite animation here if you want the ring) 0E 50 09 1D 08 04 04 19 8C 00 3F 05 03 F9 A7 0B 08 0A 05 04 00 00 00 09 00 00 00 1F 00 05 0B 03 0D 08

And this is the ringless punchless fire-punch (just paste this after your bite if you don't want the ring):
00 9F 27 00 2D 27 00 97 27 0A 03 0C 0C 08 03 F9 A7 0B 08 0A 05 04 00 02 00 00 00 09 00 1F 00 0E 50 09 1D 08 04 04 19 8C 00 3F 05 03 F9 A7 0B 08 0A 05 04 00 00 00 09 00 00 00 1F 00 05 0B 03 0D 08

Garuga17
January 26th, 2013, 10:19 PM
Anybody have the code for the self-bubbles(when doing the waterfall move) only? i'm trying to make an aqua tail animation(is that even possible to do that? use the bubbles only?)

romancandle
January 27th, 2013, 06:08 PM
well i actually did the same thing myself so i think i could help you :)

at first you copy all the code from the bite-offset and start replacing 08-bytes with FF until the game restarts exactly at the end of the animation :) If the animation plays fine, then you removed a 08-byte that didn't belong to the animation. If it stops midway, it was not the end of the animation and you have to restore it and replace the next 08 byte.
Alternatively in about 99% of all the cases an animation starts with 00 xx 27 or 00 xx 28 meaning you could search for the next 00 xx 27 or 00 xx 28 after your animation so just search for it at offset 1C3190 :) this way saves MUCH time :D

When you got your bite-animation-data just remove the final 08 bite and add the particles you need.

Now for the particles:
To get the thunder particle is quite easy: just remove the first 02 xx xx 3E 08 xx ... you see and all code until the next 02 xx xx 3E 08 so you remove the punching part. Then add the rest of the animation at the end of your bite animation, making them play after each other.

The fire- and ice-particles are harder to get, but if you remember which part you deleted in the thunderpunch animation this shouldn't be a big problem :) if you want to remove the ring of fire/ice in the beginning, just remove everything before the punch except the 00 xx 27 or 00 xx 28 parts as they load the graphics. If you want the ring to play BEFORE the bite, paste the bite animation at the position where you deleted the punch :)

Here is the code for the punchless fire-punch :)
00 9F 27 00 2D 27 00 97 27 0A 03 0C 0C 08 03 F9 A7 0B 08 0A 05 04 00 02 00 00 00 09 00 1F 00 02 E0 5B 3E 08 81 01 00 00 02 E0 5B 3E 08 81 01 40 00 02 E0 5B 3E 08 81 01 80 00 02 E0 5B 3E 08 81 01 C4 00 19 89 00 3F 05 02 10 67 3E 08 82 04 00 00 00 00 01 00 01 00 03 F9 89 09 08 02 05 01 00 00 00 03 00 0F 00 01 00 (paste the bite animation here if you want the ring) 0E 50 09 1D 08 04 04 19 8C 00 3F 05 03 F9 A7 0B 08 0A 05 04 00 00 00 09 00 00 00 1F 00 05 0B 03 0D 08

And this is the ringless punchless fire-punch (just paste this after your bite if you don't want the ring):
00 9F 27 00 2D 27 00 97 27 0A 03 0C 0C 08 03 F9 A7 0B 08 0A 05 04 00 02 00 00 00 09 00 1F 00 0E 50 09 1D 08 04 04 19 8C 00 3F 05 03 F9 A7 0B 08 0A 05 04 00 00 00 09 00 00 00 1F 00 05 0B 03 0D 08

First and foremost, major thanks for helping me. Here's what I got:

00 9B 27 00 97 27 0A 01 0C 0C 08 19 9A 00 3F 02 30 79 3E 08 02 06 00 00 E0 FF 00 00 00 00 33 03 0A 00 02 30 79 3E 08 02 06 00 00 20 00 04 00 00 00 CD FC 0A 00 04 0A 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 03 F9 89 09 08 05 05 01 00 00 00 04 00 07 00 01 00 05 0B 01 0D 04 01 00 9F 27 00 2D 27 00 97 27 0A 03 0C 0C 08 03 F9 A7 0B 08 0A 05 04 00 02 00 00 00 09 00 1F 00 0E 50 09 1D 08 04 04 19 8C 00 3F 05 03 F9 A7 0B 08 0A 05 04 00 00 00 09 00 00 00 1F 00 05 0B 03 0D 08Italics is where I added the fire punch particles, all I did was delete a 08. I had forgotten to at the beginning and the move was just bite. When I removed it, now it stops after the bite?

OH, I SEE IT! I MISSED A 08 after a 0B. Ugh.

It works:

http://i.imgur.com/iZOW80o.png

I used exactly the code above. It's a little low when used on you, for my tastes, but it works. I'll post Ice Fang and Thunder Fang when I have the time to play with them. I just wanted to show you code works. It bites, the bite disappears, and the particles appear, if that bothers anyone.

SchokoInc
January 27th, 2013, 06:19 PM
So is everthing working now with the fangs? :)

And for the self-bubbles:
Find the offset of the waterfall animation and copy it then start cutting of bites from the end until about a line after the first 02 xx xx 3E in the waterfall-animation (usually the 05 byte after it if there isn't any you have to experiment a little here) and then add your impact animation :) If you want a nice tail animation try the knock-off-animation which pretty much resembles the gen VI and V tail-attack-hit's animation :)

romancandle
January 27th, 2013, 06:43 PM
So is everthing working now with the fangs? :)

And for the self-bubbles:
Find the offset of the waterfall animation and copy it then start cutting of bites from the end until about a line after the first 02 xx xx 3E in the waterfall-animation (usually the 05 byte after it if there isn't any you have to experiment a little here) and then add your impact animation :) If you want a nice tail animation try the knock-off-animation which pretty much resembles the gen VI and V tail-attack-hit's animation :)

Apparently not. I went with this for Ice Fang:

00 9D 27 00 97 27 00 9F 27 08 03 04 00 00 F6 FF 01 00 01 00 19 84 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 03 00 01 00 05 04 0F 0E 0A 54 1D 08 04 05 03 F9 A7 0B 08 0A 05 04 00 02 00 09 00 00 00 4C 7F 05 02 24 7B 3E 08 02 05 01 00 00 00 07 00 00 00 00 00 05 0B 03 0D 08That's only the ice particles. However, when used in battle, it does nothing (well, it bites, but no particles). Not sure where I went wrong.

Edit: There was a part in the beginning, 5 spaces long that I removed. 0A 03 0C 0C 08. I didn't see them as all that important and thus I removed them. Should I reenter those?

Double Edit: I removed an extra 08 (right after the third 27) that had snuck in. Now it crashes after the bite.

Triple Edit: I discovered I missed an entire 02 xx xx xx 3E anyway, so I got rid of that. Then it crashed again.

Quad-Edit-ruped: I tried it on Thunder Fang, and it crashed again. It goes from the bite to the restart. I removed everything from the first 02 xx xx xx 3E to the last 02 xx xx xx 3E 08 and it doesn't work. Maybe I misunderstood your directions. And I know you said "next", but that just seems insanely long compared to the fire particles. I even tried to reverse engineer the fire particles and just can't seem to see the logic.

Garuga17
January 27th, 2013, 09:03 PM
So is everthing working now with the fangs? :)

And for the self-bubbles:
Find the offset of the waterfall animation and copy it then start cutting of bites from the end until about a line after the first 02 xx xx 3E in the waterfall-animation (usually the 05 byte after it if there isn't any you have to experiment a little here) and then add your impact animation :) If you want a nice tail animation try the knock-off-animation which pretty much resembles the gen VI and V tail-attack-hit's animation :)

Whoa, thanks dude! I was planning to use slam animation, but i never thought about knock off, thank you! :D

SchokoInc
January 27th, 2013, 09:30 PM
Whoa, thanks dude! I was planning to use slam animation, but i never thought about knock off, thank you! :D
no problem :D I stumbled across the knock-off animation when i created a dragon tail attack that should also disable the foes item and thought well knock off sure looks like a tail attack :)

EDIT.: If you want the star that shows the impact to be blue (for the more waterish feeling), go to the last 02 xx xx 3E in the knock off animation (and you entire animation) which should be the star marking the impact. Go to that position ( 3E xx xx ) and copy the animation data you find here (should start with yy 27 yy 27 ... 08) and is 24 bytes (1,5 lines) long to some place (i prefer the end of my animation) and then repoint the 02 xx xx 3E to that position. After that you just have to experiment and replace the second yy byte in your yy 27 yy 27 part (which is responsible for the colour) with another palette (as your bubbles start with 00 zz 27 or 00 zz 28 you can just copy that zz value and replace the second yy value with it) so you get the blue impact star. :)


As for the fangs try to leave out the bite part and start with the punch-animations again and just remove that 02 xx xx 3E part for the punch :) and i think you misunderstood the part about removing everthing between two 02 xx xx 3Es :o you just have to remove about 1 line and a little more so when you see a 05 or 04 14 or 19 one line lower this is normally where you have to stop deleting :)

romancandle
January 28th, 2013, 12:08 PM
As for the fangs try to leave out the bite part and start with the punch-animations again and just remove that 02 xx xx 3E part for the punch :) and i think you misunderstood the part about removing everthing between two 02 xx xx 3Es :o you just have to remove about 1 line and a little more so when you see a 05 or 04 14 or 19 one line lower this is normally where you have to stop deleting :)

Okay, here is the Ice Punch animation:

00 9D 27 00 97 27 00 9F 27 02 24 7B 3E 08 02 05 01 00 01 00 00 00 07 00 00 00 03 F9 A7 0B 08 0A 05 04 00 02 00 00 00 09 00 4C 7F 04 14 19 7A 00 3F 02 60 63 3E 08 02 01 00 00 02 60 63 3E 08 02 01 40 00 02 60 63 3E 08 02 01 80 00 02 60 63 3E 08 02 01 C0 00 04 05 02 48 63 3E 08 02 01 20 00 02 48 63 3E 08 02 01 60 00 02 48 63 3E 08 02 01 A0 00 02 48 63 3E 08 02 01 E0 00 04 11 02 10 67 3E 08 04 05 00 00 F6 FF 08 00 01 00 00 00 02 08 7C 3E 08 03 04 00 00 F6 FF 01 00 01 00 19 84 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 03 00 01 00 05 04 0F 0E 0A 54 1D 08 04 05 03 F9 A7 0B 08 0A 05 04 00 02 00 09 00 00 00 4C 7F 05 02 24 7B 3E 08 02 05 01 00 00 00 07 00 00 00 00 00 05 0B 03 0D 08Every 02 xx xx 3E 08 is highlighted. The part italicized is the part I believe you're talking about. I've removed that, it just goes back to start. I think I'm getting hung up on where to start the removal.

Edit: I removed ALL of the underlined. It now works--HOWEVER! However, there's a quick black fade-in, fade-out at the end. The original fades to black a bit. I'm not sure what part caused that. I don't know WHY removing the underlined worked, but it did. Now I just want to remove the black fade part.

Double Edit: FIXED IT! I started at the end and changed bytes that differed between Fire Punch and Ice Punch until the fade disappeared. Here's the Ice Fang code:

00 9B 27 00 97 27 0A 01 0C 0C 08 19 9A 00 3F 02 30 79 3E 08 02 06 00 00 E0 FF 00 00 00 00 33 03 0A 00 02 30 79 3E 08 02 06 00 00 20 00 04 00 00 00 CD FC 0A 00 04 0A 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 03 F9 89 09 08 05 05 01 00 00 00 04 00 07 00 01 00 05 0B 01 0D 04 01 00 9D 27 00 97 27 00 9F 27 0E 0A 54 1D 08 04 05 03 F9 A7 0B 08 0A 05 04 00 02 00 09 00 00 00 4C 7F 05 02 24 7B 3E 08 02 05 04 00 00 00 07 00 00 00 00 00 05 0B 03 0D 08

I've also got Thunder Fang working.
00 9B 27 00 97 27 0A 01 0C 0C 08 19 9A 00 3F 02 30 79 3E 08 02 06 00 00 E0 FF 00 00 00 00 33 03 0A 00 02 30 79 3E 08 02 06 00 00 20 00 04 00 00 00 CD FC 0A 00 04 0A 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 03 F9 89 09 08 05 05 01 00 00 00 04 00 07 00 01 00 05 0B 01 0D 04 01 00 97 27 00 9F 27 00 35 27 0A 01 0C 0C 08 02 38 5F 3E 08 02 02 00 00 F0 FF 04 01 02 38 5F 3E 08 02 02 00 00 10 00 04 01 19 D6 00 3F 03 E9 A0 0B 08 02 03 01 01 01 01 01 01 04 02 03 F9 89 09 08 02 05 01 00 00 00 03 00 0F 00 01 00 02 08 7C 3E 08 03 04 00 00 00 00 01 00 02 00 04 01 02 24 7B 3E 08 02 05 07 00 02 00 10 00 00 00 00 00 04 14 05 0B 01 0D 08Italics = Thunderpunch effects. 07 was a necessary change to get the sprites and background back to normal after the effect. Now that these are done, I'm moving onto Head Smash.

romancandle
January 29th, 2013, 11:18 AM
I don't usually double post, but I figured a different problem would require it:

Is it possible to edit the color of the particles in the animation? Here's the scenario:

I'm trying to use Psybeam as a base for Dark Pulse. (I tried Water Pulse, but the water droplets were driving me nuts). Here's the code:

00 B3 27 19 B6 00 C0 14 00 17 1F 39 CF 0D 08 07 C1 00 C0 FF 3F 00 03 00 04 00 00 00 0F 00 0E D4 0D 1D 08 0E D4 0D 1D 08 03 05 97 09 08 05 05 00 00 06 00 00 08 04 00 01 00 03 DD 9B 0B 08 02 06 04 00 02 00 02 00 00 00 0C 00 5F 7E 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 0E D4 0D 1D 08 05 04 01 13 36 85 1C 08The italic bits are the Psybeam waves. I've edited in the background (01, I stole the ending from Pursuit because I honestly couldn't figure out how to close non-moving backgrounds). It works as is. I'm just curious if anyone knows if it's possible to change the palette of the particles without affecting Psybeam itself. I was also planning on using this for Dragon Pulse.

Edit: I've found that 7E edits the color of the target.

http://i.imgur.com/rqiX5p3.pnghttp://i.imgur.com/F9iAXiH.pnghttp://i.imgur.com/pVSis1F.png

First is 30, Second is 00, and the Third is FF. HOWEVER, that's only changing 7E. The 5F changes it too, the 00 before doesn't seem to do anything, and the 0E after it is unrelated to this change (and crashes the game if you change it. That'll learn me).

SchokoInc
January 30th, 2013, 02:16 PM
Beware that 02 24 7B 3E 08 xxxxxxxxxxxxxxxxxxxx is the code for changing the background colour.

Editing the particles colour or even the particles used is possible :) I gave Garuga17 instructions on how to change the stars color in the knock-off-animation before :)
Here is a quick summary:

1. The particle type and palette is already defined in the 02 xx xx 3E 08 part. So you have to go to the adress it points too (02 12 34 3E 08 points to 0x3E3412) and copy the 24 bytes long code you find there (zz 27/28 zz 27/28 xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx 08). That zz in the code should also be at the start of your attack animation in any of these 00 zz 27/28s.

2. Paste it somewhere free (I normally paste it directly under my attack animation) Let's say at 0x912345.

3. Repoint the 02 xx xx 3E 08 to the pasted space ( 02 45 23 91 08 in our example).

4. The first zz is for the particle used, the second one for the palette. If you want a particle in your attack to have another palette search for another attack that uses a particle with that attack. (Let's say you want your psybeam-rings to have shadow-balls palette which is C0). So you have the psybeam zz 27/28 zz 27/28 xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx 08 at 912345 and replace the second zz which is for the palette with C0 (for the shadow ball ball with psybeams palette replace the first zz and for the normal shadow ball replace both). That way you get every attack particle-palette-attack combination possible.

5. As in most cases the new particles/palettes are not loaded yet, add a 00 .. 27/28 at the beginning of your animation for every particle or palette used where .. stands for the particle or palette used (so 00 C0 27 at the beginning for our dark rings)

pawell6
February 3rd, 2013, 04:33 PM
Hi guys, I try to recreate draco meteor, so I used one of meteors from eruption (changed color from red to violet) , colored BG (violet one). Everything works fine, but one thing: after attack is perfomed pokemon sprites become violet. Can somebody help me?
code I used:
00 D9 27 00 A6 27 02 24 7B 3E 08 02 05 1F 00 02 00 00 00 09 00 CC CC 02 14 05 93 08 28 05 96 00 E0 FF 20 00 3C 00 02 00 1C 7C 00 3F 10 02 04 50 05 0E C7 59 1D 08 08

Bold pointer: D9 27 A6 27 D8 C9 3A 08 F0 1C 23 08 00 00 00 00 FC 1C 23 08 55 D4 0A 08

Screenshots during attack and after attack

MrDollSteak
February 8th, 2013, 11:54 PM
no problem :D I stumbled across the knock-off animation when i created a dragon tail attack that should also disable the foes item and thought well knock off sure looks like a tail attack :)

EDIT.: If you want the star that shows the impact to be blue (for the more waterish feeling), go to the last 02 xx xx 3E in the knock off animation (and you entire animation) which should be the star marking the impact. Go to that position ( 3E xx xx ) and copy the animation data you find here (should start with yy 27 yy 27 ... 08) and is 24 bytes (1,5 lines) long to some place (i prefer the end of my animation) and then repoint the 02 xx xx 3E to that position. After that you just have to experiment and replace the second yy byte in your yy 27 yy 27 part (which is responsible for the colour) with another palette (as your bubbles start with 00 zz 27 or 00 zz 28 you can just copy that zz value and replace the second yy value with it) so you get the blue impact star. :)


As for the fangs try to leave out the bite part and start with the punch-animations again and just remove that 02 xx xx 3E part for the punch :) and i think you misunderstood the part about removing everthing between two 02 xx xx 3Es :o you just have to remove about 1 line and a little more so when you see a 05 or 04 14 or 19 one line lower this is normally where you have to stop deleting :)

I've just been making Aqua tail too, following your advice to use Knock-off. However I really can't find the end to knock off, i've been trimming it down to every 08 i could and either, the whole animation would play out and freeze OR after excess trimming it would freeze mid animation. Do you happen to know the last line of the data?

Edit: I'm 100% certain that the Knock Off goes from offset 1D4A0F and finishes at 1D4A9E, because there is a pointer to a new move at 1D4A9F. However even with all this copied and combined with Aqua Tail, the end of the move freezes. In the mean time I've used Slam and it works.

Bela
February 9th, 2013, 01:06 AM
Has anyone tried yet to compare Razor Leaf with Magical Leaf? I think using Magical Leaf's "rainbow" effect for moves like Draco Meteor would be cool. I took a look at this a while back, I'll post what I found later.

Garuga17
February 9th, 2013, 01:49 AM
I've just been making Aqua tail too, following your advice to use Knock-off. However I really can't find the end to knock off, i've been trimming it down to every 08 i could and either, the whole animation would play out and freeze OR after excess trimming it would freeze mid animation. Do you happen to know the last line of the data?

Edit: I'm 100% certain that the Knock Off goes from offset 1D4A0F and finishes at 1D4A9E, because there is a pointer to a new move at 1D4A9F. However even with all this copied and combined with Aqua Tail, the end of the move freezes. In the mean time I've used Slam and it works.


dude, here is my Aqua tail code:

00 A4 27 00 AB 27 00 9D 27 0A 03 0C 0C 08 03 F9 89 09 08 05 05 00 00 00 00 02 00 17 00 01 00 04 05 19 87 00 C0 02 B0 5A 3E 08 02 04 0A 00 0A 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 F1 FF 00 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 14 00 0A 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 00 00 F6 FF 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 F6 FF 0F 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 19 00 14 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 EC FF 14 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 0C 00 00 00 19 00 00 00 05 00 25 28 00 97 27 02 54 4E 3D 08 02 02 04 00 06 00 04 04 19 73 00 3F 02 64 F7 3F 08 82 02 F0 FF F0 FF 04 08 02 3C 7B 3E 08 02 07 1F 00 05 00 01 00 FF 7F 0A 00 00 00 00 00 02 08 7C 3E 08 83 04 00 00 00 00 01 00 02 00 19 84 00 3F 02 9C 4E 3D 08 02 05 01 00 F4 FF 0A 00 00 00 03 00 02 84 4E 3D 08 02 03 00 00 00 00 05 00 04 03 03 D1 8C 09 08 02 05 01 00 00 00 03 00 06 00 01 00 04 05 02 84 4E 3D 08 02 03 01 00 00 00 06 00 04 0A 05 0B 03 0D 08

I created it few days ago, i'm not remember what is exactly i'm doing to fix the freezes though

knizz
February 9th, 2013, 02:26 AM
00 xxxx
01 xxxx
02 08xxxxxx xx nn [0000 1111 2222 … nnnn]
03 08xxxxxx xx nn [0000 1111 2222 … nnnn]
04 xx
05
06
07
08
09 xxxx
0A xx
0B xx
0C xxxx
0D
0E 08xxxxxx
0F
10 xx xxxx
11 08aaaaaa 08bbbbbb
12 vv 08xxxxxx
13 08xxxxxx
14 xx
15
16
17
18 xx
19 xxxx xx
1A xx
1B ?
1C xxxx xx xx xx
1D xxxx xx xx
1E xxxx
1F 08xxxxxx nn [0000 1111 2222 … nnnn]
20
21 xx xxxx 08xxxxxx
22 xx
23 xx
24 xxxxxxxx
25 xx xx xx
26 ?
27 ?
28 xx
29
2A xx
2B xx
2C xx
2D xx
2E xx
2F
--END


the implementations of these commands can be found in the table at 083ADF5C

02: The "08xxxxxx" points to an object template. (http://www.pokecommunity.com/showthread.php?p=6346323)
0C: BLDCNT (http://nocash.emubase.de/gbatek.htm#lcdiocolorspecialeffects)=0x3F40; BLDALPHA=x;
0D: BLDCNT=0; BLDALPHA=0;
0E: call (calls in calls are not supported)
0F: return
11: if(cond&1) goto b; else goto a;
12: if(cond==v) goto x;
13: goto x;
1E: BLDCNT=x

tajaros
February 9th, 2013, 03:35 AM
Ok, so I'm trying to create a custom animation for zen headbutt and I tried using the charge animation (I tried the one in shock wave but didn't worked... :/) and headbutt animation...

The thing is I want the charge to be blue instead of yellow here is how it looks like:
http://i1075.photobucket.com/albums/w425/tajaros/Charge_zpsc64c7727.pnghttp://i1075.photobucket.com/albums/w425/tajaros/Headbutt_zps987595c3.png

And here's the code I used for the animation:
00 E3 27 00 E4 27 00 E5 27 0A 00 0C 0C 08 02 24 7B 3E 08 02 05 01 00 02 00 00 00 04 00 00 00 05 03 41 E5 0A 08 02 04 00 00 3C 00 02 00 0C 00 19 CE 00 C0 04 1E 19 CE 00 C0 04 1E 19 CE 00 C0 02 D4 61 3E 08 02 01 00 00 04 19 19 CE 00 C0 04 14 19 CE 00 C0 04 0F 19 CE 00 C0 04 0A 04 06 1C CE 00 C0 06 05 05 02 04 62 3E 08 02 03 00 00 10 00 10 00 04 02 02 04 62 3E 08 02 03 00 00 F0 FF F0 FF 19 70 00 C0 05 02 24 7B 3E 08 02 05 01 00 04 00 04 00 00 00 00 00 0B 00 0D 00 97 27 02 50 35 3E 08 02 01 00 00 19 9B 00 C0 05 04 02 02 50 35 3E 08 02 01 01 00 05 03 D1 8C 09 08 02 05 00 00 02 00 00 00 04 00 01 00 03 F9 89 09 08 02 05 01 00 05 00 00 00 06 00 01 00 02 50 35 3E 08 02 01 02 00 02 98 7C 3E 08 83 04 00 00 00 00 01 00 01 00 19 74 00 3F 05 08

So does anyone now how to edit the color of the charge animation? :3

Thundrake
February 9th, 2013, 10:04 PM
So does anyone now how to edit the color of the charge animation? :3

http://www.pokecommunity.com/showpost.php?p=7481054&postcount=32

It's all in this post.

tajaros
February 9th, 2013, 10:32 PM
http://www.pokecommunity.com/showpost.php?p=7481054&postcount=32

It's all in this post.

My bad for not seeing that, I'll edit my post out later and see what will happen... :)

MrDollSteak
February 9th, 2013, 11:28 PM
So i've found a rather interesting bug with one of my animations,
after implementing a new move animation into the new move slot,
for some reason whenever a target is poisoned, instead of displaying
the 'poison damage' they bullet punch themselves in the face.
Does anyone know where the poison damage might be located so
I can check for overlaps?

Edit: I can confirm this does not happen with burns, paralyz or anything else. Just the poison.

lcotvye
February 11th, 2013, 01:41 AM
My English is so bad……
It's nice,but I can't remember these codes.For example,05 0E C7 59 1D.Should I remember them for a long time?I want to make notes and read them when I do that.
Please give me some advice,thanks. :)

romancandle
February 11th, 2013, 12:54 PM
Has anyone come up with a X-Scissors animation? I keep playing with Fury Cutter, but everytime I think I get something working, tinkering a bit with it just makes it crash and not work. I can't even seem to successfully nail down the animation of the move itself, let alone make it play back to back, change the direction, or make them play at the same time.

MrDollSteak
February 11th, 2013, 06:09 PM
Has anyone come up with a X-Scissors animation? I keep playing with Fury Cutter, but everytime I think I get something working, tinkering a bit with it just makes it crash and not work. I can't even seem to successfully nail down the animation of the move itself, let alone make it play back to back, change the direction, or make them play at the same time.

I'd possibly play around with Leaf Blade. It has the X cut at the very end of the animation which you could merge with something.

romancandle
February 12th, 2013, 12:07 PM
I'd possibly play around with Leaf Blade. It has the X cut at the very end of the animation which you could merge with something.

Oh wow, I didn't know that. I never used Treecko and Bulbapedia had a still image. Good call. I'll combine it with, say, the Silver Wind background or something.

MrDollSteak
February 23rd, 2013, 12:28 AM
I've just been making a few more animations. I was trying to make scald and gunk shot from Hydro pump.
But I've noticed that moves like Hydro Pump and Sonic Boom that use repeating animations, don't follow the conventional structure 0f 02 xx xx xx 08, rather they seem to have animations that follow an 0E xx xx xx 08 structure, where xx xx xx 08 is a pointer to a table which is comprised of 02 xx xx xx 08. I've tried going to these locations and copying them to free space and repointing to that area, but this causes the animation to freeze. So this makes it difficult to change the palette. I was wondering if anyone knows more about this particular area.

EDIT: After some research, I've been able to successfully copy the 02 XX XX XX 08 data existing where the 0E xx xx xx 08 points to, and move it and change all the pointers. However when I copy the information at the pointer 02 xx xx xx 08 to a new offset and change the 02 xx xx xx 08 to point to that area that is when the animation freezes.

EDIT2: I'm an idiot. I was only copying 20 bytes as opposed to the 24 at 02 XX XX XX 08. It works now. So for those that want to change the colours or animation particles for a repeating animation such as Sonic Boom or Hydro Pump look for the 0E XX XX XX 08 pointer, and follow it to XX XX XX. Then copy the bytes from the start of that offset until you reach an F9 89 09 08. This signifies the end of the animation. Copy it to a new offset and change all the pointers. Then change the pointers in that to the 02 XX XX XX 08 animation in the new 0E XX XX XX 08 animation. Make sure to add the palette load at the beginning of the original animation. Sorry if I didn't explain this particularly well. It's a tad convoluted.

EDIT3: I've been doing some more research, and have found that by mixing Amnesia's background effect with different backgrounds such as the Dark type background, leads to some rather interesting combinations. It seems to take the palette and play a scrolling colour effect, which could be interesting for certain backgrounds.

HyperXhydra
February 27th, 2013, 04:09 PM
Someone must make a tool for this!

pawell6
February 28th, 2013, 03:01 AM
EDIT3: I've been doing some more research, and have found that by mixing Amnesia's background effect with different backgrounds such as the Dark type background, leads to some rather interesting combinations. It seems to take the palette and play a scrolling colour effect, which could be interesting for certain backgrounds.

Yeah, such animations give me creeps even If i want to change pallete only. About edit3 it sounds interesting, could you give some screenshots?

MrDollSteak
March 1st, 2013, 08:04 AM
Yeah, such animations give me creeps even If i want to change pallete only. About edit3 it sounds interesting, could you give some screenshots?

Sure!

Here's an example of Nasty Plot

http://www.romhackersonline.com/social/file/pic/photo/2013/02/0e310deb0e108569a36a3a45c68fe6c2_500.png

It uses the Dark Type background. As it shows it seems to take the first few colours and starts scrolling them from the middle to give an idea of movement. It only seems to work with scrolling backgrounds so far from what I've seen.

I currently don't have any more screenshots, but I'll take some more soon!

pawell6
March 3rd, 2013, 07:25 AM
Thanks for answer. 11bayerf1. After some testing I managed to find such BGs (for example see attachment). I used:

00 6D 27 0E XX XX XX 08 04 08 02 F4 6F 3E 08 14 00 19 B3 00 C0 04 36 1C B3 00 C0 10 03 05 0E C7 59 1D 08 08
where 0E XX XX XX 08 is a pointer to new location. At the location there should be:

14 09 16 03 F1 E6 0D 08 05 00 17 0F

Such code gives effect of ... how to call it - blinking or glowing.

Note: You can substitute 09 for any number from 00 to 1A for standard BGs or you even can insert number of custom BG. Also at the end there should be clearing command 0E C7 59 1D 08. If you change 09 to 00, you'll (probably) get BG from your first post.
It's possible to give that effect to colored BG. Example:

02 24 7B 3E 08 02 05 01 00 01 00 00 00 05 00 YY YY 05 00 6D 27 0E XX XX XX 08 04 08 02 F4 6F 3E 08 14 00 19 B3 00 C0 04 36 1C B3 00 C0 10 03 05 0E C7 59 1D 08 08
where YY YY color, 0E XX XX XX 08 is a pointer to new location. At the location there should be:

03 F1 E6 0D 08 05 00 17 0F

knizz
March 3rd, 2013, 03:12 PM
I think I didn't explain my earlier post (http://www.pokecommunity.com/showpost.php?p=7529819&postcount=64) properly. It is a list of commands for this animation-bytecode and the format of their arguments. "1C xxxx xx xx xx" = "The command 1C is followed by four arguments that are 2, 1, 1 and 1 bytes wide respectively."
I'll demonstrate it using this code by tajaros (http://www.pokecommunity.com/showpost.php?p=7529857&postcount=65) as example:

00 E3 27 00 E4 27 00 E5 27 0A 00 0C 0C 08 02 24 7B 3E 08 02 05 01 00 02 00
00 00 04 00 00 00 05 03 41 E5 0A 08 02 04 00 00 3C 00 02 00 0C 00 19 CE 00
C0 04 1E 19 CE 00 C0 04 1E 19 CE 00 C0 02 D4 61 3E 08 02 01 00 00 04 19 19
CE 00 C0 04 14 19 CE 00 C0 04 0F 19 CE 00 C0 04 0A 04 06 1C CE 00 C0 06 05
05 02 04 62 3E 08 02 03 00 00 10 00 10 00 04 02 02 04 62 3E 08 02 03 00 00
F0 FF F0 FF 19 70 00 C0 05 02 24 7B 3E 08 02 05 01 00 04 00 04 00 00 00 00
00 0B 00 0D 00 97 27 02 50 35 3E 08 02 01 00 00 19 9B 00 C0 05 04 02 02 50
35 3E 08 02 01 01 00 05 03 D1 8C 09 08 02 05 00 00 02 00 00 00 04 00 01 00
03 F9 89 09 08 02 05 01 00 05 00 00 00 06 00 01 00 02 50 35 3E 08 02 01 02
00 02 98 7C 3E 08 83 04 00 00 00 00 01 00 01 00 19 74 00 3F 05 08
Formatted code
00 27E3
00 27E4
00 27E5
0A 00
0C 080C
02 083E7B24 02 05
0001
0002
0000
0004
0000
05
03 080AE541 02 04
0000
003C
0002
000C
19 00CE C0
04 1E
19 00CE C0
04 1E
19 00CE C0
02 083E61D4 02 01
0000
04 19
19 00CE C0
04 14
19 00CE C0
04 0F
19 00CE C0
04 0A
04 06
1C 00CE C0 06 05
05
02 083E6204 02 03
0000
0010
0010
04 02
02 083E6204 02 03
0000
FFF0
FFF0
19 0070 C0
05
02 083E7B24 02 05
0001
0004
0004
0000
0000
0B 00
0D
00 2797
02 083E3550 02 01
0000
19 009B C0
05
04 02
02 083E3550 02 01
0001
05
03 08098CD1 02 05
0000
0002
0000
0004
0001
03 080989F9 02 05
01 00
05 00
00 00
06 00
01 00
02 083E3550 02 01
0002
02 083E7C98 83 04
00 00
00 00
01 00
01 00
19 0074 3F
05
08
Arguments of the 02 command:
083E7B24: objtemplate
unknown1 0000
unknown2 0000
oamdata 08231CE4 (=oam_empty)
animtbl1 08231CF0 (=animtable_empty_1)
gfxtbl 00000000
animtbl2 08231CFC (=animtable_empty_2)
callback 080B99D4083E61D4: objtemplate
unknown1 27E4
unknown2 27E4
oamdata 083ACB60
animtbl1 08231CF0 (=animtable_empty_1)
gfxtbl 00000000
animtbl2 083E61C8
[0] 083E6138
0010 0010
0000 0000
0004 0004
3C00 0000
0100 0100
0000 0000
7FFD 0000
0000 0000
FFFC FFFC
0500 0000
0004 0004
0500 0000
7FFD 000A
0000 0000
7FFF 0000
0000 0000
[1] 083E6178
0010 0010
0000 0000
0008 0008
1E00 0000
0100 0100
0000 0000
FFFC FFFC
0500 0000
0004 0004
0500 0000
7FFE 0003
0000 0000
[2] 083E61A8
0010 0010
0000 0000
0008 0008
1E00 0000
FFF8 FFF8
1E00 0000
7FFF 0000
0000 0000
callback 080AE71C083E6204: objtemplate
unknown1 27E5
unknown2 27E5
oamdata 083AC9D8
animtbl1 083E6200
[0] 083E61EC
0000 0003
0010 0003
0020 0003
0030 0003
FFFF 0000
gfxtbl 00000000
animtbl2 08231CFC (=animtable_empty_2)
callback 080AE774083E3550: objtemplate
unknown1 0000
unknown2 0000
oamdata 08231CE4 (=oam_empty)
animtbl1 08231CF0 (=animtable_empty_1)
gfxtbl 00000000
animtbl2 08231CFC (=animtable_empty_2)
callback 080A5340083E7C98: objtemplate
unknown1 0x2797
unknown2 0x2797
oamdata 083ACA38
animtbl1 08231CF0 (=animtable_empty_1)
gfxtbl 00000000
animtbl2 083E7BF8
[0] 083E7BA0

[1] 083E7BB0

[2] 083E7BC8

[3] 083E7BE0

callback 080BA780

takeKopter
March 6th, 2013, 09:30 PM
oh my, this is a very good tutorial.
last night I decided to give it a try, and I made one.
here's animation for Roost

00 1E 28 0A 03 29 19 C3 00 3F 04 00 02 00 6C 3E 08 80 08 00 00 F0 FF 40 00 02 00 68 00 28 2C 20 00 01 00 04 06 02 00 6C 3E 08 80 08 00 00 F0 FF 20 00 02 00 68 00 28 2C 20 00 01 00 02 00 6C 3E 08 80 08 00 00 F0 FF 00 00 02 00 68 00 28 2C 20 00 01 00 04 06 02 00 6C 3E 08 80 08 00 00 F0 FF E0 00 02 00 68 00 28 2C 20 00 01 00 02 00 6C 3E 08 80 08 00 00 F0 FF 80 00 02 00 68 00 28 2C 20 00 01 00 04 06 02 00 6C 3E 08 80 08 00 00 F0 FF C0 00 02 00 68 00 28 2C 20 00 01 00 02 00 6C 3E 08 80 08 00 00 F0 FF A0 00 02 00 68 00 28 2C 20 00 01 00 04 06 02 00 6C 3E 08 80 08 00 00 F0 FF 60 00 02 00 68 00 28 2C 20 00 01 00 05 0B 03 00 2F 27 0E C9 56 1D 08 05 08

needed bytes = 217

don't forget to set "target" -> "user" in attack editor. :)

MrDollSteak
March 8th, 2013, 11:00 PM
I can now confirm that it is possible to create custom battle backgrounds by expanding the battle background table:
http://i49.tinypic.com/4trcow.png

http://i47.tinypic.com/2zy8qwi.png
This custom battle background takes up slot 0x1B (which does not exist in the original FireRed rom)

The table starts at 0x3ADE18, and ends at 0x3ADF5B. There's another table right after it, which I mistook as part of the same table, so just remember that it ends at 0x3ADF5B, even though it looks like it doesn't.

I inserted my tileset, palette, and tilemap all with unLZ (I made the tilemap with NTME). Simply insert into free space, then manually point to the offsets you used in your new table with a hex editor.


For anyone that wants to experiment, here is my tileset and tilemap (the palette is included within the tileset because it's indexed). To test it, insert these with unLZ, keep track of the offsets you inserted the tileset, palette, and tilemap, then repoint and expand the table (make sure you don't mistake the table right after it as part of the original table!!! just look at the start and end offsets I gave earlier in this post), then have the new entries in the table point to your tileset, palette, and tilemap, then make a custom battle animation (or edit an existing one) and use the background slot 0x1B. And yes, I designed the graphics so that it can scroll horizontally.

This is an amazing discovery, I looked at this before but didn't decide to implement it until now! Just a few questions, each background has 12 bytes, obviously pointers to the tileset, palette and tilemap. I was just wondering if the 3 pointers are respective to that order, ie. is the first pointer the pointer to the tileset etc.?
Also is there a specific limit to how many extra backgrounds you have? and finally, do they have to be 16 colours? I'm assuming they do, but with any luck they might not.

Thanks so much for your help!

tajaros
March 8th, 2013, 11:05 PM
This is an amazing discovery, I looked at this before but didn't decide to implement it until now! Just a few questions, each background has 12 bytes, obviously pointers to the tileset, palette and tilemap. I was just wondering if the 3 pointers are respective to that order, ie. is the first pointer the pointer to the tileset etc.?
Also is there a specific limit to how many extra backgrounds you have? and finally, do they have to be 16 colours? I'm assuming they do, but with any luck they might not.

Thanks so much for your help!

Dude, I made a tut for this already, and you still saw it here haha... xD http://www.pokecommunity.com/showthread.php?t=296865

Yes, they are respectively in that order.

All images to be inserted in the ROM should be 16 colors just for you to know. I think you can have at least 255 backgrounds though I only have managed to have 0x25 backgrounds in my game.

MrDollSteak
March 9th, 2013, 02:34 AM
Dude, I made a tut for this already, and you still saw it here haha... xD http://www.pokecommunity.com/showthread.php?t=296865

Yes, they are respectively in that order.

All images to be inserted in the ROM should be 16 colors just for you to know. I think you can have at least 255 backgrounds though I only have managed to have 0x25 backgrounds in my game.

Ha! I didn't see your tutorial at all. I managed to put it all in without problems before, I just wasn't sure about the order, thanks for clarifying that though.

Aryan143
March 31st, 2013, 05:04 AM
Hello everyone, I am new to this tutorial. I want to make a Hammer Arm by having Karate Chop animation and 04 (Focus Punch) background. I found the start offset for the Karate Chop animation but how can I find the end offset for the animation? Please help.

toasterr
March 31st, 2013, 07:48 AM
Finding the end of an animation is normally trial and error - your best bet is to grab a bunch of bytes starting at Karate Chop's offset, paste them into free space (FF bytes) and repoint Karate Chop's pointer in the table to where you posted the edited bytes, open up GBA's Memory Viewer (Tools > Memory Viewer), and test the move. If it runs properly, it's likely you've grabbed too much, so head to the offset (note that it's prefaced with an 08 here, so for example if your animation is at 0xXXYYZZ, it would be 0x08XXYYZZ here) and replace bytes at the end with FF until you overwrite an 08 byte, refresh and retry. Do this until your animation resets at the end - this means your animation is what you have left, plus an 08 at the end (normally). If it freezes mid animation, you've deleted too much, so restart and try again.

Some animations don't end in a 08 byte; however, I'm pretty sure Karate Chop isn't one of them. It seems difficult at first but if you're editing a bunch you'll quickly get the hang of it.

I have a question of a different sort. I created an Aqua Tail animation:

00 A4 27 00 AB 27 00 9D 27 0A 03 0C 0C 08 03 F9 89 09 08 05 05 00 00 00 00 02 00 17 00 01 00 04 05 19 87 00 C0 02 B0 5A 3E 08 02 04 0A 00 0A 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 F1 FF 00 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 14 00 0A 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 00 00 F6 FF 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 F6 FF 0F 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 19 00 14 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 EC FF 14 00 19 00 00 00 04 04 19 87 00 C0 02 B0 5A 3E 08 02 04 0C 00 00 00 19 00 00 00 05 0E A9 8A 1C 08

It's essentially the water-bubbles from Waterfall's code, followed by an 0E pointer to the Slam animation (underlined for clarity). It mostly works; however, if a mon uses this in battle and then something levels up, the game freezes after trying to load the stats summary box. Also, certain graphics, such as the status-drop animations and the move menu (in battle) become borked until the battle ends. Is this because I have too many 00 XX 27 structures? I've been working on this for a few hours and can't seem to fix the problem.

Aryan143
March 31st, 2013, 08:11 AM
Thanks a lot for your help!

MrDollSteak
April 5th, 2013, 10:31 PM
It's essentially the water-bubbles from Waterfall's code, followed by an 0E pointer to the Slam animation (underlined for clarity). It mostly works; however, if a mon uses this in battle and then something levels up, the game freezes after trying to load the stats summary box. Also, certain graphics, such as the status-drop animations and the move menu (in battle) become borked until the battle ends. Is this because I have too many 00 XX 27 structures? I've been working on this for a few hours and can't seem to fix the problem.

I think this is due to the 0E pointer to slam animation more than anything. Because 0E animations point to repeating animations, and aren't the end to the script. To be honest if I were you i'd just remove to 0E pointer and put the slam animation in there. That's what I've done for my Aqua Tail code and it doesn't have any problems like that.

The Legacy of The Legends Creator :D
April 7th, 2013, 01:50 PM
Im just skimming through the topics, and i havent read all of this one, but is there a topic to create your own attacks? is there a guide somewhere, if this isnt one, like i said didnt read it all xD </3

karatekid552
April 7th, 2013, 02:42 PM
Im just skimming through the topics, and i havent read all of this one, but is there a topic to create your own attacks? is there a guide somewhere, if this isnt one, like i said didnt read it all xD </3

By "create your own attacks" what exactly are you referring to? This thread is all about creating new animations for attacks.

- If you wanted to make your own attack or bring in a Gen IV/V attack and the options in PGE are not enough, then you will have to learn how to Battle Script from Jambo's tutorial.

-If you just want to make new animations, then you should read the whole first post of this thread, and then skim most of the rest of the thread.

-If you want to increase the number of in-game attacks, there a couple of tutorials/researches for that.

The Legacy of The Legends Creator :D
April 7th, 2013, 03:40 PM
I am hoping to create new attacks with new animations, bring later gen attacks like Darkrais special attack, and such.

karatekid552
April 7th, 2013, 03:43 PM
I am hoping to create new attacks with new animations, bring later gen attacks like Darkrais special attack, and such.

Well then, do all three of the things I listed above!

The Legacy of The Legends Creator :D
April 7th, 2013, 03:48 PM
lol thank you, i will look into em

There was a topic on adding new moves, and it showed and offset location that i didnt have.

When i look for the 00250c04 i have
00250bff
then it goes to
00250c08 is that ok?

bradyroush
April 11th, 2013, 09:31 AM
Has anyone posted/found the animation pointer in a Ruby ROM?

The hack that I'm working on is for Ruby and it would be extremely helpful

dreamengine
April 11th, 2013, 11:38 PM
So I was doing so quick research for Ruby and this is what I got.

Animation Pointer: 1C7168

I think for the most part the structure is the same the only thing that differs are pointers

Scrolling background command

14 WW 17 03 59 3A 0E 08 05 04 00 XX 00 YY ZZ 00 FF FF

Psychic Scrolling Background

0E E7 61 1D 08

End a scrolling background(works with the psychic one)

0E F3 61 1D 08

For now this is enough to make decent animations with Ruby. Like I said things are almost exactly the same as Fire Red except for these few pointer changes

chaosakita
April 15th, 2013, 06:55 PM
In one hack I saw, apparently the animation for Fury Attack was replaced with knives. How would one replicate this? Sorry, I don't have link posting permissions yet.

Shadowraze
April 15th, 2013, 07:05 PM
In one hack I saw, apparently the animation for Fury Attack was replaced with knives. How would one replicate this? Sorry, I don't have link posting permissions yet.

He probably changed the animation image in unlz with knives. So just try to find the fury attack image in UNLZ and replace it with whatever you want. But it's still not granted to work.

chaosakita
April 15th, 2013, 08:29 PM
He probably changed the animation image in unlz with knives. So just try to find the fury attack image in UNLZ and replace it with whatever you want. But it's still not granted to work.

I found the knives image in UNLZ and it was the last image on the rom. However, the fury attack image is not the same location on a regular Fire Red rom.

Shadowraze
April 15th, 2013, 08:38 PM
I found the knives image in UNLZ and it was the last image on the rom. However, the fury attack image is not the same location on a regular Fire Red rom.

Well because it differs maybe you inserted some sprites in the game already that caused the images to shift places in UNLZ.

chaosakita
April 15th, 2013, 09:00 PM
Well because it differs maybe you inserted some sprites in the game already that caused the images to shift places in UNLZ.

No, I have not inserted anything in either rom.

robin22gongon
April 20th, 2013, 10:39 PM
How do I determine how long an animation code is?

Shadowraze
April 20th, 2013, 10:46 PM
How do I determine how long an animation code is?

Just copy paste an amount of code and put it to free-space and test the animation. If it's working then good although it can work if you put remove some more bytes so remove the unnecessary bytes as much as possible. If I remember right animations start with E0 Correct me If I'm wrong please.. And if the animation is not working copy paste remaining codes per E0.

MrDollSteak
April 21st, 2013, 12:42 AM
Just copy paste an amount of code and put it to free-space and test the animation. If it's working then good although it can work if you put remove some more bytes so remove the unnecessary bytes as much as possible. If I remember right animations start with E0 Correct me If I'm wrong please.. And if the animation is not working copy paste remaining codes per E0.

Most animations start with 00 XX 27 or 00 XX 28. What I would do is just search for the bytes 08 00 and once you reach one that looks like 08 00 XX 27 or 28 chances are you're in the right place.

robin22gongon
April 21st, 2013, 01:17 AM
So I would go to the animation pointer and then most likely, when I see 08 00 XX 27 or 28, that's the end of the code?

MrDollSteak
April 21st, 2013, 05:51 AM
So I would go to the animation pointer and then most likely, when I see 08 00 XX 27 or 28, that's the end of the code?

Yup. Go to the start of the move you want and just search for 08 00 in your hex editor and keep going until you see that. The XX will be different every time. That's just a placeholder. There are some occasions where this isn't the end of the code, but as a general rule it's pretty good.

mohammadfaizan
April 21st, 2013, 05:59 AM
I extra toon repointing for the episode editor with PGE 2 or 3 weeks in the past but simply haven't much launched your up-date. There's no need for like sophisticated guidelines about repointing.

robin22gongon
April 23rd, 2013, 05:29 PM
Hey guys! Quick question. What's the complete code for the Pound or Tackle's Animation?

Shadowraze
April 23rd, 2013, 07:24 PM
Hey guys! Quick question. What's the complete code for the Pound or Tackle's Animation?

You know you can just follow the animation pointer from PGE and get the animation yourself by cutting through every 08.

Anyways, here's your animation.

Pound
00 97 27 0A 01 0C 0C 08 19 7F 00 3F 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 03 F9 89 09 08 02 05 01 00 03 00 00 00 06 00 01 00 05 0B 01 0D 08

Tackle
00 97 27 0A 01 0C 0C 08 02 54 4E 3D 08 02 02 04 00 04 00 04 06 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 03 F9 89 09 08 02 05 01 00 03 00 00 00 06 00 01 00 19 84 00 3F 05 0B 01 0D 08

robin22gongon
April 23rd, 2013, 09:10 PM
If I use the command for a Non-scrolling BG, do I still have to use
0E C7 59 1D 08

Or do I just have to put this at the end?
0E C7 59 1D 08

EDIT: Sorry they were the same codes.

dreamengine
April 23rd, 2013, 09:18 PM
If I use the command for a Non-scrolling BG, do I still have to use
0E C7 59 1D 08

Or do I just have to put this at the end?
0E C7 59 1D 08

Please try to read through the whole thread before asking. I know for a fact that this has been stated by DoesntKnowHowToPlay. Anyways, the answer is yes. Where you would put 0E C7 59 1D 08, instead put 15 17 or 15 16.

dreamengine
April 27th, 2013, 12:35 PM
Well I'm back with some more interesting stuff. Sorry for the double post, but I just felt this needed a separate post. In terms of Battle backgrounds, there are a few that change depending on the user of the move. For example in hyper fang, when you're the one using it then background is number 04, but when the opponent uses it, it becomes 05. I did some research and found out how to do that, but your own custom backgrounds you inserted.

Still Background Version 1

Simply insert the following code somewhere, and instead of using 14 XX 17 to load a background use a 0E command pointing to this code.

04 02 03 2D C0 0B 08 02 00 21 07 01 00 C0 7D 1C 08 03 B5 EA 0D 08 02 00 21 07 00 00 B2 7D 1C 08 21 07 01 00 B9 7D 1C 08 0F 18 XX 13 B1 7D 1C 08 18 YY 13 B1 7D 1C 08 18 ZZ 13 B1 7D 1C 08

XX - background number when user attacks
YY - background number when the opponent attacks
ZZ - background number when targeting other opponent in double battle? Not sure.

Scrolling Backgrounds

Now, I also figured out how to do the same with scrolling backgrounds. It's actually much more simple than still backgrounds, but can be applied to still backgrounds as well.

First off here is our code for the scrolling background

03 21 B9 0B 08 02 00 21 07 01 00 UU UU UU 08 14 WW 17 03 2D B8 0B 08 05 04 00 XX 00 YY ZZ 00 FF FF

UU UU UU is a pointer to 14 VV 13 TT TT TT 08
TT TT TT is a pointer to 17
VV - the background number of the BG when opponent uses attack
WW - the background number of the BG when the user attacks
XX - how fast background scrolls horizontally
YY - how fast background scrolls vertically
ZZ - either 00(scrolls right) or 01(scrolls left) but only applies to when the opponent uses the move

Note* The tricky part with this is that you can't put the code just anywhere like you can with a regular scrolling BG. This one has must go after 00 XX 27 or 00 XX 28 at some point. Usually it goes immediately after.

Still Backgrounds Version 2

Now, I found out the scrolling method after version one of the still backgrounds. Version two is pretty much the same as scrolling.

Here's the code

03 21 B9 0B 08 02 00 21 07 01 00 UU UU UU 08 14 WW 17

UU UU UU is a pointer to 14 VV 13 TT TT TT 08
TT TT TT is a pointer to 17
VV - the background number of the BG when opponent uses attack
WW - the background number of the BG when the user attacks

MrDollSteak
April 28th, 2013, 08:15 PM
I've been thinking about the palettes assigned to certain XX 27 or XX 28 commands, and wondering how the colours themselves are stored, and how to go about finding these palettes. The reason why I ask this, is that theoretically once we find how the game goes about assigning palettes to these commands we should either be able to edit the colours assigned to these bytes, or better yet to create new palettes. From what I've seen so far, there should be more than enough space to do this, because the XX 28 commands themselves do not go much further than 2D 28, which in theory would be an index of 28 2D, so realistically we could create ones at higher levels such as 4F 28. We should also in theory be able to assign particles to these commands as well, which may make adding new particles possible.

All of this is theoretical of course, I haven't been able to find such tables. For all I know they may even be hard coded. I just thought it was food for thought, and hopefully someone with more knowledge may be able to offer some insight into this.

rhettz_emboar
May 28th, 2013, 03:16 AM
Hey! Thanks for this great Tut. Think im gonna try it.
But I'm a lot confused and failing a lot. I really dont have any knowledge on hex editing,Though

Anyway I'm gonna try my best {:3}

chaosakita
June 10th, 2013, 03:36 PM
I really like some of the move animations for the custom moves in Pokemon Vega. I wonder how you could port those moves to the English version. And it seems like the Japanese are much more ahead in creating custom move animations in general.

Here is an example, Focus Blast (http://youtu.be/jbQP4--Z0Vg?t=1m14s): it uses background 11 and something similar to Luster Purge, I guess. I think I'll try to document more of these custom moves for reference if it's allowed.

pawell6
June 17th, 2013, 01:27 PM
Hey guys, while playing pokemon vega I noticed that creator took particles from rockslide and made it move like in icy wind. After some reasearch I figured out how to do it. Lets say we want leaves from razor leaf to move like fire in flamethrower.
1. First we look for animation code for flamethrower:
[S-HIGHLIGHT]00 2D 27 0A 03 28 01 0C 0C 08 03 F9 89 09 08 05 05 00 00 00 00 02 00 2E 00 01 00 04 06 03 01 B1 0A 08 05 01 64 00 1B 8B 00 C0 3F 02 00 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 03 F9 89 09 08 05 05 01 00 03 00 00 00 2B 00 01 00 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 05 0B 03 0D 08[/S-HIGHLIGHT]
2. We look for 02 commands (animation load). There are none, so those commands are hidden in 0E command: 0E 8F FA 1C. We go to offset 1CFA8F:
02 D0 59 3E 08 03 04 0A 00 0A 00 00 00 10 00 04 02 02 D0 59 3E 08 03 04 0A 00 0A 00 00 00 10 00 04 02 0F(0F indicates return to original animation). Copy it and paste in new loaction. Don't forget to change pointers in 0E command according to your new location. Anyway we have 02 D0 59 3E 08. Offset 3E59D0:
2D 27 2D 27 D8 C9 3A 08 CC 59 3E 08 00 00 00 00 FC 1C 23 08 25 B0 0A 08This is fire particle. Repoint it to another location. Don't forget to change pointers in 02 command according to your new location. Bold part is important.
3. Now we look for leaf partice in razor leaf code animation. Its poniter is right behind 02 command: 02 08 2C 3E 08. Offset 3E2C08:

4F 27 4F 27 D0 C9 3A 08 00 2C 3E 08 00 00 00 00 FC 1C 23 08 A5 2A 0A 08Then we replace part of code from point 2 with bold part from point 3. Of course you have to add 00 4F 27 to the begining of the code.

4. So the final code is:

00 2D 27 00 4F 27 0A 03 28 01 0C 0C 08 03 F9 89 09 08 05 05 00 00 00 00 02 00 2E 00 01 00 04 06 03 01 B1 0A 08 05 01 64 00 1B 8B 00 C0 3F 02 00 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 03 F9 89 09 08 05 05 01 00 03 00 00 00 2B 00 01 00 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 0E XX YY ZZ 08 05 0B 03 0D 08
Offset XX YY ZZ:
02 XX2 YY2 ZZ2 08 03 04 0A 00 0A 00 00 00 10 00 04 02 02 XX2 YY2 ZZ2 08 03 04 0A 00 0A 00 00 00 10 00 04 02 0F
Offset XX2 YY2 ZZ2:
4F 27 4F 27 D0 C9 3A 08 00 2C 3E 08 00 00 00 00 FC 1C 23 08 25 B0 0A 08

karatekid552
June 17th, 2013, 03:01 PM
Hey guys, while playing pokemon vega I noticed that creator took particles from rockslide and made it move like in icy wind. After some reasearch I figured out how to do it. Lets say we want leaves from razor leaf to move like fire in flamethrower.
1. First we look for animation code for flamethrower:
[S-HIGHLIGHT]00 2D 27 0A 03 28 01 0C 0C 08 03 F9 89 09 08 05 05 00 00 00 00 02 00 2E 00 01 00 04 06 03 01 B1 0A 08 05 01 64 00 1B 8B 00 C0 3F 02 00 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 03 F9 89 09 08 05 05 01 00 03 00 00 00 2B 00 01 00 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 0E 8F FA 1C 08 05 0B 03 0D 08[/S-HIGHLIGHT]
2. We look for 02 commands (animation load). There are none, so those commands are hidden in 0E command: 0E 8F FA 1C. We go to offset 1CFA8F:
(0F indicates return to original animation). Copy it and paste in new loaction. Don't forget to change pointers in 0E command according to your new location. Anyway we have 02 D0 59 3E 08. Offset 3E59D0:
This is fire particle. Repoint it to another location. Don't forget to change pointers in 02 command according to your new location. Bold part is important.
3. Now we look for leaf partice in razor leaf code animation. Its poniter is right behind 02 command: 02 08 2C 3E 08. Offset 3E2C08:

Then we replace part of code from point 2 with bold part from point 3. Of course you have to add 00 4F 27 to the begining of the code.

4. So the final code is:

Should I inform you that we are already starting research on particle effects?

http://www.romhackersonline.com/social/discussions/thread/225/creating-new-particle-effects/

franx93
July 29th, 2013, 10:50 PM
Hey guys, I'm new here, I'm from Argentina so I apologize for my bad English :(

I'd been doing some "hack", and i'm stuck with a "Bullet Punch" script.

I read the entire post and I can't fix the problem!

I'm making some new moves with the existing graphics, in the next code there are codes from "Iron Defense", "Mega Punch" and the speed background, the problem is that the background remains and I don't know where is the mistake (I really know that I may have lots of errors, but it's my first try)

Here's what I have:

BULLET PUNCH:
14 09 17 03 2D B8 0B 08 05 04 00 0F 00 00 01 00 FF FF 1C 5F 00 C0 1C 02 03 ED 86 0B 08 05 03 00 00 00 00 00 00 02 3C 7B 3E 08 02 07 01 00 08 00 02 00 FF FF 0E 00 FF FF 00 00 05 00 97 27 00 9F 27 0A 01 0C 0C 08 11 91 7E 1C 08 0E C7 51 1D 08 08

Another one, "Drain punch", I want to use "Mega punch" and "Leech Life" but i have to remove the pin in the leech life animation, I don't know how! Also, the same problem with the "Mega punch" animation, i don't know how to add something after it!

The "Leech life" animation (don't know if this is ALL the code, maybe it's shorter):

00 B1 27 00 A3 27 04 01 00 2F 27 00 97 27 0A 03 2A 01 0C 0C 08 04 01 02 78 72 3E 08 02 03 EC FF 0F 00 0C 00 05 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 19 AD 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 05 00 01 00 05 02 24 7B 3E 08 02 05 01 00 01 00 00 00 07 00 00 00 05 0E 44 EC 1C 08 05 04 0F 0E C9 56 1D 08 05 02 24 7B 3E 08 02 05 01 00 01 00 07 00 00 00 00 00 05 0B 03 0D 08



EXTRA:
NIGHT PULSE:
14 00 17 00 B4 27 03 1D 8B 09 08 02 05 00 00 03 00 00 00 02 00 01 00 0E E8 75 1C 08 0E E8 75 1C 08 04 10 03 05 97 09 08 05 05 00 00 06 00 00 08 02 00 01 00 05 0E C7 59 1D 08 08

"Screech" and Night background (00)


Saludos desde Argentina :)

Enigmatic Emolga
July 31st, 2013, 08:44 AM
I'm trying to make Shadow Force in Fire Red using Charmander as a test and Fly as a base. Problem is, I can't tell where the complete Fly animation ends because of all the 08s! Bacause of this, after adding a background, it won't go away, which is quite frustrating as I have no idea which 08 to end on! Is there a way to tell the end of two-turned animations? If not, is there at least a Fly script for me to work off of?

Also, with Attack effect 155, my attack says "********** dug a hole!" even though Fly has the exact same effect and says something different! Is there a way to expand the table to include other quotes like "********** vanished!" and implement them into new moves?

pawell6
July 31st, 2013, 10:35 AM
@franx93, I think I can help you. Animation for bullet punch:
14 09 17 03 2D B8 0B 08 05 04 00 0F 00 00 01 00 FF FF 1C 5F 00 C0 1C 02 03 ED 86 0B 08 05 03 00 00 00 00 00 00 02 3C 7B 3E 08 02 07 01 00 08 00 02 00 FF FF 0E 00 FF FF 00 00 05 00 97 27 00 9F 27 0A 01 0C 0C 08 02 08 7C 3E 08 02 04 F8 FF F8 FF 01 00 02 00 02 10 67 3E 08 03 05 F8 FF 00 00 08 00 01 00 00 00 03 F9 89 09 08 02 05 01 00 03 00 00 00 06 00 01 00 19 84 00 3F 05 0B 01 0D 05 0E C7 59 1D 08 08First of all clearing command is 0E C7 59 1D 08, not 0E C7 51 1D 08. Next in your code there is command 11 91 7E 1C 08,which jumps to offset 1C7E91, so clearing command isn't executed. So you should copy data animation from the offset and replace it with 11 command (but there is also next jump command 13 77 7E 1C 08 which should be replaced with data from offset 1C7E77).
Animation with removed pin:
00 B1 27 00 A3 27 04 01 00 2F 27 00 97 27 0A 03 2A 01 0C 0C 08 04 01 02 08 7C 3E 08 02 04 00 00 00 00 01 00 02 00 19 AD 00 3F 04 02 03 F9 89 09 08 05 05 01 00 00 00 05 00 05 00 01 00 05 02 24 7B 3E 08 02 05 01 00 01 00 00 00 07 00 00 00 05 0E 44 EC 1C 08 05 04 0F 0E C9 56 1D 08 05 02 24 7B 3E 08 02 05 01 00 01 00 07 00 00 00 00 00 05 0B 03 0D 08where 02 78 72 3E 08 02 03 EC FF 0F 00 0C 00 was removed. You can easily identify the particle:
in the last code there is 02 XX XX XX 08 YY ZZ, where XX XX XX is a pointer, YY byte of uknown meaning and ZZ is a byte which indicates how long is code: next 2*ZZ bytes belong to that particle. After that usually there is next particle (starts with 02), 05 command, 04 TT (waiting command, TT is waitng time) , some sound command (19, 1C or 1D) or 0E command. In our example ZZ is 03 so next 6 bytes belong to the particle (EC FF 0F 00 0C 00).

Edit: The same rule aplies to 03 XX XX XX 08 command, which usually shakes sprites or loads different animation.

Ultraxwing
July 31st, 2013, 11:37 AM
Hello, i'm working on a project that i wish to keep secret as for now. i have the PGE and it has the animation pointer. i do understand Hex, well enough how could i go about using that seeing how i make many mistakes involving hex, though i do plenty of backups. is there any way of using what might be considerably easier. or is this method much preferred? Mind you i would much prefer the animation pointer versus this to be 100% honest.

Enigmatic Emolga
August 1st, 2013, 01:24 AM
Okay, so we know how to add backgrounds to attacks, but what about removing them?

From what I can gather, this is Luster Purge's animation.
00 1B 28 00 97 27 14 03 16 03 B5 E7 0D 08 05 00 17 0A 00 0C 0C 08 19 C2 00 C0 02 48 71 3E 08 29 04 00 00 00 00 00 00 00 00 04 14 03 3D A8 0B 08 05 05 05 00 02 00 00 00 10 00 FF FF 03 21 AA 0B 08 05 05 1B 28 02 00 00 00 10 00 FF FF 05 03 21 AA 0B 08 05 05 97 27 00 00 0C 00 0C 00 00 5C 05 02 50 7C 3E 08 83 02 01 00 02 00 03 DD D3 0D 08 05 02 D0 00 3F 00 04 03 02 50 7C 3E 08 83 02 01 00 02 00 03 DD D3 0D 08 05 02 D0 00 3F 00 04 03 02 50 7C 3E 08 83 02 01 00 02 00 03 DD D3 0D 08 05 02 D0 00 3F 00 04 03 02 50 7C 3E 08 83 02 01 00 02 00 03 DD D3 0D 08 05 02 D0 00 3F 00 04 03 02 50 7C 3E 08 83 02 01 00 02 00 03 DD D3 0D 08 05 02 D0 00 3F 00 04 03 02 50 7C 3E 08 83 02 01 00 02 00 03 DD D3 0D 08 05 02 D0 00 3F 00 05 03 3D A8 0B 08 05 05 05 00 02 00 10 00 00 00 FF FF 03 B5 94 0B 08 05 03 01 00 05 00 0E 00 05 0B 00 0D 0E C7 59 1D 08 08The highlighted values are the background codes. I copied the code into an empty area, removed the background codes, repointed the attack animation data and tested. The game crashed and reset. Is there something more to this, or do I need to replace the BG codes with FF and not close the gaps?

EDIT: Just noticed something else. Merely copying the animation and pasting it makes the game crash if the copy is used. -_-

franx93
August 1st, 2013, 03:25 PM
@pawell6 Thaaaaanks, you're a hero! I find it quiet difficult to learn this because of the lenguaje.
Thanks again!! :)

xGal
August 4th, 2013, 09:25 AM
EDIT: Figured it out, I am so dumb...

See more on VM :/

misterpoor
December 14th, 2013, 09:06 PM
I'm a newbie and the tutorial is too advanced for me to understand. Could somebody please guide me easier to understand? Such as where must I put these code?

wael96
January 18th, 2014, 06:18 AM
Well, I am a still a beginner now, which tutorial should I read first in order to understand this tutorial?

Flower
January 18th, 2014, 10:43 AM
Well, I am a still a beginner now, which tutorial should I read first in order to understand this tutorial?

First post I believe. lol

Leafbarrett
February 5th, 2014, 06:11 AM
So, if nobody else is going to try to help out Emerald hackers, I guess I'll do my bit. Just don't be mad if I get literally everything wrong, because I haven't got a ****ing clue what I'm doing - I'm just blindly stumbling around, trying to search for the non-pointer byte patterns from this tutorial. I'd appreciate it if Chaos Rush would put this stuff in the OP, so other people don't have to guess at this stuff, but...

14 WW 16 03 61 76 11 08 05 04 00 XX 00 YY ZZ 00 FF FF
The fragment of hex used in Emerald for background movement (the pointer is different). All the background IDs are still accurate. Haven't tested, but I presume replacing 16 with 17 has the same effect as in Fire Red.

As a side note, because I couldn't for the life of me find any information for this, the pointer for the second animation for Sky Attack is 2CD28E in Emerald. Still no idea where Skull Bash is.

Artemis64
March 1st, 2014, 08:04 PM
For Ruby hackers, the command to clear background is 0E F3 61 1D 08 before you add the 08 byte at the end.
Most of Chaos Rush's commands work, except for any command with an "08" (pointer) inside.

Edit: I found the commands. They are:
14 XX 17 03 59 3A 0E 08 05 04 00 00 00 YY 0Z 00 00 FF FF (Scrolling BG Left-to-Right)
14 XX 17 03 59 3A 0E 08 05 04 00 00 00 YY FZ 00 00 FF FF (Scrolling BG Right-to-Left)

Now, I would like some help with finding the Psychic Background command for Ruby.

Crazy_chu
March 19th, 2014, 12:17 AM
i confused X.X can you make a video about it?
please..

HidoranBlaze
April 6th, 2014, 07:59 PM
If a person experienced in Emerald animations would help me with this, I would be very grateful.
I'm trying to make a new animation, with the Dark background and the slash animation, but the game freezes every time the animation finishes. I did add an extra 08 and everything, and I'm pretty sure I found the right commands, so I'm not really sure what's going wrong. I really want to squash this bug so I can move on to implementing custom backgrounds in Emerald.
Anyways, here's my code:
14 00 17 00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 FF 0E DD 7C 2D 08 08

EDIT: Nvm I realized what went wrong. It's funny how one byte changes everything.

Giniselono
May 4th, 2014, 03:20 PM
If a person experienced in Emerald animations would help me with this, I would be very grateful.
I'm trying to make a new animation, with the Dark background and the slash animation, but the game freezes every time the animation finishes. I did add an extra 08 and everything, and I'm pretty sure I found the right commands, so I'm not really sure what's going wrong. I really want to squash this bug so I can move on to implementing custom backgrounds in Emerald.
Anyways, here's my code:
14 00 17 00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 FF 0E DD 7C 2D 08 08

EDIT: Nvm I realized what went wrong. It's funny how one byte changes everything.

What was the one byte that went wrong? I want to use this code too, and I'm getting the same problem you were having.

Yuna Hope
May 7th, 2014, 06:14 AM
i confused X.X can you make a video about it?
please..

Same here <3 Need some video

HidoranBlaze
May 7th, 2014, 10:50 PM
What was the one byte that went wrong? I want to use this code too, and I'm getting the same problem you were having. Ah my apologies, I didn't see this. It's been a while since I made this code, but I believe the FF byte near the end caused the problem; just take that out and you should be fine, I think.

Giniselono
May 8th, 2014, 10:27 AM
Ah my apologies, I didn't see this. It's been a while since I made this code, but I believe the FF byte near the end caused the problem; just take that out and you should be fine, I think.

Maybe you have the code stashed away somewhere? I changed the FF byte to 00 but that restarted my ROM when the attack was executed, so I instead took out the FF byte completely and my ROM broke.

HidoranBlaze
May 8th, 2014, 04:19 PM
Maybe you have the code stashed away somewhere? I changed the FF byte to 00 but that restarted my ROM when the attack was executed, so I instead took out the FF byte completely and my ROM broke. Ok, I'm on my computer now, I'll look at it and tell you what the problem is.

EDIT: Ok, here's my revised code. This definitely works. If this doesn't work, then you're probably doing something wrong. (I tested this myself) :

14 00 16 00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 0E DD 7C 2D 08 08

Giniselono
May 8th, 2014, 05:55 PM
Ok, I'm on my computer now, I'll look at it and tell you what the problem is.

EDIT: Ok, here's my revised code. This definitely works. If this doesn't work, then you're probably doing something wrong. (I tested this myself) :

14 00 16 00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 0E DD 7C 2D 08 08

Thanks, it worked!

25charmanderlimit

Artemis64
May 12th, 2014, 08:01 PM
Here's some animation codes for Ruby:
Ice Fang
http://i.imgur.com/qJsAful.gif
00 9B 27 00 9D 27 00 9F 27 00 97 27 0A 01 0C 0C 08 19 A1 00 3F 02 D0 B1 3D 08 02 06 00 00 E0 FF 00 00 00 00 33 03 0A 00 02 D0 B1 3D 08 02 06 00 00 20 00 04 00 00 00 CD FC 0A 00 04 0A 02 A8 B4 3D 08 02 04 00 00 00 00 01 00 02 00 03 7D 7E 0A 08 05 05 01 00 00 00 04 00 07 00 01 00 05 0B 01 0D 04 01 0E 36 5C 1D 08 04 05 03 39 2A 0E 08 0A 05 04 00 02 00 09 00 00 00 4C 7F 05 08 19 C5 00 C0
Thunder Fang
http://i.imgur.com/z7xQrDo.gif
00 9B 27 00 97 27 00 9F 27 00 35 27 0A 01 0C 0C 08 19 A1 00 3F 02 D0 B1 3D 08 02 06 00 00 E0 FF 00 00 00 00 33 03 0A 00 02 D0 B1 3D 08 02 06 00 00 20 00 04 00 00 00 CD FC 0A 00 04 0A 02 A8 B4 3D 08 02 04 00 00 00 00 01 00 02 00 03 7D 7E 0A 08 05 05 01 00 00 00 04 00 07 00 01 00 05 0B 01 0D 04 01 02 D0 97 3D 08 02 02 00 00 F0 FF 04 01 03 25 23 0E 08 02 03 01 01 01 01 01 01 04 01 02 D0 97 3D 08 82 02 00 00 D0 FF 04 01 02 D0 97 3D 08 02 02 00 00 F0 FF 04 01 02 D0 97 3D 08 02 02 00 00 10 00 04 01 19 DD 00 3F 03 25 23 0E 08 02 03 01 01 01 01 01 01 04 02 03 7D 7E 0A 08 02 05 01 00 00 00 03 00 0F 00 01 00 02 A8 B4 3D 08 03 04 00 00 00 00 01 00 02 00 04 01 02 C4 B3 3D 08 02 05 01 00 02 00 10 00 00 00 00 00 04 14 05 0B 01 0D 08
Drain Punch
http://i.imgur.com/v8EHDRo.gif
00 9F 27 00 A3 27 04 01 00 2F 27 00 97 27 0A 03 2A 01 0C 0C 08 04 01 02 A8 9F 3D 08 02 03 EC FF 0F 00 0C 00 05 02 A8 9F 3D 08 02 04 00 00 00 00 01 00 02 00 19 B4 00 3F 04 02 03 7D 7E 0A 08 05 05 01 00 00 00 05 00 05 00 01 00 05 02 C4 B3 3D 08 02 05 01 00 01 00 00 00 07 00 00 00 05 0E AE F5 1C 08 05 04 0F 0E F5 5E 1D 08 05 02 C4 B3 3D 08 02 05 01 00 01 00 07 00 00 00 00 00 05 0B 03 0D 08
Seed Bomb
http://i.imgur.com/HBRMRFP.gif
00 D6 27 00 BF 27 00 16 27 19 A7 00 C0 02 28 76 3D 08 82 06 0A 00 00 00 00 00 00 00 19 00 E0 FF 05 03 A1 7F 0A 08 02 05 01 00 04 00 00 00 10 00 01 00 02 28 78 3D 08 84 04 06 00 05 00 01 00 00 00 19 B1 00 3F 04 03 02 28 78 3D 08 84 04 F0 FF F1 FF 01 00 00 00 19 B1 00 3F 04 03 02 28 78 3D 08 84 04 10 00 FB FF 01 00 00 00 19 B1 00 3F 04 03 02 28 78 3D 08 84 04 F4 FF 12 00 01 00 00 00 19 B1 00 3F 04 03 02 28 78 3D 08 84 04 00 00 05 00 01 00 00 00 19 B1 00 3F 04 03 05 08
And I have some questions:
-What command allows you to play a sound multiple times?
-How would a pointer to offset 1 00 00 00 be written? Would it be 00 00 00 01 08, 00 00 00 18, or 00 00 00 09?

destinedjagold
May 13th, 2014, 07:07 PM
I have successfully made a simple animation for Night Slash in a Ruby ROM. :P
Adding backgrounds seemed to be easier than I thought.
Many thanks to Chaos Rush for this tutorial, and to dreamengine and Artemis64 for your Ruby contributions~ ^^

But I'm having trouble understanding how to add some hues of blue and green and other colors to the screen, like Absorb and Water Pulse. =/

HidoranBlaze
May 13th, 2014, 08:00 PM
I have successfully made a simple animation for Night Slash in a Ruby ROM. :P
Adding backgrounds seemed to be easier than I thought.
Many thanks to Chaos Rush for this tutorial, and to dreamengine and Artemis64 for your Ruby contributions~ ^^

But I'm having trouble understanding how to add some hues of blue and green and other colors to the screen, like Absorb and Water Pulse. =/ destinedjagold: Same principle applies. Just add the code to activate the background at the front, put your animation in between, and put the clear code at the end. Except you don't really need to add an extra 08 here. Here's my modified night slash example for Emerald, with the Giga Drain background, but you can substitute in the codes for Ruby (I think Artemis64 has the codes somewhere) :
02 74 72 59 08 02 05 01 00 01 00 00 00 04 00 ED 33 05 00 C7 27 02 2C 2D 59 08 82 03 01 00 F8 FF 00 00 19 88 00 3F 04 04 02 2C 2D 59 08 82 03 01 00 08 00 00 00 03 D1 52 0D 08 02 05 01 00 04 00 00 00 12 00 01 00 19 88 00 3F 05 02 74 72 59 08 02 05 01 00 01 00 04 00 00 00 ED 33 05 0B 03 0D 08

Artemis64
May 15th, 2014, 01:00 AM
Here are the codes:
To enable such a background: 02 C4 B3 3D 08 02 05 01 00 SS 00 00 00 II 00 CC CC 05
To clear the background: 02 C4 B3 3D 08 02 05 01 00 SS 00 II 00 00 00 CC CC 05 0B 03 0D
SS refers to speed at which the battle becomes colored CC CC, and II controls at what intensity. For CC CC, all you have to do is open up Advance Map, go to the block editor then the palette editor, and pick the color you want. The 15-bit value there, however, has to be reversed to be usable in the thing.
I was thinking about adding new attack backgrounds, however. Using tajaros' tutorial, and substituting the offset 0x37F374, and adding his example Waterfall background, it failed when I placed the pointers at the end of the table. However, if I use it to overwrite BG 0x1 (the extra Dark-type BG) I can load it, and it works perfectly fine as far as I can see. Which makes me think there is some limiter that is preventing the game from loading more than 0x1A (26) backgrounds, in Ruby at least. Unfortunately, I have no idea how to go about finding limiter bytes. If someone can explain the process to me, I'd be more than willing to do it myself.
Edit: Wow, I even forgot what I originally wanted to post (my Flame Charge animation bytes, and my adapted Gen 4 flame sprites):
Flame Charge:

http://i.imgur.com/10FTN4Q.gif
00 2D 27 0A 02 0C 0C 08 1C A8 00 C0 14 0F 0E E9 39 1D 08 0E E9 39 1D 08 0E E1 02 1D 08 04 20 03 8D 1F 0E 08 02 06 0A 00 08 00 02 00 00 00 0E 00 FF 7F 05 0B 02 0D 02 F8 1F 3C 08 02 05 00 00 18 00 00 00 00 00 06 00 04 04 03 7D 7E 0A 08 02 05 01 00 05 00 00 00 08 00 01 00 03 91 97 07 08 03 05 01 00 1F 00 0C 00 01 00 01 00 19 91 00 3F 0E A2 11 1D 08 04 07 02 E0 1F 3C 08 02 03 00 00 00 00 09 00 05 0B 03 08 02 94 96 3D 08 03 03 00 00 00 00 32 00 04 04 0F
72021
Edit 2: Here are some more animated background commands:
Animated Psychic : 0E E7 61 1D 08
High-power BG command: 0E E9 85 1C 08
Flying type BG : 0E FB 61 1D 08
As usual, all of them are for Ruby.

RaileysXerilyasRX
May 23rd, 2014, 12:41 AM
Wow! Very interesting! This really helped me a lot and I get to create on my own. :)

Draco Meteor (noGIF):
http://fc09.deviantart.net/fs71/f/2014/143/5/1/twilightfr_0027_insert_sprites_2___elite_four_by_raileysxerilyasrx-d7je4bd.png
I like it a lot. :)

Leaf Storm (noGIF):
http://fc05.deviantart.net/fs71/f/2014/143/2/0/twilightfr_0027_insert_sprites_2___elite_four_by_raileysxerilyasrx-d7je4b5.png
Well, kinda bit simple for a powerful move. :3

If you want the Hex codes, just download the attachments below:
72102
72103
Just open it in an hex editor and you got it. :)

Artemis64
May 28th, 2014, 04:00 AM
Here's some more data on the commands/pointers:
To recap, the 0E command not only loads a sprite, but also loads complex movements e.g. the rotating fire of Fire Spin, the Mud-Slap. The 02 command loads a sprite with some basic movements e.g. the moving upwards before falling downwards in a curve of Acid and Water Gun.
So I was intending to create a custom Emerald animation for Acid Spray by using Mud Slap and replacing the mud particles with A6 27, which is the Acid poison particle command. However, the 02 command didn't load the spherical Acid properly, but rather loaded half of it and combined it with the acid droplets. Therefore I was digging through the 02 command's 0x18 bytes to see how to get it fixed. What I found was the structure of the 02 command:
(1st 2 bytes, image data)(Next 2 bytes, palette data)(2 pointers to what should be extracted from the image and used and how to piece it together)(4 00 bytes, still haven't figured out what they do)(2 pointers containing movement data)

Artemis64
August 31st, 2014, 02:09 AM
More interesting information:
I don't really get this one, but it seems that 0A XX YY 00 02 00 00 00 is the command to color a Pokémon (like the white in Mist and the purple in Sludge). The YY byte appears to define what is colored. 04 is opponent's Pokémon, 0F appears to be the whole area (Heat Wave?) Then, a byte follows that decides the limits of the color. 09 appears to be limited to basic red (Flame Wheel), while 0C/0E seems to accept any color. After that, a 00 byte appears, then the color in reverse hex.
Then, extracting data from Mist, the command is 0A 00 08 00 02 00 00 00 0E 00 FF 7F? However, using Flame Wheel's data, changing the bytes to 00 08 crashes the animation..???
Finally, looking at Heat Wave, the command used to color the whole background is 06 02 06 00 00 1F, while the command used to color the sand particles is 06 00 06 00 00 1F. Just a single byte's difference. The structure appears kinda similar, but it IS different, which is weird, since most animations using the same resource usually is the same command. Get the confusion?
The reason why I am posting this now is because it needs to be better researched and finalised before it can become a proper command. Help please?

Lance32497
September 11th, 2014, 08:53 AM
I try to calculate the offset for SHADOW BALL, but I dont know what is the indication that this byte is the last byte for the move SHADOW BALL? How can I identify the end byte of a certain move???

vizor
September 11th, 2014, 10:22 AM
Today i was doing some reserach on the script engine of this language and figuered out, how some commands work. I have not worked through them all and yet I dont understand everything the commands do. The list i am posting is for firered german, so the offsets won't fit a english rom, but the way the commands work should be the same


battle anim engine

cmd0 [u16 a]
loads a animated graphic given in a into objvram and its animation into animation_bank

cmd2 [u32 a] [u8 b] [u8 c] [...]
a seems to be an oam_structure, while b is a flag?
c also shows additional animation which is loaded into animation_bank
this function spawns an OAM from this structure which a certain animation


cmd3 [u32 a] [u8 b] [u8 c] [...]
loads a into ram as a callback
loads b into this callback as status
c shows the amount of additional animation, which is loeaded into animation_bank

cmd4 [u8 a]
seems to delay the next command by a frames

cmd5
delays the script by a number given at 0x02037EE2, must be some kind of "waitstate"

cmd6
nop

cmd7
nop

cmd8
ends the script, as long there is no delay remaining, otherwise it will wait and then end the script

cmd9 [u16 a]
plays a sound/song given in a, as long as 0x02031DD8 == 0 and 0x0203AdFA != 2

cmdA [u8 a]
something very complex, a lot of code, spawns a callback if there is an targeta
a has states from 0-3 (0,2 = players poke as target ;; 1,3 = opps. poke)

cmdB [u8 b]
very similar to cmdA but not so complex
also spawns a callback and clears bits in the OAM structure flags

cmdC [u16 a]
enables blending by setting BLDCNT to 0x3F40 and sets COLEV to a

cmdD
resets BLDCNT and COLEV to 0

cmdE [u32 a]
branches the code to a and places a return adress at 0x02037ED8

cmdF
branches the code to the return adress at 0x02037ED8

cmd10 [u8 a] [u16 b]
places b in the animation_bank, places it with the ID a

cmd11 [u32 a] [u32 b]
branches the code to a if the byte at 0x02037F16 has bit0 set, otherwise it branches the code to b

cmd12 [u8 a] [u32 b]
branches the code to b if the byte at 0x02037F16 == a

cmd13 [u8 a]
branches the code to a

cmd14 [u8 a]
spawns 0x80737B4|1 as callback and sets a as it param 0x8 in RAM
sets byte at 0x02037F17 to 0x1

cmd15
spawns 0x080737B5|1 as callback and sets it param 0x8 to 0xFFFF
sets byte at 0x02037F17 to 0x1

cmd16
halts the code until 0x02037F17 == 0x2

cmd17
halts the code until 0x02037F17 == 0x0

cmd18 [u8 a]
loads a background into the battle from the table at 0x3ADC64 (ID is a, entry length is 0xC)

cmd19 [u16 a] [s8 b]
does a lot of checks with the singed byte b and then seems to play sound a or something like that
maybe b is some modulation for the sound display


cmd1A [s8 a]
does the same thing with a as cmd19 does with b (maybe modulation)

cmd1B [u16 a] [s8 b] [u8 c] [u8 d] [u8 e]
spawns 0x0873C50|1 as callback
sets a transformed value of b (like in cmd19) as param 0x8 in RAM
sets " c " 0xA "
sets abs(d) or 0x0 (if b >= c)as param 0xE in RAM
sets e as param 0x10 in RAM



cmd1F [u16 a]
sets BLDCNT to a




cmd23 [u8 a]
does the same thing as cmdB but doesnt spawn a callback

cmd24 [u8 a]
very similar to cmdB

kittopian
November 28th, 2014, 11:10 PM
I have recently got back into ROM hacking, and I am now working on a tool to make editing move animations slightly easier by "decompiling" it into some kind of pseudo-scripting 'language'. So far, it seems to work "ok", for instance, fly seems to be parsed nicely:

load ac 27;
load 97 27;
2waybranch f71f2d08 0f202d08;
wait;



However, It seems to "break" very easily, as evident by this move (Vine whip):

load 2f 28;
sound 8f 0;
execute 28fe578 2 2;
delay 0;
nop;
load 4 6;
sound 9b 0;
execute e828598 82 2;
load 0 0;
load 4 6;
unknown2 d152d8 2 5;
load 2 0;
load 0 6;
load 1 0;


it mainly has trouble with 0x02, and 0x03. It may be due to me miscounting the number of arguments it uses. Can someone tell me the number of arguments these "commands" accept? Or a way of "splitting" these commands? Any help will be appreciated and thank you for your time.