├── .gitattributes ├── .gitignore ├── Assets ├── Unity Cache.meta └── Unity Cache │ ├── Examples.meta │ ├── Examples │ ├── Coin.meta │ ├── Coin │ │ ├── Materials.meta │ │ ├── Materials │ │ │ ├── TEX_Coin_Bronze.mat │ │ │ ├── TEX_Coin_Bronze.mat.meta │ │ │ ├── TEX_Coin_Gold.mat │ │ │ ├── TEX_Coin_Gold.mat.meta │ │ │ ├── TEX_Coin_Silver.mat │ │ │ └── TEX_Coin_Silver.mat.meta │ │ ├── Models.meta │ │ ├── Models │ │ │ ├── MSH_Coin.FBX │ │ │ ├── MSH_Coin.FBX.meta │ │ │ ├── Materials.meta │ │ │ └── Materials │ │ │ │ ├── TEX_Coin.mat │ │ │ │ └── TEX_Coin.mat.meta │ │ ├── Textures.meta │ │ └── Textures │ │ │ ├── coin_bronze.png │ │ │ ├── coin_bronze.png.meta │ │ │ ├── coin_gold.png │ │ │ ├── coin_gold.png.meta │ │ │ ├── coin_silver.png │ │ │ └── coin_silver.png.meta │ ├── Prefabs.meta │ ├── Prefabs │ │ ├── Coin Bronze.prefab │ │ ├── Coin Bronze.prefab.meta │ │ ├── Coin Gold.prefab │ │ ├── Coin Gold.prefab.meta │ │ ├── Coin Silver.prefab │ │ └── Coin Silver.prefab.meta │ ├── Scenes.meta │ ├── Scenes │ │ ├── Code Spawner Example.unity │ │ ├── Code Spawner Example.unity.meta │ │ ├── Editor Spawner Example.unity │ │ └── Editor Spawner Example.unity.meta │ ├── Scripts.meta │ └── Scripts │ │ ├── PickableSpawnerExample.cs │ │ └── PickableSpawnerExample.cs.meta │ ├── Scripts.meta │ └── Scripts │ ├── Grygus.meta │ └── Grygus │ ├── Utilities.meta │ └── Utilities │ ├── Pool.meta │ └── Pool │ ├── C.cs │ ├── C.cs.meta │ ├── Cache.cs │ ├── Cache.cs.meta │ ├── CacheInternal.cs │ ├── CacheInternal.cs.meta │ ├── CacheLog.cs │ ├── CacheLog.cs.meta │ ├── CacheRegister.cs │ ├── CacheRegister.cs.meta │ ├── IPool.cs │ ├── IPool.cs.meta │ ├── NoObjectsInPoolException.cs │ ├── NoObjectsInPoolException.cs.meta │ ├── ObjectAlreadyInPoolException.cs │ ├── ObjectAlreadyInPoolException.cs.meta │ ├── Tests.meta │ ├── Tests │ ├── CacheStorageTest.cs │ └── CacheStorageTest.cs.meta │ ├── Unity.meta │ └── Unity │ ├── Editor.meta │ ├── Editor │ ├── UnityPoolDrawer.cs │ ├── UnityPoolDrawer.cs.meta │ ├── UnityStorageDrawer.cs │ ├── UnityStorageDrawer.cs.meta │ ├── UnityStorageLogDrawer.cs │ └── UnityStorageLogDrawer.cs.meta │ ├── UnityPool.cs │ ├── UnityPool.cs.meta │ ├── UnityStorage.cs │ ├── UnityStorage.cs.meta │ ├── UnityStorageLog.cs │ └── UnityStorageLog.cs.meta ├── Docs ├── PoolUML.png ├── UnityStorage.png └── UnityStorageLog.png ├── LICENSE ├── ProjectSettings ├── AudioManager.asset ├── ClusterInputManager.asset ├── DynamicsManager.asset ├── EditorBuildSettings.asset ├── EditorSettings.asset ├── GraphicsSettings.asset ├── InputManager.asset ├── NavMeshAreas.asset ├── NetworkManager.asset ├── Physics2DSettings.asset ├── ProjectSettings.asset ├── ProjectVersion.txt ├── QualitySettings.asset ├── TagManager.asset ├── TimeManager.asset ├── UnityAdsSettings.asset └── UnityConnectSettings.asset ├── README.md └── Tests ├── Properties └── AssemblyInfo.cs ├── Tests.csproj ├── describe_Cache.cs ├── describe_PickableMap.cs └── packages.config /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | [Ll]ibrary/ 2 | [Tt]emp/ 3 | [Oo]bj/ 4 | [Bb]uild/ 5 | [Bb]uilds/ 6 | [Bb]in/ 7 | /Assets/AssetStoreTools* 8 | 9 | # Autogenerated VS/MD/Consulo solution and project files 10 | ExportedObj/ 11 | .consulo/ 12 | #*.csproj 13 | *.unityproj 14 | *.sln 15 | *.suo 16 | *.tmp 17 | *.user 18 | *.userprefs 19 | *.pidb 20 | *.booproj 21 | *.svd 22 | 23 | 24 | # Unity3D generated meta files 25 | *.pidb.meta 26 | 27 | # Unity3D Generated File On Crash Reports 28 | sysinfo.txt 29 | 30 | # Builds 31 | *.apk 32 | *.unitypackage 33 | -------------------------------------------------------------------------------- /Assets/Unity Cache.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 79947374a4f31494882d9a8ce914d679 3 | folderAsset: yes 4 | timeCreated: 1502043588 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 041949581b1644342ba11a81689051db 3 | folderAsset: yes 4 | timeCreated: 1501794045 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9d7c59a8727b39141958289dd1c50f30 3 | folderAsset: yes 4 | timeCreated: 1479679336 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6c0daaf67b292494d802c8daa765c4bb 3 | folderAsset: yes 4 | timeCreated: 1479679348 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials/TEX_Coin_Bronze.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_PrefabParentObject: {fileID: 0} 8 | m_PrefabInternal: {fileID: 0} 9 | m_Name: TEX_Coin_Bronze 10 | m_Shader: {fileID: 10701, guid: 0000000000000000f000000000000000, type: 0} 11 | m_ShaderKeywords: 12 | m_LightmapFlags: 5 13 | m_CustomRenderQueue: -1 14 | stringTagMap: {} 15 | m_SavedProperties: 16 | serializedVersion: 2 17 | m_TexEnvs: 18 | - first: 19 | name: _BumpMap 20 | second: 21 | m_Texture: {fileID: 0} 22 | m_Scale: {x: 1, y: 1} 23 | m_Offset: {x: 0, y: 0} 24 | - first: 25 | name: _DetailAlbedoMap 26 | second: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - first: 31 | name: _DetailMask 32 | second: 33 | m_Texture: {fileID: 0} 34 | m_Scale: {x: 1, y: 1} 35 | m_Offset: {x: 0, y: 0} 36 | - first: 37 | name: _DetailNormalMap 38 | second: 39 | m_Texture: {fileID: 0} 40 | m_Scale: {x: 1, y: 1} 41 | m_Offset: {x: 0, y: 0} 42 | - first: 43 | name: _EmissionMap 44 | second: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - first: 49 | name: _MainTex 50 | second: 51 | m_Texture: {fileID: 2800000, guid: 0584d8244f9e82a419b8766f71a733cd, type: 3} 52 | m_Scale: {x: 1, y: 1} 53 | m_Offset: {x: 0, y: 0} 54 | - first: 55 | name: _MetallicGlossMap 56 | second: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - first: 61 | name: _OcclusionMap 62 | second: 63 | m_Texture: {fileID: 0} 64 | m_Scale: {x: 1, y: 1} 65 | m_Offset: {x: 0, y: 0} 66 | - first: 67 | name: _ParallaxMap 68 | second: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | m_Floats: 73 | - first: 74 | name: _BumpScale 75 | second: 1 76 | - first: 77 | name: _Cutoff 78 | second: 0.5 79 | - first: 80 | name: _DetailNormalMapScale 81 | second: 1 82 | - first: 83 | name: _DstBlend 84 | second: 0 85 | - first: 86 | name: _GlossMapScale 87 | second: 1 88 | - first: 89 | name: _Glossiness 90 | second: 0.5 91 | - first: 92 | name: _GlossyReflections 93 | second: 1 94 | - first: 95 | name: _Metallic 96 | second: 0 97 | - first: 98 | name: _Mode 99 | second: 0 100 | - first: 101 | name: _OcclusionStrength 102 | second: 1 103 | - first: 104 | name: _Parallax 105 | second: 0.02 106 | - first: 107 | name: _SmoothnessTextureChannel 108 | second: 0 109 | - first: 110 | name: _SpecularHighlights 111 | second: 1 112 | - first: 113 | name: _SrcBlend 114 | second: 1 115 | - first: 116 | name: _UVSec 117 | second: 0 118 | - first: 119 | name: _ZWrite 120 | second: 1 121 | m_Colors: 122 | - first: 123 | name: _Color 124 | second: {r: 0.588, g: 0.588, b: 0.588, a: 1} 125 | - first: 126 | name: _EmissionColor 127 | second: {r: 0, g: 0, b: 0, a: 1} 128 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials/TEX_Coin_Bronze.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b2eaa78a9d3274a44a2d415cfde9f0db 3 | timeCreated: 1479679348 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials/TEX_Coin_Gold.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_PrefabParentObject: {fileID: 0} 8 | m_PrefabInternal: {fileID: 0} 9 | m_Name: TEX_Coin_Gold 10 | m_Shader: {fileID: 10701, guid: 0000000000000000f000000000000000, type: 0} 11 | m_ShaderKeywords: 12 | m_LightmapFlags: 5 13 | m_CustomRenderQueue: -1 14 | stringTagMap: {} 15 | m_SavedProperties: 16 | serializedVersion: 2 17 | m_TexEnvs: 18 | - first: 19 | name: _BumpMap 20 | second: 21 | m_Texture: {fileID: 0} 22 | m_Scale: {x: 1, y: 1} 23 | m_Offset: {x: 0, y: 0} 24 | - first: 25 | name: _DetailAlbedoMap 26 | second: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - first: 31 | name: _DetailMask 32 | second: 33 | m_Texture: {fileID: 0} 34 | m_Scale: {x: 1, y: 1} 35 | m_Offset: {x: 0, y: 0} 36 | - first: 37 | name: _DetailNormalMap 38 | second: 39 | m_Texture: {fileID: 0} 40 | m_Scale: {x: 1, y: 1} 41 | m_Offset: {x: 0, y: 0} 42 | - first: 43 | name: _EmissionMap 44 | second: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - first: 49 | name: _MainTex 50 | second: 51 | m_Texture: {fileID: 2800000, guid: b452914bfab4cf046845f62f7cd7ae12, type: 3} 52 | m_Scale: {x: 1, y: 1} 53 | m_Offset: {x: 0, y: 0} 54 | - first: 55 | name: _MetallicGlossMap 56 | second: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - first: 61 | name: _OcclusionMap 62 | second: 63 | m_Texture: {fileID: 0} 64 | m_Scale: {x: 1, y: 1} 65 | m_Offset: {x: 0, y: 0} 66 | - first: 67 | name: _ParallaxMap 68 | second: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | m_Floats: 73 | - first: 74 | name: _BumpScale 75 | second: 1 76 | - first: 77 | name: _Cutoff 78 | second: 0.5 79 | - first: 80 | name: _DetailNormalMapScale 81 | second: 1 82 | - first: 83 | name: _DstBlend 84 | second: 0 85 | - first: 86 | name: _GlossMapScale 87 | second: 1 88 | - first: 89 | name: _Glossiness 90 | second: 0.5 91 | - first: 92 | name: _GlossyReflections 93 | second: 1 94 | - first: 95 | name: _Metallic 96 | second: 0 97 | - first: 98 | name: _Mode 99 | second: 0 100 | - first: 101 | name: _OcclusionStrength 102 | second: 1 103 | - first: 104 | name: _Parallax 105 | second: 0.02 106 | - first: 107 | name: _SmoothnessTextureChannel 108 | second: 0 109 | - first: 110 | name: _SpecularHighlights 111 | second: 1 112 | - first: 113 | name: _SrcBlend 114 | second: 1 115 | - first: 116 | name: _UVSec 117 | second: 0 118 | - first: 119 | name: _ZWrite 120 | second: 1 121 | m_Colors: 122 | - first: 123 | name: _Color 124 | second: {r: 0.588, g: 0.588, b: 0.588, a: 1} 125 | - first: 126 | name: _EmissionColor 127 | second: {r: 0, g: 0, b: 0, a: 1} 128 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials/TEX_Coin_Gold.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7eb7fd6dd919bf54b963b5d7250be2f9 3 | timeCreated: 1479679348 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials/TEX_Coin_Silver.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_PrefabParentObject: {fileID: 0} 8 | m_PrefabInternal: {fileID: 0} 9 | m_Name: TEX_Coin_Silver 10 | m_Shader: {fileID: 10701, guid: 0000000000000000f000000000000000, type: 0} 11 | m_ShaderKeywords: 12 | m_LightmapFlags: 5 13 | m_CustomRenderQueue: -1 14 | stringTagMap: {} 15 | m_SavedProperties: 16 | serializedVersion: 2 17 | m_TexEnvs: 18 | - first: 19 | name: _BumpMap 20 | second: 21 | m_Texture: {fileID: 0} 22 | m_Scale: {x: 1, y: 1} 23 | m_Offset: {x: 0, y: 0} 24 | - first: 25 | name: _DetailAlbedoMap 26 | second: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - first: 31 | name: _DetailMask 32 | second: 33 | m_Texture: {fileID: 0} 34 | m_Scale: {x: 1, y: 1} 35 | m_Offset: {x: 0, y: 0} 36 | - first: 37 | name: _DetailNormalMap 38 | second: 39 | m_Texture: {fileID: 0} 40 | m_Scale: {x: 1, y: 1} 41 | m_Offset: {x: 0, y: 0} 42 | - first: 43 | name: _EmissionMap 44 | second: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - first: 49 | name: _MainTex 50 | second: 51 | m_Texture: {fileID: 2800000, guid: 34fcaf36d19158e4fb5087e9fe0ea076, type: 3} 52 | m_Scale: {x: 1, y: 1} 53 | m_Offset: {x: 0, y: 0} 54 | - first: 55 | name: _MetallicGlossMap 56 | second: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - first: 61 | name: _OcclusionMap 62 | second: 63 | m_Texture: {fileID: 0} 64 | m_Scale: {x: 1, y: 1} 65 | m_Offset: {x: 0, y: 0} 66 | - first: 67 | name: _ParallaxMap 68 | second: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | m_Floats: 73 | - first: 74 | name: _BumpScale 75 | second: 1 76 | - first: 77 | name: _Cutoff 78 | second: 0.5 79 | - first: 80 | name: _DetailNormalMapScale 81 | second: 1 82 | - first: 83 | name: _DstBlend 84 | second: 0 85 | - first: 86 | name: _GlossMapScale 87 | second: 1 88 | - first: 89 | name: _Glossiness 90 | second: 0.5 91 | - first: 92 | name: _GlossyReflections 93 | second: 1 94 | - first: 95 | name: _Metallic 96 | second: 0 97 | - first: 98 | name: _Mode 99 | second: 0 100 | - first: 101 | name: _OcclusionStrength 102 | second: 1 103 | - first: 104 | name: _Parallax 105 | second: 0.02 106 | - first: 107 | name: _SmoothnessTextureChannel 108 | second: 0 109 | - first: 110 | name: _SpecularHighlights 111 | second: 1 112 | - first: 113 | name: _SrcBlend 114 | second: 1 115 | - first: 116 | name: _UVSec 117 | second: 0 118 | - first: 119 | name: _ZWrite 120 | second: 1 121 | m_Colors: 122 | - first: 123 | name: _Color 124 | second: {r: 0.588, g: 0.588, b: 0.588, a: 1} 125 | - first: 126 | name: _EmissionColor 127 | second: {r: 0, g: 0, b: 0, a: 1} 128 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Materials/TEX_Coin_Silver.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6bfaeb2f8a4832941ade1c8f4de43da6 3 | timeCreated: 1479679348 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Models.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3555438a19cdf9e4cbb946bb1a391d3b 3 | folderAsset: yes 4 | timeCreated: 1502036008 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Models/MSH_Coin.FBX.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0b8f172e5f43bcc4eb83c33cd004f795 3 | timeCreated: 1479679348 4 | licenseType: Pro 5 | ModelImporter: 6 | serializedVersion: 19 7 | fileIDToRecycleName: 8 | 100000: //RootNode 9 | 400000: //RootNode 10 | 2300000: //RootNode 11 | 3300000: //RootNode 12 | 4300000: MSH_Coin 13 | 11400000: //RootNode 14 | materials: 15 | importMaterials: 1 16 | materialName: 0 17 | materialSearch: 1 18 | animations: 19 | legacyGenerateAnimations: 4 20 | bakeSimulation: 0 21 | resampleCurves: 1 22 | optimizeGameObjects: 0 23 | motionNodeName: 24 | animationImportErrors: 25 | animationImportWarnings: 26 | animationRetargetingWarnings: 27 | animationDoRetargetingWarnings: 0 28 | animationCompression: 1 29 | animationRotationError: 0.5 30 | animationPositionError: 0.5 31 | animationScaleError: 0.5 32 | animationWrapMode: 0 33 | extraExposedTransformPaths: [] 34 | clipAnimations: [] 35 | isReadable: 1 36 | meshes: 37 | lODScreenPercentages: [] 38 | globalScale: 10 39 | meshCompression: 0 40 | addColliders: 0 41 | importBlendShapes: 1 42 | swapUVChannels: 0 43 | generateSecondaryUV: 0 44 | useFileUnits: 1 45 | optimizeMeshForGPU: 1 46 | keepQuads: 0 47 | weldVertices: 1 48 | secondaryUVAngleDistortion: 8 49 | secondaryUVAreaDistortion: 15.000001 50 | secondaryUVHardAngle: 88 51 | secondaryUVPackMargin: 4 52 | useFileScale: 1 53 | tangentSpace: 54 | normalSmoothAngle: 60 55 | normalImportMode: 0 56 | tangentImportMode: 3 57 | importAnimation: 0 58 | copyAvatar: 0 59 | humanDescription: 60 | human: [] 61 | skeleton: [] 62 | armTwist: 0.5 63 | foreArmTwist: 0.5 64 | upperLegTwist: 0.5 65 | legTwist: 0.5 66 | armStretch: 0.05 67 | legStretch: 0.05 68 | feetSpacing: 0 69 | rootMotionBoneName: 70 | hasTranslationDoF: 0 71 | lastHumanDescriptionAvatarSource: {instanceID: 0} 72 | animationType: 0 73 | humanoidOversampling: 1 74 | additionalBone: 0 75 | userData: 76 | assetBundleName: 77 | assetBundleVariant: 78 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Models/Materials.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a2f77e3af417d394aa44478567268fe6 3 | folderAsset: yes 4 | timeCreated: 1502043596 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Models/Materials/TEX_Coin.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_PrefabParentObject: {fileID: 0} 8 | m_PrefabInternal: {fileID: 0} 9 | m_Name: TEX_Coin 10 | m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} 11 | m_ShaderKeywords: 12 | m_LightmapFlags: 5 13 | m_CustomRenderQueue: -1 14 | stringTagMap: {} 15 | m_SavedProperties: 16 | serializedVersion: 2 17 | m_TexEnvs: 18 | - first: 19 | name: _BumpMap 20 | second: 21 | m_Texture: {fileID: 0} 22 | m_Scale: {x: 1, y: 1} 23 | m_Offset: {x: 0, y: 0} 24 | - first: 25 | name: _DetailAlbedoMap 26 | second: 27 | m_Texture: {fileID: 0} 28 | m_Scale: {x: 1, y: 1} 29 | m_Offset: {x: 0, y: 0} 30 | - first: 31 | name: _DetailMask 32 | second: 33 | m_Texture: {fileID: 0} 34 | m_Scale: {x: 1, y: 1} 35 | m_Offset: {x: 0, y: 0} 36 | - first: 37 | name: _DetailNormalMap 38 | second: 39 | m_Texture: {fileID: 0} 40 | m_Scale: {x: 1, y: 1} 41 | m_Offset: {x: 0, y: 0} 42 | - first: 43 | name: _EmissionMap 44 | second: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - first: 49 | name: _MainTex 50 | second: 51 | m_Texture: {fileID: 0} 52 | m_Scale: {x: 1, y: 1} 53 | m_Offset: {x: 0, y: 0} 54 | - first: 55 | name: _MetallicGlossMap 56 | second: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - first: 61 | name: _OcclusionMap 62 | second: 63 | m_Texture: {fileID: 0} 64 | m_Scale: {x: 1, y: 1} 65 | m_Offset: {x: 0, y: 0} 66 | - first: 67 | name: _ParallaxMap 68 | second: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | m_Floats: 73 | - first: 74 | name: _BumpScale 75 | second: 1 76 | - first: 77 | name: _Cutoff 78 | second: 0.5 79 | - first: 80 | name: _DetailNormalMapScale 81 | second: 1 82 | - first: 83 | name: _DstBlend 84 | second: 0 85 | - first: 86 | name: _GlossMapScale 87 | second: 1 88 | - first: 89 | name: _Glossiness 90 | second: 0.5 91 | - first: 92 | name: _GlossyReflections 93 | second: 1 94 | - first: 95 | name: _Metallic 96 | second: 0 97 | - first: 98 | name: _Mode 99 | second: 0 100 | - first: 101 | name: _OcclusionStrength 102 | second: 1 103 | - first: 104 | name: _Parallax 105 | second: 0.02 106 | - first: 107 | name: _SmoothnessTextureChannel 108 | second: 0 109 | - first: 110 | name: _SpecularHighlights 111 | second: 1 112 | - first: 113 | name: _SrcBlend 114 | second: 1 115 | - first: 116 | name: _UVSec 117 | second: 0 118 | - first: 119 | name: _ZWrite 120 | second: 1 121 | m_Colors: 122 | - first: 123 | name: _Color 124 | second: {r: 0.588, g: 0.588, b: 0.588, a: 1} 125 | - first: 126 | name: _EmissionColor 127 | second: {r: 0, g: 0, b: 0, a: 1} 128 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Models/Materials/TEX_Coin.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0c6688481bed0d641bf454bcae20a615 3 | timeCreated: 1502043596 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9ee841602785d86459bfe63bf26ec271 3 | folderAsset: yes 4 | timeCreated: 1502036000 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures/coin_bronze.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/grygus/Unity-Cache-System/7eebe2b2d9e58579645bedf2de8a53f53edd3c0f/Assets/Unity Cache/Examples/Coin/Textures/coin_bronze.png -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures/coin_bronze.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0584d8244f9e82a419b8766f71a733cd 3 | timeCreated: 1471171481 4 | licenseType: Store 5 | TextureImporter: 6 | fileIDToRecycleName: {} 7 | serializedVersion: 2 8 | mipmaps: 9 | mipMapMode: 0 10 | enableMipMap: 0 11 | linearTexture: 0 12 | correctGamma: 0 13 | fadeOut: 0 14 | borderMipMap: 0 15 | mipMapFadeDistanceStart: 1 16 | mipMapFadeDistanceEnd: 3 17 | bumpmap: 18 | convertToNormalMap: 0 19 | externalNormalMap: 0 20 | heightScale: 0.25 21 | normalMapFilter: 0 22 | isReadable: 0 23 | grayScaleToAlpha: 0 24 | generateCubemap: 0 25 | cubemapConvolution: 0 26 | cubemapConvolutionSteps: 7 27 | cubemapConvolutionExponent: 1.5 28 | seamlessCubemap: 0 29 | textureFormat: -3 30 | maxTextureSize: 1024 31 | textureSettings: 32 | filterMode: 2 33 | aniso: 16 34 | mipBias: -1 35 | wrapMode: 1 36 | nPOTScale: 0 37 | lightmap: 0 38 | rGBM: 0 39 | compressionQuality: 50 40 | allowsAlphaSplitting: 0 41 | spriteMode: 1 42 | spriteExtrude: 1 43 | spriteMeshType: 1 44 | alignment: 0 45 | spritePivot: {x: 0.5, y: 0.5} 46 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 47 | spritePixelsToUnits: 100 48 | alphaIsTransparency: 1 49 | textureType: 8 50 | buildTargetSettings: [] 51 | spriteSheet: 52 | serializedVersion: 2 53 | sprites: [] 54 | outline: [] 55 | spritePackingTag: 56 | userData: 57 | assetBundleName: 58 | assetBundleVariant: 59 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures/coin_gold.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/grygus/Unity-Cache-System/7eebe2b2d9e58579645bedf2de8a53f53edd3c0f/Assets/Unity Cache/Examples/Coin/Textures/coin_gold.png -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures/coin_gold.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b452914bfab4cf046845f62f7cd7ae12 3 | timeCreated: 1471171482 4 | licenseType: Store 5 | TextureImporter: 6 | fileIDToRecycleName: {} 7 | serializedVersion: 2 8 | mipmaps: 9 | mipMapMode: 0 10 | enableMipMap: 0 11 | linearTexture: 0 12 | correctGamma: 0 13 | fadeOut: 0 14 | borderMipMap: 0 15 | mipMapFadeDistanceStart: 1 16 | mipMapFadeDistanceEnd: 3 17 | bumpmap: 18 | convertToNormalMap: 0 19 | externalNormalMap: 0 20 | heightScale: 0.25 21 | normalMapFilter: 0 22 | isReadable: 0 23 | grayScaleToAlpha: 0 24 | generateCubemap: 0 25 | cubemapConvolution: 0 26 | cubemapConvolutionSteps: 7 27 | cubemapConvolutionExponent: 1.5 28 | seamlessCubemap: 0 29 | textureFormat: -3 30 | maxTextureSize: 1024 31 | textureSettings: 32 | filterMode: 2 33 | aniso: 16 34 | mipBias: -1 35 | wrapMode: 1 36 | nPOTScale: 0 37 | lightmap: 0 38 | rGBM: 0 39 | compressionQuality: 50 40 | allowsAlphaSplitting: 0 41 | spriteMode: 1 42 | spriteExtrude: 1 43 | spriteMeshType: 1 44 | alignment: 0 45 | spritePivot: {x: 0.5, y: 0.5} 46 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 47 | spritePixelsToUnits: 100 48 | alphaIsTransparency: 1 49 | textureType: 8 50 | buildTargetSettings: [] 51 | spriteSheet: 52 | serializedVersion: 2 53 | sprites: [] 54 | outline: [] 55 | spritePackingTag: 56 | userData: 57 | assetBundleName: 58 | assetBundleVariant: 59 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures/coin_silver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/grygus/Unity-Cache-System/7eebe2b2d9e58579645bedf2de8a53f53edd3c0f/Assets/Unity Cache/Examples/Coin/Textures/coin_silver.png -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Coin/Textures/coin_silver.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 34fcaf36d19158e4fb5087e9fe0ea076 3 | timeCreated: 1471171481 4 | licenseType: Store 5 | TextureImporter: 6 | fileIDToRecycleName: {} 7 | serializedVersion: 2 8 | mipmaps: 9 | mipMapMode: 0 10 | enableMipMap: 0 11 | linearTexture: 0 12 | correctGamma: 0 13 | fadeOut: 0 14 | borderMipMap: 0 15 | mipMapFadeDistanceStart: 1 16 | mipMapFadeDistanceEnd: 3 17 | bumpmap: 18 | convertToNormalMap: 0 19 | externalNormalMap: 0 20 | heightScale: 0.25 21 | normalMapFilter: 0 22 | isReadable: 0 23 | grayScaleToAlpha: 0 24 | generateCubemap: 0 25 | cubemapConvolution: 0 26 | cubemapConvolutionSteps: 7 27 | cubemapConvolutionExponent: 1.5 28 | seamlessCubemap: 0 29 | textureFormat: -3 30 | maxTextureSize: 1024 31 | textureSettings: 32 | filterMode: 2 33 | aniso: 16 34 | mipBias: -1 35 | wrapMode: 1 36 | nPOTScale: 0 37 | lightmap: 0 38 | rGBM: 0 39 | compressionQuality: 50 40 | allowsAlphaSplitting: 0 41 | spriteMode: 1 42 | spriteExtrude: 1 43 | spriteMeshType: 1 44 | alignment: 0 45 | spritePivot: {x: 0.5, y: 0.5} 46 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 47 | spritePixelsToUnits: 100 48 | alphaIsTransparency: 1 49 | textureType: 8 50 | buildTargetSettings: [] 51 | spriteSheet: 52 | serializedVersion: 2 53 | sprites: [] 54 | outline: [] 55 | spritePackingTag: 56 | userData: 57 | assetBundleName: 58 | assetBundleVariant: 59 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0950027a430b3c046ba7907aac2777eb 3 | folderAsset: yes 4 | timeCreated: 1502035771 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs/Coin Bronze.prefab: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1001 &100100000 4 | Prefab: 5 | m_ObjectHideFlags: 1 6 | serializedVersion: 2 7 | m_Modification: 8 | m_TransformParent: {fileID: 0} 9 | m_Modifications: [] 10 | m_RemovedComponents: [] 11 | m_ParentPrefab: {fileID: 0} 12 | m_RootGameObject: {fileID: 1000011078001962} 13 | m_IsPrefabParent: 1 14 | --- !u!1 &1000011078001962 15 | GameObject: 16 | m_ObjectHideFlags: 0 17 | m_PrefabParentObject: {fileID: 0} 18 | m_PrefabInternal: {fileID: 100100000} 19 | serializedVersion: 4 20 | m_Component: 21 | - 4: {fileID: 4000013792346898} 22 | - 33: {fileID: 33000010038850630} 23 | - 23: {fileID: 23000010894772098} 24 | - 114: {fileID: 114000010213971602} 25 | m_Layer: 0 26 | m_Name: Coin Bronze 27 | m_TagString: Untagged 28 | m_Icon: {fileID: 0} 29 | m_NavMeshLayer: 0 30 | m_StaticEditorFlags: 0 31 | m_IsActive: 1 32 | --- !u!4 &4000013792346898 33 | Transform: 34 | m_ObjectHideFlags: 1 35 | m_PrefabParentObject: {fileID: 0} 36 | m_PrefabInternal: {fileID: 100100000} 37 | m_GameObject: {fileID: 1000011078001962} 38 | m_LocalRotation: {x: 1.7112914e-15, y: 1, z: -0.000000021855694, w: 0.0000000754979} 39 | m_LocalPosition: {x: 0, y: 0, z: 0} 40 | m_LocalScale: {x: 1, y: 1, z: 1} 41 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 42 | m_Children: [] 43 | m_Father: {fileID: 0} 44 | m_RootOrder: 0 45 | --- !u!23 &23000010894772098 46 | MeshRenderer: 47 | m_ObjectHideFlags: 1 48 | m_PrefabParentObject: {fileID: 0} 49 | m_PrefabInternal: {fileID: 100100000} 50 | m_GameObject: {fileID: 1000011078001962} 51 | m_Enabled: 1 52 | m_CastShadows: 1 53 | m_ReceiveShadows: 1 54 | m_MotionVectors: 1 55 | m_LightProbeUsage: 1 56 | m_ReflectionProbeUsage: 1 57 | m_Materials: 58 | - {fileID: 2100000, guid: b2eaa78a9d3274a44a2d415cfde9f0db, type: 2} 59 | m_SubsetIndices: 60 | m_StaticBatchRoot: {fileID: 0} 61 | m_ProbeAnchor: {fileID: 0} 62 | m_LightProbeVolumeOverride: {fileID: 0} 63 | m_ScaleInLightmap: 1 64 | m_PreserveUVs: 0 65 | m_IgnoreNormalsForChartDetection: 0 66 | m_ImportantGI: 0 67 | m_SelectedWireframeHidden: 0 68 | m_MinimumChartSize: 4 69 | m_AutoUVMaxDistance: 0.5 70 | m_AutoUVMaxAngle: 89 71 | m_LightmapParameters: {fileID: 0} 72 | m_SortingLayerID: 0 73 | m_SortingOrder: 0 74 | --- !u!33 &33000010038850630 75 | MeshFilter: 76 | m_ObjectHideFlags: 1 77 | m_PrefabParentObject: {fileID: 0} 78 | m_PrefabInternal: {fileID: 100100000} 79 | m_GameObject: {fileID: 1000011078001962} 80 | m_Mesh: {fileID: 4300000, guid: 0b8f172e5f43bcc4eb83c33cd004f795, type: 3} 81 | --- !u!114 &114000010213971602 82 | MonoBehaviour: 83 | m_ObjectHideFlags: 33 84 | m_PrefabParentObject: {fileID: 0} 85 | m_PrefabInternal: {fileID: 100100000} 86 | m_GameObject: {fileID: 1000011078001962} 87 | m_Enabled: 1 88 | m_EditorHideFlags: 0 89 | m_Script: {fileID: 11500000, guid: 46a02d0f612a241b293c0da4f82b712c, type: 3} 90 | m_Name: 91 | m_EditorClassIdentifier: 92 | Properties: 93 | Properties: [] 94 | Groups: [] 95 | Hidden: 96 | Links: 97 | Links: 98 | - LIIF: 1346582609 99 | InstanceTarget: {fileID: 114000010213971602} 100 | - LIIF: -1863392894 101 | InstanceTarget: {fileID: 23000010894772098} 102 | - LIIF: -626934547 103 | InstanceTarget: {fileID: 33000010038850630} 104 | - LIIF: -765337030 105 | InstanceTarget: {fileID: 4000013792346898} 106 | - LIIF: -233967762 107 | InstanceTarget: {fileID: 1000011078001962} 108 | Modifications: 109 | Modificated: [] 110 | NonPrefabObjects: [] 111 | NonPrefabComponents: [] 112 | RemovedObjects: 113 | TransformParentChanges: [] 114 | ParentPrefabGUID: 115 | PrefabGUID: 3239363466376637303933373238313433613564653437646639626165366639 116 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs/Coin Bronze.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2964f7f7093728143a5de47df9bae6f9 3 | timeCreated: 1486684597 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: HaveNested_false 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs/Coin Gold.prefab: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1001 &100100000 4 | Prefab: 5 | m_ObjectHideFlags: 1 6 | serializedVersion: 2 7 | m_Modification: 8 | m_TransformParent: {fileID: 0} 9 | m_Modifications: [] 10 | m_RemovedComponents: [] 11 | m_ParentPrefab: {fileID: 0} 12 | m_RootGameObject: {fileID: 1000011078001962} 13 | m_IsPrefabParent: 1 14 | --- !u!1 &1000011078001962 15 | GameObject: 16 | m_ObjectHideFlags: 0 17 | m_PrefabParentObject: {fileID: 0} 18 | m_PrefabInternal: {fileID: 100100000} 19 | serializedVersion: 4 20 | m_Component: 21 | - 4: {fileID: 4000013792346898} 22 | - 33: {fileID: 33000010038850630} 23 | - 23: {fileID: 23000010894772098} 24 | - 114: {fileID: 114000010213971602} 25 | m_Layer: 0 26 | m_Name: Coin Gold 27 | m_TagString: Untagged 28 | m_Icon: {fileID: 0} 29 | m_NavMeshLayer: 0 30 | m_StaticEditorFlags: 0 31 | m_IsActive: 1 32 | --- !u!4 &4000013792346898 33 | Transform: 34 | m_ObjectHideFlags: 1 35 | m_PrefabParentObject: {fileID: 0} 36 | m_PrefabInternal: {fileID: 100100000} 37 | m_GameObject: {fileID: 1000011078001962} 38 | m_LocalRotation: {x: 1.7112914e-15, y: 1, z: -0.000000021855694, w: 0.0000000754979} 39 | m_LocalPosition: {x: 0, y: 0, z: 0} 40 | m_LocalScale: {x: 1, y: 1, z: 1} 41 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 42 | m_Children: [] 43 | m_Father: {fileID: 0} 44 | m_RootOrder: 0 45 | --- !u!23 &23000010894772098 46 | MeshRenderer: 47 | m_ObjectHideFlags: 1 48 | m_PrefabParentObject: {fileID: 0} 49 | m_PrefabInternal: {fileID: 100100000} 50 | m_GameObject: {fileID: 1000011078001962} 51 | m_Enabled: 1 52 | m_CastShadows: 1 53 | m_ReceiveShadows: 1 54 | m_MotionVectors: 1 55 | m_LightProbeUsage: 1 56 | m_ReflectionProbeUsage: 1 57 | m_Materials: 58 | - {fileID: 2100000, guid: 7eb7fd6dd919bf54b963b5d7250be2f9, type: 2} 59 | m_SubsetIndices: 60 | m_StaticBatchRoot: {fileID: 0} 61 | m_ProbeAnchor: {fileID: 0} 62 | m_LightProbeVolumeOverride: {fileID: 0} 63 | m_ScaleInLightmap: 1 64 | m_PreserveUVs: 0 65 | m_IgnoreNormalsForChartDetection: 0 66 | m_ImportantGI: 0 67 | m_SelectedWireframeHidden: 0 68 | m_MinimumChartSize: 4 69 | m_AutoUVMaxDistance: 0.5 70 | m_AutoUVMaxAngle: 89 71 | m_LightmapParameters: {fileID: 0} 72 | m_SortingLayerID: 0 73 | m_SortingOrder: 0 74 | --- !u!33 &33000010038850630 75 | MeshFilter: 76 | m_ObjectHideFlags: 1 77 | m_PrefabParentObject: {fileID: 0} 78 | m_PrefabInternal: {fileID: 100100000} 79 | m_GameObject: {fileID: 1000011078001962} 80 | m_Mesh: {fileID: 4300000, guid: 0b8f172e5f43bcc4eb83c33cd004f795, type: 3} 81 | --- !u!114 &114000010213971602 82 | MonoBehaviour: 83 | m_ObjectHideFlags: 33 84 | m_PrefabParentObject: {fileID: 0} 85 | m_PrefabInternal: {fileID: 100100000} 86 | m_GameObject: {fileID: 1000011078001962} 87 | m_Enabled: 1 88 | m_EditorHideFlags: 0 89 | m_Script: {fileID: 11500000, guid: 46a02d0f612a241b293c0da4f82b712c, type: 3} 90 | m_Name: 91 | m_EditorClassIdentifier: 92 | Properties: 93 | Properties: [] 94 | Groups: [] 95 | Hidden: 96 | Links: 97 | Links: 98 | - LIIF: 1346582609 99 | InstanceTarget: {fileID: 114000010213971602} 100 | - LIIF: -1863392894 101 | InstanceTarget: {fileID: 23000010894772098} 102 | - LIIF: -626934547 103 | InstanceTarget: {fileID: 33000010038850630} 104 | - LIIF: -765337030 105 | InstanceTarget: {fileID: 4000013792346898} 106 | - LIIF: -233967762 107 | InstanceTarget: {fileID: 1000011078001962} 108 | Modifications: 109 | Modificated: [] 110 | NonPrefabObjects: [] 111 | NonPrefabComponents: [] 112 | RemovedObjects: 113 | TransformParentChanges: [] 114 | ParentPrefabGUID: 115 | PrefabGUID: 3161353938613133363363303661623431393932333431333765383134326466 116 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs/Coin Gold.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1a598a1363c06ab4199234137e8142df 3 | timeCreated: 1486684597 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: HaveNested_false 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs/Coin Silver.prefab: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1001 &100100000 4 | Prefab: 5 | m_ObjectHideFlags: 1 6 | serializedVersion: 2 7 | m_Modification: 8 | m_TransformParent: {fileID: 0} 9 | m_Modifications: [] 10 | m_RemovedComponents: [] 11 | m_ParentPrefab: {fileID: 0} 12 | m_RootGameObject: {fileID: 1000011078001962} 13 | m_IsPrefabParent: 1 14 | --- !u!1 &1000011078001962 15 | GameObject: 16 | m_ObjectHideFlags: 0 17 | m_PrefabParentObject: {fileID: 0} 18 | m_PrefabInternal: {fileID: 100100000} 19 | serializedVersion: 4 20 | m_Component: 21 | - 4: {fileID: 4000013792346898} 22 | - 33: {fileID: 33000010038850630} 23 | - 23: {fileID: 23000010894772098} 24 | - 114: {fileID: 114000010213971602} 25 | m_Layer: 0 26 | m_Name: Coin Silver 27 | m_TagString: Untagged 28 | m_Icon: {fileID: 0} 29 | m_NavMeshLayer: 0 30 | m_StaticEditorFlags: 0 31 | m_IsActive: 1 32 | --- !u!4 &4000013792346898 33 | Transform: 34 | m_ObjectHideFlags: 1 35 | m_PrefabParentObject: {fileID: 0} 36 | m_PrefabInternal: {fileID: 100100000} 37 | m_GameObject: {fileID: 1000011078001962} 38 | m_LocalRotation: {x: 1.7112914e-15, y: 1, z: -0.000000021855694, w: 0.0000000754979} 39 | m_LocalPosition: {x: 0, y: 0, z: 0} 40 | m_LocalScale: {x: 1, y: 1, z: 1} 41 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 42 | m_Children: [] 43 | m_Father: {fileID: 0} 44 | m_RootOrder: 0 45 | --- !u!23 &23000010894772098 46 | MeshRenderer: 47 | m_ObjectHideFlags: 1 48 | m_PrefabParentObject: {fileID: 0} 49 | m_PrefabInternal: {fileID: 100100000} 50 | m_GameObject: {fileID: 1000011078001962} 51 | m_Enabled: 1 52 | m_CastShadows: 1 53 | m_ReceiveShadows: 1 54 | m_MotionVectors: 1 55 | m_LightProbeUsage: 1 56 | m_ReflectionProbeUsage: 1 57 | m_Materials: 58 | - {fileID: 2100000, guid: 6bfaeb2f8a4832941ade1c8f4de43da6, type: 2} 59 | m_SubsetIndices: 60 | m_StaticBatchRoot: {fileID: 0} 61 | m_ProbeAnchor: {fileID: 0} 62 | m_LightProbeVolumeOverride: {fileID: 0} 63 | m_ScaleInLightmap: 1 64 | m_PreserveUVs: 0 65 | m_IgnoreNormalsForChartDetection: 0 66 | m_ImportantGI: 0 67 | m_SelectedWireframeHidden: 0 68 | m_MinimumChartSize: 4 69 | m_AutoUVMaxDistance: 0.5 70 | m_AutoUVMaxAngle: 89 71 | m_LightmapParameters: {fileID: 0} 72 | m_SortingLayerID: 0 73 | m_SortingOrder: 0 74 | --- !u!33 &33000010038850630 75 | MeshFilter: 76 | m_ObjectHideFlags: 1 77 | m_PrefabParentObject: {fileID: 0} 78 | m_PrefabInternal: {fileID: 100100000} 79 | m_GameObject: {fileID: 1000011078001962} 80 | m_Mesh: {fileID: 4300000, guid: 0b8f172e5f43bcc4eb83c33cd004f795, type: 3} 81 | --- !u!114 &114000010213971602 82 | MonoBehaviour: 83 | m_ObjectHideFlags: 33 84 | m_PrefabParentObject: {fileID: 0} 85 | m_PrefabInternal: {fileID: 100100000} 86 | m_GameObject: {fileID: 1000011078001962} 87 | m_Enabled: 1 88 | m_EditorHideFlags: 0 89 | m_Script: {fileID: 11500000, guid: 46a02d0f612a241b293c0da4f82b712c, type: 3} 90 | m_Name: 91 | m_EditorClassIdentifier: 92 | Properties: 93 | Properties: [] 94 | Groups: [] 95 | Hidden: 96 | Links: 97 | Links: 98 | - LIIF: 1346582609 99 | InstanceTarget: {fileID: 114000010213971602} 100 | - LIIF: -1863392894 101 | InstanceTarget: {fileID: 23000010894772098} 102 | - LIIF: -626934547 103 | InstanceTarget: {fileID: 33000010038850630} 104 | - LIIF: -765337030 105 | InstanceTarget: {fileID: 4000013792346898} 106 | - LIIF: -233967762 107 | InstanceTarget: {fileID: 1000011078001962} 108 | Modifications: 109 | Modificated: [] 110 | NonPrefabObjects: [] 111 | NonPrefabComponents: [] 112 | RemovedObjects: 113 | TransformParentChanges: [] 114 | ParentPrefabGUID: 115 | PrefabGUID: 3732333361366264663932636537343431383865306338396632633063383931 116 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Prefabs/Coin Silver.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7233a6bdf92ce744188e0c89f2c0c891 3 | timeCreated: 1486684597 4 | licenseType: Pro 5 | NativeFormatImporter: 6 | userData: HaveNested_false 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scenes.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 06410d6b5520af642b7aea4a5a6014d7 3 | folderAsset: yes 4 | timeCreated: 1501794139 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scenes/Code Spawner Example.unity: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!29 &1 4 | SceneSettings: 5 | m_ObjectHideFlags: 0 6 | m_PVSData: 7 | m_PVSObjectsArray: [] 8 | m_PVSPortalsArray: [] 9 | m_OcclusionBakeSettings: 10 | smallestOccluder: 5 11 | smallestHole: 0.25 12 | backfaceThreshold: 100 13 | --- !u!104 &2 14 | RenderSettings: 15 | m_ObjectHideFlags: 0 16 | serializedVersion: 7 17 | m_Fog: 0 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_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0} 29 | m_HaloStrength: 0.5 30 | m_FlareStrength: 1 31 | m_FlareFadeSpeed: 3 32 | m_HaloTexture: {fileID: 0} 33 | m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} 34 | m_DefaultReflectionMode: 0 35 | m_DefaultReflectionResolution: 128 36 | m_ReflectionBounces: 1 37 | m_ReflectionIntensity: 1 38 | m_CustomReflection: {fileID: 0} 39 | m_Sun: {fileID: 0} 40 | m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1} 41 | --- !u!157 &3 42 | LightmapSettings: 43 | m_ObjectHideFlags: 0 44 | serializedVersion: 7 45 | m_GIWorkflowMode: 0 46 | m_GISettings: 47 | serializedVersion: 2 48 | m_BounceScale: 1 49 | m_IndirectOutputScale: 1 50 | m_AlbedoBoost: 1 51 | m_TemporalCoherenceThreshold: 1 52 | m_EnvironmentLightingMode: 0 53 | m_EnableBakedLightmaps: 1 54 | m_EnableRealtimeLightmaps: 1 55 | m_LightmapEditorSettings: 56 | serializedVersion: 4 57 | m_Resolution: 2 58 | m_BakeResolution: 40 59 | m_TextureWidth: 1024 60 | m_TextureHeight: 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_DirectLightInLightProbes: 1 70 | m_FinalGather: 0 71 | m_FinalGatherFiltering: 1 72 | m_FinalGatherRayCount: 256 73 | m_ReflectionCompression: 2 74 | m_LightingDataAsset: {fileID: 0} 75 | m_RuntimeCPUUsage: 25 76 | --- !u!196 &4 77 | NavMeshSettings: 78 | serializedVersion: 2 79 | m_ObjectHideFlags: 0 80 | m_BuildSettings: 81 | serializedVersion: 2 82 | agentRadius: 0.5 83 | agentHeight: 2 84 | agentSlope: 45 85 | agentClimb: 0.4 86 | ledgeDropHeight: 0 87 | maxJumpAcrossDistance: 0 88 | accuratePlacement: 0 89 | minRegionArea: 2 90 | cellSize: 0.16666667 91 | manualCellSize: 0 92 | m_NavMeshData: {fileID: 0} 93 | --- !u!1 &273914666 94 | GameObject: 95 | m_ObjectHideFlags: 0 96 | m_PrefabParentObject: {fileID: 0} 97 | m_PrefabInternal: {fileID: 0} 98 | serializedVersion: 4 99 | m_Component: 100 | - 4: {fileID: 273914667} 101 | - 114: {fileID: 273914668} 102 | m_Layer: 0 103 | m_Name: Spawner_1 104 | m_TagString: Untagged 105 | m_Icon: {fileID: 0} 106 | m_NavMeshLayer: 0 107 | m_StaticEditorFlags: 0 108 | m_IsActive: 1 109 | --- !u!4 &273914667 110 | Transform: 111 | m_ObjectHideFlags: 0 112 | m_PrefabParentObject: {fileID: 0} 113 | m_PrefabInternal: {fileID: 0} 114 | m_GameObject: {fileID: 273914666} 115 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 116 | m_LocalPosition: {x: -1, y: 0, z: 0} 117 | m_LocalScale: {x: 1, y: 1, z: 1} 118 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 119 | m_Children: [] 120 | m_Father: {fileID: 1271577311} 121 | m_RootOrder: 0 122 | --- !u!114 &273914668 123 | MonoBehaviour: 124 | m_ObjectHideFlags: 0 125 | m_PrefabParentObject: {fileID: 0} 126 | m_PrefabInternal: {fileID: 0} 127 | m_GameObject: {fileID: 273914666} 128 | m_Enabled: 1 129 | m_EditorHideFlags: 0 130 | m_Script: {fileID: 11500000, guid: 0ac74b31fa1014848bc3d90c27d4de5e, type: 3} 131 | m_Name: 132 | m_EditorClassIdentifier: 133 | _prefab: {fileID: 1000011078001962, guid: 1a598a1363c06ab4199234137e8142df, type: 2} 134 | _spawnDistance: 0.5 135 | _spawnDelay: 0.5 136 | _maxSpawned: 10 137 | _maxDistance: 20 138 | _spawnRatio: 139 | serializedVersion: 2 140 | m_Curve: 141 | - time: 0 142 | value: 0 143 | inSlope: 2 144 | outSlope: 2 145 | tangentMode: 0 146 | - time: 0.5 147 | value: 1 148 | inSlope: -0.024288893 149 | outSlope: -0.024288893 150 | tangentMode: 0 151 | - time: 0.62886137 152 | value: 0.381597 153 | inSlope: -3.517252 154 | outSlope: -3.517252 155 | tangentMode: 0 156 | - time: 1 157 | value: 0 158 | inSlope: -2.5136027 159 | outSlope: -2.5136027 160 | tangentMode: 0 161 | m_PreInfinity: 2 162 | m_PostInfinity: 2 163 | m_RotationOrder: 0 164 | _ratioTimer: 0 165 | _ratioMaxTime: 2 166 | _eSpawner: 0 167 | _circleRadius: 0 168 | _clampDistanceToCircle: 0 169 | CachePool: 170 | Name: 171 | Prefab: {fileID: 0} 172 | AllowExpand: 0 173 | AllowRecycle: 0 174 | Size: 0 175 | --- !u!1 &423445623 176 | GameObject: 177 | m_ObjectHideFlags: 0 178 | m_PrefabParentObject: {fileID: 0} 179 | m_PrefabInternal: {fileID: 0} 180 | serializedVersion: 4 181 | m_Component: 182 | - 4: {fileID: 423445625} 183 | - 108: {fileID: 423445624} 184 | m_Layer: 0 185 | m_Name: Directional Light 186 | m_TagString: Untagged 187 | m_Icon: {fileID: 0} 188 | m_NavMeshLayer: 0 189 | m_StaticEditorFlags: 0 190 | m_IsActive: 1 191 | --- !u!108 &423445624 192 | Light: 193 | m_ObjectHideFlags: 0 194 | m_PrefabParentObject: {fileID: 0} 195 | m_PrefabInternal: {fileID: 0} 196 | m_GameObject: {fileID: 423445623} 197 | m_Enabled: 1 198 | serializedVersion: 7 199 | m_Type: 1 200 | m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1} 201 | m_Intensity: 1 202 | m_Range: 10 203 | m_SpotAngle: 30 204 | m_CookieSize: 10 205 | m_Shadows: 206 | m_Type: 2 207 | m_Resolution: -1 208 | m_CustomResolution: -1 209 | m_Strength: 1 210 | m_Bias: 0.05 211 | m_NormalBias: 0.4 212 | m_NearPlane: 0.2 213 | m_Cookie: {fileID: 0} 214 | m_DrawHalo: 0 215 | m_Flare: {fileID: 0} 216 | m_RenderMode: 0 217 | m_CullingMask: 218 | serializedVersion: 2 219 | m_Bits: 4294967295 220 | m_Lightmapping: 4 221 | m_AreaSize: {x: 1, y: 1} 222 | m_BounceIntensity: 1 223 | m_ShadowRadius: 0 224 | m_ShadowAngle: 0 225 | --- !u!4 &423445625 226 | Transform: 227 | m_ObjectHideFlags: 0 228 | m_PrefabParentObject: {fileID: 0} 229 | m_PrefabInternal: {fileID: 0} 230 | m_GameObject: {fileID: 423445623} 231 | m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261} 232 | m_LocalPosition: {x: 0, y: 3, z: 0} 233 | m_LocalScale: {x: 1, y: 1, z: 1} 234 | m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0} 235 | m_Children: [] 236 | m_Father: {fileID: 0} 237 | m_RootOrder: 1 238 | --- !u!1 &1011166715 239 | GameObject: 240 | m_ObjectHideFlags: 0 241 | m_PrefabParentObject: {fileID: 0} 242 | m_PrefabInternal: {fileID: 0} 243 | serializedVersion: 4 244 | m_Component: 245 | - 4: {fileID: 1011166716} 246 | - 114: {fileID: 1011166717} 247 | m_Layer: 0 248 | m_Name: Spawner_2 249 | m_TagString: Untagged 250 | m_Icon: {fileID: 0} 251 | m_NavMeshLayer: 0 252 | m_StaticEditorFlags: 0 253 | m_IsActive: 1 254 | --- !u!4 &1011166716 255 | Transform: 256 | m_ObjectHideFlags: 0 257 | m_PrefabParentObject: {fileID: 0} 258 | m_PrefabInternal: {fileID: 0} 259 | m_GameObject: {fileID: 1011166715} 260 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 261 | m_LocalPosition: {x: 0, y: 0, z: 0} 262 | m_LocalScale: {x: 1, y: 1, z: 1} 263 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 264 | m_Children: [] 265 | m_Father: {fileID: 1271577311} 266 | m_RootOrder: 1 267 | --- !u!114 &1011166717 268 | MonoBehaviour: 269 | m_ObjectHideFlags: 0 270 | m_PrefabParentObject: {fileID: 0} 271 | m_PrefabInternal: {fileID: 0} 272 | m_GameObject: {fileID: 1011166715} 273 | m_Enabled: 1 274 | m_EditorHideFlags: 0 275 | m_Script: {fileID: 11500000, guid: 0ac74b31fa1014848bc3d90c27d4de5e, type: 3} 276 | m_Name: 277 | m_EditorClassIdentifier: 278 | _prefab: {fileID: 1000011078001962, guid: 7233a6bdf92ce744188e0c89f2c0c891, type: 2} 279 | _spawnDistance: 0.5 280 | _spawnDelay: 0.5 281 | _maxSpawned: 20 282 | _maxDistance: 20 283 | _spawnRatio: 284 | serializedVersion: 2 285 | m_Curve: 286 | - time: 0 287 | value: 0 288 | inSlope: 8.569173 289 | outSlope: 8.569173 290 | tangentMode: 0 291 | - time: 0.12188322 292 | value: 0.7082909 293 | inSlope: 2.1111596 294 | outSlope: 2.1111596 295 | tangentMode: 0 296 | - time: 0.5 297 | value: 1 298 | inSlope: -0.024288893 299 | outSlope: -0.024288893 300 | tangentMode: 0 301 | - time: 1 302 | value: 0 303 | inSlope: -0.23906747 304 | outSlope: -0.23906747 305 | tangentMode: 0 306 | m_PreInfinity: 2 307 | m_PostInfinity: 2 308 | m_RotationOrder: 0 309 | _ratioTimer: 0 310 | _ratioMaxTime: 2 311 | _eSpawner: 0 312 | _circleRadius: 0 313 | _clampDistanceToCircle: 0 314 | CachePool: 315 | Name: 316 | Prefab: {fileID: 0} 317 | AllowExpand: 0 318 | AllowRecycle: 0 319 | Size: 0 320 | --- !u!1 &1203234105 321 | GameObject: 322 | m_ObjectHideFlags: 0 323 | m_PrefabParentObject: {fileID: 0} 324 | m_PrefabInternal: {fileID: 0} 325 | serializedVersion: 4 326 | m_Component: 327 | - 4: {fileID: 1203234106} 328 | - 114: {fileID: 1203234107} 329 | m_Layer: 0 330 | m_Name: Spawner_3 331 | m_TagString: Untagged 332 | m_Icon: {fileID: 0} 333 | m_NavMeshLayer: 0 334 | m_StaticEditorFlags: 0 335 | m_IsActive: 1 336 | --- !u!4 &1203234106 337 | Transform: 338 | m_ObjectHideFlags: 0 339 | m_PrefabParentObject: {fileID: 0} 340 | m_PrefabInternal: {fileID: 0} 341 | m_GameObject: {fileID: 1203234105} 342 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 343 | m_LocalPosition: {x: 1, y: 0, z: 0} 344 | m_LocalScale: {x: 1, y: 1, z: 1} 345 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 346 | m_Children: [] 347 | m_Father: {fileID: 1271577311} 348 | m_RootOrder: 2 349 | --- !u!114 &1203234107 350 | MonoBehaviour: 351 | m_ObjectHideFlags: 0 352 | m_PrefabParentObject: {fileID: 0} 353 | m_PrefabInternal: {fileID: 0} 354 | m_GameObject: {fileID: 1203234105} 355 | m_Enabled: 1 356 | m_EditorHideFlags: 0 357 | m_Script: {fileID: 11500000, guid: 0ac74b31fa1014848bc3d90c27d4de5e, type: 3} 358 | m_Name: 359 | m_EditorClassIdentifier: 360 | _prefab: {fileID: 1000011078001962, guid: 2964f7f7093728143a5de47df9bae6f9, type: 2} 361 | _spawnDistance: 0.5 362 | _spawnDelay: 0.5 363 | _maxSpawned: 15 364 | _maxDistance: 20 365 | _spawnRatio: 366 | serializedVersion: 2 367 | m_Curve: 368 | - time: 0 369 | value: 0 370 | inSlope: 2 371 | outSlope: 2 372 | tangentMode: 0 373 | - time: 0.5 374 | value: 1 375 | inSlope: -0.024288893 376 | outSlope: -0.024288893 377 | tangentMode: 0 378 | - time: 1 379 | value: 0 380 | inSlope: -2.5136027 381 | outSlope: -2.5136027 382 | tangentMode: 0 383 | m_PreInfinity: 2 384 | m_PostInfinity: 2 385 | m_RotationOrder: 0 386 | _ratioTimer: 0 387 | _ratioMaxTime: 2 388 | _eSpawner: 0 389 | _circleRadius: 0 390 | _clampDistanceToCircle: 0 391 | CachePool: 392 | Name: 393 | Prefab: {fileID: 0} 394 | AllowExpand: 0 395 | AllowRecycle: 0 396 | Size: 0 397 | --- !u!1 &1271577309 398 | GameObject: 399 | m_ObjectHideFlags: 0 400 | m_PrefabParentObject: {fileID: 0} 401 | m_PrefabInternal: {fileID: 0} 402 | serializedVersion: 4 403 | m_Component: 404 | - 4: {fileID: 1271577311} 405 | m_Layer: 0 406 | m_Name: SpawnerExample 407 | m_TagString: Untagged 408 | m_Icon: {fileID: 0} 409 | m_NavMeshLayer: 0 410 | m_StaticEditorFlags: 0 411 | m_IsActive: 1 412 | --- !u!4 &1271577311 413 | Transform: 414 | m_ObjectHideFlags: 0 415 | m_PrefabParentObject: {fileID: 0} 416 | m_PrefabInternal: {fileID: 0} 417 | m_GameObject: {fileID: 1271577309} 418 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 419 | m_LocalPosition: {x: 0, y: 0, z: 0} 420 | m_LocalScale: {x: 1, y: 1, z: 1} 421 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 422 | m_Children: 423 | - {fileID: 273914667} 424 | - {fileID: 1011166716} 425 | - {fileID: 1203234106} 426 | m_Father: {fileID: 0} 427 | m_RootOrder: 3 428 | --- !u!1 &1454869194 429 | GameObject: 430 | m_ObjectHideFlags: 0 431 | m_PrefabParentObject: {fileID: 0} 432 | m_PrefabInternal: {fileID: 0} 433 | serializedVersion: 4 434 | m_Component: 435 | - 4: {fileID: 1454869199} 436 | - 20: {fileID: 1454869198} 437 | - 92: {fileID: 1454869197} 438 | - 124: {fileID: 1454869196} 439 | - 81: {fileID: 1454869195} 440 | m_Layer: 0 441 | m_Name: Main Camera 442 | m_TagString: MainCamera 443 | m_Icon: {fileID: 0} 444 | m_NavMeshLayer: 0 445 | m_StaticEditorFlags: 0 446 | m_IsActive: 1 447 | --- !u!81 &1454869195 448 | AudioListener: 449 | m_ObjectHideFlags: 0 450 | m_PrefabParentObject: {fileID: 0} 451 | m_PrefabInternal: {fileID: 0} 452 | m_GameObject: {fileID: 1454869194} 453 | m_Enabled: 1 454 | --- !u!124 &1454869196 455 | Behaviour: 456 | m_ObjectHideFlags: 0 457 | m_PrefabParentObject: {fileID: 0} 458 | m_PrefabInternal: {fileID: 0} 459 | m_GameObject: {fileID: 1454869194} 460 | m_Enabled: 1 461 | --- !u!92 &1454869197 462 | Behaviour: 463 | m_ObjectHideFlags: 0 464 | m_PrefabParentObject: {fileID: 0} 465 | m_PrefabInternal: {fileID: 0} 466 | m_GameObject: {fileID: 1454869194} 467 | m_Enabled: 1 468 | --- !u!20 &1454869198 469 | Camera: 470 | m_ObjectHideFlags: 0 471 | m_PrefabParentObject: {fileID: 0} 472 | m_PrefabInternal: {fileID: 0} 473 | m_GameObject: {fileID: 1454869194} 474 | m_Enabled: 1 475 | serializedVersion: 2 476 | m_ClearFlags: 1 477 | m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} 478 | m_NormalizedViewPortRect: 479 | serializedVersion: 2 480 | x: 0 481 | y: 0 482 | width: 1 483 | height: 1 484 | near clip plane: 0.3 485 | far clip plane: 1000 486 | field of view: 60 487 | orthographic: 0 488 | orthographic size: 5 489 | m_Depth: -1 490 | m_CullingMask: 491 | serializedVersion: 2 492 | m_Bits: 4294967295 493 | m_RenderingPath: -1 494 | m_TargetTexture: {fileID: 0} 495 | m_TargetDisplay: 0 496 | m_TargetEye: 3 497 | m_HDR: 0 498 | m_OcclusionCulling: 1 499 | m_StereoConvergence: 10 500 | m_StereoSeparation: 0.022 501 | m_StereoMirrorMode: 0 502 | --- !u!4 &1454869199 503 | Transform: 504 | m_ObjectHideFlags: 0 505 | m_PrefabParentObject: {fileID: 0} 506 | m_PrefabInternal: {fileID: 0} 507 | m_GameObject: {fileID: 1454869194} 508 | m_LocalRotation: {x: 0.49775454, y: -0, z: -0, w: 0.867318} 509 | m_LocalPosition: {x: 0, y: 14.19, z: -1.45} 510 | m_LocalScale: {x: 1, y: 1, z: 1} 511 | m_LocalEulerAnglesHint: {x: 59.688004, y: 0, z: 0} 512 | m_Children: [] 513 | m_Father: {fileID: 0} 514 | m_RootOrder: 0 515 | --- !u!1 &2110836450 516 | GameObject: 517 | m_ObjectHideFlags: 0 518 | m_PrefabParentObject: {fileID: 0} 519 | m_PrefabInternal: {fileID: 0} 520 | serializedVersion: 4 521 | m_Component: 522 | - 4: {fileID: 2110836452} 523 | - 114: {fileID: 2110836451} 524 | - 114: {fileID: 2110836453} 525 | m_Layer: 0 526 | m_Name: _GMCache 527 | m_TagString: Untagged 528 | m_Icon: {fileID: 0} 529 | m_NavMeshLayer: 0 530 | m_StaticEditorFlags: 0 531 | m_IsActive: 1 532 | --- !u!114 &2110836451 533 | MonoBehaviour: 534 | m_ObjectHideFlags: 0 535 | m_PrefabParentObject: {fileID: 0} 536 | m_PrefabInternal: {fileID: 0} 537 | m_GameObject: {fileID: 2110836450} 538 | m_Enabled: 1 539 | m_EditorHideFlags: 0 540 | m_Script: {fileID: 11500000, guid: c7825a584cafa12498d31ae7e4918f39, type: 3} 541 | m_Name: 542 | m_EditorClassIdentifier: 543 | _pools: 544 | - Name: Coin Silver 545 | Prefab: {fileID: 1000011078001962, guid: 7233a6bdf92ce744188e0c89f2c0c891, type: 2} 546 | AllowExpand: 0 547 | AllowRecycle: 0 548 | Size: 0 549 | - Name: Coin Gold 550 | Prefab: {fileID: 1000011078001962, guid: 1a598a1363c06ab4199234137e8142df, type: 2} 551 | AllowExpand: 0 552 | AllowRecycle: 0 553 | Size: 0 554 | - Name: Coin Bronze 555 | Prefab: {fileID: 1000011078001962, guid: 2964f7f7093728143a5de47df9bae6f9, type: 2} 556 | AllowExpand: 0 557 | AllowRecycle: 0 558 | Size: 0 559 | --- !u!4 &2110836452 560 | Transform: 561 | m_ObjectHideFlags: 0 562 | m_PrefabParentObject: {fileID: 0} 563 | m_PrefabInternal: {fileID: 0} 564 | m_GameObject: {fileID: 2110836450} 565 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 566 | m_LocalPosition: {x: 0, y: 0, z: 0} 567 | m_LocalScale: {x: 1, y: 1, z: 1} 568 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 569 | m_Children: [] 570 | m_Father: {fileID: 0} 571 | m_RootOrder: 2 572 | --- !u!114 &2110836453 573 | MonoBehaviour: 574 | m_ObjectHideFlags: 0 575 | m_PrefabParentObject: {fileID: 0} 576 | m_PrefabInternal: {fileID: 0} 577 | m_GameObject: {fileID: 2110836450} 578 | m_Enabled: 1 579 | m_EditorHideFlags: 0 580 | m_Script: {fileID: 11500000, guid: c5d45b1350a01a84d9ef90c6a38e95ae, type: 3} 581 | m_Name: 582 | m_EditorClassIdentifier: 583 | LogTypes: [] 584 | Count: 0 585 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scenes/Code Spawner Example.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7146e9bd7dcd06a4fbf265d4b9180af2 3 | timeCreated: 1500233534 4 | licenseType: Pro 5 | DefaultImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scenes/Editor Spawner Example.unity: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!29 &1 4 | SceneSettings: 5 | m_ObjectHideFlags: 0 6 | m_PVSData: 7 | m_PVSObjectsArray: [] 8 | m_PVSPortalsArray: [] 9 | m_OcclusionBakeSettings: 10 | smallestOccluder: 5 11 | smallestHole: 0.25 12 | backfaceThreshold: 100 13 | --- !u!104 &2 14 | RenderSettings: 15 | m_ObjectHideFlags: 0 16 | serializedVersion: 7 17 | m_Fog: 0 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_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0} 29 | m_HaloStrength: 0.5 30 | m_FlareStrength: 1 31 | m_FlareFadeSpeed: 3 32 | m_HaloTexture: {fileID: 0} 33 | m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} 34 | m_DefaultReflectionMode: 0 35 | m_DefaultReflectionResolution: 128 36 | m_ReflectionBounces: 1 37 | m_ReflectionIntensity: 1 38 | m_CustomReflection: {fileID: 0} 39 | m_Sun: {fileID: 0} 40 | m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1} 41 | --- !u!157 &3 42 | LightmapSettings: 43 | m_ObjectHideFlags: 0 44 | serializedVersion: 7 45 | m_GIWorkflowMode: 1 46 | m_GISettings: 47 | serializedVersion: 2 48 | m_BounceScale: 1 49 | m_IndirectOutputScale: 1 50 | m_AlbedoBoost: 1 51 | m_TemporalCoherenceThreshold: 1 52 | m_EnvironmentLightingMode: 0 53 | m_EnableBakedLightmaps: 1 54 | m_EnableRealtimeLightmaps: 1 55 | m_LightmapEditorSettings: 56 | serializedVersion: 4 57 | m_Resolution: 2 58 | m_BakeResolution: 40 59 | m_TextureWidth: 1024 60 | m_TextureHeight: 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_DirectLightInLightProbes: 1 70 | m_FinalGather: 0 71 | m_FinalGatherFiltering: 1 72 | m_FinalGatherRayCount: 256 73 | m_ReflectionCompression: 2 74 | m_LightingDataAsset: {fileID: 0} 75 | m_RuntimeCPUUsage: 25 76 | --- !u!196 &4 77 | NavMeshSettings: 78 | serializedVersion: 2 79 | m_ObjectHideFlags: 0 80 | m_BuildSettings: 81 | serializedVersion: 2 82 | agentRadius: 0.5 83 | agentHeight: 2 84 | agentSlope: 45 85 | agentClimb: 0.4 86 | ledgeDropHeight: 0 87 | maxJumpAcrossDistance: 0 88 | accuratePlacement: 0 89 | minRegionArea: 2 90 | cellSize: 0.16666667 91 | manualCellSize: 0 92 | m_NavMeshData: {fileID: 0} 93 | --- !u!1 &528397491 94 | GameObject: 95 | m_ObjectHideFlags: 0 96 | m_PrefabParentObject: {fileID: 0} 97 | m_PrefabInternal: {fileID: 0} 98 | serializedVersion: 4 99 | m_Component: 100 | - 4: {fileID: 528397492} 101 | - 114: {fileID: 528397494} 102 | - 114: {fileID: 528397493} 103 | m_Layer: 0 104 | m_Name: _GMCache 105 | m_TagString: Untagged 106 | m_Icon: {fileID: 0} 107 | m_NavMeshLayer: 0 108 | m_StaticEditorFlags: 0 109 | m_IsActive: 1 110 | --- !u!4 &528397492 111 | Transform: 112 | m_ObjectHideFlags: 0 113 | m_PrefabParentObject: {fileID: 0} 114 | m_PrefabInternal: {fileID: 0} 115 | m_GameObject: {fileID: 528397491} 116 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 117 | m_LocalPosition: {x: 16.780354, y: 22.610935, z: 2.9695287} 118 | m_LocalScale: {x: 1, y: 1, z: 1} 119 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 120 | m_Children: [] 121 | m_Father: {fileID: 1044546307} 122 | m_RootOrder: 0 123 | --- !u!114 &528397493 124 | MonoBehaviour: 125 | m_ObjectHideFlags: 0 126 | m_PrefabParentObject: {fileID: 0} 127 | m_PrefabInternal: {fileID: 0} 128 | m_GameObject: {fileID: 528397491} 129 | m_Enabled: 1 130 | m_EditorHideFlags: 0 131 | m_Script: {fileID: 11500000, guid: c5d45b1350a01a84d9ef90c6a38e95ae, type: 3} 132 | m_Name: 133 | m_EditorClassIdentifier: 134 | LogTypes: [] 135 | Count: 0 136 | --- !u!114 &528397494 137 | MonoBehaviour: 138 | m_ObjectHideFlags: 0 139 | m_PrefabParentObject: {fileID: 0} 140 | m_PrefabInternal: {fileID: 0} 141 | m_GameObject: {fileID: 528397491} 142 | m_Enabled: 1 143 | m_EditorHideFlags: 0 144 | m_Script: {fileID: 11500000, guid: c7825a584cafa12498d31ae7e4918f39, type: 3} 145 | m_Name: 146 | m_EditorClassIdentifier: 147 | _pools: 148 | - Name: Coin Bronze 149 | Prefab: {fileID: 1000011078001962, guid: 2964f7f7093728143a5de47df9bae6f9, type: 2} 150 | AllowExpand: 0 151 | AllowRecycle: 0 152 | Size: 0 153 | --- !u!1 &598078208 154 | GameObject: 155 | m_ObjectHideFlags: 0 156 | m_PrefabParentObject: {fileID: 0} 157 | m_PrefabInternal: {fileID: 0} 158 | serializedVersion: 4 159 | m_Component: 160 | - 4: {fileID: 598078211} 161 | - 114: {fileID: 598078209} 162 | m_Layer: 0 163 | m_Name: Silver Coins Spawner 164 | m_TagString: Untagged 165 | m_Icon: {fileID: 0} 166 | m_NavMeshLayer: 0 167 | m_StaticEditorFlags: 0 168 | m_IsActive: 1 169 | --- !u!114 &598078209 170 | MonoBehaviour: 171 | m_ObjectHideFlags: 0 172 | m_PrefabParentObject: {fileID: 0} 173 | m_PrefabInternal: {fileID: 0} 174 | m_GameObject: {fileID: 598078208} 175 | m_Enabled: 1 176 | m_EditorHideFlags: 0 177 | m_Script: {fileID: 11500000, guid: 0ac74b31fa1014848bc3d90c27d4de5e, type: 3} 178 | m_Name: 179 | m_EditorClassIdentifier: 180 | _prefab: {fileID: 1000011078001962, guid: 7233a6bdf92ce744188e0c89f2c0c891, type: 2} 181 | _spawnDistance: 0.35 182 | _spawnDelay: 0.35 183 | _maxSpawned: 12 184 | _maxDistance: 12.566371 185 | _spawnRatio: 186 | serializedVersion: 2 187 | m_Curve: 188 | - time: 0 189 | value: 0 190 | inSlope: 2 191 | outSlope: 2 192 | tangentMode: 0 193 | - time: 0.5 194 | value: 1 195 | inSlope: -0.024288893 196 | outSlope: -0.024288893 197 | tangentMode: 0 198 | - time: 0.62886137 199 | value: 0.381597 200 | inSlope: -3.517252 201 | outSlope: -3.517252 202 | tangentMode: 0 203 | - time: 1 204 | value: 0 205 | inSlope: -0.25658503 206 | outSlope: -0.25658503 207 | tangentMode: 0 208 | m_PreInfinity: 2 209 | m_PostInfinity: 2 210 | m_RotationOrder: 0 211 | _ratioTimer: 0.9306276 212 | _ratioMaxTime: 2 213 | _eSpawner: 1 214 | _circleRadius: 2 215 | _clampDistanceToCircle: 1 216 | CachePool: 217 | Name: 218 | Prefab: {fileID: 0} 219 | AllowExpand: 0 220 | AllowRecycle: 0 221 | Size: 0 222 | --- !u!4 &598078211 223 | Transform: 224 | m_ObjectHideFlags: 0 225 | m_PrefabParentObject: {fileID: 0} 226 | m_PrefabInternal: {fileID: 0} 227 | m_GameObject: {fileID: 598078208} 228 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 229 | m_LocalPosition: {x: 0, y: 0, z: 5} 230 | m_LocalScale: {x: 1, y: 1, z: 1} 231 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 232 | m_Children: 233 | - {fileID: 2080752114} 234 | m_Father: {fileID: 0} 235 | m_RootOrder: 3 236 | --- !u!1 &669576243 237 | GameObject: 238 | m_ObjectHideFlags: 0 239 | m_PrefabParentObject: {fileID: 0} 240 | m_PrefabInternal: {fileID: 0} 241 | serializedVersion: 4 242 | m_Component: 243 | - 4: {fileID: 669576245} 244 | - 108: {fileID: 669576244} 245 | m_Layer: 0 246 | m_Name: Directional Light 247 | m_TagString: Untagged 248 | m_Icon: {fileID: 0} 249 | m_NavMeshLayer: 0 250 | m_StaticEditorFlags: 0 251 | m_IsActive: 1 252 | --- !u!108 &669576244 253 | Light: 254 | m_ObjectHideFlags: 0 255 | m_PrefabParentObject: {fileID: 0} 256 | m_PrefabInternal: {fileID: 0} 257 | m_GameObject: {fileID: 669576243} 258 | m_Enabled: 1 259 | serializedVersion: 7 260 | m_Type: 1 261 | m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1} 262 | m_Intensity: 1 263 | m_Range: 10 264 | m_SpotAngle: 30 265 | m_CookieSize: 10 266 | m_Shadows: 267 | m_Type: 2 268 | m_Resolution: -1 269 | m_CustomResolution: -1 270 | m_Strength: 1 271 | m_Bias: 0.05 272 | m_NormalBias: 0.4 273 | m_NearPlane: 0.2 274 | m_Cookie: {fileID: 0} 275 | m_DrawHalo: 0 276 | m_Flare: {fileID: 0} 277 | m_RenderMode: 0 278 | m_CullingMask: 279 | serializedVersion: 2 280 | m_Bits: 4294967295 281 | m_Lightmapping: 4 282 | m_AreaSize: {x: 1, y: 1} 283 | m_BounceIntensity: 1 284 | m_ShadowRadius: 0 285 | m_ShadowAngle: 0 286 | --- !u!4 &669576245 287 | Transform: 288 | m_ObjectHideFlags: 0 289 | m_PrefabParentObject: {fileID: 0} 290 | m_PrefabInternal: {fileID: 0} 291 | m_GameObject: {fileID: 669576243} 292 | m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261} 293 | m_LocalPosition: {x: 0, y: 3, z: 0} 294 | m_LocalScale: {x: 1, y: 1, z: 1} 295 | m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0} 296 | m_Children: [] 297 | m_Father: {fileID: 0} 298 | m_RootOrder: 0 299 | --- !u!1 &1044546304 300 | GameObject: 301 | m_ObjectHideFlags: 0 302 | m_PrefabParentObject: {fileID: 0} 303 | m_PrefabInternal: {fileID: 0} 304 | serializedVersion: 4 305 | m_Component: 306 | - 4: {fileID: 1044546307} 307 | - 114: {fileID: 1044546305} 308 | m_Layer: 0 309 | m_Name: Bronze Coins Spawner 310 | m_TagString: Untagged 311 | m_Icon: {fileID: 0} 312 | m_NavMeshLayer: 0 313 | m_StaticEditorFlags: 0 314 | m_IsActive: 1 315 | --- !u!114 &1044546305 316 | MonoBehaviour: 317 | m_ObjectHideFlags: 0 318 | m_PrefabParentObject: {fileID: 0} 319 | m_PrefabInternal: {fileID: 0} 320 | m_GameObject: {fileID: 1044546304} 321 | m_Enabled: 1 322 | m_EditorHideFlags: 0 323 | m_Script: {fileID: 11500000, guid: 0ac74b31fa1014848bc3d90c27d4de5e, type: 3} 324 | m_Name: 325 | m_EditorClassIdentifier: 326 | _prefab: {fileID: 1000011078001962, guid: 2964f7f7093728143a5de47df9bae6f9, type: 2} 327 | _spawnDistance: 0.35 328 | _spawnDelay: 0.35 329 | _maxSpawned: 12 330 | _maxDistance: 12.566371 331 | _spawnRatio: 332 | serializedVersion: 2 333 | m_Curve: 334 | - time: 0 335 | value: 0 336 | inSlope: 2 337 | outSlope: 2 338 | tangentMode: 0 339 | - time: 0.5 340 | value: 1 341 | inSlope: -0.024288893 342 | outSlope: -0.024288893 343 | tangentMode: 0 344 | - time: 0.62886137 345 | value: 0.381597 346 | inSlope: -3.517252 347 | outSlope: -3.517252 348 | tangentMode: 0 349 | - time: 1 350 | value: 0 351 | inSlope: -0.25658503 352 | outSlope: -0.25658503 353 | tangentMode: 0 354 | m_PreInfinity: 2 355 | m_PostInfinity: 2 356 | m_RotationOrder: 0 357 | _ratioTimer: 0.9306276 358 | _ratioMaxTime: 2 359 | _eSpawner: 1 360 | _circleRadius: 2 361 | _clampDistanceToCircle: 1 362 | CachePool: 363 | Name: 364 | Prefab: {fileID: 0} 365 | AllowExpand: 0 366 | AllowRecycle: 0 367 | Size: 0 368 | --- !u!4 &1044546307 369 | Transform: 370 | m_ObjectHideFlags: 0 371 | m_PrefabParentObject: {fileID: 0} 372 | m_PrefabInternal: {fileID: 0} 373 | m_GameObject: {fileID: 1044546304} 374 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 375 | m_LocalPosition: {x: 0, y: 0, z: 14} 376 | m_LocalScale: {x: 1, y: 1, z: 1} 377 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 378 | m_Children: 379 | - {fileID: 528397492} 380 | m_Father: {fileID: 0} 381 | m_RootOrder: 4 382 | --- !u!1 &1574980283 383 | GameObject: 384 | m_ObjectHideFlags: 0 385 | m_PrefabParentObject: {fileID: 0} 386 | m_PrefabInternal: {fileID: 0} 387 | serializedVersion: 4 388 | m_Component: 389 | - 4: {fileID: 1574980285} 390 | - 114: {fileID: 1574980286} 391 | m_Layer: 0 392 | m_Name: Gold Coin Spawner 393 | m_TagString: Untagged 394 | m_Icon: {fileID: 0} 395 | m_NavMeshLayer: 0 396 | m_StaticEditorFlags: 0 397 | m_IsActive: 1 398 | --- !u!4 &1574980285 399 | Transform: 400 | m_ObjectHideFlags: 0 401 | m_PrefabParentObject: {fileID: 0} 402 | m_PrefabInternal: {fileID: 0} 403 | m_GameObject: {fileID: 1574980283} 404 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 405 | m_LocalPosition: {x: 0, y: 0, z: 0} 406 | m_LocalScale: {x: 1, y: 1, z: 1} 407 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 408 | m_Children: 409 | - {fileID: 1739679259} 410 | m_Father: {fileID: 0} 411 | m_RootOrder: 2 412 | --- !u!114 &1574980286 413 | MonoBehaviour: 414 | m_ObjectHideFlags: 0 415 | m_PrefabParentObject: {fileID: 0} 416 | m_PrefabInternal: {fileID: 0} 417 | m_GameObject: {fileID: 1574980283} 418 | m_Enabled: 1 419 | m_EditorHideFlags: 0 420 | m_Script: {fileID: 11500000, guid: 0ac74b31fa1014848bc3d90c27d4de5e, type: 3} 421 | m_Name: 422 | m_EditorClassIdentifier: 423 | _prefab: {fileID: 1000011078001962, guid: 1a598a1363c06ab4199234137e8142df, type: 2} 424 | _spawnDistance: 0.35 425 | _spawnDelay: 0.35 426 | _maxSpawned: 12 427 | _maxDistance: 12.566371 428 | _spawnRatio: 429 | serializedVersion: 2 430 | m_Curve: 431 | - time: 0 432 | value: 0 433 | inSlope: 2 434 | outSlope: 2 435 | tangentMode: 0 436 | - time: 0.5 437 | value: 1 438 | inSlope: -0.024288893 439 | outSlope: -0.024288893 440 | tangentMode: 0 441 | - time: 0.62886137 442 | value: 0.381597 443 | inSlope: -3.517252 444 | outSlope: -3.517252 445 | tangentMode: 0 446 | - time: 1 447 | value: 0 448 | inSlope: -0.25658503 449 | outSlope: -0.25658503 450 | tangentMode: 0 451 | m_PreInfinity: 2 452 | m_PostInfinity: 2 453 | m_RotationOrder: 0 454 | _ratioTimer: 0.9306276 455 | _ratioMaxTime: 2 456 | _eSpawner: 1 457 | _circleRadius: 2 458 | _clampDistanceToCircle: 1 459 | CachePool: 460 | Name: 461 | Prefab: {fileID: 0} 462 | AllowExpand: 0 463 | AllowRecycle: 0 464 | Size: 0 465 | --- !u!1 &1739679258 466 | GameObject: 467 | m_ObjectHideFlags: 0 468 | m_PrefabParentObject: {fileID: 0} 469 | m_PrefabInternal: {fileID: 0} 470 | serializedVersion: 4 471 | m_Component: 472 | - 4: {fileID: 1739679259} 473 | - 114: {fileID: 1739679261} 474 | - 114: {fileID: 1739679260} 475 | m_Layer: 0 476 | m_Name: _GMCache 477 | m_TagString: Untagged 478 | m_Icon: {fileID: 0} 479 | m_NavMeshLayer: 0 480 | m_StaticEditorFlags: 0 481 | m_IsActive: 1 482 | --- !u!4 &1739679259 483 | Transform: 484 | m_ObjectHideFlags: 0 485 | m_PrefabParentObject: {fileID: 0} 486 | m_PrefabInternal: {fileID: 0} 487 | m_GameObject: {fileID: 1739679258} 488 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 489 | m_LocalPosition: {x: 16.780354, y: 22.610935, z: 2.9695287} 490 | m_LocalScale: {x: 1, y: 1, z: 1} 491 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 492 | m_Children: [] 493 | m_Father: {fileID: 1574980285} 494 | m_RootOrder: 0 495 | --- !u!114 &1739679260 496 | MonoBehaviour: 497 | m_ObjectHideFlags: 0 498 | m_PrefabParentObject: {fileID: 0} 499 | m_PrefabInternal: {fileID: 0} 500 | m_GameObject: {fileID: 1739679258} 501 | m_Enabled: 1 502 | m_EditorHideFlags: 0 503 | m_Script: {fileID: 11500000, guid: c5d45b1350a01a84d9ef90c6a38e95ae, type: 3} 504 | m_Name: 505 | m_EditorClassIdentifier: 506 | LogTypes: [] 507 | Count: 0 508 | --- !u!114 &1739679261 509 | MonoBehaviour: 510 | m_ObjectHideFlags: 0 511 | m_PrefabParentObject: {fileID: 0} 512 | m_PrefabInternal: {fileID: 0} 513 | m_GameObject: {fileID: 1739679258} 514 | m_Enabled: 1 515 | m_EditorHideFlags: 0 516 | m_Script: {fileID: 11500000, guid: c7825a584cafa12498d31ae7e4918f39, type: 3} 517 | m_Name: 518 | m_EditorClassIdentifier: 519 | _pools: 520 | - Name: Coin Gold 521 | Prefab: {fileID: 1000011078001962, guid: 1a598a1363c06ab4199234137e8142df, type: 2} 522 | AllowExpand: 0 523 | AllowRecycle: 0 524 | Size: 0 525 | --- !u!1 &2024832451 526 | GameObject: 527 | m_ObjectHideFlags: 0 528 | m_PrefabParentObject: {fileID: 0} 529 | m_PrefabInternal: {fileID: 0} 530 | serializedVersion: 4 531 | m_Component: 532 | - 4: {fileID: 2024832456} 533 | - 20: {fileID: 2024832455} 534 | - 92: {fileID: 2024832454} 535 | - 124: {fileID: 2024832453} 536 | - 81: {fileID: 2024832452} 537 | m_Layer: 0 538 | m_Name: Main Camera 539 | m_TagString: MainCamera 540 | m_Icon: {fileID: 0} 541 | m_NavMeshLayer: 0 542 | m_StaticEditorFlags: 0 543 | m_IsActive: 1 544 | --- !u!81 &2024832452 545 | AudioListener: 546 | m_ObjectHideFlags: 0 547 | m_PrefabParentObject: {fileID: 0} 548 | m_PrefabInternal: {fileID: 0} 549 | m_GameObject: {fileID: 2024832451} 550 | m_Enabled: 1 551 | --- !u!124 &2024832453 552 | Behaviour: 553 | m_ObjectHideFlags: 0 554 | m_PrefabParentObject: {fileID: 0} 555 | m_PrefabInternal: {fileID: 0} 556 | m_GameObject: {fileID: 2024832451} 557 | m_Enabled: 1 558 | --- !u!92 &2024832454 559 | Behaviour: 560 | m_ObjectHideFlags: 0 561 | m_PrefabParentObject: {fileID: 0} 562 | m_PrefabInternal: {fileID: 0} 563 | m_GameObject: {fileID: 2024832451} 564 | m_Enabled: 1 565 | --- !u!20 &2024832455 566 | Camera: 567 | m_ObjectHideFlags: 0 568 | m_PrefabParentObject: {fileID: 0} 569 | m_PrefabInternal: {fileID: 0} 570 | m_GameObject: {fileID: 2024832451} 571 | m_Enabled: 1 572 | serializedVersion: 2 573 | m_ClearFlags: 1 574 | m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} 575 | m_NormalizedViewPortRect: 576 | serializedVersion: 2 577 | x: 0 578 | y: 0 579 | width: 1 580 | height: 1 581 | near clip plane: 0.3 582 | far clip plane: 1000 583 | field of view: 60 584 | orthographic: 0 585 | orthographic size: 5 586 | m_Depth: -1 587 | m_CullingMask: 588 | serializedVersion: 2 589 | m_Bits: 4294967295 590 | m_RenderingPath: -1 591 | m_TargetTexture: {fileID: 0} 592 | m_TargetDisplay: 0 593 | m_TargetEye: 3 594 | m_HDR: 0 595 | m_OcclusionCulling: 1 596 | m_StereoConvergence: 10 597 | m_StereoSeparation: 0.022 598 | m_StereoMirrorMode: 0 599 | --- !u!4 &2024832456 600 | Transform: 601 | m_ObjectHideFlags: 0 602 | m_PrefabParentObject: {fileID: 0} 603 | m_PrefabInternal: {fileID: 0} 604 | m_GameObject: {fileID: 2024832451} 605 | m_LocalRotation: {x: 0.49775454, y: -0, z: -0, w: 0.867318} 606 | m_LocalPosition: {x: 0, y: 14.19, z: -7.08} 607 | m_LocalScale: {x: 1, y: 1, z: 1} 608 | m_LocalEulerAnglesHint: {x: 59.688004, y: 0, z: 0} 609 | m_Children: [] 610 | m_Father: {fileID: 0} 611 | m_RootOrder: 1 612 | --- !u!1 &2080752113 613 | GameObject: 614 | m_ObjectHideFlags: 0 615 | m_PrefabParentObject: {fileID: 0} 616 | m_PrefabInternal: {fileID: 0} 617 | serializedVersion: 4 618 | m_Component: 619 | - 4: {fileID: 2080752114} 620 | - 114: {fileID: 2080752116} 621 | - 114: {fileID: 2080752115} 622 | m_Layer: 0 623 | m_Name: _GMCache 624 | m_TagString: Untagged 625 | m_Icon: {fileID: 0} 626 | m_NavMeshLayer: 0 627 | m_StaticEditorFlags: 0 628 | m_IsActive: 1 629 | --- !u!4 &2080752114 630 | Transform: 631 | m_ObjectHideFlags: 0 632 | m_PrefabParentObject: {fileID: 0} 633 | m_PrefabInternal: {fileID: 0} 634 | m_GameObject: {fileID: 2080752113} 635 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 636 | m_LocalPosition: {x: 16.780354, y: 22.610935, z: 2.9695287} 637 | m_LocalScale: {x: 1, y: 1, z: 1} 638 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 639 | m_Children: [] 640 | m_Father: {fileID: 598078211} 641 | m_RootOrder: 0 642 | --- !u!114 &2080752115 643 | MonoBehaviour: 644 | m_ObjectHideFlags: 0 645 | m_PrefabParentObject: {fileID: 0} 646 | m_PrefabInternal: {fileID: 0} 647 | m_GameObject: {fileID: 2080752113} 648 | m_Enabled: 1 649 | m_EditorHideFlags: 0 650 | m_Script: {fileID: 11500000, guid: c5d45b1350a01a84d9ef90c6a38e95ae, type: 3} 651 | m_Name: 652 | m_EditorClassIdentifier: 653 | LogTypes: [] 654 | Count: 0 655 | --- !u!114 &2080752116 656 | MonoBehaviour: 657 | m_ObjectHideFlags: 0 658 | m_PrefabParentObject: {fileID: 0} 659 | m_PrefabInternal: {fileID: 0} 660 | m_GameObject: {fileID: 2080752113} 661 | m_Enabled: 1 662 | m_EditorHideFlags: 0 663 | m_Script: {fileID: 11500000, guid: c7825a584cafa12498d31ae7e4918f39, type: 3} 664 | m_Name: 665 | m_EditorClassIdentifier: 666 | _pools: 667 | - Name: Coin Silver 668 | Prefab: {fileID: 1000011078001962, guid: 7233a6bdf92ce744188e0c89f2c0c891, type: 2} 669 | AllowExpand: 0 670 | AllowRecycle: 0 671 | Size: 0 672 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scenes/Editor Spawner Example.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 071221102feac81459b329f0d8302ec7 3 | timeCreated: 1501794718 4 | licenseType: Pro 5 | DefaultImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 5edf6a3682e03f149894bd32e2faa3e3 3 | folderAsset: yes 4 | timeCreated: 1501794100 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scripts/PickableSpawnerExample.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | using System.Collections; 4 | using System.Collections.Generic; 5 | using Grygus.Utilities.Pool; 6 | using Grygus.Utilities.Pool.Unity; 7 | 8 | public class PickableSpawnerExample : MonoBehaviour 9 | { 10 | public enum ESpawnerType 11 | { 12 | Line, 13 | Circle 14 | } 15 | 16 | [SerializeField] private GameObject _prefab; 17 | [SerializeField] 18 | private float _spawnDistance; 19 | [SerializeField] 20 | private float _spawnDelay; 21 | [SerializeField] 22 | private int _maxSpawned; 23 | [SerializeField] 24 | private float _maxDistance; 25 | 26 | [SerializeField] private AnimationCurve _spawnRatio; 27 | [SerializeField] private float _ratioTimer; 28 | [SerializeField] private float _ratioMaxTime; 29 | 30 | private float _spawnTimer; 31 | private float _lastSpawnDistance; 32 | 33 | private List _activeGameObjects; 34 | // [Header("Line Settings")] 35 | [SerializeField] 36 | private ESpawnerType _eSpawner; 37 | [SerializeField] 38 | private float _circleRadius; 39 | 40 | [SerializeField] private bool _clampDistanceToCircle; 41 | public UnityPool CachePool; 42 | 43 | private void OnValidate() 44 | { 45 | if (_clampDistanceToCircle) 46 | _maxDistance = _circleRadius * Mathf.PI * 2; 47 | } 48 | // Use this for initialization 49 | void Start() 50 | { 51 | _activeGameObjects = new List(); 52 | Cache.Caches[_prefab.name] 53 | .SetFactory(() => 54 | { 55 | var gm = Instantiate(_prefab); 56 | gm.transform.parent = transform; 57 | return gm; 58 | }) 59 | .SetResetAction(o => o.SetActive(false)) 60 | .Generate(_maxSpawned); 61 | } 62 | 63 | // Update is called once per frame 64 | void Update() 65 | { 66 | if (_ratioTimer < _ratioMaxTime) 67 | _ratioTimer += Time.deltaTime; 68 | else 69 | _ratioTimer = 0; 70 | 71 | var spawnCount = (int)(_spawnRatio.Evaluate(_ratioTimer / _ratioMaxTime)*_maxSpawned); 72 | if (spawnCount >= 0) 73 | { 74 | while (spawnCount > _activeGameObjects.Count) 75 | { 76 | Spawn(); 77 | } 78 | while(spawnCount < _activeGameObjects.Count) 79 | { 80 | Cache.Caches[_prefab.name].Push(_activeGameObjects[0]); 81 | _activeGameObjects.RemoveAt(0); 82 | } 83 | } 84 | } 85 | 86 | 87 | 88 | private void Spawn() 89 | { 90 | var distance = _lastSpawnDistance + _spawnDistance; 91 | if (distance > _maxDistance) 92 | distance = 0; 93 | _lastSpawnDistance = distance; 94 | var pickable = GetPickable(); 95 | _activeGameObjects.Add(pickable); 96 | Spawn(pickable, transform.position+GetNextPosition(), transform.rotation); 97 | } 98 | 99 | private Vector3 GetNextPosition() 100 | { 101 | var position = Vector3.zero; 102 | var distance = _lastSpawnDistance + _spawnDistance; 103 | if (distance > _maxDistance) 104 | distance = 0; 105 | _lastSpawnDistance = distance; 106 | switch (_eSpawner) 107 | { 108 | case ESpawnerType.Line: 109 | position = Vector3.forward * distance; 110 | break; 111 | case ESpawnerType.Circle: 112 | var ratio = distance / (_circleRadius * Mathf.PI * 2); 113 | var x = _circleRadius * Mathf.Cos(Mathf.PI * 2 * ratio); 114 | var y = _circleRadius * Mathf.Sin(Mathf.PI * 2 * ratio); 115 | position = new Vector3(x,0,y); 116 | break; 117 | default: 118 | throw new ArgumentOutOfRangeException(); 119 | } 120 | return position; 121 | } 122 | 123 | private GameObject GetPickable() 124 | { 125 | return Cache.Caches[_prefab.name].Pop(); 126 | } 127 | 128 | private void Spawn(GameObject pickable,Vector3 position,Quaternion rotation ) 129 | { 130 | pickable.transform.position = position; 131 | pickable.transform.rotation = rotation; 132 | pickable.SetActive(true); 133 | } 134 | 135 | private void Despawn(GameObject pickable) 136 | { 137 | 138 | } 139 | 140 | } 141 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Examples/Scripts/PickableSpawnerExample.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0ac74b31fa1014848bc3d90c27d4de5e 3 | timeCreated: 1501191937 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a81641b68aa07d84c8a27525d10ad362 3 | folderAsset: yes 4 | timeCreated: 1501096685 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7e30b391429bc1840b1dd8a4511ad8ce 3 | folderAsset: yes 4 | timeCreated: 1498499267 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: cf6d5e021b5d5be4593be2690e3c8744 3 | folderAsset: yes 4 | timeCreated: 1498499268 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8d232a52e3917f14e8ddd6debd44af63 3 | folderAsset: yes 4 | timeCreated: 1498499268 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/C.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace Grygus.Utilities.Pool 7 | { 8 | class C 9 | { 10 | public T Value; 11 | private IPool _cache; 12 | 13 | internal C(T value,IPool cache) 14 | { 15 | this.Value = value; 16 | this._cache = cache; 17 | } 18 | 19 | public void Dispose() 20 | { 21 | _cache.Push(this.Value); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/C.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bf9a2093e2ce79b47af3cdb876e2829e 3 | timeCreated: 1498499269 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Cache.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace Grygus.Utilities.Pool 6 | { 7 | public delegate void PoolStateChangedEventHandler(IPool sender,T arg); 8 | 9 | public static partial class Cache where T : class 10 | { 11 | public static readonly CacheRegister Caches; 12 | private static readonly string DefaultName = "Default"; 13 | 14 | public static int Count { get { return DefaultPool.Count; } } 15 | public static IPool DefaultPool { get; private set; } 16 | 17 | public static event PoolStateChangedEventHandler Added = (sender, arg) => { }; 18 | public static event PoolStateChangedEventHandler Removed = (sender, arg) => { }; 19 | public static event PoolStateChangedEventHandler AddedAny = (sender, arg) => { }; 20 | public static event PoolStateChangedEventHandler RemovedAny = (sender, arg) => { }; 21 | 22 | static Cache() 23 | { 24 | Caches = new CacheRegister(); 25 | DefaultPool = Caches[DefaultName]; 26 | DefaultPool.SetResetAction((instance) => { }); 27 | DefaultPool.Added += (sender, arg) => Added(sender,arg); 28 | DefaultPool.Removed += (sender, arg) => Removed(sender,arg); 29 | CacheLog.AddType(typeof(Cache)); 30 | } 31 | 32 | public static void Generate(int count) 33 | { 34 | DefaultPool.Generate(count); 35 | } 36 | 37 | public static void SetFactory(Func factoryMethod) 38 | { 39 | DefaultPool.SetFactory(factoryMethod); 40 | } 41 | 42 | public static void SetResetAction(Action resetMethod) 43 | { 44 | DefaultPool.SetResetAction(resetMethod); 45 | } 46 | 47 | public static T Pop() 48 | { 49 | return DefaultPool.Pop(); 50 | } 51 | 52 | public static T PopFrom(string cacheId) 53 | { 54 | return Caches[cacheId].Pop(); 55 | } 56 | 57 | public static void Push(T instance) 58 | { 59 | DefaultPool.Push(instance); 60 | } 61 | 62 | public static void PushInto(T instance, string cacheId) 63 | { 64 | Caches[cacheId].Push(instance); 65 | } 66 | 67 | public static string GetTypeName() 68 | { 69 | return typeof(T).Name; 70 | } 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Cache.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 72b5959795dddea4d8a3a6532fe7a4a0 3 | timeCreated: 1498499269 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/CacheInternal.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Linq.Expressions; 5 | using System.Text; 6 | 7 | namespace Grygus.Utilities.Pool 8 | { 9 | public static partial class Cache where T : class 10 | { 11 | private class CacheInternal : IPool,IPool 12 | { 13 | public string Name { get; private set; } 14 | 15 | private HashSet _poolSet; 16 | private Queue _poolOrder; 17 | private HashSet _deploySet; 18 | private List _deployOrder; 19 | 20 | public int Count { get { return _poolSet.Count; } } 21 | 22 | public event PoolStateChangedEventHandler Added; 23 | public event PoolStateChangedEventHandler Removed; 24 | 25 | private Func _factoryMethod; 26 | private Action _resetMethod; 27 | 28 | private bool _canExpand; 29 | private bool _canRecycle; 30 | 31 | public CacheInternal(string name) 32 | { 33 | Name = name; 34 | TryGetDefaultConstructor(); 35 | _poolSet = new HashSet(); 36 | _poolOrder = new Queue(); 37 | _deploySet = new HashSet(); 38 | _deployOrder = new List(); 39 | _resetMethod = instance => { }; 40 | } 41 | 42 | public IPool Generate(int count) 43 | { 44 | if (_factoryMethod == null) 45 | _factoryMethod = TryGetDefaultConstructor(); 46 | for (int i = 0; i < count; i++) 47 | { 48 | var item = _factoryMethod(); 49 | _resetMethod(item); 50 | Push(item); 51 | } 52 | return this; 53 | } 54 | 55 | public T Pop() 56 | { 57 | if (_poolOrder.Count == 0) 58 | { 59 | if (_canRecycle) 60 | TryRecycle(); 61 | if (_canExpand) 62 | Generate(1); 63 | } 64 | 65 | if (_poolOrder.Count > 0) 66 | { 67 | var itemToPop = _poolOrder.Dequeue(); 68 | var isSuccess = _poolSet.Remove(itemToPop); 69 | if (!isSuccess) 70 | { 71 | throw new NotImplementedException(); 72 | } 73 | Removed(this, itemToPop); 74 | 75 | _deploySet.Add(itemToPop); 76 | _deployOrder.Add(itemToPop); 77 | return itemToPop; 78 | } 79 | throw new NoObjectsInPoolException(typeof(T),Name); 80 | } 81 | 82 | public void Push(T instance) 83 | { 84 | var isSuccess = _poolSet.Add(instance); 85 | if (isSuccess) 86 | { 87 | _resetMethod(instance); 88 | _poolOrder.Enqueue(instance); 89 | 90 | if (_deploySet.Contains(instance)) 91 | { 92 | _deploySet.Remove(instance); 93 | _deployOrder.Remove(instance); 94 | } 95 | 96 | Added(this, instance); 97 | } 98 | else 99 | { 100 | throw new ObjectAlreadyInPoolException(); 101 | } 102 | } 103 | 104 | public IPool SetFactory(Func factoryFunc) 105 | { 106 | _factoryMethod = factoryFunc; 107 | return this; 108 | } 109 | 110 | public IPool SetResetAction(Action resetAction) 111 | { 112 | _resetMethod = resetAction; 113 | return this; 114 | } 115 | 116 | public IPool AllowExpand() 117 | { 118 | _canExpand = true; 119 | return this; 120 | } 121 | 122 | public IPool DoNotExpand() 123 | { 124 | _canExpand = false; 125 | return this; 126 | } 127 | 128 | public IPool AllowRecycle() 129 | { 130 | _canRecycle = true; 131 | return this; 132 | } 133 | 134 | public IPool DoNotRecycle() 135 | { 136 | _canRecycle = false; 137 | return this; 138 | } 139 | 140 | public IPool Reset() 141 | { 142 | throw new NotImplementedException(); 143 | } 144 | 145 | public void Clear() 146 | { 147 | _poolSet.Clear(); 148 | _poolOrder.Clear(); 149 | } 150 | 151 | private void TryRecycle() 152 | { 153 | if (_deploySet.Count > 0) 154 | { 155 | Push(_deployOrder[0]); 156 | } 157 | } 158 | 159 | private Func TryGetDefaultConstructor() 160 | { 161 | var constructor = typeof(T).GetConstructor(Type.EmptyTypes); 162 | if (constructor != null) 163 | { 164 | var lambda = Expression.Lambda>(Expression.New(constructor)); 165 | return lambda.Compile(); 166 | } 167 | else 168 | { 169 | throw new Exception("No Default Constructor found for type:"+typeof(T).Name); 170 | } 171 | } 172 | 173 | } 174 | } 175 | } 176 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/CacheInternal.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0737cf2bcc880c54d9c2d2e576951585 3 | timeCreated: 1500159555 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/CacheLog.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Reflection; 5 | using System.Text; 6 | 7 | namespace Grygus.Utilities.Pool 8 | { 9 | public delegate void CacheCahangedEventHandler(object sender,object args); 10 | public static class CacheLog 11 | { 12 | public static event CacheCahangedEventHandler AnyAdded; 13 | public static event CacheCahangedEventHandler AnyRemoved; 14 | public static Dictionary CacheCounter; 15 | public static Dictionary> NamedCacheCounter; 16 | private static List _cacheTypes = new List(); 17 | 18 | static CacheLog() 19 | { 20 | CacheCounter = new Dictionary(); 21 | NamedCacheCounter = new Dictionary>(); 22 | AnyAdded += (sender, args) => 23 | { 24 | var argumentType = sender.GetType().GetGenericArguments()[0]; 25 | CacheCounter[argumentType]++; 26 | var pool = (IPool) sender; 27 | var poolCache = NamedCacheCounter[argumentType]; 28 | if(poolCache.ContainsKey(pool.Name)) 29 | poolCache[pool.Name]++; 30 | else 31 | poolCache[pool.Name] = 1; 32 | }; 33 | AnyRemoved += (sender, args) => 34 | { 35 | var argumentType = sender.GetType().GetGenericArguments()[0]; 36 | CacheCounter[argumentType]--; 37 | var pool = (IPool) sender; 38 | var poolCache = NamedCacheCounter[argumentType]; 39 | poolCache[pool.Name]--; 40 | }; 41 | 42 | } 43 | 44 | public static List GetTypes() 45 | { 46 | var result = System.Reflection.Assembly.GetExecutingAssembly() 47 | .GetTypes() 48 | .Where(t => t.IsGenericType && 49 | t.GetGenericTypeDefinition() == typeof(Cache<>) 50 | ); 51 | return new List(result); 52 | 53 | } 54 | 55 | public static void AddType(Type cacheType) 56 | { 57 | var argumentType = cacheType.GetGenericArguments()[0]; 58 | CacheCounter[argumentType] = 0; 59 | NamedCacheCounter[argumentType] = new Dictionary(); 60 | 61 | _cacheTypes.Add(cacheType); 62 | var eventInfo = cacheType.GetEvent("AddedAny"); 63 | SubscriveToEvent(eventInfo, null, "OnAnyAdded"); 64 | var removedEventInfo = cacheType.GetEvent("RemovedAny"); 65 | SubscriveToEvent(removedEventInfo, null, "OnAnyRemoved"); 66 | } 67 | 68 | public static List GetCacheClosedTypes() 69 | { 70 | return _cacheTypes; 71 | } 72 | 73 | private static void SubscriveToEvent(EventInfo eventInfo, object targetObject, string targetMethod) 74 | { 75 | ConstructorInfo constructor = eventInfo.EventHandlerType.GetConstructors()[0]; 76 | Delegate handler = (Delegate)constructor.Invoke(new object[] 77 | { 78 | null, 79 | typeof(CacheLog).GetMethod(targetMethod, BindingFlags.Static | BindingFlags.NonPublic).MethodHandle.GetFunctionPointer() 80 | }); 81 | eventInfo.AddEventHandler(null, handler); 82 | } 83 | 84 | private static void OnAnyAdded(object sernder, object args) 85 | { 86 | AnyAdded(sernder, args); 87 | } 88 | 89 | private static void OnAnyRemoved(object sernder, object args) 90 | { 91 | AnyRemoved(sernder, args); 92 | } 93 | } 94 | } 95 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/CacheLog.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b862f4f1483d44a4294029da10158f87 3 | timeCreated: 1500838158 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/CacheRegister.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace Grygus.Utilities.Pool 7 | { 8 | // public class PoolStatus 9 | // { 10 | // public string Name; 11 | // public string Count; 12 | // } 13 | // public interface IRegisterLog 14 | // { 15 | // List GetLog(); 16 | // } 17 | public static partial class Cache where T : class 18 | { 19 | public class CacheRegister 20 | { 21 | // internal static event PoolStateChangedEventHandler Added = (sender, arg) => { }; 22 | // internal static event PoolStateChangedEventHandler Removed = (sender, arg) => { }; 23 | 24 | private static Dictionary> _namedCache; 25 | 26 | public CacheRegister() 27 | { 28 | _namedCache = new Dictionary>(); 29 | } 30 | public IPool this[string poolName] 31 | { 32 | get 33 | { 34 | if (!_namedCache.ContainsKey(poolName)) 35 | { 36 | _namedCache[poolName] = new CacheInternal(poolName); 37 | _namedCache[poolName].Added += (sender, arg) => AddedAny(sender, arg); 38 | _namedCache[poolName].Removed += (sender, arg) => RemovedAny(sender, arg); 39 | } 40 | return _namedCache[poolName]; 41 | } 42 | } 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/CacheRegister.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e6ba0207d6347bf4d984a29b0ae94916 3 | timeCreated: 1500502566 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/IPool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace Grygus.Utilities.Pool 7 | { 8 | public interface IPool 9 | { 10 | int Count { get; } 11 | 12 | event PoolStateChangedEventHandler Added; 13 | event PoolStateChangedEventHandler Removed; 14 | 15 | T Pop(); 16 | void Push(T item); 17 | IPool Generate(int count); 18 | IPool SetFactory(Func factoryFunc); 19 | IPool SetResetAction(Action resetAction); 20 | IPool AllowExpand(); 21 | IPool DoNotExpand(); 22 | IPool AllowRecycle(); 23 | IPool DoNotRecycle(); 24 | IPool Reset(); 25 | void Clear(); 26 | } 27 | 28 | public interface IPool 29 | { 30 | string Name { get; } 31 | } 32 | } -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/IPool.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7ceb96b44676ac04ea0eae307cf8bce0 3 | timeCreated: 1498499269 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/NoObjectsInPoolException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace Grygus.Utilities.Pool 7 | { 8 | public class NoObjectsInPoolException : System.Exception 9 | { 10 | public NoObjectsInPoolException() { } 11 | public NoObjectsInPoolException(Type cacheType, string cacheName) 12 | : this("No objects left in cache " + cacheType.Name + "|"+cacheName) { } 13 | public NoObjectsInPoolException(string message) : base(message) { } 14 | public NoObjectsInPoolException(string message, System.Exception inner) : base(message, inner) { } 15 | protected NoObjectsInPoolException( 16 | System.Runtime.Serialization.SerializationInfo info, 17 | System.Runtime.Serialization.StreamingContext context) : base(info, context) { } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/NoObjectsInPoolException.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 294b24dc2f53b9f4ca4c958c1098539f 3 | timeCreated: 1501445956 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/ObjectAlreadyInPoolException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace Grygus.Utilities.Pool 7 | { 8 | public class ObjectAlreadyInPoolException : System.Exception 9 | { 10 | public ObjectAlreadyInPoolException() { } 11 | public ObjectAlreadyInPoolException(Type cacheType, string cacheName) 12 | : this("Object is already in cached " + cacheType.Name + "|"+cacheName) { } 13 | public ObjectAlreadyInPoolException(string message) : base(message) { } 14 | public ObjectAlreadyInPoolException(string message, System.Exception inner) : base(message, inner) { } 15 | protected ObjectAlreadyInPoolException( 16 | System.Runtime.Serialization.SerializationInfo info, 17 | System.Runtime.Serialization.StreamingContext context) : base(info, context) { } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/ObjectAlreadyInPoolException.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a853e826ab6305e4eaa28634d362e415 3 | timeCreated: 1501445956 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Tests.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8a5c337a4a19fb34e98f410ca3ef1ad0 3 | folderAsset: yes 4 | timeCreated: 1498499268 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Tests/CacheStorageTest.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace Grygus.Utilities.Pool.Tests 7 | { 8 | class CacheStorageTest 9 | { 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Tests/CacheStorageTest.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8d9f622ecde7ea7459465162ef4f21ab 3 | timeCreated: 1498499269 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3e70b704493d8774082fa9bf5a821d1f 3 | folderAsset: yes 4 | timeCreated: 1500233642 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b7f450ad23fbb394bb8ba6bcca878fca 3 | folderAsset: yes 4 | timeCreated: 1501362759 5 | licenseType: Pro 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor/UnityPoolDrawer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | using System.Collections; 4 | using System.Collections.Generic; 5 | using System.Linq; 6 | using System.Reflection; 7 | using UnityEditor; 8 | 9 | namespace Grygus.Utilities.Pool.Unity 10 | { 11 | [CustomPropertyDrawer(typeof(UnityPool))] 12 | public class UnityPoolDrawer : PropertyDrawer 13 | { 14 | private float lineHeight { get { return EditorGUIUtility.singleLineHeight; } } 15 | 16 | public override void OnGUI(Rect position, SerializedProperty property, GUIContent label) 17 | { 18 | SerializedProperty prefabProperty = property.FindPropertyRelative("Prefab"); 19 | SerializedProperty nameProperty = property.FindPropertyRelative("Name"); 20 | SerializedProperty sizeProperty = property.FindPropertyRelative("Size"); 21 | SerializedProperty allowExpandProperty = property.FindPropertyRelative("AllowExpand"); 22 | SerializedProperty allowRecycleProperty = property.FindPropertyRelative("AllowRecycle"); 23 | 24 | GUIStyle buttonStyle = new GUIStyle(EditorStyles.toolbarButton); 25 | var headerPosition = new Rect(position.x, position.y, position.width, 20); 26 | GUI.Box(headerPosition, "", EditorStyles.toolbar); 27 | 28 | var layoutNavigator = new RectPositionWrapper(position); 29 | 30 | 31 | GUI.Label(layoutNavigator.ReserveDrawSpace(0.25f), string.Empty); 32 | 33 | allowExpandProperty.boolValue = GUI.Toggle(layoutNavigator.ReserveDrawSpace(0.25f), allowExpandProperty.boolValue, "Expand", buttonStyle); 34 | allowRecycleProperty.boolValue = GUI.Toggle(layoutNavigator.ReserveDrawSpace(0.25f), allowRecycleProperty.boolValue, "Recycle", 35 | buttonStyle); 36 | if (GUI.Button(layoutNavigator.ReserveDrawSpace(0.25f), "X",buttonStyle)) 37 | { 38 | Delete(property); 39 | } 40 | property.isExpanded = EditorGUI.Foldout(headerPosition, property.isExpanded, nameProperty.stringValue); 41 | 42 | if (property.isExpanded) 43 | { 44 | 45 | GUI.Box(position, "", GUI.skin.box); 46 | layoutNavigator.MoveNextLine(); 47 | layoutNavigator.Span(); 48 | layoutNavigator.Span(); 49 | EditorGUI.PropertyField(layoutNavigator.ReserveDrawSpace(1f), sizeProperty); 50 | layoutNavigator.MoveNextLine(); 51 | EditorGUI.BeginChangeCheck(); 52 | EditorGUI.PropertyField(layoutNavigator.ReserveDrawSpace(1f), prefabProperty); 53 | if (EditorGUI.EndChangeCheck()) 54 | { 55 | if (prefabProperty.objectReferenceValue) 56 | nameProperty.stringValue = prefabProperty.objectReferenceValue.name; 57 | } 58 | } 59 | } 60 | 61 | 62 | private void DrawHeader(Rect position, string poolName, SerializedProperty property) 63 | { 64 | 65 | } 66 | 67 | public override float GetPropertyHeight(SerializedProperty property, GUIContent label) 68 | { 69 | return property.isExpanded ? lineHeight * 3 + 4 : lineHeight; 70 | } 71 | 72 | private UnityStorage GetPoolObject(SerializedProperty property) 73 | { 74 | var obj = property.serializedObject.targetObject; 75 | var filedName = fieldInfo.Name; 76 | var type = obj.GetType(); 77 | 78 | return (UnityStorage)type.GetField(filedName).GetValue(obj); 79 | } 80 | 81 | private void Delete(SerializedProperty property) 82 | { 83 | int lIndex = property.propertyPath.IndexOf("["); 84 | var propPath = property.propertyPath.Remove(0, lIndex + 1); 85 | propPath = propPath.Replace("]", ""); 86 | int index = int.Parse(propPath); 87 | 88 | var parent = PropertyDrawerHelper.GetParent(property); 89 | 90 | 91 | 92 | var fi = fieldInfo.GetValue(parent) as List; 93 | var val = fi[index]; 94 | fi.Remove(val); 95 | } 96 | } 97 | 98 | 99 | public class RectPositionWrapper 100 | { 101 | private Rect _startPosition; 102 | private Rect _currentPosition; 103 | public RectPositionWrapper(Rect position) 104 | { 105 | _startPosition = position; 106 | _currentPosition = _startPosition; 107 | _currentPosition.width = 0; 108 | _currentPosition.height = EditorGUIUtility.singleLineHeight; 109 | } 110 | 111 | public Rect MoveNextLine() 112 | { 113 | _currentPosition.y += EditorGUIUtility.singleLineHeight; 114 | _currentPosition.width = 0; 115 | _currentPosition.x = _startPosition.x; 116 | return _currentPosition; 117 | } 118 | 119 | public Rect ReserveDrawSpace(float widthRatio) 120 | { 121 | _currentPosition.x = Mathf.Clamp(_currentPosition.x + _currentPosition.width, _startPosition.x, 122 | _startPosition.x + _startPosition.width); 123 | _currentPosition.width = _startPosition.width * widthRatio; 124 | 125 | return _currentPosition; 126 | } 127 | 128 | public Rect GetLeftSpace() 129 | { 130 | _currentPosition.x = _startPosition.x; 131 | _currentPosition.height = _startPosition.height - (_currentPosition.y - _startPosition.y); 132 | _currentPosition.width = _startPosition.width; 133 | return _currentPosition; 134 | } 135 | 136 | public Rect Span() 137 | { 138 | _currentPosition.y += 2f; 139 | _currentPosition.width = 0; 140 | _currentPosition.x = _startPosition.x; 141 | return _currentPosition; 142 | } 143 | } 144 | public static class PropertyDrawerHelper 145 | { 146 | 147 | public static object GetParent(SerializedProperty prop) 148 | { 149 | var path = prop.propertyPath.Replace(".Array.data[", "["); 150 | object obj = prop.serializedObject.targetObject; 151 | var elements = path.Split('.'); 152 | foreach (var element in elements.Take(elements.Length - 1)) 153 | { 154 | if (element.Contains("[")) 155 | { 156 | var elementName = element.Substring(0, element.IndexOf("[")); 157 | var index = Convert.ToInt32(element.Substring(element.IndexOf("[")).Replace("[", "").Replace("]", "")); 158 | obj = GetValue(obj, elementName, index); 159 | } 160 | else 161 | { 162 | obj = GetValue(obj, element); 163 | } 164 | } 165 | return obj; 166 | } 167 | 168 | public static object GetValue(object source, string name) 169 | { 170 | if (source == null) 171 | return null; 172 | var type = source.GetType(); 173 | var f = type.GetField(name, BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance); 174 | if (f == null) 175 | { 176 | var p = type.GetProperty(name, BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance | BindingFlags.IgnoreCase); 177 | if (p == null) 178 | return null; 179 | return p.GetValue(source, null); 180 | } 181 | return f.GetValue(source); 182 | } 183 | 184 | public static object GetValue(object source, string name, int index) 185 | { 186 | var enumerable = GetValue(source, name) as IEnumerable; 187 | var enm = enumerable.GetEnumerator(); 188 | while (index-- >= 0) 189 | enm.MoveNext(); 190 | return enm.Current; 191 | } 192 | } 193 | } 194 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor/UnityPoolDrawer.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 63d973cd27fe36d4baef24355f54b46d 3 | timeCreated: 1501617301 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor/UnityStorageDrawer.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections; 3 | using System.Linq; 4 | using Grygus.Utilities.Pool.Unity; 5 | using UnityEditor; 6 | 7 | 8 | [CustomEditor(typeof(UnityStorage))] 9 | public class UnityStorageInspector : Editor 10 | { 11 | 12 | private UnityStorage _target; 13 | private GUIStyle background; 14 | private GUIStyle poolBackground; 15 | private GUIStyle _toolbarStyle; 16 | private GUIStyle dropBox; 17 | 18 | private void OnEnable() 19 | { 20 | _target = target as UnityStorage; 21 | background = new GUIStyle(); 22 | poolBackground = new GUIStyle(); 23 | dropBox = new GUIStyle(); 24 | 25 | background.normal.background = MakeTex(new Color(0.5f, 0.5f, 0.5f, 0.5f)); 26 | poolBackground.normal.background = MakeTex(new Color(0.3f, 0.3f, 0.3f, 0.2f)); 27 | dropBox.normal.background = MakeTex(new Color(0.2f, 0.5f, 0.2f, 0.5f)); 28 | 29 | poolBackground.margin = new RectOffset(2, 2, 2, 2); 30 | dropBox.margin = new RectOffset(4, 4, 4, 4); 31 | 32 | dropBox.alignment = TextAnchor.MiddleCenter; 33 | 34 | dropBox.fontSize = 14; 35 | 36 | dropBox.normal.textColor = Color.white; 37 | 38 | } 39 | 40 | public override void OnInspectorGUI() 41 | { 42 | DropArea(); 43 | base.OnInspectorGUI(); 44 | 45 | } 46 | private void DropArea() 47 | { 48 | GUILayout.Box("Drop prefabs here", dropBox, GUILayout.ExpandWidth(true), GUILayout.Height(35)); 49 | 50 | EventType eventType = Event.current.type; 51 | bool isAccepted = false; 52 | 53 | if (eventType == EventType.DragUpdated || eventType == EventType.DragPerform) 54 | { 55 | DragAndDrop.visualMode = DragAndDropVisualMode.Copy; 56 | 57 | if (eventType == EventType.DragPerform) 58 | { 59 | DragAndDrop.AcceptDrag(); 60 | isAccepted = true; 61 | } 62 | Event.current.Use(); 63 | } 64 | 65 | if (isAccepted) 66 | { 67 | var pools = DragAndDrop.objectReferences 68 | .Where(obj => obj.GetType() == typeof(GameObject)) 69 | .Cast() 70 | .Where(obj => PrefabUtility.GetPrefabType(obj) == PrefabType.Prefab) 71 | .Except(_target.Pools.Select(_=>_.Prefab).ToList()) 72 | .Select(obj => new UnityPool() {Prefab = obj,Name = obj.name}); 73 | 74 | _target.Pools.AddRange(pools); 75 | } 76 | } 77 | private Texture2D MakeTex(Color col) 78 | { 79 | Color[] pix = new Color[1 * 1]; 80 | 81 | for (int i = 0; i < pix.Length; i++) 82 | pix[i] = col; 83 | 84 | Texture2D result = new Texture2D(1, 1, TextureFormat.ARGB32, false); 85 | result.hideFlags = HideFlags.HideAndDontSave; 86 | result.SetPixels(pix); 87 | result.Apply(); 88 | 89 | return result; 90 | } 91 | } 92 | 93 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor/UnityStorageDrawer.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e7c4dc9cbe0227b4e9b490329a0dd715 3 | timeCreated: 1501614851 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor/UnityStorageLogDrawer.cs: -------------------------------------------------------------------------------- 1 |  2 | using System.Collections.Generic; 3 | using Grygus.Utilities.Pool; 4 | using UnityEditor; 5 | using UnityEngine; 6 | 7 | [CustomEditor(typeof(UnityStorageLog))] 8 | public class UnityStorageLogDrawer : Editor 9 | { 10 | const int DEFAULT_FOLDOUT_MARGIN = 11; 11 | static Dictionary _coloredBoxStyles; 12 | 13 | private UnityStorageLog _target; 14 | 15 | private UnityStorageLogDrawer() 16 | { 17 | _coloredBoxStyles = new Dictionary(); 18 | } 19 | private void OnEnable() 20 | { 21 | _target = target as UnityStorageLog; 22 | } 23 | 24 | public override void OnInspectorGUI() 25 | { 26 | // base.OnInspectorGUI(); 27 | 28 | if (_target.TypeDic != null) 29 | { 30 | int index = 0; 31 | int count = _target.TypeDic.Count; 32 | foreach (var kvp in _target.TypeDic) 33 | { 34 | 35 | var boxStyle = getColoredBoxStyle(count, index); 36 | BeginVerticalBox(boxStyle); 37 | { 38 | EditorGUILayout.LabelField(kvp.Key.ToString()); 39 | EditorGUILayout.IntField("Count", kvp.Value.Count); 40 | foreach (var namedKvp in CacheLog.NamedCacheCounter[kvp.Key]) 41 | { 42 | BeginVerticalBox(boxStyle); 43 | { 44 | BeginHorizontal(); 45 | { 46 | EditorGUILayout.LabelField(namedKvp.Key); 47 | EditorGUILayout.LabelField("Count "+ namedKvp.Value); 48 | } 49 | EndHorizontal(); 50 | } 51 | EndVertical(); 52 | } 53 | } 54 | EndVertical(); 55 | index++; 56 | } 57 | } 58 | } 59 | 60 | public static bool Foldout(bool foldout, string content, int leftMargin = DEFAULT_FOLDOUT_MARGIN) 61 | { 62 | return Foldout(foldout, content, EditorStyles.foldout, leftMargin); 63 | } 64 | 65 | public static bool Foldout(bool foldout, string content, GUIStyle style, int leftMargin = DEFAULT_FOLDOUT_MARGIN) 66 | { 67 | BeginHorizontal(); 68 | GUILayout.Space(leftMargin); 69 | foldout = EditorGUILayout.Foldout(foldout, content, style); 70 | EndHorizontal(); 71 | return foldout; 72 | } 73 | 74 | public static Rect BeginVertical() 75 | { 76 | return EditorGUILayout.BeginVertical(); 77 | } 78 | 79 | public static Rect BeginVerticalBox(GUIStyle style = null) 80 | { 81 | return EditorGUILayout.BeginVertical(style ?? GUI.skin.box); 82 | } 83 | 84 | public static void EndVertical() 85 | { 86 | EditorGUILayout.EndVertical(); 87 | } 88 | 89 | public static Rect BeginHorizontal() 90 | { 91 | return EditorGUILayout.BeginHorizontal(); 92 | } 93 | 94 | public static void EndHorizontal() 95 | { 96 | EditorGUILayout.EndHorizontal(); 97 | } 98 | static GUIStyle getColoredBoxStyle(int totalComponents, int index) 99 | { 100 | GUIStyle[] styles; 101 | if (!_coloredBoxStyles.TryGetValue(totalComponents, out styles)) 102 | { 103 | styles = new GUIStyle[totalComponents]; 104 | for (int i = 0; i < styles.Length; i++) 105 | { 106 | var hue = (float)i / (float)totalComponents; 107 | var componentColor = Color.HSVToRGB(hue, 0.7f, 1f); 108 | componentColor.a = 0.15f; 109 | var style = new GUIStyle(GUI.skin.box); 110 | style.normal.background = createTexture(2, 2, componentColor); 111 | styles[i] = style; 112 | } 113 | _coloredBoxStyles.Add(totalComponents, styles); 114 | } 115 | 116 | return styles[index]; 117 | } 118 | static Texture2D createTexture(int width, int height, Color color) 119 | { 120 | var pixels = new Color[width * height]; 121 | for (int i = 0; i < pixels.Length; ++i) 122 | { 123 | pixels[i] = color; 124 | } 125 | var result = new Texture2D(width, height); 126 | result.SetPixels(pixels); 127 | result.Apply(); 128 | return result; 129 | } 130 | } 131 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/Editor/UnityStorageLogDrawer.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d4834fc3de441d24bb19feadafb70970 3 | timeCreated: 1501362777 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/UnityPool.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | 4 | namespace Grygus.Utilities.Pool.Unity 5 | { 6 | [Serializable] 7 | public class UnityPool 8 | { 9 | public string Name; 10 | public GameObject Prefab; 11 | public bool AllowExpand; 12 | public bool AllowRecycle; 13 | public int Size; 14 | 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/UnityPool.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6b977c37c5d8ddc4d82421e95c2d3b72 3 | timeCreated: 1501614321 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/UnityStorage.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System; 3 | using System.Collections.Generic; 4 | using Grygus.Utilities.Pool; 5 | using Grygus.Utilities.Pool.Unity; 6 | 7 | namespace Grygus.Utilities.Pool.Unity 8 | { 9 | public class UnityStorage : MonoBehaviour 10 | { 11 | public List Pools 12 | { 13 | get { return _pools; } 14 | } 15 | [SerializeField] 16 | private List _pools; 17 | private Cache.CacheRegister _caches; 18 | private void Awake() 19 | { 20 | Initialize(); 21 | } 22 | 23 | private void Initialize() 24 | { 25 | _caches = Cache.Caches; 26 | for (int i = 0; i < _pools.Count; i++) 27 | { 28 | var pool = _pools[i]; 29 | var parent = new GameObject(pool.Prefab.name); 30 | parent.transform.parent = transform; 31 | var cache = _caches[pool.Prefab.name]; 32 | cache.SetFactory(() => 33 | { 34 | var gm = Instantiate(pool.Prefab); 35 | gm.transform.parent = parent.transform; 36 | return gm; 37 | }) 38 | .SetResetAction((item) => 39 | { 40 | item.SetActive(false); 41 | }) 42 | .Generate(pool.Size); 43 | 44 | 45 | if (pool.AllowExpand) cache.AllowExpand(); 46 | if (pool.AllowRecycle) cache.AllowRecycle(); 47 | } 48 | } 49 | 50 | [ContextMenu("TestGenerate")] 51 | public void TestGenerateOne() 52 | { 53 | for (int i = 0; i < _pools.Count; i++) 54 | { 55 | var pool = _pools[i]; 56 | _caches[pool.Prefab.name].Generate(1); 57 | 58 | } 59 | } 60 | } 61 | } -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/UnityStorage.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c7825a584cafa12498d31ae7e4918f39 3 | timeCreated: 1500233679 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/UnityStorageLog.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | using System.Collections; 4 | using System.Collections.Generic; 5 | using System.Reflection; 6 | using Grygus.Utilities.Pool; 7 | using UnityEditor; 8 | 9 | public class UnityStorageLog : MonoBehaviour 10 | { 11 | 12 | [SerializeField] 13 | private List LogTypes; 14 | 15 | [SerializeField] 16 | private int Count; 17 | 18 | public Dictionary TypeDic; 19 | 20 | private void Awake() 21 | { 22 | TypeDic = new Dictionary(); 23 | var pool = Cache.DefaultPool; 24 | var intPool = Cache.DefaultPool; 25 | Initialize(); 26 | Cache.Generate(2); 27 | Cache>.Generate(2); 28 | // Cache.Generate(2);//Generate No COnstructor found Exception to implement 29 | } 30 | 31 | public void Initialize() 32 | { 33 | foreach (var cacheType in CacheLog.GetCacheClosedTypes()) 34 | { 35 | var argumentType = cacheType.GetGenericArguments()[0]; 36 | var log = new TypeLog() 37 | { 38 | Type = argumentType.Name 39 | 40 | }; 41 | 42 | LogTypes.Add(log); 43 | TypeDic[argumentType] = log; 44 | log.Count = CacheLog.CacheCounter[argumentType]; 45 | // SubscribeToCacheEvents(cacheType); 46 | } 47 | CacheLog.AnyAdded+=AddedHandler; 48 | CacheLog.AnyRemoved+=RemovedHandler; 49 | } 50 | 51 | public void AddedHandler(object sender, object arg) 52 | { 53 | var argumentType = sender.GetType().GetGenericArguments()[0]; 54 | if (!TypeDic.ContainsKey(argumentType)) 55 | { 56 | var log = new TypeLog() 57 | { 58 | Type = argumentType.Name 59 | 60 | }; 61 | LogTypes.Add(log); 62 | TypeDic[argumentType] = log; 63 | log.Count = CacheLog.CacheCounter[argumentType]; 64 | } 65 | else 66 | { 67 | TypeDic[argumentType].Count++; 68 | } 69 | } 70 | 71 | public void RemovedHandler(object sender, object arg) 72 | { 73 | var argumentType = sender.GetType().GetGenericArguments()[0]; 74 | TypeDic[argumentType].Count--; 75 | } 76 | 77 | private void SubscribeToCacheEvents(Type cacheType) 78 | { 79 | var eventInfo = cacheType.GetEvent("AddedAny"); 80 | SubscriveToEvent(eventInfo,this,"AddedHandler"); 81 | var removedEventInfo = cacheType.GetEvent("RemovedAny"); 82 | SubscriveToEvent(removedEventInfo ,this,"RemovedHandler"); 83 | /*var handlerType = eventInfo.EventHandlerType.GetGenericArguments()[0]; 84 | ConstructorInfo constructor = eventInfo.EventHandlerType.GetConstructors()[0]; 85 | // cacheType.GetGenericTypeDefinition().GetEvent("Added").EventHandlerType 86 | // .MakeGenericType(handlerType).GetConstructors()[0]; 87 | Delegate handler = (Delegate)constructor 88 | .Invoke(new object[] 89 | { 90 | this, 91 | GetType().GetMethod("SuccessMethod").MethodHandle.GetFunctionPointer() 92 | }); 93 | eventInfo.AddEventHandler(null, handler);*/ 94 | } 95 | 96 | private void SubscriveToEvent(EventInfo eventInfo, object targetObject, string targetMethod) 97 | { 98 | ConstructorInfo constructor = eventInfo.EventHandlerType.GetConstructors()[0]; 99 | Delegate handler = (Delegate)constructor.Invoke(new object[] 100 | { 101 | targetObject, 102 | targetObject.GetType().GetMethod(targetMethod).MethodHandle.GetFunctionPointer() 103 | }); 104 | eventInfo.AddEventHandler(null, handler); 105 | } 106 | } 107 | 108 | [System.Serializable] 109 | public class TypeLog 110 | { 111 | public string Type; 112 | public int Count; 113 | // public int InUse; 114 | // public int TotalCached; 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /Assets/Unity Cache/Scripts/Grygus/Utilities/Pool/Unity/UnityStorageLog.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c5d45b1350a01a84d9ef90c6a38e95ae 3 | timeCreated: 1500410143 4 | licenseType: Pro 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Docs/PoolUML.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/grygus/Unity-Cache-System/7eebe2b2d9e58579645bedf2de8a53f53edd3c0f/Docs/PoolUML.png -------------------------------------------------------------------------------- /Docs/UnityStorage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/grygus/Unity-Cache-System/7eebe2b2d9e58579645bedf2de8a53f53edd3c0f/Docs/UnityStorage.png -------------------------------------------------------------------------------- /Docs/UnityStorageLog.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/grygus/Unity-Cache-System/7eebe2b2d9e58579645bedf2de8a53f53edd3c0f/Docs/UnityStorageLog.png -------------------------------------------------------------------------------- /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: 0 12 | m_VirtualVoiceCount: 512 13 | m_RealVoiceCount: 32 14 | m_SpatializerPlugin: 15 | m_DisableAudio: 0 16 | m_VirtualizeEffects: 1 17 | -------------------------------------------------------------------------------- /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: 2 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_SolverIterationCount: 6 13 | m_SolverVelocityIterations: 1 14 | m_QueriesHitTriggers: 1 15 | m_EnableAdaptiveForce: 0 16 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 17 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /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: 3 7 | m_ExternalVersionControlSupport: Visible Meta Files 8 | m_SerializationMode: 2 9 | m_WebSecurityEmulationEnabled: 0 10 | m_WebSecurityEmulationHostUrl: http://www.mydomain.com/mygame.unity3d 11 | m_DefaultBehaviorMode: 0 12 | m_SpritePackerMode: 2 13 | m_SpritePackerPaddingPower: 1 14 | m_ProjectGenerationIncludedExtensions: txt;xml;fnt;cd 15 | m_ProjectGenerationRootNamespace: 16 | -------------------------------------------------------------------------------- /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: 7 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: 10782, guid: 0000000000000000f000000000000000, type: 0} 39 | m_PreloadedShaders: [] 40 | m_SpritesDefaultMaterial: {fileID: 10754, guid: 0000000000000000f000000000000000, 41 | type: 0} 42 | m_ShaderSettings_Tier1: 43 | useCascadedShadowMaps: 1 44 | standardShaderQuality: 2 45 | useReflectionProbeBoxProjection: 1 46 | useReflectionProbeBlending: 1 47 | m_ShaderSettings_Tier2: 48 | useCascadedShadowMaps: 1 49 | standardShaderQuality: 2 50 | useReflectionProbeBoxProjection: 1 51 | useReflectionProbeBlending: 1 52 | m_ShaderSettings_Tier3: 53 | useCascadedShadowMaps: 1 54 | standardShaderQuality: 2 55 | useReflectionProbeBoxProjection: 1 56 | useReflectionProbeBlending: 1 57 | m_BuildTargetShaderSettings: [] 58 | m_LightmapStripping: 0 59 | m_FogStripping: 0 60 | m_LightmapKeepPlain: 1 61 | m_LightmapKeepDirCombined: 1 62 | m_LightmapKeepDirSeparate: 1 63 | m_LightmapKeepDynamicPlain: 1 64 | m_LightmapKeepDynamicDirCombined: 1 65 | m_LightmapKeepDynamicDirSeparate: 1 66 | m_FogKeepLinear: 1 67 | m_FogKeepExp: 1 68 | m_FogKeepExp2: 1 69 | -------------------------------------------------------------------------------- /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 | NavMeshAreas: 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 | -------------------------------------------------------------------------------- /ProjectSettings/NetworkManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!149 &1 4 | NetworkManager: 5 | m_ObjectHideFlags: 0 6 | m_DebugLevel: 0 7 | m_Sendrate: 15 8 | m_AssetToPrefab: {} 9 | -------------------------------------------------------------------------------- /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: 2 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_MinPenetrationForPenalty: 0.01 17 | m_BaumgarteScale: 0.2 18 | m_BaumgarteTimeOfImpactScale: 0.75 19 | m_TimeToSleep: 0.5 20 | m_LinearSleepTolerance: 0.01 21 | m_AngularSleepTolerance: 2 22 | m_QueriesHitTriggers: 1 23 | m_QueriesStartInColliders: 1 24 | m_ChangeStopsCallbacks: 0 25 | m_AlwaysShowColliders: 0 26 | m_ShowColliderSleep: 1 27 | m_ShowColliderContacts: 0 28 | m_ContactArrowScale: 0.2 29 | m_ColliderAwakeColor: {r: 0.5686275, g: 0.95686275, b: 0.54509807, a: 0.7529412} 30 | m_ColliderAsleepColor: {r: 0.5686275, g: 0.95686275, b: 0.54509807, a: 0.36078432} 31 | m_ColliderContactColor: {r: 1, g: 0, b: 1, a: 0.6862745} 32 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 33 | -------------------------------------------------------------------------------- /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: 8 7 | productGUID: 70c338d0c19f13f4085a53d69ec285ef 8 | AndroidProfiler: 0 9 | defaultScreenOrientation: 4 10 | targetDevice: 2 11 | useOnDemandResources: 0 12 | accelerometerFrequency: 60 13 | companyName: DefaultCompany 14 | productName: Cache System 15 | defaultCursor: {fileID: 0} 16 | cursorHotspot: {x: 0, y: 0} 17 | m_SplashScreenStyle: 0 18 | m_ShowUnitySplashScreen: 1 19 | m_VirtualRealitySplashScreen: {fileID: 0} 20 | defaultScreenWidth: 1024 21 | defaultScreenHeight: 768 22 | defaultScreenWidthWeb: 960 23 | defaultScreenHeightWeb: 600 24 | m_RenderingPath: 1 25 | m_MobileRenderingPath: 1 26 | m_ActiveColorSpace: 0 27 | m_MTRendering: 1 28 | m_MobileMTRendering: 0 29 | m_StackTraceTypes: 010000000100000001000000010000000100000001000000 30 | iosShowActivityIndicatorOnLoading: -1 31 | androidShowActivityIndicatorOnLoading: -1 32 | iosAppInBackgroundBehavior: 0 33 | displayResolutionDialog: 1 34 | iosAllowHTTPDownload: 1 35 | allowedAutorotateToPortrait: 1 36 | allowedAutorotateToPortraitUpsideDown: 1 37 | allowedAutorotateToLandscapeRight: 1 38 | allowedAutorotateToLandscapeLeft: 1 39 | useOSAutorotation: 1 40 | use32BitDisplayBuffer: 1 41 | disableDepthAndStencilBuffers: 0 42 | defaultIsFullScreen: 1 43 | defaultIsNativeResolution: 1 44 | runInBackground: 0 45 | captureSingleScreen: 0 46 | Override IPod Music: 0 47 | Prepare IOS For Recording: 0 48 | submitAnalytics: 1 49 | usePlayerLog: 1 50 | bakeCollisionMeshes: 0 51 | forceSingleInstance: 0 52 | resizableWindow: 0 53 | useMacAppStoreValidation: 0 54 | gpuSkinning: 0 55 | graphicsJobs: 0 56 | xboxPIXTextureCapture: 0 57 | xboxEnableAvatar: 0 58 | xboxEnableKinect: 0 59 | xboxEnableKinectAutoTracking: 0 60 | xboxEnableFitness: 0 61 | visibleInBackground: 0 62 | allowFullscreenSwitch: 1 63 | macFullscreenMode: 2 64 | d3d9FullscreenMode: 1 65 | d3d11FullscreenMode: 1 66 | xboxSpeechDB: 0 67 | xboxEnableHeadOrientation: 0 68 | xboxEnableGuest: 0 69 | xboxEnablePIXSampling: 0 70 | n3dsDisableStereoscopicView: 0 71 | n3dsEnableSharedListOpt: 1 72 | n3dsEnableVSync: 0 73 | uiUse16BitDepthBuffer: 0 74 | ignoreAlphaClear: 0 75 | xboxOneResolution: 0 76 | xboxOneMonoLoggingLevel: 0 77 | xboxOneLoggingLevel: 1 78 | ps3SplashScreen: {fileID: 0} 79 | videoMemoryForVertexBuffers: 0 80 | psp2PowerMode: 0 81 | psp2AcquireBGM: 1 82 | wiiUTVResolution: 0 83 | wiiUGamePadMSAA: 1 84 | wiiUSupportsNunchuk: 0 85 | wiiUSupportsClassicController: 0 86 | wiiUSupportsBalanceBoard: 0 87 | wiiUSupportsMotionPlus: 0 88 | wiiUSupportsProController: 0 89 | wiiUAllowScreenCapture: 1 90 | wiiUControllerCount: 0 91 | m_SupportedAspectRatios: 92 | 4:3: 1 93 | 5:4: 1 94 | 16:10: 1 95 | 16:9: 1 96 | Others: 1 97 | bundleIdentifier: com.Company.ProductName 98 | bundleVersion: 1.0 99 | preloadedAssets: [] 100 | metroEnableIndependentInputSource: 0 101 | xboxOneDisableKinectGpuReservation: 0 102 | singlePassStereoRendering: 0 103 | protectGraphicsMemory: 0 104 | AndroidBundleVersionCode: 1 105 | AndroidMinSdkVersion: 9 106 | AndroidPreferredInstallLocation: 1 107 | aotOptions: 108 | apiCompatibilityLevel: 2 109 | stripEngineCode: 1 110 | iPhoneStrippingLevel: 0 111 | iPhoneScriptCallOptimization: 0 112 | iPhoneBuildNumber: 0 113 | ForceInternetPermission: 0 114 | ForceSDCardPermission: 0 115 | CreateWallpaper: 0 116 | APKExpansionFiles: 0 117 | preloadShaders: 0 118 | StripUnusedMeshComponents: 0 119 | VertexChannelCompressionMask: 120 | serializedVersion: 2 121 | m_Bits: 238 122 | iPhoneSdkVersion: 988 123 | iPhoneTargetOSVersion: 24 124 | tvOSSdkVersion: 0 125 | tvOSTargetOSVersion: 900 126 | tvOSRequireExtendedGameController: 0 127 | uIPrerenderedIcon: 0 128 | uIRequiresPersistentWiFi: 0 129 | uIRequiresFullScreen: 1 130 | uIStatusBarHidden: 1 131 | uIExitOnSuspend: 0 132 | uIStatusBarStyle: 0 133 | iPhoneSplashScreen: {fileID: 0} 134 | iPhoneHighResSplashScreen: {fileID: 0} 135 | iPhoneTallHighResSplashScreen: {fileID: 0} 136 | iPhone47inSplashScreen: {fileID: 0} 137 | iPhone55inPortraitSplashScreen: {fileID: 0} 138 | iPhone55inLandscapeSplashScreen: {fileID: 0} 139 | iPadPortraitSplashScreen: {fileID: 0} 140 | iPadHighResPortraitSplashScreen: {fileID: 0} 141 | iPadLandscapeSplashScreen: {fileID: 0} 142 | iPadHighResLandscapeSplashScreen: {fileID: 0} 143 | appleTVSplashScreen: {fileID: 0} 144 | tvOSSmallIconLayers: [] 145 | tvOSLargeIconLayers: [] 146 | tvOSTopShelfImageLayers: [] 147 | iOSLaunchScreenType: 0 148 | iOSLaunchScreenPortrait: {fileID: 0} 149 | iOSLaunchScreenLandscape: {fileID: 0} 150 | iOSLaunchScreenBackgroundColor: 151 | serializedVersion: 2 152 | rgba: 0 153 | iOSLaunchScreenFillPct: 100 154 | iOSLaunchScreenSize: 100 155 | iOSLaunchScreenCustomXibPath: 156 | iOSLaunchScreeniPadType: 0 157 | iOSLaunchScreeniPadImage: {fileID: 0} 158 | iOSLaunchScreeniPadBackgroundColor: 159 | serializedVersion: 2 160 | rgba: 0 161 | iOSLaunchScreeniPadFillPct: 100 162 | iOSLaunchScreeniPadSize: 100 163 | iOSLaunchScreeniPadCustomXibPath: 164 | iOSDeviceRequirements: [] 165 | iOSURLSchemes: [] 166 | appleDeveloperTeamID: 167 | AndroidTargetDevice: 0 168 | AndroidSplashScreenScale: 0 169 | androidSplashScreen: {fileID: 0} 170 | AndroidKeystoreName: 171 | AndroidKeyaliasName: 172 | AndroidTVCompatibility: 1 173 | AndroidIsGame: 1 174 | androidEnableBanner: 1 175 | m_AndroidBanners: 176 | - width: 320 177 | height: 180 178 | banner: {fileID: 0} 179 | androidGamepadSupportLevel: 0 180 | resolutionDialogBanner: {fileID: 0} 181 | m_BuildTargetIcons: 182 | - m_BuildTarget: 183 | m_Icons: 184 | - serializedVersion: 2 185 | m_Icon: {fileID: 0} 186 | m_Width: 128 187 | m_Height: 128 188 | m_BuildTargetBatching: [] 189 | m_BuildTargetGraphicsAPIs: [] 190 | webPlayerTemplate: APPLICATION:Default 191 | m_TemplateCustomTags: {} 192 | wiiUTitleID: 0005000011000000 193 | wiiUGroupID: 00010000 194 | wiiUCommonSaveSize: 4096 195 | wiiUAccountSaveSize: 2048 196 | wiiUOlvAccessKey: 0 197 | wiiUTinCode: 0 198 | wiiUJoinGameId: 0 199 | wiiUJoinGameModeMask: 0000000000000000 200 | wiiUCommonBossSize: 0 201 | wiiUAccountBossSize: 0 202 | wiiUAddOnUniqueIDs: [] 203 | wiiUMainThreadStackSize: 3072 204 | wiiULoaderThreadStackSize: 1024 205 | wiiUSystemHeapSize: 128 206 | wiiUTVStartupScreen: {fileID: 0} 207 | wiiUGamePadStartupScreen: {fileID: 0} 208 | wiiUDrcBufferDisabled: 0 209 | wiiUProfilerLibPath: 210 | actionOnDotNetUnhandledException: 1 211 | enableInternalProfiler: 0 212 | logObjCUncaughtExceptions: 1 213 | enableCrashReportAPI: 0 214 | cameraUsageDescription: 215 | locationUsageDescription: 216 | microphoneUsageDescription: 217 | XboxTitleId: 218 | XboxImageXexPath: 219 | XboxSpaPath: 220 | XboxGenerateSpa: 0 221 | XboxDeployKinectResources: 0 222 | XboxSplashScreen: {fileID: 0} 223 | xboxEnableSpeech: 0 224 | xboxAdditionalTitleMemorySize: 0 225 | xboxDeployKinectHeadOrientation: 0 226 | xboxDeployKinectHeadPosition: 0 227 | ps3TitleConfigPath: 228 | ps3DLCConfigPath: 229 | ps3ThumbnailPath: 230 | ps3BackgroundPath: 231 | ps3SoundPath: 232 | ps3NPAgeRating: 12 233 | ps3TrophyCommId: 234 | ps3NpCommunicationPassphrase: 235 | ps3TrophyPackagePath: 236 | ps3BootCheckMaxSaveGameSizeKB: 128 237 | ps3TrophyCommSig: 238 | ps3SaveGameSlots: 1 239 | ps3TrialMode: 0 240 | ps3VideoMemoryForAudio: 0 241 | ps3EnableVerboseMemoryStats: 0 242 | ps3UseSPUForUmbra: 0 243 | ps3EnableMoveSupport: 1 244 | ps3DisableDolbyEncoding: 0 245 | ps4NPAgeRating: 12 246 | ps4NPTitleSecret: 247 | ps4NPTrophyPackPath: 248 | ps4ParentalLevel: 1 249 | ps4ContentID: ED1633-NPXX51362_00-0000000000000000 250 | ps4Category: 0 251 | ps4MasterVersion: 01.00 252 | ps4AppVersion: 01.00 253 | ps4AppType: 0 254 | ps4ParamSfxPath: 255 | ps4VideoOutPixelFormat: 0 256 | ps4VideoOutInitialWidth: 1920 257 | ps4VideoOutReprojectionRate: 120 258 | ps4PronunciationXMLPath: 259 | ps4PronunciationSIGPath: 260 | ps4BackgroundImagePath: 261 | ps4StartupImagePath: 262 | ps4SaveDataImagePath: 263 | ps4SdkOverride: 264 | ps4BGMPath: 265 | ps4ShareFilePath: 266 | ps4ShareOverlayImagePath: 267 | ps4PrivacyGuardImagePath: 268 | ps4NPtitleDatPath: 269 | ps4RemotePlayKeyAssignment: -1 270 | ps4RemotePlayKeyMappingDir: 271 | ps4PlayTogetherPlayerCount: 0 272 | ps4EnterButtonAssignment: 1 273 | ps4ApplicationParam1: 0 274 | ps4ApplicationParam2: 0 275 | ps4ApplicationParam3: 0 276 | ps4ApplicationParam4: 0 277 | ps4DownloadDataSize: 0 278 | ps4GarlicHeapSize: 2048 279 | ps4Passcode: frAQBc8Wsa1xVPfvJcrgRYwTiizs2trQ 280 | ps4UseDebugIl2cppLibs: 0 281 | ps4pnSessions: 1 282 | ps4pnPresence: 1 283 | ps4pnFriends: 1 284 | ps4pnGameCustomData: 1 285 | playerPrefsSupport: 0 286 | ps4UseResolutionFallback: 0 287 | restrictedAudioUsageRights: 0 288 | ps4ReprojectionSupport: 0 289 | ps4UseAudio3dBackend: 0 290 | ps4SocialScreenEnabled: 0 291 | ps4ScriptOptimizationLevel: 3 292 | ps4Audio3dVirtualSpeakerCount: 14 293 | ps4attribCpuUsage: 0 294 | ps4PatchPkgPath: 295 | ps4PatchLatestPkgPath: 296 | ps4PatchChangeinfoPath: 297 | ps4PatchDayOne: 0 298 | ps4attribUserManagement: 0 299 | ps4attribMoveSupport: 0 300 | ps4attrib3DSupport: 0 301 | ps4attribShareSupport: 0 302 | ps4attribExclusiveVR: 0 303 | ps4disableAutoHideSplash: 0 304 | ps4IncludedModules: [] 305 | monoEnv: 306 | psp2Splashimage: {fileID: 0} 307 | psp2NPTrophyPackPath: 308 | psp2NPSupportGBMorGJP: 0 309 | psp2NPAgeRating: 12 310 | psp2NPTitleDatPath: 311 | psp2NPCommsID: 312 | psp2NPCommunicationsID: 313 | psp2NPCommsPassphrase: 314 | psp2NPCommsSig: 315 | psp2ParamSfxPath: 316 | psp2ManualPath: 317 | psp2LiveAreaGatePath: 318 | psp2LiveAreaBackroundPath: 319 | psp2LiveAreaPath: 320 | psp2LiveAreaTrialPath: 321 | psp2PatchChangeInfoPath: 322 | psp2PatchOriginalPackage: 323 | psp2PackagePassword: F69AzBlax3CF3EDNhm3soLBPh71Yexui 324 | psp2KeystoneFile: 325 | psp2MemoryExpansionMode: 0 326 | psp2DRMType: 0 327 | psp2StorageType: 0 328 | psp2MediaCapacity: 0 329 | psp2DLCConfigPath: 330 | psp2ThumbnailPath: 331 | psp2BackgroundPath: 332 | psp2SoundPath: 333 | psp2TrophyCommId: 334 | psp2TrophyPackagePath: 335 | psp2PackagedResourcesPath: 336 | psp2SaveDataQuota: 10240 337 | psp2ParentalLevel: 1 338 | psp2ShortTitle: Not Set 339 | psp2ContentID: IV0000-ABCD12345_00-0123456789ABCDEF 340 | psp2Category: 0 341 | psp2MasterVersion: 01.00 342 | psp2AppVersion: 01.00 343 | psp2TVBootMode: 0 344 | psp2EnterButtonAssignment: 2 345 | psp2TVDisableEmu: 0 346 | psp2AllowTwitterDialog: 1 347 | psp2Upgradable: 0 348 | psp2HealthWarning: 0 349 | psp2UseLibLocation: 0 350 | psp2InfoBarOnStartup: 0 351 | psp2InfoBarColor: 0 352 | psp2UseDebugIl2cppLibs: 0 353 | psmSplashimage: {fileID: 0} 354 | spritePackerPolicy: 355 | scriptingDefineSymbols: {} 356 | metroPackageName: Cache System 357 | metroPackageVersion: 358 | metroCertificatePath: 359 | metroCertificatePassword: 360 | metroCertificateSubject: 361 | metroCertificateIssuer: 362 | metroCertificateNotAfter: 0000000000000000 363 | metroApplicationDescription: Cache System 364 | wsaImages: {} 365 | metroTileShortName: 366 | metroCommandLineArgsFile: 367 | metroTileShowName: 0 368 | metroMediumTileShowName: 0 369 | metroLargeTileShowName: 0 370 | metroWideTileShowName: 0 371 | metroDefaultTileSize: 1 372 | metroTileForegroundText: 1 373 | metroTileBackgroundColor: {r: 0.13333334, g: 0.17254902, b: 0.21568628, a: 0} 374 | metroSplashScreenBackgroundColor: {r: 0.12941177, g: 0.17254902, b: 0.21568628, 375 | a: 1} 376 | metroSplashScreenUseBackgroundColor: 0 377 | platformCapabilities: {} 378 | metroFTAName: 379 | metroFTAFileTypes: [] 380 | metroProtocolName: 381 | metroCompilationOverrides: 1 382 | tizenProductDescription: 383 | tizenProductURL: 384 | tizenSigningProfileName: 385 | tizenGPSPermissions: 0 386 | tizenMicrophonePermissions: 0 387 | tizenMinOSVersion: 0 388 | n3dsUseExtSaveData: 0 389 | n3dsCompressStaticMem: 1 390 | n3dsExtSaveDataNumber: 0x12345 391 | n3dsStackSize: 131072 392 | n3dsTargetPlatform: 2 393 | n3dsRegion: 7 394 | n3dsMediaSize: 0 395 | n3dsLogoStyle: 3 396 | n3dsTitle: GameName 397 | n3dsProductCode: 398 | n3dsApplicationId: 0xFF3FF 399 | stvDeviceAddress: 400 | stvProductDescription: 401 | stvProductAuthor: 402 | stvProductAuthorEmail: 403 | stvProductLink: 404 | stvProductCategory: 0 405 | XboxOneProductId: 406 | XboxOneUpdateKey: 407 | XboxOneSandboxId: 408 | XboxOneContentId: 409 | XboxOneTitleId: 410 | XboxOneSCId: 411 | XboxOneGameOsOverridePath: 412 | XboxOnePackagingOverridePath: 413 | XboxOneAppManifestOverridePath: 414 | XboxOnePackageEncryption: 0 415 | XboxOnePackageUpdateGranularity: 2 416 | XboxOneDescription: 417 | XboxOneIsContentPackage: 0 418 | XboxOneEnableGPUVariability: 0 419 | XboxOneSockets: {} 420 | XboxOneSplashScreen: {fileID: 0} 421 | XboxOneAllowedProductIds: [] 422 | XboxOnePersistentLocalStorageSize: 0 423 | intPropertyNames: 424 | - Android::ScriptingBackend 425 | - Standalone::ScriptingBackend 426 | - WebPlayer::ScriptingBackend 427 | Android::ScriptingBackend: 0 428 | Standalone::ScriptingBackend: 0 429 | WebPlayer::ScriptingBackend: 0 430 | boolPropertyNames: 431 | - Android::VR::enable 432 | - Metro::VR::enable 433 | - N3DS::VR::enable 434 | - PS3::VR::enable 435 | - PS4::VR::enable 436 | - PSM::VR::enable 437 | - PSP2::VR::enable 438 | - SamsungTV::VR::enable 439 | - Standalone::VR::enable 440 | - Tizen::VR::enable 441 | - WebGL::VR::enable 442 | - WebPlayer::VR::enable 443 | - WiiU::VR::enable 444 | - Xbox360::VR::enable 445 | - XboxOne::VR::enable 446 | - XboxOne::enus 447 | - iOS::VR::enable 448 | - tvOS::VR::enable 449 | Android::VR::enable: 0 450 | Metro::VR::enable: 0 451 | N3DS::VR::enable: 0 452 | PS3::VR::enable: 0 453 | PS4::VR::enable: 0 454 | PSM::VR::enable: 0 455 | PSP2::VR::enable: 0 456 | SamsungTV::VR::enable: 0 457 | Standalone::VR::enable: 0 458 | Tizen::VR::enable: 0 459 | WebGL::VR::enable: 0 460 | WebPlayer::VR::enable: 0 461 | WiiU::VR::enable: 0 462 | Xbox360::VR::enable: 0 463 | XboxOne::VR::enable: 0 464 | XboxOne::enus: 1 465 | iOS::VR::enable: 0 466 | tvOS::VR::enable: 0 467 | stringPropertyNames: 468 | - Analytics_ServiceEnabled::Analytics_ServiceEnabled 469 | - Build_ServiceEnabled::Build_ServiceEnabled 470 | - Collab_ServiceEnabled::Collab_ServiceEnabled 471 | - ErrorHub_ServiceEnabled::ErrorHub_ServiceEnabled 472 | - Game_Performance_ServiceEnabled::Game_Performance_ServiceEnabled 473 | - Hub_ServiceEnabled::Hub_ServiceEnabled 474 | - Purchasing_ServiceEnabled::Purchasing_ServiceEnabled 475 | - UNet_ServiceEnabled::UNet_ServiceEnabled 476 | - Unity_Ads_ServiceEnabled::Unity_Ads_ServiceEnabled 477 | Analytics_ServiceEnabled::Analytics_ServiceEnabled: False 478 | Build_ServiceEnabled::Build_ServiceEnabled: False 479 | Collab_ServiceEnabled::Collab_ServiceEnabled: False 480 | ErrorHub_ServiceEnabled::ErrorHub_ServiceEnabled: False 481 | Game_Performance_ServiceEnabled::Game_Performance_ServiceEnabled: False 482 | Hub_ServiceEnabled::Hub_ServiceEnabled: False 483 | Purchasing_ServiceEnabled::Purchasing_ServiceEnabled: False 484 | UNet_ServiceEnabled::UNet_ServiceEnabled: False 485 | Unity_Ads_ServiceEnabled::Unity_Ads_ServiceEnabled: False 486 | vectorPropertyNames: 487 | - Android::VR::enabledDevices 488 | - Metro::VR::enabledDevices 489 | - N3DS::VR::enabledDevices 490 | - PS3::VR::enabledDevices 491 | - PS4::VR::enabledDevices 492 | - PSM::VR::enabledDevices 493 | - PSP2::VR::enabledDevices 494 | - SamsungTV::VR::enabledDevices 495 | - Standalone::VR::enabledDevices 496 | - Tizen::VR::enabledDevices 497 | - WebGL::VR::enabledDevices 498 | - WebPlayer::VR::enabledDevices 499 | - WiiU::VR::enabledDevices 500 | - Xbox360::VR::enabledDevices 501 | - XboxOne::VR::enabledDevices 502 | - iOS::VR::enabledDevices 503 | - tvOS::VR::enabledDevices 504 | Android::VR::enabledDevices: 505 | - Oculus 506 | Metro::VR::enabledDevices: [] 507 | N3DS::VR::enabledDevices: [] 508 | PS3::VR::enabledDevices: [] 509 | PS4::VR::enabledDevices: 510 | - PlayStationVR 511 | PSM::VR::enabledDevices: [] 512 | PSP2::VR::enabledDevices: [] 513 | SamsungTV::VR::enabledDevices: [] 514 | Standalone::VR::enabledDevices: 515 | - Oculus 516 | Tizen::VR::enabledDevices: [] 517 | WebGL::VR::enabledDevices: [] 518 | WebPlayer::VR::enabledDevices: [] 519 | WiiU::VR::enabledDevices: [] 520 | Xbox360::VR::enabledDevices: [] 521 | XboxOne::VR::enabledDevices: [] 522 | iOS::VR::enabledDevices: [] 523 | tvOS::VR::enabledDevices: [] 524 | cloudProjectId: 525 | projectName: 526 | organizationId: 527 | cloudEnabled: 0 528 | -------------------------------------------------------------------------------- /ProjectSettings/ProjectVersion.txt: -------------------------------------------------------------------------------- 1 | m_EditorVersion: 5.4.2f2 2 | m_StandardAssetsVersion: 0 3 | -------------------------------------------------------------------------------- /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: Fastest 11 | pixelLightCount: 0 12 | shadows: 0 13 | shadowResolution: 0 14 | shadowProjection: 1 15 | shadowCascades: 1 16 | shadowDistance: 15 17 | shadowNearPlaneOffset: 2 18 | shadowCascade2Split: 0.33333334 19 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 20 | blendWeights: 1 21 | textureQuality: 1 22 | anisotropicTextures: 0 23 | antiAliasing: 0 24 | softParticles: 0 25 | softVegetation: 0 26 | realtimeReflectionProbes: 0 27 | billboardsFaceCameraPosition: 0 28 | vSyncCount: 0 29 | lodBias: 0.3 30 | maximumLODLevel: 0 31 | particleRaycastBudget: 4 32 | asyncUploadTimeSlice: 2 33 | asyncUploadBufferSize: 4 34 | excludedTargetPlatforms: [] 35 | - serializedVersion: 2 36 | name: Fast 37 | pixelLightCount: 0 38 | shadows: 0 39 | shadowResolution: 0 40 | shadowProjection: 1 41 | shadowCascades: 1 42 | shadowDistance: 20 43 | shadowNearPlaneOffset: 2 44 | shadowCascade2Split: 0.33333334 45 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 46 | blendWeights: 2 47 | textureQuality: 0 48 | anisotropicTextures: 0 49 | antiAliasing: 0 50 | softParticles: 0 51 | softVegetation: 0 52 | realtimeReflectionProbes: 0 53 | billboardsFaceCameraPosition: 0 54 | vSyncCount: 0 55 | lodBias: 0.4 56 | maximumLODLevel: 0 57 | particleRaycastBudget: 16 58 | asyncUploadTimeSlice: 2 59 | asyncUploadBufferSize: 4 60 | excludedTargetPlatforms: [] 61 | - serializedVersion: 2 62 | name: Simple 63 | pixelLightCount: 1 64 | shadows: 1 65 | shadowResolution: 0 66 | shadowProjection: 1 67 | shadowCascades: 1 68 | shadowDistance: 20 69 | shadowNearPlaneOffset: 2 70 | shadowCascade2Split: 0.33333334 71 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 72 | blendWeights: 2 73 | textureQuality: 0 74 | anisotropicTextures: 1 75 | antiAliasing: 0 76 | softParticles: 0 77 | softVegetation: 0 78 | realtimeReflectionProbes: 0 79 | billboardsFaceCameraPosition: 0 80 | vSyncCount: 1 81 | lodBias: 0.7 82 | maximumLODLevel: 0 83 | particleRaycastBudget: 64 84 | asyncUploadTimeSlice: 2 85 | asyncUploadBufferSize: 4 86 | excludedTargetPlatforms: [] 87 | - serializedVersion: 2 88 | name: Good 89 | pixelLightCount: 2 90 | shadows: 2 91 | shadowResolution: 1 92 | shadowProjection: 1 93 | shadowCascades: 2 94 | shadowDistance: 40 95 | shadowNearPlaneOffset: 2 96 | shadowCascade2Split: 0.33333334 97 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 98 | blendWeights: 2 99 | textureQuality: 0 100 | anisotropicTextures: 1 101 | antiAliasing: 0 102 | softParticles: 0 103 | softVegetation: 1 104 | realtimeReflectionProbes: 1 105 | billboardsFaceCameraPosition: 1 106 | vSyncCount: 1 107 | lodBias: 1 108 | maximumLODLevel: 0 109 | particleRaycastBudget: 256 110 | asyncUploadTimeSlice: 2 111 | asyncUploadBufferSize: 4 112 | excludedTargetPlatforms: [] 113 | - serializedVersion: 2 114 | name: Beautiful 115 | pixelLightCount: 3 116 | shadows: 2 117 | shadowResolution: 2 118 | shadowProjection: 1 119 | shadowCascades: 2 120 | shadowDistance: 70 121 | shadowNearPlaneOffset: 2 122 | shadowCascade2Split: 0.33333334 123 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 124 | blendWeights: 4 125 | textureQuality: 0 126 | anisotropicTextures: 2 127 | antiAliasing: 2 128 | softParticles: 1 129 | softVegetation: 1 130 | realtimeReflectionProbes: 1 131 | billboardsFaceCameraPosition: 1 132 | vSyncCount: 1 133 | lodBias: 1.5 134 | maximumLODLevel: 0 135 | particleRaycastBudget: 1024 136 | asyncUploadTimeSlice: 2 137 | asyncUploadBufferSize: 4 138 | excludedTargetPlatforms: [] 139 | - serializedVersion: 2 140 | name: Fantastic 141 | pixelLightCount: 4 142 | shadows: 2 143 | shadowResolution: 2 144 | shadowProjection: 1 145 | shadowCascades: 4 146 | shadowDistance: 150 147 | shadowNearPlaneOffset: 2 148 | shadowCascade2Split: 0.33333334 149 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 150 | blendWeights: 4 151 | textureQuality: 0 152 | anisotropicTextures: 2 153 | antiAliasing: 2 154 | softParticles: 1 155 | softVegetation: 1 156 | realtimeReflectionProbes: 1 157 | billboardsFaceCameraPosition: 1 158 | vSyncCount: 1 159 | lodBias: 2 160 | maximumLODLevel: 0 161 | particleRaycastBudget: 4096 162 | asyncUploadTimeSlice: 2 163 | asyncUploadBufferSize: 4 164 | excludedTargetPlatforms: [] 165 | m_PerPlatformDefaultQuality: 166 | Android: 2 167 | Nintendo 3DS: 5 168 | PS3: 5 169 | PS4: 5 170 | PSM: 5 171 | PSP2: 2 172 | Samsung TV: 2 173 | Standalone: 5 174 | Tizen: 2 175 | Web: 5 176 | WebGL: 3 177 | WiiU: 5 178 | Windows Store Apps: 5 179 | XBOX360: 5 180 | XboxOne: 5 181 | iPhone: 2 182 | tvOS: 5 183 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ProjectSettings/UnityAdsSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!292 &1 4 | UnityAdsSettings: 5 | m_ObjectHideFlags: 0 6 | m_Enabled: 0 7 | m_InitializeOnStartup: 1 8 | m_TestMode: 0 9 | m_EnabledPlatforms: 4294967295 10 | m_IosGameId: 11 | m_AndroidGameId: 12 | -------------------------------------------------------------------------------- /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 | m_Enabled: 0 7 | m_TestMode: 0 8 | m_TestEventUrl: 9 | m_TestConfigUrl: 10 | CrashReportingSettings: 11 | m_EventUrl: https://perf-events.cloud.unity3d.com/api/events/crashes 12 | m_Enabled: 0 13 | UnityPurchasingSettings: 14 | m_Enabled: 0 15 | m_TestMode: 0 16 | UnityAnalyticsSettings: 17 | m_Enabled: 0 18 | m_InitializeOnStartup: 1 19 | m_TestMode: 0 20 | m_TestEventUrl: 21 | m_TestConfigUrl: 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## First glimpse 2 | 3 | ```csharp 4 | //Generate objects in default pool for given class 5 | Cache.Generate(10); 6 | //Retrieve object from pool 7 | var instance = Cache.Pop(); 8 | //Return object to pool 9 | Cache.Push(instance); 10 | //Shortcut for accessing default pool 11 | var myPool = Cache.DefaultPool; 12 | ``` 13 | ## Overview 14 | Unity Cache is simple solution for pooling objects. Especially made for Unity3D but its core can be used outside of this engine. 15 | * Custom Inspector for Unity3D 16 | * Can be used for every class not only GameObjects; 17 | * Very flexible and easy to use 18 | * Supports Fluent API 19 | 20 | 21 | ![alt text](/Docs/PoolUML.png) 22 | ## Code Example 23 | 24 | ```csharp 25 | Cache.SetFactory(() => 26 | { 27 | var gm = Instantiate(CoinPrefab); 28 | gm.transform.parent = transform; 29 | return gm; 30 | }) 31 | .SetResetAction(o => o.SetActive(false)) 32 | .Generate(10); 33 | ``` 34 | Using specified named caches 35 | ```csharp 36 | Cache.Caches["Coins"] 37 | .SetFactory(() => 38 | { 39 | var gm = Instantiate(CoinPrefab); 40 | gm.transform.parent = transform; 41 | return gm; 42 | }) 43 | .SetResetAction(o => o.SetActive(false)) 44 | .Generate(10); 45 | ``` 46 | ## Motivation 47 | 48 | Pooling objects can be the most important performance boost in every game or application, 49 | Main purpose of this library is to made this as simple and straightforward to operation as possible. 50 | Among all other pooling solutioins this one do not concentrate only on GameObjects. U can use pooling for all class types; 51 | 52 | # Editor Helpers 53 | 54 | ![alt text](/Docs/UnityStorage.png) 55 | ![alt text](/Docs/UnityStorageLog.png) 56 | ## Installation 57 | 58 | 1) Add this repository as submodule to your projects, prefered directory "{YouGame}\Submodules\" 59 | 60 | 2) Symlink "UnityCache" folder to your "Assets\Plugins\" folder 61 | ## API Reference 62 | 63 | ## Tests 64 | 65 | Tests are written with SpecsFor library. 66 | 67 | ## Contributors 68 | 69 | 70 | 71 | ## License 72 | GNU GENERAL PUBLIC LICENSE 73 | -------------------------------------------------------------------------------- /Tests/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("Tests")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("Tests")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("d1068884-fb55-418b-9502-7f8f2abbccc7")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /Tests/Tests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {D1068884-FB55-418B-9502-7F8F2ABBCCC7} 8 | Library 9 | Properties 10 | Tests 11 | Tests 12 | v4.5 13 | 512 14 | 15 | 16 | true 17 | full 18 | false 19 | bin\Debug\ 20 | DEBUG;TRACE 21 | prompt 22 | 4 23 | 24 | 25 | pdbonly 26 | true 27 | bin\Release\ 28 | TRACE 29 | prompt 30 | 4 31 | 32 | 33 | 34 | ..\..\..\packages\ExpectedObjects.1.2.3\lib\net40\ExpectedObjects.dll 35 | True 36 | 37 | 38 | ..\..\..\packages\FluentAssertions.4.19.2\lib\net45\FluentAssertions.dll 39 | True 40 | 41 | 42 | ..\..\..\packages\FluentAssertions.4.19.2\lib\net45\FluentAssertions.Core.dll 43 | True 44 | 45 | 46 | ..\..\..\packages\Moq.4.2.1510.2205\lib\net40\Moq.dll 47 | True 48 | 49 | 50 | ..\..\..\packages\NUnit.2.6.3\lib\nunit.framework.dll 51 | True 52 | 53 | 54 | ..\..\..\packages\Should.1.1.20\lib\Should.dll 55 | True 56 | 57 | 58 | ..\..\..\packages\SpecsFor.5.0.1\lib\net40\SpecsFor.dll 59 | True 60 | 61 | 62 | ..\..\..\packages\structuremap.4.1.3.394\lib\net40\StructureMap.dll 63 | True 64 | 65 | 66 | ..\..\..\packages\structuremap.4.1.3.394\lib\net40\StructureMap.Net4.dll 67 | True 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | ..\..\..\Library\UnityAssemblies\UnityEngine.dll 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | {b47f0079-7c45-ea68-5ac1-ad701bc75fda} 92 | Cartoon Dash.CSharp 93 | 94 | 95 | {2cb802d9-d3a0-8a35-474d-46299c52d38c} 96 | Cartoon Dash.CSharp.Plugins 97 | 98 | 99 | 100 | 107 | -------------------------------------------------------------------------------- /Tests/describe_Cache.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Moq; 3 | using NUnit.Framework; 4 | using Should; 5 | using SpecsFor; 6 | using UnityEngine; 7 | 8 | namespace Grygus.Utilities.Pool 9 | { 10 | public class describe_Cache 11 | { 12 | public class given 13 | { 14 | public class the_sample_class_cache : SpecsFor 15 | { 16 | protected override void Given() 17 | { 18 | SUT = new SampleClass(); 19 | base.BeforeEachTest(); 20 | Cache.DefaultPool.Clear(); 21 | var myCache = Cache.Caches["MyCache"]; 22 | myCache.Clear(); 23 | } 24 | 25 | } 26 | } 27 | 28 | public class when_generating_objects : given.the_sample_class_cache 29 | { 30 | 31 | protected override void When() 32 | { 33 | Cache.Generate(2); 34 | Cache.Caches["MyCache"].Generate(2); 35 | } 36 | 37 | [Test] 38 | public void then_default_pool_contains_objects() 39 | { 40 | 41 | Cache.Count.ShouldEqual(2); 42 | } 43 | 44 | [Test] 45 | public void then_named_pool_contains_objects() 46 | { 47 | 48 | Cache.Caches["MyCache"].Count.ShouldEqual(2); 49 | } 50 | } 51 | 52 | public class when_pulling_from_cache : given.the_sample_class_cache 53 | { 54 | protected override void When() 55 | { 56 | Cache.Generate(3); 57 | var myCache = Cache.DefaultPool; 58 | var defaultPoolInstance = myCache.Pop(); 59 | var cachedInstance = Cache.Pop(); 60 | } 61 | 62 | [Test] 63 | public void then_it_should_have_one_element() 64 | { 65 | 66 | var myCache = Cache.DefaultPool; 67 | myCache.Count.ShouldEqual(1); 68 | } 69 | } 70 | 71 | public class when_pushing_to_cache : given.the_sample_class_cache 72 | { 73 | protected override void When() 74 | { 75 | var myCache = Cache.DefaultPool; 76 | myCache.Push(new SampleClass()); 77 | Cache.Push(new SampleClass()); 78 | } 79 | 80 | [Test] 81 | public void then_it_should_have_two_elements() 82 | { 83 | 84 | var myCache = Cache.DefaultPool; 85 | myCache.Count.ShouldEqual(2); 86 | } 87 | } 88 | 89 | public class when_caching_with_custom_factory : given.the_sample_class_cache 90 | { 91 | protected override void When() 92 | { 93 | var myCache = Cache.DefaultPool; 94 | myCache.SetFactory(() => new SampleClass() { Name = "Custom" }); 95 | myCache.Generate(1); 96 | } 97 | 98 | [Test] 99 | public void then_it_should_have_elements_with_custom_name() 100 | { 101 | 102 | var myCache = Cache.DefaultPool; 103 | myCache.Pop().Name.ShouldBeSameAs("Custom"); 104 | } 105 | } 106 | 107 | public class when_using_custom_reset : given.the_sample_class_cache 108 | { 109 | protected override void When() 110 | { 111 | var myCache = Cache.DefaultPool; 112 | myCache.SetResetAction((instance) => instance.Name = "Reset"); 113 | myCache.Generate(1); 114 | var sampleInstance = myCache.Pop(); 115 | sampleInstance.Name = "Popped"; 116 | myCache.Push(sampleInstance); 117 | } 118 | 119 | [Test] 120 | public void then_it_should_have_elements_with_reset_name() 121 | { 122 | 123 | var myCache = Cache.DefaultPool; 124 | myCache.Pop().Name.ShouldBeSameAs("Reset"); 125 | } 126 | } 127 | 128 | public class when_Allowing_To_Expand : given.the_sample_class_cache 129 | { 130 | protected override void When() 131 | { 132 | var myCache = Cache.DefaultPool; 133 | myCache.AllowExpand().Generate(1); 134 | var instance1 = myCache.Pop(); 135 | var instance2 = myCache.Pop(); 136 | var instance3 = myCache.Pop(); 137 | myCache.Push(instance1); 138 | myCache.Push(instance2); 139 | myCache.Push(instance3); 140 | } 141 | 142 | [Test] 143 | public void then_it_should_have_elements_with_reset_name() 144 | { 145 | 146 | var myCache = Cache.DefaultPool; 147 | myCache.Count.ShouldEqual(3); 148 | } 149 | } 150 | 151 | public class when_allowing_to_recycle_with_one_element_in_cache : given.the_sample_class_cache 152 | { 153 | protected override void When() 154 | { 155 | var myCache = Cache.DefaultPool; 156 | myCache.AllowRecycle().Generate(1); 157 | } 158 | 159 | [Test] 160 | public void then_all_pop_elements_should_be_the_same() 161 | { 162 | 163 | var myCache = Cache.DefaultPool; 164 | 165 | myCache.Count.ShouldEqual(1); 166 | 167 | var instance1 = myCache.Pop(); 168 | var instance2 = myCache.Pop(); 169 | 170 | instance1.ShouldEqual(instance2); 171 | myCache.Count.ShouldEqual(0); 172 | } 173 | 174 | [Test] 175 | public void then_recycled_element_should_reset() 176 | { 177 | var myCache = Cache.DefaultPool; 178 | myCache.SetResetAction(instance => instance.count = 0); 179 | 180 | var instance1 = myCache.Pop(); 181 | instance1.count++; 182 | var instance2 = myCache.Pop(); 183 | instance2.count++; 184 | var instance3 = myCache.Pop(); 185 | instance3.count.ShouldEqual(0); 186 | } 187 | } 188 | } 189 | 190 | public class SampleClass 191 | { 192 | public string Name = string.Empty; 193 | public int count = 0; 194 | } 195 | } 196 | -------------------------------------------------------------------------------- /Tests/describe_PickableMap.cs: -------------------------------------------------------------------------------- 1 | //BDD-Style Tests 2 | 3 | using System; 4 | using Moq; 5 | using NUnit.Framework; 6 | using Should; 7 | using SpecsFor; 8 | using UnityEngine; 9 | 10 | namespace Grygus.Preset.Tests 11 | { 12 | public class describe_PickableMap 13 | { 14 | public class when_creating_a_map : SpecsFor 15 | { 16 | 17 | protected override void Given() 18 | { 19 | base.BeforeEachTest(); 20 | SUT = new PickableMap(); 21 | } 22 | 23 | protected override void When() 24 | { 25 | SUT.AddNode(0, 0, new Vector3(1, 1, 1)); 26 | } 27 | 28 | [Test] 29 | public void then_it_should_have_one_element() 30 | { 31 | SUT.Count().ShouldEqual(1); 32 | } 33 | 34 | } 35 | 36 | public class when_removeing_item : SpecsFor 37 | { 38 | protected override void Given() 39 | { 40 | base.BeforeEachTest(); 41 | SUT = new PickableMap(); 42 | } 43 | 44 | protected override void When() 45 | { 46 | SUT.AddNode(0, 0, new Vector3(1, 1, 1)); 47 | SUT.AddNode(0, 1, new Vector3(1, 1, 2)); 48 | SUT.AddNode(0, 2, new Vector3(1, 1, 3)); 49 | 50 | SUT.RemoveNode(0, 2); 51 | } 52 | 53 | [Test] 54 | public void then_it_should_have_two_elements() 55 | { 56 | SUT.Count().ShouldEqual(2); 57 | } 58 | 59 | [Test] 60 | public void then_second_element() 61 | { 62 | SUT.GetNode(0, 1).z.ShouldEqual(2); 63 | } 64 | 65 | [Test] 66 | public void then_third_element_should_not_exist() 67 | { 68 | Action act = () => SUT.GetNode(0, 2); 69 | act.ShouldThrow(); 70 | } 71 | } 72 | } 73 | } -------------------------------------------------------------------------------- /Tests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | --------------------------------------------------------------------------------