Game Development Your number one stop for anything related to creating games (except ROM hacks). You can even make your own!

Ad Content
Reply
 
Thread Tools
  #1   Link to this post, but load the entire thread.  
Old May 29th, 2018 (11:56 AM).
Takako Rune's Avatar
Takako Rune Takako Rune is offline
Hack Player
     
    Join Date: Aug 2016
    Gender: Female
    Nature: Timid
    Posts: 36
    Hi there.
    Whenever I receive an egg from the daycare I get the error below.
    The daycare script is untouched. Perhaps the problem is in the Pokemon PBS?
    I tried several Pokémon, with and without ditto. Always the same.
    Any ideas? Googling didn't turn up anything useful.

    I'm using Essentials 16.2


    The error log:
    -------------------------
    Code:
    Exception: RuntimeError
    Message: Script error within event 1, map 118 (ROUTE 510):
    Exception: SystemStackError
    Message: Section126:202:in `pbGetBabySpecies'stack level too deep
    ***Full script:
    pbDayCareGenerateEgg
    $PokemonGlobal.daycareEgg=0
    $PokemonGlobal.daycareEggSteps=0
     
    Interpreter:243:in `pbExecuteScript'
    Pokemon_Evolution:197:in `loop'
    Pokemon_Evolution:215:in `pbGetBabySpecies'
    Pokemon_Evolution:191:in `pbRgssOpen'
    SpriteWindow:1776:in `open'
    SpriteWindow:1776:in `pbRgssOpen'
    Pokemon_Evolution:191:in `pbGetBabySpecies'
    Pokemon_Evolution:219:in `pbGetBabySpecies'
    Pokemon_Evolution:219:in `pbGetBabySpecies'
    Pokemon_Evolution:219:in `pbGetBabySpecies'
     
    Interpreter:276:in `pbExecuteScript'
    Interpreter:1606:in `command_355'
    Interpreter:494:in `execute_command'
    Interpreter:193:in `update'
    Interpreter:106:in `loop'
    Interpreter:198:in `update'
    Scene_Map:103:in `update'
    Scene_Map:101:in `loop'
    Scene_Map:114:in `update'
    Scene_Map:68:in `main'
    Reply With Quote
      #2   Link to this post, but load the entire thread.  
    Old May 30th, 2018 (1:39 PM).
    Takako Rune's Avatar
    Takako Rune Takako Rune is offline
    Hack Player
       
      Join Date: Aug 2016
      Gender: Female
      Nature: Timid
      Posts: 36
      I found the problem.

      How Essentials generates eggs is by checking what the earliest pre-evolution of the parent pokemon is.

      Well, in my game I gave them the ability to "de-evolve" by using an item, which is technically still an evolution.

      What this means is that the program will loop around the same evolution line eternally, never finding the earliest evolution.

      So either I'll have to find a different method of de-evolving or sacrifice either this function or the day-care altogether. :/
      Reply With Quote
        #3   Link to this post, but load the entire thread.  
      Old May 30th, 2018 (2:30 PM). Edited May 30th, 2018 by GT-Baka.
      GT-Baka GT-Baka is offline
         
        Join Date: Jul 2008
        Posts: 75
        Quote:
        Originally Posted by Takako Rune View Post
        I found the problem.

        How Essentials generates eggs is by checking what the earliest pre-evolution of the parent pokemon is.

        Well, in my game I gave them the ability to "de-evolve" by using an item, which is technically still an evolution.

        What this means is that the program will loop around the same evolution line eternally, never finding the earliest evolution.

        So either I'll have to find a different method of de-evolving or sacrifice either this function or the day-care altogether. :/
        How does your "de-evolve" work?

        I managed to get this working, and I had no issues breeding.
        paste in PItem_ItemEffects
        Code:
        ItemHandlers::UseOnPokemon.add(:DEVOLUTIONSTONE,proc{|item,pokemon,scene|
           if isConst?(pokemon.species,PBSpecies,:NINETALES)
             pokemon.species=PBSpecies::VULPIX
             pokemon.calcStats
             scene.pbDisplay(_INTL("NINETALES devolved into VULPIX."))
             scene.pbHardRefresh
           else
             scene.pbDisplay(_INTL("It won't have any effect."))
           end
         })
        Change a Ninetales back into a Vulpix.
        Reply With Quote
          #4   Link to this post, but load the entire thread.  
        Old May 30th, 2018 (5:36 PM).
        Takako Rune's Avatar
        Takako Rune Takako Rune is offline
        Hack Player
           
          Join Date: Aug 2016
          Gender: Female
          Nature: Timid
          Posts: 36
          Quote:
          Originally Posted by GT-Baka View Post
          How does your "de-evolve" work?

          I managed to get this working, and I had no issues breeding.
          paste in PItem_ItemEffects
          Code:
          ItemHandlers::UseOnPokemon.add(:DEVOLUTIONSTONE,proc{|item,pokemon,scene|
             if isConst?(pokemon.species,PBSpecies,:NINETALES)
               pokemon.species=PBSpecies::VULPIX
               pokemon.calcStats
               scene.pbDisplay(_INTL("NINETALES devolved into VULPIX."))
               scene.pbHardRefresh
             else
               scene.pbDisplay(_INTL("It won't have any effect."))
             end
           })
          Change a Ninetales back into a Vulpix.
          Thank you! This line of code works exactly how I wanted it to. I've been trying to figure this out for hours now. ^^ Now I just need to do this for every mon in the game. :p

          How my de-evolution worked is that in the pokemon.txt each evolved pokemon could evolve into the previous evolution via an item. It worked really nicely until I discovered the overflow bug with the breading.

          Thanks again. :) I should be able to get it to work now with a couple of hours work.

          ~TJ
          Reply With Quote
          Reply

          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
          Ad Content
          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 3:35 PM.