赞 | 0 |
VIP | 0 |
好人卡 | 0 |
积分 | 1 |
经验 | 225 |
最后登录 | 2013-12-22 |
在线时间 | 0 小时 |
Lv1.梦旅人
- 梦石
- 0
- 星屑
- 50
- 在线时间
- 0 小时
- 注册时间
- 2007-8-23
- 帖子
- 539
|
加入我们,或者,欢迎回来。
您需要 登录 才可以下载或查看,没有帐号?注册会员
x
调试好的^使用时候用一个640*480的TIT.PNG放在下面.不用多说了吧.
- #——使用注意:默认会返回地图,如果需要返回开头,请将本脚本中的
- #return_scene = Scene_Map.new改为return_scene = Scene_Title.new
- class Scene_Credit
- CREDIT=<<_END_
- #这里输入字幕内容
- _END_
- end
- class Scene_Credit
- def initialize(return_scene = nil)
- @sprite = Sprite.new
- @sprite.bitmap = Bitmap.new("Graphics/Pictures/tit")
- @sprite.x = 0
- @sprite.y = 0
- if return_scene.nil?
- return_scene = Scene_Title.new
- end
- @return_scene = return_scene
- end
-
- def scene_start
- credit_lines = CREDIT.split(/\n/)
- credit_bitmap = Bitmap.new(576,32 * credit_lines.size)
- credit_lines.each_index do |i|
- line = credit_lines[i]
- credit_bitmap.draw_text(0,i * 32,576,32,line,1)
- end
- @credit_sprite = Sprite.new(Viewport.new(0,50,576,432))
- @credit_sprite.bitmap = credit_bitmap
- @credit_sprite.oy = -430
- @frame_index = 0
- @last_flag = false
- end
- def scene_end
- @credit_sprite.dispose
- @sprite.dispose
- end
-
- def last?
- return (@frame_index >= @credit_sprite.bitmap.height + 320)
- end
-
- def last
- if not @last_flag
- Audio.bgm_fade(10000)
- @last_flag = true
- @last_count = 0
- else
- @last_count += 1
- end
- if @last_count >= 300
- $scene = @return_scene
- end
- end
-
- def update
- @frame_index += 1
- return if cancel?
- last if last?
- @credit_sprite.oy += 1
- end
- def cancel?
- if Input.trigger?(Input::B)
- $scene = @return_scene
- return true
- end
- return false
- end
- def main
- scene_start
- # 过渡
- Graphics.transition
- # 主循环
- loop do
- Graphics.update
- Input.update
- update
- if $scene != self
- break
- end
- end
- # 准备过渡
- Graphics.freeze
- scene_end
- end
- end
复制代码
640*480的脚本
- -汗那...针对640*480脚本的才在这里
- #——使用注意:默认会返回地图,如果需要返回开头,请将本脚本中的
- #return_scene = Scene_Map.new改为return_scene = Scene_Title.new
- class Scene_Credit
- CREDIT=<<_END_
- #输入内容
- _END_
- end
- class Scene_Credit
- def initialize(return_scene = nil)
- @sprite = Sprite.new
- @sprite.bitmap = Bitmap.new("Graphics/Pictures/tit")
- @sprite.x = 0
- @sprite.y = 0
- if return_scene.nil?
- return_scene = Scene_Map.new
- end
- @return_scene = return_scene
- end
-
- def scene_start
- credit_lines = CREDIT.split(/\n/)
- credit_bitmap = Bitmap.new(640,32 * credit_lines.size)
- credit_lines.each_index do |i|
- line = credit_lines[i]
- credit_bitmap.draw_text(0,i * 32,640,32,line,1)
- end
- @credit_sprite = Sprite.new(Viewport.new(0,50,640,480))
- @credit_sprite.bitmap = credit_bitmap
- @credit_sprite.oy = -430
- @frame_index = 0
- @last_flag = false
- end
- def scene_end
- @credit_sprite.dispose
- @sprite.dispose
- end
-
- def last?
- return (@frame_index >= @credit_sprite.bitmap.height + 320)
- end
-
- def last
- if not @last_flag
- Audio.bgm_fade(10000)
- @last_flag = true
- @last_count = 0
- else
- @last_count += 1
- end
- if @last_count >= 300
- $scene = @return_scene
- end
- end
-
- def update
- @frame_index += 1
- return if cancel?
- last if last?
- @credit_sprite.oy += 1
- end
- def cancel?
- if Input.trigger?(Input::B)
- $scene = @return_scene
- return true
- end
- return false
- end
- def main
- scene_start
- # 过渡
- Graphics.transition
- # 主循环
- loop do
- Graphics.update
- Input.update
- update
- if $scene != self
- break
- end
- end
- # 准备过渡
- Graphics.freeze
- scene_end
- end
- end
复制代码
|
|