The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > ROM Hacking > Research & Development
Sign Up Rules/FAQ Live Battle Blogs Mark Forums Read

Notices

Research & Development Got a well-founded knack with ROM hacking? Love reverse-engineering the Pokémon games? Or perhaps you love your assembly language. This is the spot for polling and gathering your ideas, and then implementing them! Share your hypothesis, get ideas from others, and collaborate to create!
Research & Development programs in this forum are subject to moderator approval before they are displayed.


Advertise here

Reply
Click here to go to the first staff post in this thread.  
Thread Tools
  #1    
Old March 20th, 2011, 05:39 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest

Advertise here
While browsing this section I found a post by colcolstyles (see below) about the amount of frames that the titlescreen in FireRed is displayed for. I then thought to myself "That'd be a good way to add an animation to the titlescreen!" and then I posted this thread.

Quote:
Originally Posted by colcolstyles View Post
For anyone who's interested, at '0x078c1c' there is a 32-bit number (the default value is '0x00000a8b') which dictates the number of frames for which the titlescreen is displayed before resetting. The GBA operates at roughly 60 frames per second and '0xa8b' divided by 60 is 45 so the unedited titlescreen is displayed for 45 seconds. You can change that number (remember to reverse it) to lengthen or shorten the amount of time it takes for the titlescreen to reset.

This is for Fire Red, by the way.
Anyway, my idea is to inject a routine just before that check to change the tileset/tilemap of the Charizard on the titlescreen, based on the amount of frames passed, allowing for animations to be used.

This would be a much better way of having an animated titlescreen than anything done before now(I think), since more than 2 frames will be able to be used.

I'll let you all know how it goes!!

EDIT:
http://www.youtube.com/watch?v=SA95KzAgb48
Success has been had.

EDIT2:
It now works by using a data array that works as such:
Code:
word:   Pointer to image
byte:   Pause Length
byte:   Next Frame
hword:  Buffer
...so a simple endless-loop animation (like in the video) would be possible, or you could play the first few frames once, then loop to a frame somewhere in the middle. Or you can stop the animation at the end by pointing to its own frame. The animation can be up to 255 frames.

So yeah, it just changes the tiles, not the tilemap, as that seems to suffice.

Any other ideas?

EDIT:
Zapdos in the animation: http://www.youtube.com/watch?v=rnm4SkwE22I
__________________
あなた は しきしゃ です
わたし は ばか です

Last edited by Darthatron; March 23rd, 2011 at 03:18 AM.
Reply With Quote
  #2    
Old March 21st, 2011, 04:37 PM
diegoisawesome's Avatar
diegoisawesome
Not the Script Help Thread
Community Supporter
 
Join Date: Dec 2007
Location: Goldenrod City, Johto
Age: 17
Gender: Male
Nature: Quirky
Nice work! Now we only need to be able to 'pull' tilemaps across the screen...
And make this work in Emerald too, as it just resets on the end of the song.
__________________


My other resources:
My Website
diegoisawesome's MEGA-HUGE XSE Scripting Tutorial
diegoisawesome's Miscellaneous Finds
The Ruins of Alph Puzzles
Reply With Quote
  #3    
Old March 21st, 2011, 11:31 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
For Emerald, I think it would be better to use an OAM. Of course, this would make moving of the animation a lot easier as well. But it would limit the size of the animation to 64x64. :\
__________________
あなた は しきしゃ です
わたし は ばか です
Reply With Quote
  #4    
Old March 22nd, 2011, 05:17 AM
Full Metal's Avatar
Full Metal
C(++) Developer.
Community Supporter
 
Join Date: Jan 2008
Location: In my mind.
Age: 19
Gender: Male
Nature: Timid
Send a message via Windows Live Messenger to Full Metal
Awesome, thanks for this, I can't wait to quit programming and try it out at somepoint.
__________________

★ full metal.

I like to push it,
and push it,
until my luck is over.

Last edited by Full Metal; March 22nd, 2011 at 05:31 AM.
Reply With Quote
  #5    
Old March 22nd, 2011, 11:32 AM
knizz's Avatar
knizz
 
Join Date: Aug 2007
Cool idea. Once I have finished all my school work I'll contribute.
__________________
Firered IDA 6.1 DB: https://www.dropbox.com/s/hvvmxxoo1dkmdzc/firered.idb
VBA-M with lua scripting support (no longer in development)
Reply With Quote
  #6    
