设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索
查看: 3153|回复: 4
打印 上一主题 下一主题

[已经解决] 战斗中技能快捷键的修改

[复制链接]

Lv1.梦旅人

剑仙·影羽

梦石
0
星屑
172
在线时间
224 小时
注册时间
2010-3-20
帖子
1580
跳转到指定楼层
发表于 2010-10-1 09:42:55 | 只看该作者 回帖奖励 |正序浏览 |阅读模式
2星屑
本帖最后由 火ZHI意志 于 2010-10-1 09:45 编辑

战斗中技能快捷键脚本下载地址
http://rpg.blue/forum.php?mod=vi ... B%E6%8D%B7%E9%94%AE
我的要求就是把横的快捷键选择框改成竖的,在右边,高度要满足480个像素
就是:
                        1 图标
                       技能名称
                        2 图标
                       技能名称
以下类推……

能容纳几个快捷键就容纳几个,技能名称的字大小不能低于13
注意高度一定要充满480个像素,什么遮挡住角色状态的问题以及其他问题我自会处理…………

最佳答案

查看完整内容

呼 改好了 效果图: 话说那个13个字符的限制很BT啊 这样只能放下5个了 ==========================分 割 线========================= 脚本Scene_Battle 3###(就是他改的那个) 82行:@kjj = Window_Skill_s.new(@active_battler) 改为@kjj = Window_Skill_s.new(@active_battler) 下面这个替换原来的Window_Skill_s再把这个插入到MAIN前MS就可以了 这个是工程 不过高度不是480 因为这样会有一大块空白 等会再 ...

——至今为止,谁也没能分析出他们为什么会因为说了这些话而死。

Lv1.梦旅人

剑仙·影羽

梦石
0
星屑
172
在线时间
224 小时
注册时间
2010-3-20
帖子
1580
4
 楼主| 发表于 2010-10-2 19:10:29 | 只看该作者
其实我也不会…………非常感谢~~~

点评

滚动选择我自己去学学吧  发表于 2010-10-2 19:20

——至今为止,谁也没能分析出他们为什么会因为说了这些话而死。
回复

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
49
在线时间
228 小时
注册时间
2010-8-11
帖子
475
3
发表于 2010-10-2 18:55:14 | 只看该作者
回复 火ZHI意志 的帖子
不好意思
本来说昨天晚上的
但是今天才有空
脚本我就不发了
直接是工程
改了那个s和sr
我不会滚动选择
所以就很猥琐地减小了字体
快捷键gx.rar (191.21 KB, 下载次数: 92)

Cola目前水区暂住  AVG缓慢展开
P.S.上面恶意卖萌的是基佬哟
回复

使用道具 举报

Lv1.梦旅人

剑仙·影羽

梦石
0
星屑
172
在线时间
224 小时
注册时间
2010-3-20
帖子
1580
2
 楼主| 发表于 2010-10-1 11:57:45 | 只看该作者
话说高度为480的能给我吗
有一大片空白的问题我自己会解决的

点评

我现在换了一个电脑 480那个在另一台机子上 晚上发  发表于 2010-10-1 17:52
虽然还有一些地方不符合我的想法,不过这些细微的东西我自己去弄就好了~~ 再次感谢~~  发表于 2010-10-1 12:03

——至今为止,谁也没能分析出他们为什么会因为说了这些话而死。
回复

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
49
在线时间
228 小时
注册时间
2010-8-11
帖子
475
1
发表于 2010-10-1 09:42:56 | 只看该作者
本帖最后由 Cola酱 于 2010-10-1 10:59 编辑

呼 改好了
效果图:


