Advertiser Content
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
If you're not interested in the techical details scroll down

As you probably know you can change the behaviourbyte of the grass block from 2 (normal grass) to 3(tall grass) in advancemap. However no animation is played for 3.

Everything starts at 083A70BC which is a table of functions. The interesting entries are at index 1 and 2: 080683C8 and 08068414. They end with:
08068402         MOVS    R0, #4
08068404         BL      overworld_effect_start
0806844E         MOVS    R0, #0x11
08068450         BL      overworld_effect_start
(the numbers that "overworld_effect_start" uses are the same as for the do_animation npc script command)
overworld_effect_start has a script collection (081D96AC) with it's own bytecode (dispatch table is at 083CBE30). The commands in bytecode are:
0 load graphics
1 load palette (v1)
2 load palette (v1)
3 call asm
4 end
5 combination of 0 1 3
6 combination of 0 3
7 combination of 1 3
Effect 0x4:
07 083A5348 080DB349 04
Effect 0x11:
07 083A5348 080DB5F5 04
Part of the function called from animation 0x4:
...
080DB368         LDR     R0, =0x083A0010 @ array of pointers to object templates (see http://www.pokecommunity.com/showthread.php?t=238937)
080DB36A         LDR     R0, [R0,#0x10]  @ selects the array-entry for the normal grass
...
080DB378         BL      template_instanciate
...
Part of the function called from animation 0x11
...
080DB614         LDR     R0, =0x083A0010 @ array of pointers to object templates (see http://www.pokecommunity.com/showthread.php?t=238937)
080DB616         LDR     R0, [R0,#0x3C]  @ selects the array-entry for the tall grass
...
080DB624         BL      template_instanciate
...
083A5420 grass_normal:object_template <0xFFFF, 0x1005, unk_083A36F0, \
083A5420                                    off_083A541C, stru_083A53DC, \
083A5420                                    rotscale_table_empty, objc_grass_normal>
083A593C grass_tall: object_template <0xFFFF, 0x1005, unk_083A36F0, \
083A593C                                    off_083A5938, stru_083A58F8, \
083A593C                                    rotscale_table_empty, objc_grass_tall>
The last entry in this structure is the callback that executed once every frame. Those are almost equal except for:
...
080DB46C         BL      complex_function
080DB470         LSLS    R0, R0, #0x18
080DB472         CMP     R0, #0
080DB474         BEQ     loc_080DB48C
...
...
080DB71C         BL      put_0_into_r0_and_do_nothing
080DB720         LSLS    R0, R0, #0x18
080DB722         CMP     R0, #0
080DB724         BEQ     loc_080DB73C
...
To make the tall grass work, a function, equivalent to the one used in the function for normal grass, needs to be written at the same offset.

HOW TO FIX IT
Start overwriting at 08059f34 with 00 21 00 06 00 0e 02 28 01 d0 d1 28 01 d1 01 20 00 e0 00 20 00 21 70 47 03 28 f5 e7

eh 08059f34 0x2100
eh 08059f48 0x2100
eh 08059f4a 0x4770
eh 08059f4c 0x2803
eh 08059f4e 0xE7F5

Have fun and please credit me.

EDIT
If you want to enable the tiny grass too overwrite at 0805A0EC with 0C 30 09 E0. (It's mapped to behaviour byte 7)

Derlo

Working on Essence of light...

Seen 2 Weeks Ago
Posted May 16th, 2018
132 posts
12.3 Years
Man if there's one thing I always wanted to fix was that ...
Great job!
I wonder know if you have tried enable other animations from the 3rd generation? Like the grass with ash on it ...

I tried to do one thing:

08068402 MOVS R0, # 4
08068404 BL dp02_exec_aka_do_animation
This #4 refers to animations that will be loaded into tile ... I tried to change this for any other byte below #40. And what I got was that instead of the normal animation of grass other animations were loaded (in fact I think all the animation tiles had been carried).

For example:
* If you place a # 01, the animation will be loaded, is when we use the cut on the grass tiles.
* And if you put # 07, the animation will be loaded is the grass with ash on top (which I referred to earlier), merged with a setmaptile with some tile of the second tileset.

And so on ...

Maybe this way there is how to enable other animations or even create new ones.

Good luck and thanks!



Pokémon
Essence of Light

Comming Soon...
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
I think that the ashgrass is also available via behaviourbytes but deactivated just like the tall grass. Finding a patch for that shouldn't be hard. I'll make one if I have time. And thank you Derlo for the animation-number of the ashgrass.
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
Patch for tall grass on behaviourbyte 0x03 and ash grass on behaviourbyte 0x24

eh 08059f34 0x2100
eh 08059f48 0x2100
eh 08059f4a 0x4770
eh 08059f4c 0x2803
eh 08059f4e 0xE7F5
eh 08059f50 0x2824
eh 08059f52 0xE7F3
eb 0806e820 0x04
eh 0806ebdc <special tile with ash>
eh 0806ebe0 <special tile without ash>
eh 0806ec00 <grass tile without ash>

You fix it with a hex editor, right?
Yes.
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
I have a small problem: I'm using XVI32 and I can't find the offset. Should I use a different hex-editor?
You can't even use a hex-editor correctly? I am disappoint. Sorry, I was in a bad mood when I wrote this.

I wrote addresses/pointers not offsets. In GBA the ROM Origin is 08000000. So if you want the offset you have to subtract this number from the address.

Derlo

Working on Essence of light...

Seen 2 Weeks Ago
Posted May 16th, 2018
132 posts
12.3 Years
Remember...
All of bytes, are written on the offset: 08068402. (Normal Grass)
And will activates when any OW steps on the tile.



01 - Animation of the HM CUT on the grass tiles. (Some leaves turning around the player)
02 - Same as before. (But without the animation of the leaves)
03 - Apparently nothing.
04 - Normal Grass.
05 - Ripple on the water when an OW step in puddles of water. (The animation appears only in these coordinates: x = y = 0d 13)
06 - Bar with a sprite POKEMON random. (The POKEMON that is shown depends on the coordinates X) [When load repeatedly times, Break the rom.]
07 - Grass with ashes on top, mixed with a setmaptile with some of the tiles.
08 - Loads the OW of HM SURF (pokemon in which the player stands on top in the water)
09 - Loads the HM SURF to the player.
0A - Dust when an OW performs a jump on the floor.
0B - Apparently nothing.
0C - effect when an OW performs a jump in the grass tiles.
0D - Footprints in the sand. (Animation is not complete, only one tile of the animation)
0E - effect when an OW performs a jump in the water tiles. (Splash)
0F - Apparently nothing.
10 - Splash of footsteps in the water.
11 - Apparently nothing.
12 - Another animation of grass. Very interesting ...
13 - Another animation of grass diferent than the previous. (The tile always gets excited. "shaking" lol.)
14 - Another animation of the grass #12. (The tile always gets excited. "shaking" lol.)
15 - A type of hole in the sand. [Possibly a WARP] (animated constantly)
16 - Submerge the water. [Possibly a WARP] (animated constantly)
17 - Apparently nothing.
18 - Same as # 0D
19 - Animation of Pokeballs in Pokecenter.
1A - 1D - Apparently nothing.
1E - Pokemon landing after using HMFLY. (The Standing animation always loaded in the player's position)
1F - 22 - Apparently nothing.
23 - BIKE Trail in the sand. (Animation is not complete, only one tile of the animation)
24 - Apparently nothing.
25 - Player using the Pokeball and POKEMON. (Possibly HM Strength)
26 - Player using the Pokeball and POKEMON. (Teleport to last WARP)
27 - Apparently nothing.
28 - Player using the Pokeball and POKEMON.
29 - 2A - Apparently nothing.
2B - Break the rom.
2C - Bar with Sprite POKEMON (Break the rom.)

2D - appears a drawing of a Pokeball in the left corner of the screen, then fades. (Possibly is not a tile)
2E - 30 - Apparently nothing.
31 - When we are sucked into the sand. (WARP)
32 - Splash water. (WARP)
33 - Animation SWEETSCENT.
34 - Apparently nothing.
35 - Bubbles on the floor.
36 - 39 - Apparently nothing.
3A - Leaves turning around the OW player.
3B - Bar with a sprit of a POKEMON.
3C - 3D - Apparently nothing.
3E - animation of the machine that records the data on FAMEHALL.
3F - Teleport to the center of the map.
40 - Apparently nothing.
41 - Animation VS.SEECKER. (Break the rom.)
42 - 44 - Apparently nothing.
45 - The screen flashes. (As a Flash)
46-9F - Resets the ROM or Break the rom.

EDIT:
A0-A1 - Resets the ROM or Break the rom.
A2 - Lock the screen, and the movements of the OW are slow.
A3-B7 - Resets the ROM or Break the rom.
B8 - Movement of the OW slower and damage their image.
B9-DD - Resets the ROM or Break the rom.
DE - Apparently nothing.
DF-E7 - Resets the ROM or Break the rom.
E8 - Apparently nothing.
E9-EE - Resets the ROM or Break the rom.
EF - Apparently nothing.
F0-F7 - Resets the ROM or Break the rom.
F8 - Apparently nothing.
F9-FF - Resets the ROM or Break the rom.



Pokémon
Essence of Light

Comming Soon...

sonic1

ASM is my life now...

Age 25
Male
Portugal
Seen May 29th, 2018
Posted November 30th, 2012
79 posts
11.5 Years
That's the limit. There isn't more than that.
It is? Well, i'm not sure, but the command doanimation uses a word as parameter, not a byte. But i'm not sure, as there can be a table or something...

~Sonic1
This signature has been disabled.
over 350px high
Please review and fix the issues by reading the signature rules.

You must edit it to meet the limits set by the rules before you may remove the [sig-reason] code from your signature. Removing this tag will re-enable it.

Do not remove the tag until you fix the issues in your signature. You may be infracted for removing this tag if you do not fix the specified issues. Do not use this tag for decoration purposes.

Quilava's Master

Shattered Dreams '13

Seen February 9th, 2018
Posted November 17th, 2014
693 posts
12.4 Years
This is beyond incredible. I definitely wish to implement this in Shattered Dreams. What I love most is how easy it is to understand for anyone who's ever worked with a hex editor! Many thanks Knizz! But I do have a question regarding the ash grass. Will it work in accordance with the "Soot Sack" item in the same vein as it did in RSE?

Note: I would have tested this myself before asking but my laptop is out of commission right now.
The return of Pokemon Shattered Dreams! Click the screenshot to visit the thread, you know you want to.

Shiny Quagsire

I'm Still Alive, Elsewhere

Age 21
Male
Hoenn Safari Zone
Seen 4 Weeks Ago
Posted April 17th, 2017
700 posts
10.6 Years
On the topic of animation ids, could you make a new tile that animates when stepped on?
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
It is? Well, i'm not sure, but the command doanimation uses a word as parameter, not a byte. But i'm not sure, as there can be a table or something...

~Sonic1
It is a table it is at 081D96AC. And it has 0x46 entries.

This is beyond incredible. I definitely wish to implement this in Shattered Dreams. What I love most is how easy it is to understand for anyone who's ever worked with a hex editor! Many thanks Knizz! But I do have a question regarding the ash grass. Will it work in accordance with the "Soot Sack" item in the same vein as it did in RSE?

Note: I would have tested this myself before asking but my laptop is out of commission right now.
I have no idea. I think this ash-grass doesn't even have pokemon encounters so it's at least broken in ONE way.

On the topic of animation ids, could you make a new tile that animates when stepped on?
Can? Yes! Want? If you pay me. I can give you a few tips though if you're serious about it. Contact me via email, PN, MSN or IRC.
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
excuse me for being noobish, but how can you activate the other animations?
Which other animations? You mean except for tall grass and ash? You can't. That'd require new patches. But no one wrote them yet. But lot's of animations are activated already. Just open AdvanceMaps block-editor and play around with the behaviour-byte.
Female
Seen October 4th, 2018
Posted January 24th, 2015
192 posts
12.3 Years
So this activates the previously blocked tall grass animation...great! I'll try it when I have the time. Thanks!

One question though: does this mean the tall grass animation can now be edited into a new grassy patch animation?
When I said patch I meant "small modification".

You can replace the images used in the animation and edit their order. Just edit the corresponding "unknown_structure". (More infos in first post)

r0bert

Quitifyingly awesome.

Male
kewl places
Seen November 23rd, 2011
Posted September 9th, 2011
370 posts
9.5 Years
Which other animations? You mean except for tall grass and ash? You can't. That'd require new patches. But no one wrote them yet. But lot's of animations are activated already. Just open AdvanceMaps block-editor and play around with the behaviour-byte.
I kinda meant the micro grass animation.
also what are the rest of the animations?(pic in attachment)
the ones I can't recognise are in a blue square.

hinkage

Everyone currently in an argument with this member: I really suggest you stop.

Age 24
Seen February 1st, 2017
Posted March 26th, 2016
378 posts
9.3 Years
Sorry for being new and stupid, but what does this part mean?

"eh 08059f34 0x2100
eh 08059f48 0x2100
eh 08059f4a 0x4770
eh 08059f4c 0x2803
eh 08059f4e 0xE7F5"

What do I do with it? I DID research a little, and the only part that confuses me still is the 0x2100, etc.
Seen June 17th, 2013
Posted December 8th, 2012
35 posts
12.4 Years
ok for all who didn´t understand it: The Offset you can see on the top are written in ASM.

So the most people don´t know where they can find it in there Hex Viewer....

So here is the "Hex" Offset:
059F34 for firered english
059F34 for firered german (feuerrot) - it´s really rare that the german rom has the same offset than the English

this is the hex code you have to use
00 21 00 06 00 0e 02 28 01 d0 d1 28 01 d1 01 20 00 e0 00 20 00 21 70 47 03 28 f5 e7

here you can see that it works



//Edit:
I have a question: How can I make that I can´t drive with the bike over the really tall grass block?
Temporarily not available
Advertiser Content