Search Unity

particle emission trails different depending on framerate?

Discussion in 'Scripting' started by Mike01923, May 13, 2020.

  1. Mike01923

    Mike01923

    Joined:
    Jun 19, 2015
    Posts:
    195
    I just noticed that all my particles aren't emitting as much since I set my targetFrameRate to 30 and look very different at 30 compared to 60, especially the trails. All my particles are purely decorative and usually I have them emitting based on distance.

    How do you create particle trail effects where the effect looks the same at 30fps and 200fps?
     
  2. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,742
    The only way I can imagine there being a difference is at very low rates of emission.

    For instance, lets say in a 30th of a second you WOULD have emitted 3 particles.

    But in 60th of a second that comes out to 1.5 particles. Well that rounds down to 1.0 particles.

    Next frame I am going to guess the particle system does not "carry over" that 0.5 particle and give you 2 particles, but I could be wrong.

    The above would apply to either rate-over-distance or rate-over-time.
     
    Joe-Censored likes this.
  3. PraetorBlue

    PraetorBlue

    Joined:
    Dec 13, 2012
    Posts:
    7,909
    Hmm really? That's kind of disappointing if they don't carry over the remainder. I'll put it in the "test this out later" list...
     
  4. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,742
    I imagine it would only be noticeable if your emission rate divided by your frame rate resulted in very small number.
     
  5. florinel2102

    florinel2102

    Joined:
    May 21, 2019
    Posts:
    76
    Same problem , I resolved by using particleSystem.emission.enabled = true instead of particleSystem.Play() , I don't know exactly why .