Hi, do you mean something like Time.timeSinceLevelLoad ? Otherwise you could increase some float variable: timeSinceStart += Time.fixedDeltaTime; in your FixedUpdate() function. If you wanna calculate the time since startup through scenes you could use a static float variable.
To get the fixed frame count you just have to divide Time.fixedTime by Time.fixedDeltaTime as you have discovered. However since those are floating point numbers the result might be slightly off. You can use Mathf.RoundToInt to get an actual integer value.
public static int FixedFrameCount()
{
return Mathf.RoundToInt(Time.fixedTime / Time.fixedDeltaTime);
}
This might get inaccurate after a longer playtime due to the dynamic accuracy range of floating point numbers but should be ok for quite a long period of time. So if you need an more “reliable” count you might want to count manually as the others have shown.