mkxp/scripts/i18n_Language.rb

145 lines
4.2 KiB
Ruby
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

class Language
attr_reader :font
attr_reader :character_table
attr_reader :character_table_height
def initialize(font, character_table, character_table_height)
@font = font
@character_table = character_table
@character_table_height = character_table_height
end
def self.get(code = :en)
return LANGUAGES[code] || LANGUAGES[:en]
end
LANGUAGES = {
:en => Language.new(
'Terminus (TTF)', [
"A","B","C","D","E",
"F","G","H","I","J",
"K","L","M","N","O",
"P","Q","R","S","T",
"U","V","W","X","Y",
"Z"," "," "," "," ",
"+","-","*","/","!",
"1","2","3","4","5",
"a","b","c","d","e",
"f","g","h","i","j",
"k","l","m","n","o",
"p","q","r","s","t",
"u","v","w","x","y",
"z"," "," "," "," ",
"#","$","%","&","@",
"6","7","8","9","0",
], 8
),
:es => Language.new(
'Terminus (TTF)', [
"A","B","C","D","E",
"F","G","H","I","J",
"K","L","M","N","O",
"P","Q","R","S","T",
"U","V","W","X","Y",
"Z"," ","Ñ","Ü"," ",
"Á","É","Í","Ó","Ú",
"+","-","*","/","!",
"1","2","3","4","5",
"a","b","c","d","e",
"f","g","h","i","j",
"k","l","m","n","o",
"p","q","r","s","t",
"u","v","w","x","y",
"z"," ","ñ","ü"," ",
"á","é","í","ó","ú",
"¡","#","%","&","@",
"6","7","8","9","0",
], 9
),
:ja => Language.new(
'WenQuanYi Micro Hei', [
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"", "","", "","",
"","","","","",
"", "","", "","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","", "", "", "",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"", "","", "","",
"","","","","",
"", "","", "","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","", "", "",
], 9
),
:ko => Language.new(
'WenQuanYi Micro Hei', [
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
"","","","","",
], 8
),
}
end