Search Unity

PlayableDirector.Play (PlayableAsset) method Caton

Discussion in 'Timeline' started by cz_kevin, Jan 10, 2018.

  1. cz_kevin

    cz_kevin

    Joined:
    Jan 10, 2018
    Posts:
    2
    I call PlayableDirector.Play (PlayableAsset) method in the game, it takes 2 seconds for android to finish executing, but the windows pc is normal, which is why?
     
  2. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    1,516
    The answer depends on the timeline (or other playable asset) you are playing. Hitting play causes the playable director to create an instance of the timeline, which does have a cost. You can mitigate that using RebuildGraph to cause the allocation earlier (e.g. on scene load). That being said, 2 seconds seems very excessive.
     
  3. cz_kevin

    cz_kevin

    Joined:
    Jan 10, 2018
    Posts:
    2
    Thank you for your answer, I have solved this problem, the android compiler way to use IL2CPP instead of mono jit compiled on it ....
     
    seant_unity likes this.