Hello Guest

Author Topic: Update 2dtoolkit in the physics update  (Read 5031 times)

Evil-Dog

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 38
    • View Profile
Update 2dtoolkit in the physics update
« on: January 05, 2014, 11:36:30 pm »
Hi there, I'm working on a game that we'd need to make deterministic.
I ask this in a global state of confusion but from what I understand, I'd need to run the sprite system on a deterministic fashion using the physics update and not the render update.

Any thoughts on that?
Is that something that would be doable?
Thanks :D

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Update 2dtoolkit in the physics update
« Reply #1 on: January 06, 2014, 11:14:19 am »
Ah. good old determinism in Unity :)
If you want to run the animation system (?) in physics update, just change animator Update -> FixedUpdate. That should be it really. You will need to use this together with script ordering to get more control over the whole pipeline.

Evil-Dog

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 38
    • View Profile
Re: Update 2dtoolkit in the physics update
« Reply #2 on: January 06, 2014, 03:41:01 pm »
Right yeah, so that's all I'd need, interesting.  Thanks!

And you do have some experience with determinism in Unity? good or bad? Care to share some thoughts on it? :)

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Update 2dtoolkit in the physics update
« Reply #3 on: January 07, 2014, 11:09:42 am »
If you want 100% determinism in Unity, I've learnt to just DIY. Have one behaviour update and call the appropriate functions on all the relevant other behaviours manually.

Evil-Dog

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 38
    • View Profile
Re: Update 2dtoolkit in the physics update
« Reply #4 on: January 07, 2014, 02:55:58 pm »
That makes sense, thanks