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

Lavender Town Ghosts For PE V17.2

  • 220
    Posts
    9
    Years
    Lavender Town Ghosts

    Lavender Town Ghosts For PE V17.2

    This is an old essentials recource that existed before the shut down of essentials wiki/forum.

    The purpose of this script is to recreate the Ghosts that are inside the Pokemon Tower in Lavender Town from Fire Red game. Before you have the Silph Scope, you can't see the true identity of the ghosts, but if you have it, it will unmask them.

    This is for Pokemon Essentials v17.2. This script was tested by me.

    So, let's do this!

    First the key item that you'll need:

    1- In the PBS folder, open "items" then add the key item:

    718,SILPHSCOPE,SILPH SCOPE,SILPH SCOPE,8,0,"A scope that makes unseeable POKéMON visible. It is made by Silph Co.",0,0,6,

    Note: Change the ID number for yours, plural name and description if you like.

    2- Put the required graphics for the key item in: Graphics/Icons folder:

    Lavender Town Ghosts For PE V17.2


    Note: Change the ID number of the item for yours. And that's it for the item. You can change the item for whatever item you want, but if you do that, you must rename it in the script too.


    Second the script:

    Add "LavenderGhostBattle" Script in a new section ABOVE MAIN:

    Spoiler:

    In the line:
    Code:
    GHOSTMAPS=[50,51,52,53,54]

    You must change the maps ID into yours. And where it says SILPHSCOPE, you can rename there the item for your liking.

    In "PokeBattle_Scene" where is :
    Code:
      def pbStartBattle(battle)
        # Called whenever the battle begins

    Replace this for the RED LINES:
    Code:
    @sprites["pokemon1"].setPokemonBitmap(@battle.party2[0],false)

    Spoiler:

    In "PokeBattle_AI" add the RED LINES:

    Spoiler:

    In "PokeBattle_Battle" right under:
    Code:
      def pbThrowPokeBall(idxPokemon,ball,rareness=nil,showplayer=false)

    Add the RED LINES:
    Spoiler:

    In the line:
    Code:
    if isGhostEncountersActive? || $game_switches[333]

    You must renumber the switch into yours.

    In the same script add the RED LINES:
    Spoiler:

    In the same script, in this Section "# Initialize wild Pokémon" add the RED LINES:
    Spoiler:

    Right after the line:
    Code:
    @peer.pbOnEnteringBattle(self,wildpoke)

    Replace the line:
    Code:
            pbSetSeen(wildpoke)

    To this:
    Code:
    [COLOR="Red"]        pbSetSeen(wildpoke) if !isGhostEncountersActive?[/COLOR]

    Right after the next line:
    Code:
            @scene.pbStartBattle(self)

    Replace the line:
    Code:
            pbDisplayPaused(_INTL("Wild {1} appeared!",wildpoke.name))

    To this:
    Spoiler:

    Replace the next like:
    Code:
                  if pbCanShowFightMenu?(i)

    For this line:
    Code:
    [COLOR="Red"]              elsif pbCanShowFightMenu?(i)[/COLOR]


    Third, the game events:

    A) Create a Parallel Process Event always ON.

    B) Add a Conditional Branch Event, in its 4th page, where is script section put this: $PokemonBag.pbQuantity(PBItems::SILPHSCOPE)>0
    And check the box below where it says: Set handling when conditions do not apply.

    C) Put this switch: LavenderGhostScript tuned OFF before the Conditional Branch else. And under that else, turn the switch ON.

    Note: This will detect if the player has the key item: Silph Scope. And rename the switch whatever name you like.

    Lavender Town Ghosts For PE V17.2



    Finaly, add the graphics in: Graphics/Battlers:
    Lavender Town Ghosts For PE V17.2


    Name it Ghost. If you want other name, just rename it and in the script too.


    Optional, if you are using Pokemon Birthsigns script add the RED LINES:
    Spoiler:


    All credits goes to zerokid, but the key item section credits goes to me, Richard PT.

    Known Issues:

    Your Pokemon can still attack the Ghost. For this part i need some help, because i don't know what codes will block your pokemon from using a move against the Ghost. Your pokemon is supposed to be too scared to attack.
     

    WolfPP

    Spriter/ Pixel Artist
  • 1,309
    Posts
    5
    Years
    Try looking for the part that call when your pokémon is disobedient, to make a code for your case.
     

    Diegou18

    Forever Chandelure lover.
  • 75
    Posts
    6
    Years
    • Seen Aug 16, 2021
    You can do that adding a new type in "types.txt" of PBS with immunities.
     
  • 220
    Posts
    9
    Years
    I think that i will try the WOLFPP suggestion first. I didn't have time to look into it. When i find a solution, i will post here.
     
  • 12
    Posts
    4
    Years
    • Seen Jun 26, 2022
    Maybe this is a stupid question but is there some kind of trigger for the ghost battle or does the ghost switch make it so that every encounter on the specified ghost map turns into a ghost? Do we even need to set any encounters on the map?
     
    Last edited:
  • 220
    Posts
    9
    Years
    Maybe this is a stupid question but is there some kind of trigger for the ghost battle or does the ghost switch make it so that every encounter on the specified ghost map turns into a ghost? Do we even need to set any encounters on the map?

    The way i did it, the maps have encounters, for ex in my game maps: gastly, haunter, cubone = this tree will turn into the ghost until you have the silph scope to unmask them. I've not tested for encounters through events, but it should work i guess, its only a "mask" for the wild pokemon. 1 switch is to forbit its capture and another one is to detect if you have the required item or not. The instructions already tells you everything. You can use it for others purposes too.
     
  • 220
    Posts
    9
    Years
    I never tested with EBS because i don't support it. I only do things for essentials (native) version. But, you can test it, it should work anyway because its a very simple script.
     
  • 1
    Posts
    3
    Years
    • Seen Dec 22, 2020
    im having an error line 2462 error in pokebattle_battle. can you help me fix this syntexerror please.
    ?
     
    Back
    Top