Tran Le _Hai Yen
Dragon Quest
- 29/12/06
- 1,314
- 2
tình hình là phải đợi thêm 2 ngày nữa mới vào makegame đc
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.

Hi, các bác pro ơi cho em hỏi tí. Làm sao để đặt tên cho nhân vật chính... ý em là làm cái bảng để người chơi vô game sẽ tự đặt tên nhân vật theo ý mình.
Em chơi cái The Final Sword II của bác Dương thấy đặt tên tiếng việt được hay quá mà không biết làm, bác chỉ em nhá![]()
#==============================================================================
# * Window_NameInput
#===================================================
# MAKE GAME VIET NAM
# Website: http://www.bolobala.net
# Y!M: master_tinh89
# Mail: [email protected]
#===================================================
class Window_NameInput < Window_Base
CHARACTER_TABLE =
[
"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",
"6", "7", "8", "9", "0",
"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", "!", "@",
"#", "$", "%", "^", "&",
"*", "(", ")", "[", "]",
"{", "}", "<", ">", "?",
"¸", "µ", "¶", "·", "¹",
"¾", "»", "¼", "½", "Æ",
"Ð", "Ì", "Î", "Ï", "Ñ",
"Õ", "Ò", "Ó", "Ô", "Ö",
"Ý", "×", "Ø", "Ü", "Þ",
"ã", "ß", "á", "â", "ä",
"í", "ê", "ö", "÷", "ù",
"è", "å", "æ", "ç", "é",
"ó", "ï", "ñ", "ò", "ô",
"í", "ê", "ë", "ì", "î",
" ",
]
#--------------------------------------------------------------------------
# - Đặt biến
#--------------------------------------------------------------------------
def initialize
super(10, 128, 620, 352)
self.contents = Bitmap.new(width - 32, height - 32)
self.contents.font.name = $defaultfonttype # 2 biến Font này cần đặt sẵn bên Main trước.
self.contents.font.size = $defaultfontsize
@index = 0
refresh
update_cursor_rect
end
#--------------------------------------------------------------------------
# - Khung
#--------------------------------------------------------------------------
def character
return CHARACTER_TABLE[@index]
end
#--------------------------------------------------------------------------
# - Refreshment
#--------------------------------------------------------------------------
def refresh
self.contents.clear
for i in 0..150
x = 74 + i / 5 / 10 * 152 + i % 5 * 28
y = i / 5 % 10 * 28
self.contents.draw_text(x, y, 28, 28, CHARACTER_TABLE[i], 1)
end
self.contents.draw_text(500, 10 * 28, 85, 28, "Xong", 1)
end
#--------------------------------------------------------------------------
# - Rectangle renewal of cursor
#--------------------------------------------------------------------------
def update_cursor_rect
# When cursor position [ decision ] is
if @index >= 150
self.cursor_rect.set(500, 10 * 28, 85, 28)
# When cursor position [ decision ] it is other than
else
x = 74 + @index / 5 / 10 * 152 + @index % 5 * 28
y = @index / 5 % 10 * 28
self.cursor_rect.set(x, y, 28, 28)
end
end
#--------------------------------------------------------------------------
# - Frame renewal
#--------------------------------------------------------------------------
def update
super
# When cursor position [ decision ] is
if @index >= 151
# Down cursor
if Input.trigger?(Input::DOWN)
$game_system.se_play($data_system.cursor_se)
@index -= 151
end
# Up cursor
if Input.repeat?(Input::UP)
$game_system.se_play($data_system.cursor_se)
@index -= 151
end
# When cursor position [ decision ] it is other than
else
# When the right of the direction button is pushed
if Input.repeat?(Input::RIGHT)
# Depression state is not repeat when
# When cursor position is not right hand edge
if Input.trigger?(Input::RIGHT) or
@index / 50 < 5 or @index % 5 < 4
# Moving cursor to the right
$game_system.se_play($data_system.cursor_se)
if @index % 5 < 4
@index += 1
else
@index += 50 - 3
end
if @index >= 151
@index -= 151
end
end
end
# When the left of the direction button is pushed
if Input.repeat?(Input::LEFT)
# Depression state is not repeat when
# When cursor position is not the left edge
if Input.trigger?(Input::LEFT) or
@index / 50 > 0 or @index % 5 > 0
# Moving cursor to the left
$game_system.se_play($data_system.cursor_se)
if @index % 5 > 0
@index -= 1
else
@index -= 50 - 3
end
if @index < 0
@index += 151
end
end
end
# When the bottom of the direction button is pushed
if Input.repeat?(Input::DOWN)
# Moving cursor down
$game_system.se_play($data_system.cursor_se)
if @index % 50 < 45
@index += 5
else
@index += 151 - 45
end
end
# When the top of the direction button is pushed
if Input.repeat?(Input::UP)
# Depression state is not repeat when
# When cursor position is not the top
if Input.trigger?(Input::UP) or @index % 50 >= 5
# Moving cursor up
$game_system.se_play($data_system.cursor_se)
if @index % 50 >= 5
@index -= 5
else
@index += 151
end
end
end
end
update_cursor_rect
end
end
là sao???= cách gõ vô bảng hội thoại: \n[thứ tự nhân vật]
