• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Dawn, Gloria, Juliana, or Summer - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • 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.

[Scripting Question] trainer scripts reseting

  • 11
    Posts
    6
    Years
    • Seen May 19, 2019
    Hi all,
    Im having a strange issue where on a certain route, the scripts for the 2 trainers on said route are being changed back to the script i copied them from whenever I save and try to run the game. whenever i run the game however, i get a separate error for a different route, that says "private method "gsub" called for in nil:nilclass"

    before playtest
    script:pbtrainerintro(:HIKER)
    script:kernel.pbNoticePlayer(get_character(0))
    text: Isn't nature beautiful?
    conditional branch: Script: pbTrainerBattle(:HIKER,"Jeff",_I("Pokemon are part of nature too i suppose..."),false,0,false,0)
    control self switch a=on
    branch end
    script: pbTrainerEnd
    the other is the exact same aside from dialogue changes

    both after saving

    script:pbtrainerintro(:YOUNGSTER)
    script:kernel.pbNoticePlayer(get_character(0))
    text: Isn't nature beautiful?
    conditional branch: Script: pbTrainerBattle(:YOUNGSTER,"Joey",_I("Eat my shorts!"),false,0,false,0)
    control self switch a=on
    branch end
    script: pbTrainerEnd
     
    Are there comments in the event? When essentials compiles, it looks for events named Trainer and if they have certain criteria in the comments, it builds a new trainer based off those comments, overwriting any edits to any of the event commands.
     
    Back
    Top