//****************************************************************** // ・ これ以降は内部処理関数(アクセス拒否) //******************************************************************* private void PopWindow() { if (!end_flag) { x_scl += speed_x; if (x_scl >= X_Scl) { x_scl = X_Scl; } y_scl += speed_y; if (y_scl >= Y_Scl) { y_scl = Y_Scl; } this.gameObject.GetComponent <RectTransform>().localScale = new Vector3(x_scl, y_scl, 1.0f); if (x_scl == X_Scl && y_scl == Y_Scl) { end_flag = true; } if (y_scl == Y_Scl) { y_flag = true; } } }
private void DeleteWindow() { if (!end_flag) { x_scl -= speed_x; if (x_scl <= 0.0f) { x_scl = 0.0f; } y_scl -= speed_y; if (y_scl <= 0.0f) { y_scl = 0.0f; } this.gameObject.GetComponent <RectTransform>().localScale = new Vector3(x_scl, y_scl, 1.0f); // めんどいけど後から判定 if (x_scl == 0.0f && y_scl == 0.0f) { end_flag = true; } } }