Old March 22nd, 2011, 02:20 PM
diegoisawesome's Avatar
diegoisawesome
Not the Script Help Thread
Community Supporter
 
Join Date: Dec 2007
Location: Goldenrod City, Johto
Age: 17
Gender: Male
Nature: Quirky
I wouldn't know, exactly, how to get the game to load a new OAM to the title screen, or how to have it animate... well, that would probably just use the frame system we've already found. But I wouldn't know how to make it, say, go across the screen. Then again, I don't know how to do that with tilemaps either...
__________________


My other resources:
My Website
diegoisawesome's MEGA-HUGE XSE Scripting Tutorial
diegoisawesome's Miscellaneous Finds
The Ruins of Alph Puzzles
Reply With Quote
  #7    
Old March 22nd, 2011, 03:49 PM
Team Fail's Avatar
Team Fail
The fine line between in|sanity
Community Supporter
 
Join Date: May 2009
Age: 19
Gender: Male
Nature: Brave
I like this. I'd like to see this as a complete working animated title screen someday. Congrats on your effort. Do you think it'd be possible to use the animated sprites of the Pokemon in Black and White, after resized, in the title screens?
__________________

Pairs:
Kevin, Echidna
Follow me on Twitter! @TeamFail
Alt 1, リザードン
Miiverse
Pokémon Hackers Online
Alt 2: Jack Cayman



[04:20.39] <@GoGo> I WILL INSERT WITH PLEASURE
[04:20.45] <@GoGo> shut it Bela

[05:41.55] <Team_Fail> Blue Spider is interesting, but #MEHMasterRace
[05:42.20] <diegoisawesome> Team_Fail: Sounds like a bunch of unmotivated people that still want to try to take over the world
Reply With Quote
  #8    
Old March 22nd, 2011, 05:45 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
Yeah, but not with the way they are stored in the B/W ROM, since they are stored as "parts" rather than full frames. But if you make/find full frames, and give me the order, I can make a video showing it.

EDIT: I got bored an put in Zapdos' animation. Well... kind of. Just the frames. Not the FULL animation, though that is very possible.

http://www.youtube.com/watch?v=rnm4SkwE22I

There is a downside to this hack, though. It takes quite a bit of space. The entire Zapdos animation (frames, tilemap and routine) take up 11.55kb (11,828 bytes) in the ROM. Which only works out to about 0.0007% of the entire (un-expanded) ROM, but it's still quite a bit.
__________________
あなた は しきしゃ です
わたし は ばか です

Last edited by Darthatron; March 23rd, 2011 at 05:11 AM.
Reply With Quote
  #9    
Old March 23rd, 2011, 09:59 AM
war rock exe's Avatar
war rock exe
Pokemon Colosseum Remaker!!
 
Join Date: Dec 2009
Location: wouldn't you like to know?
Age: 17
Gender: Male
Nature: Hardy
Quote:
Originally Posted by Darthatron View Post
Yeah, but not with the way they are stored in the B/W ROM, since they are stored as "parts" rather than full frames. But if you make/find full frames, and give me the order, I can make a video showing it.

EDIT: I got bored an put in Zapdos' animation. Well... kind of. Just the frames. Not the FULL animation, though that is very possible.

http://www.youtube.com/watch?v=rnm4SkwE22I

There is a downside to this hack, though. It takes quite a bit of space. The entire Zapdos animation (frames, tilemap and routine) take up 11.55kb (11,828 bytes) in the ROM. Which only works out to about 0.0007% of the entire (un-expanded) ROM, but it's still quite a bit.


nice vid man

i'm guessing that you should probably complete the hack before you input the titlescreen...
__________________
POKÈMON COLOSSEUM TRILOGY FOR RMXP!! COMING THIS SUMMER!
STATUS; BETA 1 70%
Reply With Quote
  #10    
Old March 23rd, 2011, 01:55 PM
Team Fail's Avatar
Team Fail
The fine line between in|sanity
Community Supporter
 
Join Date: May 2009
Age: 19
Gender: Male
Nature: Brave
Quote:
Originally Posted by Darthatron View Post
Yeah, but not with the way they are stored in the B/W ROM, since they are stored as "parts" rather than full frames. But if you make/find full frames, and give me the order, I can make a video showing it.