话说那个13个字符的限制很BT啊
这样只能放下5个了
==========================分    割    线=========================
脚本Scene_Battle 3###(就是他改的那个)
82行:@kjj = Window_Skill_s.new(@active_battler) 改为@kjj = Window_Skill_s.new(@active_battler)
下面这个替换原来的Window_Skill_s
  1.   class Window_Skill_s < Window_Selectable
  2.   #--------------------------------------------------------------------------
  3.   # ● 初始化对像
  4.   #--------------------------------------------------------------------------
  5.   def initialize(actor)
  6.     @actor = actor
  7.     super(0, 480-96, 640, 96)
  8.     #super(480, 0, 160, 480)
  9.     self.contents = Bitmap.new(width - 32, height - 32)
  10.     @item_max = 5
  11.     @column_max = 5
  12.     @commands = ["1","2","3","4","5"]
  13.     refresh
  14.     self.index = 0
  15.   end
  16.   #--------------------------------------------------------------------------
  17.   # ● 刷新
  18.   #--------------------------------------------------------------------------
  19.   def refresh
  20.     self.contents.clear
  21.     for i in 0...@item_max
  22.       draw_item(i)
  23.     end
  24.   end
  25.   #--------------------------------------------------------------------------
  26.   # ● 描绘项目
  27.   #     index : 项目编号
  28.   #--------------------------------------------------------------------------
  29.   def draw_item(index)
  30.     x = index*60*2+30#4 + index * 160
  31.     self.contents.font.size = 18
  32.     self.contents.draw_text(x-25, 0, 32, 32, @commands[index])
  33.     if @actor.skill_s[index] != ""
  34.       
  35.     bitmap = RPG::Cache.icon($data_skills[@actor.skill_s[index]].icon_name)
  36.     opacity = self.contents.font.color == normal_color ? 255 : 128
  37.     self.contents.blt(x-10, 8, bitmap, Rect.new(0, 0, 24, 24), opacity)  
  38.       
  39.     self.contents.draw_text(x-48, 32, 160, 32, $data_skills[@actor.skill_s[index]].name,1)
  40.     end
  41.   end
  42.   #--------------------------------------------------------------------------
  43.   # ● 刷新光标矩形
  44.   #--------------------------------------------------------------------------
  45.   def update_cursor_rect
  46.     if @index < 0
  47.       self.cursor_rect.empty
  48.     else
  49.       if $game_temp.in_battle
  50.       self.cursor_rect.empty
  51.       else
  52.       self.cursor_rect.set(@index*120, 0, 64+48+12, 64)
  53.       end
  54.     end
  55.   end
  56. end

复制代码
再把这个插入到MAIN前
  1.   class Window_Skill_sr < Window_Selectable
  2.   #--------------------------------------------------------------------------
  3.   # ● 初始化对像
  4.   #--------------------------------------------------------------------------
  5.   def initialize(actor)
  6.     @actor = actor
  7.     #super(0, 480-96, 640, 96)
  8.     super(480, 0, 160, 320)
  9.     self.contents = Bitmap.new(width - 32, height - 32)
  10.     @item_max = 5
  11.     @column_max = 1
  12.     @commands = ["1","2","3","4","5"]
  13.     refresh
  14.     self.index = 0
  15.   end
  16.   #--------------------------------------------------------------------------
  17.   # ● 刷新
  18.   #--------------------------------------------------------------------------
  19.   def refresh
  20.     self.contents.clear
  21.     for i in 0...@item_max
  22.       draw_item(i)
  23.     end
  24.   end
  25.   #--------------------------------------------------------------------------
  26.   # ● 描绘项目
  27.   #     index : 项目编号
  28.   #--------------------------------------------------------------------------
  29.   def draw_item(index)
  30.     x = 32
  31.     y = index*60
  32.     self.contents.font.size = 18
  33.     self.contents.draw_text(x-25, y, 32, 32, @commands[index])
  34.     if @actor.skill_s[index] != ""
  35.       
  36.       bitmap = RPG::Cache.icon($data_skills[@actor.skill_s[index]].icon_name)
  37.       opacity = self.contents.font.color == normal_color ? 255 : 128
  38.       self.contents.blt(x-12, 8+y, bitmap, Rect.new(0, 0, 24, 24), opacity)  
  39.       
  40.     self.contents.draw_text(x-48 , y+32, 160, 32, $data_skills[@actor.skill_s[index]].name,1)
  41.     end
  42.   end
  43.   #--------------------------------------------------------------------------
  44.   # ● 刷新光标矩形
  45.   #--------------------------------------------------------------------------
  46.   def update_cursor_rect
  47.     if @index < 0
  48.       self.cursor_rect.empty
  49.     else
  50.       if $game_temp.in_battle
  51.       self.cursor_rect.empty
  52.       else
  53.       self.cursor_rect.set(@index*60, 0, 64, 64)
  54.       end
  55.     end
  56.   end
  57. end

复制代码
MS就可以了

这个是工程 快捷键gx.rar (187.21 KB, 下载次数: 129)

不过高度不是480
因为这样会有一大块空白
等会再改一下吧

点评

非常感谢~~~  发表于 2010-10-1 11:55

Cola目前水区暂住  AVG缓慢展开
P.S.上面恶意卖萌的是基佬哟
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

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

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

GMT+8, 2025-7-19 01:11

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表