transform.position assign attempt for 'turretBullet' is not valid. Input position is { NaN, NaN, NaN

I’m apperently getting an error with this code

        mySpeed = 10 * (5 / reloadTime);
        transform.Translate (Vector3.forward * Time.deltaTime * mySpeed);
        myDist += Time.deltaTime * mySpeed;
        if (myDist >= myRange) {
            Destroy(gameObject);
        }

The full error message

transform.position assign attempt for 'turretBullet' is not valid. Input position is { NaN, NaN, NaN }.
UnityEngine.Transform:Translate(Vector3)
turretBullet:Update() (at Assets/Script/damageTowers/turretBullet.cs:22)

Can you put the following after you calculate mySpeed and before you translate and give the results? Will probably give a clue as to what’s going on. I want to say reloadTime is 0, but that wouldn’t cause 3 NaN, as z should be infinite (at least in my quick test it was).

Debug.Log("reloadTime: " + reloadTime);
Debug.Log("mySpeed: " + mySpeed);

And to quickly confirm, mySpeed and reloadTime are floats?

Hey GiTS
Both of them is the type float.

reloadTime is equal to 5

If reloadTime is 5, then mySpeed should be 10, Vector3.forward is usually (0.0f, 0.0f, 1.0f) and as far as I know cannot be changed, Time.deltaTime is going to be a low float value, say 0.02f… which should result in (0.0f, 0.0f, 0.2f). One of these values isn’t right…

So can you tell me all the output for,

Debug.Log("reloadTime: " + reloadTime);
Debug.Log("mySpeed: " + mySpeed);
Debug.Log("deltaTime: " + Time.deltaTime);
Debug.Log("Forward: " + Vector3.forward);

Put it after you calculate mySpeed and before you translate, I want to know all of it because I am quite stumped as it’s working fine on mine.