赞 | 1 |
VIP | 32 |
好人卡 | 13 |
积分 | 16 |
经验 | 88876 |
最后登录 | 2021-7-25 |
在线时间 | 2205 小时 |
Lv3.寻梦者
- 梦石
- 0
- 星屑
- 1641
- 在线时间
- 2205 小时
- 注册时间
- 2010-6-27
- 帖子
- 1299
|
本帖最后由 pigsss 于 2012-2-13 13:22 编辑
a000b1745 发表于 2012-2-11 12:05
問一下唷...複製代碼的時候怎樣不會複製到前面的數字啊...
我之前都是下載範例直接黏貼。
01.#============ ...
點代碼最後的“複製”
‘‘- class Window_CP < Window_Selectable
- #--------------------------------------------------------------------------
- # ● 初始化对象
- #--------------------------------------------------------------------------
- def initialize
- super(0, 0, window_width, window_height)
- refresh
- self.openness = 0
- self.opacity = 200
- self.contents_opacity = 200
- end
-
- #--------------------------------------------------------------------------
- # ● 获取窗口的宽度
- #--------------------------------------------------------------------------
- def window_width
- 64
- end
- end
- class Scene_Battle
- #--------------------------------------------------------------------------
- # ● 生成名字窗口
- #--------------------------------------------------------------------------
- def create_name_window
- @name_window = Window_Name.new
- @name_window.y = 250 + Graphics.height - 416
- end
- #--------------------------------------------------------------------------
- # ● 生成状态窗口
- #--------------------------------------------------------------------------
- def create_CP_window
- @cp_window = Window_CP.new
- @cp_window.x = 0
- @cp_window.y = Graphics.height - 120
- end
- #-------------------------------------------------------------------------
- # ● 重定义:行动结束
- #------------------------------------------------------------------------
- def process_action_end
- @subject.on_action_end
- @subject.my_turn = false
- if @subject.cp >= 65535
- @subject.cp = 0
- end
- refresh_status
- @log_window.display_auto_affected_status(@subject)
- @log_window.wait_and_clear
- @log_window.display_current_state(@subject)
- @log_window.wait_and_clear
- BattleManager.judge_win_loss
- @cp_thread.stop = false ###########
- end
- end
- class Window_Name < Window_Base
- #--------------------------------------------------------------------------
- # ● 初始化对象
- #--------------------------------------------------------------------------
- def initialize
- super(Graphics.width - 128, 0, window_width, fitting_height(1))
- self.openness = 0
- @actor = nil
- end
- #--------------------------------------------------------------------------
- # ● 获取窗口的宽度
- #--------------------------------------------------------------------------
- def window_width
- return 128
- end
- end
复制代码 适合任意分辨率了,修正了一个小bug
──pigsss于2012-2-13 13:14补充以上内容’’ |
|