Project1

标题: 帮忙在我这个教程的发布页里面加个说明,谢谢 [打印本页]

作者: 闪电    时间: 2008-10-5 18:34
标题: 帮忙在我这个教程的发布页里面加个说明,谢谢
http://rpg.blue/web/htm/news842.htm
范例一里面描绘EXP有点问题,等级太高会报错,解决办法是:
window_Base下的EXPメーター の描画,改成以下内容


  1.   #--------------------------------------------------------------------------
  2.   # ● EXPメーター の描画
  3.   #--------------------------------------------------------------------------
  4.   def EXP(actor,x,y,w=96)
  5.     if actor.next_exp != 0
  6.   self.contents.fill_rect(x-2,y+20,w+4,11,Color.new(255,255,255,255))
  7.   self.contents.fill_rect(x-1,y+21,w+2,9,Color.new(0,0,0,255))
  8.     w1 = w * actor.now_exp/actor.next_exp
  9.   self.contents.fill_rect(x-1,y+21,w1,1,Color.new(0,120,210,255))
  10.   self.contents.fill_rect(x-1,y+22,w1,1,Color.new(0,120,230,255))
  11.   self.contents.fill_rect(x-1,y+23,w1,1,Color.new(0,120,250,255))
  12.   self.contents.fill_rect(x-1,y+24,w1,1,Color.new(0,120,270,255))
  13.   self.contents.fill_rect(x-1,y+25,w1,1,Color.new(0,125,290,255))
  14.   self.contents.fill_rect(x-1,y+26,w1,1,Color.new(0,120,270,255))
  15.   self.contents.fill_rect(x-1,y+27,w1,1,Color.new(0,120,250,255))
  16.   self.contents.fill_rect(x-1,y+28,w1,1,Color.new(0,120,230,255))
  17.   self.contents.fill_rect(x-1,y+29,w1,1,Color.new(0,120,210,255))
  18. else
  19.   self.contents.fill_rect(x-2,y+20,w+4,11,Color.new(255,255,255,255))
  20.   self.contents.fill_rect(x-1,y+21,w+2,9,Color.new(0,0,0,255))
  21.   self.contents.fill_rect(x-1,y+21,w+2,1,Color.new(0,120,210,255))
  22.   self.contents.fill_rect(x-1,y+22,w+2,1,Color.new(0,120,230,255))
  23.   self.contents.fill_rect(x-1,y+23,w+2,1,Color.new(0,120,250,255))
  24.   self.contents.fill_rect(x-1,y+24,w+2,1,Color.new(0,120,270,255))
  25.   self.contents.fill_rect(x-1,y+25,w+2,1,Color.new(0,125,290,255))
  26.   self.contents.fill_rect(x-1,y+26,w+2,1,Color.new(0,120,270,255))
  27.   self.contents.fill_rect(x-1,y+27,w+2,1,Color.new(0,120,250,255))
  28.   self.contents.fill_rect(x-1,y+28,w+2,1,Color.new(0,120,230,255))
  29.   self.contents.fill_rect(x-1,y+29,w+2,1,Color.new(0,120,210,255))
  30.   end
  31. end
复制代码

作者: 包子    时间: 2008-10-5 18:39
提示: 作者被禁止或删除 内容自动屏蔽




欢迎光临 Project1 (https://rpg.blue/) Powered by Discuz! X3.1