How accurate is the timer?

Hi everyone, I have been speedrunning a certain game in VXAce. I will not mention the game unless asked to, since it's 18+. This game has recently been accepted on speedrun.com and we are trying to figure out rules. The main problem is using in game time (IGT), which is the time the game claims you've beaten the game in, against using an external timer, such as livesplit. The way IGT is measured at the moment is as follows: after the event that ends the run, we write a row that saves the game in a certain slot and then we check the time in that slot. I have a few technical questions. How accurate is this time? If I understand correctly, it counts frames. Will it count loading screens (the black screen we see while moving from a map to another)?
Is there variance in how long loading creens are?

On a side note, is it possible to add milliseconds to the in game timer?

I understand these are quite specific questions. I'd be happy even if you could refer me to someone who's knowledgeable. Thanks for any help
I'm no programmer, but I'm pretty certain the in-game clock and timer's speed depend on the game's current frame rate, i.e., a lower FPS means a slower timer, and inversely.

So no, in-game time isn't reliable.
Hey,

VXAce games generally run at a predetermined frame rate (60 by default), and the game logic is built around it. The frame count should include screen transitions, and screen transitions also have a fixed frame count.

As far as variance goes, the biggest issue might be that the game will pause while out of focus (which also freezes the frame count).

If one frame takes too long to compute, subsequent frames are shortened to let the game catch up, but this behaviour can be suspended if the game ends up over 1 second behind or Graphics.frame_reset is used (which will slightly distort the timer, but should only happen in extreme cases).

You can check the frame count by using Graphics.frame_count. For adding milliseconds to the save file, you could try to add this as a script:
Code:
class Game_System
 
  def playtime_s
    hour = playtime / 60 / 60
    min = playtime / 60 % 60
    sec = playtime % 60
    msec = (Graphics.frame_count % Graphics.frame_rate) * 1000 / Graphics.frame_rate
    sprintf("%02d:%02d:%02d.%03d", hour, min, sec, msec)
  end
end

Original thread: https://forums.rpgmakerweb.com/threads/how-accurate-is-the-timer.179842/