ROM Hacking Need a helping hand? You can get help on any ROM Hacking-related problems or questions you have here.

Draconius GO
Closed Thread
 
Thread Tools
  #8551    
Old August 3rd, 2013 (10:05 AM).
Renegade's Avatar
Renegade Renegade is offline
Time for real life...
     
    Join Date: Nov 2011
    Location: United States
    Gender: Male
    Nature: Careful
    Posts: 998
    Quote:
    Originally Posted by QuilavaKing View Post
    Thanks, this got it working (I guess you have to specify an unused var number even if you don't need one in the script?), although he takes more than one step... he actually walked all the way off screen, and I'm permanently locked in place, even with the 0xFE. I'll mess around with it and see if I can get it working on my own, but here's what I have just in case you can get me an answer faster than I can. lol
    Code:
    ;---------------
    #org 0x80017C
    applymovement 0x5 0x8800188
    waitmovement 0x5
    end
    
    
    ;-----------
    ; Movements
    ;-----------
    #org 0x800188
    #raw 0x8 ;Step Down (Normal)
    #raw 0xFE ;End of Movements
    I don't what that walking off screen thing is about (because I haven't followed this thread in a while) but you need to put "release" before "end" to free your character from being locked in place.

    Relevant Advertising!

      #8552    
    Old August 3rd, 2013 (2:44 PM).
    Marohak's Avatar
    Marohak Marohak is offline
    Asker of Dumb Questions
       
      Join Date: Aug 2013
      Location: South Africa
      Age: 30
      Gender: Male
      Nature: Quirky
      Posts: 20
      Wow, gonna be using this thread alot :D

      Using XSE, if I change nothing of a script except the speech, the lines go over each other.
      What can I do to fix this?
        #8553    
      Old August 3rd, 2013 (4:25 PM).
      destinedjagold's Avatar
      destinedjagold destinedjagold is offline
      Oh Hai Thar~
      • Silver Tier
       
      Join Date: May 2007
      Location: Philippines
      Age: 27
      Gender: Male
      Nature: Careful
      Posts: 8,574
      Quote:
      Originally Posted by QuilavaKing View Post
      Thanks, this got it working (I guess you have to specify an unused var number even if you don't need one in the script?), although he takes more than one step... he actually walked all the way off screen, and I'm permanently locked in place, even with the 0xFE. I'll mess around with it and see if I can get it working on my own, but here's what I have just in case you can get me an answer faster than I can. lol
      Code:
      ;---------------
      #org 0x80017C
      applymovement 0x5 0x8800188
      waitmovement 0x5
      end
      
      
      ;-----------
      ; Movements
      ;-----------
      #org 0x800188
      #raw 0x8 ;Step Down (Normal)
      #raw 0xFE ;End of Movements
      As CrystalStatic stated, add a "release" command right before the "end" command.
      Code:
      #org 0x80017C
      applymovement 0x5 0x8800188
      waitmovement 0x5
      release
      end
      Also, I absolutely have NO idea why your NPC walked all the way with just one single stepping command. =/


      Quote:
      Originally Posted by Marohak View Post
      Wow, gonna be using this thread alot :D

      Using XSE, if I change nothing of a script except the speech, the lines go over each other.
      What can I do to fix this?
      Write a new speech and point the script to your new speech script: link for a small tutorial.
      __________________


      FC: 0061-1111-6462
      TSV: 1364(X), 0790(OR)

        #8554    
      Old August 3rd, 2013 (7:34 PM). Edited August 3rd, 2013 by Alice.
      Alice's Avatar
      Alice Alice is offline
      (>^.(>0.0)>
      • Crystal Tier
       
      Join Date: Mar 2009
      Location: Oregon
      Age: 25
      Gender: Female
      Nature: Careful
      Posts: 3,081
      Thanks, release stopped him from from taking more than one step and it all works fine now.

      I have about a billion other questions, but I'll start with this one... When I setvar 0x4000 1 (or 0x1, tried both) nothing seems to happen. Based on DrFuji's explanation, I thought that if the script's var number, set in advance map, was 4000, with a var value of 0, setting it to 1 in the script should cause the script to no longer execute after that... but it does. Am I wrong? Not sure what I did differently, but this is working now.

      So, this is what I've got so far... You start in your bed, and when you take one step out, your mom comes up the stairs and walks up to you to tell you some intro-y stuff. I have a few problems though. First of all, how do I make your mom invisible until the script starts? As it is, she's just standing on the stairs. Second, how can I make her actually stay hidden once the script ends. As soon as I take a step, she reappears. I've also tried movesprite(and hidespritepos) to get her out of the way, and she still came back on top of the stairs. Also, how do I play the stair sound effect? (I think it'd just be the normal sound effect that plays when you warp.)
      Spoiler:
      #dynamic 0x800198

      #org @main
      msgbox @2talk1 0x6
      applymovement 0x1 @1move1
      waitmovement 0x1
      msgbox @3talk2 0x6
      applymovement 0x1 @4move2
      waitmovement 0x1
      hidesprite 0x1
      setvar 0x4000 0x1
      release
      end

      #org @1move1
      #raw 0x8 ;Down
      #raw 0x8
      #raw 0x8
      #raw 0xA ;Left
      #raw 0xA
      #raw 0xA
      #raw 0xA
      #raw 0xFE ;End Move

      #org @2talk1
      = \v\h01?\pOh good, you're up.

      #org @3talk2
      = Blah blah.

      #org @4move2
      #raw 0x0B ;right
      #raw 0x0B
      #raw 0x0B
      #raw 0x0B
      #raw 0x09 ;Up
      #raw 0x09
      #raw 0x09
      #raw 0xFE ;End

      And another question that I can't seem to find anywhere... how do I give the player the pokedex (and national dex)? Specifically for Ruby... I can find a million tutorials for everything with FR/LG, but nothing on RSE.
        #8555    
      Old August 3rd, 2013 (11:05 PM).
      Satoshi Ookami's Avatar
      Satoshi Ookami Satoshi Ookami is offline
      Memento Mori
      • Gold Tier
       
      Join Date: Jul 2008
      Location: Abyss of Time, Great Seal
      Age: 25
      Gender: Male
      Nature: Calm
      Posts: 14,508
      Quote:
      Originally Posted by jsziede View Post
      Because QuilavaKing is having trouble with his script, he doesn't want to keep wasting bytes with trashy scripts. #Clean will overwrite the newly compiled script to the last used #dynamic offset.
      I know what clean does... I was asking why he had to write it into the script

      Quote:
      Originally Posted by QuilavaKing View Post
      Code:
      ;---------------
      #org 0x80017C
      applymovement 0x5 0x8800188
      waitmovement 0x5
      end
      
      
      ;-----------
      ; Movements
      ;-----------
      #org 0x800188
      #raw 0x8 ;Step Down (Normal)
      #raw 0xFE ;End of Movements
      Can I advise something? It's best to use waitmovement 0x0 as it's pause that works everytime.

      Quote:
      Originally Posted by QuilavaKing View Post
      And another question that I can't seem to find anywhere... how do I give the player the pokedex (and national dex)? Specifically for Ruby... I can find a million tutorials for everything with FR/LG, but nothing on RSE.
      You should have checked my "About Me" xD

      National Dex Ruby:
      writebytetooffset 0x2 0x2026B00
      writebytetooffset 0x3 0x2026B01
      writebytetooffset 0xDA 0x2024EBE
      writebytetooffset 0x67 0x2026A5A
      __________________
      ROM hacking FAQ - Read before asking how to play a hack.

      Anime List | PSN Trophy List
        #8556    
      Old August 3rd, 2013 (11:30 PM).
      destinedjagold's Avatar
      destinedjagold destinedjagold is offline
      Oh Hai Thar~
      • Silver Tier
       
      Join Date: May 2007
      Location: Philippines
      Age: 27
      Gender: Male
      Nature: Careful
      Posts: 8,574
      Quote:
      Originally Posted by QuilavaKing View Post
      First of all, how do I make your mom invisible until the script starts?
      You can simply put her into ‘Hidden’ through Advance Map, and just add the ‘show’ command (it's 0x55 in Ruby, but not sure in FireRed) in each applymovement of your script.

      Quote:
      Originally Posted by QuilavaKing View Post
      Second, how can I make her actually stay hidden once the script ends. As soon as I take a step, she reappears.
      If you will follow my suggestion in your first question, then she'll automatically disappear.
      If however, you will choose a different way, then to permanently make her invisible, use the ‘hidesprite 0x’ and immediately followed by a ‘setflag’ command.
      Make sure that you are setting the flag that she has.


      Quote:
      Originally Posted by QuilavaKing View Post
      Also, how do I play the stair sound effect? (I think it'd just be the normal sound effect that plays when you warp.)
      I believe that there's a command ‘sound’, but I never actually tried that yet.
      Although I am quite sure that there's a documented list of sounds in the game.
      I believe that the thread is located in the Resource and Development section.


      Quote:
      Originally Posted by QuilavaKing View Post
      And another question that I can't seem to find anywhere... how do I give the player the pokedex (and national dex)? Specifically for Ruby... I can find a million tutorials for everything with FR/LG, but nothing on RSE.
      As Ash493 stated, copy that code and place them right after the flag for the PokéDex.
      __________________


      FC: 0061-1111-6462
      TSV: 1364(X), 0790(OR)

        #8557    
      Old August 4th, 2013 (8:41 AM).
      Alice's Avatar
      Alice Alice is offline
      (>^.(>0.0)>
      • Crystal Tier
       
      Join Date: Mar 2009
      Location: Oregon
      Age: 25
      Gender: Female
      Nature: Careful
      Posts: 3,081
      Quote:
      Originally Posted by destinedjagold View Post
      As Ash493 stated, copy that code and place them right after the flag for the PokéDex.
      How to activate the pokedex was what I was actually asking for. I actually found that bit of code in an earlier post of yours while searching this thread shortly after posting that, but I still can't find anything on how to activate the regular pokedex... I've been searching for hours on multiple sites, and it just doesn't exist (for R/S)... while we're on it, I'll also need to know how to activate the pokemon menu, give badges, etc. I've found all this stuff for FR/LG already several times, but again, not for R/S.
        #8558    
      Old August 4th, 2013 (8:59 AM).
      pokefreake's Avatar
      pokefreake pokefreake is offline
         
        Join Date: Nov 2012
        Gender: Male
        Posts: 69
        Quote:
        Originally Posted by QuilavaKing View Post
        How to activate the pokedex was what I was actually asking for. I actually found that bit of code in an earlier post of yours while searching this thread shortly after posting that, but I still can't find anything on how to activate the regular pokedex... I've been searching for hours on multiple sites, and it just doesn't exist (for R/S)... while we're on it, I'll also need to know how to activate the pokemon menu, give badges, etc. I've found all this stuff for FR/LG already several times, but again, not for R/S.
        Just open the scripts where these happen. If you want to learn how to give a gym badge open a script of a gym leader and look through it.
          #8559    
        Old August 4th, 2013 (9:40 AM). Edited August 4th, 2013 by Alice.
        Alice's Avatar
        Alice Alice is offline
        (>^.(>0.0)>
        • Crystal Tier
         
        Join Date: Mar 2009
        Location: Oregon
        Age: 25
        Gender: Female
        Nature: Careful
        Posts: 3,081
        Quote:
        Originally Posted by pokefreake View Post
        Just open the scripts where these happen. If you want to learn how to give a gym badge open a script of a gym leader and look through it.
        Believe me, I tried that (with the pokedex anyway) and couldn't figure it out at all. The only thing that even seemed possible was special 0x9E, but that opened the nicknaming screen. I finally found it with google though, so I've got it figured out now. Although, on a route with no pokemon data, I found a level 47 sunflora in the grass after activating the pokedex... not a problem yet afaik, because I can just set pokemon data and hopefully it won't happen, but just a strange little side effect lol.
          #8560    
        Old August 4th, 2013 (10:36 AM).
        Avara's Avatar
        Avara Avara is offline
        Author Of Tales
        • Moderator
         
        Join Date: Dec 2011
        Location: Avlar
        Gender: Female
        Nature: Adamant
        Posts: 650
        Worried that I may have screwed something up a lot in my rom, for some reason whenever i give an item, instead of the automatic "PLAYER received a _" message, this appears...
        [I can't post a URL link because havent had 15 posts... but it says

        " en't
        available..."


        Can anyone help me? I hope i havent ruined my rom, unfortunately the problem is present in all my backups and ive been working on it for 5 months so really dont want to start over... Thanks to anyone who can tell me how to fix this
        __________________
        x
        Luna <3
          #8561    
        Old August 4th, 2013 (10:39 AM).
        pokefreake's Avatar
        pokefreake pokefreake is offline
           
          Join Date: Nov 2012
          Gender: Male
          Posts: 69
          Quote:
          Originally Posted by avaramoon View Post
          Worried that I may have screwed something up a lot in my rom, for some reason whenever i give an item, instead of the automatic "PLAYER received a _" message, this appears...
          [I can't post a URL link because havent had 15 posts... but it says

          " en't
          available..."


          Can anyone help me? I hope i havent ruined my rom, unfortunately the problem is present in all my backups and ive been working on it for 5 months so really dont want to start over... Thanks to anyone who can tell me how to fix this
          Can you post the script here?
            #8562    
          Old August 4th, 2013 (10:57 AM). Edited August 4th, 2013 by Avara.
          Avara's Avatar
          Avara Avara is offline
          Author Of Tales
          • Moderator
           
          Join Date: Dec 2011
          Location: Avlar
          Gender: Female
          Nature: Adamant
          Posts: 650
          Quote:
          Originally Posted by pokefreake View Post
          Can you post the script here?

          it is happening in every giveitem script I make. I've even tried using "giveitem2" to try and fix the problem but when I tried that the game froze.

          I'm using FR ROM and JPAN's Clearing Patch (NOT hacked engine)

          Spoiler:

          '---------------
          #org 0x725F70
          lock
          faceplayer
          checkflag 0x1200
          if 0x1 goto 0x8725F95
          msgbox 0x8725FA0 MSG_NORMAL '"Hi there! Have you just graduated\..."
          giveitem 0x2 0x1 MSG_OBTAIN
          setflag 0x1200
          release
          end
          '---------------
          #org 0x725F95
          msgbox 0x872605E MSG_NORMAL '"ULTRA BALLs are, in my opinion,\nt..."
          release
          end

          '---------
          ' Strings
          '---------
          #org 0x725FA0
          = Hi there! Have you just graduated\nfrom the POKéMON School? I'm a\lPOKéMART representative. You can\lhave this free sample. It's an\lULTRA BALL that will come in\lhandy when catching POKéMON!
          #org 0x72605E
          = ULTRA BALLs are, in my opinion,\nthe best kind of BALL to use when\lcapturing POKéMON.



          Did some research on my last post and found something odd.

          I opened up my ROM in ItemEditor and it came up with an error message, all the data was totally corrupted and messed up. It was sadly the same for all of my backup roms, even the ones I saved at earlier times, but the funny thing is I opened my clean, untouched roms and the same thing happened? has anyone heard of this
          __________________
          x
          Luna <3
            #8563    
          Old August 4th, 2013 (1:27 PM).
          destinedjagold's Avatar
          destinedjagold destinedjagold is offline
          Oh Hai Thar~
          • Silver Tier
           
          Join Date: May 2007
          Location: Philippines
          Age: 27
          Gender: Male
          Nature: Careful
          Posts: 8,574
          Quote:
          Originally Posted by QuilavaKing View Post
          How to activate the pokedex was what I was actually asking for. I actually found that bit of code in an earlier post of yours while searching this thread shortly after posting that, but I still can't find anything on how to activate the regular pokedex... I've been searching for hours on multiple sites, and it just doesn't exist (for R/S)... while we're on it, I'll also need to know how to activate the pokemon menu, give badges, etc. I've found all this stuff for FR/LG already several times, but again, not for R/S.
          Activating the Pokedex is simply just activating its flag with the setflag command.
          The Pokedex flag is 0x801 in Ruby, 0x829 in FireRed and 0x861 in Emerald.
          __________________


          FC: 0061-1111-6462
          TSV: 1364(X), 0790(OR)

            #8564    
          Old August 4th, 2013 (1:42 PM).
          pokefreake's Avatar
          pokefreake pokefreake is offline
             
            Join Date: Nov 2012
            Gender: Male
            Posts: 69
            Quote:
            Originally Posted by avaramoon View Post
            it is happening in every giveitem script I make. I've even tried using "giveitem2" to try and fix the problem but when I tried that the game froze.

            I'm using FR ROM and JPAN's Clearing Patch (NOT hacked engine)

            Spoiler:

            '---------------
            #org 0x725F70
            lock
            faceplayer
            checkflag 0x1200
            if 0x1 goto 0x8725F95
            msgbox 0x8725FA0 MSG_NORMAL '"Hi there! Have you just graduated\..."
            giveitem 0x2 0x1 MSG_OBTAIN
            setflag 0x1200
            release
            end
            '---------------
            #org 0x725F95
            msgbox 0x872605E MSG_NORMAL '"ULTRA BALLs are, in my opinion,\nt..."
            release
            end

            '---------
            ' Strings
            '---------
            #org 0x725FA0
            = Hi there! Have you just graduated\nfrom the POKéMON School? I'm a\lPOKéMART representative. You can\lhave this free sample. It's an\lULTRA BALL that will come in\lhandy when catching POKéMON!
            #org 0x72605E
            = ULTRA BALLs are, in my opinion,\nthe best kind of BALL to use when\lcapturing POKéMON.



            Did some research on my last post and found something odd.

            I opened up my ROM in ItemEditor and it came up with an error message, all the data was totally corrupted and messed up. It was sadly the same for all of my backup roms, even the ones I saved at earlier times, but the funny thing is I opened my clean, untouched roms and the same thing happened? has anyone heard of this
            Were your patches backed up to your computer or somewhere online? If it was online can you send me a link to the patch? Maybe your computer is messing up the files somehow.
            Also does it say " en't
            available..." in advance text too?
              #8565    
            Old August 4th, 2013 (1:52 PM). Edited August 4th, 2013 by Alice.
            Alice's Avatar
            Alice Alice is offline
            (>^.(>0.0)>
            • Crystal Tier
             
            Join Date: Mar 2009
            Location: Oregon
            Age: 25
            Gender: Female
            Nature: Careful
            Posts: 3,081
            Quote:
            Originally Posted by destinedjagold View Post
            Activating the Pokedex is simply just activating its flag with the setflag command.
            The Pokedex flag is 0x801 in Ruby, 0x829 in FireRed and 0x861 in Emerald.
            Yeah, I was able to find it after a lot of googling. I really wish there was a sticky thread that has all this information in one place... you'd get a lot less repeated questions here, I'm sure.

            Thanks for all the help though. I'm a good ways into my plot scripts now, and I'm having no issues atm. Couldn't have done it without you. lol (Although, I'm sure I'll have more questions at some point. lol)



            Okay, I've found something really strange now... is there a limit to the number of movements per sprite per script? I have quite a few in this script (about 230 lines total) and for this last movement I was doing, only the first part happens.

            Here it is:
            Spoiler:
            #org @playerMove8
            #raw 0x0B
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0xFE

            The player moves right once and that's it. He's following the professor back to the lab at this point, and the professor goes all the way to the lab no problem, but the player only moves once. I've tried deleting the professor's last move, and switching the order of them in the code, and either way he only moves once. Is there any way around this?
              #8566    
            Old August 4th, 2013 (5:23 PM).
            destinedjagold's Avatar
            destinedjagold destinedjagold is offline
            Oh Hai Thar~
            • Silver Tier
             
            Join Date: May 2007
            Location: Philippines
            Age: 27
            Gender: Male
            Nature: Careful
            Posts: 8,574
            Quote:
            Originally Posted by QuilavaKing View Post
            I really wish there was a sticky thread that has all this information in one place... you'd get a lot less repeated questions here, I'm sure.
            There are, although not stickied. They're called “scripting tutorials” in the Tutorials section.

            Quote:
            Originally Posted by QuilavaKing View Post
            Okay, I've found something really strange now... is there a limit to the number of movements per sprite per script? I have quite a few in this script (about 230 lines total) and for this last movement I was doing, only the first part happens.

            Here it is:
            Spoiler:
            #org @playerMove8
            #raw 0x0B
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x08
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0x0B
            #raw 0xFE

            The player moves right once and that's it. He's following the professor back to the lab at this point, and the professor goes all the way to the lab no problem, but the player only moves once. I've tried deleting the professor's last move, and switching the order of them in the code, and either way he only moves once. Is there any way around this?
            Post your entire script.
            What you provided is not really helpful.
            __________________


            FC: 0061-1111-6462
            TSV: 1364(X), 0790(OR)

              #8567    
            Old August 4th, 2013 (7:13 PM).
            Alice's Avatar
            Alice Alice is offline
            (>^.(>0.0)>
            • Crystal Tier
             
            Join Date: Mar 2009
            Location: Oregon
            Age: 25
            Gender: Female
            Nature: Careful
            Posts: 3,081
            Quote:
            Originally Posted by destinedjagold View Post
            There are, although not stickied. They're called “scripting tutorials” in the Tutorials section.
            I know, I'm using DiegoIsAwesome's for most of my information, but it's very much incomplete. All of the tutorials are. All of the information is available, but it's spread out so much that it's very difficult to find, plus 99% of the tutorials are done for FR/LG, not R/S, so finding specific flags, specials, etc for these games has been very difficult.


            Quote:
            Originally Posted by destinedjagold View Post
            Post your entire script.
            What you provided is not really helpful.

            I have no idea what I did differently, but now it just works... this seems to be happening a lot. Several times now, something has been broken completely, and I go away for a little bit and then without even changing the script it works again.
              #8568    
            Old August 5th, 2013 (4:02 PM).
            Shubunkus's Avatar
            Shubunkus Shubunkus is offline
            I.R.
               
              Join Date: Jul 2012
              Gender: Male
              Nature: Bold
              Posts: 49
              So, I have a script which works completely fine except for the fadescreen commands. I want the screen to fade until the end of the script but for some reason it won't stay faded. I even added a pause in there to try to delay when the screen fades back to normal but it won't work. The idea that the script is supposed to execute is unfinished but I wanted to test it before continuing. Can anyone let me know what I am doing wrong? PS. the character starts in black tiles if you need to know.

              Spoiler:
              #clean
              #dynamic 0x800200

              #org @start
              lock
              fadescreen 0x1
              setvar 0x7000 0x1
              setweather 0x5
              doweather
              special 0x113
              applymovement 0x7F @move1
              waitmovement 0x0
              special 0x114
              pause 0x20
              fadescreen 0x0
              end

              #org @move1
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0x1E
              #raw 0xFE
              __________________
                #8569    
              Old August 5th, 2013 (9:44 PM).
              Alice's Avatar
              Alice Alice is offline
              (>^.(>0.0)>
              • Crystal Tier
               
              Join Date: Mar 2009
              Location: Oregon
              Age: 25
              Gender: Female
              Nature: Careful
              Posts: 3,081
              So, I'm having a strange issue with showpokepic. Spent the better part of today searching for fixes or anyone having the same problem at all, and can't find anything. This is what it looks like:

              Here's the whole script. It uses the player's position to determine which pokeball he's looking at, so I can use the same script on all three of them. I've tried removing that and changing the vars used, and it hasn't helped.
              Code:
              #dynamic 0x801E9C
              
              #org @main
              lock
              getplayerpos 0x4000 0x4001
              compare 0x4000 0x6
              if 0x1 goto @bulbasaurDisplay
              release
              end
              
              ;---------------------------BULBASAUR STUFFS------------------------------
              #org @bulbasaurDisplay
              cry 0x1 0x0
              showpokepic 0x1 0xA 0x3
              msgbox @bulbasaurMessage1 0x5
              closeonkeypress
              compare 0x800D 0x1
              if 0x1 goto @bulbasaurChoose
              hidepokepic
              end
              
              #org @bulbasaurChoose
              hidepokepic
              givepokemon 0x1 0x5 0x0 0x0 0x0 0x0
              fanfare 0x13E
              msgbox @bulbasaurMessage2 0x4
              waitfanfare
              closeonkeypress
              setflag 0x800 ;activate pokemon menu
              hidesprite 0x5
              setflag 0x1206 
              end
              
              #org @bulbasaurMessage1
              = Do you want to take\nthe GRASS type BULBASAUR?
              
              #org @bulbasaurMessage2
              = \v\h01 received the BULBASAUR!
              ;-------------------------------------------------------------------------
              Attached Images
              File Type: png blackasaur.png‎ (4.4 KB, 81 views) (Save to Dropbox)
                #8570    
              Old August 5th, 2013 (10:07 PM).
              Renegade's Avatar
              Renegade Renegade is offline
              Time for real life...
                 
                Join Date: Nov 2011
                Location: United States
                Gender: Male
                Nature: Careful
                Posts: 998
                Quote:
                Originally Posted by QuilavaKing View Post
                So, I'm having a strange issue with showpokepic. Spent the better part of today searching for fixes or anyone having the same problem at all, and can't find anything. This is what it looks like:

                Here's the whole script. It uses the player's position to determine which pokeball he's looking at, so I can use the same script on all three of them. I've tried removing that and changing the vars used, and it hasn't helped.
                Code:
                #dynamic 0x801E9C
                
                #org @main
                lock
                getplayerpos 0x4000 0x4001
                compare 0x4000 0x6
                if 0x1 goto @bulbasaurDisplay
                release
                end
                
                ;---------------------------BULBASAUR STUFFS------------------------------
                #org @bulbasaurDisplay
                cry 0x1 0x0
                showpokepic 0x1 0xA 0x3
                msgbox @bulbasaurMessage1 0x5
                closeonkeypress
                compare 0x800D 0x1
                if 0x1 goto @bulbasaurChoose
                hidepokepic
                end
                
                #org @bulbasaurChoose
                hidepokepic
                givepokemon 0x1 0x5 0x0 0x0 0x0 0x0
                fanfare 0x13E
                msgbox @bulbasaurMessage2 0x4
                waitfanfare
                closeonkeypress
                setflag 0x800 ;activate pokemon menu
                hidesprite 0x5
                setflag 0x1206 
                end
                
                #org @bulbasaurMessage1
                = Do you want to take\nthe GRASS type BULBASAUR?
                
                #org @bulbasaurMessage2
                = \v\h01 received the BULBASAUR!
                ;-------------------------------------------------------------------------
                This happened to me when I used to hack R/S/E. I'm not sure what the problem is, but just throwing a wild guess out there: Try giving the player the National Pokedex (because bulbasaur is not from the Hoen region) before the "showpokepic" command is executed. I've had this problem before, and I tried everything that I could to fix it but I never tried the National Pokedex.
                  #8571    
                Old August 5th, 2013 (10:53 PM).
                Satoshi Ookami's Avatar
                Satoshi Ookami Satoshi Ookami is offline
                Memento Mori
                • Gold Tier
                 
                Join Date: Jul 2008
                Location: Abyss of Time, Great Seal
                Age: 25
                Gender: Male
                Nature: Calm
                Posts: 14,508
                Quote:
                Originally Posted by Shubunkus View Post
                So, I have a script which works completely fine except for the fadescreen commands. I want the screen to fade until the end of the script but for some reason it won't stay faded. I even added a pause in there to try to delay when the screen fades back to normal but it won't work. The idea that the script is supposed to execute is unfinished but I wanted to test it before continuing. Can anyone let me know what I am doing wrong? PS. the character starts in black tiles if you need to know.

                Spoiler:
                #clean
                #dynamic 0x800200

                #org @start
                lock
                fadescreen 0x1
                setvar 0x7000 0x1
                setweather 0x5
                doweather
                special 0x113
                applymovement 0x7F @move1
                waitmovement 0x0
                special 0x114
                pause 0x20
                fadescreen 0x0
                end

                #org @move1
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0x1E
                #raw 0xFE
                Can I advise not to use so many movements? IIRC my scripting days there's a limit to how many movements can be executed in one applymovement for script to work...
                It's better to have the OW hidden and then just show it with applymovement =)
                __________________
                ROM hacking FAQ - Read before asking how to play a hack.

                Anime List | PSN Trophy List
                  #8572    
                Old August 5th, 2013 (10:58 PM).
                Alice's Avatar
                Alice Alice is offline
                (>^.(>0.0)>
                • Crystal Tier
                 
                Join Date: Mar 2009
                Location: Oregon
                Age: 25
                Gender: Female
                Nature: Careful
                Posts: 3,081
                Quote:
                Originally Posted by CrystalStatic View Post
                This happened to me when I used to hack R/S/E. I'm not sure what the problem is, but just throwing a wild guess out there: Try giving the player the National Pokedex (because bulbasaur is not from the Hoen region) before the "showpokepic" command is executed. I've had this problem before, and I tried everything that I could to fix it but I never tried the National Pokedex.
                The player already has the pokedex and national dex at this point. =/ I tried it without having the pokedex too, and got the same result. I also just tested it with treecko (used 277) instead of bulbasaur, and got this:
                Attached Images
                File Type: png treecko.png‎ (4.5 KB, 80 views) (Save to Dropbox)
                  #8573    
                Old August 5th, 2013 (11:01 PM).
                mikefromindyindy's Avatar
                mikefromindyindy mikefromindyindy is offline
                EDM producer/ pokemon hacker
                   
                  Join Date: Aug 2013
                  Age: 23
                  Gender: Male
                  Nature: Quiet
                  Posts: 7
                  I'm trying to add a script (Person Event) in my Pokémon emerald to activate an "in-game" trade with an npc..(ADD a trade, not edit one.) I've looked EVERYWHERE for tutorial's on this and have literally found not one, in fact, its the sole purpose I even created an account at this website..
                  if anyone could help with this or even point me in the right direction, it would be GREATLY appreciated.
                    #8574    
                  Old August 5th, 2013 (11:07 PM). Edited August 5th, 2013 by Wobbu.
                  Wobbu's Avatar
                  Wobbu Wobbu is offline
                  Drag a needle on the good today
                     
                    Join Date: Mar 2012
                    Location: Stardew Valley
                    Gender: Male
                    Nature: Relaxed
                    Posts: 2,797
                    Quote:
                    Originally Posted by QuilavaKing View Post
                    The player already has the pokedex and national dex at this point. =/ I tried it without having the pokedex too, and got the same result. I also just tested it with treecko (used 277) instead of bulbasaur, and got this:
                    This worked fine for me.
                    excerpt:
                    Code:
                    showpokepic 0x53 0xA 0x3
                    msgbox @msg 0x5
                    hidepokepic
                    The message says something like 'Farfetch'd, the Wild Duck Pokémon. Is this the Pokémon you want?'
                    You may want to check if the actual sprites aren't corrupted.

                    Quote:
                    Originally Posted by mikefromindyindy View Post
                    I'm trying to add a script (Person Event) in my Pokémon emerald to activate an "in-game" trade with an npc..(ADD a trade, not edit one.) I've looked EVERYWHERE for tutorial's on this and have literally found not one, in fact, its the sole purpose I even created an account at this website..
                    if anyone could help with this or even point me in the right direction, it would be GREATLY appreciated.
                    Welcome to PC :D
                    If you're using XSE, then read this.

                    WARNING: MASSIVE WALL OF TEXT!
                    WARNING: MASSIVE WALL OF TEXT!
                    WARNING: MASSIVE WALL OF TEXT!
                    Spoiler:
                    In-Game Trades
                    Bellsprout For Onix...





                    In-Game trades are often those that you find in the game where NPCs ask if you would want to exchange a pokémon for theirs. Here we'll learn to reproduce a trade script which is particularly useful if you have more than one trade slots available and can help make a hack more interesting. Anyway, we won't be teaching you how to modify a trade cause that can be done with an trade editor so since you know what specials, flags, variables are then you would do fine, if not then go back to those topics to recap. Let's take a look at the example which is decompiled from the game and study it before making our own.

                    Example:
                    '---------------
                    #org 0x16A9B1
                    lock // locks the sprite movement
                    faceplayer // sprite faces the player
                    setvar 0x8008 0x1 // sets value of variable 0x8008 to 0x1
                    call 0x81A8CAD // calls a branch before returning at 0x1A8CAD
                    checkflag 0x24A // the script returns and checks flag 0x24A
                    if 0x1 goto 0x816AA23 // if the flag is enabled goto 0x16AA23
                    msgbox 0x81A59FE MSG_YESNO '"Hello, there! Do you happen to\nha..." // asks a question - Yes/No
                    compare LASTRESULT 0x0 // compares LASTRESULT if its value is 0x0 - for No
                    if 0x1 goto 0x816AA0B // if LASTRESULT is 0x0 - No, the script jumps to 0x16AA0B if Yes then continues
                    call 0x81A8CBD // the result is Yes and again it jumps to another offset 0x1A8CBD
                    compare 0x8004 0x6 // compares 0x8004 if its equal to 0x6
                    if 0x4 goto 0x816AA0B // if the value of 0x8004 is smaller than equal to the script jumps to 0x16AA0B
                    call 0x81A8CC9 // calls another offset 0x1A8CC9
                    comparevars2 LASTRESULT 0x8009 // compares if the value LASTRESULT is equal to the value of 0x8009
                    if 0x5 goto 0x816AA15 // if LASTRESULT's value is not equal to value at 0x8009 script jumps to 0x16AA15
                    call 0x81A8CD9 // calls another branch of the script at 0x1A8CD9
                    msgbox 0x81A5A9D MSG_KEEPOPEN '"Thanks!" // displays a Keep Open msg at 0x1A5A9D
                    setflag 0x24A // sets flag 0x24A
                    release // sprite resumes movement and the textbox can be closed
                    end // ends script execution

                    '---------------
                    #org 0x1A8CAD
                    copyvar 0x8004 0x8008 // copies value of 0x8004 to 0x8008
                    special2 LASTRESULT 0xFC // script uses special2 0xfc to retain a returned value to LASTRESULT
                    copyvar 0x8009 LASTRESULT // copies value at 0x8009 to LASTRESULT
                    return // script returns where it was last called

                    '---------------
                    #org 0x16AA23
                    msgbox 0x81A5AA5 MSG_KEEPOPEN '"The [buffer2] that I traded you,\n..." // displays msg at 0x1A5AA5
                    release // sprite resumes movement and the textbox can be closed
                    end // ends script execution

                    '---------------
                    #org 0x16AA0B
                    msgbox 0x81A5A4E MSG_KEEPOPEN '"Well, if you don't want to[.]" // displays msg at 0x1A5A4E
                    release // sprite resumes movement and the textbox can be closed
                    end // ends script execution

                    '---------------
                    #org 0x1A8CBD
                    special 0x9F // script uses special 0x9f which chooses a pokemon in the party
                    waitstate // script is in waitstate waiting for the special
                    lock // locks the sprites movement
                    faceplayer // sprite faces the player
                    copyvar 0x800A 0x8004 // copies value at 0x800A to 0x8004
                    return // script returns where it was last called

                    '---------------
                    #org 0x1A8CC9
                    copyvar 0x8005 0x800A // copies value at 0x8005 to 0x800A
                    special2 LASTRESULT 0xFF // uses special 0xFF and stores returned value at LASTRESULT
                    copyvar 0x800B LASTRESULT // copies value at 0x800B to LASTRESULT
                    return // script returns where it was last called

                    '---------------
                    #org 0x16AA15
                    bufferpokemon 0x0 0x8009 // stores the pokemon name value in 0x8009 to [buffer1]
                    msgbox 0x81A5A6A MSG_KEEPOPEN '"Hmmm?\nThis isn't a [buffer1].\pTh..." // displays msg at 0x1A5A6A
                    release // sprite resumes movement and the textbox can be closed
                    end // ends script execution

                    '---------------
                    #org 0x1A8CD9
                    copyvar 0x8004 0x8008 // copies value at 0x8004 to 0x8008
                    copyvar 0x8005 0x800A // copies value at 0x8005 to 0x800A
                    special 0xFD // special 0xFD is used
                    special 0xFE // special 0xFE is also used
                    waitstate // script is in waiting state waiting for the specials
                    lock // locks the sprite
                    faceplayer // sprite faces the player
                    return // script returns where it was last called


                    '---------
                    ' Strings
                    '---------
                    #org 0x1A59FE
                    = Hello, there! Do you happen to\nhave a [buffer1]?\pWould you agree to a trade for\nmy [buffer2]?

                    #org 0x1A5A9D
                    = Thanks!

                    #org 0x1A5AA5
                    = The [buffer2] that I traded you,\nhas it grown stronger?

                    #org 0x1A5A4E
                    = Well, if you don't want to[.]

                    #org 0x1A5A6A
                    = Hmmm?\nThis isn't a [buffer1].\pThink of me if you get one.
                    Phew... Okay the commenting should be pretty much and very much straight forward and you should be able to understand. Well, here's the parts of the script that can be modified:

                    setvar 0x8008 0x1 // 0x1 is the trade number
                    checkflag 0x24A // 24A is the trade flag and is checked if the trade has occurred or not
                    setflag 0x24A // 24A is set meaning the trade has occurred

                    Please note that Fire Red has 9 trade slots which in hex starts at 0 and ends at 8, of course you can add more but you will need to repoint. With those three above factors in mind let's build a original trade script.

                    Example 2:

                    #dynamic 0x800000

                    #org @start
                    lock
                    faceplayer
                    setvar 0x8008 0x8
                    call 0x1A8CAD
                    checkflag 0x1000
                    if 0x1 goto @how
                    msgbox @yesno 0x5
                    compare LASTRESULT 0x0
                    if 0x1 goto @too
                    call 0x1A8CBD
                    compare 0x8004 0x6
                    if 0x4 goto @too
                    call 0x1A8CC9
                    comparevars2 LASTRESULT 0x8009
                    if 0x5 goto @not
                    call 0x1A8CD9
                    msgbox @thanksalot 0x4
                    setflag 0x1000
                    release
                    end

                    #org @not
                    bufferpokemon 0x0 0x8009
                    msgbox @not2 0x4
                    release
                    end

                    #org @too
                    bufferpokemon 0x0 0x8009
                    msgbox @too2 0x4
                    release
                    end

                    #org @how
                    msgbox @old 0x4
                    release
                    end

                    #org @thanksalot
                    = Thanks man!\nI really mean it!

                    #org @not2
                    = That's not [buffer1]\nYou have it or not?

                    #org @too2
                    = Darn, I wanted one [buffer1]!

                    #org @yesno
                    = Hey there!\nDo you have a [buffer1]?\lWant to trade it for my\l[buffer2]?

                    #org @old
                    = I miss [buffer2]\nYour [buffer1] is doing fine.

                    Done! We've reproduced a new script which calls trade number 9. Remember all those calls are system based branches - for Fire Red. You can build a same one but why waste space when the game originally have them. For Ruby, Sapphire, and Emerald the script may differ due to a different format but these are same:

                    setvar 0x8008 0xTT
                    checkflag 0xFlag
                    setflag 0xFlag
                    TT = Trade Number
                    Flag = Any working flag - both should be same

                    As for editing the trade data use a program built for that purpose .







                    --------------------------------------------------------------------------------


                    Copyright © 2008 HackMew. All rights reserved. Special thanks to Martin™ and ZodiacDaGreat.
                    __________________

                    My Favorite Song
                      #8575    
                    Old August 5th, 2013 (11:12 PM).
                    Satoshi Ookami's Avatar
                    Satoshi Ookami Satoshi Ookami is offline
                    Memento Mori
                    • Gold Tier
                     
                    Join Date: Jul 2008
                    Location: Abyss of Time, Great Seal
                    Age: 25
                    Gender: Male
                    Nature: Calm
                    Posts: 14,508
                    Quote:
                    Originally Posted by QuilavaKing View Post
                    The player already has the pokedex and national dex at this point. =/ I tried it without having the pokedex too, and got the same result. I also just tested it with treecko (used 277) instead of bulbasaur, and got this:
                    Are you sure it's Treecko? Haven't you accidentally written the number of one of 25 ???s?
                    __________________
                    ROM hacking FAQ - Read before asking how to play a hack.

                    Anime List | PSN Trophy List
                    Closed Thread

                    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 10:02 AM.