Adjustments for Galv's Item on event Script

Discussion in 'RGSSx Script Support' started by mylafter, Aug 9, 2019.

  1. mylafter

    mylafter Veteran Veteran

    Messages:
    172
    Likes Received:
    43
    First Language:
    English
    Primarily Uses:
    N/A
    I'm using Galv's script for using items on events. Can be found here. There are two things I need help with. Though i'm not sure if the second can be easily done.

    The text in my game isn't outlined, which I prefer but I specifically need the text where it says, 'A < Items > S' to be outlined. The text not being outlined makes it hard to read. Changing the color of that specific text doesn't help either. Check the spoiler to have a better visualization of what I need to be outlined.
    [​IMG]

    For this next one, I'm not sure if it could be easily achieved but I was wondering if an additional window could be added to show the description for the item be viewed.
    [​IMG]
     
    #1
  2. ZirconStorms

    ZirconStorms VX & VX Ace Scripts Veteran

    Messages:
    315
    Likes Received:
    103
    First Language:
    English
    Primarily Uses:
    RMVXA
    Change draw_heading in the script to this, should solve the 1st issue.

    Code:
      def draw_heading
        return if @heading != nil
        @heading = Sprite.new
        @heading.bitmap = Bitmap.new(Graphics.width, 25)
        @heading.bitmap.font.size = 25
        @heading.bitmap.font.color.set(text_color(0))
        @position = 0 if @position.nil?
        if Galv_Key::CATEGORIES.count > 1
          text = Galv_Key::CHANGE_CAT_LEFT + Galv_Key::CATEGORIES[@position][1] + Galv_Key::CHANGE_CAT_RIGHT
          contents.font.outline = true
        else
          text = Galv_Key::CATEGORIES[@position][1]
          contents.font.outline = true
        end
        
        @heading.bitmap.draw_text(@heading.bitmap.rect, text, 1)
        contents.font.outline = true
        reset_font_settings
        
        if @message_window.y >= Graphics.height / 2
          @heading.y = @message_window.height
        else
          @heading.y = Graphics.height - height + @message_window.height
        end
        
        @heading.z = z + 1
        @heading.opacity = 0
      end
    
     
    #2
  3. mylafter

    mylafter Veteran Veteran

    Messages:
    172
    Likes Received:
    43
    First Language:
    English
    Primarily Uses:
    N/A
    It didn't seem to work. I'm also using Yanfly's Core Engine Script. Which I think MAYBE is interefering with it.
    In Yanfly's script Line 201, I changed it to false, so that all the text being show won't be outlined.
     
    #3
  4. ZirconStorms

    ZirconStorms VX & VX Ace Scripts Veteran

    Messages:
    315
    Likes Received:
    103
    First Language:
    English
    Primarily Uses:
    RMVXA
    Try this, maybe. Specify what core scripts you're using for future threads, those can affect a ton of settings in a project.

    Code:
     
      def draw_heading
        return if @heading != nil
        @heading = Sprite.new
        @heading.bitmap = Bitmap.new(Graphics.width, 25)
        @heading.bitmap.font.size = 25
        @heading.bitmap.font.outline = true
        @heading.bitmap.font.color.set(text_color(0))
        @position = 0 if @position.nil?
        if Galv_Key::CATEGORIES.count > 1
          text = Galv_Key::CHANGE_CAT_LEFT + Galv_Key::CATEGORIES[@position][1] + Galv_Key::CHANGE_CAT_RIGHT
        else
          text = Galv_Key::CATEGORIES[@position][1]
        end
       
        @heading.bitmap.draw_text(@heading.bitmap.rect, text, 1)
        @heading.bitmap.font.outline = false
        reset_font_settings
       
        if @message_window.y >= Graphics.height / 2
          @heading.y = @message_window.height
        else
          @heading.y = Graphics.height - height + @message_window.height
        end
       
        @heading.z = z + 1
        @heading.opacity = 0
      end
    
    Let me know if it still doesn't work.
    EDIT: changed Font.default to @heading.bitmap.font .
     
    #4
  5. mylafter

    mylafter Veteran Veteran

    Messages:
    172
    Likes Received:
    43
    First Language:
    English
    Primarily Uses:
    N/A
    It worked. That fixes the first issue. Thanks! I didn't stop to think the core script would effect anything, but noted. Thanks again!
     
    #5
  6. ZirconStorms

    ZirconStorms VX & VX Ace Scripts Veteran

    Messages:
    315
    Likes Received:
    103
    First Language:
    English
    Primarily Uses:
    RMVXA
    Last edited: Aug 10, 2019
    #6
  7. mylafter

    mylafter Veteran Veteran

    Messages:
    172
    Likes Received:
    43
    First Language:
    English
    Primarily Uses:
    N/A
    I got it. It works perfectly. Better than I envisioned, actually. Thank you so much for the help!
     
    #7
    ZirconStorms likes this.

Share This Page