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

Script: Simple HUD

3
Posts
4
Years
  • Age 24
  • Seen Apr 22, 2021
That looks cool you made better use of this than I did. How did you display the money and how many Pokemon you caught?
 

WolfPP

Spriter/ Pixel Artist
1,309
Posts
5
Years
When i change the map, the HUD still keep into the screen (pbFadeOutIn doens't works for it). How can i change that? I mean, i would like to do something like:
When player changes the map; pbfadeoutin (HUD included) and then refresh to the new map.

Thanks in advanced!
 

FL

Pokémon Island Creator
2,448
Posts
13
Years
  • Seen today
That looks cool you made better use of this than I did. How did you display the money and how many Pokemon you caught?
Change the
Code:
      ret[0] = _INTL("text one")
      ret[1] = _INTL("text two")
into the values that you wish. I your case, $Trainer.money and $Trainer.pokedexOwned.

WolfPP said:
When i change the map, the HUD still keep into the screen (pbFadeOutIn doens't works for it). How can i change that? I mean, i would like to do something like:
When player changes the map; pbfadeoutin (HUD included) and then refresh to the new map.

Thanks in advanced!
pbFadeOutIn isn't called when you change map (at least in examples). If you mean adding the fade into HUD, change line '@hud = HUD.new(@viewport1) if !@hud' into '@hud = HUD.new(@@viewport1) if !@hud'.
 

Cardcaptor Sakura

Can you - Catch you Catch you Catch Me Catch Me –
3
Posts
6
Years
  • Age 24
  • Seen Sep 10, 2020
Can you help me with how to make it so when you press a button such as space, the HUD closes and tapping it again makes it reopen.
 

FL

Pokémon Island Creator
2,448
Posts
13
Years
  • Seen today
Cardcaptor Sakura said:
Can you help me with how to make it so when you press a button such as space, the HUD closes and tapping it again makes it reopen.
First you need to add the space button. After line 'module Input' add line 'SPACE = 40'. Before line 'when Input::SHIFT; return [0x10]' add line 'when Input::SPACE; return [0x20]'. Since Space also works as "confirm", you probably need to remove this feature. To do this, change line 'when Input::C; return [0x43,0x0D,0x20]' into 'when Input::C; return [0x43,0x0D]'.

So, for adding a function, on Scene_Map, before line 'if Input.trigger?(Input::F5)' add line '$game_switches[128] = !$game_switches[128] if Input.trigger?(Input::SPACE)'. And set the togglable switch on my script as 128 (is SWITCHNUMBER). 128 is an example, you can use any switch number that aren't used.
 
Last edited:

Minorthreat0987

Pokemon Tellurium
462
Posts
18
Years
  • Seen Jan 28, 2021
I was wondering if anyone has had success adding functionality to show when each Pokemon is inflicted with a status condition? I've tried mimicking the methods that are used to show the pokemon icons, however I can only seem to get it to show the status icon for the first pokemon in the party. Any tips? Thanks in advance!
 

FL

Pokémon Island Creator
2,448
Posts
13
Years
  • Seen today
I was wondering if anyone has had success adding functionality to show when each Pokemon is inflicted with a status condition? I've tried mimicking the methods that are used to show the pokemon icons, however I can only seem to get it to show the status icon for the first pokemon in the party. Any tips? Thanks in advance!
Below. I put above the pokémon, since there is no much space left.

Code:
class Spriteset_Map
  class HUD
    # If you wish to use a background picture, put the image path below, like
    # BGPATH="Graphics/Pictures/battleMessage". I recommend a 512x64 picture
    BGPATH=""

    # Make as 'false' to don't show the blue bar
    USEBAR=true

    # Make as 'true' to draw the HUD at bottom
    DRAWATBOTTOM=false

    # Make as 'true' to only show HUD in the pause menu
    DRAWONLYINMENU=false

    # Make as 'false' to don't show the hp bars
    SHOWHPBARS=true

    # When above 0, only displays HUD when this switch is on.
    SWITCHNUMBER = 0

    # Lower this number = more lag.
    FRAMESPERUPDATE=2

    # The size of drawable content.
    BARHEIGHT = 64

    def initialize(viewport1)
      @viewport1 = viewport1
      @sprites = {}
      @yposition = DRAWATBOTTOM ? Graphics.height-64 : 0
      @statuses = AnimatedBitmap.new(_INTL("Graphics/Pictures/statuses")) #statuses
    end

    def showHUD?
      return (
        $Trainer &&
        (SWITCHNUMBER<=0 || $game_switches[SWITCHNUMBER]) &&
        (!DRAWONLYINMENU || $game_temp.in_menu)
      )
    end

    def create
      @sprites.clear

      @partySpecies = Array.new(6, 0)
      @partyForm = Array.new(6, 0)
      @partyIsEgg = Array.new(6, false)
      @partyHP = Array.new(6, 0)
      @partyTotalHP = Array.new(6, 0)
      @partyStatuses = Array.new(6, 0)# statuses

      if USEBAR
        @sprites["bar"]=IconSprite.new(0,@yposition,@viewport1)
        barBitmap = Bitmap.new(Graphics.width,BARHEIGHT)
        barRect = Rect.new(0,0,barBitmap.width,barBitmap.height)
        barBitmap.fill_rect(barRect,Color.new(128,128,192))
        @sprites["bar"].bitmap = barBitmap
      end

      drawBarFromPath = BGPATH != ""
      if drawBarFromPath
        @sprites["bgbar"]=IconSprite.new(0,@yposition,@viewport1)
        @sprites["bgbar"].setBitmap(BGPATH)
      end

      @currentTexts = textsDefined
      drawText

      for i in 0...6
        x = 16+64*i
        y = @yposition-8
        y-=8 if SHOWHPBARS
        @sprites["pokeicon#{i}"]=IconSprite.new(x,y,@viewport1)
      end
      refreshPartyIcons

      if SHOWHPBARS
        borderWidth = 36
        borderHeight = 10
        fillWidth = 32
        fillHeight = 6
        for i in 0...6
          x=64*i+48
          y=@yposition+55

          @sprites["hpbarborder#{i}"] = BitmapSprite.new(
            borderWidth,borderHeight,@viewport1
          )
          @sprites["hpbarborder#{i}"].x = x-borderWidth/2
          @sprites["hpbarborder#{i}"].y = y-borderHeight/2
          @sprites["hpbarborder#{i}"].bitmap.fill_rect(
            Rect.new(0,0,borderWidth,borderHeight),
            Color.new(32,32,32)
          )
          @sprites["hpbarborder#{i}"].bitmap.fill_rect(
            (borderWidth-fillWidth)/2,
            (borderHeight-fillHeight)/2,
            fillWidth,
            fillHeight,
            Color.new(96,96,96)
          )
          @sprites["hpbarborder#{i}"].visible = false

          @sprites["hpbarfill#{i}"] = BitmapSprite.new(
            fillWidth,fillHeight,@viewport1
          )
          @sprites["hpbarfill#{i}"].x = x-fillWidth/2
          @sprites["hpbarfill#{i}"].y = y-fillHeight/2
          #statuses
          @sprites["statuses#{i}"] = BitmapSprite.new(44,16,@viewport1)
          @sprites["statuses#{i}"].x = 22+64*i
          @sprites["statuses#{i}"].y = @yposition+16
        end
        refreshHPBars
      end

      for sprite in @sprites.values
        sprite.z+=600
      end
    end

    def drawText
      baseColor=Color.new(72,72,72)
      shadowColor=Color.new(160,160,160)

      if @sprites.include?("overlay")
        @sprites["overlay"].bitmap.clear
      else
        width = Graphics.width
        @sprites["overlay"] = BitmapSprite.new(width,BARHEIGHT,@viewport1)
        @sprites["overlay"].y = @yposition
      end

      xposition = Graphics.width-64
      textPositions=[
        [@currentTexts[0],xposition,0,2,baseColor,shadowColor],
        [@currentTexts[1],xposition,32,2,baseColor,shadowColor]
      ]

      pbSetSystemFont(@sprites["overlay"].bitmap)
      pbDrawTextPositions(@sprites["overlay"].bitmap,textPositions)
    end

    # Note that this method is called on each refresh, but the texts
    # only will be redrawed if any character change.
    def textsDefined
      ret=[]
      ret[0] = _INTL("text one")
      ret[1] = _INTL("text two")
      return ret
    end

    def refreshPartyIcons
      for i in 0...6
        partyMemberExists = $Trainer.party.size > i
        partySpecie = 0
        partyForm = 0
        partyIsEgg = false
        if partyMemberExists
          partySpecie = $Trainer.party[i].species
          partyForm = $Trainer.party[i].form
          partyIsEgg = $Trainer.party[i].egg?
        end
        refresh = (
          @partySpecies[i]!=partySpecie || 
          @partyForm[i]!=partyForm ||
          @partyIsEgg[i]!=partyIsEgg
        )
        if refresh
          @partySpecies[i] = partySpecie
          @partyForm[i] = partyForm
          @partyIsEgg[i] = partyIsEgg
          if partyMemberExists
            pokemonIconFile = pbPokemonIconFile($Trainer.party[i])
            @sprites["pokeicon#{i}"].setBitmap(pokemonIconFile)
            @sprites["pokeicon#{i}"].src_rect=Rect.new(0,0,64,64)
          end
          @sprites["pokeicon#{i}"].visible = partyMemberExists
        end
      end
    end

    def refreshHPBars
      for i in 0...6
        hp = 0
        totalhp = 0
        hasHP = i<$Trainer.party.size && !$Trainer.party[i].egg?
        if hasHP
          hp = $Trainer.party[i].hp
          totalhp = $Trainer.party[i].totalhp
        end

        lastTimeWasHP = @partyTotalHP[i] != 0
        @sprites["hpbarborder#{i}"].visible = hasHP if lastTimeWasHP != hasHP

        redrawFill = hp != @partyHP[i] || totalhp != @partyTotalHP[i]
        if redrawFill
          @partyHP[i] = hp
          @partyTotalHP[i] = totalhp
          @sprites["hpbarfill#{i}"].bitmap.clear

          width = @sprites["hpbarfill#{i}"].bitmap.width
          height = @sprites["hpbarfill#{i}"].bitmap.height
          fillAmount = (hp==0 || totalhp==0) ? 0 : hp*width/totalhp
          # Always show a bit of HP when alive
          fillAmount = 1 if fillAmount==0 && hp>0
          if fillAmount > 0
            hpColors=nil
            if hp<=(totalhp/4).floor
              hpColors = [Color.new(240,80,32),Color.new(168,48,56)] # Red
            elsif hp<=(totalhp/2).floor
              hpColors = [Color.new(248,184,0),Color.new(184,112,0)] # Orange
            else
              hpColors = [Color.new(24,192,32),Color.new(0,144,0)] # Green
            end
            shadowHeight = 2
            rect = Rect.new(0,0,fillAmount,shadowHeight)
            @sprites["hpbarfill#{i}"].bitmap.fill_rect(rect, hpColors[1])
            rect = Rect.new(0,shadowHeight,fillAmount,height-shadowHeight)
            @sprites["hpbarfill#{i}"].bitmap.fill_rect(rect, hpColors[0])
          end
        end
        
        #statuses
        status = i<$Trainer.party.size ? $Trainer.party[i].status : 0
        redrawStatuses = status != @partyStatuses[i]
        if redrawStatuses
          @partyStatuses[i] = status
          @sprites["statuses#{i}"].bitmap.clear
          if @partyStatuses[i] >= 0
            rect = Rect.new(
              0,
              16*(@partyStatuses[i]-1),
              @sprites["statuses#{i}"].bitmap.width,
              @sprites["statuses#{i}"].bitmap.height
            )
            @sprites["statuses#{i}"].bitmap.blt(0,0,@statuses.bitmap,rect)
          end
        end
      end
    end

    def update
      if showHUD?
        if @sprites.empty?
          create
        else
          updateHUDContent = (
            FRAMESPERUPDATE<=1 || Graphics.frame_count%FRAMESPERUPDATE==0
          )
          if updateHUDContent
            newTexts = textsDefined
            if @currentTexts != newTexts
              @currentTexts = newTexts
              drawText
            end
            refreshPartyIcons
            refreshHPBars if SHOWHPBARS
          end
        end
        pbUpdateSpriteHash(@sprites)
      else
        dispose if [email protected]?
      end
    end

    def dispose
      pbDisposeSpriteHash(@sprites)
      @statuses.dispose #statuses
    end
  end

  alias :initializeOldFL :initialize
  alias :disposeOldFL :dispose
  alias :updateOldFL :update

  def initialize(map=nil)
    initializeOldFL(map)
  end

  def dispose
    @hud.dispose if @hud
    disposeOldFL
  end

  def update
    updateOldFL
    @hud = HUD.new(@viewport1) if !@hud
    @hud.update
  end
end
 

WolfPP

Spriter/ Pixel Artist
1,309
Posts
5
Years
Below. I put above the pokémon, since there is no much space left.
Spoiler:

FL, like we have into Following Pokémon Script, about status into overworld:
Spoiler:


Is possible to put to color the icon sprite too using 'tone' code instead showing status condicion icon?

Thank you!
 
Last edited:

Natzen

Creator of Pokémon: Sanguine
49
Posts
8
Years
5M1qcW6.png



Thanks a bunch @FL, I managed to sort mine out somewhat after a bit of tinkering.

kCHiwCf.gif

I added a GPS, if anyone is interested:

first add to currentTexts
Code:
[@currentTexts[2],xpos,ypos,2,baseColor,shadowColor]

and then

in def textsDefined add:
Code:
ret[2] = $game_map.name
 
Last edited:

FL

Pokémon Island Creator
2,448
Posts
13
Years
  • Seen today
FL, like we have into Following Pokémon Script, about status into overworld:
Spoiler:


Is possible to put to color the icon sprite too using 'tone' code instead showing status condicion icon?

Thank you!
Take note than there is no tone for sleep. Anyway, here the script:
Code:
class Spriteset_Map
  class HUD
    # If you wish to use a background picture, put the image path below, like
    # BGPATH="Graphics/Pictures/battleMessage". I recommend a 512x64 picture
    BGPATH=""

    # Make as 'false' to don't show the blue bar
    USEBAR=true

    # Make as 'true' to draw the HUD at bottom
    DRAWATBOTTOM=false

    # Make as 'true' to only show HUD in the pause menu
    DRAWONLYINMENU=false

    # Make as 'false' to don't show the hp bars
    SHOWHPBARS=true

    # When above 0, only displays HUD when this switch is on.
    SWITCHNUMBER = 0

    # Lower this number = more lag.
    FRAMESPERUPDATE=2

    # The size of drawable content.
    BARHEIGHT = 64

    def initialize(viewport1)
      @viewport1 = viewport1
      @sprites = {}
      @yposition = DRAWATBOTTOM ? Graphics.height-64 : 0
      @statuses = AnimatedBitmap.new(_INTL("Graphics/Pictures/statuses")) #statuses
      @toneArrayPerStatus = [ #statuses
        Tone.new(0,0,0,0),        # Normal
        Tone.new(0,0,0,0),        # Sleep
        Tone.new(153,102,204,50), # Poison
        Tone.new(204,51,51,50),   # Burn
        Tone.new(255,255,153,50), # Paralysis
        Tone.new(153,204,204,50)  # Freeze        
      ]
    end

    def showHUD?
      return (
        $Trainer &&
        (SWITCHNUMBER<=0 || $game_switches[SWITCHNUMBER]) &&
        (!DRAWONLYINMENU || $game_temp.in_menu)
      )
    end

    def create
      @sprites.clear

      @partySpecies = Array.new(6, 0)
      @partyForm = Array.new(6, 0)
      @partyIsEgg = Array.new(6, false)
      @partyHP = Array.new(6, 0)
      @partyTotalHP = Array.new(6, 0)
      @partyStatuses = Array.new(6, 0)# statuses

      if USEBAR
        @sprites["bar"]=IconSprite.new(0,@yposition,@viewport1)
        barBitmap = Bitmap.new(Graphics.width,BARHEIGHT)
        barRect = Rect.new(0,0,barBitmap.width,barBitmap.height)
        barBitmap.fill_rect(barRect,Color.new(128,128,192))
        @sprites["bar"].bitmap = barBitmap
      end

      drawBarFromPath = BGPATH != ""
      if drawBarFromPath
        @sprites["bgbar"]=IconSprite.new(0,@yposition,@viewport1)
        @sprites["bgbar"].setBitmap(BGPATH)
      end

      @currentTexts = textsDefined
      drawText

      for i in 0...6
        x = 16+64*i
        y = @yposition-8
        y-=8 if SHOWHPBARS
        @sprites["pokeicon#{i}"]=IconSprite.new(x,y,@viewport1)
      end
      refreshPartyIcons

      if SHOWHPBARS
        borderWidth = 36
        borderHeight = 10
        fillWidth = 32
        fillHeight = 6
        for i in 0...6
          x=64*i+48
          y=@yposition+55

          @sprites["hpbarborder#{i}"] = BitmapSprite.new(
            borderWidth,borderHeight,@viewport1
          )
          @sprites["hpbarborder#{i}"].x = x-borderWidth/2
          @sprites["hpbarborder#{i}"].y = y-borderHeight/2
          @sprites["hpbarborder#{i}"].bitmap.fill_rect(
            Rect.new(0,0,borderWidth,borderHeight),
            Color.new(32,32,32)
          )
          @sprites["hpbarborder#{i}"].bitmap.fill_rect(
            (borderWidth-fillWidth)/2,
            (borderHeight-fillHeight)/2,
            fillWidth,
            fillHeight,
            Color.new(96,96,96)
          )
          @sprites["hpbarborder#{i}"].visible = false

          @sprites["hpbarfill#{i}"] = BitmapSprite.new(
            fillWidth,fillHeight,@viewport1
          )
          @sprites["hpbarfill#{i}"].x = x-fillWidth/2
          @sprites["hpbarfill#{i}"].y = y-fillHeight/2
          #statuses
          #@sprites["statuses#{i}"] = BitmapSprite.new(44,16,@viewport1)
          #@sprites["statuses#{i}"].x = 22+64*i
          #@sprites["statuses#{i}"].y = @yposition+16
        end
        refreshHPBars
      end

      for sprite in @sprites.values
        sprite.z+=600
      end
    end

    def drawText
      baseColor=Color.new(72,72,72)
      shadowColor=Color.new(160,160,160)

      if @sprites.include?("overlay")
        @sprites["overlay"].bitmap.clear
      else
        width = Graphics.width
        @sprites["overlay"] = BitmapSprite.new(width,BARHEIGHT,@viewport1)
        @sprites["overlay"].y = @yposition
      end

      xposition = Graphics.width-64
      textPositions=[
        [@currentTexts[0],xposition,0,2,baseColor,shadowColor],
        [@currentTexts[1],xposition,32,2,baseColor,shadowColor]
      ]

      pbSetSystemFont(@sprites["overlay"].bitmap)
      pbDrawTextPositions(@sprites["overlay"].bitmap,textPositions)
    end

    # Note that this method is called on each refresh, but the texts
    # only will be redrawed if any character change.
    def textsDefined
      ret=[]
      ret[0] = _INTL("text one")
      ret[1] = _INTL("text two")
      return ret
    end

    def refreshPartyIcons
      for i in 0...6
        partyMemberExists = $Trainer.party.size > i
        partySpecie = 0
        partyForm = 0
        partyIsEgg = false
        if partyMemberExists
          partySpecie = $Trainer.party[i].species
          partyForm = $Trainer.party[i].form
          partyIsEgg = $Trainer.party[i].egg?
        end
        refresh = (
          @partySpecies[i]!=partySpecie || 
          @partyForm[i]!=partyForm ||
          @partyIsEgg[i]!=partyIsEgg
        )
        if refresh
          @partySpecies[i] = partySpecie
          @partyForm[i] = partyForm
          @partyIsEgg[i] = partyIsEgg
          if partyMemberExists
            pokemonIconFile = pbPokemonIconFile($Trainer.party[i])
            @sprites["pokeicon#{i}"].setBitmap(pokemonIconFile)
            @sprites["pokeicon#{i}"].src_rect=Rect.new(0,0,64,64)
          end
          @sprites["pokeicon#{i}"].visible = partyMemberExists
        end
      end
    end

    def refreshHPBars
      for i in 0...6
        hp = 0
        totalhp = 0
        hasHP = i<$Trainer.party.size && !$Trainer.party[i].egg?
        if hasHP
          hp = $Trainer.party[i].hp
          totalhp = $Trainer.party[i].totalhp
        end

        lastTimeWasHP = @partyTotalHP[i] != 0
        @sprites["hpbarborder#{i}"].visible = hasHP if lastTimeWasHP != hasHP

        redrawFill = hp != @partyHP[i] || totalhp != @partyTotalHP[i]
        if redrawFill
          @partyHP[i] = hp
          @partyTotalHP[i] = totalhp
          @sprites["hpbarfill#{i}"].bitmap.clear

          width = @sprites["hpbarfill#{i}"].bitmap.width
          height = @sprites["hpbarfill#{i}"].bitmap.height
          fillAmount = (hp==0 || totalhp==0) ? 0 : hp*width/totalhp
          # Always show a bit of HP when alive
          fillAmount = 1 if fillAmount==0 && hp>0
          if fillAmount > 0
            hpColors=nil
            if hp<=(totalhp/4).floor
              hpColors = [Color.new(240,80,32),Color.new(168,48,56)] # Red
            elsif hp<=(totalhp/2).floor
              hpColors = [Color.new(248,184,0),Color.new(184,112,0)] # Orange
            else
              hpColors = [Color.new(24,192,32),Color.new(0,144,0)] # Green
            end
            shadowHeight = 2
            rect = Rect.new(0,0,fillAmount,shadowHeight)
            @sprites["hpbarfill#{i}"].bitmap.fill_rect(rect, hpColors[1])
            rect = Rect.new(0,shadowHeight,fillAmount,height-shadowHeight)
            @sprites["hpbarfill#{i}"].bitmap.fill_rect(rect, hpColors[0])
          end
        end
        
        #statuses
        status = i<$Trainer.party.size ? $Trainer.party[i].status : 0
        redrawStatuses = status != @partyStatuses[i]
        if redrawStatuses
          @partyStatuses[i] = status
          #@sprites["statuses#{i}"].bitmap.clear
          #if @partyStatuses[i] >= 0
          #  rect = Rect.new(
          #    0,
          #    16*(@partyStatuses[i]-1),
          #    @sprites["statuses#{i}"].bitmap.width,
          #    @sprites["statuses#{i}"].bitmap.height
          #  )
          #  @sprites["statuses#{i}"].bitmap.blt(0,0,@statuses.bitmap,rect)
          #end
          @sprites["pokeicon#{i}"].tone = @toneArrayPerStatus[@partyStatuses[i]] #statuses
        end
      end
    end

    def update
      if showHUD?
        if @sprites.empty?
          create
        else
          updateHUDContent = (
            FRAMESPERUPDATE<=1 || Graphics.frame_count%FRAMESPERUPDATE==0
          )
          if updateHUDContent
            newTexts = textsDefined
            if @currentTexts != newTexts
              @currentTexts = newTexts
              drawText
            end
            refreshPartyIcons
            refreshHPBars if SHOWHPBARS
          end
        end
        pbUpdateSpriteHash(@sprites)
      else
        dispose if [email protected]?
      end
    end
    
    def dispose
      pbDisposeSpriteHash(@sprites)
      @statuses.dispose #statuses
    end
  end

  alias :initializeOldFL :initialize
  alias :disposeOldFL :dispose
  alias :updateOldFL :update

  def initialize(map=nil)
    initializeOldFL(map)
  end

  def dispose
    @hud.dispose if @hud
    disposeOldFL
  end

  def update
    updateOldFL
    @hud = HUD.new(@viewport1) if !@hud
    @hud.update
  end
end

Thanks a bunch @FL, I managed to sort mine out somewhat after a bit of tinkering.

I added a GPS, if anyone is interested:

first add to currentTexts
Code:
[@currentTexts[2],xpos,ypos,2,baseColor,shadowColor]

and then

in def textsDefined add:
Code:
ret[2] = $game_map.name
These screenshots are very cool! Any your change for route name is neat! Thanks for sharing!
 
4
Posts
4
Years
  • Age 23
  • Seen Jun 3, 2023
I dont have any idea of scripting :/, how did you put the "$" money symbol and he "caught"?
 

FL

Pokémon Island Creator
2,448
Posts
13
Years
  • Seen today
I dont have any idea of scripting :/, how did you put the "$" money symbol and he "caught"?
Not sure if I understand. You wish to print the player money and catch count? If so, change.

Code:
    def textsDefined
      ret=[]
      ret[0] = _INTL("text one")
      ret[1] = _INTL("text two")
      return ret
    end

Code:
    def textsDefined
      ret=[]
      ret[0] = _INTL("$ "+$Trainer.money.to_s)
      ret[1] = _INTL("Caught: "+$Trainer.pokedexOwned(0).to_s)
      return ret
    end

The "$" symbol is automatic converted into Pokédollar symbol by the font.
 
4
Posts
4
Years
  • Age 23
  • Seen Jun 3, 2023
Not sure if I understand. You wish to print the player money and catch count? If so, change.

Code:
    def textsDefined
      ret=[]
      ret[0] = _INTL("text one")
      ret[1] = _INTL("text two")
      return ret
    end

Code:
    def textsDefined
      ret=[]
      ret[0] = _INTL("$ "+$Trainer.money.to_s)
      ret[1] = _INTL("Caught: "+$Trainer.pokedexOwned(0).to_s)
      return ret
    end

The "$" symbol is automatic converted into Pokédollar symbol by the font.

Ok thanks!
 

FL

Pokémon Island Creator
2,448
Posts
13
Years
  • Seen today
Well. Can you answer my question I asked about an year ago?
This was a affirmation, wasn't?

Anyway, I don't know how to make it compatible with Luka's Neo Pause Menu or Luka SJ's Modular Pause Menu, since I never used both.
 

_pheebee

[I]Gosh! What's poppin'?[/i]
528
Posts
5
Years
Spoiler:


Never mind, it works.
Dunno how i fixed it.

EowPND.jpg
 
Last edited:
Back
Top