• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Staff applications for our PokéCommunity Daily and Social Media team are now open! Interested in joining staff? Then click here for more info!
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Other] Script For Battle with give pokemon at end

Shogun

I'll be back
  • 527
    Posts
    11
    Years
    Hello everybody
    For my fire red 493 hack(85%done but i create a thread only when he is finish) i want to insert some trainer battle with a pokemon in present at the end of the battle.
    BUT I want a trainer battle re-fightable all the time with a pokemon given only the first time

    '---------------
    #org 0xEFC600
    trainerbattle 0x0 0x2E8 0x0 0x8000008 0x8000008
    givepokemon 0x1F4 0x5 0x0 0x0 0x0 0x0
    fanfare 0x13E
    waitfanfare
    end


    '---------
    ' Strings
    '---------
    #org 0x8
    = ...



    I used this script but with this I can only fight 1 time and after that he give me the pokemon all the time (I try to put set flag and checkflag but i don't know where to put it)
    If someone can change my script please
    thanks
     
    First of all, you have trainerbattle 0x0 ______

    But I believe it needs to be trainerbattle 0x1 ______ if you want the script to continue after the battle.
    As for the single time pokemon, simply add after the battle script:

    checkflag 0x(your flag here)
    if 0x0 jump @pokemongift
    (here add script for what they do if they don't give you the pokemon)

    #org @pokemongift
    (here add the script for if they do give you the pokemon, somewhere in it adding the setflag command)
     
    Thank a lot man ! BUT...

    "As for the single time pokemon, simply add after the battle script:

    checkflag 0x(your flag here)
    if 0x0 jump @pokemongift
    (here add script for what they do if they don't give you the pokemon)

    #org @pokemongift
    (here add the script for if they do give you the pokemon, somewhere in it adding the setflag command)"


    Is the first time I try an dynamic offset so can you say me if I need to put this between trainer battle and give pokemon or in another place in the script.
     
    Your script don't work. It only fight one time and give the pokemon one time
    BUT I have create a solution for a rematch with your idea of a "gym leader battle"-like
    and he work very fine
    #dynamic 0xOFFSET DE 6 CHIFFRES
    #org @start
    lock
    faceplayer
    checkflag 0xCHOISIRFLAGSANSL4INSCRIREDANSL4ID
    if 0x1 goto @done
    msgbox @2 0x6
    trainerbattle 0x1 0xVALEUR DU DRESSUER 0x0 @before @after @later
    end
    #org @before
    = Show me what ya got!
    #org @after
    = What the-?
    #org @later
    msgbox @3 0x6
    fanfare 0x13E
    msgbox @4 0x4
    waitfanfare
    closeonkeypress
    msgbox @5 0x6
    givepokemon 0xPOKEMON 0xLEVEL 0x0 0x0 0x0 0x0
    setflag 0xFLAGDUDEBUT
    release
    end
    #org @done
    msgbox @0 0x5
    if 0x1 goto @yes
    msgbox @6 0x6
    release
    end
    #org @yes
    msgbox @8 0x6
    trainerbattle 0x4 0xDRESSEURDUDEBUT 0x0 @before2 @after2 @later2
    end
    #org @0
    = Shall we have a rematch?
    #org @1
    = You should travel to Moserde town\nto get your next badge.
    #org @2
    = Welcome to Fander Town Gym.\nYou want to challenge me?
    #org @3
    = Congratulations!\pFor beating me, you get\nthis badge!
    #org @4
    = \v\h01 recieved a badge!
    #org @5
    = Oh, and please take this.
    #org @6
    = O.k maybe next time?
    #org @before2
    = Ha Ha....
    #org @after2
    = Oh Man!!!
    #org @later2
    = O.k you are still in good shape!!
    #org @8
    = Bring it on!!

    this is a script for a gym leader rematchable but he give a pokemon at end if someone need it
    if someone don't understand this modded script just PM me^^.



    Thanks for Aerow base script
     
    Back
    Top