The PokéCommunity Forums Fan Games ROM Hacking
Script Help Thread (DO NOT REQUEST SCRIPTS)

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


Closed Thread
 
Thread Tools
  #5051    
Old January 7th, 2011 (7:23 AM).
metapod23's Avatar
metapod23 metapod23 is offline
Hardened Trainer
     
    Join Date: Mar 2009
    Gender: Male
    Nature: Timid
    Posts: 673
    Quote:
    Originally Posted by Silent the Lucario View Post
    Thanks dude :D i figured out the other flag thing but i still couldn't get the after message to work so thank you also could you help me to make it that this person talks to you after you do more stuff like for example get all eight badges or something :D[/spoiler]
    The eighth badge is activated by setting flag 0x827, so just use checkflag 0x827 and have it go to the script you want if it's set.

    Quote:
    anyway here are some more scripts that i need help with

    Spoiler:
    #dynamic 0x800000

    #org @start
    trainerbattle 0x0 0x002 0x0 @intro @defeat
    msgbox @msg 0x2
    hidesprite 9
    end

    #org @intro
    = Yo, you must be a new trainer.\nLet's battle

    #org @defeat
    = Me the Champion lost to a\nrookie....I'll be waiting for you\lin Hoenn!

    #org @msg
    = Meet me in Hoenn...[player]

    ----------------------
    #org 0x212F31
    trainerbattle 0x1 0x109 0x0 0x821362A 0x821370B 0x8212F66
    special2 LASTRESULT 0x3C
    compare LASTRESULT 0x1
    if 0x1 goto 0x8212FC8
    checkflag 0xA5
    if 0x0 goto 0x8212FA4
    msgbox 0x82139A7 '"Since you are so strong, you should..."
    callstd 0x4
    release
    end

    '-----------------------
    #org 0x212F66
    msgbox2 0x82137EC '"[player] received the HYPNOSIS BADGE\n..."
    waitmsgbox
    call 0x827207E
    msgbox 0x8213816 '"The HYPNOSIS BADGE heightens the ATTAC..."
    callstd 0x4
    setflag 0x4F0
    setflag 0x867
    setvar 0x405A 0x1
    addvar 0x4085 0x1
    setvar 0x8008 0x1
    call 0x8271F43
    compare 0x4085 0x6
    if 0x1 call 0x8271E84
    goto 0x8212FA4
    end

    '-----------------------
    #org 0x212FC8
    trainerbattle 0x7 0x109 0x0 0x8213C2F 0x8213CF9 0x8213D93
    msgbox 0x8213D12 '"WALLY: I still have much to learn..."
    callstd 0x6
    end

    '-----------------------
    #org 0x212FA4
    giveitem 0x147 0x1 0x0
    compare LASTRESULT 0x0
    if 0x1 goto 0x8272054
    setflag 0xA5
    msgbox 0x82138B1 '"That TECHNICAL MACHINE, TM39,\ncont..."
    callstd 0x4
    release
    end

    '-----------------------
    #org 0x27207E
    fanfare 0x171
    waitfanfare
    return

    '-----------------------
    #org 0x271F43
    copyvar 0x8000 0x8008
    compare 0x8000 0x1
    if 0x1 goto 0x8271FA1
    compare 0x8000 0x2
    if 0x1 goto 0x8271FAB
    compare 0x8000 0x3
    if 0x1 goto 0x8271FBE
    compare 0x8000 0x4
    if 0x1 goto 0x8271FCE
    compare 0x8000 0x5
    if 0x1 goto 0x8271FE7
    compare 0x8000 0x6
    if 0x1 goto 0x8271FFD
    compare 0x8000 0x7
    if 0x1 goto 0x8272010
    compare 0x8000 0x8
    if 0x1 goto 0x8272035
    end

    '-----------------------
    #org 0x271E84
    clearflag 0x30D
    setflag 0x128
    return

    '-----------------------
    #org 0x272054
    msgbox 0x8272AD0 '"Too bad!\nThe BAG is full[.]"
    callstd 0x4
    release
    end

    '-----------------------
    #org 0x271FA1
    cleartrainerflag 0x140
    cleartrainerflag 0x141
    cleartrainerflag 0x23B
    return

    '-----------------------
    #org 0x271FAB
    cleartrainerflag 0xB3
    cleartrainerflag 0x1A9
    cleartrainerflag 0x1AA
    cleartrainerflag 0x23C
    cleartrainerflag 0x23E
    cleartrainerflag 0x23D
    return

    '-----------------------
    #org 0x271FBE
    cleartrainerflag 0xBF
    cleartrainerflag 0xC2
    cleartrainerflag 0x143
    cleartrainerflag 0x289
    cleartrainerflag 0x322
    return

    '-----------------------
    #org 0x271FCE
    cleartrainerflag 0xC9
    cleartrainerflag 0xCB
    cleartrainerflag 0xCD
    cleartrainerflag 0x288
    cleartrainerflag 0x28A
    cleartrainerflag 0xCC
    cleartrainerflag 0xCA
    cleartrainerflag 0x1F5
    return

    '-----------------------
    #org 0x271FE7
    cleartrainerflag 0x47
    cleartrainerflag 0x48
    cleartrainerflag 0x49
    cleartrainerflag 0x4A
    cleartrainerflag 0x59
    cleartrainerflag 0x5A
    cleartrainerflag 0x5B
    return

    '-----------------------
    #org 0x271FFD
    cleartrainerflag 0x191
    cleartrainerflag 0x28E
    cleartrainerflag 0x28F
    cleartrainerflag 0x194
    cleartrainerflag 0x192
    cleartrainerflag 0x323
    return

    '-----------------------
    #org 0x272010
    cleartrainerflag 0xE9
    cleartrainerflag 0xEA
    cleartrainerflag 0xEB
    cleartrainerflag 0xF4
    cleartrainerflag 0xF5
    cleartrainerflag 0xF6
    cleartrainerflag 0x23F
    cleartrainerflag 0x246
    cleartrainerflag 0x247
    cleartrainerflag 0x248
    cleartrainerflag 0x24F
    cleartrainerflag 0x249
    return

    '-----------------------
    #org 0x272035
    cleartrainerflag 0x265
    cleartrainerflag 0x266
    cleartrainerflag 0x76
    cleartrainerflag 0x80
    cleartrainerflag 0x81
    cleartrainerflag 0x82
    cleartrainerflag 0x83
    cleartrainerflag 0x12D
    cleartrainerflag 0x1F6
    cleartrainerflag 0x73
    return


    '---------
    ' Strings
    '---------
    #org 0x21362A
    = = Hello I am Wally,the Palpolis Gym\nLeader! I became a Gym leader so I\lcan show that Psychic types can be\lgood using phsyical and\lnon-phsyical move! I hope you take\lme seriously!

    #org 0x21370B
    = So[.]\nI lost[.]\pIt seems that I still have much more\nto learn[.]\pI understand.\pThe POKéMON LEAGUE's rules state\nthat TRAINERS are to be given this\lif they defeat a GYM LEADER.\pPlease accept the official POKéMON\nLEAGUE HYPNOSIS BADGE.

    #org 0x2139A7
    = Since you are so strong, you should\nchallenge other GYM LEADERS.\pBy battling many TRAINERS, you should\nlearn many things.

    #org 0x2137EC
    = [player] received the HYPNOSIS BADGE\nfrom ROXANNE.

    #org 0x213816
    = The HYPNOSIS BADGE heightens the ATTACK\npower of your POKéMON.\pIt also enables them to use the HM move\nCUT outside of battle.\pPlease take this with you, too.

    #org 0x213C2F
    = WALLY: I'm so glad to see you again.\nI'm WALLY, the GYM LEADER here.\pI'm sure we've both experienced many\nbattles since we last met.\pI would like to see how much better\nwe've become. Let us battle!

    #org 0x213CF9
    = Grr[.]\nAgain, I have lost[.]

    #org 0x213D93
    = WALLY: I'm so glad to see you again.\nI'm WALLY, the GYM LEADER here.\pI'm sure we've both experienced many\nbattles since we last met.\pI would like to see how much better\nwe've become[.]\pOh, no[.]\nYou only have one POKéMON with you?\pPlease return with at least one more\nPOKéMON.

    #org 0x213D12
    = WALLY: I still have much to learn\nwhen it comes to battling POKéMON.\pThat awareness makes me love battling\nall that much more!

    #org 0x2138B1
    = That TECHNICAL MACHINE, TM29,\ncontains PSYCHIC.\pIt not only inflicts damage by tapping\ninto psychic powers\pIf you use a TM, it instantly teaches\nthe move to a POKéMON.\pRemember, a TM can be used only once,\nso think before you use it.

    #org 0x272AD0
    = Too bad!\nThe BAG is full[.]
    #dynamic 0x800000
    #org @main
    msgbox @msg 0x2
    end

    #org @msg
    = Prof.ELM's House


    I'll send rest later (i have like 10 or 15 more :D)
    As Binary said, not sure what all the problems are with the scripts you have, you have to say what you're having trouble with. The first one, with the hidesprite, you might need to put a flag number in the person's ID and put setflag 0x(flag number in person's ID) in the script to make the sprite permanently hidden.
    __________________

    Relevant Advertising!

      #5052    
    Old January 7th, 2011 (11:35 AM).
    Nomad_Mu's Avatar
    Nomad_Mu Nomad_Mu is offline
       
      Join Date: Sep 2010
      Location: Foot of the Mountain, Misery
      Age: 27
      Gender: Male
      Nature: Adamant
      Posts: 12
      What is the command to enable/activate the PokéDex? So far I've only been able to find the National Dex command.
      __________________
      There is no such thing as overkill, just sufficient firepower.
      Current Project:
        #5053    
      Old January 7th, 2011 (11:53 AM).
      Binary's Avatar
      Binary Binary is offline
      え?
         
        Join Date: Aug 2007
        Age: 23
        Posts: 3,992
        Quote:
        Originally Posted by Nomad_Mu View Post
        What is the command to enable/activate the PokéDex? So far I've only been able to find the National Dex command.
        Assuming it's for FR/LG, the flag 0x829 activates Pokedex Menu.
        __________________
          #5054    
        Old January 7th, 2011 (11:53 AM).
        Hi-Techneon's Avatar
        Hi-Techneon Hi-Techneon is offline
           
          Join Date: Dec 2010
          Location: Belgium
          Age: 20
          Gender: Male
          Nature: Rash
          Posts: 228
          Quote:
          Originally Posted by Nomad_Mu View Post
          What is the command to enable/activate the PokéDex? So far I've only been able to find the National Dex command.
          It uses a flag. Flag 0x801 for Ruby if I'm right. Use setflag to enable it and clearflag to disable it.
          __________________

          VDex:
          White:
            #5055    
          Old January 7th, 2011 (11:59 AM). Edited January 7th, 2011 by Nomad_Mu.
          Nomad_Mu's Avatar
          Nomad_Mu Nomad_Mu is offline
             
            Join Date: Sep 2010
            Location: Foot of the Mountain, Misery
            Age: 27
            Gender: Male
            Nature: Adamant
            Posts: 12
            Major edit, I missed the post by Binary. Thank you both.
            Yes, I am working on a FireRed hack, sorry I forgot to mention that.

            Would there be any problems by activating both the PokéDex and National Dex at the same time?
            __________________
            There is no such thing as overkill, just sufficient firepower.
            Current Project:
              #5056    
            Old January 7th, 2011 (12:12 PM).
            Binary's Avatar
            Binary Binary is offline
            え?
               
              Join Date: Aug 2007
              Age: 23
              Posts: 3,992
              Quote:
              Originally Posted by Nomad_Mu View Post
              Major edit, I missed the post by Binary. Thank you both.
              Yes, I am working on a FireRed hack, sorry I forgot to mention that.

              Would there be any problems by activating both the PokéDex and National Dex at the same time?
              None that I know of. There shouldn't be any problems.
              Haven't really tried though.
              __________________
                #5057    
              Old January 7th, 2011 (12:15 PM).
              Hi-Techneon's Avatar
              Hi-Techneon Hi-Techneon is offline
                 
                Join Date: Dec 2010
                Location: Belgium
                Age: 20
                Gender: Male
                Nature: Rash
                Posts: 228
                Quote:
                Originally Posted by Nomad_Mu View Post
                Major edit, I missed the post by Binary. Thank you both.
                Yes, I am working on a FireRed hack, sorry I forgot to mention that.

                Would there be any problems by activating both the PokéDex and National Dex at the same time?
                There shouldn't be any problems since the PokéDex is active once you start your game, but it isn't visible in the menu until you use the setflag command to make it visible in the menu.
                __________________

                VDex:
                White:
                  #5058    
                Old January 7th, 2011 (6:21 PM). Edited January 7th, 2011 by Silent the Lucario.
                Silent the Lucario's Avatar
                Silent the Lucario Silent the Lucario is offline
                Novice Mapper
                   
                  Join Date: Apr 2010
                  Location: Somewhere in Hoenn
                  Gender: Male
                  Nature: Relaxed
                  Posts: 27
                  I don't need any help with those scipts anymore :D their useless now :P

                  Edit: I need help with this script

                  Spoiler:
                  #include stdpoke.rbh
                  #dynamic 0x800000

                  #org @start
                  checkflag 0x827
                  checkflag 0x2000
                  if 0x1 goto @stealbadges
                  checkflag 0x1000
                  checkflag 0x828
                  checkflag 0x829
                  if 0x1 goto @nomore
                  msgbox @starters 0x2
                  givepokemon PKMN_MAGBY 0x10 0x0 0x0 0x0 0x0
                  givepokemon PKMN_PICHU 0x10 0x0 0x0 0x0 0x0
                  setflag 0x1000
                  setflag 0x828
                  setflag 0x829
                  end

                  #org @stealbadges
                  msgbox @gottosteal 0x2
                  clearflag 0x820
                  clearflag 0x821
                  clearflag 0x822
                  clearflag 0x823
                  clearflag 0x824
                  clearflag 0x825
                  clearflag 0x826
                  clearflag 0x827
                  setflag 0x1001
                  end

                  #org @gottosteal
                  = I'm taking your badges so you can\ngo to the new region and start\lyour journey there! Don't worry\lthey'll let you fight them! I'm\lsure!

                  #org @nomore
                  checkflag 0x1002
                  if 0x1 goto @annoy
                  msgbox @giveno 0x2
                  setflag 0x1002
                  end

                  #org @giveno
                  = Go on your journey! But make sure\nto come back after you have beaten\lthe Elite Four! I'll have\lsomething to give you!

                  #org @annoy
                  msgbox @annoying 0x2
                  end

                  #org @annoying
                  = Just leave already!

                  #org @starters
                  = Sky: Hello [player] I'm Profeesor\nSky! This is my pokemon Lab! I\lassume you are here for a starter\lright?\p[player]: Yes Proffessor I've been\nwaiting my whole life to get a\lPokemon\pSky: Well [player] your not just\ngetting one but, two pokemon!\p[player]: Awesome!\pSky: Yes I know. Anyway I'm also\ngiving you a pokedex make sure to\lkeep it safe!\p[player]: Yes Proffessor! Thank\nyou!\pSky: No problem! Now get started\non your Journey!


                  It keeps on going to a part of the script that only happens when you get the eighth gym badge and when the champion activates a flag :( and i don't have the eighth gym badge nor did I even put the champion script in the game yet :(
                  __________________
                  I support all nintendo handheld hacking.

                  ---------------------------------------------------------------------------
                  I'm novice mapper and a Intermediate scripter

                  If you need any help with scripting don't refrain to ask!
                  Pokemon Emerald Rules!


                  Hacks I support:




                  Pokemon Shinygold


                  Please click my egg it'll get lonely :( :P



                    #5059    
                  Old January 7th, 2011 (6:33 PM). Edited January 14th, 2011 by phantom12.
                  phantom12 phantom12 is offline
                     
                    Join Date: May 2010
                    Posts: 4
                    when ever i try this script the chareter just freezes in spot.
                    It is supposed to make a sprite move to the right, trainer battle and then give a item


                    [b]Game: ruby
                    [b]Type: script
                    [b]Editor: xse
                    [/spoiler]
                    #dynamic 0x291403
                    '---------------
                    #org @start
                    lock
                    checkflag 0x7
                    if 0x0 goto @snippet1
                    release
                    end
                    '---------------
                    #org @snippet1
                    msgbox @string1 0x6 '"Beat it! i'm working hear."
                    applymovement 0x1 @move1
                    waitmovement 0x0
                    trainerbattle 0x0 0x8 0x0 @string2 @string3
                    msgbox @string4 0x6 '"How could my virus pokemon fail i\..."
                    giveitem 0x1 0xA 0x0
                    setflag 0x7
                    release
                    end

                    '---------
                    ' Strings
                    '---------
                    #org @string1
                    = Beat it! i'm working hear.
                    #org @string2
                    = Go! my virus pokemon.
                    #org @string3
                    = Time for me to escape.
                    #org @string4
                    = How could my virus pokemon fail i\nhave to retreat for now.\pPOKEDEX: he dropped something.

                    '-----------
                    ' Movements
                    '-----------
                    #org @move1
                    #raw 0x24 'Step on the Spot Right (Faster)
                    #raw 0x24 'Step on the Spot Right (Faster)
                    #raw 0x24 'Step on the Spot Right (Faster)
                    #raw 0x24 'Step on the Spot Right (Faster)
                    #raw 0x24 'Step on the Spot Right (Faster)
                    #raw 0x24 'Step on the Spot Right (Faster)
                    #raw 0xFE 'End of Movements
                      #5060    
                    Old January 7th, 2011 (9:10 PM).
                    metapod23's Avatar
                    metapod23 metapod23 is offline
                    Hardened Trainer
                       
                      Join Date: Mar 2009
                      Gender: Male
                      Nature: Timid
                      Posts: 673
                      Quote:
                      Originally Posted by Silent the Lucario View Post
                      I don't need any help with those scipts anymore :D their useless now :P

                      Edit: I need help with this script

                      Spoiler:
                      #include stdpoke.rbh
                      #dynamic 0x800000

                      #org @start
                      checkflag 0x827
                      if 0x1 goto @stealbadges
                      checkflag 0x2000
                      if 0x1 goto @stealbadges
                      checkflag 0x1000
                      if 0x1 goto @nomore
                      checkflag 0x828
                      if 0x1 goto @nomore
                      checkflag 0x829
                      if 0x1 goto @nomore

                      msgbox @starters 0x2
                      givepokemon PKMN_MAGBY 0x10 0x0 0x0 0x0 0x0
                      givepokemon PKMN_PICHU 0x10 0x0 0x0 0x0 0x0
                      setflag 0x1000
                      setflag 0x828
                      setflag 0x829
                      end

                      #org @stealbadges
                      checkflag 0x1001
                      if 0x1 goto @end

                      msgbox @gottosteal 0x2
                      clearflag 0x820
                      clearflag 0x821
                      clearflag 0x822
                      clearflag 0x823
                      clearflag 0x824
                      clearflag 0x825
                      clearflag 0x826
                      clearflag 0x827
                      setflag 0x1001
                      end

                      #org @end
                      * script you want to run after the badges are deactivated


                      #org @gottosteal
                      = I'm taking your badges so you can\ngo to the new region and start\lyour journey there! Don't worry\lthey'll let you fight them! I'm\lsure!

                      #org @nomore
                      checkflag 0x1002
                      if 0x1 goto @annoy
                      msgbox @giveno 0x2
                      setflag 0x1002
                      end

                      #org @giveno
                      = Go on your journey! But make sure\nto come back after you have beaten\lthe Elite Four! I'll have\lsomething to give you!

                      #org @annoy
                      msgbox @annoying 0x2
                      end

                      #org @annoying
                      = Just leave already!

                      #org @starters
                      = Sky: Hello [player] I'm Profeesor\nSky! This is my pokemon Lab! I\lassume you are here for a starter\lright?\p[player]: Yes Proffessor I've been\nwaiting my whole life to get a\lPokemon\pSky: Well [player] your not just\ngetting one but, two pokemon!\p[player]: Awesome!\pSky: Yes I know. Anyway I'm also\ngiving you a pokedex make sure to\lkeep it safe!\p[player]: Yes Proffessor! Thank\nyou!\pSky: No problem! Now get started\non your Journey!


                      It keeps on going to a part of the script that only happens when you get the eighth gym badge and when the champion activates a flag :( and i don't have the eighth gym badge nor did I even put the champion script in the game yet :(
                      Some changes in bold - not sure why you're setting three flags (0x1000, 0x828, and 0x829) and needing to check all three of them. Whatever it's for, you probably only need to check flag 0x1000 at the beginning of the script, anyway.

                      If you need the @stealbadges script to activate only when both flags (0x827 and 0x1000) are active, it would have to be like this:

                      Code:
                      checkflag 0x827
                      if 0x1 goto @check2
                      ......
                      
                      #org @check2
                      checkflag 0x1000
                      if 0x1 goto @stealbadges
                      (rest of script)
                      __________________
                        #5061    
                      Old January 7th, 2011 (9:19 PM).
                      SnapTime's Avatar
                      SnapTime SnapTime is offline
                         
                        Join Date: Dec 2010
                        Gender: Male
                        Posts: 48
                        Hey guys im having a problem with my script still. Its been awhile and I still cant figure it out.
                        After the battle, the rival says his lines and then disappears without doing the movement first.
                        Here's the script.

                        Quote:
                        #dyn 0x740000
                        #org @begin
                        trainerbattle 0x1 0x211 0x0 @intro @defeat @after
                        end

                        #org @after
                        lock
                        msgbox @afterwards
                        callstd msg_normal
                        applymovement 0x10 @move
                        pauseevent 0x0
                        disappear LASTTALKED
                        setflag 0x251
                        release
                        end

                        #org @intro
                        = I will crush you!!!

                        #org @defeat
                        = You crushed me[.]

                        #org @afterwards
                        = I can also say something after the battle.

                        #org @move
                        = m walk_up walk_right walk_right walk_right walk_right walk_right walk_right walk_right walk_right end
                        Here's the events log in AM which i think might be the problem.
                          #5062    
                        Old January 7th, 2011 (11:28 PM).
                        destinedjagold's Avatar
                        destinedjagold destinedjagold is online now
                        Oh Hai Thar~
                         
                        Join Date: May 2007
                        Location: Philippines
                        Age: 27
                        Gender: Male
                        Nature: Careful
                        Posts: 8,579
                        your problem is the applymovement 0x10 @move line...
                        Remember that 10 and 0x10 are not the same.
                        So either use applymovement 10 @move or applymovement 0xA @move...
                        __________________

                          #5063    
                        Old January 8th, 2011 (6:55 AM).
                        Silent the Lucario's Avatar
                        Silent the Lucario Silent the Lucario is offline
                        Novice Mapper
                           
                          Join Date: Apr 2010
                          Location: Somewhere in Hoenn
                          Gender: Male
                          Nature: Relaxed
                          Posts: 27
                          I fixed the script :D i just needed to talk to the person from behind and it worked perfectly :D
                          __________________
                          I support all nintendo handheld hacking.

                          ---------------------------------------------------------------------------
                          I'm novice mapper and a Intermediate scripter

                          If you need any help with scripting don't refrain to ask!
                          Pokemon Emerald Rules!


                          Hacks I support:




                          Pokemon Shinygold


                          Please click my egg it'll get lonely :( :P



                            #5064    
                          Old January 8th, 2011 (8:04 AM).
                          SnapTime's Avatar
                          SnapTime SnapTime is offline
                             
                            Join Date: Dec 2010
                            Gender: Male
                            Posts: 48
                            Quote:
                            Originally Posted by destinedjagold View Post
                            your problem is the applymovement 0x10 @move line...
                            Remember that 10 and 0x10 are not the same.
                            So either use applymovement 10 @move or applymovement 0xA @move...
                            Thanks so much for helping me out, well now my script looks like this:
                            Quote:
                            #org 0x874110A
                            '-----------------------------------
                            trainerbattle 0x1 0x211 0x0 0x874682C 0x87487E2 0x8746785
                            end

                            #org 0x8746785
                            '-----------------------------------
                            lock
                            msgbox 0x8750248 ' I can also say somet...
                            callstd MSG_LOCK ' Built-in lock command
                            applymovement 0xA 0x885D5B2 ' walk_up walk_right w...
                            pauseevent 0x0
                            disappear LASTTALKED
                            setflag 0x251
                            release
                            end


                            #org 0x874682C
                            = I will crush you!!!

                            #org 0x87487E2
                            = You crushed me[.]

                            #org 0x8750248
                            = I can also say something after the battle.

                            #org 0x885D5B2
                            M walk_up walk_right walk_right walk_right walk_right walk_right walk_right end
                            After the battle, he talks to you, then pauses, then disappears with no movement.
                              #5065    
                            Old January 8th, 2011 (11:52 AM).
                            Hi-Techneon's Avatar
                            Hi-Techneon Hi-Techneon is offline
                               
                              Join Date: Dec 2010
                              Location: Belgium
                              Age: 20
                              Gender: Male
                              Nature: Rash
                              Posts: 228
                              Quote:
                              Originally Posted by SnapTime View Post
                              Thanks so much for helping me out, well now my script looks like this:


                              After the battle, he talks to you, then pauses, then disappears with no movement.
                              Not sure or it works, but try applymovement LASTTALKED OFFSET, it might work :)
                              __________________

                              VDex:
                              White:
                                #5066    
                              Old January 8th, 2011 (12:22 PM).
                              SnapTime's Avatar
                              SnapTime SnapTime is offline
                                 
                                Join Date: Dec 2010
                                Gender: Male
                                Posts: 48
                                Quote:
                                Originally Posted by Hi-Techneon View Post
                                Not sure or it works, but try applymovement LASTTALKED OFFSET, it might work :)
                                thanks but that didnt work either :(
                                the script looks fine to me.
                                I think its a problem with my event log maybe. Or maybe because hes a trainer and its not an actual script?
                                  #5067    
                                Old January 9th, 2011 (9:30 AM).
                                Atterny's Avatar
                                Atterny Atterny is offline
                                Pokemon Scarlet Head Hacker
                                   
                                  Join Date: Jan 2010
                                  Age: 22
                                  Gender: Male
                                  Nature: Naive
                                  Posts: 5
                                  Ruby
                                  Person Script (givepokemon)

                                  Spoiler:
                                  #dynamic 0x801B51

                                  #org @start
                                  checkflag 0x8D3
                                  if 0x1 goto @done
                                  msgbox @1 0x5
                                  compare LASTRESULT 0x1
                                  if 0x1 goto @option1
                                  msgbox @2 0x6
                                  release
                                  end

                                  #org @option1
                                  Msgbox @3 0x5
                                  If 0x0 goto @option2
                                  Givepokemon 0x115 0x5 0x0 0x0 0x0 0x0
                                  Fanfare 0x13E
                                  Msgbox @4 0x4
                                  Waitfanfare
                                  Closeonkeypress
                                  Setflag 0x8D3
                                  Msgbox @5 0x5
                                  Compare LASTRESULT 0x1
                                  If 0x1 gosub @name
                                  Msgbox @6 0x6
                                  Release
                                  End

                                  #org @option2
                                  Msgbox @7 0x5
                                  If 0x0 goto @option3
                                  Givepokemon 0x118 0x5 0x0 0x0 0x0 0x0
                                  Fanfare 0x13E
                                  Msgbox @4 0x4
                                  Waitfanfare
                                  Closeonkeypress
                                  Setflag 0x8D3
                                  Msgbox @5 0x5
                                  Compare LASTRESULT 0x1
                                  If 0x1 gosub @name
                                  Msgbox @6 0x6
                                  Release
                                  End

                                  #org @option3
                                  Msgbox @8 0x5
                                  If 0x0 goto @option1
                                  Givepokemon 0x11B 0x5 0x0 0x0 0x0 0x0
                                  Fanfare 0x13E
                                  Msgbox @4 0x4
                                  Waitfanfare
                                  Closeonkeypress
                                  Setflag 0x8D3
                                  Msgbox @5 0x5
                                  Compare LASTRESULT 0x1
                                  If 0x1 gosub @name
                                  Msgbox @6 0x6
                                  Release
                                  End

                                  #org @name
                                  Call 0x1A74EB
                                  Return

                                  #org @done
                                  Msgbox @15 0x6

                                  #org @1
                                  = Want a pokemon?

                                  #org @2
                                  = How are you?

                                  #org @3
                                  = Do you want CHULEE,\nThe kungfu bird?

                                  #org @4
                                  = Here you go.

                                  #org @5
                                  = Do you want to name it?

                                  #org @6
                                  = Congratulations!\n You’ve just got\lyour first pokemon!

                                  #org @7
                                  = Do you want DRATT?\nThe dark beast?

                                  #org @8
                                  = Do you want LEEBRIO?\nThe happy spirit?


                                  I debug and compile the script, and it all works fine, but when i talk to the person nothing happens, any ideas? (i think im missing something but i can't figure it out.)
                                  __________________
                                  All you do, no matter how amazing, will never amount to what you can do on any video rated 13+ or M, no matter what.
                                    #5068    
                                  Old January 9th, 2011 (11:49 PM).
                                  avolonsaber avolonsaber is offline
                                     
                                    Join Date: Oct 2010
                                    Posts: 182
                                    I decided to change something up in the hack I'm working on, but don't know how to go about it. I started with a script where you'd talk to a guy and he'd activate the Pokemon menu, the Running Shoes, give the player a Totodile, then "walk out" of the room. What I decided to do was change the script so that you have a choice between Squirtle, Totodile, or Mudkip, but everything else stays the same. So it would essentially be the same script as below, but he'd ask something like "Do you want Squirtle?" and you could either say "Yes" or "No, "So you want Totodile?" "Yes" or "No", "Well I heard you like Mudkip" "Yes" or "No". I've tried time & time again to get this, but I cannot. I don't know how to get it right, and I've tried playing around with other scripts of the same nature, but its not going good. Since I can't ask for a script, can someone give me some hints as to how to go about modifying the one below to get it to do what I want? The ROM is FireRed if it helps.
                                    Spoiler:
                                    #dynamic 0x3213C2

                                    #org @start
                                    lock
                                    faceplayer
                                    message @1 6
                                    setflag 0x828
                                    givepokemon 0x9E 0x5 0x0 0x0 0x0 0x0
                                    fanfare 0x13E
                                    message @2 6
                                    applymovement 0x2 @move
                                    waitmovement 0x0
                                    setflag 0x1200
                                    release
                                    end

                                    #org @1
                                    = Hey there, kiddo. Its about time\nyou're awake.\p\v\h01: Dad, what are you doing\nhere?\pI came by for a visit real\nquick, and also to give you\lsomething. I know I'm a little late\pbut here, take this.

                                    #org @2
                                    = I have to get back to work, but\nI'll be working in Sevi, so I\lexpect you to come find me.\p...\n...\l...\p\v\h01: See you around.

                                    #org @move
                                    #raw 0x10
                                    #raw 0x10
                                    #raw 0x13
                                    #raw 0x13
                                    #raw 0x13
                                    #raw 0x9
                                    #raw 0x1C
                                      #5069    
                                    Old January 10th, 2011 (4:44 AM).
                                    DrFuji's Avatar
                                    DrFuji DrFuji is offline
                                    Heiki Hecchara‌‌
                                     
                                    Join Date: Sep 2009
                                    Location: Aussie
                                    Age: 25
                                    Gender: Male
                                    Nature: Jolly
                                    Posts: 1,423
                                    Quote:
                                    Originally Posted by avolonsaber View Post
                                    I decided to change something up in the hack I'm working on, but don't know how to go about it. I started with a script where you'd talk to a guy and he'd activate the Pokemon menu, the Running Shoes, give the player a Totodile, then "walk out" of the room. What I decided to do was change the script so that you have a choice between Squirtle, Totodile, or Mudkip, but everything else stays the same. So it would essentially be the same script as below, but he'd ask something like "Do you want Squirtle?" and you could either say "Yes" or "No, "So you want Totodile?" "Yes" or "No", "Well I heard you like Mudkip" "Yes" or "No". I've tried time & time again to get this, but I cannot. I don't know how to get it right, and I've tried playing around with other scripts of the same nature, but its not going good. Since I can't ask for a script, can someone give me some hints as to how to go about modifying the one below to get it to do what I want? The ROM is FireRed if it helps.
                                    Spoiler:
                                    #dynamic 0x3213C2

                                    #org @start
                                    lock
                                    faceplayer
                                    message @1 0x6
                                    goto @Squirtle

                                    #org @Squirtle
                                    msgbox @SquirtMsg 0x5
                                    compare 0x800D 0x1
                                    if 0x0 goto @Totodile
                                    givepokemon 0x7 0x5 0x0 0x0 0x0 0x0
                                    goto @Continue

                                    #org @Totodile
                                    msgbox @TotoMsg 0x5
                                    compare 0x800D 0x1
                                    if 0x0 goto @Mudkip
                                    givepokemon 0x9E 0x5 0x0 0x0 0x0 0x0
                                    goto @Continue

                                    #org @Mudkip
                                    msgbox @MudMsg 0x5
                                    compare 0x800D 0x1
                                    if 0x0 goto @Squirtle
                                    givepokemon 0x102 0x5 0x0 0x0 0x0 0x0
                                    goto @Continue

                                    #org @Continue
                                    fanfare 0x13E
                                    message @2 0x6
                                    applymovement 0x2 @move
                                    waitmovement 0x0
                                    setflag 0x828
                                    setflag 0x82F
                                    release
                                    end

                                    #org @1
                                    = Hey there, kiddo. Its about time\nyou're awake.\p\v\h01: Dad, what are you doing\nhere?\pI came by for a visit real\nquick, and also to give you\lsomething. I know I'm a little late\pbut here, take this.

                                    #org @2
                                    = I have to get back to work, but\nI'll be working in Sevi, so I\lexpect you to come find me.\p...\n...\l...\p\v\h01: See you around.

                                    #org @move
                                    #raw 0x10
                                    #raw 0x10
                                    #raw 0x13
                                    #raw 0x13
                                    #raw 0x13
                                    #raw 0x9
                                    #raw 0x1C
                                    Changes in red.

                                    There you go. All you need to do is make three parts of the script that will repeat endlessly if the player doesn't accept the Pokemon being offered. Obviously the msgboxs in each part will be where you put the text like "doo u liek mudkipz??" and stuff.

                                    As a side note, you don't need to setflag 0x1200 in the script as you are already setting 0x828 and 0x82F to activate the Pokemon Menu and Running Shoes. If you have anyone with an ID of 1200 you can change it 828/ 82F and they will still disappear once the script has ended.

                                    I'd also suggest that you start using an offset from 0x800000 onwards as you might be overwriting some code that appears to be empty space but is actually needed in graphics or something. You could experience effects similar to the pixilating of your main menu like earlier.
                                    __________________
                                      #5070    
                                    Old January 10th, 2011 (11:40 AM). Edited January 10th, 2011 by avolonsaber.
                                    avolonsaber avolonsaber is offline
                                       
                                      Join Date: Oct 2010
                                      Posts: 182
                                      Quote:
                                      Originally Posted by DrFuji View Post
                                      I'd also suggest that you start using an offset from 0x800000 onwards as you might be overwriting some code that appears to be empty space but is actually needed in graphics or something. You could experience effects similar to the pixilating of your main menu like earlier.
                                      After I added in the messages it worked like a charm, thank you (: I'm using Free Space Finder to get my offsets, is there still a chance I could get one that appears to be empty if I use it?

                                      Edit: I added "showpokepic" for the Pokemon and made sure to put in their respective numbers/coordinates for the images to appear as well as "hidepokepic", and it works fine. I get the pixelation on the menu account again though. I tried using "0x800001" and a few other offsets, but it still gets pixelated?
                                        #5071    
                                      Old January 10th, 2011 (12:59 PM).
                                      lazinicki's Avatar
                                      lazinicki lazinicki is offline
                                      Spriter
                                         
                                        Join Date: May 2009
                                        Nature: Jolly
                                        Posts: 132
                                        can anyone help me with a national dex script for FR! i have been trying diffrent scripts, playing wiht oaks orginal script, looking at past msgs on this board... but all of them are confusing!
                                        __________________
                                        http://www.youtube.com/lazinicki
                                        300+ subs


                                        Im the maker but i still support it!

                                        Poison type mono run user!
                                          #5072    
                                        Old January 10th, 2011 (1:57 PM).
                                        DrFuji's Avatar
                                        DrFuji DrFuji is offline
                                        Heiki Hecchara‌‌
                                         
                                        Join Date: Sep 2009
                                        Location: Aussie
                                        Age: 25
                                        Gender: Male
                                        Nature: Jolly
                                        Posts: 1,423
                                        Quote:
                                        Originally Posted by avolonsaber View Post
                                        After I added in the messages it worked like a charm, thank you (: I'm using Free Space Finder to get my offsets, is there still a chance I could get one that appears to be empty if I use it?

                                        Edit: I added "showpokepic" for the Pokemon and made sure to put in their respective numbers/coordinates for the images to appear as well as "hidepokepic", and it works fine. I get the pixelation on the menu account again though. I tried using "0x800001" and a few other offsets, but it still gets pixelated?
                                        0x800000-0x8FFFFF is always going to be free space, so you won't have any problems there :)

                                        If you go back a page or two you can see how to resolve the menu issues in one of my earlier posts.

                                        Quote:
                                        Originally Posted by lazinicki View Post
                                        can anyone help me with a national dex script for FR! i have been trying diffrent scripts, playing wiht oaks orginal script, looking at past msgs on this board... but all of them are confusing!
                                        Inserting the National Dex is quiet easy as it only requires you to use the command 'special 0x16F' somewhere in your script, whereas the the ability to view the Dex in the main menu is unlocked in by the command 'setflag 0x828'.

                                        If you are planning to insert the special command into Oak's script (and because you will be extending old script) repoint it so that you don't overwrite anything else.
                                        __________________
                                          #5073    
                                        Old January 10th, 2011 (3:56 PM).
                                        avolonsaber avolonsaber is offline
                                           
                                          Join Date: Oct 2010
                                          Posts: 182
                                          Quote:
                                          Originally Posted by DrFuji View Post
                                          0x800000-0x8FFFFF is always going to be free space, so you won't have any problems there :)

                                          If you go back a page or two you can see how to resolve the menu issues in one of my earlier posts.
                                          Gah, I wish I had known that earlier. I would have just used offsets from there instead of using FSF. I found that post that you were talking about, but I didn't understand it, lol. I used an offset that contained image data, but appeared to be free space, that's all I got out of it :p
                                            #5074    
                                          Old January 11th, 2011 (8:03 AM).
                                          Metroid Die Metroid Die is offline
                                             
                                            Join Date: Mar 2009
                                            Posts: 54
                                            Hey can anyone tell me the command that is used when Oak checks your Pokedex in Fire Red?
                                              #5075    
                                            Old January 11th, 2011 (8:36 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
                                              Quote:
                                              Originally Posted by Metroid Die View Post
                                              Hey can anyone tell me the command that is used when Oak checks your Pokedex in Fire Red?
                                              Idk if I'm understanding you correctly but if you mean a check to see if you have the pokedex, then it's:
                                              Code:
                                              checkflag 0x828
                                              __________________
                                              http://www.pokecommunity.com/member.php?u=253113
                                              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 2:22 AM.