Search Unity

Running high speed simulation

Discussion in 'Editor & General Support' started by frimalabs, Dec 8, 2015.

  1. frimalabs

    frimalabs

    Joined:
    Dec 8, 2015
    Posts:
    2
    Hi,

    I would like to be able to run my game at high speed (without rendering) in order to "test AI simulation outputs"
    Is there any way to do this?
    1: Run X number of frame with fixed time steps without rendering to speed up the process
    2: Disable unity auto-time increment, and increment it manualy?

    In past project I was able to do this because I was controlling everything, but I am now using NavMeshes and Animation Events... So it is really a time based system.

    Any suggestion is welcome!
     
  2. frimalabs

    frimalabs

    Joined:
    Dec 8, 2015
    Posts:
    2
    Auto-answering my post:
    You can use video rendering capabilities,
    Time.captureFramerate = 10000;

    This will force the time update to be whatever you want in between the frames.

    You can then run the build with command lines such as
    -batchmode -nographics

    So now I got every frame processed, with uniform time steps, at around 60x the speed of what I could get from the editor.
     
    Baste likes this.
  3. 295cade1

    295cade1

    Joined:
    Mar 9, 2013
    Posts:
    3
    Are you setting the timescale here, or how are you changing the game speed?
    Also is this running at a timespeed you set, or as fast as it can?