赞 | 90 |
VIP | 350 |
好人卡 | 311 |
积分 | 101 |
经验 | 150139 |
最后登录 | 2024-7-17 |
在线时间 | 5020 小时 |
Lv4.逐梦者 (版主) 无限の剣制
- 梦石
- 0
- 星屑
- 10074
- 在线时间
- 5020 小时
- 注册时间
- 2013-2-28
- 帖子
- 5030
|
本帖最后由 VIPArcher 于 2014-6-22 12:44 编辑
插入这个脚本- #==============================================================================
- #
- # ▼ Yanfly Engine Ace - Command Window Icons v1.00
- # -- Last Updated: 2011.12.11
- # -- Level: Normal
- # -- Requires: n/a
- #
- #==============================================================================
- $imported = {} if $imported.nil?
- $imported["YEA-CommandWindowIcons"] = true
- #==============================================================================
- # ▼ Updates
- # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # 2011.12.11 - Started Script and Finished.
- #
- #==============================================================================
- # ▼ Introduction
- # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Here's a script that allows you to allocate icons to each of your commands
- # provided that the text for the command matches the icon in the script. There
- # are, however, some scripts that this won't be compatible with and it's due
- # to them using unique way of drawing out their commands. This script does not
- # maintain compatibility for those specific scripts.
- #
- #==============================================================================
- # ▼ Instructions
- # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # To install this script, open up your script editor and copy/paste this script
- # to an open slot below ▼ Materials/素材 but above ▼ Main. Remember to save.
- #
- # Go to the module and match the text under ICON_HASH with a proper Icon ID.
- # You can find an icon's ID by opening up the icon select window in the RPG
- # Maker VX Ace database and look in the lower left corner.
- #
- #==============================================================================
- # ▼ Compatibility
- # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # This script is made strictly for RPG Maker VX Ace. It is highly unlikely that
- # it will run with RPG Maker VX without adjusting.
- #
- #==============================================================================
- module YEA
- module COMMAND_WINDOW_ICONS
-
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- # - Icon Hash -
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- # This hash controls all of the icon data for what's used with each text
- # item. Any text items without icons won't display icons. The text has to
- # match with the hash (case sensitive) to display icons.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- ICON_HASH ={
- # Matching Text => Icon ID,
- "开始" => 224, # Title scene.
- "继续" => 230, # Title scene.
- "消除" => 265, # Title scene. Game End scene.
- "自动" => 564, # Title scene. Game End scene.
- "战斗" => 547, # Battle scene.
- "撤退" => 546, # Battle scene.
- "攻击" => 544, # Battle scene.
- "防御" => 545, # Battle scene.
-
-
- "特技" => 565, # Skill scene. Battle scene.
- "魔法" => 566, # Skill scene. Battle scene.
-
-
- "睡眠" => 6, # Menu scene. Item scene. Battle scene.
- "合成" => 217, # Menu scene. Item scene. Battle scene.
- "淫语朗诵" => 122, # Menu scene. Item scene. Battle scene.
- "整队" => 11, # Menu scene.
- "技能升级" => 115, # Menu scene.
- "伙伴" => 165, # Menu scene.
- "情报" => 12, # Menu scene.
- "学习技能" => 232, # Menu scene.
- "性格" => 176, # Menu scene.
- "商店" => 165, # Menu scene.
- "设置" => 226, # Menu scene.
- "物品图鉴" => 231, # Menu scene.
- "异事录" => 728, # Menu scene.
- "任务确认" => 235, # Menu scene.
- "声音控制" => 4, # Menu scene.
- "传送" => 215, # Menu scene.
- "魔法世界" => 519, # Menu scene.
- "事件商店" => 241, # Menu scene.
- "证件" => 230, # Menu scene..
- "援护" => 338, # Menu scene.
-
-
- "主要职业" => 233, # Class scene.
- "次要职业" => 234, # Class scene.
-
- "确定" => 377, # Party scene.
- "取消" => 540, # Party scene.
- "还原" => 379, # Party scene.
- "完成" => 380, # Party scene.
-
- "物品" => 528, # Menu scene. Item scene. Battle scene.
- "道具" => 560, # Menu scene. Item scene. Battle scene.
- "技能" => 529, # Menu scene.
- "已学技能" => 529, # Menu scene.
- "装备" => 530, # Menu scene.
- "当前装备" => 530, # Menu scene.
- "状态" => 531, # Menu scene.
- "详细属性" => 543, # Menu scene.
- "基本信息" => 531, # Menu scene.
- "系统" => 532,
- "成就" => 533, # Menu scene. Item scene. Battle scene.
- "任务" => 534, # Menu scene. Item scene. Battle scene.
- "人物传记" => 548, # Menu scene. Item scene. Battle scene.
-
- "购买" => 559, # Menu scene. Item scene. Battle scene.
- "卖出" => 558, # Menu scene. Item scene. Battle scene.
- "存入物品" => 561, # Menu scene. Item scene. Battle scene.
- "取出物品" => 562, # Menu scene. Item scene. Battle scene.
-
- "更换装备" => 550, # Equip scene.
- "自动换装" => 551, # Equip scene.
- "全部卸下" => 549, # Equip scene.
-
- "进行中的任务" => 552, # Menu scene.
- "已完成的任务" => 553, # Menu scene.
- "退出查看任务" => 554, #Title scene. Game End scene.
- "武器" => 535, # Item scene.
- "护甲" => 536, # Item scene.
- "特殊物品" => 537, # Item scene.
-
- "覆盖" => 563, # Menu scene
- "保存记录" => 538, # Menu scene
- "读取记录" => 539, # Menu scene
- "返回上级" => 540, # Game End scene.
- "退出游戏" => 541, # Menu scene.
- "回到标题" => 542, # Game End scene.
- } # Do not remove this.
-
- end # COMMAND_WINDOW_ICONS
- end # YEA
- #==============================================================================
- # ▼ Editting anything past this point may potentially result in causing
- # computer damage, incontinence, explosion of user's head, coma, death, and/or
- # halitosis so edit at your own risk.
- #==============================================================================
- #==============================================================================
- # ■ Window_Command
- #==============================================================================
- class Window_Command < Window_Selectable
-
- #--------------------------------------------------------------------------
- # new method: use_icon?
- #--------------------------------------------------------------------------
- def use_icon?(text)
- return YEA::COMMAND_WINDOW_ICONS::ICON_HASH.include?(text)
- end
-
- #--------------------------------------------------------------------------
- # new method: command_icon
- #--------------------------------------------------------------------------
- def command_icon(text)
- return YEA::COMMAND_WINDOW_ICONS::ICON_HASH[text]
- end
-
- #--------------------------------------------------------------------------
- # overwrite method: draw_item
- #--------------------------------------------------------------------------
- def draw_item(index)
- enabled = command_enabled?(index)
- change_color(normal_color, enabled)
- rect = item_rect_for_text(index)
- text = command_name(index)
- if use_icon?(text)
- draw_icon_text(rect.clone, text, alignment, enabled)
- else
- draw_text(rect, text, alignment)
- end
- end
-
- #--------------------------------------------------------------------------
- # new method: draw_icon_text
- #--------------------------------------------------------------------------
- def draw_icon_text(rect, text, alignment, enabled)
- cw = text_size(text).width
- icon = command_icon(text)
- draw_icon(icon, rect.x, rect.y, enabled)
- rect.x += 24
- rect.width -= 24
- draw_text(rect, text, alignment)
- end
-
- end # Window_Command
- #==============================================================================
- #
- # ▼ End of File
- #
- #==============================================================================
复制代码 附赠UI图标一份,自行PS。改的UI图标 |
评分
-
查看全部评分
|