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

[Essentials Tutorial] Hidden Grottos

69
Posts
14
Years
    • Seen Nov 19, 2014
    Pokémon Essentials tutorial: Hidden Grottos:
    I could Finally make a hidden grotto that work,and as an almost totally new
    bie in essentials and in RPG Maker XP this is a big achievement for me xD. I imagine that what i made can be done in a much more simpler way, so if you know a better way to do this just post it here :)

    To apply this feature in your game you must copy this script:
    Code:
    #Hidden Grotto script made by VEGET@, aka Amatsukase
    class PokemonGlobalMetadata
      attr_accessor :grottosteps
      attr_accessor :whichoption
    
      def grottosteps
        @grottosteps=0 if !@grottosteps
        return @grottosteps
      end
      
      @regenerate = 0
    end
    
    Events.onStepTaken+=proc{
    		 $PokemonGlobal.grottosteps += 1
      }
    #This calculates how many steps the player has walked
    
     def pbAssignnum
       @whichoption = rand(9)
    #This will determine what will appear in the grotto, if an item, a special item, a pokémon or nothing.
       @grottopkmn = rand(2)
    #This will determine which pokémon will appear in the grotto
       @grottohidden = rand(11)
    #This will determine which special item will appear in the grotto
       @grottoitem = rand(7)
    #This will determine which item will appear in the grotto
     end

    Later you will need to create the event that will allow you to enter to the grotto and will need to have this
    Spoiler:


    The conditional "$PokemonGlobal.grottosteps>=256" checks if the player has walked more than 256 steps every time the player enters to the grotto, if not the content of the grotto will not change, but if the walked more than 256 every grotto will regenerate it content (this make that if you enter in the grotto and take the item or battle with a pokémon, nothing will appear till the player walks the necessary steps)

    Code:
    @regenerate=2
    $PokemonGlobal.grottosteps=0
    pbAssignnum

    In this event you will transport the player to the grotto map in the exact point where the event A is and make the player move automatically move 1 tile up (move the player to the event B)


    After this you will need to create 5 event in each grotto, 1 for the exit, 1 that control what will appear in the center of the grotto, 1 that has all the item possibilities, 1 that has all the special item possibilities and 1 that has all the pokémon possibilities:
    Spoiler:


    EVENT A: This is the event that will let you out of the grotto, so you already know how configure it (or just copy a door event xD )

    EVENT B: This will have 3 pages, the first one will have the autorun option as start trigger, in the first page will only have "control self switch: B =ON"
    Spoiler:

    The second page will look like this and will have the collition option as start trigger and the condition of self switch A being ON:
    Spoiler:

    The third page will look like this and will have too the collition option as start trigger and the condition of self switch B being ON:
    Spoiler:

    This page will determine what will appear in this specific grotto according to the "whichoption" value, so you can change this event in a diferent grotto so it will have his own chances of getting an item, a special item, a pokémon or nothing. In this example you can see that if "whichoption" is equal to 0, 1 or 2 an item will appear in the center of the grotto, if "whichoption" is equal to 3 or 7 nothing will appear, if "whichoption" is equal to 4, 5 or 6 a special item will appear and if "whichoption" is equal to 8 or 9 a pokemon will appear. "whichoption" is defined in the script to select a number between 0 to 9 (10 results) so the chances to get an item are %30, to get a special item are %30, to get a pokémon are %20 and %20 to get nothing. You easily can change this and make diferent possibilities for each grotto.
    -Remember that every time a pokemon appear in the center of the grotto, this event determine the sprite of the pokemon, so you need to change the sprite to the pokemon you will want to appear in the grotto ("grottopkmn" give you 3 option, so you need a conditional branch of each option).

    EVENT C: This event determine which pokemon you can battle, remember to match the pokemon that you will fight with the overworld sprite you assigned in EVENT B. You can manipulate every option and edit the pokemon as you want, the grotto feature in BW all pokémon that appear in a grotto has a hidden ability, if you want this go to the script "PokemonEncounterModifiers" and add this:
    Code:
    Events.onWildPokemonCreate+=proc {|sender,e|
       pokemon=e[0]
       if $game_switches[SECONDABILY_PKMN_SWITCH]
         pokemon.setAbility(1)
       end
    }
    And after that go to the script "Settings" and add:
    Code:
    SECONDABILY_PKMN_SWITCH   = 59

    Here is how the first page of EVENT C will look, if you dont want to edit the pokemon ability don´t change the switch 59.
    Spoiler:


    The second page of EVENT C will look like this:
    Spoiler:


    EVENT D: This event will have 2 pages, the first one must have the graphic of a pokeball and a diferent conditional branch for each value that "grottoitem" can take, this event has all the item that you can find, you can esaily change which item you want to give and it possibilities.
    Spoiler:


    The second page will have the same thing that the second page of EVENT C has.
    Spoiler:


    EVENT E: This event is just a copy of EVENT D but with some changes, in this event every conditional branch checks the "grottohidden" value and give you better items.
    Spoiler:

    Well that´s all, i hope you liked it ^^. Obvious this is based on the tutorial of Rayd12smitty, so if you use this please give credit to him and me, is not much effort xD.

    English is not my native language, so i´m sorry if i say something wrong or i repeat to many times the sames words.
     
    Back
    Top