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

Project1

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

[已经解决] 使用显示敌人血量脚本在战斗结束时会出现脚本错误如何解

[复制链接]

Lv1.梦旅人

梦石
0
星屑
55
在线时间
38 小时
注册时间
2010-9-4
帖子
43
跳转到指定楼层
1
发表于 2012-11-13 14:24:57 | 显示全部楼层 |只看大图 回帖奖励 |倒序浏览 |阅读模式
RT附上图
def dispose
if self.bitmap != nil
self.bitmap.dispose
@enemy_hpmp_window.dispose
end
super
end
请问哪里出错了?

点评

表示LZ有敌人血条显示的图标没?  发表于 2012-11-13 14:32

Lv1.梦旅人

梦石
0
星屑
55
在线时间
38 小时
注册时间
2010-9-4
帖子
43
2
 楼主| 发表于 2012-11-13 20:52:50 | 显示全部楼层
当然有
这脚本本来有显示确切的血量数值 和MP数字我把它改掉了
下面是脚本
class Window_Base < Window
#--------------------------------------------------------------------------
# ● 描绘敌人HP
#--------------------------------------------------------------------------
def draw_enemy_hp(enemy, x, y, width = 80)
draw_gauge(x, y, width, enemy.hp_rate, hp_gauge_color1, hp_gauge_color2)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 0, line_height, Vocab::hp_a)
self.contents.font.color = hp_color(enemy)
self.contents.draw_text(x + width - 0, y, 0, line_height, enemy.hp, 0)
#一个数字占16像素
end
#--------------------------------------------------------------------------
# ● 绘制敌人MP
#--------------------------------------------------------------------------
def draw_enemy_mp(enemy, x, y, width = 0)
draw_gauge(x, y, width, enemy.mp_rate, mp_gauge_color1, mp_gauge_color2)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 0, line_height, Vocab::mp_a)
self.contents.font.color = mp_color(enemy)
self.contents.draw_text(x + width - 0, y,0, line_height, enemy.mp, 0)
end
end

点评

我想我应该没把- - 请问该如何定义呢- -。。。。  发表于 2012-11-14 18:03
我说的是你有没血槽位图图标,错误显示你没定议位图  发表于 2012-11-14 09:02
回复

使用道具 举报

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

本版积分规则

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

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

GMT+8, 2024-5-21 20:13

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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