Project1
标题:
为什么我弄了个脚本会冲突的?
[打印本页]
作者:
nazx
时间:
2008-2-16 21:47
标题:
为什么我弄了个脚本会冲突的?
我下了一个升级自动升级的脚本,但是却看不明怎样可以改.请问谁可以帮帮我??
还有我有一个显示敌人HP百分比的脚本,也不会用.求达人大大帮助!!
作者:
zero2
时间:
2008-2-16 22:11
那个是用在RGSS的吧,VX是RGSS2,有些地方不同,所以不兼容!!
作者:
啸心
时间:
2008-2-17 01:18
提示:
作者被禁止或删除 内容自动屏蔽
作者:
Beside
时间:
2008-2-17 01:23
原脚本地址贴一下
作者:
nazx
时间:
2008-2-17 03:42
#==============================================================================
# ■ Window_Help
#------------------------------------------------------------------------------
# 重新定义的内容,可以显示敌人的HP\MP百分比
# 作者:carol3_柳柳
#==============================================================================
class Window_Help < Window_Base
def set_enemy(actor)
self.contents.clear
draw_actor_name(actor, 4, 0)
draw_actor_state(actor, 140, 0)
carol3_draw_hp_bar(actor, 284, 0)
carol3_draw_sp_bar(actor, 460, 0)
@text = nil
self.visible = true
end
def carol3_draw_hp_bar(actor, x, y, width = 128) #宽度可调
self.contents.font.color = system_color
self.contents.fill_rect(x-1, y+17, width+2,6, Color.new(0, 0, 0, 255))
w = width * actor.hp / actor.maxhp
self.contents.fill_rect(x, y+18, w,1, Color.new(255, 96, 96, 255))
self.contents.fill_rect(x, y+19, w,1, Color.new(255, 0, 0, 255))
self.contents.fill_rect(x, y+20, w,1, Color.new(128, 0, 0, 255))
self.contents.fill_rect(x, y+21, w,1, Color.new(0, 0, 0, 255))
self.contents.draw_text(x,y,128,32,$data_system.words.hp,1)
self.contents.font.color = normal_color
end
def carol3_draw_sp_bar(actor, x, y, width = 128)
self.contents.font.color = system_color
self.contents.fill_rect(x-1, y+17, width+2,6, Color.new(0, 0, 0, 255))
w = width * actor.sp / actor.maxsp
self.contents.fill_rect(x, y+18, w,1, Color.new(128, 255, 255, 255))
self.contents.fill_rect(x, y+19, w,1, Color.new(0, 255, 255, 255))
self.contents.fill_rect(x, y+20, w,1, Color.new(0, 192, 192, 255))
self.contents.fill_rect(x, y+21, w,1, Color.new(0, 128, 128, 255))
self.contents.draw_text(x,y,128,32,$data_system.words.sp,1)
self.contents.font.color = normal_color
end
end
这个和这个
#--------------------------------------------------------------------------
# ● 更改 EXP
# exp : 新的 EXP
#--------------------------------------------------------------------------
def exp=(exp)
@exp = [[exp, 9999999].min, 0].max
# 升级
while @exp >= @exp_list[@level+1] and @exp_list[@level+1] > 0
@level += 1
@hp = maxhp
@sp = maxsp
# 学会特技
for j in $data_classes[@class_id].learnings
if j.level == @level
learn_skill(j.skill_id)
end
end
end
# 降级
while @exp < @exp_list[@level]
@level -= 1
end
# 修正当前的 HP 与 SP 超过最大值
@hp = [@hp, self.maxhp].min
@sp = [@sp, self.maxsp].min
end
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1