EDIT: I got bored an put in Zapdos' animation. Well... kind of. Just the frames. Not the FULL animation, though that is very possible.

http://www.youtube.com/watch?v=rnm4SkwE22I

There is a downside to this hack, though. It takes quite a bit of space. The entire Zapdos animation (frames, tilemap and routine) take up 11.55kb (11,828 bytes) in the ROM. Which only works out to about 0.0007% of the entire (un-expanded) ROM, but it's still quite a bit.
That's pretty damn cool. Not kidding. If I was able to do this for my hack, I would do so by all means. But, the one thing that bugs me the most is the flames in the background. Is it possible to use them elsewhere on the screen. I do know they can be edited using UnLzGBA, but yeah.
__________________

Pairs:
Kevin, Echidna
Follow me on Twitter! @TeamFail
Alt 1, リザードン
Miiverse
Pokémon Hackers Online
Alt 2: Jack Cayman



[04:20.39] <@GoGo> I WILL INSERT WITH PLEASURE
[04:20.45] <@GoGo> shut it Bela

[05:41.55] <Team_Fail> Blue Spider is interesting, but #MEHMasterRace
[05:42.20] <diegoisawesome> Team_Fail: Sounds like a bunch of unmotivated people that still want to try to take over the world
Reply With Quote
  #11    
Old March 23rd, 2011, 03:45 PM
Full Metal's Avatar
Full Metal
C(++) Developer.
Community Supporter
 
Join Date: Jan 2008
Location: In my mind.
Age: 19
Gender: Male
Nature: Timid
Send a message via Windows Live Messenger to Full Metal
^ He's not actually making a hack. He's hacking. you know, learning, experimenting in areas others haven't really abused much. It's pretty cool and fun.
ANYWAYS, what I *really* came here with.
I tried bpr 08078C1C 2
and nothing ever came up.
But it's okay, I followed that post link, and read down on that thread a bit further where Knizz ( Reference ) posted the offset of the comparison. I looked up the point where r0 is loaded with the value.
Spoiler:

08078bf8 4907 ldr r1, [$08078c18] (=$03005098)
08078bfa 1840 add r0, r0, r1
08078bfc 2300 mov r3, #0x0
08078bfe 5ec1 ldsh r1, [r0, r3]
08078c00 4806 ldr r0, [$08078c1c] (=$00000a8b)
08078c02 4281 cmp r1, r0
08078c04 dd05 ble $08078c12

And I was wondering, is the bpr not triggering because it's not ldr-ing a constant value? :\
__________________

★ full metal.

I like to push it,
and push it,
until my luck is over.
Reply With Quote
  #12    
Old March 23rd, 2011, 10:02 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
Quote:
Originally Posted by Full Metal View Post
^ He's not actually making a hack. He's hacking. you know, learning, experimenting in areas others haven't really abused much. It's pretty cool and fun.
ANYWAYS, what I *really* came here with.
I tried bpr 08078C1C 2
and nothing ever came up.
But it's okay, I followed that post link, and read down on that thread a bit further where Knizz ( Reference ) posted the offset of the comparison. I looked up the point where r0 is loaded with the value.
Spoiler:

08078bf8 4907 ldr r1, [$08078c18] (=$03005098)
08078bfa 1840 add r0, r0, r1
08078bfc 2300 mov r3, #0x0
08078bfe 5ec1 ldsh r1, [r0, r3]
08078c00 4806 ldr r0, [$08078c1c] (=$00000a8b)
08078c02 4281 cmp r1, r0
08078c04 dd05 ble $08078c12

And I was wondering, is the bpr not triggering because it's not ldr-ing a constant value? :\
I had the same problem, I think. I had to manually go to the offset and look for the part that loaded it. :\ I have no idea why, though. Sorry.

I use No$GBA to debug, though. Not VBA.



Anyway, if anyone wants the routine as is, PM me for it. I'm sure it can be optimized, but I don't have much free time to do so.
__________________
あなた は しきしゃ です
わたし は ばか です
Reply With Quote
  #13    
