Hello
I am working on a basic project, and i am facing a problem i wish i can have support to solve it.
My game is a rotating wheel with score decreasing from 99 to 0 with a speed 120.
the problem i am facing is that i am failing to add a feature which is after score become 90, the speed of the rotating wheel increase to 150 an than after reaching score 80 i want the speed to be 190.
i failed to make those additions, and i want your help. below you can find my spin code without any errors.
using UnityEngine;
using System.Collections;
public class Spin : MonoBehaviour {
public float speed = 120f;
private float direction = 1; //1: rotate clk, 0: rotate cclk
// Update is called once per frame
void FixedUpdate () {
//only rotate when in playing mode
if (GameManager.CurrentState == GameManager.GameState.Playing)
transform.Rotate (Vector3.forward, direction * speed * Time.fixedDeltaTime);
}
//called by Picker.cs
public void ChangeDirection(){
direction *= -1;
}
}
If you can help me with additions i should make to get best result
thanks in advance for your support.