Change Color of The diferent Status Script
#1
Change Color of The diferent Status Script
MASTERLOKI
Jul 18 2006

This is a locked, single-post thread from Creation Asylum. Archived here to prevent its loss.
No support is given. If you are the owner of the thread, please contact administration.


This script change the color of the diferent status in the game

Its 100 compatible whit alls scripts of the forum


INSTRUCCIONS

just copy in a new page above the main and change some lines.

SCRIPT

Code:
#Status Color Change By Momomo, Post By Masterloki
#Thanks to the Really Traductor of this code

class Window_BattleStatus < Window_Base
STATE_DRAW_FRAME = 20 # Indicatory frame interval
STATE_DRAW_X = 160  # Distance between actor #You PROBEBLY NEED to change this
STATE_DRAW_Y = 96 # The state the Y-coordinate which is indicated
STATE_DRAW_COLOR_USE = true # Whether or not letter color setting is made effective
#--------------------------------------------------------------------------
# â—? Letter color setting of state
# ¦nbsp; ¦nbsp; actor ¦nbsp; ¦nbsp; ¦nbsp; : Actor
# ¦nbsp; ¦nbsp; text ¦nbsp; ¦nbsp; ¦nbsp;  : Drawing character string
#--------------------------------------------------------------------------
def state_font_color(actor, text)
if STATE_DRAW_COLOR_USE
color = normal_color
case text
when "[Normal]" #translated Normality
color = normal_color
when "[Muerte]" #translated agressive failure
color = knockout_color
when "[Aturdido]"
color = normal_color
when "[Veneno]"
color = Color.new(128, 255, 128, 255)
when "[Cegado]" #translated Dazzaldinezz
color = Color.new(255, 255, 128, 255)
when "[Silencio]"
color = Color.new(160, 160, 160, 255)
when "[Confusión]"
color = Color.new(200, 255, 140, 255)
when "[Sueño]"
color = Color.new(64, 64, 200, 255)
when "[Paralizado]"
color = Color.new(128, 255, 255, 255)
when "[Debilidad]","[Silencio]","[Maldición]","[Freno]","[Congelación]","[Borracho]","[Shock]" #tranlated: ????, Cram Gee, Delay, Fee Bull
color = Color.new(128, 128, 128, 255)
  when "[Evasión]","[Barrera]","[Precisión]","[Escudo]","[Furia]","[Agilidad]","[Fulgor]","[Tecnico]","[Vigor]"
color = Color.new(128, 128, 255, 255)
  end
else
# When STATE_DRAW_COLOR_USE is false, processing of colors (only dead with red drawing)
color = actor.hp == 0 ? knockout_color : normal_color
end
  @state_sprite.bitmap.font.color = color
end
attr_accessor :state_count
alias window_battlestatus_state_draw_initialize initialize
def initialize
  window_battlestatus_state_draw_initialize
# Drawing up the counter for state indication
@state_count = 0
# Drawing up the sprite for state indication
  @state_sprite = Sprite.new(self.viewport)
@state_sprite.bitmap = Bitmap.new(self.width - 32, self.height - 32)
  @state_sprite.x = self.x + 16
@state_sprite.y = self.y + 16
@state_sprite.z = self.z + 2
  # Refreshing the sprite for state indication
state_draw_refresh
end
alias window_battlestatus_state_draw_dispose dispose
def dispose
window_battlestatus_state_draw_dispose
# Opening the sprite for state indication
@state_sprite.dispose
end
#--------------------------------------------------------------------------
# â—? State character string compilation for drawing
# ¦nbsp; ¦nbsp; actor ¦nbsp; ¦nbsp; ¦nbsp; : Actor
# ¦nbsp; ¦nbsp; width ¦nbsp; ¦nbsp; ¦nbsp; : Width ahead drawing
# ¦nbsp; ¦nbsp; need_normal : Whether or not [ normal ] is active (true / false)
#--------------------------------------------------------------------------
def make_battler_state_text(battler, width, need_normal)
# Acquiring the width of the parenthesis
brackets_width = self.contents.text_size("[]").width
# Drawing up the character string of state name
text = ""
# Actually arrangement compilation of the state which is indicated
show_state = []
for i in battler.states
if $data_states[i].rating >= 1
show_state.push($data_states[i].name)
end
  end