Old March 25th, 2011, 06:14 AM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
Quote:
Originally Posted by diegoisawesome View Post
Nice work! Now we only need to be able to 'pull' tilemaps across the screen...
And make this work in Emerald too, as it just resets on the end of the song.
In regards to this, I looked in to it, and it's a LOT easier to move the tilemap than I thought it would be. Infact, I implemented it and it seems to work fine. Except when moving it from the X-axis, from off the screen, since the GBA hardware "wraps" the tilemap, which makes it come from left if moved off the right, and visa versa. :\ I can't see an easy way around this... Y-axis has no problem at all, though.

EDIT: Source off all knowledge: http://nocash.emubase.de/gbatek.htm#lcdiobgscrolling

EDIT2: http://www.youtube.com/watch?v=NuetDQEUqKQ
__________________
あなた は しきしゃ です
わたし は ばか です

Last edited by Darthatron; March 25th, 2011 at 06:36 AM.
Reply With Quote
  #14    
Old March 25th, 2011, 11:01 AM
itari's Avatar
itari
Community Supporter
 
Join Date: Mar 2010
Location: 渦潮隠れの里
Age: 17
Gender: Female
Nature: Relaxed
Wow, that really is quite amazing. Great work! I only wish I knew more so that I could contribute to this.
__________________
Touhou Puppet Play: Sapphire

SubscriptAdvanced SongType Effectiveness EditorTilemap CreatorPython IPS Patcher
Reply With Quote
  #15    
Old March 25th, 2011, 02:17 PM
diegoisawesome's Avatar
diegoisawesome
Not the Script Help Thread
Community Supporter
 
Join Date: Dec 2007
Location: Goldenrod City, Johto
Age: 17
Gender: Male
Nature: Quirky
There's an I/O flag for the BG layer that checks for wrapping.
Disable it and you're good to go.
__________________


My other resources:
My Website
diegoisawesome's MEGA-HUGE XSE Scripting Tutorial
diegoisawesome's Miscellaneous Finds
The Ruins of Alph Puzzles
Reply With Quote
  #16    
Old March 25th, 2011, 07:02 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
Quote:
Originally Posted by diegoisawesome View Post
There's an I/O flag for the BG layer that checks for wrapping.
Disable it and you're good to go.
Yeah, I tried that, but I couldn't get it working. I'll have another go later.
__________________
あなた は しきしゃ です
わたし は ばか です
Reply With Quote
  #17    
Old March 26th, 2011, 02:49 PM
RHIOne's Avatar
RHIOne
Dev of Hack Album RHIOne
 
Join Date: Mar 2011
Location: New Bark Town
Gender: Male
Wow... Amazing job on this, I was having a two-framed titlescreen before, and I look into this for more frames :D
Reply With Quote
  #18    
Old March 27th, 2011, 09:09 AM
colcolstyles's Avatar
colcolstyles
Yours truly
 
Join Date: May 2008
Location: The Bay Area
Gender: Male
Nature: Lonely
Mm, cool idea. I'll be keeping my eye on this. :)
__________________

Brother of Vrai
Reply With Quote
  #19    
Old March 27th, 2011, 01:12 PM
Full Metal's Avatar
Full Metal
C(++) Developer.
Community Supporter
 
Join Date: Jan 2008
Location: In my mind.
Age: 19
Gender: Male
Nature: Timid
Send a message via Windows Live Messenger to Full Metal
Hey, I tried that routine.
I think I did a nice job at understanding it.
You load a pointer to an array of those structures
Then, you load a pointer to the image and copy it.
Then you wait until the frame count for that image passes
Then you load the next and continue. { you store the fc and the current frame in that RAM_ADDRESS location thing. }
But one question, how do you know when to reset back to the first image?
{ I still haven't actually gotten this thing to work btw. I probably just need to start with a fresh ROM and go from there. }
Also, some other questions.
For that routine, does it use a tilemap? What about the graphics, should they be compressed, or decompressed?
*edit*
NVM on the knowing when to restart. You just set the `next frame` value to 0.
I FEEL SILLY now. But the questions of tilemaps uncompressed/compressed still remains.
Although I have a feeling it's uncompressed with a tilemap...(GbaTek doesn't say swi 0xC uncompresses any data )
__________________

★ full metal.

I like to push it,
and push it,
until my luck is over.

Last edited by Full Metal; March 27th, 2011 at 05:57 PM.
Reply With Quote
  #20    
