Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question Tying physics to framerate

Discussion in 'Physics' started by evanFroelich, Aug 13, 2020.

  1. evanFroelich

    evanFroelich

    Joined:
    Apr 8, 2018
    Posts:
    1
    I am trying to train a neural net to throw a ball. it being a physics simulation the bottleneck on my training speed of the neural net is the speed at which the game runs. I would like to tie physics updates to frame rate and remove deltaTime from them so that if i can push out 180 frames a second i could effectively train the game at 3 times speed and go back to a locked 60 fps when i am viewing/demonstrating the net. Unity being a game engine normally what im trying to do is a big no no in games so i get why it might be difficult but is it possible to do? or do i have to abandon the physics/fixedupdate stuff all together and handle all movement code myself in update to tie it to my frame rate?
     
  2. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    11,321