注册会员 登录
Project1 返回首页

IamI的个人空间 https://rpg.blue/?17962 [收藏] [复制] [分享] [RSS]

日志

<VX>存档变换(动态)

热度 2已有 897 次阅读2010-8-29 14:10 |个人分类:Ruby更讨厌|

又一枚诡异脚本,DK要的,写完没事贴出来吧……加入VX工程使用。

MINUS = 32
STEPS = 2
class Scene_File
  alias fxxx_create create_savefile_windows
  def create_savefile_windows
    fxxx_create
    @savefile_windows[1].height -= MINUS
    @savefile_windows[2].height -= MINUS
    @savefile_windows[3].height -= MINUS
    @savefile_windows[1].y -= MINUS * 0
    @savefile_windows[2].y -= MINUS * 1
    @savefile_windows[3].y -= MINUS * 2
    @savefile_windows[1].follow = @savefile_windows[0]
    @savefile_windows[2].follow = @savefile_windows[1]
    @savefile_windows[3].follow = @savefile_windows[2]
  end
  def cursor_down(wrap)
    last = @savefile_windows[@index]
    if @index < @item_max - 1 or wrap
      @index = (@index + 1) % @item_max
    end
    now = @savefile_windows[@index]
    for i in 0..MINUS / STEPS
      last.height -= STEPS
      now.height  += STEPS
      @savefile_windows[1].update
      @savefile_windows[2].update
      @savefile_windows[3].update
      Graphics.update
    end
  end
  def cursor_up(wrap)
    last = @savefile_windows[@index]
    if @index > 0 or wrap
      @index = (@index - 1 + @item_max) % @item_max
    end
    now = @savefile_windows[@index]
    for i in 0..MINUS / STEPS
      last.height -= STEPS
      now.height  += STEPS
      @savefile_windows[1].update
      @savefile_windows[2].update
      @savefile_windows[3].update
      Graphics.update
    end
  end
end

class Window_SaveFile
  attr_accessor :follow
  alias fxxx_update update
  def update
    fxxx_update
    if @follow != nil
      self.y = @follow.y + @follow.height
    end
  end
end

我必须承认这个算法非常的囧= =b 老规矩 贴张图

鸡蛋
1

鲜花

刚表态过的朋友 (1 人)

发表评论 评论 (1 个评论)

回复 DeathKing 2010-10-31 15:42
DK要的。。。。
手感诡异。。。小三角更诡异。

facelist doodle 涂鸦笔

您需要登录后才可以评论 登录 | 注册会员

拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-4-24 16:54

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

返回顶部