- UID
- 117
- 帖子
- 14933
- 主题
- 1013
- 精华
- 2
- 积分
- 23743
- 历练
- 3
- 声望
- 133
- 人气
- 2619
- 经验
- 21523
- 金钱
- 3486
- 注册时间
- 2009-10-1
- 最后登录
- 2024-11-21
- 在线时间
- 2308 小时
- 阅读权限
- 100
TA的每日心情 | 擦汗 昨天 20:16 |
---|
签到天数: 1406 天 [LV.10]以坛为家III - 精华
- 2
- 积分
- 23743
- 历练
- 3
- 声望
- 133
- 人气
- 2619
|
首先先把未完成的东西丢下:- $smmax = 200
- $smhave = []
- class Window_SMUP < Window_Base
- def initialize
- super(0, 0, 160, 94)
- self.contents = Bitmap.new(width - 32, height - 32)
- refresh
- end
- def refresh
- self.contents.clear
- self.contents.font.color = normal_color
- self.contents.draw_text(0, 0, 160, 32, "完成度", 2)
- smbfb = $smhave.size * 100
- smbfb /= 200
- self.contents.draw_text(0, 32, 160, 32, smbfb.to_s + "%", 2)
- end
- end
- class Window_SMCH < Window_Selectable
- def initialize
- super (160, 32, 160, 480-64)
- self.index = 0
- end
- def type (type)
- @type = type
- end
- def refresh
- if self.contents != nil
- self.contents.dispose
- self.contents = nil
- end
- @data = []
- for i in 1...$data_enemys.size
- if $data_enemys[i].battler_name = @type
- if $smhave.include(i)
- @data.push($data_enemys[i])
- else
- @data.push($data_enemys[i])
- end
- end
- end
- @item_max = @data.size
- if @item_max > 0
- self.contents = Bitmap.new(width - 32, row_max * 32)
- for i in 0...@item_max
- draw_enemy(i)
- end
- end
- $monst = @data
- $monsterindex = self.index
- end
- def draw_enemy(enemy)
- enemy = @data[index]
- if @actor.skill_can_use?(skill.id)
- self.contents.font.color = black_color
- else
- self.contents.font.color = black_color
- end
- x = 4
- y = index * 32
- rect = Rect.new(x, y, self.width / @column_max - 32, 32)
- self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
- opacity = self.contents.font.color == black_color ? 255 : 128
- self.contents.blt(x, y + 4, bitmap, Rect.new(0, 0, 24, 24), opacity)
- self.contents.draw_text(x, y, 999, 32,enemy.name, 0)
- end
- end
- class Window_SMZT < Window_Base
- def initialize
- super(320, 0, 360, 480)
- self.contents = Bitmap.new(width - 32, height - 32)
- refresh
- end
- def refresh
- enemy = $monst[$monsterindex]
- draw_enemy(enemy)
- end
- def draw_enemy(enemy)
- self.contents.draw_text(0, 0, 999, 32,enemy.name, 0)
-
- end
- end
复制代码- class Scene_SM
- def initialize
- @menu_index = 0
- end
- def main
- @up = Window_SMUP.new
- @ch = Window_SMCH.new
- @zt = Window_SMZT.new
- @ch.active = false
- @command_window = Window_Command2.new(160, ["", "", "","","","","","","","","",""]
- @command_window.index = @menu_index
- Graphics.transition
- loop do
- Graphics.update
- Input.update
- update
- if $scene != self
- break
- end
- end
- Graphics.freeze
- @up.dispose
- @ch.dispose
- @zt.dispose
- @command_window.dispose
- end
- def update
- @up.update
- @ch.update
- @zt.update
- @command_window.update
- data_update
- pic_update
- if Input.trigger?(Input::B)
- $game_system.se_play($data_system.cancel_se)
- $scene = Scene_Menu.new(0)
- return
- end
- end
- def data_update
- case @command_window.index
- when 0
- @ch.type("天神")
- when 1
- @ch.type("魔神")
- when 2
- @ch.type("神兽")
- when 3
- @ch.type("魔兽")
- when 4
- @ch.type("仙灵")
- when 5
- @ch.type("妖灵")
- when 6
- @ch.type("精怪")
- when 7
- @ch.type("鬼魂")
- when 8
- @ch.type("活尸")
- when 9
- @ch.type("生物")
- when 10
- @ch.type("人类")
- when 11
- @ch.type("魔王")
- end
- end
- def pic_update
-
- end
- end
复制代码 好吧,现在没头绪了,请大家协助我完成 |
|