• 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?".
  • 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.

[Script] Battle frontier scripting help

15
Posts
3
Years
    • Seen Nov 11, 2020
    I'm trying to enter this code for a battle facility but it says that its missing #define

    Code:
    setflag FLAG_BATTLE_FACILITY
    setvar VAR_BATTLE_FACILITY_POKE_NUM 4
    setvar VAR_BATTLE_FACILITY_POKE_LEVEL 50
    setvar VAR_BATTLE_FACILITY_BATTLE_TYPE 0

    I'm using CFRU
     
    48
    Posts
    7
    Years
  • Are you using XSE to write this? If yes, then you need to make some small changes because XSE doesn't know what "FLAG_BATTLE_FACILITY", "VAR_BATTLE_FACILITY_POKE_NUM", etc are. So, you have to make XSE identify these using '#define'.

    Try using one of these two solutions:
    Solution 1: Put these lines on the top of your script below #dynamic 0xOffset and before any main script begins.
    #define FLAG_BATTLE_FACILITY 0x930
    #define VAR_BATTLE_FACILITY_POKE_NUM 0x5015
    #define VAR_BATTLE_FACILITY_POKE_LEVEL 0x5016
    #define VAR_BATTLE_FACILITY_BATTLE_TYPE 0x5017
    Make sure to change the underlined parts to the variables that you used in CFRU's config.h for the Battle Tower Options.

    Solution 2: Replace the parts in your post with these lines:
    setflag 0x930
    setvar 0x5015 4
    setvar 0x5016 50
    setvar 0x5017 0
    Once again, make sure to change the underlined parts with the variables from config.h

    If you are using PKSV, the solution should be same. Although, I have never used it before.
     
    Back
    Top