Old March 27th, 2011, 10:46 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
Quote:
Originally Posted by Full Metal View Post
Hey, I tried that routine.
I think I did a nice job at understanding it.
You load a pointer to an array of those structures
Then, you load a pointer to the image and copy it.
Then you wait until the frame count for that image passes
Then you load the next and continue. { you store the fc and the current frame in that RAM_ADDRESS location thing. }
But one question, how do you know when to reset back to the first image?
{ I still haven't actually gotten this thing to work btw. I probably just need to start with a fresh ROM and go from there. }
Also, some other questions.
For that routine, does it use a tilemap? What about the graphics, should they be compressed, or decompressed?
*edit*
NVM on the knowing when to restart. You just set the `next frame` value to 0.
I FEEL SILLY now. But the questions of tilemaps uncompressed/compressed still remains.
Although I have a feeling it's uncompressed with a tilemap...(GbaTek doesn't say swi 0xC uncompresses any data )
The routine I gave you doesn't load any tilemap, it just uses the one in the original titlescreen, so you can replace that one. All graphics are compressed.

EDIT: Also, I don't know where you got SWI 0xC from? The only SWI used is 0x12 (LZ77UnCompVram.)
__________________
あなた は しきしゃ です
わたし は ばか です

Last edited by Darthatron; March 28th, 2011 at 01:46 AM.
Reply With Quote
  #21    
Old March 28th, 2011, 05:08 AM
Full Metal's Avatar
Full Metal
C(++) Developer.
Community Supporter
 
Join Date: Jan 2008
Location: In my mind.
Age: 19
Gender: Male
Nature: Timid
Send a message via Windows Live Messenger to Full Metal
OH! I thought that was a decimal twelve, which I thought was odd. Awesome, thanks.

Okay...I must be doing something wrong.
I inserted my routine, and adjusted the original as you recommended ( I remembered to add 1 to the offset ) and I can view the titlescreen, and continue to the continue/new game screen. However...the swi function I think is causing some issues. It's copying *way* too much data, and it looks corrupt in the tile-viewer. ( I did insert two frames using unlz.GBA )



The Title Screen as it appears now.


Tile Viewer.
__________________

★ full metal.

I like to push it,
and push it,
until my luck is over.

Last edited by Full Metal; March 28th, 2011 at 01:58 PM. Reason: Your double post has been automatically merged.
Reply With Quote
  #22    
Old January 22nd, 2012, 08:50 AM
xephos's Avatar
xephos
xephos Inc.
 
Join Date: Jan 2012
Location: U.S.A
Gender: Male
Nature: Quiet
Nice. Is it possible to get objects moving left to fight ie: fireballs going left and right rather than up and down?
Reply With Quote
  #23    
Old January 24th, 2012, 03:54 PM
itari's Avatar
itari
Community Supporter
 
Join Date: Mar 2010
Location: 渦潮隠れの里
Age: 17
Gender: Female
Nature: Relaxed
Quote:
Originally Posted by xephos View Post
Nice. Is it possible to get objects moving left to fight ie: fireballs going left and right rather than up and down?
I would think so, you would just have to find where their animation is controlled.

Also, will you ever release your ASM on this?
__________________
Touhou Puppet Play: Sapphire

SubscriptAdvanced SongType Effectiveness EditorTilemap CreatorPython IPS Patcher
Reply With Quote
  #24    
Old January 24th, 2012, 05:46 PM
Darthatron's Avatar
Darthatron
巨大なトロール。
Community Supporter Tier 2
 
Join Date: Jan 2006
Location: Melbourne, Australia
Age: 22
Gender: Male
Nature: Modest
I already give it out to people who ask for it. But it's still messy, and uncommented.
__________________
あなた は しきしゃ です
わたし は ばか です
Reply With Quote
  #25    
Old July 27th, 2012, 03:07 PM
Robert Conley's Avatar
Robert Conley
GPXPlus.net/user/Robert+Conley
 
Join Date: Oct 2008
Location: The Anti Spiral Homeworld
Gender: Male
Nature: Docile
Are you still developing this? I don't know much about ASM but implementing this would kind of make it worth learning it in my opinion.
__________________
Reply With Quote
Reply
Quick Reply

Sponsored Links


Advertise here
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 03:49 PM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2014 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2014 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.