Search Unity

[RELEASED] Fluid Dynamics : 2D GPU Particle System Fluid Simulation.

Discussion in 'Assets and Asset Store' started by seedounity, Jan 18, 2019.

  1. seedounity

    seedounity

    Joined:
    Jan 18, 2019
    Posts:
    6
    image.png
    Fluid Dynamics is a 2D GPU Particle System Fluid Simulation for Unity. Fire, smoke or any other fluid in your game in realtime using GPU.

    Fluid Dynamics uses Compute Shaders and PC, Linux, Android compatible, but please make additional check here

    itch.io - https://seedo.itch.io/fluid-dynamics
    Asset Store - https://assetstore.unity.com/packages/slug/137435



    Features:

    PC and mobile friendly
    Full source code included
    Vorticity control
    Viscosity control
    Multiple simulation spaces support
    Full control of physical based simulation
    Fluid flow followers support included
    Multiple Emitteres
    PC and mobile controls support (included)

    Four example scenes and online documentation included.
     
    Last edited: Feb 11, 2019
    Lars-Steenhoff and Mark_01 like this.
  2. seedounity

    seedounity

    Joined:
    Jan 18, 2019
    Posts:
    6
    SugoiDev likes this.
  3. qqqbbb

    qqqbbb

    Joined:
    Jan 13, 2016
    Posts:
    113
    There is no demo on itch.io page.
     
  4. seedounity

    seedounity

    Joined:
    Jan 18, 2019
    Posts:
    6
    Sorry about that. Demo projects now added.
     
  5. sbtp

    sbtp

    Joined:
    Jul 26, 2013
    Posts:
    7
    Just bought and imported the asset today. You might want to include some project setup instructions other than the prefab/component usage. I can imagine this will be the first issue faced by most users: https://answers.unity.com/questions/1373447/systeminfosupportscomputeshaders-always-false-on-a.html

    I'm also getting a bunch of other errors here from the example scene (From the asset store btw):

    Kernel 'AddVelocity' not found
    UnityEngine.ComputeShader:FindKernel()
    FluidDynamics.Main_Fluid_Simulation:Start() (at Assets/FluidDynamics/Scripts/Main_Fluid_Simulation.cs:147)



    Kernel index (0) out of range
    UnityEngine.ComputeShader:SetBuffer(Int32, String, ComputeBuffer)
    FluidDynamics.Main_Fluid_Simulation:Update() (at Assets/FluidDynamics/Scripts/Main_Fluid_Simulation.cs:176)



    Kernel index (0) out of range
    UnityEngine.ComputeShader:Dispatch()
    FluidDynamics.Main_Fluid_Simulation:Update() (at Assets/FluidDynamics/Scripts/Main_Fluid_Simulation.cs:177)


    The last two goes on for a bit. Is there a setup process I'm missing?
     
  6. sbtp

    sbtp

    Joined:
    Jul 26, 2013
    Posts:
    7
    One more thing. This one is maybe a nitpick, but your readme file mentioned to add a "Main_Fluid_Simulation" component. I usually search for my components after clicking Add Component on a GameObject. It confused me to see that it wasn't there. I looked at your code and realised that you named it differently in the dropdown menu. Would've been more intuitive to have the same name?

    Screenshot 2019-02-08 at 9.03.47 PM.png
     
  7. seedounity

    seedounity

    Joined:
    Jan 18, 2019
    Posts:
    6
    Thank you for your observation.
    New online documentation


    Seems like there is no unity support for Metal2 on Mac.
    Also in online docs added instruction for Android target platform in Windows Unity Editor.
     
  8. seedounity

    seedounity

    Joined:
    Jan 18, 2019
    Posts:
    6
    Pixel Art fire example
     
  9. summerian

    summerian

    Joined:
    Jul 6, 2014
    Posts:
    140
    Looks great! Is it possible to implement colliders?
     
    seedounity likes this.
  10. seedounity

    seedounity

    Joined:
    Jan 18, 2019
    Posts:
    6
    Yep, Fluid Dynamics already supports polygon colliders.
     
    summerian likes this.
  11. dongfangliu

    dongfangliu

    Joined:
    Mar 6, 2017
    Posts:
    45
    good and ncie
     
  12. SleepyAgapornis

    SleepyAgapornis

    Joined:
    Sep 7, 2018
    Posts:
    23
    does this work on Unity WebGL?
     
  13. Ttravi

    Ttravi

    Joined:
    Jan 22, 2018
    Posts:
    32
    It is possible to project those fluids on a 3D surface?
     
  14. stanislavdol

    stanislavdol

    Joined:
    Aug 3, 2013
    Posts:
    282
  15. Vic070

    Vic070

    Joined:
    Aug 6, 2016
    Posts:
    9
    Will this asset work in webGL?
     
  16. xiao-xxl

    xiao-xxl

    Joined:
    Nov 16, 2018
    Posts:
    48
    Do you have mobile demo?
     
  17. marcjamerocom

    marcjamerocom

    Joined:
    Nov 9, 2018
    Posts:
    2
    Is it possible to change the fluid color without affecting the existing fluid on the plane. For example: I inject Red fluid, then inject Green fluid afterward. Is it possible to retain the Red fluid but still interact with the new Green fluid? I have tried changing the color of FluidSimulation (Update Gradient Checked), but the existing Red fluid got changed to Green as well.
     
  18. marcjamerocom

    marcjamerocom

    Joined:
    Nov 9, 2018
    Posts:
    2
    By the way, does this work on mobile? I tried to build the ExampleScene to iOS. I doesn't work. There's an error in Xcode:

    Execution of the command buffer was aborted due to an error during execution. Caused GPU Hang Error (IOAF code 3)
     
  19. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    anyone got it going on webgl? i dont think it works.
     
  20. radiantboy

    radiantboy

    Joined:
    Nov 21, 2012
    Posts:
    1,633
    can anyone tell me why you cannot change viscosity, particle life or dissapation via code, its weird! I set them but they do not change.