Esempio n. 1
0
 void gageProc()
 {
     //ゲージが空で無いかモードが増加の場合
     if (InputManager.emptyGageFlag | mode == GAGE_STATE.INCREMENT)
     {
         gageScale.x += Time.deltaTime * increment * redGage.transform.localScale.x;
     }
     //モードが減少の場合
     else if (mode == GAGE_STATE.ATTENUATION)
     {
         gageScale.x -= Time.deltaTime * attenuation * redGage.transform.localScale.x * (1f / GameManager.slowSpeed);
     }
     //モードが停止の場合
     if (mode != GAGE_STATE.STOP)
     {
         blueGage.transform.localScale = gageScale;
     }
     //スケールが0より小さい(ゲージがすべて赤)時に空フラグをtrueにする
     if (blueGage.transform.localScale.x < 0)
     {
         InputManager.emptyGageFlag = true;
     }
     //ゲージがすべて青になったら空フラグをfalseにし、モードをストップに
     else if (blueGage.transform.localScale.x > redGage.transform.localScale.x)
     {
         blueGage.transform.localScale = redGage.transform.localScale;
         gageScale = blueGage.transform.localScale;
         mode      = GAGE_STATE.STOP;
         InputManager.emptyGageFlag = false;
     }
 }
Esempio n. 2
0
 void gageProc()
 {
     //ゲージが空で無いかモードが増加の場合
     if (InputManager.emptyGageFlag | mode == GAGE_STATE.INCREMENT)
     {
         gageScale.x += Time.deltaTime * increment * redGage.transform.localScale.x;
     }
     //モードが減少の場合
     else if (mode == GAGE_STATE.ATTENUATION)
     {
         gageScale.x -= Time.deltaTime * attenuation * redGage.transform.localScale.x * (1f / GameManager.slowSpeed);
     }
     //モードが停止の場合
     if (mode != GAGE_STATE.STOP)
     {
         blueGage.transform.localScale = gageScale;
     }
     //スケールが0より小さい(ゲージがすべて赤)時に空フラグをtrueにする
     if (blueGage.transform.localScale.x < 0)
     {
         InputManager.emptyGageFlag = true;
     }
     //ゲージがすべて青になったら空フラグをfalseにし、モードをストップに
     else if (blueGage.transform.localScale.x > redGage.transform.localScale.x)
     {
         blueGage.transform.localScale = redGage.transform.localScale;
         gageScale = blueGage.transform.localScale;
         mode = GAGE_STATE.STOP;
         InputManager.emptyGageFlag = false;
     }
 }
Esempio n. 3
0
 // Use this for initialization
 void Start()
 {
     blueGage.transform.localScale = redGage.transform.localScale;
     gageScale = blueGage.transform.localScale;
     mode = GAGE_STATE.STOP;
 }
Esempio n. 4
0
 // Use this for initialization
 void Start()
 {
     blueGage.transform.localScale = redGage.transform.localScale;
     gageScale = blueGage.transform.localScale;
     mode      = GAGE_STATE.STOP;
 }