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

Help Thread: Script Help Thread

Status
Not open for further replies.
  • 14
    Posts
    9
    Years
    • Seen Jun 13, 2016
    I'm not really sure about the copy var because I don't use it but assuming that part is correct and you are using XSE try this:

    Spoiler:


    This better?

    Edit: I've left out the dynamic for clarity but you should keep that in btw.

    thanks for this ^_^
     

    C me

    Creator of Pokemon League Of Legends
  • 681
    Posts
    10
    Years
    • Seen Apr 9, 2021
    Why is my level script not starting when I enter the map? It's the first map you enter so the var isn't set and the script used to work fine but now it doesn't, any ideas?

    Spoiler:
     

    Joexv

    ManMadeOfGouda joexv.github.io
  • 1,037
    Posts
    11
    Years
    Why is my level script not starting when I enter the map? It's the first map you enter so the var isn't set and the script used to work fine but now it doesn't, any ideas?

    Spoiler:
    Could you post the actual script too?
     

    C me

    Creator of Pokemon League Of Legends
  • 681
    Posts
    10
    Years
    • Seen Apr 9, 2021
    Could you post the actual script too?

    Spoiler:


    4052 and 0x1 in Amap
     

    Joexv

    ManMadeOfGouda joexv.github.io
  • 1,037
    Posts
    11
    Years
    Spoiler:


    4052 and 0x1 in Amap
    Ok well for starters you have the var using 0x1. And you said that it needs to run on he starting map. So if you want that to go without previously setting the var you will need to change that to 0x0.
     

    C me

    Creator of Pokemon League Of Legends
  • 681
    Posts
    10
    Years
    • Seen Apr 9, 2021
    Ok well for starters you have the var using 0x1. And you said that it needs to run on he starting map. So if you want that to go without previously setting the var you will need to change that to 0x0.

    I love you so much. Just a playthrough left for me and I release my hack's first Alpha.
     
  • 14
    Posts
    10
    Years
    • Seen Jan 20, 2020
    Hey everybody, I need some help again with my script. I want to recive a Delibird, when my Character talks to a Pokeball.
    Mana already tried to help me in the other thread (thank you Mana), but somehow I still get the massage, "Error 13, Type mismatch, in line 5, missing #define or parameter. Line: givepokemon 225 25 0000

    Spoiler:
     
  • 10,078
    Posts
    15
    Years
    • UK
    • Seen Oct 17, 2023
    Hey everybody, I need some help again with my script. I want to recive a Delibird, when my Character talks to a Pokeball.
    Mana already tried to help me in the other thread (thank you Mana), but somehow I still get the massage, "Error 13, Type mismatch, in line 5, missing #define or parameter. Line: givepokemon 225 25 0000

    Spoiler:

    Those zeros need separating! :)

    givepokemon 255 25 0 0 0 0

    The givepokemon command asks for six parameters, so that should do it. Normally I'd do it all in hex but it should work like that too.
     
  • 16
    Posts
    8
    Years
    • Seen Sep 27, 2015
    Hey everybody, I need some help again with my script. I want to recive a Delibird, when my Character talks to a Pokeball.
    Mana already tried to help me in the other thread (thank you Mana), but somehow I still get the massage, "Error 13, Type mismatch, in line 5, missing #define or parameter. Line: givepokemon 225 25 0000

    Spoiler:


    There should only be 1 zero there, not 4.... plus you need to specify the hidesprite with 0x(sprite# in hex).
     
  • 14
    Posts
    10
    Years
    • Seen Jan 20, 2020
    Thanks both of you very much. :)
    @Mana
    I'm so sorry, I didn't realised in the other thread that the zeroes were seperated.
    Now it works perfectly. :)

    @Anexenaumoon
    I tried it with one zero before, but then I got the error message.
    The same with the hidesprite. In my case it only works when I directly write the personnumber of the sprite. :)
     
  • 16
    Posts
    8
    Years
    • Seen Sep 27, 2015
    Thanks both of you very much. :)
    @Mana
    I'm so sorry, I didn't realised in the other thread that the zeroes were seperated.
    Now it works perfectly. :)

    @Anexenaumoon
    I tried it with one zero before, but then I got the error message.
    The same with the hidesprite. In my case it only works when I directly write the personnumber of the sprite. :)
    Yea, person # & the parameters for the last three are:
    DWORD (0x0)
    BYTE(0x0)
    BYTE(0x0)
    Plus 255 is not even a valid pokemon # so i will use #54 (0x36 in hex)
    so in otherwords it would look like so:
    givepokemon 0x36 0x19 0x0 0x0 0x0 0x0

    you must separate those zeros with the hexadecimal format! without it, the ROM will not read those byte values. Plus, you forgot to convert your level # to hex (25 in dec. is 0x19 in hex) you must convert the pokemon id # to hex as well. the three last 0x0's i wouldn't mess with as those are just fillers. The first 0x0 is your item #. So remember to convert that to hex too! PM me if you have any questions!
    ~Anex
     
  • 10,078
    Posts
    15
    Years
    • UK
    • Seen Oct 17, 2023
    Yea, person # & the parameters for the last three are:
    DWORD (0x0)
    BYTE(0x0)
    BYTE(0x0)
    Plus 255 is not even a valid pokemon # so i will use #54 (0x36 in hex)
    so in otherwords it would look like so:
    givepokemon 0x36 0x19 0x0 0x0 0x0 0x0

    you must separate those zeros with the hexadecimal format! without it, the ROM will not read those byte values. Plus, you forgot to convert your level # to hex (25 in dec. is 0x19 in hex) you must convert the pokemon id # to hex as well. the three last 0x0's i wouldn't mess with as those are just fillers. The first 0x0 is your item #. So remember to convert that to hex too! PM me if you have any questions!
    ~Anex

    He was using decimal, which XSE also understands. He's all good.
     

    KID VEGITO

    Charmareian
  • 3
    Posts
    9
    Years
    • Seen Oct 15, 2015
    Hi I need help with Pokemon Essentials scripting. How do you script a wild pokemon event to be in a different form. Ex) A wild battle event with Black Kyurem or shaymin in its second form in a wild battle.
     

    destinedjagold

    You can contact me in PC's discord server...
  • 8,593
    Posts
    16
    Years
    • Seen Dec 23, 2023
    Hi I need help with Pokemon Essentials scripting. How do you script a wild pokemon event to be in a different form. Ex) A wild battle event with Black Kyurem or shaymin in its second form in a wild battle.

    Pokémon Essentials is for Game Making, and not for ROM Hacking. This is the wrong subsection for you to ask. I suggest you ask in the Game Development section.
     
  • 5
    Posts
    8
    Years
    • Seen Aug 12, 2017
    Ok so I'm having an issue with a script not executing when i step on it. Also im pretty new to scripting big things like this so i probably missed a few things. and im using XSE on a Ruby ROM.
    Spoiler:
     
  • 10,078
    Posts
    15
    Years
    • UK
    • Seen Oct 17, 2023
    Ok so I'm having an issue with a script not executing when i step on it. Also im pretty new to scripting big things like this so i probably missed a few things. and im using XSE on a Ruby ROM.
    Spoiler:

    Does your script-tile have '7000' as the var number in A-Map? Other than your flag and variable numbers being pretty high, the rest looks find. Have a look here for suggested flag/var numbers as well as more information on Script Tiles.
     

    C me

    Creator of Pokemon League Of Legends
  • 681
    Posts
    10
    Years
    • Seen Apr 9, 2021
    Surprise, Surprise! I'm back with another level script problem!

    Can you have more than one level script using the 02 script type? I need two level scripts on one map but using 04 causes a black screen (the music still plays). Using 2 02's causes the first one to work fine but the second one doesn't start (although experience tells me it's probably my script). So I'll post it here:

    Spoiler:


    407B 0000 on Amap
    Any ideas?
     
  • 10,078
    Posts
    15
    Years
    • UK
    • Seen Oct 17, 2023
    Surprise, Surprise! I'm back with another level script problem!

    Can you have more than one level script using the 02 script type? I need two level scripts on one map but using 04 causes a black screen (the music still plays). Using 2 02's causes the first one to work fine but the second one doesn't start (although experience tells me it's probably my script). So I'll post it here:

    Spoiler:


    407B 0000 on Amap
    Any ideas?

    I haven't done double level scripts in a long time. I can't remember if I used to do it the normal way or cheat it somehow.

    Anyway, I'd recommend changing your variable and giving that a go first. At the moment, assuming this is your second script, it'll activate on the first time along with your other script.

    Make them both use the same variable then:

    Script one: Activate when 0xVAR = 0 (script sets to 1)
    <intermediate script/event somewhere that sets 0xVAR to 2>
    Script two: Activate when 0xVAR = 2 (script sets to 3)

    Let me know if it works. o_o I'm skeptical on if I'm remembering this right.

    ALTERNATIVELY.

    Add a checkflag to the start of your first level script, where 0x1 sends you to the second script. Then reset the variable back to zero + set the flag in a later script, which will activate this 'new' level script. This means you only have one level script that is used in two different ways :).
     

    C me

    Creator of Pokemon League Of Legends
  • 681
    Posts
    10
    Years
    • Seen Apr 9, 2021
    ALTERNATIVELY.

    Add a checkflag to the start of your first level script, where 0x1 sends you to the second script. Then reset the variable back to zero + set the flag in a later script, which will activate this 'new' level script. This means you only have one level script that is used in two different ways :).

    Sounds like this might work. How do I reset the var?
     
    Status
    Not open for further replies.
    Back
    Top