赞 | 12 |
VIP | 107 |
好人卡 | 6 |
积分 | 4 |
经验 | 31122 |
最后登录 | 2024-6-29 |
在线时间 | 1606 小时 |
Lv2.观梦者 傻♂逼
- 梦石
- 0
- 星屑
- 374
- 在线时间
- 1606 小时
- 注册时间
- 2007-3-13
- 帖子
- 6562
|
加入我们,或者,欢迎回来。
您需要 登录 才可以下载或查看,没有帐号?注册会员
x
- #==============================================================================
- # ** Scene_Base
- #------------------------------------------------------------------------------
- # 这个类是游戏中所有场景画面所共同继承的父类。
- #==============================================================================
- class Scene_Base
- #--------------------------------------------------------------------------
- # * 程式开始
- #--------------------------------------------------------------------------
- def start
- $mylogo.show
- end
- #--------------------------------------------------------------------------
- # * 更新帧
- #--------------------------------------------------------------------------
- def update
- $mylogo.update
- end
- end
- #FOR VX
- def exitnovx
- print "你使用的不是VX"
- exit
- end
- Bitmap.new(1,1).clear_rect(0,0,1,1) rescue (exitnovx)
- GC.start
- class Logo
- Width = 255
- Height = 32
- HideFPS = 10
- FPS = 60
- Text = "本游戏在66RPG免费下载"
- Opacity = 200
- def initialize
- @bitmaps = Bitmap.new(Width,Height)
- @bitmaps.gradient_fill_rect(Rect.new(0,0,Width,Height),Color.new(0,0,0,255),Color.new(0,0,0,0))
- @bitmaps.draw_text(Rect.new(0,0,Width,Height),Text)
- @sprite = Sprite.new
- @sprite.x = 0
- @sprite.y = 0
- @sprite.z = 99999
- @sprite.bitmap = Bitmap.new(Width,Height)
- @showed = false
- @hideed = false
- @showing = false
- @hideing = false
- @nx = 0
- @xall = FPS/HideFPS
- @alp = 255
- @aa = 255 / Width
- end
- def HideTime
- return Width / @xall
- end
- def show
- return if @showed
- @hideing = false
- @showing = true
- end
- def hide
- return if @hideed
- @hideing = true
- @showing = false
- end
- def update
- if @showing
- # @sprite.bitmap.gradient_fill_rect(Rect.new(@nx,0,@xall,Height),Color.new(0,0,0,@alp+(@aa*@xall)-1),Color.new(0,0,0,@alp))
- @sprite.bitmap.blt(@nx, 0, @bitmaps, Rect.new(@nx,0,@xall,Height),Opacity)
- @alp = @alp - (@aa*@xall)
- @nx = @nx+@xall
- if @nx >= 256
- # @sprite.bitmap.draw_text(Rect.new(0,0,Width,Height),"本游戏在66RPG免费下载")
- @nx = 255
- @showing = false
- @showed = true
- @hideed = false
- @alp = @alp + @aa
- end
- end
- if @hideing
- @sprite.bitmap.clear_rect(Rect.new([@nx,0].max,0,@xall,Height))
- @nx -= @xall
- if @nx <= -1
- @sprite.bitmap.clear
- @nx = 0
- @hideing = false
- @hideed = true
- @showed = false
- @alp = 255
- end
-
- end
- end
- end
- $mylogo = Logo.new
复制代码
看左上角,多么好啊~~
Text = "本游戏在66RPG免费下载"
Width = 255
Height = 32
HideFPS = 10
FPS = 60
是对脚本的设定
分别是文字、宽度、高度、展示帧数(显示所用帧数、不准确(算法所有误))FPS是自定义FPS用的不用管
|
|