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!

TrollandToad.com
Reply
 
Thread Tools
  #1    
Old November 9th, 2010 (7:28 AM). Edited July 17th, 2014 by Shiny Quagsire.
Shiny Quagsire's Avatar
Shiny Quagsire Shiny Quagsire is offline
I'm Still Alive, Elsewhere
     
    Join Date: May 2009
    Location: Hoenn Safari Zone
    Age: 19
    Gender: Male
    Nature: Jolly
    Posts: 700
    OK, so me and xGGxToiZ have decided to release our knowledge to the general public. This knowledge is the knowledge of trainer animations!

    xGGxToiZ noticed the pointer I found to a blank animation while looking at the trainer's back animations (No, this is not the front animations!). Here's the origanal post:
    Spoiler:

    Quote:
    Originally Posted by shiny quagsire View Post
    I found some more animation data. It's huge though,
    Code:
    01 00 14 00
    02 00 06 00 
    03 00 06 00 
    04 00 18 00 
    00 00 01 00 
    FF FF 00 00
    
    01 00 14 00 
    02 00 06 00 
    03 00 06 00 
    04 00 18 00 
    00 00 01 00 
    FF FF 00 00 
    
    01 00 18 00 
    02 00 09 00 
    03 00 18 00 
    00 00 09 00 
    FF FF 00 00 
    
    01 00 18 00 
    02 00 09 00 
    03 00 18 00 
    00 00 09 00 
    FF FF 00 00 
    
    00 00 18 00 
    01 00 09 00 
    02 00 18 00 
    00 00 09 00 
    03 00 32 00 
    FF FF 00 00
     
    00 00 18 00 
    01 00 09 00 
    02 00 18 00 
    00 00 09 00 
    03 00 32 00 
    FF FF 00 00
    it's at offset 239EBB.There are 6 different trainers: the boy, the girl, trainer dude, old man, brendan, and may. plus, they're all the same!I played with the values, and it's correct. These are the animations for the trainer backsprites! Funny, there are pointers to 2347E8, which contains this:
    Code:
    00 00 00 00 FF FF 00 00
    I fiddled with the first value, the frame, and changed it to 05, and check out the result!

    Oh, and I was a boy at the time.


    It was quite odd, because it also led to the trainer's sprite, and several other things we don't know.

    So how do we do this? Simple! Let me quote xGGxTioZ:
    Quote:
    Originally Posted by xGGxTioZ
    Okay, each trainer sprite has their own pointer to E8 47 23 08. So I searched for that and voila!
    Code:
    Table starts at: 0x238E8C
    Select: 250h Bytes. (148d * 4d)
    This means, each trainer can have their own number of frames! Exciting, huh? And if we can expand it, who knows what are the possibilities!
    So, like he said, each trainer gets it's own animation pointer. So go to the table, and multiply your trainer's sprite's number (Starting from 0) by 4, and add it to the table offset. Now repoint the following pointer to free space, and write out your animation data. Here's how it works:

    Animation data is a sequence of 4 bytes, giving data on various information, and ends in FF FF 00 00.

    The first byte is the frame number from 0 Up to as many frames as you want!
    The second byte is unknown, but I'll look into the ASM coding to figure it out.
    The third byte is the duration. 0x10 is about a half second.
    The fourth byte is unknown

    The format is two bytes for the frame, two bytes for the duration. The values are simple flipped half-words.

    After you've typed up as many of these sequences you want, end it in FF FF 00 00. Here's one I used for Pokemon Chrome:

    Code:
    00 00 00 00
    02 00 FE 00
    02 00 30 00
    01 00 0F 00
    00 00 30 00
    FF FF 00 00
    I'm not sure why I used the 0's, but it works. This is a good example of going in any order. I went from my 3rd frame, to my second, to my first. The duration of 30 at the end delays when the pokemon are sent out.
    __________________



    Reply With Quote

    Relevant Advertising!

      #2    
    Old November 10th, 2010 (6:43 AM). Edited November 10th, 2010 by Diegoisawesome.
    Diegoisawesome's Avatar
    Diegoisawesome Diegoisawesome is offline
    Oh god the bees
    • Silver Tier
     
    Join Date: Dec 2007
    Location: :noitacoL
    Age: 20
    Gender: Male
    Nature: Naive
    Posts: 1,039
    Quote:
    Originally Posted by shiny quagsire View Post
    OK, so me and xGGxToiZ have decided to release our knowledge to the general public. This knowledge is the knowledge of trainer animations!
    I'm not entirely sure about this... This seems to be for trainer backsprites, but all throughout the thread, you mention "trainer sprites"...
    Is this for trainer front- or back-sprites?
    EDIT: I see. In this thread, there's info on the frames for back sprites AND for front sprites.
    Awesome!
    __________________


    My other resources:
    My Website
    diegoisawesome's MEGA-HUGE XSE Scripting Tutorial
    diegoisawesome's Miscellaneous Finds
    The Ruins of Alph Puzzles
    Diego's Miscellaneous Patches
    GBA Intro Manager
    The Secret Sauce: Triple-Layer Tiles
    Reply With Quote
      #3    
    Old November 10th, 2010 (6:50 AM).
    Shiny Quagsire's Avatar
    Shiny Quagsire Shiny Quagsire is offline
    I'm Still Alive, Elsewhere
       
      Join Date: May 2009
      Location: Hoenn Safari Zone
      Age: 19
      Gender: Male
      Nature: Jolly
      Posts: 700
      It's fro the front sprites. Each sprite has their own pointer in the table at 238E8C
      __________________



      Reply With Quote
        #4    
      Old November 10th, 2010 (6:54 AM).
      Diegoisawesome's Avatar
      Diegoisawesome Diegoisawesome is offline
      Oh god the bees
      • Silver Tier
       
      Join Date: Dec 2007
      Location: :noitacoL
      Age: 20
      Gender: Male
      Nature: Naive
      Posts: 1,039
      Quote:
      Originally Posted by shiny quagsire View Post
      It's fro the front sprites. Each sprite has their own pointer in the table at 238E8C
      Yeah, I saw. But there's also info for the back sprites, which is cool, too.
      __________________


      My other resources:
      My Website
      diegoisawesome's MEGA-HUGE XSE Scripting Tutorial
      diegoisawesome's Miscellaneous Finds
      The Ruins of Alph Puzzles
      Diego's Miscellaneous Patches
      GBA Intro Manager
      The Secret Sauce: Triple-Layer Tiles
      Reply With Quote
        #5    
      Old November 10th, 2010 (6:56 AM).
      Shiny Quagsire's Avatar
      Shiny Quagsire Shiny Quagsire is offline
      I'm Still Alive, Elsewhere
         
        Join Date: May 2009
        Location: Hoenn Safari Zone
        Age: 19
        Gender: Male
        Nature: Jolly
        Posts: 700
        Quote:
        Originally Posted by diegoisawesome View Post
        Yeah, I saw. But there's also info for the back sprites, which is cool, too.
        Yeah, that was how he found it. It was just actually a post from the pokemon animation thread.
        __________________



        Reply With Quote
          #6    
        Old November 10th, 2010 (7:02 AM).
        Diegoisawesome's Avatar
        Diegoisawesome Diegoisawesome is offline
        Oh god the bees
        • Silver Tier
         
        Join Date: Dec 2007
        Location: :noitacoL
        Age: 20
        Gender: Male
        Nature: Naive
        Posts: 1,039
        Quote:
        Originally Posted by shiny quagsire View Post
        Yeah, that was how he found it. It was just actually a post from the pokemon animation thread.
        Ahh, I see.
        Both are still interesting discoveries, though.
        __________________


        My other resources:
        My Website
        diegoisawesome's MEGA-HUGE XSE Scripting Tutorial
        diegoisawesome's Miscellaneous Finds
        The Ruins of Alph Puzzles
        Diego's Miscellaneous Patches
        GBA Intro Manager
        The Secret Sauce: Triple-Layer Tiles
        Reply With Quote
          #7    
        Old November 10th, 2010 (7:49 AM).
        altariaking's Avatar
        altariaking altariaking is offline
        Needs NO VMs...
           
          Join Date: Dec 2009
          Location: Scotland, Lesmahagow
          Age: 43
          Gender: Male
          Nature: Naive
          Posts: 1,098
          Yay! I already had the offset for Ruby but it's good to see you've released it to everyone now
          __________________
          http://www.pokecommunity.com/member.php?u=253113
          Reply With Quote
            #8    
          Old November 10th, 2010 (9:44 AM). Edited November 10th, 2010 by knizz.
          knizz's Avatar
          knizz knizz is offline
             
            Join Date: Aug 2007
            Posts: 192
            Great find! (Why didn't you tell me about this earlier?!)

            So... which animation is front and which is back?
            __________________
            Firered IDA 6.6 DB: https://www.dropbox.com/s/d856o3pyndyr5sr/firered.idb
            VBA-M with lua scripting support
            Reply With Quote
              #9    
            Old November 10th, 2010 (3:05 PM).
            Shiny Quagsire's Avatar
            Shiny Quagsire Shiny Quagsire is offline
            I'm Still Alive, Elsewhere
               
              Join Date: May 2009
              Location: Hoenn Safari Zone
              Age: 19
              Gender: Male
              Nature: Jolly
              Posts: 700
              Quote:
              Originally Posted by knizz View Post
              Great find! (Why didn't you tell me about this earlier?!)

              So... which animation is front and which is back?
              I couldn't tell you because I promised xGGxTioZ to keep it a secret. In fact, he posted this video in the pokemon animations thread. (Which he actually made, but he never told anyone that)

              Spoiler:


              The back animations are at 239EBB, and the front onse are in a table of pointers to each trainer's animation at 238E8C
              __________________



              Reply With Quote
                #10    
              Old September 24th, 2012 (3:20 PM).
              alypkm alypkm is offline
                 
                Join Date: Sep 2009
                Gender: Male
                Posts: 8
                please How can I animate the pokemon too in fire red ? and where do I put this code ?
                Reply With Quote
                  #11    
                Old September 24th, 2012 (5:27 PM).
                Shiny Quagsire's Avatar
                Shiny Quagsire Shiny Quagsire is offline
                I'm Still Alive, Elsewhere
                   
                  Join Date: May 2009
                  Location: Hoenn Safari Zone
                  Age: 19
                  Gender: Male
                  Nature: Jolly
                  Posts: 700
                  Quote:
                  Originally Posted by alypkm View Post
                  please How can I animate the pokemon too in fire red ? and where do I put this code ?
                  If you scrolled down in R&D you'd find it.
                  __________________



                  Reply With Quote
                    #12    
                  Old September 29th, 2012 (11:38 AM).
                  alypkm alypkm is offline
                     
                    Join Date: Sep 2009
                    Gender: Male
                    Posts: 8
                    Quote:
                    Originally Posted by shiny quagsire View Post
                    If you scrolled down in R&D .
                    I'm using the HEX editor in NSE..I searched the Sprite table and entered this code then the game freeze once I start a wild battle even after I added 2 sprites for the pokemon.

                    how do I repoint it to another offset ?
                    Reply With Quote
                      #13    
                    Old January 10th, 2013 (5:50 PM).
                    SneakyEpicface11's Avatar
                    SneakyEpicface11 SneakyEpicface11 is offline
                    PkMnMaster Ben
                       
                      Join Date: Dec 2012
                      Location: Johto
                      Gender: Male
                      Nature: Calm
                      Posts: 15
                      Hmm.... seems complicated... that is why I do not do rom hacking xD.
                      __________________
                      Hi, I'm SneakyEpicface11.
                      I'm 12 years old and like Pizza.
                      Pizza is my life... Just kidding.

                      "Go Rattata!" - Youngster Joey
                      Reply With Quote
                        #14    
                      Old April 12th, 2013 (3:14 PM).
                      BlackWhiteRobin's Avatar
                      BlackWhiteRobin BlackWhiteRobin is offline
                         
                        Join Date: Sep 2012
                        Age: 19
                        Gender: Male
                        Nature: Quirky
                        Posts: 539
                        What's the Final Code? I'm using FR and I need 3 frames each for some trainers. I can apply this to whoever I just want animated right?
                        __________________

                        Reply With Quote
                          #15    
                        Old April 12th, 2013 (10:24 PM).
                        Shiny Quagsire's Avatar
                        Shiny Quagsire Shiny Quagsire is offline
                        I'm Still Alive, Elsewhere
                           
                          Join Date: May 2009
                          Location: Hoenn Safari Zone
                          Age: 19
                          Gender: Male
                          Nature: Jolly
                          Posts: 700
                          Quote:
                          Originally Posted by robin22gongon View Post
                          What's the Final Code? I'm using FR and I need 3 frames each for some trainers. I can apply this to whoever I just want animated right?
                          Um, code? I guess the closest thing we have to code is ASM, but ff you mean hex it's at the bottom of the post.
                          __________________



                          Reply With Quote
                            #16    
                          Old April 30th, 2013 (10:37 PM).
                          hackstar's Avatar
                          hackstar hackstar is offline
                          Check it out!!
                             
                            Join Date: Jan 2013
                            Location: Dhaka
                            Gender: Male
                            Nature: Gentle
                            Posts: 243
                            Is animated trainer sprite is working?
                            __________________
                            Always FEEL CONFIDENT!!!
                            Reply With Quote
                              #17    
                            Old June 26th, 2013 (9:00 AM).
                            BugMania's Avatar
                            BugMania BugMania is offline
                            The Bug Master
                               
                              Join Date: Jun 2013
                              Gender: Male
                              Nature: Quiet
                              Posts: 32
                              at least in the pokemon party can put a loop.
                              __________________
                              Even the smallest of beings can achieve the greatest of obstacles!
                              Click in the spoiler, if you dare!
                              Spoiler:


                              L
                              et's dream bigger than our bodies can endure!
                              G
                              et to the extreme!

                              See my works here

                              Reply With Quote
                                #18    
                              Old October 24th, 2013 (2:28 PM).
                              BugMania's Avatar
                              BugMania BugMania is offline
                              The Bug Master
                                 
                                Join Date: Jun 2013
                                Gender: Male
                                Nature: Quiet
                                Posts: 32
                                Instead of using the HEX code, podemon well use a space in memory of the ROM.

                                example:

                                Go to the 0x82349BC.
                                You'll notice that the code uses an offset to 0x823499C, ie 9C 49 23 08.

                                To have an offset memory, we replace XX XX XX 08 to XX XX XX 02

                                In the end, find a space memory FREE, and inserted a routine battle system that changes the bytes FF FF 00 00 to FE FF 00 00.

                                I'm sorry that I did not bring the solution ready.


                                And of course, my bad English.
                                __________________
                                Even the smallest of beings can achieve the greatest of obstacles!
                                Click in the spoiler, if you dare!
                                Spoiler:


                                L
                                et's dream bigger than our bodies can endure!
                                G
                                et to the extreme!

                                See my works here

                                Reply With Quote
                                  #19    
                                Old December 3rd, 2014 (11:56 AM).
                                BLAx501!'s Avatar
                                BLAx501! BLAx501! is offline
                                Pokemon Flux
                                   
                                  Join Date: Oct 2013
                                  Location: Madrid, Spain
                                  Gender: Male
                                  Nature: Gentle
                                  Posts: 77
                                  Sorry for reviving this post but since I got working the animated sprites for Pokemon, I wanted to get some trainers animated too. The only problem I find came when I have to add the frames. I've been trying all evening diferent ways to do it without getting anything correct... So I summon you Shiny Quagsire... How did you do to add the frames?
                                  Reply With Quote
                                    #20    
                                  Old December 3rd, 2014 (1:58 PM).
                                  Shiny Quagsire's Avatar
                                  Shiny Quagsire Shiny Quagsire is offline
                                  I'm Still Alive, Elsewhere
                                     
                                    Join Date: May 2009
                                    Location: Hoenn Safari Zone
                                    Age: 19
                                    Gender: Male
                                    Nature: Jolly
                                    Posts: 700
                                    Quote:
                                    Originally Posted by BLAxTOISE View Post
                                    So I summon you Shiny Quagsire...


                                    Quote:
                                    Originally Posted by BLAxTOISE View Post
                                    How did you do to add the frames?
                                    Basically you just format your different frames vertically like you would do for Pokemon for the trainer image you want to animate, and then find that sprite's index in the animation table and create an animation for it.
                                    __________________



                                    Reply With Quote
                                      #21    
                                    Old December 3rd, 2014 (4:10 PM). Edited December 4th, 2014 by BLAx501!.
                                    BLAx501!'s Avatar
                                    BLAx501! BLAx501! is offline
                                    Pokemon Flux
                                       
                                      Join Date: Oct 2013
                                      Location: Madrid, Spain
                                      Gender: Male
                                      Nature: Gentle
                                      Posts: 77
                                      Quote:
                                      Originally Posted by Shiny Quagsire View Post
                                      Basically you just format your different frames vertically like you would do for Pokemon for the trainer image you want to animate, and then find that sprite's index in the animation table and create an animation for it.
                                      Thank you so much man, I've done it succesfuly :D

                                      Tomorrow or so I'll post here a short tutorial of how I did it step by step, and also I'll complete the information about the frames parameters since they work the same way animated Pokemon Sprites do. It's better to have all the info on the same place xD
                                      Reply With Quote
                                        #22    
                                      Old December 6th, 2014 (9:57 AM).
                                      AtecainCorp.'s Avatar
                                      AtecainCorp. AtecainCorp. is online now
                                      Rejishan awake...
                                         
                                        Join Date: Jun 2008
                                        Location: Takoabe Town (Region Thonsu)
                                        Age: 24
                                        Gender: Male
                                        Nature: Hardy
                                        Posts: 1,266
                                        One important thing. Where is the Trainer Sprite Showing limiter in Ruby and Fire Red? It can make some issues after adding animations sice Limiter disable to show extra sprites
                                        __________________
                                        - My new Project comming Soon
                                        Reply With Quote
                                        Reply

                                        Quick Reply

                                        Join the conversation!

                                        Create an account to post a reply in this thread, participate in other discussions, and more!

                                        Create a PokéCommunity Account

                                        Sponsored Links
                                        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

                                        Forum Jump


                                        All times are GMT -8. The time now is 2:28 PM.