# When arrangement of the indicatory state is the sky, "[ it makes normal ]"
  if show_state.size == 0
if need_normal
text = "[Normal]"
else
text = ""
end
else
  # Setting the state which it corresponds to count to the character string
  text = show_state[(@state_count / STATE_DRAW_FRAME) % show_state.size]
# The parenthesis is attached
text = "[" + text + "]"
end
# The character string which you complete is returned
return text
end  

def state_draw_refresh
# The character string which you complete is returned
@state_count += 1
# Not to be state renewal interval, if the first renewal time is not, it does not renew
  return if @state_count % STATE_DRAW_FRAME != 0 and @state_count != 1
@state_sprite.bitmap.clear
for i in 0...$game_party.actors.size
actor = $game_party.actors[i]
  actor_x = i * STATE_DRAW_X + 4
if @level_up_flags[i]
@state_sprite.bitmap.font.color = normal_color
  @state_sprite.bitmap.draw_text(actor_x, STATE_DRAW_Y, 120, 32, "LEVEL UP!")
else
text = make_battler_state_text(actor, 120, true)
state_font_color(actor, text)
@state_sprite.bitmap.draw_text(actor_x, STATE_DRAW_Y, 120, 32, text)
  end
end
end

def draw_actor_state(actor, x, y, width = 120)
# The dummy because usual draw_actor_state is not made to execute
end
end

class Scene_Battle
alias scene_battle_state_draw_update update
def update
# Renewing state indication to every update
  @status_window.state_draw_refresh
scene_battle_state_draw_update
end
end



Well well, this is very important to this Script..
you make this changes to this script in your game....



Code:
def state_font_color(actor, text)
if STATE_DRAW_COLOR_USE
color = normal_color
case text
when "[Normal]" #translated Normality
color = normal_color
when "[Muerte]" #translated agressive failure
color = knockout_color
when "[Aturdido]"
color = normal_color
when "[Veneno]"
color = Color.new(128, 255, 128, 255)
when "[Cegado]" #translated Dazzaldinezz
color = Color.new(255, 255, 128, 255)
when "[Silencio]"
color = Color.new(160, 160, 160, 255)
when "[xxxxx]"
color = Color.new(200, 255, 140, 255)
when "[Sueño]"
color = Color.new(64, 64, 200, 255)
when "[Paralizado]"
color = Color.new(128, 255, 255, 255)
when "[Debilidad]","[Silencio]","[Maldición]","[Freno]","[Congelación]","[Borracho]","[Shock]" #tranlated: ????, Cram Gee, Delay, Fee Bull
color = Color.new(128, 128, 128, 255)
  when "[Evasión]","[Barrera]","[Precisión]","[Escudo]","[Furia]","[Agilidad]","[Fulgor]","[Tecnico]","[Vigor]"
color = Color.new(128, 128, 255, 255)
  end
else



in this part of this code, you may change the [xxxxx], by the name of the status in your game
you may change the color and create new color states.
}


Possibly Related Threads…
Thread Author Replies Views Last Post
  Change character script jaigai 0 3,187 11-19-2006, 01:00 PM
Last Post: jaigai
  Just a modification of Abyssos' facs script lumina... 0 2,958 11-01-2006, 01:00 PM
Last Post: lumina...
  Credit Script 1.1 acoole 0 2,838 10-24-2006, 01:00 PM
Last Post: acoole
  Script Dev Kit Nick 0 3,227 10-15-2006, 01:00 PM
Last Post: Nick
  Friend Death Status sandsand 0 3,348 10-10-2006, 01:00 PM
Last Post: sandsand
  Change menu character sprites to Pictures like in rpg maker 2003 Abyssos 0 4,052 09-28-2006, 01:00 PM
Last Post: Abyssos
  Opening Image script sasuke89 0 2,360 07-24-2006, 01:00 PM
Last Post: sasuke89
  Define a Gradiated Color Tsunokiette 0 2,259 07-05-2006, 01:00 PM
Last Post: Tsunokiette
  Change Cursor with differend commands in Battle Divinity 0 2,608 06-22-2006, 01:00 PM
Last Post: Divinity
  Event Name and ID Search Script Hadriel 0 2,417 06-21-2006, 01:00 PM
Last Post: Hadriel



Users browsing this thread: 1 Guest(s)