The World
16-03-2008, 02:13 PM
السلام عليكم
اما بعد
سكريبت سهل وبسيط ورح يضيف حركة جميلة للعبة
كلنا نلاحظ جمود في قراءة الرسالة في RM بكل النسخ بشكل عام
هذا السكريبت سيضيف صوت اثناء عرض الرسالة في اللعبة
مثلا صوت الة كاتبة
او غيره بامكانكم اختيار اي صوت تريدونه
السكريبت : ( أضف فوف Main )
#==============================================================================
# ■ DeadlyDan_MessageSound v2.0 by DeadlyDan
#------------------------------------------------------------------------------
# Simple "typewriting" style sound when messages are displayed.
#==============================================================================
# Usage:
=begin
Simply change:
MS_SOUND = "Audio/SE/cursor"
To what ever sound file you want, for example:
MS_SOUND = "Audio/SE/cow"
If you want to change how fast it sounds, change
MS_FRAME_INTERVAL = 2
To, for example, if you want longer:
MS_FRAME_INTERVAL = 4
=end
class Window_Message < Window_Selectable
MS_SOUND = "Audio/SE/cursor"
MS_FRAME_INTERVAL = 2
def update_message
loop do
c = @text.slice!(/./m)
case c
when nil
finish_message
break
when "\x00"
new_line
if @line_count >= MAX_LINE
unless @text.empty?
self.pause = true
break
end
end
when "\x01"
@text.sub!(/\[([0-9]+)\]/, "")
contents.font.color = text_color($1.to_i)
next
when "\x02"
@gold_window.refresh
@gold_window.open
when "\x03"
@wait_count = 15
break
when "\x04"
@wait_count = 60
break
when "\x05"
self.pause = true
break
when "\x06"
@line_show_fast = true
when "\x07"
@line_show_fast = false
when "\x08"
@pause_skip = true
else
if ( @line_show_fast == false and @show_fast == false )
if ( Graphics.frame_count > ( @last_ms_sound_frame.to_i + MS_FRAME_INTERVAL ) )
Audio.se_play ( MS_SOUND, 100, 100 )
@last_ms_sound_frame = Graphics.frame_count
end
end
contents.draw_text(@contents_x, @contents_y, 40, WLH, c)
c_width = contents.text_size(c).width
@contents_x += c_width
end
break unless @show_fast or @line_show_fast
end
end
end
معلومات للتغير في السكرييت حسب الرغبة
في هذا السطر MS_SOUND = "Audio/SE/cursor"
قم بتغيير cursor الى اي صوت تريده موجود في المجلد SE مثل COW
اما هذا السطر MS_FRAME_INTERVAL = 2 فهو للتحكم بسرعة الصوت كل ما اردته اطول زيد في الرقم مثل 4 او 6 او .... وهكذا
أتمنى أن يكون السكريبت مفيد لكم
تحياتي ^__^
اما بعد
سكريبت سهل وبسيط ورح يضيف حركة جميلة للعبة
كلنا نلاحظ جمود في قراءة الرسالة في RM بكل النسخ بشكل عام
هذا السكريبت سيضيف صوت اثناء عرض الرسالة في اللعبة
مثلا صوت الة كاتبة
او غيره بامكانكم اختيار اي صوت تريدونه
السكريبت : ( أضف فوف Main )
#==============================================================================
# ■ DeadlyDan_MessageSound v2.0 by DeadlyDan
#------------------------------------------------------------------------------
# Simple "typewriting" style sound when messages are displayed.
#==============================================================================
# Usage:
=begin
Simply change:
MS_SOUND = "Audio/SE/cursor"
To what ever sound file you want, for example:
MS_SOUND = "Audio/SE/cow"
If you want to change how fast it sounds, change
MS_FRAME_INTERVAL = 2
To, for example, if you want longer:
MS_FRAME_INTERVAL = 4
=end
class Window_Message < Window_Selectable
MS_SOUND = "Audio/SE/cursor"
MS_FRAME_INTERVAL = 2
def update_message
loop do
c = @text.slice!(/./m)
case c
when nil
finish_message
break
when "\x00"
new_line
if @line_count >= MAX_LINE
unless @text.empty?
self.pause = true
break
end
end
when "\x01"
@text.sub!(/\[([0-9]+)\]/, "")
contents.font.color = text_color($1.to_i)
next
when "\x02"
@gold_window.refresh
@gold_window.open
when "\x03"
@wait_count = 15
break
when "\x04"
@wait_count = 60
break
when "\x05"
self.pause = true
break
when "\x06"
@line_show_fast = true
when "\x07"
@line_show_fast = false
when "\x08"
@pause_skip = true
else
if ( @line_show_fast == false and @show_fast == false )
if ( Graphics.frame_count > ( @last_ms_sound_frame.to_i + MS_FRAME_INTERVAL ) )
Audio.se_play ( MS_SOUND, 100, 100 )
@last_ms_sound_frame = Graphics.frame_count
end
end
contents.draw_text(@contents_x, @contents_y, 40, WLH, c)
c_width = contents.text_size(c).width
@contents_x += c_width
end
break unless @show_fast or @line_show_fast
end
end
end
معلومات للتغير في السكرييت حسب الرغبة
في هذا السطر MS_SOUND = "Audio/SE/cursor"
قم بتغيير cursor الى اي صوت تريده موجود في المجلد SE مثل COW
اما هذا السطر MS_FRAME_INTERVAL = 2 فهو للتحكم بسرعة الصوت كل ما اردته اطول زيد في الرقم مثل 4 او 6 او .... وهكذا
أتمنى أن يكون السكريبت مفيد لكم
تحياتي ^__^