[RGSS3/Ace] - Galv Busts Are Semi-Transparent at Start of Event

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
The Script: (No, don't tell me to change bust script, it's too far into dev now)

#------------------------------------------------------------------------------##  Galv's Message Busts#------------------------------------------------------------------------------##  For: RPGMAKER VX ACE#  Version 1.1#------------------------------------------------------------------------------##  2013-01-13 - version 1.1 - added option to make busts slide onto the screen#  2012-12-01 - version 1.0 - release#------------------------------------------------------------------------------##  This script automatically displays a message bust instead of a face.#------------------------------------------------------------------------------##  INSTRUCTIONS:#  Put in script list below Materials and above Main.##  Put bust images in Graphics/Pictures/ and name them the same as the face#  graphic used in the message, plus the position of the face in it.#  For example:#  If the message shows "Actor1" face file and uses the first face in that file#  then you will name the bust image "Actor1-1.png"##  Download the demo if you don't understand##  NOTE: This script does NOT contain bust images. You will need your own.##------------------------------------------------------------------------------##  SCRIPT CALL#------------------------------------------------------------------------------##  #  bust_mirror(x)           # x can be true or false. All messages after this#                           # call will change until changed again.#                           # false = on left. true = on right and flipped.##------------------------------------------------------------------------------# ($imported ||= {})["Galvs_Message_Busts"] = truemodule Galv_Bust #------------------------------------------------------------------------------##  SCRIPT SETTINGS#------------------------------------------------------------------------------#   DISABLE_SWITCH = 1   # Turn swith ON to disable busts and show normal face     BUST_Z = 1            # adds to z value of busts if needed. A negative number                       # will make the bust appear below the message window.     BUST_Y_OVER = true  # can be true or false                       # true = busts sit at the bottom of the screen                       # false = busts sit on top of the message window   TEXT_X = 0           # Offset text when displaying busts above the message                       # window. The script automatically offsets the text x                        # by the bust image width IF the BUST_Z is 0 or more.   SLIDE = false         # Slide portrait onto the screen instead of fading in.   #------------------------------------------------------------------------------##  END SCRIPT SETTINGS#------------------------------------------------------------------------------# end  class Game_Interpreter     def bust_mirror(state)    $game_message.mirror = state  end   alias galv_busts_command_101 command_101  def command_101    $game_message.bust_name = @params[0]    $game_message.bust_index = @params[1]    galv_busts_command_101  endend # Game_Interpreter  class Game_Message  attr_accessor :bust_name  attr_accessor :bust_index  attr_accessor :mirror     alias galv_busts_message_initialize initialize  def initialize    galv_busts_message_initialize    @mirror = false  end   alias galv_busts_message_clear clear  def clear    @bust_name = ""    @bust_index = 0    galv_busts_message_clear  endend # Game_Message  class Window_Message < Window_Base     alias galv_busts_window_create_back_bitmap create_back_bitmap  def create_back_bitmap    @bust = Sprite.new if @bust.nil?    @bust.visible = true    @bust.opacity = 0    @bust.z = z + Galv_Bust::BUST_Z    galv_busts_window_create_back_bitmap  end     alias galv_busts_window_dispose dispose  def dispose    galv_busts_window_dispose    dispose_bust  end     def dispose_bust    @bust.dispose if !@bust.nil?    @bust.bitmap.dispose if !@bust.bitmap.nil?  end     alias galv_busts_window_update_back_sprite update_back_sprite  def update_back_sprite    galv_busts_window_update_back_sprite    update_bust if need_update?  end     def update_bust    puts "Updating busts #{Time.now}"    if !$game_message.bust_name.empty? && !$game_switches[Galv_Bust::DISABLE_SWITCH]      @bust.mirror = $game_message.mirror      @bust.bitmap = Cache.picture(get_bust_filename) # Changed to method for filename      if !$game_message.mirror        if Galv_Bust::SLIDE          @bust.x = ((openness.to_f / 255) * @bust.width) - @bust.width        else          @bust.x = 0        end      else        if Galv_Bust::SLIDE          @bust.x = Graphics.width - ((openness.to_f / 255) * @bust.width)        else          @bust.x = Graphics.width - @bust.bitmap.width        end      end             if $game_message.position == 2 && !Galv_Bust::BUST_Y_OVER        @bust.y = Graphics.height - @bust.bitmap.height - self.height      else        @bust.y = Graphics.height - @bust.bitmap.height      end    else      @bust.bitmap = nil    end    if $game_switches[Galv_Bust::DISABLE_SWITCH]      @bust.opacity = 0    else      @bust.opacity = openness           end    @bust.update        # New - update old bust name for control    @old_bust_name = get_bust_filename  end    # NEW - Gets filename for bust conveniently when we need it multiple times  def get_bust_filename    $game_message.bust_name + "-" + ($game_message.bust_index + 1).to_s  end    # NEW - Check if old bust?  def need_update?    return false unless $game_message.visible    @old_bust_name != get_bust_filename || openness < 255  end     def new_line_x    if $game_switches[Galv_Bust::DISABLE_SWITCH]      $game_message.face_name.empty? ? 0 : 112    else      if @bust.z >= self.z && !$game_message.mirror && $game_message.position == 2        $game_message.face_name.empty? ? 0 : @bust.bitmap.width + Galv_Bust::TEXT_X      else        return 0      end    end  end     def draw_face(face_name, face_index, x, y, enabled = true)    return if !$game_message.face_name.empty? && !$game_switches[Galv_Bust::DISABLE_SWITCH]    super  end end # Window_Message < Window_Base
The issue:



Paraphrased text from forum eating my earlier longer explanation:

Busts appear about 95-99% opaque, with a slight hint of transparency at the start of events. In battle, the busts always remain transparent, but on the map, busts tend to return to full opacity after the first line of dialogue.

The error occurs in all game resolutions.

Is there an error in the script above that could be causing this issue, or is there another script I should be looking for incompatibilities with?
 
Last edited by a moderator:

cabfe

Cool Cat
Veteran
Joined
Jun 13, 2013
Messages
2,353
Reaction score
2,549
First Language
French
Primarily Uses
RMVXA
I see this:

    if $game_switches[Galv_Bust::DISABLE_SWITCH]      @bust.opacity = 0    else      @bust.opacity = openness Is there a possibility that your switch #1 is activated somewhere and thus leads to an erroneous openness value?

Try with a different,unused value in the script to check if it's related.
 

EatYourBeetS

The Abysswalker
Veteran
Joined
Feb 23, 2015
Messages
96
Reaction score
30
First Language
Italian
Primarily Uses
BUST_Z = 1 , have you already tried increasing this?
 

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
There is literally nowhere for the switch to even be turned on, as I am starting the battle right from the beginning of testing in a "new game".








@EatyourBeetS: yes, I put it to 10, no change.


EDIT: Multiple edits, lol.


@Cafbe: What value do you want to me to change in testing?
 
Last edited by a moderator:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,365
Reaction score
7,675
First Language
German
Primarily Uses
RMMV
There is literally nowhere for the switch to even be turned on, as I am starting the battle right from the beginning of testing in a "new game".
wrong, it could have been turned on by another script or a parallel process event.
This is especially true since a lot of scripts are configured to use the first switches/variables by default.


Check every script wether or not it has been configured and its switches and variables reserved - if not, do it now.


If the problem still happens after that, check the switch in your event - if it's ON at the beginning, then you have something in your project that turns the switch ON and you'll have to find that "something".
 

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
wrong, it could have been turned on by another script or a parallel process event.


This is especially true since a lot of scripts are configured to use the first switches/variables by default.


Check every script wether or not it has been configured and its switches and variables reserved - if not, do it now.


If the problem still happens after that, check the switch in your event - if it's ON at the beginning, then you have something in your project that turns the switch ON and you'll have to find that "something".
I changed it to switch 200, the issue is exactly the same. There is nothing turning it ON.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,365
Reaction score
7,675
First Language
German
Primarily Uses
RMMV
Does the same problem appear if you use a regular text command outside battleprocessing, or does the problem only happens on the battlescreen?


Edit - OK, you answered the question in the first post.


Looks like there is something in the way galv handles the data, because the battle is a screen, not the map, and that makes things different internally for the engine.
 
Last edited by a moderator:

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
Yeah, I just did some more testing - if there are a lot of events (such as adding players, etc) then it tends to show 100% opaque. However, if there is a movement or speech at the start of the event, it shows like so:


 

cabfe

Cool Cat
Veteran
Joined
Jun 13, 2013
Messages
2,353
Reaction score
2,549
First Language
French
Primarily Uses
RMVXA
For the sake of testing, have you tried with the Slide effect = true (it looks like you don't use it)?

Since it deals with opacity, maybe...
 

EternalShadow

Veteran
Veteran
Joined
Sep 16, 2012
Messages
5,781
Reaction score
1,041
First Language
English
Primarily Uses
For the sake of testing, have you tried with the Slide effect = true (it looks like you don't use it)?


Since it deals with opacity, maybe...
Just tried it. It slides in, but the opacity issue still remains. It looks exactly the same as above.
 

FeaR616

Veteran
Veteran
Joined
Nov 22, 2014
Messages
277
Reaction score
52
First Language
german
Primarily Uses
in script change all '255' values to '256'.

I tested it and my busts are at 100% opacity now.
 

FeaR616

Veteran
Veteran
Joined
Nov 22, 2014
Messages
277
Reaction score
52
First Language
german
Primarily Uses
glad I could help =)
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD

Forum statistics

Threads
105,868
Messages
1,017,072
Members
137,578
Latest member
JamesLightning
Top