Ayene

Liczba postów: 758
Dołączył: 09-04-13
Pomógł: 112

|
RE: Czcionka z RM2k
Użyłam nieco innej skórki, by zróżnicować rogi. Oto wynik moich zmagań:
![[Obrazek: custom_window_screen.jpg]](http://www.ultimateam.pl/files/custom_window_screen.jpg)
Zmodyfikowałam kształt windowskina, by można było czytać z niego kolor czcionki i gradientu. Do tego zmniejszyłam tło, aby ładnie wyglądały rogi. Oczywiście można wrócić do starej wersji. No i kolorów można dodać więcej (wystarczy jeden piksel koloru i jeden piksel gradientu), więc można by umieścić ich ponad 2000... tylko po co :P
Tak wygląda okienko:
A to dość długi kod:
#==============================================================================
# CUSTOM WINDOWSKIN by Ayene
# Zapętlanie tła w oknie
# Gradient czcionki
# Czcionka RM2k
# Kolor czytany z windowskina
#
# Wykorzystano skrypt "Window - Hidden RGSS Class" by Selwyn
#==============================================================================
module CustomWindow
STRETCH = false # Rozciąganie tła okna
GRADIENT = true # Gradient czcionki
BITMAP_FONT = false # Czcionka RM2k
SHADOW = true # Cień
end
#==============================================================================
# Color
#==============================================================================
class Color
#--------------------------------------------------------------------------
# * Gradient
#--------------------------------------------------------------------------
def gradient
@gradient = self if @gradient.nil?
return @gradient
end
#--------------------------------------------------------------------------
# * Gradient=
#--------------------------------------------------------------------------
def gradient=(gradient)
@gradient = gradient
end
end
#==============================================================================
# Window
#==============================================================================
class Window
#--------------------------------------------------------------------------
# * Public Instance Variables
#--------------------------------------------------------------------------
attr_reader :x
attr_reader :y
attr_reader :z
attr_reader :width
attr_reader :height
attr_reader :ox
attr_reader :oy
attr_reader :opacity
attr_reader :back_opacity
attr_reader :stretch
attr_reader :contents_opacity
attr_reader :visible
attr_reader :pause
attr_accessor :active
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize()
@skin = Skin.new
@viewport = Viewport.new(0, 0, 0, 0)
@cursor_viewport = Viewport.new(0, 0, 0, 0)
@width = 0
@height = 0
@ox = 0
@oy = 0
@opacity = 255
@back_opacity = 255
@contents_opacity = 255
@frame = Sprite.new()
@bg = Sprite.new()
@window = Sprite.new(@viewport)
@pause_s = Sprite.new()
@arrows = []
for i in 0...4
@arrows.push(Sprite.new(@cursor_viewport))
@arrows[i].bitmap = Bitmap.new(16, 16)
@arrows[i].visible = false
end
@cursor_rect = Cursor_Rect.new(@cursor_viewport)
@cursor_fade = true
@pause_s.visible = false
@pause = false
@active = true
@stretch = CustomWindow::STRETCH
@visible = true
self.x = 0
self.y = 0
self.z = 100
self.windowskin = RPG::Cache.windowskin($game_system.windowskin_name)
end
#--------------------------------------------------------------------------
# * Contents
#--------------------------------------------------------------------------
def contents=(bmp)
@window.bitmap = bmp
if bmp != nil
if bmp.width > @viewport.rect.width
bmp.height > @viewport.rect.height
draw_arrows
end
end
end
#--------------------------------------------------------------------------
# * Contents
#--------------------------------------------------------------------------
def contents
return @window.bitmap
end
#--------------------------------------------------------------------------
# * Dispose
#--------------------------------------------------------------------------
def dispose
@bg.dispose
@frame.dispose
@window.dispose
@cursor_rect.dispose
@viewport.dispose
@pause_s.dispose
@cursor_viewport.dispose
for arrow in @arrows
arrow.dispose
end
end
#--------------------------------------------------------------------------
# * Update
#--------------------------------------------------------------------------
def update
@window.update
@cursor_rect.update
@viewport.update
@cursor_viewport.update
@pause_s.src_rect = @skin["pause#{(Graphics.frame_count / 8) % 4}"]
@pause_s.update
update_visible
update_arrows
if @cursor_fade
@cursor_rect.opacity -= 10
@cursor_fade = false if @cursor_rect.opacity <= 100
else
@cursor_rect.opacity += 10
@cursor_fade = true if @cursor_rect.opacity >= 255
end
end
#--------------------------------------------------------------------------
# * Update Visible
#--------------------------------------------------------------------------
def update_visible
@frame.visible = @visible
@bg.visible = @visible
@window.visible = @visible
@cursor_rect.visible = @visible
if @pause
@pause_s.visible = @visible
else
@pause_s.visible = false
end
end
#--------------------------------------------------------------------------
# * Pause
#--------------------------------------------------------------------------
def pause=(pause)
@pause = pause
update_visible
end
#--------------------------------------------------------------------------
# * Update Arrows
#--------------------------------------------------------------------------
def update_arrows
if @window.bitmap == nil or @visible == false
for arrow in @arrows
arrow.visible = false
end
else
@arrows[0].visible = @oy > 0
@arrows[1].visible = @ox > 0
@arrows[2].visible = (@window.bitmap.width - @ox) > @viewport.rect.width
@arrows[3].visible = (@window.bitmap.height - @oy) > @viewport.rect.height
end
end
#--------------------------------------------------------------------------
# * Visible
#--------------------------------------------------------------------------
def visible=(visible)
@visible = visible
update_visible
update_arrows
end
#--------------------------------------------------------------------------
# * X-coordinate
#--------------------------------------------------------------------------
def x=(x)
@x = x
@bg.x = x + 2
@frame.x = x
@viewport.rect.x = x + 16
@cursor_viewport.rect.x = x
@pause_s.x = x + (@width / 2) - 8
set_arrows
end
#--------------------------------------------------------------------------
# * Y-coordinate
#--------------------------------------------------------------------------
def y=(y)
@y = y
@bg.y = y + 2
@frame.y = y
@viewport.rect.y = y + 16
@cursor_viewport.rect.y = y
@pause_s.y = y + @height - 16
set_arrows
end
#--------------------------------------------------------------------------
# * Z-coordinate
#--------------------------------------------------------------------------
def z=(z)
@z = z
@bg.z = z
@frame.z = z + 1
@cursor_viewport.z = z + 2
@viewport.z = z + 3
@pause_s.z = z + 4
end
#--------------------------------------------------------------------------
# * OX
#--------------------------------------------------------------------------
def ox=(ox)
return if @ox == ox
@ox = ox
@viewport.ox = ox
update_arrows
end
#--------------------------------------------------------------------------
# * OY
#--------------------------------------------------------------------------
def oy=(oy)
return if @oy == oy
@oy = oy
@viewport.oy = oy
update_arrows
end
#--------------------------------------------------------------------------
# * Width
#--------------------------------------------------------------------------
def width=(width)
@width = width
@viewport.rect.width = width - 16 * 2
@cursor_viewport.rect.width = width
if @width > 0 and @height > 0
@frame.bitmap = Bitmap.new(@width, @height)
@bg.bitmap = Bitmap.new(@width - 4, @height - 4)
draw_window
end
self.x = @x
self.y = @y
end
#--------------------------------------------------------------------------
# * Height
#--------------------------------------------------------------------------
def height=(height)
@height = height
@viewport.rect.height = height - 16 * 2
@cursor_viewport.rect.height = height
if @height > 0 and @width > 0
@frame.bitmap = Bitmap.new(@width, @height)
@bg.bitmap = Bitmap.new(@width - 4, @height - 4)
draw_window
end
self.x = @x
self.y = @y
end
#--------------------------------------------------------------------------
# * Opacity
#--------------------------------------------------------------------------
def opacity=(opacity)
value = [[opacity, 255].min, 0].max
@opacity = value
@contents_opacity = value
@back_opacity = value
@frame.opacity = value
@bg.opacity = value
@window.opacity = value
end
#--------------------------------------------------------------------------
# * Back Opacity
#--------------------------------------------------------------------------
def back_opacity=(opacity)
value = [[opacity, 255].min, 0].max
@back_opacity = value
@bg.opacity = value
end
#--------------------------------------------------------------------------
# * Contents Opacity
#--------------------------------------------------------------------------
def contents_opacity=(opacity)
value = [[opacity, 255].min, 0].max
@contents_opacity = value
@window.opacity = value
end
#--------------------------------------------------------------------------
# * Cursor Rectangle
#--------------------------------------------------------------------------
def cursor_rect
return @cursor_rect
end
#--------------------------------------------------------------------------
# * Cursor Rectangle=
#--------------------------------------------------------------------------
def cursor_rect=(rect)
@cursor_rect.x = rect.x
@cursor_rect.y = rect.y
if @cursor_rect.width != rect.width or @cursor_rect.height != rect.height
@cursor_rect.set(@cursor_rect.x, @cursor_rect.y, rect.width, rect.height)
end
end
#--------------------------------------------------------------------------
# * Windowskin
#--------------------------------------------------------------------------
def windowskin
return @skin.bitmap
end
#--------------------------------------------------------------------------
# * Windowskin=
#--------------------------------------------------------------------------
def windowskin=(windowskin)
return if windowskin == nil
if @skin.bitmap != windowskin
@pause_s.bitmap = windowskin
@pause_s.src_rect = @skin['pause0']
@skin.bitmap = windowskin
@cursor_rect.skin = windowskin
draw_window
draw_arrows
end
end
#--------------------------------------------------------------------------
# * Stretch=
#--------------------------------------------------------------------------
def stretch=(bool)
if @stretch != bool
@stretch = bool
draw_window
end
end
#--------------------------------------------------------------------------
# * Set Arrow
#--------------------------------------------------------------------------
def set_arrows
@arrows[0].x = @width / 2 - 8
@arrows[0].y = 8
@arrows[1].x = 8
@arrows[1].y = @height / 2 - 8
@arrows[2].x = @width - 16
@arrows[2].y = @height / 2 - 8
@arrows[3].x = @width / 2 - 8
@arrows[3].y = @height - 16
end
#--------------------------------------------------------------------------
# * Draw Arrow
#--------------------------------------------------------------------------
def draw_arrows
return if @skin.bitmap == nil
@arrows[0].bitmap.blt(0, 0, @skin.bitmap, @skin['arrow_up'])
@arrows[1].bitmap.blt(0, 0, @skin.bitmap, @skin['arrow_left'])
@arrows[2].bitmap.blt(0, 0, @skin.bitmap, @skin['arrow_right'])
@arrows[3].bitmap.blt(0, 0, @skin.bitmap, @skin['arrow_down'])
update_arrows
end
#--------------------------------------------------------------------------
# * Draw Window
#--------------------------------------------------------------------------
def draw_window
return if @skin.bitmap == nil
return if @width == 0 or @height == 0
if @frame.bitmap.nil?
@frame.bitmap = Bitmap.new(@width, @height)
@bg.bitmap = Bitmap.new(@width - 4, @height - 4)
end
@frame.bitmap.clear
@bg.bitmap.clear
if @stretch
dest_rect = Rect.new(0, 0, @width-4, @height-4)
@bg.bitmap.stretch_blt(dest_rect, @skin.bitmap, @skin['bg'])
else
bgw = Integer((@width-4) / 32) + 1
bgh = Integer((@height-4) / 32) + 1
for x in 0..bgw
for y in 0..bgh
@bg.bitmap.blt(x * 32, y * 32, @skin.bitmap, @skin['bg'])
end
end
for x in 0..bgw
@bg.bitmap.blt(x * 32, 0, @skin.bitmap, @skin['bg_up'])
@bg.bitmap.blt(x * 32, @height - 20, @skin.bitmap, @skin['bg_down'])
end
for y in 0..bgh
@bg.bitmap.blt(0, y * 32, @skin.bitmap, @skin['bg_left'])
@bg.bitmap.blt(@width -20, y * 32, @skin.bitmap, @skin['bg_right'])
end
@bg.bitmap.blt(0, 0, @skin.bitmap, @skin['bg_ulcorner'])
@bg.bitmap.blt(@width - 20, 0, @skin.bitmap, @skin['bg_urcorner'])
@bg.bitmap.blt(0, @height - 20, @skin.bitmap, @skin['bg_dlcorner'])
@bg.bitmap.blt(@width - 20, @height - 20, @skin.bitmap, @skin['bg_drcorner'])
end
bx = Integer((@width - 32) / @skin['up'].width) + 1
by = Integer((@height - 32) / @skin['left'].height) + 1
for x in 0..bx
w = @skin['up'].width
@frame.bitmap.blt(x * w + 16, 0, @skin.bitmap, @skin['up'])
@frame.bitmap.blt(x * w + 16, @height - 16, @skin.bitmap, @skin['down'])
end
for y in 0..by
h = @skin['left'].height
@frame.bitmap.blt(0, y * h + 16, @skin.bitmap, @skin['left'])
@frame.bitmap.blt(@width - 16, y * h + 16, @skin.bitmap, @skin['right'])
end
@frame.bitmap.erase(@width - 16, 0, 16, 16)
@frame.bitmap.erase(0, @height - 16, 16, 16)
@frame.bitmap.erase(@width - 16, @height - 16, 16, 16)
@frame.bitmap.blt(0, 0, @skin.bitmap, @skin['ul_corner'])
@frame.bitmap.blt(@width - 16, 0, @skin.bitmap, @skin['ur_corner'])
@frame.bitmap.blt(0, @height - 16, @skin.bitmap, @skin['dl_corner'])
@frame.bitmap.blt(@width - 16, @height - 16, @skin.bitmap, @skin['dr_corner'])
end
end
#==============================================================================
# Skin
#==============================================================================
class Skin
#--------------------------------------------------------------------------
# * Public Instance Variables
#--------------------------------------------------------------------------
attr_accessor :bitmap
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
@bitmap = nil
@values = {}
@values['bg'] = Rect.new(16, 16, 32, 32)
@values['bg_ulcorner'] = Rect.new(0, 0, 16, 16)
@values['bg_urcorner'] = Rect.new(48, 0, 16, 16)
@values['bg_dlcorner'] = Rect.new(0, 48, 16, 16)
@values['bg_drcorner'] = Rect.new(48, 48, 16, 16)
@values['bg_up'] = Rect.new(16, 0, 32, 16)
@values['bg_down'] = Rect.new(16, 48, 32, 16)
@values['bg_left'] = Rect.new(0, 16, 16, 32)
@values['bg_right'] = Rect.new(48, 16, 16, 32)
@values['pause0'] = Rect.new(96, 64, 16, 16)
@values['pause1'] = Rect.new(112, 64, 16, 16)
@values['pause2'] = Rect.new(96, 80, 16, 16)
@values['pause3'] = Rect.new(112, 80, 16, 16)
@values['arrow_up'] = Rect.new(88, 16, 16, 8)
@values['arrow_down'] = Rect.new(88, 40, 16, 8)
@values['arrow_left'] = Rect.new(80, 24, 8, 16)
@values['arrow_right'] = Rect.new(104, 24, 8, 16)
@values['ul_corner'] = Rect.new(64, 0, 16, 16)
@values['ur_corner'] = Rect.new(112, 0, 16, 16)
@values['dl_corner'] = Rect.new(64, 48, 16, 16)
@values['dr_corner'] = Rect.new(112, 48, 16, 16)
@values['up'] = Rect.new(80, 0, 32, 16)
@values['down'] = Rect.new(80, 48, 32, 16)
@values['left'] = Rect.new(64, 16, 16, 32)
@values['right'] = Rect.new(112, 16, 16, 32)
end
#--------------------------------------------------------------------------
# []
#--------------------------------------------------------------------------
def [](value)
return @values[value]
end
end
#==============================================================================
# Cursor_Rect
#==============================================================================
class Cursor_Rect < ::Sprite
#--------------------------------------------------------------------------
# * Public Instance Variables
#--------------------------------------------------------------------------
attr_reader :height
attr_reader :width
attr_reader :skin
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize(viewport)
super(viewport)
@width = 0
@height = 0
@skin = nil
@rect = {}
@rect['bg'] = Rect.new(65, 65, 30, 30)
@rect['cursor_up'] = Rect.new(65, 64, 30, 1)
@rect['cursor_down'] = Rect.new(65, 95, 30, 1)
@rect['cursor_left'] = Rect.new(64, 65, 1, 30)
@rect['cursor_right'] = Rect.new(95, 65, 1, 30)
@rect['upleft'] = Rect.new(64, 64, 1, 1)
@rect['upright'] = Rect.new(95, 64, 1, 1)
@rect['downleft'] = Rect.new(64, 95, 1, 1)
@rect['downright'] = Rect.new(95, 95, 1, 1)
end
#--------------------------------------------------------------------------
# * Windowskin
#--------------------------------------------------------------------------
def skin=(skin)
@skin = skin
draw_rect
end
#--------------------------------------------------------------------------
# * Width
#--------------------------------------------------------------------------
def width=(width)
return if @width == width
@width = width
if @width == 0 and self.bitmap != nil
self.bitmap.dispose
self.bitmap = nil
end
draw_rect
end
#--------------------------------------------------------------------------
# * Height
#--------------------------------------------------------------------------
def height=(height)
return if @height == height
@height = height
if @height == 0 and self.bitmap != nil
self.bitmap.dispose
self.bitmap = nil
end
draw_rect
end
#--------------------------------------------------------------------------
# * Set
#--------------------------------------------------------------------------
def set(x, y, width, height)
self.x = x + 16
self.y = y + 16
if @width != width or @height != height
@width = width
@height = height
if width > 0 and height > 0
draw_rect
end
end
end
#--------------------------------------------------------------------------
# * Empty
#--------------------------------------------------------------------------
def empty
self.x = 0
self.y = 0
self.width = 0
self.height = 0
end
#--------------------------------------------------------------------------
# * Draw Rectangle
#--------------------------------------------------------------------------
def draw_rect
return if @skin == nil
if @width > 0 and @height > 0
self.bitmap = Bitmap.new(@width, @height)
rect = Rect.new(1, 1, @width - 2, @height - 2)
self.bitmap.stretch_blt(rect, @skin, @rect['bg'])
self.bitmap.blt(0, 0, @skin, @rect['upleft'])
self.bitmap.blt(@width-1, 0, @skin, @rect['upright'])
self.bitmap.blt(0, @height-1, @skin, @rect['downright'])
self.bitmap.blt(@width-1, @height-1, @skin, @rect['downleft'])
rect = Rect.new(1, 0, @width - 2, 1)
self.bitmap.stretch_blt(rect, @skin, @rect['cursor_up'])
rect = Rect.new(0, 1, 1, @height - 2)
self.bitmap.stretch_blt(rect, @skin, @rect['cursor_left'])
rect = Rect.new(1, @height-1, @width - 2, 1)
self.bitmap.stretch_blt(rect, @skin, @rect['cursor_down'])
rect = Rect.new(@width - 1, 1, 1, @height - 2)
self.bitmap.stretch_blt(rect, @skin, @rect['cursor_right'])
end
end
end
#==============================================================================
# Bitmap
#==============================================================================
class Bitmap
#--------------------------------------------------------------------------
# * Letter Width
#--------------------------------------------------------------------------
def letter_width
return 12
end
#--------------------------------------------------------------------------
# * Letter Height
#--------------------------------------------------------------------------
def letter_height
return 28
end
#--------------------------------------------------------------------------
# * Text Size
#--------------------------------------------------------------------------
alias custom_window_text_size text_size
def text_size(*args)
if CustomWindow::BITMAP_FONT
Rect.new(0, 0, letter_width, letter_height)
else
custom_window_text_size(*args)
end
end
#--------------------------------------------------------------------------
# * Draw Text
#--------------------------------------------------------------------------
alias custom_window_draw_text draw_text
def draw_text(*args)
if CustomWindow::BITMAP_FONT
draw_bitmap_text(*args)
else
if CustomWindow::GRADIENT
draw_gradient_text(*args)
else
draw_shadow(*args) if CustomWindow::SHADOW
custom_window_draw_text(*args)
end
end
end
#--------------------------------------------------------------------------
# * Return Arguments
#--------------------------------------------------------------------------
def return_args(*args)
color = font.color.dup
if args[0].is_a?(Rect)
x, y, width, height = args[0].x, args[0].y, args[0].width, args[0].height
text = args[1]
align = args[2] == nil ? 0 : args[2]
else
x, y, width, height, text = args
align = args[5] == nil ? 0 : args[5]
end
text = sprintf(text)
return x, y, width, height, text, align, color
end
#--------------------------------------------------------------------------
# * Draw Shadow
#--------------------------------------------------------------------------
def draw_shadow(*args)
x, y, width, height, text, align, color = return_args(*args)
font.color = Color.new(0, 0, 0)
custom_window_draw_text(x + 2, y + 2, width, height, text, align)
font.color = color
end
#--------------------------------------------------------------------------
# * Draw Bitmap Text
#--------------------------------------------------------------------------
def draw_bitmap_text(*args)
x, y, width, height, text, align, color = return_args(*args)
input_string = []
text.size.times do
c = text.slice!(/./m)
input_string.push(c)
end
size = input_string.size * letter_width
case align
when 1
x = x + (width - size) / 2
when 2
x = x + width - size
end
black = Color.new(0, 0, 0)
for letter in input_string
print_letter(letter, x + 2, y + 2, black) if CustomWindow::SHADOW
print_letter(letter, x, y, color)
print_gradient_layer(letter, x, y, height, color) if CustomWindow::GRADIENT
x += letter_width
end
end
#--------------------------------------------------------------------------
# * Draw Gradient Text
#--------------------------------------------------------------------------
def draw_gradient_text(*args)
x, y, width, height, text, align, color = return_args(*args)
tmp = Bitmap.new(width, height)
tmp2 = Bitmap.new(width, height)
tmp.font.size = font.size
tmp.font.name = font.name
if CustomWindow::SHADOW
tmp.font.color = Color.new(0, 0, 0)
tmp.custom_window_draw_text(2, 2, width, height, text, align)
end
tmp.font.color = color.gradient
tmp.custom_window_draw_text(0, 0, width, height, text, align)
h = [tmp.text_size(text).height, 1].max
p = (height / 2) - (h / 2)
for i in 0...height
opacity = set_opacity(i, p, h)
tmp2.blt(0, i, tmp, Rect.new(0, i, width, 1), opacity)
end
temp_color = font.color
font.color = color
custom_window_draw_text(x, y, width, height, text, align)
font.color = temp_color
blt(x, y, tmp2, Rect.new(0, 0, width, height))
tmp.dispose
tmp2.dispose
end
#--------------------------------------------------------------------------
# * Print Gradient Layer
#--------------------------------------------------------------------------
def print_gradient_layer(letter, x, y, height, color)
tmp = Bitmap.new(12, 28)
tmp2 = Bitmap.new(12, 28)
tmp.print_letter(letter, 0, 0, color.gradient)
h = letter_height
p = (height / 2) - (h / 2)
for i in 0...h
opacity = set_opacity(i, p, h)
tmp2.blt(0, i, tmp, Rect.new(0, i, 12, 1), opacity)
end
blt(x, y, tmp2, Rect.new(0, 0, 12, 28))
tmp.dispose
tmp2.dispose
end
#--------------------------------------------------------------------------
# * Set Opacity
#--------------------------------------------------------------------------
def set_opacity(i, p, h)
if i < p
opacity = 0
elsif i >= p + h
opacity = 255
else
r = ((i - p) * 1.0 / h)
r -= (0.5 - r) * 0.5
opacity = r * 255
opacity = 0 if opacity < 0
opacity = 255 if opacity > 255
end
return opacity
end
#--------------------------------------------------------------------------
# * Print Letter
#--------------------------------------------------------------------------
def print_letter(input, x, y, color)
case input
when "A"
fill_rect(x, y + 16, 2, 8, color)
fill_rect(x + 2, y + 10, 2, 6, color)
fill_rect(x + 2, y + 18, 2, 2, color)
fill_rect(x + 4, y + 6, 2, 4, color)
fill_rect(x + 2, y + 18, 6, 2, color)
fill_rect(x + 2, y + 18, 6, 2, color)
fill_rect(x + 6, y + 10, 2, 6, color)
fill_rect(x + 8, y + 16, 2, 8, color)
when "Ą"
fill_rect(x, y + 16, 2, 8, color)
fill_rect(x + 2, y + 10, 2, 6, color)
fill_rect(x + 2, y + 18, 2, 2, color)
fill_rect(x + 4, y + 6, 2, 4, color)
fill_rect(x + 2, y + 18, 6, 2, color)
fill_rect(x + 2, y + 18, 6, 2, color)
fill_rect(x + 6, y + 10, 2, 6, color)
fill_rect(x + 8, y + 16, 2, 8, color)
fill_rect(x + 6, y + 24, 2, 2, color)
fill_rect(x + 8, y + 26, 2, 2, color)
when "B"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 14, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 6, color)
fill_rect(x + 8, y + 16, 2, 6, color)
when "C"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 4, color)
fill_rect(x + 8, y + 18, 2, 4, color)
when "Ć"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 4, color)
fill_rect(x + 8, y + 18, 2, 4, color)
fill_rect(x + 4, y + 4, 2, 2, color)
fill_rect(x + 6, y + 2, 2, 2, color)
when "D"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 2, color)
fill_rect(x + 6, y + 20, 2, 2, color)
fill_rect(x + 8, y + 10, 2, 10, color)
when "E"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 8, 2, color)
fill_rect(x + 2, y + 14, 6, 2, color)
fill_rect(x + 2, y + 22, 8, 2, color)
when "Ę"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 8, 2, color)
fill_rect(x + 2, y + 14, 6, 2, color)
fill_rect(x + 2, y + 22, 8, 2, color)
fill_rect(x + 6, y + 24, 2, 2, color)
fill_rect(x + 8, y + 26, 2, 2, color)
when "F"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 8, 2, color)
fill_rect(x + 2, y + 14, 6, 2, color)
when "G"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 8, y + 8, 2, 4, color)
fill_rect(x + 6, y + 16, 4, 2, color)
fill_rect(x + 8, y + 18, 2, 6, color)
fill_rect(x + 6, y + 20, 2, 2, color)
when "H"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 14, 6, 2, color)
fill_rect(x + 8, y + 6, 2, 18, color)
when "I"
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 4, y + 8, 2, 14, color)
fill_rect(x + 2, y + 22, 6, 2, color)
when "J"
fill_rect(x, y + 18, 2, 4, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 6, 2, 16, color)
when "K"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 14, 2, 2, color)
fill_rect(x + 4, y + 10, 2, 4, color)
fill_rect(x + 4, y + 16, 2, 4, color)
fill_rect(x + 6, y + 6, 2, 4, color)
fill_rect(x + 6, y + 20, 2, 4, color)
when "L"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 22, 8, 2, color)
when "Ł"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 22, 8, 2, color)
fill_rect(x + 2, y + 14, 2, 2, color)
fill_rect(x + 4, y + 12, 2, 2, color)
when "M"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 10, 2, 6, color)
fill_rect(x + 4, y + 16, 2, 8, color)
fill_rect(x + 6, y + 10, 2, 6, color)
fill_rect(x + 8, y + 6, 2, 18, color)
when "N"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 8, 2, 4, color)
fill_rect(x + 4, y + 12, 2, 6, color)
fill_rect(x + 6, y + 18, 2, 4, color)
fill_rect(x + 8, y + 6, 2, 18, color)
when "Ń"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 8, 2, 4, color)
fill_rect(x + 4, y + 12, 2, 6, color)
fill_rect(x + 6, y + 18, 2, 4, color)
fill_rect(x + 8, y + 6, 2, 18, color)
fill_rect(x + 4, y + 4, 2, 2, color)
fill_rect(x + 6, y + 2, 2, 2, color)
when "O"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 14, color)
when "Ó"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 14, color)
fill_rect(x + 4, y + 4, 2, 2, color)
fill_rect(x + 6, y + 2, 2, 2, color)
when "P"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 14, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 6, color)
when "Q"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 8, y + 8, 2, 14, color)
fill_rect(x + 4, y + 18, 2, 2, color)
fill_rect(x + 6, y + 20, 2, 2, color)
fill_rect(x + 8, y + 22, 2, 2, color)
when "R"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 14, 6, 2, color)
fill_rect(x + 8, y + 8, 2, 6, color)
fill_rect(x + 6, y + 16, 2, 2, color)
fill_rect(x + 8, y + 18, 2, 6, color)
when "S"
fill_rect(x, y + 8, 2, 4, color)
fill_rect(x, y + 18, 2, 4, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 2, y + 12, 2, 2, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 6, y + 16, 2, 2, color)
fill_rect(x + 8, y + 8, 2, 4, color)
fill_rect(x + 8, y + 18, 2, 4, color)
when "Ś"
fill_rect(x, y + 8, 2, 4, color)
fill_rect(x, y + 18, 2, 4, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 2, y + 12, 2, 2, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 6, y + 16, 2, 2, color)
fill_rect(x + 8, y + 8, 2, 4, color)
fill_rect(x + 8, y + 18, 2, 4, color)
fill_rect(x + 4, y + 4, 2, 2, color)
fill_rect(x + 6, y + 2, 2, 2, color)
when "T"
fill_rect(x, y + 6, 10, 2, color)
fill_rect(x + 4, y + 8, 2, 16, color)
when "U"
fill_rect(x, y + 6, 2, 16, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 6, 2, 16, color)
when "V"
fill_rect(x, y + 6, 2, 6, color)
fill_rect(x + 2, y + 12, 2, 6, color)
fill_rect(x + 4, y + 18, 2, 6, color)
fill_rect(x + 6, y + 12, 2, 6, color)
fill_rect(x + 8, y + 6, 2, 6, color)
when "W"
fill_rect(x, y + 6, 2, 10, color)
fill_rect(x + 2, y + 16, 2, 8, color)
fill_rect(x + 4, y + 6, 2, 10, color)
fill_rect(x + 6, y + 16, 2, 8, color)
fill_rect(x + 8, y + 6, 2, 10, color)
when "X"
fill_rect(x, y + 6, 2, 4, color)
fill_rect(x, y + 20, 2, 4, color)
fill_rect(x + 2, y + 10, 2, 4, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 6, y + 10, 2, 4, color)
fill_rect(x + 6, y + 16, 2, 4, color)
fill_rect(x + 8, y + 6, 2, 4, color)
fill_rect(x + 8, y + 20, 2, 4, color)
when "Y"
fill_rect(x, y + 6, 2, 4, color)
fill_rect(x + 2, y + 10, 2, 4, color)
fill_rect(x + 4, y + 14, 2, 10, color)
fill_rect(x + 6, y + 10, 2, 4, color)
fill_rect(x + 8, y + 6, 2, 4, color)
when "Z"
fill_rect(x, y + 6, 10, 2, color)
fill_rect(x + 8, y + 8, 2, 2, color)
fill_rect(x + 6, y + 10, 2, 4, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x, y + 20, 2, 2, color)
fill_rect(x, y + 22, 10, 2, color)
when "Ź"
fill_rect(x, y + 6, 10, 2, color)
fill_rect(x + 8, y + 8, 2, 2, color)
fill_rect(x + 6, y + 10, 2, 4, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x, y + 20, 2, 2, color)
fill_rect(x, y + 22, 10, 2, color)
fill_rect(x + 4, y + 4, 2, 2, color)
fill_rect(x + 6, y + 2, 2, 2, color)
when "Ż"
fill_rect(x, y + 6, 10, 2, color)
fill_rect(x + 8, y + 8, 2, 2, color)
fill_rect(x + 6, y + 10, 2, 4, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x, y + 20, 2, 2, color)
fill_rect(x, y + 22, 10, 2, color)
fill_rect(x + 4, y + 2, 2, 2, color)
when "a"
fill_rect(x, y + 14, 2, 2, color)
fill_rect(x, y + 18, 2, 4, color)
fill_rect(x + 2, y + 12, 4, 2, color)
fill_rect(x + 2, y + 16, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 14, 2, 8, color)
fill_rect(x + 8, y + 22, 2, 2, color)
when "ą"
fill_rect(x, y + 14, 2, 2, color)
fill_rect(x, y + 18, 2, 4, color)
fill_rect(x + 2, y + 12, 4, 2, color)
fill_rect(x + 2, y + 16, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 14, 2, 8, color)
fill_rect(x + 8, y + 22, 2, 2, color)
fill_rect(x + 6, y + 24, 2, 2, color)
fill_rect(x + 8, y + 26, 2, 2, color)
when "b"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 8, color)
when "c"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 8, y + 20, 2, 2, color)
when "ć"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 8, y + 20, 2, 2, color)
fill_rect(x + 4, y + 8, 2, 2, color)
fill_rect(x + 6, y + 6, 2, 2, color)
when "d"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 6, 2, 18, color)
when "e"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 8, y + 20, 2, 2, color)
fill_rect(x + 2, y + 16, 8, 2, color)
when "ę"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 8, y + 20, 2, 2, color)
fill_rect(x + 2, y + 16, 8, 2, color)
fill_rect(x + 6, y + 24, 2, 2, color)
fill_rect(x + 8, y + 26, 2, 2, color)
when "f"
fill_rect(x, y + 12, 2, 2, color)
fill_rect(x + 2, y + 8, 2, 16, color)
fill_rect(x + 4, y + 6, 4, 2, color)
fill_rect(x + 4, y + 12, 2, 2, color)
when "g"
fill_rect(x, y + 14, 2, 2, color)
fill_rect(x, y + 18, 2, 2, color)
fill_rect(x, y + 22, 2, 2, color)
fill_rect(x + 2, y + 12, 4, 2, color)
fill_rect(x + 2, y + 16, 4, 2, color)
fill_rect(x + 2, y + 20, 6, 2, color)
fill_rect(x + 2, y + 24, 6, 2, color)
fill_rect(x + 6, y + 14, 2, 2, color)
fill_rect(x + 8, y + 12, 2, 2, color)
fill_rect(x + 8, y + 22, 2, 2, color)
when "h"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 10, color)
when "i"
fill_rect(x + 4, y + 6, 2, 4, color)
fill_rect(x + 4, y + 12, 2, 12, color)
when "j"
fill_rect(x + 4, y + 6, 2, 4, color)
fill_rect(x + 4, y + 12, 2, 12, color)
fill_rect(x , y + 24, 4, 2, color)
when "k"
fill_rect(x, y + 6, 2, 18, color)
fill_rect(x + 2, y + 18, 4, 2, color)
fill_rect(x + 4, y + 16, 2, 2, color)
fill_rect(x + 6, y + 14, 2, 2, color)
fill_rect(x + 8, y + 12, 2, 2, color)
fill_rect(x + 6, y + 20, 2, 2, color)
fill_rect(x + 8, y + 22, 2, 2, color)
when "l"
fill_rect(x + 4, y + 6, 2, 18, color)
when "ł"
fill_rect(x + 4, y + 6, 2, 18, color)
fill_rect(x + 2, y + 14, 2, 2, color)
fill_rect(x + 6, y + 12, 2, 2, color)
when "m"
fill_rect(x, y + 12, 2, 12, color)
fill_rect(x + 2, y + 12, 2, 2, color)
fill_rect(x + 4, y + 14, 2, 10, color)
fill_rect(x + 6, y + 12, 2, 2, color)
fill_rect(x + 8, y + 14, 2, 10, color)
when "n"
fill_rect(x, y + 12, 2, 12, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 10, color)
when "ń"
fill_rect(x, y + 12, 2, 12, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 10, color)
fill_rect(x + 4, y + 8, 2, 2, color)
fill_rect(x + 6, y + 6, 2, 2, color)
when "o"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 8, color)
when "ó"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 8, color)
fill_rect(x + 4, y + 8, 2, 2, color)
fill_rect(x + 6, y + 6, 2, 2, color)
when "p"
fill_rect(x, y + 12, 2, 14, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 8, color)
when "q"
fill_rect(x, y + 14, 2, 8, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 12, 2, 14, color)
when "r"
fill_rect(x + 2, y + 12, 2, 12, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 6, y + 12, 4, 2, color)
when "s"
fill_rect(x, y + 14, 2, 2, color)
fill_rect(x, y + 20, 2, 2, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 16, 4, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 6, y + 18, 2, 2, color)
fill_rect(x + 8, y + 20, 2, 2, color)
when "ś"
fill_rect(x, y + 14, 2, 2, color)
fill_rect(x, y + 20, 2, 2, color)
fill_rect(x + 2, y + 12, 6, 2, color)
fill_rect(x + 2, y + 16, 4, 2, color)
fill_rect(x + 2, y + 22, 6, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 6, y + 18, 2, 2, color)
fill_rect(x + 8, y + 20, 2, 2, color)
fill_rect(x + 4, y + 8, 2, 2, color)
fill_rect(x + 6, y + 6, 2, 2, color)
when "t"
fill_rect(x, y + 12, 6, 2, color)
fill_rect(x + 2, y + 6, 2, 16, color)
fill_rect(x + 4, y + 22, 4, 2, color)
when "u"
fill_rect(x, y + 12, 2, 10, color)
fill_rect(x + 2, y + 22, 8, 2, color)
fill_rect(x + 8, y + 12, 2, 10, color)
when "v"
fill_rect(x, y + 12, 2, 4, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x + 4, y + 20, 2, 4, color)
fill_rect(x + 6, y + 16, 2, 4, color)
fill_rect(x + 8, y + 12, 2, 4, color)
when "w"
fill_rect(x, y + 12, 2, 6, color)
fill_rect(x + 2, y + 18, 2, 6, color)
fill_rect(x + 4, y + 12, 2, 6, color)
fill_rect(x + 6, y + 18, 2, 6, color)
fill_rect(x + 8, y + 12, 2, 6, color)
when "x"
fill_rect(x, y + 12, 2, 2, color)
fill_rect(x, y + 22, 2, 2, color)
fill_rect(x + 2, y + 14, 2, 2, color)
fill_rect(x + 2, y + 20, 2, 2, color)
fill_rect(x + 4, y + 16, 2, 4, color)
fill_rect(x + 6, y + 14, 2, 2, color)
fill_rect(x + 6, y + 20, 2, 2, color)
fill_rect(x + 8, y + 12, 2, 2, color)
fill_rect(x + 8, y + 22, 2, 2, color)
when "y"
fill_rect(x, y + 12, 2, 4, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x + 4, y + 20, 2, 4, color)
fill_rect(x + 6, y + 16, 2, 4, color)
fill_rect(x + 8, y + 12, 2, 4, color)
fill_rect(x, y + 24, 4, 2, color)
when "z"
fill_rect(x, y + 12, 10, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 6, y + 16, 2, 2, color)
fill_rect(x + 4, y + 18, 2, 2, color)
fill_rect(x + 2, y + 20, 2, 2, color)
fill_rect(x, y + 22, 10, 2, color)
when "ź"
fill_rect(x, y + 12, 10, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 6, y + 16, 2, 2, color)
fill_rect(x + 4, y + 18, 2, 2, color)
fill_rect(x + 2, y + 20, 2, 2, color)
fill_rect(x, y + 22, 10, 2, color)
fill_rect(x + 4, y + 8, 2, 2, color)
fill_rect(x + 6, y + 6, 2, 2, color)
when "ż"
fill_rect(x, y + 12, 10, 2, color)
fill_rect(x + 8, y + 14, 2, 2, color)
fill_rect(x + 6, y + 16, 2, 2, color)
fill_rect(x + 4, y + 18, 2, 2, color)
fill_rect(x + 2, y + 20, 2, 2, color)
fill_rect(x, y + 22, 10, 2, color)
fill_rect(x + 4, y + 8, 2, 2, color)
when "0"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 14, color)
when "1"
fill_rect(x + 2, y + 8, 2, 2, color)
fill_rect(x + 4, y + 6, 2, 18, color)
when "2"
fill_rect(x, y + 8, 2, 4, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 6, color)
fill_rect(x + 4, y + 14, 2, 2, color)
fill_rect(x + 2, y + 16, 2, 4, color)
fill_rect(x, y + 20, 2, 4, color)
fill_rect(x + 2, y + 22, 6, 2, color)
when "3"
fill_rect(x, y + 8, 2, 4, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 6, color)
fill_rect(x + 2, y + 14, 4, 2, color)
fill_rect(x + 6, y + 16, 2, 6, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x, y + 18, 2, 4, color)
when "4"
fill_rect(x, y + 16, 2, 4, color)
fill_rect(x + 2, y + 12, 2, 4, color)
fill_rect(x + 4, y + 8, 2, 4, color)
fill_rect(x + 6, y + 6, 2, 18, color)
fill_rect(x + 2, y + 18, 8, 2, color)
when "5"
fill_rect(x, y + 6, 2, 10, color)
fill_rect(x + 2, y + 6, 6, 2, color)
fill_rect(x + 2, y + 12, 4, 2, color)
fill_rect(x, y + 18, 2, 4, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 14, 2, 8, color)
when "6"
fill_rect(x, y + 8, 2, 14, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 2, y + 14, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 4, color)
fill_rect(x + 6, y + 16, 2, 6, color)
when "7"
fill_rect(x, y + 6, 8, 2, color)
fill_rect(x + 6, y + 8, 2, 4, color)
fill_rect(x + 4, y + 12, 2, 6, color)
fill_rect(x + 2, y + 18, 2, 6, color)
when "8"
fill_rect(x, y + 8, 2, 6, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 6, color)
fill_rect(x + 2, y + 14, 4, 2, color)
fill_rect(x + 6, y + 16, 2, 6, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x, y + 16, 2, 6, color)
when "9"
fill_rect(x, y + 8, 2, 6, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 14, color)
fill_rect(x + 2, y + 14, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
fill_rect(x, y + 18, 2, 4, color)
when "."
fill_rect(x + 2, y + 20, 4, 4, color)
when ","
fill_rect(x + 2, y + 20, 4, 2, color)
fill_rect(x + 4, y + 22, 2, 2, color)
fill_rect(x + 2, y + 24, 2, 2, color)
when "-"
fill_rect(x, y + 14, 8, 2, color)
when ":"
fill_rect(x + 4, y + 10, 2, 4, color)
fill_rect(x + 4, y + 18, 2, 4, color)
when "!"
fill_rect(x + 4, y + 6, 2, 12, color)
fill_rect(x + 4, y + 20, 2, 4, color)
when "?"
fill_rect(x, y + 8, 2, 4, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 6, y + 8, 2, 6, color)
fill_rect(x + 4, y + 14, 2, 4, color)
fill_rect(x + 4, y + 20, 2, 4, color)
when "'"
fill_rect(x + 2, y + 2, 4, 2, color)
fill_rect(x + 4, y + 4, 2, 2, color)
fill_rect(x + 2, y + 6, 2, 2, color)
when "/"
fill_rect(x + 8, y + 4, 2, 4, color)
fill_rect(x + 6, y + 8, 2, 4, color)
fill_rect(x + 4, y + 12, 2, 6, color)
fill_rect(x + 2, y + 18, 2, 4, color)
fill_rect(x, y + 22, 2, 4, color)
when "["
fill_rect(x + 2, y + 6, 2, 18, color)
fill_rect(x + 4, y + 6, 4, 2, color)
fill_rect(x + 4, y + 22, 4, 2, color)
when "]"
fill_rect(x + 6, y + 6, 2, 18, color)
fill_rect(x + 2, y + 6, 4, 2, color)
fill_rect(x + 2, y + 22, 4, 2, color)
end
end
#--------------------------------------------------------------------------
# * Erase
#--------------------------------------------------------------------------
def erase(*args)
if args.size == 1
rect = args[0]
elsif args.size == 4
rect = Rect.new(*args)
end
fill_rect(rect, Color.new(0, 0, 0, 0))
end
end
#==============================================================================
# Window_Base
#==============================================================================
class Window_Base < Window
#--------------------------------------------------------------------------
# * Get Text Color
# n : text color number (0-15)
#--------------------------------------------------------------------------
def text_color(n)
n = 0 if n > 15
color = @skin.bitmap.get_pixel(n % 4 * 16, 64 + (n / 4 * 16))
self.contents.font.color.gradient = @skin.bitmap.get_pixel(n % 4 * 16, 79 + (n / 4 * 16))
return color
end
#--------------------------------------------------------------------------
# * Get Normal Text Color
#--------------------------------------------------------------------------
def normal_color; text_color(0); end
#--------------------------------------------------------------------------
# * Get Disabled Text Color
#--------------------------------------------------------------------------
def disabled_color; text_color(3); end
#--------------------------------------------------------------------------
# * Get System Text Color
#--------------------------------------------------------------------------
def system_color; text_color(1); end
#--------------------------------------------------------------------------
# * Get Crisis Text Color
#--------------------------------------------------------------------------
def crisis_color; text_color(8); end
#--------------------------------------------------------------------------
# * Get Knockout Text Color
#--------------------------------------------------------------------------
def knockout_color; text_color(2); end
end
|
|