The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Create & Discover > Game Development > Scripts & Tutorials
Reload this Page Script [RMXP] Egg Incubator Script
Sign Up Rules/FAQ Daily Battle Blogs Mark Forums Read


Scripts & Tutorials This forum is for scripts and code, as well as all kinds of tutorials, software, tools and so forth. Remember to give credit!
The thread revival limit does not apply here.

Reply
 
Thread Tools
  #1    
Old April 11th, 2013 (12:29 PM).
Derxwna Kapsyla's Avatar
Derxwna Kapsyla Derxwna Kapsyla is offline
[Primal Despair] Derxwna "The Badman" Kapsyla
 
Join Date: Jun 2011
Location: Margate, FL
Age: 23
Gender: Male
Nature: Lax
Posts: 364
Thanks to my good friend Mugendai, he came up with a script that works a bit better than the default debug options for egg hatching. This makes all eggs hatch instantly, instead of forcing you to walk an additional step after selecting the Force Hatch option in the debug menu.
In the Pokemon Day Care script, go to line 425, or right before the line that says
"Events.onStepTaken+=proc {|sender,e|" and paste this code in.
Code:
def pbHatchAll
  for egg in $Trainer.party
    if egg.egg?
      egg.eggsteps=0
      pbHatch(egg)
    end
  end
end
This will run the Egg Hatching routine instantly for all eggs in your party. To bind this to some sort of NPC in the Overworld, create a new event, and in the events options, go to the "Script" Event Command, and put this in:
Code:
pbHatchAll
If you want to use it, I'd say give credit to my friend Mugendai, and I doubt he'd mind if this was used in any project or Essentials itself.
Additional proof that it works
__________________
Development Blog:
For more information future news and updates to any projects, the following blogs are where I post information. You can usually hit me with a message there when it comes to bug reports or feedback, or general conversation about something.
Game Projects:
In Progress:
Reply With Quote

Relevant Advertising!

  #2    
Old April 11th, 2013 (7:09 PM).
Rango's Avatar
Rango Rango is offline
Show Me The Money Wide Load!
 
Join Date: Apr 2013
Location: Australia
Age: 21
Gender: Male
Nature: Naive
Posts: 44
Thank you for this script, it should become very useful for my project.
One question though, is there anyway to have it only hatch a single egg as apposed to al of them at once?
__________________
Reply With Quote
  #3    
Old April 11th, 2013 (11:35 PM).
Nickalooose Nickalooose is offline
--------------------
 
Join Date: Mar 2008
Gender: Female
Posts: 1,285
@Rango: You have the script call a choose Pokemon command and then check of its an egg.

I know that question would come up as soon as I saw the 1st post
Reply With Quote
Reply
Quick Reply

Sponsored Links
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 2:22 AM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2016 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2016 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.

Acknowledgements
Use of PokéCommunity Assets
vB Optimise by DragonByte Technologies Ltd © 2016.