| 赞 | 3  | 
 
| VIP | 109 | 
 
| 好人卡 | 208 | 
 
| 积分 | 3 | 
 
| 经验 | 22037 | 
 
| 最后登录 | 2025-4-27 | 
 
| 在线时间 | 1196 小时 | 
 
 
 
 
 
Lv2.观梦者 虚構歪曲
	- 梦石
 - 0 
 
        - 星屑
 - 334 
 
        - 在线时间
 - 1196 小时
 
        - 注册时间
 - 2010-12-18
 
        - 帖子
 - 3928
 
 
   
 
 | 
	
 本帖最后由 忧雪の伤 于 2011-2-26 16:03 编辑  
renxiaomei 发表于 2011-2-26 16:02 ![]()  
回复 忧雪の伤 的帖子 
 
谢谢了。 - #==============================================================================
 
 - # ■ 【ISA】敌人名字显示 - Monster Name Display
 
 - #------------------------------------------------------------------------------
 
 - # - 2011.2.19
 
 - #   初始化 忧雪の伤
 
 - # - 2011.2.20
 
 - #   更新 忧雪の伤
 
 - # - 2011.2.25
 
 - #   更新 忧雪の伤
 
 - # - 2011.2.26
 
 - #   更新 忧雪の伤
 
 - #______________________________________________________________________________
 
 - # 
 
 - # 追加敌人战斗中名字的显示。
 
 - #
 
 - #==============================================================================
 
 - #==============================================================================
 
 - # ★ 设定部分 ★
 
 - #==============================================================================
 
 - module ISA 
 
 -   # 功能开关
 
 -   MND = true
 
 -   # 字体名称
 
 -   MND_FONT_NAME = ["黑体"]
 
 -   # 字体大小
 
 -   MND_FONT_SIZE = 22
 
 -   # 字体颜色
 
 -   MND_FONT_COLOR = Color.new(255, 255, 255, 255)
 
 -   # 字体描边
 
 -   MND_FONT_SHADOW = true
 
 -   # 字体描边颜色
 
 -   MND_FONT_SHADOW_COLOR = Color.new(-255, -255, -255, 255)
 
 -   # 字体粗体
 
 -   MND_FONT_BOLD = true
 
 -   # 字体斜体
 
 -   MND_FONT_ITALIC = false
 
 -   # X坐标修正
 
 -   MND_X_PLUS = -80
 
 -   # Y坐标修正
 
 -   MND_Y_PLUS = -80
 
 -   # 透明度设定
 
 -   MND_WINDOW_OPACITY = 0
 
 - end
 
  
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★
 
  
- # 注册【ISA】
 
 - $ISA = {} if $ISA == nil
 
 - $ISA["MND"] = true
 
  
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★
 
 -   
 
 - #==============================================================================
 
 - # ■ ISA_Window_Enemy_Name
 
 - #------------------------------------------------------------------------------
 
 - #  显示战斗画面敌人名字的窗口。
 
 - #==============================================================================
 
 - class ISA_Window_Enemy_Name < Window_Base
 
 -   #--------------------------------------------------------------------------
 
 -   # ● 初始化对像
 
 -   #--------------------------------------------------------------------------
 
 -   def initialize(x, y, id)
 
 -     super(0, 0, 160, 64)
 
 -     # 创建描绘区域
 
 -     self.contents = Bitmap.new(width - 32, height - 32)
 
 -     # 读取透明度
 
 -     self.opacity = ISA::MND_WINDOW_OPACITY
 
 -     # 坐标修正
 
 -     self.x = x + ISA::MND_X_PLUS
 
 -     self.y = y + ISA::MND_Y_PLUS
 
 -     # 代入id
 
 -     @id = id
 
 -     refresh
 
 -   end
 
 -   #--------------------------------------------------------------------------
 
 -   # ● 刷新
 
 -   #--------------------------------------------------------------------------
 
 -   def refresh
 
 -     self.contents.clear
 
 -     # 读取敌人
 
 -     @enemy = $game_troop.enemies[@id]
 
 -     # 读取名字
 
 -     text = @enemy.name 
 
 -     # 读取字体设定
 
 -     self.contents.font.name = ISA::MND_FONT_NAME
 
 -     self.contents.font.size = ISA::MND_FONT_SIZE
 
 -     self.contents.font.bold = ISA::MND_FONT_BOLD
 
 -     self.contents.font.italic = ISA::MND_FONT_ITALIC
 
 -     # 描边部分
 
 -     if ISA::MND_FONT_SHADOW == true
 
 -       # 读取描边色
 
 -       self.contents.font.color = ISA::MND_FONT_SHADOW_COLOR
 
 -       # 同时向八个方向扩展描绘
 
 -       self.contents.draw_text(1, 0, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(0, 1, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(-1, 0, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(0, -1, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(1, 1, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(-1, -1, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(1, -1, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -       self.contents.draw_text(-1, 1, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -     end
 
 -     # 主要部分
 
 -     self.contents.font.color = ISA::MND_FONT_COLOR
 
 -     self.contents.draw_text(0, 0, self.width - 32, self.height - 32, text,1) if ISA::MND
 
 -   end
 
 - end
 
 -   
 
 - #==============================================================================
 
 - # ■ Scene_Battle 
 
 - #------------------------------------------------------------------------------
 
 - #  处理战斗画面的类。
 
 - #==============================================================================
 
 - class Scene_Battle
 
 -   #--------------------------------------------------------------------------
 
 -   # ● 主处理
 
 -   #--------------------------------------------------------------------------
 
 -   alias old_main main
 
 -   def main
 
 -     # 声明别名
 
 -     # 准备队伍
 
 -     @troop_id = $game_temp.battle_troop_id
 
 -     $game_troop.setup(@troop_id)
 
 -     # 生成数组
 
 -     @ISA_Enemy_Name_window = []
 
 -     for i in 0...$game_troop.enemies.size
 
 -       # 获取敌人
 
 -       @enemy = $game_troop.enemies[i]
 
 -       # 读取画面X、Y坐标
 
 -       actor_x = @enemy.screen_x
 
 -       actor_y = @enemy.screen_y
 
 -       # 生成窗口
 
 -       @ISA_Enemy_Name_window[i] = ISA_Window_Enemy_Name.new(actor_x, actor_y, @enemy.id)
 
 -       @ISA_Enemy_Name_window[i].visible = true 
 
 -     end
 
 -     # 调用其他
 
 -     old_main
 
 -   end
 
 -   #--------------------------------------------------------------------------
 
 -   # ● 刷新画面
 
 -   #--------------------------------------------------------------------------
 
 -   alias old_update update
 
 -   def update
 
 -     # 全员死亡或者不存在队员的场合
 
 -     if $game_party.all_dead? or $game_party.actors.size == 0 
 
 -       for i in 0...$game_troop.enemies.size
 
 -         # 判断关闭
 
 -         @ISA_Enemy_Name_window[i].visible = false 
 
 -       end
 
 -     end
 
 -     # 调用其他
 
 -     old_update
 
 -   end
 
 -   #--------------------------------------------------------------------------
 
 -   # ● 战斗结束
 
 -   #     result : 結果 (0:胜利 1:失败 2:逃跑)
 
 -   #--------------------------------------------------------------------------
 
 -   alias old_battle_end battle_end
 
 -   def battle_end(result)
 
 -     # 声明别名
 
 -     for i in 0...$game_troop.enemies.size
 
 -       # 判断关闭
 
 -       @ISA_Enemy_Name_window[i].visible = false 
 
 -     end
 
 -     # 调用其他
 
 -     old_battle_end(result)
 
 -   end
 
 -   #--------------------------------------------------------------------------
 
 -   # ● 刷新画面 (主回合步骤 6 : 刷新)
 
 -   #--------------------------------------------------------------------------
 
 -   alias old_update_phase4_step6 update_phase4_step6
 
 -   def update_phase4_step6
 
 -     # 声明别名
 
 -     for i in 0...$game_troop.enemies.size
 
 -       # 获取敌人
 
 -       @enemy = $game_troop.enemies[i]
 
 -       if @enemy.hp0? 
 
 -         # 判断关闭
 
 -         @ISA_Enemy_Name_window[i].visible = false 
 
 -       end
 
 -     end
 
 -     # 调用其他
 
 -     old_update_phase4_step6
 
 -   end
 
 - end
 
  复制代码 |   
 
 
 
 |