赞 | 0 |
VIP | 1 |
好人卡 | 28 |
积分 | 10 |
经验 | 59980 |
最后登录 | 2024-10-19 |
在线时间 | 1685 小时 |
Lv3.寻梦者
- 梦石
- 0
- 星屑
- 951
- 在线时间
- 1685 小时
- 注册时间
- 2009-7-25
- 帖子
- 534
|
回复 巧克力猫咪 的帖子
手打了一个
替换Window_Skill- #==============================================================================
- # ■ Window_Skill
- #------------------------------------------------------------------------------
- # 特技画面、可以使用的特技列表显示窗口。
- #==============================================================================
- class Window_Skill < Window_Selectable
- #--------------------------------------------------------------------------
- # ● 初始化对象
- # x : 窗口的 X 坐标
- # y : 窗口的 Y 坐标
- # width : 窗口的宽
- # height : 窗口的高
- # actor : 角色
- #--------------------------------------------------------------------------
- def initialize(x, y, width, height, actor)
- super(x, y, width, height)
- @actor = actor
- @column_max = 1##########################################3
- self.index = 0
- refresh
- end
- #--------------------------------------------------------------------------
- # ● 获取特技
- #--------------------------------------------------------------------------
- def skill
- return @data[self.index]
- end
- #--------------------------------------------------------------------------
- # ● 刷新
- #--------------------------------------------------------------------------
- def refresh
- @data = []
- for skill in @actor.skills
- @data.push(skill)
- if skill.id == @actor.last_skill_id
- self.index = @data.size - 1
- end
- end
- @item_max = @data.size
- create_contents
- for i in 0...@item_max
- draw_item(i)
- end
- end
- #--------------------------------------------------------------------------
- # ● 描绘项目
- # index : 项目编号
- #--------------------------------------------------------------------------
- def draw_item(index)
- rect = item_rect(index)
- self.contents.clear_rect(rect)
- skill = @data[index]
- if skill != nil
- rect.width -= 4
- enabled = @actor.skill_can_use?(skill)
- draw_item_name(skill, rect.x, rect.y, enabled)
- self.contents.draw_text(rect, @actor.calc_mp_cost(skill), 1)
- draw_skill_range(skill, rect, enabled)
- end
- end
- #--------------------------------------------------------------------------
- # ● 刷新帮助文本
- #--------------------------------------------------------------------------
- def update_help
- @help_window.set_text(skill == nil ? "" : skill.description)
- end
-
- def draw_skill_range(skill, rect, enabled)
- str=["无","敌方单体","敌方全体","敌方单体 连击",\
- "敌方单体 随机目标","敌方二体 随机目标","敌方三体 随机目标",\
- "我方单体","我方全体","我方单个濒死者","我方所有濒死者",\
- "使用者自身"][skill.scope]
- self.contents.font.color = normal_color
- self.contents.font.color.alpha = enabled ? 255 : 128
- self.contents.draw_text((rect.width)/2 + 24, rect.y, 172, WLH, str)
- str=""
- if skill.element_set.size==0
- str="无属性"
- self.contents.font.color = normal_color
- self.contents.font.color.alpha = enabled ? 255 : 128
- self.contents.draw_text(rect, str, 2)
- return
- else
- for i in skill.element_set
- str += $data_system.elements[i] + " "
- end
- self.contents.font.color = normal_color
- self.contents.font.color.alpha = enabled ? 255 : 128
- self.contents.draw_text(rect, str, 2)
- return
- end
- end
- end
复制代码 无责任饭粒。。
VX技能界面改.rar
(238.89 KB, 下载次数: 130)
|
评分
-
查看全部评分
|