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

Project1

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

[已经过期] 关于MOG计时器与多元化计时器合并问题

[复制链接]

Lv3.寻梦者

梦石
0
星屑
2605
在线时间
896 小时
注册时间
2011-4-30
帖子
131

开拓者

跳转到指定楼层
1
发表于 2014-6-16 14:10:45 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有帐号?注册会员

x
让两个脚本互不干扰,也就是让MOG计时器具有正数和变速功能(时间条从左往右加)
多元化:
  1. #==============================================================================
  2. # ■ 事件計時器多元化控制  Diversiform Timer Control
  3. #-----------------------------------------------------------------------------
  4. #     作者:TERENCE (龙皇)
  5. #  本類別的實例請參考 $game_system
  6. #==============================================================================
  7. class Game_System
  8.   #--------------------------------------------------------------------------
  9.   # ● 自定义设定
  10.   #--------------------------------------------------------------------------
  11.   Timer_Pause = 127    # 計時器暫停的開關編號
  12.   
  13.   Timer_CountUp = 128    # 計時器 "啟動" 正數 的開關編號
  14.   Midway_CountUp = 129    # 計時器 "中途" 改變計數方式 的開關編號
  15.   
  16.   Count_speed = 129    # 計時器計算速度的變量編號
  17.   
  18.   #--------------------------------------------------------------------------
  19.   # ● 更新畫面
  20.   #--------------------------------------------------------------------------
  21.   def update
  22.     unless $game_switches[Timer_CountUp] #若要正數,使遊戲的10號開關為ON
  23.       # 計時器減 1
  24.       if @timer_working and @timer > 0*40
  25.         if $game_switches[Timer_Pause] # 計時器是否暫停
  26.           @timer -= 0
  27.         else
  28.            unless $game_switches[Midway_CountUp]
  29.               if $game_variables[Count_speed]<=0
  30.                 @timer -= 1
  31.               else
  32.                 @timer -= 1*$game_variables[Count_speed]
  33.               end
  34.            else
  35.              if @timer_working and @timer < 5999*40
  36.                if $game_variables[Count_speed]<=0
  37.                   @timer += 1
  38.                 else
  39.                   @timer += 1*$game_variables[Count_speed]
  40.                 end
  41.               end
  42.            end
  43.         end
  44.       end
  45.     else
  46.       # 計時器加 1
  47.       if @timer_working and @timer < 5999*40
  48.         if $game_switches[Timer_Pause] # 計時器是否暫停
  49.           @timer += 0
  50.         else
  51.            unless $game_switches[Midway_CountUp]
  52.               if $game_variables[Count_speed]<=0
  53.                 @timer += 1
  54.               else
  55.                 @timer += 1*$game_variables[Count_speed]
  56.               end
  57.            else
  58.               if @timer_working and @timer > 0*40
  59.                 if $game_variables[Count_speed]<=0
  60.                   @timer -= 1
  61.                 else
  62.                   @timer -= 1*$game_variables[Count_speed]
  63.                 end
  64.               end
  65.            end
  66.         end
  67.       end
  68.     end
  69.   end
  70. end
复制代码
MOG:

XP_TIME_METER.rar

198.01 KB, 下载次数: 37

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

本版积分规则

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

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

GMT+8, 2024-9-30 23:31

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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