├── .gitignore ├── Assets ├── Fluid.meta ├── Fluid │ ├── CPU Version.meta │ ├── CPU Version │ │ ├── CPUFluid.cs │ │ └── CPUFluid.cs.meta │ ├── Fluid.compute │ ├── Fluid.compute.meta │ ├── Fluid.cs │ └── Fluid.cs.meta ├── FluidMaterial.mat ├── FluidMaterial.mat.meta ├── Scene.meta └── Scene │ ├── PostProcessing Profile.asset │ ├── PostProcessing Profile.asset.meta │ ├── Scene.unity │ └── Scene.unity.meta ├── LICENSE ├── Logs └── Packages-Update.log ├── Packages └── manifest.json ├── ProjectSettings ├── AudioManager.asset ├── ClusterInputManager.asset ├── DynamicsManager.asset ├── EditorBuildSettings.asset ├── EditorSettings.asset ├── GraphicsSettings.asset ├── InputManager.asset ├── NavMeshAreas.asset ├── Physics2DSettings.asset ├── PresetManager.asset ├── ProjectSettings.asset ├── ProjectVersion.txt ├── QualitySettings.asset ├── TagManager.asset ├── TimeManager.asset ├── UnityConnectSettings.asset └── VFXManager.asset ├── README.md └── img └── naG9ADa.jpg /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | 3 | [Ll]ibrary/ 4 | [Tt]emp/ 5 | [Oo]bj/ 6 | [Bb]uild/ 7 | [Bb]uilds/ 8 | Assets/AssetStoreTools* 9 | 10 | # Visual Studio cache directory 11 | .vs/ 12 | 13 | # Autogenerated VS/MD/Consulo solution and project files 14 | ExportedObj/ 15 | .consulo/ 16 | *.csproj 17 | *.unityproj 18 | *.sln 19 | *.suo 20 | *.tmp 21 | *.user 22 | *.userprefs 23 | *.pidb 24 | *.booproj 25 | *.svd 26 | *.pdb 27 | *.opendb 28 | 29 | # Unity3D generated meta files 30 | *.pidb.meta 31 | *.pdb.meta 32 | 33 | # Unity3D Generated File On Crash Reports 34 | sysinfo.txt 35 | 36 | # Builds 37 | *.apk 38 | *.unitypackage 39 | -------------------------------------------------------------------------------- /Assets/Fluid.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2f69e08663f9a7b4081644c39504b597 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Fluid/CPU Version.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7d06e25df8b383a41a84bffc2234c4f7 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Fluid/CPU Version/CPUFluid.cs: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright © Daniel Shervheim, 2019 3 | // danielshervheim@gmail.com 4 | // danielshervheim.com 5 | // 6 | 7 | using System.Collections; 8 | using System.Collections.Generic; 9 | using UnityEngine; 10 | 11 | public class CPUFluid : MonoBehaviour { 12 | 13 | [Header("Required")] 14 | public Material material; 15 | 16 | [Header("Simulation Parameters")] 17 | public int n = 64; 18 | public float diff = 0f; 19 | public float visc = 0f; 20 | public float force = 75f; 21 | public float source = 100f; 22 | 23 | // Texture to visualize the density field. 24 | Texture2D texture; 25 | 26 | // Arrays to hold the field values. 27 | int size; 28 | float[] u, u_prev, v, v_prev, dens, dens_prev; 29 | 30 | // Mouse movement variables. 31 | Vector3 mousePos, mouseDelta; 32 | 33 | 34 | 35 | void Start () { 36 | size = (n+2)*(n+2); 37 | 38 | // Create the empty arrays. 39 | u = new float[size]; 40 | u_prev = new float[size]; 41 | 42 | v = new float[size]; 43 | v_prev = new float[size]; 44 | 45 | dens = new float[size]; 46 | dens_prev = new float[size]; 47 | 48 | // Spawn a plane to render the field(s) onto. 49 | GameObject plane = GameObject.CreatePrimitive(PrimitiveType.Plane); 50 | plane.transform.parent = this.transform; 51 | plane.transform.localPosition = Vector3.zero; 52 | plane.transform.localRotation = Quaternion.Euler(0f, 180f, 0f); 53 | plane.transform.localScale = Vector3.one * 0.1f; 54 | plane.GetComponent().material = material; 55 | 56 | // Adjust the camera to be over the plane. 57 | Camera.main.transform.parent = this.transform; 58 | Camera.main.transform.localPosition = Vector3.up * 5f; 59 | Camera.main.transform.localRotation = Quaternion.Euler(90f, 0f, 0f); 60 | Camera.main.transform.localScale = Vector3.one; 61 | Camera.main.orthographic = true; 62 | Camera.main.orthographicSize = 0.5f; 63 | 64 | // Create a texture to display the density field and assign it to the material. 65 | texture = new Texture2D(n+2, n+2, TextureFormat.RGBAHalf, false); 66 | material.SetTexture("_MainTex", texture); 67 | } 68 | 69 | 70 | 71 | void Update () { 72 | // Update the mouse variables. 73 | mouseDelta = GetMousePos() - mousePos; 74 | mousePos = GetMousePos(); 75 | 76 | // Clear the fields if the middle mouse button is pressed. 77 | if (Input.GetMouseButtonDown(2)) { 78 | ClearFields(); 79 | } 80 | 81 | // Advance simulation. 82 | GetFromUI(ref dens_prev, ref u_prev, ref v_prev); 83 | VelocityStep(n, ref u, ref v, ref u_prev, ref v_prev, visc, Time.deltaTime); 84 | DensityStep(n, ref dens, ref dens_prev, ref u, ref v, diff, Time.deltaTime); 85 | 86 | // Upload the density as colors to the texture. 87 | DrawDensity(); 88 | } 89 | 90 | 91 | 92 | void Swap(ref float[] a, ref float[] b) { 93 | var tmp = a; 94 | a = b; 95 | b = tmp; 96 | } 97 | 98 | 99 | 100 | void AddSource(int n, ref float[] x, ref float[] s, float dt) { 101 | for (int i = 0; i < size; i++) { 102 | x[i] += dt*s[i]; 103 | } 104 | } 105 | 106 | 107 | 108 | void Diffuse(int n, int b, ref float[] x, ref float[] x0, float diff, float dt) { 109 | float a = dt * diff * n * n; 110 | LinearSolve(n, b, ref x, ref x0, a, 1f+4f*a); 111 | } 112 | 113 | 114 | 115 | void SetBoundary(int n, int b, ref float[] x) { 116 | /* 117 | int i; 118 | 119 | for (i = 1; i <= n; i++) { 120 | x[To1D(0, i)] = b==1 ? -x[To1D(1, i)] : x[To1D(1, i)]; 121 | x[To1D(n+1, i)] = b==1 ? -x[To1D(n, i)] : x[To1D(n, i)]; 122 | x[To1D(i, 0)] = b==2 ? -x[To1D(i, 1)] : x[To1D(i, 1)]; 123 | x[To1D(i, n+1)] = b==2 ? -x[To1D(i, n)] : x[To1D(i, n)]; 124 | } 125 | 126 | x[To1D(0, 0)] = 0.5f * (x[To1D(1, 0)] + x[To1D(0, 1)]); 127 | x[To1D(0, n+1)] = 0.5f * (x[To1D(1, n+1)] + x[To1D(0, n)]); 128 | x[To1D(n+1, 0)] = 0.5f * (x[To1D(n, 0)] + x[To1D(n+1, 1)]); 129 | x[To1D(n+1, n+1)] = 0.5f * (x[To1D(n, n+1)] + x[To1D(n+1, n)]); 130 | */ 131 | } 132 | 133 | 134 | 135 | void LinearSolve(int n, int b, ref float[] x, ref float[] x0, float a, float c) { 136 | 137 | int i, j, k; 138 | 139 | for (k = 0; k < 20; k++) { 140 | for (i = 1; i <= n; i++) { 141 | for (j = 1; j <= n; j++) { 142 | x[To1D(i,j)] = (x0[To1D(i,j)] + a*(x[To1D(i-1,j)]+x[To1D(i+1,j)]+x[To1D(i,j-1)]+x[To1D(i,j+1)]))/c; 143 | } 144 | } 145 | SetBoundary(n, b, ref x); 146 | } 147 | } 148 | 149 | 150 | 151 | void Project(int n, ref float[] u, ref float[] v, ref float[] p, ref float[] div) { 152 | int i, j; 153 | 154 | for (i = 1; i <= n; i++) { 155 | for (j = 1; j <= n; j++) { 156 | div[To1D(i, j)] = -0.5f*(u[To1D(i+1,j)]-u[To1D(i-1,j)]+v[To1D(i,j+1)]-v[To1D(i,j-1)])/n; 157 | p[To1D(i, j)] = 0.0f; 158 | } 159 | } 160 | 161 | SetBoundary(n, 0, ref div); 162 | SetBoundary(n, 0, ref p); 163 | 164 | LinearSolve(n, 0, ref p, ref div, 1, 4); 165 | 166 | for (i = 1; i <= n; i++) { 167 | for (j = 1; j <= n; j++) { 168 | u[To1D(i,j)] -= 0.5f * n * (p[To1D(i+1,j)] - p[To1D(i-1,j)]); 169 | v[To1D(i,j)] -= 0.5f * n * (p[To1D(i,j+1)] - p[To1D(i,j-1)]); 170 | } 171 | } 172 | 173 | SetBoundary(n, 1, ref u); 174 | SetBoundary(n, 2, ref v); 175 | } 176 | 177 | 178 | 179 | void Advect (int n, int b, ref float[] d, ref float[] d0, ref float[] u, ref float[] v, float dt) { 180 | int i, j, i0, j0, i1, j1; 181 | float x, y, s0, t0, s1, t1, dt0; 182 | 183 | dt0 = dt * n; 184 | 185 | for (i = 1; i <= n; i++) { 186 | for (j = 1; j <= n; j++) { 187 | x = i - dt0*u[To1D(i,j)]; 188 | y = j - dt0*v[To1D(i,j)]; 189 | 190 | if (x < 0.5f) x = 0.5f; 191 | if (x > n+0.5f) x = n+0.5f; 192 | i0 = (int)x; 193 | i1 = i0 + 1; 194 | 195 | if (y < 0.5f) y = 0.5f; 196 | if (y > n+0.5f) y = n + 0.5f; 197 | j0 = (int)y; 198 | j1 = j0 + 1; 199 | 200 | s1 = x - i0; 201 | s0 = 1f - s1; 202 | 203 | t1 = y - j0; 204 | t0 = 1f - t1; 205 | 206 | d[To1D(i,j)] = s0*(t0*d0[To1D(i0,j0)] + t1*d0[To1D(i0,j1)]) + 207 | s1*(t0*d0[To1D(i1,j0)] + t1*d0[To1D(i1,j1)]); 208 | } 209 | } 210 | 211 | SetBoundary(n, b, ref d); 212 | } 213 | 214 | 215 | 216 | void VelocityStep(int n, ref float[] u, ref float[] v, ref float[] u0, ref float[] v0, float visc, float dt) { 217 | AddSource(n, ref u, ref u0, dt); 218 | AddSource(n, ref v, ref v0, dt); 219 | 220 | Swap(ref u0, ref u); 221 | Diffuse(n, 1, ref u, ref u0, visc, dt); 222 | 223 | Swap(ref v0, ref v); 224 | Diffuse(n, 2, ref v, ref v0, visc, dt); 225 | 226 | Project(n, ref u, ref v, ref u0, ref v0); 227 | 228 | Swap(ref u0, ref u); 229 | Swap(ref v0, ref v); 230 | 231 | Advect(n, 1, ref u, ref u0, ref u0, ref v0, dt); 232 | Advect(n, 2, ref v, ref v0, ref u0, ref v0, dt); 233 | 234 | Project(n, ref u, ref v, ref u0, ref v0); 235 | } 236 | 237 | 238 | 239 | void DensityStep(int n, ref float[] x, ref float[] x0, ref float[] u, ref float[] v, float diff, float dt) { 240 | AddSource(n, ref x, ref x0, dt); 241 | Swap(ref x0, ref x); 242 | Diffuse(n, 0, ref x, ref x0, diff, dt); 243 | Swap(ref x0, ref x); 244 | Advect(n, 0, ref x, ref x0, ref u, ref v, dt); 245 | } 246 | 247 | 248 | 249 | void GetFromUI(ref float[] d, ref float[] u, ref float[] v) { 250 | for (int i = 0; i < size; i++) { 251 | d[i] = u[i] = v[i] = 0f; 252 | } 253 | 254 | if (!Input.GetMouseButton(0) && !Input.GetMouseButton(1)) { 255 | return; 256 | } 257 | 258 | int x = GetIdFromPosition(mousePos).x; 259 | int y = GetIdFromPosition(mousePos).y; 260 | 261 | if (x < 1 || x > n || y < 1 || y > n) { 262 | return; 263 | } 264 | 265 | if (Input.GetMouseButton(0)) { 266 | u[To1D(x, y)] = force * mouseDelta.x * (n+2); // scale by resolution. 267 | v[To1D(x, y)] = force * mouseDelta.z * (n+2); // scale by resolution. 268 | } 269 | 270 | if (Input.GetMouseButton(1)) { 271 | d[To1D(x, y)] = source; 272 | } 273 | } 274 | 275 | 276 | 277 | void ClearFields() { 278 | u = new float[size]; 279 | v = new float[size]; 280 | dens = new float[size]; 281 | } 282 | 283 | 284 | 285 | void DrawDensity() { 286 | Color[] tmp = texture.GetPixels(0); 287 | 288 | for (int i = 0; i < tmp.Length; i++) { 289 | tmp[i] = new Color(dens[i], dens[i], dens[i], 1f); 290 | } 291 | 292 | texture.SetPixels(tmp, 0); 293 | texture.Apply(); 294 | } 295 | 296 | 297 | 298 | Vector2Int To2D(int i) { 299 | return new Vector2Int(i%(n+2), i/(n+2)); 300 | } 301 | 302 | 303 | 304 | int To1D(int i, int j) { 305 | return i + j*(n+2); 306 | } 307 | 308 | 309 | 310 | /* Returns the mouse position in simulation space. */ 311 | Vector3 GetMousePos() { 312 | Vector3 p = Camera.main.ScreenToWorldPoint(Input.mousePosition); 313 | return new Vector3(p.x, 0f, p.z); 314 | } 315 | 316 | 317 | 318 | /* Returns the ID of the cell nearest to the input position. */ 319 | Vector2Int GetIdFromPosition(Vector3 p) { 320 | p += 0.5f * Vector3.one; 321 | p *= (n+2); 322 | return new Vector2Int((int)p.x, (int)p.z); 323 | } 324 | } 325 | -------------------------------------------------------------------------------- /Assets/Fluid/CPU Version/CPUFluid.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 22213be4a7fda2441a44993263467262 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Fluid/Fluid.compute: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright © Daniel Shervheim, 2019 3 | // danielshervheim@gmail.com 4 | // danielshervheim.com 5 | // 6 | 7 | 8 | 9 | // 10 | // GLOBAL VARIABLES 11 | // 12 | 13 | uint n, n2, len; 14 | float dt, diff, visc; 15 | 16 | 17 | 18 | // 19 | // UTILITIES 20 | // 21 | 22 | // Converts a 2d index to a 1d index. 23 | uint To1D(uint x, uint y) { 24 | return y*n2 + x; 25 | } 26 | 27 | // Converts a 2d index to a 1d index. 28 | uint To1D(uint2 id) { 29 | return To1D(id.x, id.y); 30 | } 31 | 32 | // Converts a 1d index to a 2d index. 33 | uint2 To2D(uint id) { 34 | return uint2(id%n2, id/n2); 35 | } 36 | 37 | // Returns whether the given index is within the inner rectangle. 38 | bool IsInBounds(uint id) { 39 | uint2 id2 = To2D(id); 40 | return id2.x >= 1 && id2.y >= 1 && id2.x <= n && id2.y <= n; 41 | } 42 | 43 | // Returns the id of the cell to the left of the input cell. 44 | uint Left(uint id) { 45 | uint2 id2 = To2D(id); 46 | id2 -= uint2(1, 0); 47 | id2.x = max(id2.x, 0); 48 | return To1D(id2); 49 | } 50 | 51 | // Returns the id of the cell to the right of the input cell. 52 | uint Right(uint id) { 53 | uint2 id2 = To2D(id); 54 | id2 += uint2(1, 0); 55 | id2.x = min(id2.x, n2-1); 56 | return To1D(id2); 57 | } 58 | 59 | // Returns the id of the cell beneath the input cell. 60 | uint Bottom(uint id) { 61 | uint2 id2 = To2D(id); 62 | id2 -= uint2(0, 1); 63 | id2.y = max(id2.y, 0); 64 | return To1D(id2); 65 | } 66 | 67 | // Returns the id of the cell above the input cell. 68 | uint Top(uint id) { 69 | uint2 id2 = To2D(id); 70 | id2 += uint2(0, 1); 71 | id2.y = min(id2.y, n2-1); 72 | return To1D(id2); 73 | } 74 | 75 | 76 | 77 | // 78 | // KERNELS 79 | // 80 | 81 | #pragma kernel AddSource 82 | 83 | RWStructuredBuffer as_x; 84 | StructuredBuffer as_s; 85 | 86 | [numthreads(256, 1, 1)] 87 | void AddSource(uint id : SV_DispatchThreadID) { 88 | as_x[id] += dt*as_s[id]; 89 | } 90 | 91 | 92 | 93 | #pragma kernel LinearSolve 94 | 95 | RWStructuredBuffer ls_x; 96 | StructuredBuffer ls_x0; 97 | float ls_a, ls_c; 98 | 99 | [numthreads(256, 1, 1)] 100 | void LinearSolve(uint id : SV_DispatchThreadID) { 101 | if (!IsInBounds(id)) return; 102 | 103 | ls_x[id] = ( 104 | ls_x0[id] + ls_a * ( 105 | ls_x[Left(id)] + 106 | ls_x[Right(id)] + 107 | ls_x[Bottom(id)] + 108 | ls_x[Top(id)] 109 | ) 110 | ) / ls_c; 111 | } 112 | 113 | 114 | 115 | #pragma kernel Advect 116 | 117 | RWStructuredBuffer ad_d; 118 | StructuredBuffer ad_d0, ad_u, ad_v; 119 | 120 | [numthreads(256, 1, 1)] 121 | void Advect(uint id : SV_DispatchThreadID) { 122 | if (!IsInBounds(id)) return; 123 | 124 | float dt0 = dt * n; 125 | 126 | uint i = To2D(id).x; 127 | float x = i - dt0 * ad_u[id]; 128 | if (x < 0.5) x = 0.5; 129 | if (x > n+0.5) x = n+0.5; 130 | uint i0 = (uint)x; 131 | uint i1 = i0+1; 132 | float s1 = x-i0; 133 | float s0 = 1.0 - s1; 134 | 135 | uint j = To2D(id).y; 136 | float y = j - dt0 * ad_v[id]; 137 | if (y < 0.5) y = 0.5; 138 | if (y > n+0.5) y = n+0.5; 139 | uint j0 = (uint)y; 140 | uint j1 = j0+1; 141 | float t1 = y - j0; 142 | float t0 = 1.0 - t1; 143 | 144 | ad_d[id] = s0 * ( 145 | t0 * ad_d0[To1D(i0, j0)] + 146 | t1 * ad_d0[To1D(i0, j1)] 147 | ) + s1 * ( 148 | t0 * ad_d0[To1D(i1, j0)] + 149 | t1 * ad_d0[To1D(i1, j1)] 150 | ); 151 | } 152 | 153 | 154 | 155 | #pragma kernel ProjectStart 156 | 157 | RWStructuredBuffer ps_p, ps_div; 158 | StructuredBuffer ps_u, ps_v; 159 | 160 | [numthreads(256, 1, 1)] 161 | void ProjectStart(uint id : SV_DispatchThreadID) { 162 | if (!IsInBounds(id)) return; 163 | 164 | ps_div[id] = -0.5 * ( 165 | ps_u[Right(id)] - 166 | ps_u[Left(id)] + 167 | ps_v[Top(id)] - 168 | ps_v[Bottom(id)] 169 | ) / (float)n; 170 | 171 | ps_p[id] = 0.0; 172 | } 173 | 174 | 175 | 176 | #pragma kernel ProjectFinish 177 | 178 | RWStructuredBuffer pf_u, pf_v; 179 | StructuredBuffer pf_p; 180 | 181 | [numthreads(256, 1, 1)] 182 | void ProjectFinish(uint id : SV_DispatchThreadID) { 183 | if (!IsInBounds(id)) return; 184 | 185 | pf_u[id] -= 0.5 * n * (pf_p[Right(id)] - pf_p[Left(id)]); 186 | pf_v[id] -= 0.5 * n * (pf_p[Top(id)] - pf_p[Bottom(id)]); 187 | } 188 | 189 | 190 | 191 | #pragma kernel BufferToTexture 192 | 193 | RWTexture2D b2t_texture; 194 | StructuredBuffer b2t_u, b2t_v, b2t_d; 195 | 196 | [numthreads(32, 32, 1)] 197 | void BufferToTexture(uint2 id : SV_DispatchThreadID) { 198 | if (!IsInBounds(To1D(id))) return; 199 | 200 | uint index = To1D(id); 201 | float u = b2t_u[index]; 202 | float v = b2t_v[index]; 203 | float d = b2t_d[index]; 204 | b2t_texture[id] = float4(d, d, d, 1.0); 205 | } 206 | 207 | 208 | 209 | #pragma kernel ClearBuffer 210 | 211 | RWStructuredBuffer cb_buffer; 212 | 213 | [numthreads(256, 1, 1)] 214 | void ClearBuffer(uint id : SV_DispatchThreadID) { 215 | cb_buffer[id] = 0.0; 216 | } 217 | -------------------------------------------------------------------------------- /Assets/Fluid/Fluid.compute.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1abef17a3385d1d40a6f42ad2fccfa0d 3 | ComputeShaderImporter: 4 | externalObjects: {} 5 | currentAPIMask: 4 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Fluid/Fluid.cs: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright © Daniel Shervheim, 2019 3 | // danielshervheim@gmail.com 4 | // danielshervheim.com 5 | // 6 | 7 | using UnityEngine; 8 | 9 | public class Fluid : MonoBehaviour { 10 | [Header("Required Assets")] 11 | public ComputeShader compute; 12 | public Material material; 13 | 14 | [Header("Preset Parameters")] 15 | public int n; 16 | int n2, len; 17 | 18 | [Header("Realtime Parameters")] 19 | public float diff = 0f; 20 | public float visc = 0f; 21 | public float force = 75f; 22 | public float source = 100f; 23 | 24 | // Kernels. 25 | int[] kernels; 26 | int addSource = 0; 27 | int linearSolve = 1; 28 | int advect = 2; 29 | int projectStart = 3; 30 | int projectFinish = 4; 31 | int bufferToTexture = 5; 32 | int clearBuffer = 6; 33 | 34 | // Buffers. 35 | ComputeBuffer[] buffers; 36 | int u = 0; 37 | int u0 = 1; 38 | int v = 2; 39 | int v0 = 3; 40 | int d = 4; 41 | int d0 = 5; 42 | 43 | // Texture. 44 | RenderTexture texture; 45 | 46 | // Mouse movement variables. 47 | Vector3 mousePos, mouseDelta; 48 | 49 | void Start() { 50 | // Calculate the global variables. 51 | n2 = n + 2; 52 | len = (int)Mathf.Pow(n2, 2f); 53 | 54 | // Set the global compute variables. 55 | compute.SetInt("n", n); 56 | compute.SetInt("n2", n2); 57 | compute.SetInt("len", len); 58 | 59 | // Find and assign the kernels. 60 | kernels = new int[7]; 61 | kernels[addSource] = compute.FindKernel("AddSource"); 62 | kernels[linearSolve] = compute.FindKernel("LinearSolve"); 63 | kernels[advect] = compute.FindKernel("Advect"); 64 | kernels[projectStart] = compute.FindKernel("ProjectStart"); 65 | kernels[projectFinish] = compute.FindKernel("ProjectFinish"); 66 | kernels[bufferToTexture] = compute.FindKernel("BufferToTexture"); 67 | kernels[clearBuffer] = compute.FindKernel("ClearBuffer"); 68 | 69 | // Create and empty the buffers. 70 | buffers = new ComputeBuffer[6]; 71 | for (int b = 0; b < buffers.Length; b++) { 72 | buffers[b] = new ComputeBuffer(len, 4); 73 | ClearBuffer(b); 74 | } 75 | 76 | // Create the texture, and assign it to the material. 77 | texture = new RenderTexture(n2, n2, 0, RenderTextureFormat.ARGBHalf, RenderTextureReadWrite.Linear); 78 | texture.enableRandomWrite = true; 79 | texture.Create(); 80 | material.SetTexture("_MainTex", texture); 81 | 82 | // Upload the texture and buffers to the gpu for rendering each frame. 83 | // Note: this is set only once in the Start() method because we will only ever 84 | // render these buffers in the bufferToTexture kernel. 85 | compute.SetTexture(kernels[bufferToTexture], "b2t_texture", texture); 86 | compute.SetBuffer(kernels[bufferToTexture], "b2t_u", buffers[u]); 87 | compute.SetBuffer(kernels[bufferToTexture], "b2t_v", buffers[v]); 88 | compute.SetBuffer(kernels[bufferToTexture], "b2t_d", buffers[d]); 89 | 90 | // Create a plane to render the display texture onto, and set its material. 91 | GameObject plane = GameObject.CreatePrimitive(PrimitiveType.Plane); 92 | plane.transform.parent = this.transform; 93 | plane.transform.localPosition = Vector3.zero; 94 | plane.transform.localRotation = Quaternion.Euler(0f, 180f, 0f); 95 | plane.transform.localScale = Vector3.one * 0.1f; 96 | plane.GetComponent().material = material; 97 | 98 | // Adjust the camera to be centered over the plane. 99 | Camera.main.transform.parent = this.transform; 100 | Camera.main.transform.localPosition = Vector3.up * 5f; 101 | Camera.main.transform.localRotation = Quaternion.Euler(90f, 0f, 0f); 102 | Camera.main.transform.localScale = Vector3.one; 103 | Camera.main.orthographic = true; 104 | Camera.main.orthographicSize = 0.5f; 105 | } 106 | 107 | void Update() { 108 | // Set the delta time on the GPU. 109 | compute.SetFloat("dt", Time.deltaTime); 110 | compute.SetFloat("diff", diff); 111 | compute.SetFloat("visc", visc); 112 | 113 | // Update the mouse variables. 114 | mouseDelta = GetMousePosition() - mousePos; 115 | mousePos = GetMousePosition(); 116 | 117 | // Reset the simulation if the middle mouse button is pressed. 118 | if (Input.GetMouseButtonDown(2)) { 119 | ClearBuffer(u); 120 | ClearBuffer(v); 121 | ClearBuffer(d); 122 | } 123 | 124 | // Get the forces from the mouse, and store them in the temporary buffers. 125 | GetFromUI(d0, u0, v0); 126 | 127 | VelocityStep(u, v, u0, v0); 128 | 129 | DensityStep(d, d0, u, v); 130 | 131 | // Copy the buffers over to the texture to display them. 132 | compute.Dispatch(kernels[bufferToTexture], n2/32 + 1, n2/32 + 1, 1); 133 | } 134 | 135 | void OnDestroy() { 136 | for (int i = 0; i < buffers.Length; i++) { 137 | if (buffers[i] != null) { 138 | buffers[i].Release(); 139 | } 140 | } 141 | 142 | if (texture != null) { 143 | texture.Release(); 144 | } 145 | } 146 | 147 | 148 | 149 | // 150 | // SOLVER STEPS 151 | // 152 | 153 | // Get the forces from the mouse and update the fields. 154 | void GetFromUI(int d, int u, int v) { 155 | // Clear the buffers. 156 | ClearBuffer(d); 157 | ClearBuffer(u); 158 | ClearBuffer(v); 159 | 160 | // Get the buffer index based on the mouse position. 161 | int index = GetIndexFromMousePosition(); 162 | 163 | int x = index%n2; 164 | int y = index/n2; 165 | 166 | if (!(x >= 1 && x <= n && y >= 1 && y <= n)) return; 167 | 168 | // Add a force to the velocity field based on left click + drag. 169 | if (Input.GetMouseButton(0)) { 170 | float[] tu = new float[len]; 171 | tu[index] = force * mouseDelta.x * n2; 172 | buffers[u].SetData(tu, index, index, 1); 173 | 174 | float[] tv = new float[len]; 175 | tv[index] = force * mouseDelta.z * n2; 176 | buffers[v].SetData(tv, index, index, 1); 177 | } 178 | 179 | // Add more density to the density field based on right click. 180 | if (Input.GetMouseButton(1)) { 181 | float[] td = new float[len]; 182 | td[index] = source; 183 | buffers[d].SetData(td, index, index, 1); 184 | } 185 | } 186 | 187 | // Update the velocity field to its next state. 188 | void VelocityStep(int u, int v, int u0, int v0) { 189 | AddSource(u, u0); 190 | AddSource(v, v0); 191 | 192 | Swap(ref u, ref u0); 193 | Diffuse(u, u0); 194 | 195 | Swap(ref v, ref v0); 196 | Diffuse(v, v0); 197 | 198 | Project(u, v, u0, v0); 199 | 200 | Swap(ref u0, ref u); 201 | Swap(ref v0, ref v); 202 | 203 | Advect(u, u0, u0, v0); 204 | Advect(v, v0, u0, v0); 205 | 206 | Project(u, v, u0, v0); 207 | } 208 | 209 | // Update the density field to its next state. 210 | void DensityStep(int x, int x0, int u, int v) { 211 | AddSource(x, x0); 212 | 213 | Swap(ref x, ref x0); 214 | Diffuse(x, x0); 215 | 216 | Swap(ref x, ref x0); 217 | Advect(x, x0, u, v); 218 | } 219 | 220 | 221 | 222 | // 223 | // SOLVER METHODS 224 | // 225 | 226 | void AddSource(int x, int s) { 227 | compute.SetBuffer(kernels[addSource], "as_x", buffers[x]); 228 | compute.SetBuffer(kernels[addSource], "as_s", buffers[s]); 229 | compute.Dispatch(kernels[addSource], len/256+1, 1, 1); 230 | } 231 | 232 | void Diffuse(int x, int x0) { 233 | float a = Time.deltaTime * diff * Mathf.Pow(n, 2f); 234 | LinearSolve(x, x0, a, 1f + 4f*a); 235 | } 236 | 237 | void Project(int u, int v, int p, int div) { 238 | compute.SetBuffer(kernels[projectStart], "ps_u", buffers[u]); 239 | compute.SetBuffer(kernels[projectStart], "ps_v", buffers[v]); 240 | compute.SetBuffer(kernels[projectStart], "ps_p", buffers[p]); 241 | compute.SetBuffer(kernels[projectStart], "ps_div", buffers[div]); 242 | compute.Dispatch(kernels[projectStart], len/256+1, 1, 1); 243 | 244 | LinearSolve(p, div, 1f, 4f); 245 | 246 | compute.SetBuffer(kernels[projectFinish], "pf_u", buffers[u]); 247 | compute.SetBuffer(kernels[projectFinish], "pf_v", buffers[v]); 248 | compute.SetBuffer(kernels[projectFinish], "pf_p", buffers[p]); 249 | compute.Dispatch(kernels[projectFinish], len/256+1, 1, 1); 250 | } 251 | 252 | void Advect(int d, int d0, int u, int v) { 253 | compute.SetBuffer(kernels[advect], "ad_d", buffers[d]); 254 | compute.SetBuffer(kernels[advect], "ad_d0", buffers[d0]); 255 | compute.SetBuffer(kernels[advect], "ad_u", buffers[u]); 256 | compute.SetBuffer(kernels[advect], "ad_v", buffers[v]); 257 | compute.Dispatch(kernels[advect], len/256+1, 1, 1); 258 | } 259 | 260 | void LinearSolve(int x, int x0, float a, float c) { 261 | compute.SetBuffer(kernels[linearSolve], "ls_x", buffers[x]); 262 | compute.SetBuffer(kernels[linearSolve], "ls_x0", buffers[x0]); 263 | compute.SetFloat("ls_a", a); 264 | compute.SetFloat("ls_c", c); 265 | for (int k = 0; k < 20; k++) { 266 | compute.Dispatch(kernels[linearSolve], len/256 + 1, 1, 1); 267 | } 268 | } 269 | 270 | 271 | 272 | // 273 | // UTILITIES 274 | // 275 | 276 | // Get the mouse position in world space orthographic view, top down (x, z). 277 | Vector3 GetMousePosition() { 278 | Vector3 tmp = Camera.main.ScreenToWorldPoint(Input.mousePosition); 279 | return new Vector3(tmp.x, 0f, tmp.z); 280 | } 281 | 282 | // Returns the index of the grid which the mouse position is currently over. 283 | int GetIndexFromMousePosition() { 284 | Vector3 tmp = mousePos; // -orthoSize:orthoSize 285 | tmp += Camera.main.orthographicSize*new Vector3(1f, 0f, 1f); // 0:1 286 | tmp *= n2; // 0:n2 287 | int x = (int)Mathf.Clamp(Mathf.Floor(tmp.x), 0f, n2-1); 288 | int y = (int)Mathf.Clamp(Mathf.Floor(tmp.z), 0f, n2-1); 289 | return y*n2 + x; 290 | } 291 | 292 | // Swaps two given integers. 293 | void Swap(ref int a, ref int b) { 294 | var tmp = a; 295 | a = b; 296 | b = tmp; 297 | } 298 | 299 | // Clears the given buffer to 0.0. 300 | void ClearBuffer(int x) { 301 | compute.SetBuffer(kernels[clearBuffer], "cb_buffer", buffers[x]); 302 | compute.Dispatch(kernels[clearBuffer], len/256+1, 1, 1); 303 | } 304 | } 305 | -------------------------------------------------------------------------------- /Assets/Fluid/Fluid.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 24d101cfa59b2374580e501e884fee14 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/FluidMaterial.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 6 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: FluidMaterial 11 | m_Shader: {fileID: 10752, guid: 0000000000000000f000000000000000, type: 0} 12 | m_ShaderKeywords: _EMISSION 13 | m_LightmapFlags: 0 14 | m_EnableInstancingVariants: 0 15 | m_DoubleSidedGI: 0 16 | m_CustomRenderQueue: -1 17 | stringTagMap: {} 18 | disabledShaderPasses: [] 19 | m_SavedProperties: 20 | serializedVersion: 3 21 | m_TexEnvs: 22 | - _BumpMap: 23 | m_Texture: {fileID: 0} 24 | m_Scale: {x: 1, y: 1} 25 | m_Offset: {x: 0, y: 0} 26 | - _DetailAlbedoMap: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - _DetailMask: 31 | m_Texture: {fileID: 0} 32 | m_Scale: {x: 1, y: 1} 33 | m_Offset: {x: 0, y: 0} 34 | - _DetailNormalMap: 35 | m_Texture: {fileID: 0} 36 | m_Scale: {x: 1, y: 1} 37 | m_Offset: {x: 0, y: 0} 38 | - _EmissionMap: 39 | m_Texture: {fileID: 0} 40 | m_Scale: {x: 1, y: 1} 41 | m_Offset: {x: 0, y: 0} 42 | - _Illum: 43 | m_Texture: {fileID: 0} 44 | m_Scale: {x: 1, y: 1} 45 | m_Offset: {x: 0, y: 0} 46 | - _MainTex: 47 | m_Texture: {fileID: 0} 48 | m_Scale: {x: 1, y: 1} 49 | m_Offset: {x: 0, y: 0} 50 | - _MetallicGlossMap: 51 | m_Texture: {fileID: 0} 52 | m_Scale: {x: 1, y: 1} 53 | m_Offset: {x: 0, y: 0} 54 | - _OcclusionMap: 55 | m_Texture: {fileID: 0} 56 | m_Scale: {x: 1, y: 1} 57 | m_Offset: {x: 0, y: 0} 58 | - _ParallaxMap: 59 | m_Texture: {fileID: 0} 60 | m_Scale: {x: 1, y: 1} 61 | m_Offset: {x: 0, y: 0} 62 | m_Floats: 63 | - _BumpScale: 1 64 | - _Cutoff: 0.5 65 | - _DetailNormalMapScale: 1 66 | - _DstBlend: 0 67 | - _Emission: 1 68 | - _GlossMapScale: 1 69 | - _Glossiness: 0.5 70 | - _GlossyReflections: 1 71 | - _Metallic: 0 72 | - _Mode: 0 73 | - _OcclusionStrength: 1 74 | - _Parallax: 0.02 75 | - _Shininess: 0.1 76 | - _SmoothnessTextureChannel: 0 77 | - _SpecularHighlights: 1 78 | - _SrcBlend: 1 79 | - _UVSec: 0 80 | - _ZWrite: 1 81 | m_Colors: 82 | - _Color: {r: 1, g: 1, b: 1, a: 1} 83 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 84 | - _SpecColor: {r: 1, g: 1, b: 1, a: 1} 85 | -------------------------------------------------------------------------------- /Assets/FluidMaterial.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 97f62e7b561a09a4cb5ae0530e7bb364 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scene.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3231f08f9ebd508448f47e19ee16153e 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scene/PostProcessing Profile.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_PrefabParentObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_GameObject: {fileID: 0} 9 | m_Enabled: 1 10 | m_EditorHideFlags: 0 11 | m_Script: {fileID: 11500000, guid: 8a3bdb2cd68f901469e7cc149151eb49, type: 3} 12 | m_Name: PostProcessing Profile 13 | m_EditorClassIdentifier: 14 | debugViews: 15 | m_Enabled: 1 16 | m_Settings: 17 | mode: 0 18 | depth: 19 | scale: 1 20 | motionVectors: 21 | sourceOpacity: 1 22 | motionImageOpacity: 0 23 | motionImageAmplitude: 16 24 | motionVectorsOpacity: 1 25 | motionVectorsResolution: 24 26 | motionVectorsAmplitude: 64 27 | fog: 28 | m_Enabled: 1 29 | m_Settings: 30 | excludeSkybox: 1 31 | antialiasing: 32 | m_Enabled: 1 33 | m_Settings: 34 | method: 1 35 | fxaaSettings: 36 | preset: 2 37 | taaSettings: 38 | jitterSpread: 0.75 39 | sharpen: 0.3 40 | stationaryBlending: 0.95 41 | motionBlending: 0.85 42 | ambientOcclusion: 43 | m_Enabled: 0 44 | m_Settings: 45 | intensity: 1 46 | radius: 0.3 47 | sampleCount: 10 48 | downsampling: 1 49 | forceForwardCompatibility: 0 50 | ambientOnly: 0 51 | highPrecision: 0 52 | screenSpaceReflection: 53 | m_Enabled: 0 54 | m_Settings: 55 | reflection: 56 | blendType: 0 57 | reflectionQuality: 2 58 | maxDistance: 100 59 | iterationCount: 256 60 | stepSize: 3 61 | widthModifier: 0.5 62 | reflectionBlur: 1 63 | reflectBackfaces: 0 64 | intensity: 65 | reflectionMultiplier: 1 66 | fadeDistance: 100 67 | fresnelFade: 1 68 | fresnelFadePower: 1 69 | screenEdgeMask: 70 | intensity: 0.03 71 | depthOfField: 72 | m_Enabled: 0 73 | m_Settings: 74 | focusDistance: 10 75 | aperture: 5.6 76 | focalLength: 50 77 | useCameraFov: 0 78 | kernelSize: 1 79 | motionBlur: 80 | m_Enabled: 0 81 | m_Settings: 82 | shutterAngle: 270 83 | sampleCount: 10 84 | frameBlending: 0 85 | eyeAdaptation: 86 | m_Enabled: 0 87 | m_Settings: 88 | lowPercent: 45 89 | highPercent: 95 90 | minLuminance: -5 91 | maxLuminance: 1 92 | keyValue: 0.25 93 | dynamicKeyValue: 1 94 | adaptationType: 0 95 | speedUp: 2 96 | speedDown: 1 97 | logMin: -8 98 | logMax: 4 99 | bloom: 100 | m_Enabled: 0 101 | m_Settings: 102 | bloom: 103 | intensity: 0.5 104 | threshold: 1.1 105 | softKnee: 0.5 106 | radius: 4 107 | antiFlicker: 0 108 | lensDirt: 109 | texture: {fileID: 0} 110 | intensity: 3 111 | colorGrading: 112 | m_Enabled: 1 113 | m_Settings: 114 | tonemapping: 115 | tonemapper: 1 116 | neutralBlackIn: 0.02 117 | neutralWhiteIn: 10 118 | neutralBlackOut: 0 119 | neutralWhiteOut: 10 120 | neutralWhiteLevel: 5.3 121 | neutralWhiteClip: 10 122 | basic: 123 | postExposure: 0.76 124 | temperature: -7 125 | tint: 7 126 | hueShift: -3 127 | saturation: 1.1 128 | contrast: 1.17 129 | channelMixer: 130 | red: {x: 1, y: 0, z: 0} 131 | green: {x: 0, y: 1, z: 0} 132 | blue: {x: 0, y: 0, z: 1} 133 | currentEditingChannel: 0 134 | colorWheels: 135 | mode: 1 136 | log: 137 | slope: {r: 1, g: 0.8999554, b: 0.9157331, a: 0} 138 | power: {r: 0.8594728, g: 0.9518555, b: 1, a: 0} 139 | offset: {r: 0.97532827, g: 0.9506581, b: 1, a: 0} 140 | linear: 141 | lift: {r: 0, g: 0, b: 0, a: 0} 142 | gamma: {r: 0, g: 0, b: 0, a: 0} 143 | gain: {r: 0, g: 0, b: 0, a: 0} 144 | curves: 145 | master: 146 | curve: 147 | serializedVersion: 2 148 | m_Curve: 149 | - serializedVersion: 2 150 | time: 0 151 | value: 0 152 | inSlope: 1 153 | outSlope: 1 154 | tangentMode: 0 155 | - serializedVersion: 2 156 | time: 1 157 | value: 1 158 | inSlope: 1 159 | outSlope: 1 160 | tangentMode: 0 161 | m_PreInfinity: 2 162 | m_PostInfinity: 2 163 | m_RotationOrder: 0 164 | m_Loop: 0 165 | m_ZeroValue: 0 166 | m_Range: 1 167 | red: 168 | curve: 169 | serializedVersion: 2 170 | m_Curve: 171 | - serializedVersion: 2 172 | time: 0 173 | value: 0 174 | inSlope: 1 175 | outSlope: 1 176 | tangentMode: 0 177 | - serializedVersion: 2 178 | time: 1 179 | value: 1 180 | inSlope: 1 181 | outSlope: 1 182 | tangentMode: 0 183 | m_PreInfinity: 2 184 | m_PostInfinity: 2 185 | m_RotationOrder: 4 186 | m_Loop: 0 187 | m_ZeroValue: 0 188 | m_Range: 1 189 | green: 190 | curve: 191 | serializedVersion: 2 192 | m_Curve: 193 | - serializedVersion: 2 194 | time: 0 195 | value: 0 196 | inSlope: 1 197 | outSlope: 1 198 | tangentMode: 0 199 | - serializedVersion: 2 200 | time: 1 201 | value: 1 202 | inSlope: 1 203 | outSlope: 1 204 | tangentMode: 0 205 | m_PreInfinity: 2 206 | m_PostInfinity: 2 207 | m_RotationOrder: 4 208 | m_Loop: 0 209 | m_ZeroValue: 0 210 | m_Range: 1 211 | blue: 212 | curve: 213 | serializedVersion: 2 214 | m_Curve: 215 | - serializedVersion: 2 216 | time: 0 217 | value: 0 218 | inSlope: 1 219 | outSlope: 1 220 | tangentMode: 0 221 | - serializedVersion: 2 222 | time: 1 223 | value: 1 224 | inSlope: 1 225 | outSlope: 1 226 | tangentMode: 0 227 | m_PreInfinity: 2 228 | m_PostInfinity: 2 229 | m_RotationOrder: 4 230 | m_Loop: 0 231 | m_ZeroValue: 0 232 | m_Range: 1 233 | hueVShue: 234 | curve: 235 | serializedVersion: 2 236 | m_Curve: [] 237 | m_PreInfinity: 2 238 | m_PostInfinity: 2 239 | m_RotationOrder: 4 240 | m_Loop: 1 241 | m_ZeroValue: 0.5 242 | m_Range: 1 243 | hueVSsat: 244 | curve: 245 | serializedVersion: 2 246 | m_Curve: [] 247 | m_PreInfinity: 2 248 | m_PostInfinity: 2 249 | m_RotationOrder: 4 250 | m_Loop: 1 251 | m_ZeroValue: 0.5 252 | m_Range: 1 253 | satVSsat: 254 | curve: 255 | serializedVersion: 2 256 | m_Curve: [] 257 | m_PreInfinity: 2 258 | m_PostInfinity: 2 259 | m_RotationOrder: 4 260 | m_Loop: 0 261 | m_ZeroValue: 0.5 262 | m_Range: 1 263 | lumVSsat: 264 | curve: 265 | serializedVersion: 2 266 | m_Curve: [] 267 | m_PreInfinity: 2 268 | m_PostInfinity: 2 269 | m_RotationOrder: 4 270 | m_Loop: 0 271 | m_ZeroValue: 0.5 272 | m_Range: 1 273 | e_CurrentEditingCurve: 0 274 | e_CurveY: 1 275 | e_CurveR: 0 276 | e_CurveG: 0 277 | e_CurveB: 0 278 | userLut: 279 | m_Enabled: 0 280 | m_Settings: 281 | lut: {fileID: 0} 282 | contribution: 1 283 | chromaticAberration: 284 | m_Enabled: 0 285 | m_Settings: 286 | spectralTexture: {fileID: 0} 287 | intensity: 1 288 | grain: 289 | m_Enabled: 1 290 | m_Settings: 291 | colored: 1 292 | intensity: 0.32 293 | size: 0.48 294 | luminanceContribution: 0.8 295 | vignette: 296 | m_Enabled: 0 297 | m_Settings: 298 | mode: 0 299 | color: {r: 0, g: 0, b: 0, a: 1} 300 | center: {x: 0.5, y: 0.5} 301 | intensity: 0.28 302 | smoothness: 0.2 303 | roundness: 0.52 304 | mask: {fileID: 0} 305 | opacity: 1 306 | rounded: 0 307 | dithering: 308 | m_Enabled: 0 309 | monitors: 310 | currentMonitorID: 0 311 | refreshOnPlay: 0 312 | histogramMode: 3 313 | waveformExposure: 0.12 314 | waveformY: 0 315 | waveformR: 1 316 | waveformG: 1 317 | waveformB: 1 318 | paradeExposure: 0.12 319 | vectorscopeExposure: 0.12 320 | vectorscopeShowBackground: 1 321 | -------------------------------------------------------------------------------- /Assets/Scene/PostProcessing Profile.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 831837db19fef8d4f9e9735ebfb7cf25 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scene/Scene.unity: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!29 &1 4 | OcclusionCullingSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_OcclusionBakeSettings: 8 | smallestOccluder: 5 9 | smallestHole: 0.25 10 | backfaceThreshold: 100 11 | m_SceneGUID: 00000000000000000000000000000000 12 | m_OcclusionCullingData: {fileID: 0} 13 | --- !u!104 &2 14 | RenderSettings: 15 | m_ObjectHideFlags: 0 16 | serializedVersion: 9 17 | m_Fog: 1 18 | m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} 19 | m_FogMode: 3 20 | m_FogDensity: 0.01 21 | m_LinearFogStart: 0 22 | m_LinearFogEnd: 300 23 | m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} 24 | m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} 25 | m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} 26 | m_AmbientIntensity: 1 27 | m_AmbientMode: 0 28 | m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1} 29 | m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0} 30 | m_HaloStrength: 0.5 31 | m_FlareStrength: 1 32 | m_FlareFadeSpeed: 3 33 | m_HaloTexture: {fileID: 0} 34 | m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} 35 | m_DefaultReflectionMode: 0 36 | m_DefaultReflectionResolution: 128 37 | m_ReflectionBounces: 1 38 | m_ReflectionIntensity: 1 39 | m_CustomReflection: {fileID: 0} 40 | m_Sun: {fileID: 952335419} 41 | m_IndirectSpecularColor: {r: 0.44657898, g: 0.4964133, b: 0.5748178, a: 1} 42 | m_UseRadianceAmbientProbe: 0 43 | --- !u!157 &3 44 | LightmapSettings: 45 | m_ObjectHideFlags: 0 46 | serializedVersion: 11 47 | m_GIWorkflowMode: 0 48 | m_GISettings: 49 | serializedVersion: 2 50 | m_BounceScale: 1 51 | m_IndirectOutputScale: 1 52 | m_AlbedoBoost: 1 53 | m_EnvironmentLightingMode: 0 54 | m_EnableBakedLightmaps: 0 55 | m_EnableRealtimeLightmaps: 1 56 | m_LightmapEditorSettings: 57 | serializedVersion: 10 58 | m_Resolution: 2 59 | m_BakeResolution: 40 60 | m_AtlasSize: 1024 61 | m_AO: 0 62 | m_AOMaxDistance: 1 63 | m_CompAOExponent: 1 64 | m_CompAOExponentDirect: 0 65 | m_Padding: 2 66 | m_LightmapParameters: {fileID: 0} 67 | m_LightmapsBakeMode: 1 68 | m_TextureCompression: 1 69 | m_FinalGather: 0 70 | m_FinalGatherFiltering: 1 71 | m_FinalGatherRayCount: 256 72 | m_ReflectionCompression: 2 73 | m_MixedBakeMode: 2 74 | m_BakeBackend: 0 75 | m_PVRSampling: 1 76 | m_PVRDirectSampleCount: 32 77 | m_PVRSampleCount: 500 78 | m_PVRBounces: 2 79 | m_PVRFilterTypeDirect: 0 80 | m_PVRFilterTypeIndirect: 0 81 | m_PVRFilterTypeAO: 0 82 | m_PVRFilteringMode: 1 83 | m_PVRCulling: 1 84 | m_PVRFilteringGaussRadiusDirect: 1 85 | m_PVRFilteringGaussRadiusIndirect: 5 86 | m_PVRFilteringGaussRadiusAO: 2 87 | m_PVRFilteringAtrousPositionSigmaDirect: 0.5 88 | m_PVRFilteringAtrousPositionSigmaIndirect: 2 89 | m_PVRFilteringAtrousPositionSigmaAO: 1 90 | m_ShowResolutionOverlay: 1 91 | m_LightingDataAsset: {fileID: 0} 92 | m_UseShadowmask: 1 93 | --- !u!196 &4 94 | NavMeshSettings: 95 | serializedVersion: 2 96 | m_ObjectHideFlags: 0 97 | m_BuildSettings: 98 | serializedVersion: 2 99 | agentTypeID: 0 100 | agentRadius: 0.5 101 | agentHeight: 2 102 | agentSlope: 45 103 | agentClimb: 0.4 104 | ledgeDropHeight: 0 105 | maxJumpAcrossDistance: 0 106 | minRegionArea: 2 107 | manualCellSize: 0 108 | cellSize: 0.16666667 109 | manualTileSize: 0 110 | tileSize: 256 111 | accuratePlacement: 0 112 | debug: 113 | m_Flags: 0 114 | m_NavMeshData: {fileID: 0} 115 | --- !u!1 &952335418 116 | GameObject: 117 | m_ObjectHideFlags: 0 118 | m_CorrespondingSourceObject: {fileID: 0} 119 | m_PrefabInstance: {fileID: 0} 120 | m_PrefabAsset: {fileID: 0} 121 | serializedVersion: 6 122 | m_Component: 123 | - component: {fileID: 952335420} 124 | - component: {fileID: 952335419} 125 | m_Layer: 0 126 | m_Name: Directional Light 127 | m_TagString: Untagged 128 | m_Icon: {fileID: 0} 129 | m_NavMeshLayer: 0 130 | m_StaticEditorFlags: 0 131 | m_IsActive: 1 132 | --- !u!108 &952335419 133 | Light: 134 | m_ObjectHideFlags: 0 135 | m_CorrespondingSourceObject: {fileID: 0} 136 | m_PrefabInstance: {fileID: 0} 137 | m_PrefabAsset: {fileID: 0} 138 | m_GameObject: {fileID: 952335418} 139 | m_Enabled: 1 140 | serializedVersion: 8 141 | m_Type: 1 142 | m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1} 143 | m_Intensity: 1 144 | m_Range: 10 145 | m_SpotAngle: 30 146 | m_CookieSize: 10 147 | m_Shadows: 148 | m_Type: 2 149 | m_Resolution: -1 150 | m_CustomResolution: -1 151 | m_Strength: 1 152 | m_Bias: 0.05 153 | m_NormalBias: 0.4 154 | m_NearPlane: 0.2 155 | m_Cookie: {fileID: 0} 156 | m_DrawHalo: 0 157 | m_Flare: {fileID: 0} 158 | m_RenderMode: 0 159 | m_CullingMask: 160 | serializedVersion: 2 161 | m_Bits: 4294967295 162 | m_Lightmapping: 4 163 | m_LightShadowCasterMode: 0 164 | m_AreaSize: {x: 1, y: 1} 165 | m_BounceIntensity: 1 166 | m_ColorTemperature: 6570 167 | m_UseColorTemperature: 0 168 | m_ShadowRadius: 0 169 | m_ShadowAngle: 0 170 | --- !u!4 &952335420 171 | Transform: 172 | m_ObjectHideFlags: 0 173 | m_CorrespondingSourceObject: {fileID: 0} 174 | m_PrefabInstance: {fileID: 0} 175 | m_PrefabAsset: {fileID: 0} 176 | m_GameObject: {fileID: 952335418} 177 | m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261} 178 | m_LocalPosition: {x: 0, y: 3, z: 0} 179 | m_LocalScale: {x: 1, y: 1, z: 1} 180 | m_Children: [] 181 | m_Father: {fileID: 0} 182 | m_RootOrder: 1 183 | m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0} 184 | --- !u!1 &994636957 185 | GameObject: 186 | m_ObjectHideFlags: 0 187 | m_CorrespondingSourceObject: {fileID: 0} 188 | m_PrefabInstance: {fileID: 0} 189 | m_PrefabAsset: {fileID: 0} 190 | serializedVersion: 6 191 | m_Component: 192 | - component: {fileID: 994636959} 193 | - component: {fileID: 994636958} 194 | m_Layer: 0 195 | m_Name: Fluid 196 | m_TagString: Untagged 197 | m_Icon: {fileID: 0} 198 | m_NavMeshLayer: 0 199 | m_StaticEditorFlags: 0 200 | m_IsActive: 1 201 | --- !u!114 &994636958 202 | MonoBehaviour: 203 | m_ObjectHideFlags: 0 204 | m_CorrespondingSourceObject: {fileID: 0} 205 | m_PrefabInstance: {fileID: 0} 206 | m_PrefabAsset: {fileID: 0} 207 | m_GameObject: {fileID: 994636957} 208 | m_Enabled: 1 209 | m_EditorHideFlags: 0 210 | m_Script: {fileID: 11500000, guid: 24d101cfa59b2374580e501e884fee14, type: 3} 211 | m_Name: 212 | m_EditorClassIdentifier: 213 | compute: {fileID: 7200000, guid: 1abef17a3385d1d40a6f42ad2fccfa0d, type: 3} 214 | material: {fileID: 2100000, guid: 97f62e7b561a09a4cb5ae0530e7bb364, type: 2} 215 | n: 254 216 | diff: 0 217 | visc: 0 218 | force: 150 219 | source: 100 220 | --- !u!4 &994636959 221 | Transform: 222 | m_ObjectHideFlags: 0 223 | m_CorrespondingSourceObject: {fileID: 0} 224 | m_PrefabInstance: {fileID: 0} 225 | m_PrefabAsset: {fileID: 0} 226 | m_GameObject: {fileID: 994636957} 227 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 228 | m_LocalPosition: {x: 0, y: 0, z: 0} 229 | m_LocalScale: {x: 1, y: 1, z: 1} 230 | m_Children: [] 231 | m_Father: {fileID: 0} 232 | m_RootOrder: 2 233 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 234 | --- !u!1 &1896215651 235 | GameObject: 236 | m_ObjectHideFlags: 0 237 | m_CorrespondingSourceObject: {fileID: 0} 238 | m_PrefabInstance: {fileID: 0} 239 | m_PrefabAsset: {fileID: 0} 240 | serializedVersion: 6 241 | m_Component: 242 | - component: {fileID: 1896215654} 243 | - component: {fileID: 1896215653} 244 | m_Layer: 0 245 | m_Name: Main Camera 246 | m_TagString: MainCamera 247 | m_Icon: {fileID: 0} 248 | m_NavMeshLayer: 0 249 | m_StaticEditorFlags: 0 250 | m_IsActive: 1 251 | --- !u!20 &1896215653 252 | Camera: 253 | m_ObjectHideFlags: 0 254 | m_CorrespondingSourceObject: {fileID: 0} 255 | m_PrefabInstance: {fileID: 0} 256 | m_PrefabAsset: {fileID: 0} 257 | m_GameObject: {fileID: 1896215651} 258 | m_Enabled: 1 259 | serializedVersion: 2 260 | m_ClearFlags: 1 261 | m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} 262 | m_projectionMatrixMode: 1 263 | m_SensorSize: {x: 36, y: 24} 264 | m_LensShift: {x: 0, y: 0} 265 | m_GateFitMode: 2 266 | m_FocalLength: 50 267 | m_NormalizedViewPortRect: 268 | serializedVersion: 2 269 | x: 0 270 | y: 0 271 | width: 1 272 | height: 1 273 | near clip plane: 0.3 274 | far clip plane: 1000 275 | field of view: 60 276 | orthographic: 0 277 | orthographic size: 5 278 | m_Depth: 0 279 | m_CullingMask: 280 | serializedVersion: 2 281 | m_Bits: 4294967295 282 | m_RenderingPath: -1 283 | m_TargetTexture: {fileID: 0} 284 | m_TargetDisplay: 0 285 | m_TargetEye: 3 286 | m_HDR: 1 287 | m_AllowMSAA: 0 288 | m_AllowDynamicResolution: 0 289 | m_ForceIntoRT: 0 290 | m_OcclusionCulling: 1 291 | m_StereoConvergence: 10 292 | m_StereoSeparation: 0.022 293 | --- !u!4 &1896215654 294 | Transform: 295 | m_ObjectHideFlags: 0 296 | m_CorrespondingSourceObject: {fileID: 0} 297 | m_PrefabInstance: {fileID: 0} 298 | m_PrefabAsset: {fileID: 0} 299 | m_GameObject: {fileID: 1896215651} 300 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 301 | m_LocalPosition: {x: 0, y: 0, z: -10} 302 | m_LocalScale: {x: 1, y: 1, z: 1} 303 | m_Children: [] 304 | m_Father: {fileID: 0} 305 | m_RootOrder: 0 306 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 307 | -------------------------------------------------------------------------------- /Assets/Scene/Scene.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a21f61242d78e664791da55554606aca 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | BSD 3-Clause License 2 | 3 | Copyright (c) 2019, Daniel Shervheim 4 | All rights reserved. 5 | 6 | Redistribution and use in source and binary forms, with or without 7 | modification, are permitted provided that the following conditions are met: 8 | 9 | 1. Redistributions of source code must retain the above copyright notice, this 10 | list of conditions and the following disclaimer. 11 | 12 | 2. Redistributions in binary form must reproduce the above copyright notice, 13 | this list of conditions and the following disclaimer in the documentation 14 | and/or other materials provided with the distribution. 15 | 16 | 3. Neither the name of the copyright holder nor the names of its 17 | contributors may be used to endorse or promote products derived from 18 | this software without specific prior written permission. 19 | 20 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 21 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 23 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 24 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 26 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 27 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | -------------------------------------------------------------------------------- /Logs/Packages-Update.log: -------------------------------------------------------------------------------- 1 | 2 | === Tue Jun 18 17:22:22 2019 3 | 4 | Packages were changed. 5 | Update Mode: resetToDefaultDependencies 6 | 7 | The following packages were added: 8 | com.unity.analytics@3.2.2 9 | com.unity.purchasing@2.0.3 10 | com.unity.ads@2.0.8 11 | com.unity.textmeshpro@1.3.0 12 | com.unity.package-manager-ui@2.0.3 13 | com.unity.collab-proxy@1.2.15 14 | com.unity.modules.ai@1.0.0 15 | com.unity.modules.animation@1.0.0 16 | com.unity.modules.assetbundle@1.0.0 17 | com.unity.modules.audio@1.0.0 18 | com.unity.modules.cloth@1.0.0 19 | com.unity.modules.director@1.0.0 20 | com.unity.modules.imageconversion@1.0.0 21 | com.unity.modules.imgui@1.0.0 22 | com.unity.modules.jsonserialize@1.0.0 23 | com.unity.modules.particlesystem@1.0.0 24 | com.unity.modules.physics@1.0.0 25 | com.unity.modules.physics2d@1.0.0 26 | com.unity.modules.screencapture@1.0.0 27 | com.unity.modules.terrain@1.0.0 28 | com.unity.modules.terrainphysics@1.0.0 29 | com.unity.modules.tilemap@1.0.0 30 | com.unity.modules.ui@1.0.0 31 | com.unity.modules.uielements@1.0.0 32 | com.unity.modules.umbra@1.0.0 33 | com.unity.modules.unityanalytics@1.0.0 34 | com.unity.modules.unitywebrequest@1.0.0 35 | com.unity.modules.unitywebrequestassetbundle@1.0.0 36 | com.unity.modules.unitywebrequestaudio@1.0.0 37 | com.unity.modules.unitywebrequesttexture@1.0.0 38 | com.unity.modules.unitywebrequestwww@1.0.0 39 | com.unity.modules.vehicles@1.0.0 40 | com.unity.modules.video@1.0.0 41 | com.unity.modules.vr@1.0.0 42 | com.unity.modules.wind@1.0.0 43 | com.unity.modules.xr@1.0.0 44 | -------------------------------------------------------------------------------- /Packages/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "com.unity.ads": "2.0.8", 4 | "com.unity.analytics": "3.2.2", 5 | "com.unity.collab-proxy": "1.2.15", 6 | "com.unity.package-manager-ui": "2.0.3", 7 | "com.unity.purchasing": "2.0.3", 8 | "com.unity.textmeshpro": "1.3.0", 9 | "com.unity.modules.ai": "1.0.0", 10 | "com.unity.modules.animation": "1.0.0", 11 | "com.unity.modules.assetbundle": "1.0.0", 12 | "com.unity.modules.audio": "1.0.0", 13 | "com.unity.modules.cloth": "1.0.0", 14 | "com.unity.modules.director": "1.0.0", 15 | "com.unity.modules.imageconversion": "1.0.0", 16 | "com.unity.modules.imgui": "1.0.0", 17 | "com.unity.modules.jsonserialize": "1.0.0", 18 | "com.unity.modules.particlesystem": "1.0.0", 19 | "com.unity.modules.physics": "1.0.0", 20 | "com.unity.modules.physics2d": "1.0.0", 21 | "com.unity.modules.screencapture": "1.0.0", 22 | "com.unity.modules.terrain": "1.0.0", 23 | "com.unity.modules.terrainphysics": "1.0.0", 24 | "com.unity.modules.tilemap": "1.0.0", 25 | "com.unity.modules.ui": "1.0.0", 26 | "com.unity.modules.uielements": "1.0.0", 27 | "com.unity.modules.umbra": "1.0.0", 28 | "com.unity.modules.unityanalytics": "1.0.0", 29 | "com.unity.modules.unitywebrequest": "1.0.0", 30 | "com.unity.modules.unitywebrequestassetbundle": "1.0.0", 31 | "com.unity.modules.unitywebrequestaudio": "1.0.0", 32 | "com.unity.modules.unitywebrequesttexture": "1.0.0", 33 | "com.unity.modules.unitywebrequestwww": "1.0.0", 34 | "com.unity.modules.vehicles": "1.0.0", 35 | "com.unity.modules.video": "1.0.0", 36 | "com.unity.modules.vr": "1.0.0", 37 | "com.unity.modules.wind": "1.0.0", 38 | "com.unity.modules.xr": "1.0.0" 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /ProjectSettings/AudioManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!11 &1 4 | AudioManager: 5 | m_ObjectHideFlags: 0 6 | m_Volume: 1 7 | Rolloff Scale: 1 8 | Doppler Factor: 1 9 | Default Speaker Mode: 2 10 | m_SampleRate: 0 11 | m_DSPBufferSize: 1024 12 | m_VirtualVoiceCount: 512 13 | m_RealVoiceCount: 32 14 | m_SpatializerPlugin: 15 | m_AmbisonicDecoderPlugin: 16 | m_DisableAudio: 0 17 | m_VirtualizeEffects: 1 18 | -------------------------------------------------------------------------------- /ProjectSettings/ClusterInputManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!236 &1 4 | ClusterInputManager: 5 | m_ObjectHideFlags: 0 6 | m_Inputs: [] 7 | -------------------------------------------------------------------------------- /ProjectSettings/DynamicsManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!55 &1 4 | PhysicsManager: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 10 7 | m_Gravity: {x: 0, y: -9.81, z: 0} 8 | m_DefaultMaterial: {fileID: 0} 9 | m_BounceThreshold: 2 10 | m_SleepThreshold: 0.005 11 | m_DefaultContactOffset: 0.01 12 | m_DefaultSolverIterations: 6 13 | m_DefaultSolverVelocityIterations: 1 14 | m_QueriesHitBackfaces: 0 15 | m_QueriesHitTriggers: 1 16 | m_EnableAdaptiveForce: 0 17 | m_ClothInterCollisionDistance: 0 18 | m_ClothInterCollisionStiffness: 0 19 | m_ContactsGeneration: 1 20 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 21 | m_AutoSimulation: 1 22 | m_AutoSyncTransforms: 0 23 | m_ReuseCollisionCallbacks: 0 24 | m_ClothInterCollisionSettingsToggle: 0 25 | m_ContactPairsMode: 0 26 | m_BroadphaseType: 0 27 | m_WorldBounds: 28 | m_Center: {x: 0, y: 0, z: 0} 29 | m_Extent: {x: 250, y: 250, z: 250} 30 | m_WorldSubdivisions: 8 31 | m_FrictionType: 0 32 | m_EnableEnhancedDeterminism: 0 33 | m_EnableUnifiedHeightmaps: 1 34 | -------------------------------------------------------------------------------- /ProjectSettings/EditorBuildSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1045 &1 4 | EditorBuildSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_Scenes: 8 | - enabled: 1 9 | path: Assets/Scene/Scene.unity 10 | guid: a21f61242d78e664791da55554606aca 11 | m_configObjects: {} 12 | -------------------------------------------------------------------------------- /ProjectSettings/EditorSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!159 &1 4 | EditorSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 7 7 | m_ExternalVersionControlSupport: Hidden Meta Files 8 | m_SerializationMode: 2 9 | m_LineEndingsForNewScripts: 2 10 | m_DefaultBehaviorMode: 0 11 | m_PrefabRegularEnvironment: {fileID: 0} 12 | m_PrefabUIEnvironment: {fileID: 0} 13 | m_SpritePackerMode: 0 14 | m_SpritePackerPaddingPower: 1 15 | m_EtcTextureCompressorBehavior: 1 16 | m_EtcTextureFastCompressor: 1 17 | m_EtcTextureNormalCompressor: 2 18 | m_EtcTextureBestCompressor: 4 19 | m_ProjectGenerationIncludedExtensions: txt;xml;fnt;cd;asmdef;rsp 20 | m_ProjectGenerationRootNamespace: 21 | m_CollabEditorSettings: 22 | inProgressEnabled: 1 23 | m_EnableTextureStreamingInPlayMode: 1 24 | -------------------------------------------------------------------------------- /ProjectSettings/GraphicsSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!30 &1 4 | GraphicsSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 12 7 | m_Deferred: 8 | m_Mode: 1 9 | m_Shader: {fileID: 69, guid: 0000000000000000f000000000000000, type: 0} 10 | m_DeferredReflections: 11 | m_Mode: 1 12 | m_Shader: {fileID: 74, guid: 0000000000000000f000000000000000, type: 0} 13 | m_ScreenSpaceShadows: 14 | m_Mode: 1 15 | m_Shader: {fileID: 64, guid: 0000000000000000f000000000000000, type: 0} 16 | m_LegacyDeferred: 17 | m_Mode: 1 18 | m_Shader: {fileID: 63, guid: 0000000000000000f000000000000000, type: 0} 19 | m_DepthNormals: 20 | m_Mode: 1 21 | m_Shader: {fileID: 62, guid: 0000000000000000f000000000000000, type: 0} 22 | m_MotionVectors: 23 | m_Mode: 1 24 | m_Shader: {fileID: 75, guid: 0000000000000000f000000000000000, type: 0} 25 | m_LightHalo: 26 | m_Mode: 1 27 | m_Shader: {fileID: 105, guid: 0000000000000000f000000000000000, type: 0} 28 | m_LensFlare: 29 | m_Mode: 1 30 | m_Shader: {fileID: 102, guid: 0000000000000000f000000000000000, type: 0} 31 | m_AlwaysIncludedShaders: 32 | - {fileID: 7, guid: 0000000000000000f000000000000000, type: 0} 33 | - {fileID: 15104, guid: 0000000000000000f000000000000000, type: 0} 34 | - {fileID: 15105, guid: 0000000000000000f000000000000000, type: 0} 35 | - {fileID: 15106, guid: 0000000000000000f000000000000000, type: 0} 36 | - {fileID: 10753, guid: 0000000000000000f000000000000000, type: 0} 37 | - {fileID: 10770, guid: 0000000000000000f000000000000000, type: 0} 38 | - {fileID: 10783, guid: 0000000000000000f000000000000000, type: 0} 39 | - {fileID: 16000, guid: 0000000000000000f000000000000000, type: 0} 40 | - {fileID: 17000, guid: 0000000000000000f000000000000000, type: 0} 41 | m_PreloadedShaders: [] 42 | m_SpritesDefaultMaterial: {fileID: 10754, guid: 0000000000000000f000000000000000, 43 | type: 0} 44 | m_CustomRenderPipeline: {fileID: 0} 45 | m_TransparencySortMode: 0 46 | m_TransparencySortAxis: {x: 0, y: 0, z: 1} 47 | m_DefaultRenderingPath: 1 48 | m_DefaultMobileRenderingPath: 1 49 | m_TierSettings: [] 50 | m_LightmapStripping: 0 51 | m_FogStripping: 0 52 | m_InstancingStripping: 0 53 | m_LightmapKeepPlain: 1 54 | m_LightmapKeepDirCombined: 1 55 | m_LightmapKeepDynamicPlain: 1 56 | m_LightmapKeepDynamicDirCombined: 1 57 | m_LightmapKeepShadowMask: 1 58 | m_LightmapKeepSubtractive: 1 59 | m_FogKeepLinear: 1 60 | m_FogKeepExp: 1 61 | m_FogKeepExp2: 1 62 | m_AlbedoSwatchInfos: [] 63 | m_LightsUseLinearIntensity: 0 64 | m_LightsUseColorTemperature: 0 65 | -------------------------------------------------------------------------------- /ProjectSettings/InputManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!13 &1 4 | InputManager: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_Axes: 8 | - serializedVersion: 3 9 | m_Name: Horizontal 10 | descriptiveName: 11 | descriptiveNegativeName: 12 | negativeButton: left 13 | positiveButton: right 14 | altNegativeButton: a 15 | altPositiveButton: d 16 | gravity: 3 17 | dead: 0.001 18 | sensitivity: 3 19 | snap: 1 20 | invert: 0 21 | type: 0 22 | axis: 0 23 | joyNum: 0 24 | - serializedVersion: 3 25 | m_Name: Vertical 26 | descriptiveName: 27 | descriptiveNegativeName: 28 | negativeButton: down 29 | positiveButton: up 30 | altNegativeButton: s 31 | altPositiveButton: w 32 | gravity: 3 33 | dead: 0.001 34 | sensitivity: 3 35 | snap: 1 36 | invert: 0 37 | type: 0 38 | axis: 0 39 | joyNum: 0 40 | - serializedVersion: 3 41 | m_Name: Fire1 42 | descriptiveName: 43 | descriptiveNegativeName: 44 | negativeButton: 45 | positiveButton: left ctrl 46 | altNegativeButton: 47 | altPositiveButton: mouse 0 48 | gravity: 1000 49 | dead: 0.001 50 | sensitivity: 1000 51 | snap: 0 52 | invert: 0 53 | type: 0 54 | axis: 0 55 | joyNum: 0 56 | - serializedVersion: 3 57 | m_Name: Fire2 58 | descriptiveName: 59 | descriptiveNegativeName: 60 | negativeButton: 61 | positiveButton: left alt 62 | altNegativeButton: 63 | altPositiveButton: mouse 1 64 | gravity: 1000 65 | dead: 0.001 66 | sensitivity: 1000 67 | snap: 0 68 | invert: 0 69 | type: 0 70 | axis: 0 71 | joyNum: 0 72 | - serializedVersion: 3 73 | m_Name: Fire3 74 | descriptiveName: 75 | descriptiveNegativeName: 76 | negativeButton: 77 | positiveButton: left shift 78 | altNegativeButton: 79 | altPositiveButton: mouse 2 80 | gravity: 1000 81 | dead: 0.001 82 | sensitivity: 1000 83 | snap: 0 84 | invert: 0 85 | type: 0 86 | axis: 0 87 | joyNum: 0 88 | - serializedVersion: 3 89 | m_Name: Jump 90 | descriptiveName: 91 | descriptiveNegativeName: 92 | negativeButton: 93 | positiveButton: space 94 | altNegativeButton: 95 | altPositiveButton: 96 | gravity: 1000 97 | dead: 0.001 98 | sensitivity: 1000 99 | snap: 0 100 | invert: 0 101 | type: 0 102 | axis: 0 103 | joyNum: 0 104 | - serializedVersion: 3 105 | m_Name: Mouse X 106 | descriptiveName: 107 | descriptiveNegativeName: 108 | negativeButton: 109 | positiveButton: 110 | altNegativeButton: 111 | altPositiveButton: 112 | gravity: 0 113 | dead: 0 114 | sensitivity: 0.1 115 | snap: 0 116 | invert: 0 117 | type: 1 118 | axis: 0 119 | joyNum: 0 120 | - serializedVersion: 3 121 | m_Name: Mouse Y 122 | descriptiveName: 123 | descriptiveNegativeName: 124 | negativeButton: 125 | positiveButton: 126 | altNegativeButton: 127 | altPositiveButton: 128 | gravity: 0 129 | dead: 0 130 | sensitivity: 0.1 131 | snap: 0 132 | invert: 0 133 | type: 1 134 | axis: 1 135 | joyNum: 0 136 | - serializedVersion: 3 137 | m_Name: Mouse ScrollWheel 138 | descriptiveName: 139 | descriptiveNegativeName: 140 | negativeButton: 141 | positiveButton: 142 | altNegativeButton: 143 | altPositiveButton: 144 | gravity: 0 145 | dead: 0 146 | sensitivity: 0.1 147 | snap: 0 148 | invert: 0 149 | type: 1 150 | axis: 2 151 | joyNum: 0 152 | - serializedVersion: 3 153 | m_Name: Horizontal 154 | descriptiveName: 155 | descriptiveNegativeName: 156 | negativeButton: 157 | positiveButton: 158 | altNegativeButton: 159 | altPositiveButton: 160 | gravity: 0 161 | dead: 0.19 162 | sensitivity: 1 163 | snap: 0 164 | invert: 0 165 | type: 2 166 | axis: 0 167 | joyNum: 0 168 | - serializedVersion: 3 169 | m_Name: Vertical 170 | descriptiveName: 171 | descriptiveNegativeName: 172 | negativeButton: 173 | positiveButton: 174 | altNegativeButton: 175 | altPositiveButton: 176 | gravity: 0 177 | dead: 0.19 178 | sensitivity: 1 179 | snap: 0 180 | invert: 1 181 | type: 2 182 | axis: 1 183 | joyNum: 0 184 | - serializedVersion: 3 185 | m_Name: Fire1 186 | descriptiveName: 187 | descriptiveNegativeName: 188 | negativeButton: 189 | positiveButton: joystick button 0 190 | altNegativeButton: 191 | altPositiveButton: 192 | gravity: 1000 193 | dead: 0.001 194 | sensitivity: 1000 195 | snap: 0 196 | invert: 0 197 | type: 0 198 | axis: 0 199 | joyNum: 0 200 | - serializedVersion: 3 201 | m_Name: Fire2 202 | descriptiveName: 203 | descriptiveNegativeName: 204 | negativeButton: 205 | positiveButton: joystick button 1 206 | altNegativeButton: 207 | altPositiveButton: 208 | gravity: 1000 209 | dead: 0.001 210 | sensitivity: 1000 211 | snap: 0 212 | invert: 0 213 | type: 0 214 | axis: 0 215 | joyNum: 0 216 | - serializedVersion: 3 217 | m_Name: Fire3 218 | descriptiveName: 219 | descriptiveNegativeName: 220 | negativeButton: 221 | positiveButton: joystick button 2 222 | altNegativeButton: 223 | altPositiveButton: 224 | gravity: 1000 225 | dead: 0.001 226 | sensitivity: 1000 227 | snap: 0 228 | invert: 0 229 | type: 0 230 | axis: 0 231 | joyNum: 0 232 | - serializedVersion: 3 233 | m_Name: Jump 234 | descriptiveName: 235 | descriptiveNegativeName: 236 | negativeButton: 237 | positiveButton: joystick button 3 238 | altNegativeButton: 239 | altPositiveButton: 240 | gravity: 1000 241 | dead: 0.001 242 | sensitivity: 1000 243 | snap: 0 244 | invert: 0 245 | type: 0 246 | axis: 0 247 | joyNum: 0 248 | - serializedVersion: 3 249 | m_Name: Submit 250 | descriptiveName: 251 | descriptiveNegativeName: 252 | negativeButton: 253 | positiveButton: return 254 | altNegativeButton: 255 | altPositiveButton: joystick button 0 256 | gravity: 1000 257 | dead: 0.001 258 | sensitivity: 1000 259 | snap: 0 260 | invert: 0 261 | type: 0 262 | axis: 0 263 | joyNum: 0 264 | - serializedVersion: 3 265 | m_Name: Submit 266 | descriptiveName: 267 | descriptiveNegativeName: 268 | negativeButton: 269 | positiveButton: enter 270 | altNegativeButton: 271 | altPositiveButton: space 272 | gravity: 1000 273 | dead: 0.001 274 | sensitivity: 1000 275 | snap: 0 276 | invert: 0 277 | type: 0 278 | axis: 0 279 | joyNum: 0 280 | - serializedVersion: 3 281 | m_Name: Cancel 282 | descriptiveName: 283 | descriptiveNegativeName: 284 | negativeButton: 285 | positiveButton: escape 286 | altNegativeButton: 287 | altPositiveButton: joystick button 1 288 | gravity: 1000 289 | dead: 0.001 290 | sensitivity: 1000 291 | snap: 0 292 | invert: 0 293 | type: 0 294 | axis: 0 295 | joyNum: 0 296 | -------------------------------------------------------------------------------- /ProjectSettings/NavMeshAreas.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!126 &1 4 | NavMeshProjectSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | areas: 8 | - name: Walkable 9 | cost: 1 10 | - name: Not Walkable 11 | cost: 1 12 | - name: Jump 13 | cost: 2 14 | - name: 15 | cost: 1 16 | - name: 17 | cost: 1 18 | - name: 19 | cost: 1 20 | - name: 21 | cost: 1 22 | - name: 23 | cost: 1 24 | - name: 25 | cost: 1 26 | - name: 27 | cost: 1 28 | - name: 29 | cost: 1 30 | - name: 31 | cost: 1 32 | - name: 33 | cost: 1 34 | - name: 35 | cost: 1 36 | - name: 37 | cost: 1 38 | - name: 39 | cost: 1 40 | - name: 41 | cost: 1 42 | - name: 43 | cost: 1 44 | - name: 45 | cost: 1 46 | - name: 47 | cost: 1 48 | - name: 49 | cost: 1 50 | - name: 51 | cost: 1 52 | - name: 53 | cost: 1 54 | - name: 55 | cost: 1 56 | - name: 57 | cost: 1 58 | - name: 59 | cost: 1 60 | - name: 61 | cost: 1 62 | - name: 63 | cost: 1 64 | - name: 65 | cost: 1 66 | - name: 67 | cost: 1 68 | - name: 69 | cost: 1 70 | - name: 71 | cost: 1 72 | m_LastAgentTypeID: -887442657 73 | m_Settings: 74 | - serializedVersion: 2 75 | agentTypeID: 0 76 | agentRadius: 0.5 77 | agentHeight: 2 78 | agentSlope: 45 79 | agentClimb: 0.75 80 | ledgeDropHeight: 0 81 | maxJumpAcrossDistance: 0 82 | minRegionArea: 2 83 | manualCellSize: 0 84 | cellSize: 0.16666667 85 | manualTileSize: 0 86 | tileSize: 256 87 | accuratePlacement: 0 88 | debug: 89 | m_Flags: 0 90 | m_SettingNames: 91 | - Humanoid 92 | -------------------------------------------------------------------------------- /ProjectSettings/Physics2DSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!19 &1 4 | Physics2DSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 4 7 | m_Gravity: {x: 0, y: -9.81} 8 | m_DefaultMaterial: {fileID: 0} 9 | m_VelocityIterations: 8 10 | m_PositionIterations: 3 11 | m_VelocityThreshold: 1 12 | m_MaxLinearCorrection: 0.2 13 | m_MaxAngularCorrection: 8 14 | m_MaxTranslationSpeed: 100 15 | m_MaxRotationSpeed: 360 16 | m_BaumgarteScale: 0.2 17 | m_BaumgarteTimeOfImpactScale: 0.75 18 | m_TimeToSleep: 0.5 19 | m_LinearSleepTolerance: 0.01 20 | m_AngularSleepTolerance: 2 21 | m_DefaultContactOffset: 0.01 22 | m_JobOptions: 23 | serializedVersion: 2 24 | useMultithreading: 0 25 | useConsistencySorting: 0 26 | m_InterpolationPosesPerJob: 100 27 | m_NewContactsPerJob: 30 28 | m_CollideContactsPerJob: 100 29 | m_ClearFlagsPerJob: 200 30 | m_ClearBodyForcesPerJob: 200 31 | m_SyncDiscreteFixturesPerJob: 50 32 | m_SyncContinuousFixturesPerJob: 50 33 | m_FindNearestContactsPerJob: 100 34 | m_UpdateTriggerContactsPerJob: 100 35 | m_IslandSolverCostThreshold: 100 36 | m_IslandSolverBodyCostScale: 1 37 | m_IslandSolverContactCostScale: 10 38 | m_IslandSolverJointCostScale: 10 39 | m_IslandSolverBodiesPerJob: 50 40 | m_IslandSolverContactsPerJob: 50 41 | m_AutoSimulation: 1 42 | m_QueriesHitTriggers: 1 43 | m_QueriesStartInColliders: 1 44 | m_CallbacksOnDisable: 1 45 | m_ReuseCollisionCallbacks: 0 46 | m_AutoSyncTransforms: 0 47 | m_AlwaysShowColliders: 0 48 | m_ShowColliderSleep: 1 49 | m_ShowColliderContacts: 0 50 | m_ShowColliderAABB: 0 51 | m_ContactArrowScale: 0.2 52 | m_ColliderAwakeColor: {r: 0.5686275, g: 0.95686275, b: 0.54509807, a: 0.7529412} 53 | m_ColliderAsleepColor: {r: 0.5686275, g: 0.95686275, b: 0.54509807, a: 0.36078432} 54 | m_ColliderContactColor: {r: 1, g: 0, b: 1, a: 0.6862745} 55 | m_ColliderAABBColor: {r: 1, g: 1, b: 0, a: 0.2509804} 56 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 57 | -------------------------------------------------------------------------------- /ProjectSettings/PresetManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1386491679 &1 4 | PresetManager: 5 | m_ObjectHideFlags: 0 6 | m_DefaultList: [] 7 | -------------------------------------------------------------------------------- /ProjectSettings/ProjectSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!129 &1 4 | PlayerSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 15 7 | productGUID: 034b208b157938147925ca05cb1c74f6 8 | AndroidProfiler: 0 9 | AndroidFilterTouchesWhenObscured: 0 10 | AndroidEnableSustainedPerformanceMode: 0 11 | defaultScreenOrientation: 4 12 | targetDevice: 2 13 | useOnDemandResources: 0 14 | accelerometerFrequency: 60 15 | companyName: DefaultCompany 16 | productName: Fluid-Simulation 17 | defaultCursor: {fileID: 0} 18 | cursorHotspot: {x: 0, y: 0} 19 | m_SplashScreenBackgroundColor: {r: 0.13725491, g: 0.12156863, b: 0.1254902, a: 1} 20 | m_ShowUnitySplashScreen: 1 21 | m_ShowUnitySplashLogo: 1 22 | m_SplashScreenOverlayOpacity: 1 23 | m_SplashScreenAnimation: 1 24 | m_SplashScreenLogoStyle: 1 25 | m_SplashScreenDrawMode: 0 26 | m_SplashScreenBackgroundAnimationZoom: 1 27 | m_SplashScreenLogoAnimationZoom: 1 28 | m_SplashScreenBackgroundLandscapeAspect: 1 29 | m_SplashScreenBackgroundPortraitAspect: 1 30 | m_SplashScreenBackgroundLandscapeUvs: 31 | serializedVersion: 2 32 | x: 0 33 | y: 0 34 | width: 1 35 | height: 1 36 | m_SplashScreenBackgroundPortraitUvs: 37 | serializedVersion: 2 38 | x: 0 39 | y: 0 40 | width: 1 41 | height: 1 42 | m_SplashScreenLogos: [] 43 | m_VirtualRealitySplashScreen: {fileID: 0} 44 | m_HolographicTrackingLossScreen: {fileID: 0} 45 | defaultScreenWidth: 1024 46 | defaultScreenHeight: 768 47 | defaultScreenWidthWeb: 960 48 | defaultScreenHeightWeb: 600 49 | m_StereoRenderingPath: 0 50 | m_ActiveColorSpace: 0 51 | m_MTRendering: 1 52 | m_StackTraceTypes: 010000000100000001000000010000000100000001000000 53 | iosShowActivityIndicatorOnLoading: -1 54 | androidShowActivityIndicatorOnLoading: -1 55 | iosAppInBackgroundBehavior: 0 56 | displayResolutionDialog: 1 57 | iosAllowHTTPDownload: 1 58 | allowedAutorotateToPortrait: 1 59 | allowedAutorotateToPortraitUpsideDown: 1 60 | allowedAutorotateToLandscapeRight: 1 61 | allowedAutorotateToLandscapeLeft: 1 62 | useOSAutorotation: 1 63 | use32BitDisplayBuffer: 1 64 | preserveFramebufferAlpha: 0 65 | disableDepthAndStencilBuffers: 0 66 | androidStartInFullscreen: 1 67 | androidRenderOutsideSafeArea: 0 68 | androidBlitType: 0 69 | defaultIsNativeResolution: 1 70 | macRetinaSupport: 1 71 | runInBackground: 0 72 | captureSingleScreen: 0 73 | muteOtherAudioSources: 0 74 | Prepare IOS For Recording: 0 75 | Force IOS Speakers When Recording: 0 76 | deferSystemGesturesMode: 0 77 | hideHomeButton: 0 78 | submitAnalytics: 1 79 | usePlayerLog: 1 80 | bakeCollisionMeshes: 0 81 | forceSingleInstance: 0 82 | resizableWindow: 0 83 | useMacAppStoreValidation: 0 84 | macAppStoreCategory: public.app-category.games 85 | gpuSkinning: 0 86 | graphicsJobs: 0 87 | xboxPIXTextureCapture: 0 88 | xboxEnableAvatar: 0 89 | xboxEnableKinect: 0 90 | xboxEnableKinectAutoTracking: 0 91 | xboxEnableFitness: 0 92 | visibleInBackground: 1 93 | allowFullscreenSwitch: 1 94 | graphicsJobMode: 0 95 | fullscreenMode: 1 96 | xboxSpeechDB: 0 97 | xboxEnableHeadOrientation: 0 98 | xboxEnableGuest: 0 99 | xboxEnablePIXSampling: 0 100 | metalFramebufferOnly: 0 101 | xboxOneResolution: 0 102 | xboxOneSResolution: 0 103 | xboxOneXResolution: 3 104 | xboxOneMonoLoggingLevel: 0 105 | xboxOneLoggingLevel: 1 106 | xboxOneDisableEsram: 0 107 | xboxOnePresentImmediateThreshold: 0 108 | switchQueueCommandMemory: 0 109 | vulkanEnableSetSRGBWrite: 0 110 | m_SupportedAspectRatios: 111 | 4:3: 1 112 | 5:4: 1 113 | 16:10: 1 114 | 16:9: 1 115 | Others: 1 116 | bundleVersion: 1.0 117 | preloadedAssets: [] 118 | metroInputSource: 0 119 | wsaTransparentSwapchain: 0 120 | m_HolographicPauseOnTrackingLoss: 1 121 | xboxOneDisableKinectGpuReservation: 0 122 | xboxOneEnable7thCore: 1 123 | isWsaHolographicRemotingEnabled: 0 124 | vrSettings: 125 | cardboard: 126 | depthFormat: 0 127 | enableTransitionView: 0 128 | daydream: 129 | depthFormat: 0 130 | useSustainedPerformanceMode: 0 131 | enableVideoLayer: 0 132 | useProtectedVideoMemory: 0 133 | minimumSupportedHeadTracking: 0 134 | maximumSupportedHeadTracking: 1 135 | hololens: 136 | depthFormat: 1 137 | depthBufferSharingEnabled: 0 138 | oculus: 139 | sharedDepthBuffer: 1 140 | dashSupport: 1 141 | enable360StereoCapture: 0 142 | protectGraphicsMemory: 0 143 | enableFrameTimingStats: 0 144 | useHDRDisplay: 0 145 | m_ColorGamuts: 00000000 146 | targetPixelDensity: 30 147 | resolutionScalingMode: 0 148 | androidSupportedAspectRatio: 1 149 | androidMaxAspectRatio: 2.1 150 | applicationIdentifier: {} 151 | buildNumber: {} 152 | AndroidBundleVersionCode: 1 153 | AndroidMinSdkVersion: 16 154 | AndroidTargetSdkVersion: 0 155 | AndroidPreferredInstallLocation: 1 156 | aotOptions: 157 | stripEngineCode: 1 158 | iPhoneStrippingLevel: 0 159 | iPhoneScriptCallOptimization: 0 160 | ForceInternetPermission: 0 161 | ForceSDCardPermission: 0 162 | CreateWallpaper: 0 163 | APKExpansionFiles: 0 164 | keepLoadedShadersAlive: 0 165 | StripUnusedMeshComponents: 0 166 | VertexChannelCompressionMask: 4054 167 | iPhoneSdkVersion: 988 168 | iOSTargetOSVersionString: 9.0 169 | tvOSSdkVersion: 0 170 | tvOSRequireExtendedGameController: 0 171 | tvOSTargetOSVersionString: 9.0 172 | uIPrerenderedIcon: 0 173 | uIRequiresPersistentWiFi: 0 174 | uIRequiresFullScreen: 1 175 | uIStatusBarHidden: 1 176 | uIExitOnSuspend: 0 177 | uIStatusBarStyle: 0 178 | iPhoneSplashScreen: {fileID: 0} 179 | iPhoneHighResSplashScreen: {fileID: 0} 180 | iPhoneTallHighResSplashScreen: {fileID: 0} 181 | iPhone47inSplashScreen: {fileID: 0} 182 | iPhone55inPortraitSplashScreen: {fileID: 0} 183 | iPhone55inLandscapeSplashScreen: {fileID: 0} 184 | iPhone58inPortraitSplashScreen: {fileID: 0} 185 | iPhone58inLandscapeSplashScreen: {fileID: 0} 186 | iPadPortraitSplashScreen: {fileID: 0} 187 | iPadHighResPortraitSplashScreen: {fileID: 0} 188 | iPadLandscapeSplashScreen: {fileID: 0} 189 | iPadHighResLandscapeSplashScreen: {fileID: 0} 190 | appleTVSplashScreen: {fileID: 0} 191 | appleTVSplashScreen2x: {fileID: 0} 192 | tvOSSmallIconLayers: [] 193 | tvOSSmallIconLayers2x: [] 194 | tvOSLargeIconLayers: [] 195 | tvOSLargeIconLayers2x: [] 196 | tvOSTopShelfImageLayers: [] 197 | tvOSTopShelfImageLayers2x: [] 198 | tvOSTopShelfImageWideLayers: [] 199 | tvOSTopShelfImageWideLayers2x: [] 200 | iOSLaunchScreenType: 0 201 | iOSLaunchScreenPortrait: {fileID: 0} 202 | iOSLaunchScreenLandscape: {fileID: 0} 203 | iOSLaunchScreenBackgroundColor: 204 | serializedVersion: 2 205 | rgba: 0 206 | iOSLaunchScreenFillPct: 100 207 | iOSLaunchScreenSize: 100 208 | iOSLaunchScreenCustomXibPath: 209 | iOSLaunchScreeniPadType: 0 210 | iOSLaunchScreeniPadImage: {fileID: 0} 211 | iOSLaunchScreeniPadBackgroundColor: 212 | serializedVersion: 2 213 | rgba: 0 214 | iOSLaunchScreeniPadFillPct: 100 215 | iOSLaunchScreeniPadSize: 100 216 | iOSLaunchScreeniPadCustomXibPath: 217 | iOSUseLaunchScreenStoryboard: 0 218 | iOSLaunchScreenCustomStoryboardPath: 219 | iOSDeviceRequirements: [] 220 | iOSURLSchemes: [] 221 | iOSBackgroundModes: 0 222 | iOSMetalForceHardShadows: 0 223 | metalEditorSupport: 1 224 | metalAPIValidation: 1 225 | iOSRenderExtraFrameOnPause: 0 226 | appleDeveloperTeamID: 227 | iOSManualSigningProvisioningProfileID: 228 | tvOSManualSigningProvisioningProfileID: 229 | iOSManualSigningProvisioningProfileType: 0 230 | tvOSManualSigningProvisioningProfileType: 0 231 | appleEnableAutomaticSigning: 0 232 | iOSRequireARKit: 0 233 | appleEnableProMotion: 0 234 | clonedFromGUID: 00000000000000000000000000000000 235 | templatePackageId: 236 | templateDefaultScene: 237 | AndroidTargetArchitectures: 1 238 | AndroidSplashScreenScale: 0 239 | androidSplashScreen: {fileID: 0} 240 | AndroidKeystoreName: 241 | AndroidKeyaliasName: 242 | AndroidBuildApkPerCpuArchitecture: 0 243 | AndroidTVCompatibility: 0 244 | AndroidIsGame: 1 245 | AndroidEnableTango: 0 246 | androidEnableBanner: 1 247 | androidUseLowAccuracyLocation: 0 248 | m_AndroidBanners: 249 | - width: 320 250 | height: 180 251 | banner: {fileID: 0} 252 | androidGamepadSupportLevel: 0 253 | resolutionDialogBanner: {fileID: 0} 254 | m_BuildTargetIcons: [] 255 | m_BuildTargetPlatformIcons: [] 256 | m_BuildTargetBatching: [] 257 | m_BuildTargetGraphicsAPIs: [] 258 | m_BuildTargetVRSettings: [] 259 | m_BuildTargetEnableVuforiaSettings: [] 260 | openGLRequireES31: 0 261 | openGLRequireES31AEP: 0 262 | m_TemplateCustomTags: {} 263 | mobileMTRendering: 264 | Android: 1 265 | iPhone: 1 266 | tvOS: 1 267 | m_BuildTargetGroupLightmapEncodingQuality: [] 268 | m_BuildTargetGroupLightmapSettings: [] 269 | playModeTestRunnerEnabled: 0 270 | runPlayModeTestAsEditModeTest: 0 271 | actionOnDotNetUnhandledException: 1 272 | enableInternalProfiler: 0 273 | logObjCUncaughtExceptions: 1 274 | enableCrashReportAPI: 0 275 | cameraUsageDescription: 276 | locationUsageDescription: 277 | microphoneUsageDescription: 278 | switchNetLibKey: 279 | switchSocketMemoryPoolSize: 6144 280 | switchSocketAllocatorPoolSize: 128 281 | switchSocketConcurrencyLimit: 14 282 | switchScreenResolutionBehavior: 2 283 | switchUseCPUProfiler: 0 284 | switchApplicationID: 0x01004b9000490000 285 | switchNSODependencies: 286 | switchTitleNames_0: 287 | switchTitleNames_1: 288 | switchTitleNames_2: 289 | switchTitleNames_3: 290 | switchTitleNames_4: 291 | switchTitleNames_5: 292 | switchTitleNames_6: 293 | switchTitleNames_7: 294 | switchTitleNames_8: 295 | switchTitleNames_9: 296 | switchTitleNames_10: 297 | switchTitleNames_11: 298 | switchTitleNames_12: 299 | switchTitleNames_13: 300 | switchTitleNames_14: 301 | switchPublisherNames_0: 302 | switchPublisherNames_1: 303 | switchPublisherNames_2: 304 | switchPublisherNames_3: 305 | switchPublisherNames_4: 306 | switchPublisherNames_5: 307 | switchPublisherNames_6: 308 | switchPublisherNames_7: 309 | switchPublisherNames_8: 310 | switchPublisherNames_9: 311 | switchPublisherNames_10: 312 | switchPublisherNames_11: 313 | switchPublisherNames_12: 314 | switchPublisherNames_13: 315 | switchPublisherNames_14: 316 | switchIcons_0: {fileID: 0} 317 | switchIcons_1: {fileID: 0} 318 | switchIcons_2: {fileID: 0} 319 | switchIcons_3: {fileID: 0} 320 | switchIcons_4: {fileID: 0} 321 | switchIcons_5: {fileID: 0} 322 | switchIcons_6: {fileID: 0} 323 | switchIcons_7: {fileID: 0} 324 | switchIcons_8: {fileID: 0} 325 | switchIcons_9: {fileID: 0} 326 | switchIcons_10: {fileID: 0} 327 | switchIcons_11: {fileID: 0} 328 | switchIcons_12: {fileID: 0} 329 | switchIcons_13: {fileID: 0} 330 | switchIcons_14: {fileID: 0} 331 | switchSmallIcons_0: {fileID: 0} 332 | switchSmallIcons_1: {fileID: 0} 333 | switchSmallIcons_2: {fileID: 0} 334 | switchSmallIcons_3: {fileID: 0} 335 | switchSmallIcons_4: {fileID: 0} 336 | switchSmallIcons_5: {fileID: 0} 337 | switchSmallIcons_6: {fileID: 0} 338 | switchSmallIcons_7: {fileID: 0} 339 | switchSmallIcons_8: {fileID: 0} 340 | switchSmallIcons_9: {fileID: 0} 341 | switchSmallIcons_10: {fileID: 0} 342 | switchSmallIcons_11: {fileID: 0} 343 | switchSmallIcons_12: {fileID: 0} 344 | switchSmallIcons_13: {fileID: 0} 345 | switchSmallIcons_14: {fileID: 0} 346 | switchManualHTML: 347 | switchAccessibleURLs: 348 | switchLegalInformation: 349 | switchMainThreadStackSize: 1048576 350 | switchPresenceGroupId: 351 | switchLogoHandling: 0 352 | switchReleaseVersion: 0 353 | switchDisplayVersion: 1.0.0 354 | switchStartupUserAccount: 0 355 | switchTouchScreenUsage: 0 356 | switchSupportedLanguagesMask: 0 357 | switchLogoType: 0 358 | switchApplicationErrorCodeCategory: 359 | switchUserAccountSaveDataSize: 0 360 | switchUserAccountSaveDataJournalSize: 0 361 | switchApplicationAttribute: 0 362 | switchCardSpecSize: -1 363 | switchCardSpecClock: -1 364 | switchRatingsMask: 0 365 | switchRatingsInt_0: 0 366 | switchRatingsInt_1: 0 367 | switchRatingsInt_2: 0 368 | switchRatingsInt_3: 0 369 | switchRatingsInt_4: 0 370 | switchRatingsInt_5: 0 371 | switchRatingsInt_6: 0 372 | switchRatingsInt_7: 0 373 | switchRatingsInt_8: 0 374 | switchRatingsInt_9: 0 375 | switchRatingsInt_10: 0 376 | switchRatingsInt_11: 0 377 | switchLocalCommunicationIds_0: 378 | switchLocalCommunicationIds_1: 379 | switchLocalCommunicationIds_2: 380 | switchLocalCommunicationIds_3: 381 | switchLocalCommunicationIds_4: 382 | switchLocalCommunicationIds_5: 383 | switchLocalCommunicationIds_6: 384 | switchLocalCommunicationIds_7: 385 | switchParentalControl: 0 386 | switchAllowsScreenshot: 1 387 | switchAllowsVideoCapturing: 1 388 | switchAllowsRuntimeAddOnContentInstall: 0 389 | switchDataLossConfirmation: 0 390 | switchUserAccountLockEnabled: 0 391 | switchSupportedNpadStyles: 6 392 | switchNativeFsCacheSize: 32 393 | switchIsHoldTypeHorizontal: 0 394 | switchSupportedNpadCount: 8 395 | switchSocketConfigEnabled: 0 396 | switchTcpInitialSendBufferSize: 32 397 | switchTcpInitialReceiveBufferSize: 64 398 | switchTcpAutoSendBufferSizeMax: 256 399 | switchTcpAutoReceiveBufferSizeMax: 256 400 | switchUdpSendBufferSize: 9 401 | switchUdpReceiveBufferSize: 42 402 | switchSocketBufferEfficiency: 4 403 | switchSocketInitializeEnabled: 1 404 | switchNetworkInterfaceManagerInitializeEnabled: 1 405 | switchPlayerConnectionEnabled: 1 406 | ps4NPAgeRating: 12 407 | ps4NPTitleSecret: 408 | ps4NPTrophyPackPath: 409 | ps4ParentalLevel: 11 410 | ps4ContentID: ED1633-NPXX51362_00-0000000000000000 411 | ps4Category: 0 412 | ps4MasterVersion: 01.00 413 | ps4AppVersion: 01.00 414 | ps4AppType: 0 415 | ps4ParamSfxPath: 416 | ps4VideoOutPixelFormat: 0 417 | ps4VideoOutInitialWidth: 1920 418 | ps4VideoOutBaseModeInitialWidth: 1920 419 | ps4VideoOutReprojectionRate: 60 420 | ps4PronunciationXMLPath: 421 | ps4PronunciationSIGPath: 422 | ps4BackgroundImagePath: 423 | ps4StartupImagePath: 424 | ps4StartupImagesFolder: 425 | ps4IconImagesFolder: 426 | ps4SaveDataImagePath: 427 | ps4SdkOverride: 428 | ps4BGMPath: 429 | ps4ShareFilePath: 430 | ps4ShareOverlayImagePath: 431 | ps4PrivacyGuardImagePath: 432 | ps4NPtitleDatPath: 433 | ps4RemotePlayKeyAssignment: -1 434 | ps4RemotePlayKeyMappingDir: 435 | ps4PlayTogetherPlayerCount: 0 436 | ps4EnterButtonAssignment: 2 437 | ps4ApplicationParam1: 0 438 | ps4ApplicationParam2: 0 439 | ps4ApplicationParam3: 0 440 | ps4ApplicationParam4: 0 441 | ps4DownloadDataSize: 0 442 | ps4GarlicHeapSize: 2048 443 | ps4ProGarlicHeapSize: 2560 444 | ps4Passcode: frAQBc8Wsa1xVPfvJcrgRYwTiizs2trQ 445 | ps4pnSessions: 1 446 | ps4pnPresence: 1 447 | ps4pnFriends: 1 448 | ps4pnGameCustomData: 1 449 | playerPrefsSupport: 0 450 | enableApplicationExit: 0 451 | resetTempFolder: 1 452 | restrictedAudioUsageRights: 0 453 | ps4UseResolutionFallback: 0 454 | ps4ReprojectionSupport: 0 455 | ps4UseAudio3dBackend: 0 456 | ps4SocialScreenEnabled: 0 457 | ps4ScriptOptimizationLevel: 2 458 | ps4Audio3dVirtualSpeakerCount: 14 459 | ps4attribCpuUsage: 0 460 | ps4PatchPkgPath: 461 | ps4PatchLatestPkgPath: 462 | ps4PatchChangeinfoPath: 463 | ps4PatchDayOne: 0 464 | ps4attribUserManagement: 0 465 | ps4attribMoveSupport: 0 466 | ps4attrib3DSupport: 0 467 | ps4attribShareSupport: 0 468 | ps4attribExclusiveVR: 0 469 | ps4disableAutoHideSplash: 0 470 | ps4videoRecordingFeaturesUsed: 0 471 | ps4contentSearchFeaturesUsed: 0 472 | ps4attribEyeToEyeDistanceSettingVR: 0 473 | ps4IncludedModules: [] 474 | monoEnv: 475 | splashScreenBackgroundSourceLandscape: {fileID: 0} 476 | splashScreenBackgroundSourcePortrait: {fileID: 0} 477 | spritePackerPolicy: 478 | webGLMemorySize: 256 479 | webGLExceptionSupport: 1 480 | webGLNameFilesAsHashes: 0 481 | webGLDataCaching: 1 482 | webGLDebugSymbols: 0 483 | webGLEmscriptenArgs: 484 | webGLModulesDirectory: 485 | webGLTemplate: APPLICATION:Default 486 | webGLAnalyzeBuildSize: 0 487 | webGLUseEmbeddedResources: 0 488 | webGLCompressionFormat: 1 489 | webGLLinkerTarget: 1 490 | webGLThreadsSupport: 0 491 | scriptingDefineSymbols: {} 492 | platformArchitecture: {} 493 | scriptingBackend: {} 494 | il2cppCompilerConfiguration: {} 495 | managedStrippingLevel: {} 496 | incrementalIl2cppBuild: {} 497 | allowUnsafeCode: 0 498 | additionalIl2CppArgs: 499 | scriptingRuntimeVersion: 1 500 | apiCompatibilityLevelPerPlatform: {} 501 | m_RenderingPath: 1 502 | m_MobileRenderingPath: 1 503 | metroPackageName: Fluid-Simulation 504 | metroPackageVersion: 505 | metroCertificatePath: 506 | metroCertificatePassword: 507 | metroCertificateSubject: 508 | metroCertificateIssuer: 509 | metroCertificateNotAfter: 0000000000000000 510 | metroApplicationDescription: Fluid-Simulation 511 | wsaImages: {} 512 | metroTileShortName: 513 | metroTileShowName: 0 514 | metroMediumTileShowName: 0 515 | metroLargeTileShowName: 0 516 | metroWideTileShowName: 0 517 | metroSupportStreamingInstall: 0 518 | metroLastRequiredScene: 0 519 | metroDefaultTileSize: 1 520 | metroTileForegroundText: 2 521 | metroTileBackgroundColor: {r: 0.13333334, g: 0.17254902, b: 0.21568628, a: 0} 522 | metroSplashScreenBackgroundColor: {r: 0.12941177, g: 0.17254902, b: 0.21568628, 523 | a: 1} 524 | metroSplashScreenUseBackgroundColor: 0 525 | platformCapabilities: {} 526 | metroTargetDeviceFamilies: {} 527 | metroFTAName: 528 | metroFTAFileTypes: [] 529 | metroProtocolName: 530 | metroCompilationOverrides: 1 531 | XboxOneProductId: 532 | XboxOneUpdateKey: 533 | XboxOneSandboxId: 534 | XboxOneContentId: 535 | XboxOneTitleId: 536 | XboxOneSCId: 537 | XboxOneGameOsOverridePath: 538 | XboxOnePackagingOverridePath: 539 | XboxOneAppManifestOverridePath: 540 | XboxOneVersion: 1.0.0.0 541 | XboxOnePackageEncryption: 0 542 | XboxOnePackageUpdateGranularity: 2 543 | XboxOneDescription: 544 | XboxOneLanguage: 545 | - enus 546 | XboxOneCapability: [] 547 | XboxOneGameRating: {} 548 | XboxOneIsContentPackage: 0 549 | XboxOneEnableGPUVariability: 1 550 | XboxOneSockets: {} 551 | XboxOneSplashScreen: {fileID: 0} 552 | XboxOneAllowedProductIds: [] 553 | XboxOnePersistentLocalStorageSize: 0 554 | XboxOneXTitleMemory: 8 555 | xboxOneScriptCompiler: 0 556 | XboxOneOverrideIdentityName: 557 | vrEditorSettings: 558 | daydream: 559 | daydreamIconForeground: {fileID: 0} 560 | daydreamIconBackground: {fileID: 0} 561 | cloudServicesEnabled: {} 562 | luminIcon: 563 | m_Name: 564 | m_ModelFolderPath: 565 | m_PortalFolderPath: 566 | luminCert: 567 | m_CertPath: 568 | m_PrivateKeyPath: 569 | luminIsChannelApp: 0 570 | luminVersion: 571 | m_VersionCode: 1 572 | m_VersionName: 573 | facebookSdkVersion: 574 | facebookAppId: 575 | facebookCookies: 1 576 | facebookLogging: 1 577 | facebookStatus: 1 578 | facebookXfbml: 0 579 | facebookFrictionlessRequests: 1 580 | apiCompatibilityLevel: 6 581 | cloudProjectId: 582 | framebufferDepthMemorylessMode: 0 583 | projectName: 584 | organizationId: 585 | cloudEnabled: 0 586 | enableNativePlatformBackendsForNewInputSystem: 0 587 | disableOldInputManagerSupport: 0 588 | legacyClampBlendShapeWeights: 0 589 | -------------------------------------------------------------------------------- /ProjectSettings/ProjectVersion.txt: -------------------------------------------------------------------------------- 1 | m_EditorVersion: 2018.3.4f1 2 | -------------------------------------------------------------------------------- /ProjectSettings/QualitySettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!47 &1 4 | QualitySettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 5 7 | m_CurrentQuality: 5 8 | m_QualitySettings: 9 | - serializedVersion: 2 10 | name: Very Low 11 | pixelLightCount: 0 12 | shadows: 0 13 | shadowResolution: 0 14 | shadowProjection: 1 15 | shadowCascades: 1 16 | shadowDistance: 15 17 | shadowNearPlaneOffset: 3 18 | shadowCascade2Split: 0.33333334 19 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 20 | shadowmaskMode: 0 21 | blendWeights: 1 22 | textureQuality: 1 23 | anisotropicTextures: 0 24 | antiAliasing: 0 25 | softParticles: 0 26 | softVegetation: 0 27 | realtimeReflectionProbes: 0 28 | billboardsFaceCameraPosition: 0 29 | vSyncCount: 0 30 | lodBias: 0.3 31 | maximumLODLevel: 0 32 | streamingMipmapsActive: 0 33 | streamingMipmapsAddAllCameras: 1 34 | streamingMipmapsMemoryBudget: 512 35 | streamingMipmapsRenderersPerFrame: 512 36 | streamingMipmapsMaxLevelReduction: 2 37 | streamingMipmapsMaxFileIORequests: 1024 38 | particleRaycastBudget: 4 39 | asyncUploadTimeSlice: 2 40 | asyncUploadBufferSize: 16 41 | asyncUploadPersistentBuffer: 1 42 | resolutionScalingFixedDPIFactor: 1 43 | excludedTargetPlatforms: [] 44 | - serializedVersion: 2 45 | name: Low 46 | pixelLightCount: 0 47 | shadows: 0 48 | shadowResolution: 0 49 | shadowProjection: 1 50 | shadowCascades: 1 51 | shadowDistance: 20 52 | shadowNearPlaneOffset: 3 53 | shadowCascade2Split: 0.33333334 54 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 55 | shadowmaskMode: 0 56 | blendWeights: 2 57 | textureQuality: 0 58 | anisotropicTextures: 0 59 | antiAliasing: 0 60 | softParticles: 0 61 | softVegetation: 0 62 | realtimeReflectionProbes: 0 63 | billboardsFaceCameraPosition: 0 64 | vSyncCount: 0 65 | lodBias: 0.4 66 | maximumLODLevel: 0 67 | streamingMipmapsActive: 0 68 | streamingMipmapsAddAllCameras: 1 69 | streamingMipmapsMemoryBudget: 512 70 | streamingMipmapsRenderersPerFrame: 512 71 | streamingMipmapsMaxLevelReduction: 2 72 | streamingMipmapsMaxFileIORequests: 1024 73 | particleRaycastBudget: 16 74 | asyncUploadTimeSlice: 2 75 | asyncUploadBufferSize: 16 76 | asyncUploadPersistentBuffer: 1 77 | resolutionScalingFixedDPIFactor: 1 78 | excludedTargetPlatforms: [] 79 | - serializedVersion: 2 80 | name: Medium 81 | pixelLightCount: 1 82 | shadows: 1 83 | shadowResolution: 0 84 | shadowProjection: 1 85 | shadowCascades: 1 86 | shadowDistance: 20 87 | shadowNearPlaneOffset: 3 88 | shadowCascade2Split: 0.33333334 89 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 90 | shadowmaskMode: 0 91 | blendWeights: 2 92 | textureQuality: 0 93 | anisotropicTextures: 1 94 | antiAliasing: 0 95 | softParticles: 0 96 | softVegetation: 0 97 | realtimeReflectionProbes: 0 98 | billboardsFaceCameraPosition: 0 99 | vSyncCount: 1 100 | lodBias: 0.7 101 | maximumLODLevel: 0 102 | streamingMipmapsActive: 0 103 | streamingMipmapsAddAllCameras: 1 104 | streamingMipmapsMemoryBudget: 512 105 | streamingMipmapsRenderersPerFrame: 512 106 | streamingMipmapsMaxLevelReduction: 2 107 | streamingMipmapsMaxFileIORequests: 1024 108 | particleRaycastBudget: 64 109 | asyncUploadTimeSlice: 2 110 | asyncUploadBufferSize: 16 111 | asyncUploadPersistentBuffer: 1 112 | resolutionScalingFixedDPIFactor: 1 113 | excludedTargetPlatforms: [] 114 | - serializedVersion: 2 115 | name: High 116 | pixelLightCount: 2 117 | shadows: 2 118 | shadowResolution: 1 119 | shadowProjection: 1 120 | shadowCascades: 2 121 | shadowDistance: 40 122 | shadowNearPlaneOffset: 3 123 | shadowCascade2Split: 0.33333334 124 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 125 | shadowmaskMode: 1 126 | blendWeights: 2 127 | textureQuality: 0 128 | anisotropicTextures: 1 129 | antiAliasing: 0 130 | softParticles: 0 131 | softVegetation: 1 132 | realtimeReflectionProbes: 1 133 | billboardsFaceCameraPosition: 1 134 | vSyncCount: 1 135 | lodBias: 1 136 | maximumLODLevel: 0 137 | streamingMipmapsActive: 0 138 | streamingMipmapsAddAllCameras: 1 139 | streamingMipmapsMemoryBudget: 512 140 | streamingMipmapsRenderersPerFrame: 512 141 | streamingMipmapsMaxLevelReduction: 2 142 | streamingMipmapsMaxFileIORequests: 1024 143 | particleRaycastBudget: 256 144 | asyncUploadTimeSlice: 2 145 | asyncUploadBufferSize: 16 146 | asyncUploadPersistentBuffer: 1 147 | resolutionScalingFixedDPIFactor: 1 148 | excludedTargetPlatforms: [] 149 | - serializedVersion: 2 150 | name: Very High 151 | pixelLightCount: 3 152 | shadows: 2 153 | shadowResolution: 2 154 | shadowProjection: 1 155 | shadowCascades: 2 156 | shadowDistance: 70 157 | shadowNearPlaneOffset: 3 158 | shadowCascade2Split: 0.33333334 159 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 160 | shadowmaskMode: 1 161 | blendWeights: 4 162 | textureQuality: 0 163 | anisotropicTextures: 2 164 | antiAliasing: 2 165 | softParticles: 1 166 | softVegetation: 1 167 | realtimeReflectionProbes: 1 168 | billboardsFaceCameraPosition: 1 169 | vSyncCount: 1 170 | lodBias: 1.5 171 | maximumLODLevel: 0 172 | streamingMipmapsActive: 0 173 | streamingMipmapsAddAllCameras: 1 174 | streamingMipmapsMemoryBudget: 512 175 | streamingMipmapsRenderersPerFrame: 512 176 | streamingMipmapsMaxLevelReduction: 2 177 | streamingMipmapsMaxFileIORequests: 1024 178 | particleRaycastBudget: 1024 179 | asyncUploadTimeSlice: 2 180 | asyncUploadBufferSize: 16 181 | asyncUploadPersistentBuffer: 1 182 | resolutionScalingFixedDPIFactor: 1 183 | excludedTargetPlatforms: [] 184 | - serializedVersion: 2 185 | name: Ultra 186 | pixelLightCount: 4 187 | shadows: 2 188 | shadowResolution: 2 189 | shadowProjection: 1 190 | shadowCascades: 4 191 | shadowDistance: 150 192 | shadowNearPlaneOffset: 3 193 | shadowCascade2Split: 0.33333334 194 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 195 | shadowmaskMode: 1 196 | blendWeights: 4 197 | textureQuality: 0 198 | anisotropicTextures: 2 199 | antiAliasing: 2 200 | softParticles: 1 201 | softVegetation: 1 202 | realtimeReflectionProbes: 1 203 | billboardsFaceCameraPosition: 1 204 | vSyncCount: 1 205 | lodBias: 2 206 | maximumLODLevel: 0 207 | streamingMipmapsActive: 0 208 | streamingMipmapsAddAllCameras: 1 209 | streamingMipmapsMemoryBudget: 512 210 | streamingMipmapsRenderersPerFrame: 512 211 | streamingMipmapsMaxLevelReduction: 2 212 | streamingMipmapsMaxFileIORequests: 1024 213 | particleRaycastBudget: 4096 214 | asyncUploadTimeSlice: 2 215 | asyncUploadBufferSize: 16 216 | asyncUploadPersistentBuffer: 1 217 | resolutionScalingFixedDPIFactor: 1 218 | excludedTargetPlatforms: [] 219 | m_PerPlatformDefaultQuality: 220 | Android: 2 221 | Lumin: 5 222 | Nintendo Switch: 5 223 | PS4: 5 224 | Standalone: 5 225 | WebGL: 3 226 | Windows Store Apps: 5 227 | XboxOne: 5 228 | iPhone: 2 229 | tvOS: 2 230 | -------------------------------------------------------------------------------- /ProjectSettings/TagManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!78 &1 4 | TagManager: 5 | serializedVersion: 2 6 | tags: [] 7 | layers: 8 | - Default 9 | - TransparentFX 10 | - Ignore Raycast 11 | - 12 | - Water 13 | - UI 14 | - 15 | - 16 | - 17 | - 18 | - 19 | - 20 | - 21 | - 22 | - 23 | - 24 | - 25 | - 26 | - 27 | - 28 | - 29 | - 30 | - 31 | - 32 | - 33 | - 34 | - 35 | - 36 | - 37 | - 38 | - 39 | - 40 | m_SortingLayers: 41 | - name: Default 42 | uniqueID: 0 43 | locked: 0 44 | -------------------------------------------------------------------------------- /ProjectSettings/TimeManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!5 &1 4 | TimeManager: 5 | m_ObjectHideFlags: 0 6 | Fixed Timestep: 0.02 7 | Maximum Allowed Timestep: 0.33333334 8 | m_TimeScale: 1 9 | Maximum Particle Timestep: 0.03 10 | -------------------------------------------------------------------------------- /ProjectSettings/UnityConnectSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!310 &1 4 | UnityConnectSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 1 7 | m_Enabled: 1 8 | m_TestMode: 0 9 | m_EventOldUrl: https://api.uca.cloud.unity3d.com/v1/events 10 | m_EventUrl: https://cdp.cloud.unity3d.com/v1/events 11 | m_ConfigUrl: https://config.uca.cloud.unity3d.com 12 | m_TestInitMode: 0 13 | CrashReportingSettings: 14 | m_EventUrl: https://perf-events.cloud.unity3d.com 15 | m_Enabled: 0 16 | m_LogBufferSize: 10 17 | m_CaptureEditorExceptions: 1 18 | UnityPurchasingSettings: 19 | m_Enabled: 0 20 | m_TestMode: 0 21 | UnityAnalyticsSettings: 22 | m_Enabled: 0 23 | m_TestMode: 0 24 | m_InitializeOnStartup: 1 25 | UnityAdsSettings: 26 | m_Enabled: 0 27 | m_InitializeOnStartup: 1 28 | m_TestMode: 0 29 | m_IosGameId: 30 | m_AndroidGameId: 31 | m_GameIds: {} 32 | m_GameId: 33 | PerformanceReportingSettings: 34 | m_Enabled: 0 35 | -------------------------------------------------------------------------------- /ProjectSettings/VFXManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!937362698 &1 4 | VFXManager: 5 | m_ObjectHideFlags: 0 6 | m_IndirectShader: {fileID: 0} 7 | m_CopyBufferShader: {fileID: 0} 8 | m_SortShader: {fileID: 0} 9 | m_RenderPipeSettingsPath: 10 | m_FixedTimeStep: 0.016666668 11 | m_MaxDeltaTime: 0.05 12 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Fluid Simulation 2 | 3 | ![image](img/naG9ADa.jpg) 4 | 5 | I wrote this fluid simulation as a project for an animation and planning course I took in university. 6 | 7 | Read more about it [here](https://danielshervheim.com/coursework/csci-5611/fluid-simulation). 8 | 9 | ## To Use 10 | 11 | - Clone this repository and open it in Unity. 12 | 13 | - Press Play. 14 | 15 | - Right-click and drag to deposit density into the density grid. 16 | 17 | - Left-click and drag to apply forces to the velocity grid. 18 | 19 | - Middle-click to reset both grids. 20 | -------------------------------------------------------------------------------- /img/naG9ADa.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/danielshervheim/unity-fluid-simulation/3ca51848e0f6af4bc75c755137e25715165b9729/img/naG9ADa.jpg --------------------------------------------------------------------------------