├── .gitignore ├── Assets ├── Animations.meta ├── Animations │ ├── Player.meta │ └── Player │ │ ├── MinecraftPlayer.controller │ │ ├── MinecraftPlayer.controller.meta │ │ ├── idle.anim │ │ ├── idle.anim.meta │ │ ├── walk.anim │ │ └── walk.anim.meta ├── Chunk.prefab ├── Chunk.prefab.meta ├── ChunkMaterial.mat ├── ChunkMaterial.mat.meta ├── Scripts.meta ├── Scripts │ ├── Chunk.cs │ ├── Chunk.cs.meta │ ├── DayNightCycle.cs │ ├── DayNightCycle.cs.meta │ ├── Noise.cs │ ├── Noise.cs.meta │ ├── PlayerIO.cs │ ├── PlayerIO.cs.meta │ ├── World.cs │ └── World.cs.meta ├── Standard Assets.meta ├── Standard Assets │ ├── Character Controllers.meta │ ├── Character Controllers │ │ ├── 3rd Person Controller.prefab │ │ ├── 3rd Person Controller.prefab.meta │ │ ├── First Person Controller.prefab │ │ ├── First Person Controller.prefab.meta │ │ ├── Materials.meta │ │ ├── Materials │ │ │ ├── MinecraftPlayer-Player__char_png.mat │ │ │ ├── MinecraftPlayer-Player__char_png.mat.meta │ │ │ ├── MinecraftPlayer-Player__char_png_0.mat │ │ │ ├── MinecraftPlayer-Player__char_png_0.mat.meta │ │ │ ├── Player.mat │ │ │ ├── Player.mat.meta │ │ │ ├── Player__char_png_0.mat │ │ │ ├── Player__char_png_0.mat.meta │ │ │ ├── char.mat │ │ │ ├── char.mat.meta │ │ │ ├── defaultMat.mat │ │ │ └── defaultMat.mat.meta │ │ ├── MinecraftPlayer.blend │ │ ├── MinecraftPlayer.blend.meta │ │ ├── MinecraftPlayer.fbx │ │ ├── MinecraftPlayer.fbx.meta │ │ ├── MinecraftPlayer.mtl │ │ ├── MinecraftPlayer.mtl.meta │ │ ├── Skin_Default.mat │ │ ├── Skin_Default.mat.meta │ │ ├── Sources.meta │ │ ├── Sources │ │ │ ├── Scripts.meta │ │ │ └── Scripts │ │ │ │ ├── CharacterMotor.js │ │ │ │ ├── CharacterMotor.js.meta │ │ │ │ ├── FPSInputController.js │ │ │ │ ├── FPSInputController.js.meta │ │ │ │ ├── MouseLook.cs │ │ │ │ ├── MouseLook.cs.meta │ │ │ │ ├── PlatformInputController.js │ │ │ │ ├── PlatformInputController.js.meta │ │ │ │ ├── ThirdPersonCamera.js │ │ │ │ ├── ThirdPersonCamera.js.meta │ │ │ │ ├── ThirdPersonController.js │ │ │ │ └── ThirdPersonController.js.meta │ │ ├── char.png │ │ ├── char.png.meta │ │ ├── char1.png │ │ └── char1.png.meta │ ├── Effects.meta │ ├── Effects │ │ ├── LightFlares.meta │ │ └── LightFlares │ │ │ ├── Flares.meta │ │ │ ├── Flares │ │ │ ├── 50mmZoom.flare │ │ │ ├── 50mmZoom.flare.meta │ │ │ ├── FlareSmall.flare │ │ │ ├── FlareSmall.flare.meta │ │ │ ├── Sun.flare │ │ │ └── Sun.flare.meta │ │ │ ├── Materials.meta │ │ │ ├── Materials │ │ │ ├── Flare50mm.mat │ │ │ └── Flare50mm.mat.meta │ │ │ ├── Textures.meta │ │ │ └── Textures │ │ │ ├── Flare50mm.psd │ │ │ ├── Flare50mm.psd.meta │ │ │ ├── FlareStar.psd │ │ │ └── FlareStar.psd.meta │ ├── Skyboxes.meta │ └── Skyboxes │ │ ├── Sunny1 Skybox.mat │ │ ├── Sunny1 Skybox.mat.meta │ │ ├── Textures.meta │ │ └── Textures │ │ ├── Sunny1.meta │ │ └── Sunny1 │ │ ├── Sunny1_back.tif │ │ ├── Sunny1_back.tif.meta │ │ ├── Sunny1_down.tif │ │ ├── Sunny1_down.tif.meta │ │ ├── Sunny1_front.tif │ │ ├── Sunny1_front.tif.meta │ │ ├── Sunny1_left.tif │ │ ├── Sunny1_left.tif.meta │ │ ├── Sunny1_right.tif │ │ ├── Sunny1_right.tif.meta │ │ ├── Sunny1_up.tif │ │ └── Sunny1_up.tif.meta ├── Textures.meta ├── Textures │ ├── checkerboard.png │ ├── checkerboard.png.meta │ ├── crosshairalpha.png │ ├── crosshairalpha.png.meta │ ├── tileTexture.png │ ├── tileTexture.png.meta │ ├── tileTextureBump.png │ └── tileTextureBump.png.meta ├── garden.unity ├── garden.unity.meta ├── mineinunity.png ├── mineinunity.png.meta ├── mineinunitylogo.png └── mineinunitylogo.png.meta ├── LICENSE.md ├── Library ├── AnnotationManager ├── AssetImportState ├── AssetServerCacheV3 ├── AssetVersioning.db ├── BuildPlayer.prefs ├── BuildSettings.asset ├── CurrentLayout.dwlt ├── CurrentMaximizeLayout.dwlt ├── EditorUserBuildSettings.asset ├── EditorUserSettings.asset ├── FailedAssetImports.txt ├── InspectorExpandedItems.asset ├── MonoManager.asset ├── ProjectSettings.asset ├── ScriptAssemblies │ ├── Assembly-CSharp-firstpass.dll │ ├── Assembly-CSharp-firstpass.dll.mdb │ ├── Assembly-CSharp.dll │ ├── Assembly-CSharp.dll.mdb │ ├── Assembly-UnityScript-firstpass.dll │ └── Assembly-UnityScript-firstpass.dll.mdb ├── ScriptMapper ├── assetDatabase3 ├── expandedItems └── metadata │ ├── 10 │ └── 1090bcb745ab46f48bf2f29b212db3be │ ├── 19 │ └── 195c271a9118d224c8562ae67cf47a66 │ ├── 23 │ ├── 2314ce3a3eecf4816bad3c9eca4de2e1 │ └── 2372dd1814cb4ed47a91f8174877623e │ ├── 32 │ └── 32ef381921b3f7f479831b042c113762 │ ├── 35 │ └── 352e5f82d7105ad408904c5f552b5fe7 │ ├── 45 │ └── 453ea2e1e226d2c4f83fe551570fbabf │ ├── 47 │ └── 4783aadae216f2140afd1967eda81d71 │ ├── 54 │ └── 54216e9ed42974e30967824b7f0b2806 │ ├── 60 │ ├── 607426a9820414bfd8081fb22854dbd4 │ └── 60bca8f58a0b8478e946e6e86658cb29 │ ├── 61 │ └── 61b884acb642d904382bce55cfeac61a │ ├── 64 │ └── 640f8137cba04b94890b520575b3e766 │ ├── 66 │ └── 66ebe4da1ef67e64e8aeccb820e409d6 │ ├── 68 │ └── 68ec2fe99d1108b9d0006a298d76c639 │ ├── 72 │ └── 7281089874bee8f4d9e8142b6e90032e │ ├── 73 │ └── 736d1d9b5c5a7a24a9b99f66657b204c │ ├── 75 │ └── 75a9f42993c7cb446b8bffb829d7adb4 │ ├── 78 │ └── 78c863421fc0e6948b59e59996e6ca7d │ ├── 00 │ ├── 00000000000000001000000000000000 │ ├── 00000000000000002000000000000000 │ ├── 00000000000000003000000000000000 │ ├── 00000000000000004000000000000000 │ ├── 00000000000000004100000000000000 │ ├── 00000000000000005000000000000000 │ ├── 00000000000000005100000000000000 │ ├── 00000000000000006000000000000000 │ ├── 00000000000000006100000000000000 │ ├── 00000000000000007000000000000000 │ ├── 00000000000000008000000000000000 │ ├── 00000000000000009000000000000000 │ ├── 0000000000000000a000000000000000 │ ├── 0000000000000000b000000000000000 │ └── 0000000000000000c000000000000000 │ ├── 08 │ └── 0823cae39ac1f1147b3653dc7db245a2 │ ├── 0a │ └── 0ab79d7f243824f5d9826bd83522c8df │ ├── 0b │ └── 0b167d00b3108411a8a963cba5ddde1b │ ├── 1b │ └── 1bf34b610fe6f466faff3dcd833c06f6 │ ├── 1d │ └── 1d5ac211a643e447ca78c2d794a16381 │ ├── 4f │ ├── 4f822a18df8013246a517342c843e83c │ └── 4f87cd5fddc81ba4d8143e6f882ab622 │ ├── 7e │ └── 7e0b0a994d8934541a387e092630b5db │ ├── 8a │ └── 8a98ef45bc7df804d95fd945abd2c943 │ ├── 8c │ └── 8ce8324a93c67cf4db6e30432f3e24ca │ ├── 9c │ └── 9cffcde21a77c864389d63351fb4e728 │ ├── 9d │ └── 9d4133d5d30b644bd87802a347eaccbe │ ├── 9e │ └── 9ef50104b12ed4ca9bed40f105986cd7 │ ├── 9f │ └── 9f67e5bce8e55e949a088765ec12d01a │ ├── a0 │ └── a05fa379be031cb49a7e7bd56e473540 │ ├── a2 │ └── a2126534b3a11b34e977105bd9e3cc03 │ ├── b1 │ └── b19aff51390c91040b9cf58efcd70390 │ ├── b5 │ └── b5b3956acb79c4c419da73d451024c28 │ ├── ba │ └── baa909ed6ff07724eaf8b9d078fd139a │ ├── c1 │ └── c12922db8df3a95418019291d35e7168 │ ├── c9 │ └── c989ae7dd4142dc4d8ba67d5b4166a30 │ ├── d0 │ └── d08f683727b16a2448be5007d8711e92 │ ├── d3 │ ├── d36233802f2e3ca448ecd6f18a36c9d8 │ └── d379536bbe06cc646bd48c83110ea995 │ ├── da │ └── da93ddd6928094e24bb1f3f665f143d3 │ ├── df │ └── dfcea0ba0cf7ab8468ea385fce550706 │ ├── e1 │ └── e1fa29a895b766e4087bebbbbe4e7647 │ ├── e4 │ └── e401e501282cf0f4498f1e9bb2765ea5 │ ├── ec │ └── ec7f2c9019cef3f409a2e0c214a49214 │ ├── f1 │ └── f117771501994564982fa44cbd1077a6 │ └── f7 │ └── f781c091d1c8647c380d5230adfaee54 ├── ProjectSettings ├── AudioManager.asset ├── ClusterInputManager.asset ├── DynamicsManager.asset ├── EditorBuildSettings.asset ├── EditorSettings.asset ├── GraphicsSettings.asset ├── InputManager.asset ├── NavMeshAreas.asset ├── NavMeshLayers.asset ├── NetworkManager.asset ├── Physics2DSettings.asset ├── ProjectSettings.asset ├── ProjectVersion.txt ├── QualitySettings.asset ├── TagManager.asset ├── TimeManager.asset └── UnityConnectSettings.asset └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | /[Ll]ibrary/ 2 | /[Tt]emp/ 3 | /[Oo]bj/ 4 | /[Bb]uild/ 5 | /[Bb]uilds/ 6 | /Assets/AssetStoreTools* 7 | 8 | # Autogenerated VS/MD solution and project files 9 | ExportedObj/ 10 | *.csproj 11 | *.unityproj 12 | *.sln 13 | *.suo 14 | *.tmp 15 | *.user 16 | *.userprefs 17 | *.pidb 18 | *.booproj 19 | *.svd 20 | 21 | 22 | # Unity3D generated meta files 23 | *.pidb.meta 24 | 25 | # Unity3D Generated File On Crash Reports 26 | sysinfo.txt 27 | 28 | # Builds 29 | *.apk 30 | *.unitypackage 31 | -------------------------------------------------------------------------------- /Assets/Animations.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8155e3c967194d045ab0ad4e043d7da3 3 | folderAsset: yes 4 | timeCreated: 1497702280 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Animations/Player.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 252422942f439a54faebd00bb201ca07 3 | folderAsset: yes 4 | timeCreated: 1497702280 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Animations/Player/MinecraftPlayer.controller: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Animations/Player/MinecraftPlayer.controller -------------------------------------------------------------------------------- /Assets/Animations/Player/MinecraftPlayer.controller.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3eb5bbd8de6138640ba9d9822b2debdc 3 | timeCreated: 1497702281 4 | licenseType: Free 5 | NativeFormatImporter: 6 | mainObjectFileID: 9100000 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Animations/Player/idle.anim: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Animations/Player/idle.anim -------------------------------------------------------------------------------- /Assets/Animations/Player/idle.anim.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3f712449ceef3114b9c0e416bc0d18a3 3 | timeCreated: 1497702280 4 | licenseType: Free 5 | NativeFormatImporter: 6 | mainObjectFileID: 7400000 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Animations/Player/walk.anim: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Animations/Player/walk.anim -------------------------------------------------------------------------------- /Assets/Animations/Player/walk.anim.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a569b7dc26a4f6845a5dc579b940334c 3 | timeCreated: 1497702489 4 | licenseType: Free 5 | NativeFormatImporter: 6 | mainObjectFileID: 7400000 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Chunk.prefab: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Chunk.prefab -------------------------------------------------------------------------------- /Assets/Chunk.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0823cae39ac1f1147b3653dc7db245a2 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/ChunkMaterial.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/ChunkMaterial.mat -------------------------------------------------------------------------------- /Assets/ChunkMaterial.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e1fa29a895b766e4087bebbbbe4e7647 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1090bcb745ab46f48bf2f29b212db3be 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Scripts/Chunk.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using SimplexNoise; 5 | 6 | [RequireComponent (typeof(MeshRenderer))] 7 | [RequireComponent (typeof(MeshCollider))] 8 | [RequireComponent (typeof(MeshFilter))] 9 | public class Chunk : MonoBehaviour { 10 | 11 | public static List chunks = new List(); 12 | public static int width { 13 | get { return World.currentWorld.chunkWidth; } 14 | } 15 | public static int height { 16 | get { return World.currentWorld.chunkHeight; } 17 | } 18 | public byte[,,] map; 19 | public Mesh visualMesh; 20 | protected MeshRenderer meshRenderer; 21 | protected MeshCollider meshCollider; 22 | protected MeshFilter meshFilter; 23 | 24 | // Use this for initialization 25 | void Start () { 26 | 27 | chunks.Add(this); 28 | 29 | meshRenderer = GetComponent(); 30 | meshCollider = GetComponent(); 31 | meshFilter = GetComponent(); 32 | 33 | 34 | 35 | CalculateMapFromScratch(); 36 | StartCoroutine(CreateVisualMesh()); 37 | 38 | } 39 | 40 | // Update is called once per frame 41 | void Update () { 42 | 43 | } 44 | 45 | public static byte GetTheoreticalByte(Vector3 pos) { 46 | Random.seed = World.currentWorld.seed; 47 | 48 | Vector3 grain0Offset = new Vector3(Random.value * 10000, Random.value * 10000, Random.value * 10000); 49 | Vector3 grain1Offset = new Vector3(Random.value * 10000, Random.value * 10000, Random.value * 10000); 50 | Vector3 grain2Offset = new Vector3(Random.value * 10000, Random.value * 10000, Random.value * 10000); 51 | 52 | return GetTheoreticalByte(pos, grain0Offset, grain1Offset, grain2Offset); 53 | 54 | } 55 | 56 | public static byte GetTheoreticalByte(Vector3 pos, Vector3 offset0, Vector3 offset1, Vector3 offset2) 57 | { 58 | 59 | float heightBase = 10; 60 | float maxHeight = height - 10; 61 | float heightSwing = maxHeight - heightBase; 62 | 63 | byte brick = 1; 64 | 65 | float clusterValue = CalculateNoiseValue(pos, offset1, 0.02f); 66 | float blobValue = CalculateNoiseValue(pos, offset1, 0.05f); 67 | float mountainValue = CalculateNoiseValue(pos, offset0, 0.009f); 68 | if ( (mountainValue == 0) && (blobValue < 0.2f) ) 69 | brick = 2; 70 | else if (clusterValue > 0.9f) 71 | brick = 1; 72 | else if (clusterValue > 0.8f) 73 | brick = 3; 74 | 75 | mountainValue = Mathf.Sqrt(mountainValue); 76 | 77 | mountainValue *= heightSwing; 78 | mountainValue += heightBase; 79 | 80 | mountainValue += (blobValue * 10) - 5f; 81 | 82 | 83 | 84 | if (mountainValue >= pos.y) 85 | return brick; 86 | return 0; 87 | } 88 | 89 | public virtual void CalculateMapFromScratch() { 90 | map = new byte[width, height, width]; 91 | 92 | Random.seed = World.currentWorld.seed; 93 | Vector3 grain0Offset = new Vector3(Random.value * 10000, Random.value * 10000, Random.value * 10000); 94 | Vector3 grain1Offset = new Vector3(Random.value * 10000, Random.value * 10000, Random.value * 10000); 95 | Vector3 grain2Offset = new Vector3(Random.value * 10000, Random.value * 10000, Random.value * 10000); 96 | 97 | 98 | 99 | for (int x = 0; x < World.currentWorld.chunkWidth; x++) 100 | { 101 | for (int y = 0; y < height; y++) 102 | { 103 | for (int z = 0; z < width; z++) 104 | { 105 | map[x, y, z] = GetTheoreticalByte(new Vector3(x, y, z) + transform.position); 106 | 107 | } 108 | } 109 | } 110 | 111 | } 112 | 113 | public static float CalculateNoiseValue(Vector3 pos, Vector3 offset, float scale) 114 | { 115 | 116 | float noiseX = Mathf.Abs((pos.x + offset.x) * scale); 117 | float noiseY = Mathf.Abs((pos.y + offset.y) * scale); 118 | float noiseZ = Mathf.Abs((pos.z + offset.z) * scale); 119 | 120 | return Mathf.Max(0, Noise.Generate(noiseX, noiseY, noiseZ)); 121 | 122 | } 123 | 124 | 125 | public virtual IEnumerator CreateVisualMesh() { 126 | visualMesh = new Mesh(); 127 | 128 | List verts = new List(); 129 | List uvs = new List(); 130 | List tris = new List(); 131 | 132 | 133 | for (int x = 0; x < width; x++) 134 | { 135 | for (int y = 0; y < height; y++) 136 | { 137 | for (int z = 0; z < width; z++) 138 | { 139 | if (map[x,y,z] == 0) continue; 140 | 141 | byte brick = map[x,y,z]; 142 | // Left wall 143 | if (IsTransparent(x - 1, y, z)) 144 | BuildFace (brick, new Vector3(x, y, z), Vector3.up, Vector3.forward, false, verts, uvs, tris); 145 | // Right wall 146 | if (IsTransparent(x + 1, y , z)) 147 | BuildFace (brick, new Vector3(x + 1, y, z), Vector3.up, Vector3.forward, true, verts, uvs, tris); 148 | 149 | // Bottom wall 150 | if (IsTransparent(x, y - 1 , z)) 151 | BuildFace (brick, new Vector3(x, y, z), Vector3.forward, Vector3.right, false, verts, uvs, tris); 152 | // Top wall 153 | if (IsTransparent(x, y + 1, z)) 154 | BuildFace (brick, new Vector3(x, y + 1, z), Vector3.forward, Vector3.right, true, verts, uvs, tris); 155 | 156 | // Back 157 | if (IsTransparent(x, y, z - 1)) 158 | BuildFace (brick, new Vector3(x, y, z), Vector3.up, Vector3.right, true, verts, uvs, tris); 159 | // Front 160 | if (IsTransparent(x, y, z + 1)) 161 | BuildFace (brick, new Vector3(x, y, z + 1), Vector3.up, Vector3.right, false, verts, uvs, tris); 162 | 163 | 164 | } 165 | } 166 | } 167 | 168 | visualMesh.vertices = verts.ToArray(); 169 | visualMesh.uv = uvs.ToArray(); 170 | visualMesh.triangles = tris.ToArray(); 171 | visualMesh.RecalculateBounds(); 172 | visualMesh.RecalculateNormals(); 173 | 174 | meshFilter.mesh = visualMesh; 175 | 176 | meshCollider.sharedMesh = null; 177 | meshCollider.sharedMesh = visualMesh; 178 | 179 | yield return 0; 180 | 181 | } 182 | public virtual void BuildFace(byte brick, Vector3 corner, Vector3 up, Vector3 right, bool reversed, List verts, List uvs, List tris) 183 | { 184 | int index = verts.Count; 185 | 186 | verts.Add (corner); 187 | verts.Add (corner + up); 188 | verts.Add (corner + up + right); 189 | verts.Add (corner + right); 190 | 191 | Vector2 uvWidth = new Vector2(0.25f, 0.25f); 192 | Vector2 uvCorner = new Vector2(0.00f, 0.75f); 193 | 194 | uvCorner.x += (float)(brick - 1) / 4; 195 | 196 | uvs.Add(uvCorner); 197 | uvs.Add(new Vector2(uvCorner.x, uvCorner.y + uvWidth.y)); 198 | uvs.Add(new Vector2(uvCorner.x + uvWidth.x, uvCorner.y + uvWidth.y)); 199 | uvs.Add(new Vector2(uvCorner.x + uvWidth.x, uvCorner.y)); 200 | 201 | if (reversed) 202 | { 203 | tris.Add(index + 0); 204 | tris.Add(index + 1); 205 | tris.Add(index + 2); 206 | tris.Add(index + 2); 207 | tris.Add(index + 3); 208 | tris.Add(index + 0); 209 | } 210 | else 211 | { 212 | tris.Add(index + 1); 213 | tris.Add(index + 0); 214 | tris.Add(index + 2); 215 | tris.Add(index + 3); 216 | tris.Add(index + 2); 217 | tris.Add(index + 0); 218 | } 219 | 220 | } 221 | public virtual bool IsTransparent (int x, int y, int z) 222 | { 223 | if ( y < 0) return false; 224 | byte brick = GetByte(x,y,z); 225 | switch (brick) 226 | { 227 | case 0: 228 | return true; 229 | default: 230 | return false; 231 | } 232 | } 233 | public virtual byte GetByte (int x, int y , int z) 234 | { 235 | 236 | if ((y < 0) || (y >= height)) 237 | return 0; 238 | 239 | if ( (x < 0) || (z < 0) || (x >= width) || (z >= width)) 240 | { 241 | 242 | Vector3 worldPos = new Vector3(x, y, z) + transform.position; 243 | Chunk chunk = Chunk.FindChunk(worldPos); 244 | if (chunk == this) return 0; 245 | if (chunk == null) 246 | { 247 | return GetTheoreticalByte(worldPos); 248 | } 249 | return chunk.GetByte (worldPos); 250 | } 251 | return map[x,y,z]; 252 | } 253 | public virtual byte GetByte(Vector3 worldPos) { 254 | worldPos -= transform.position; 255 | int x = Mathf.FloorToInt(worldPos.x); 256 | int y = Mathf.FloorToInt(worldPos.y); 257 | int z = Mathf.FloorToInt(worldPos.z); 258 | return GetByte (x, y, z); 259 | } 260 | 261 | public static Chunk FindChunk(Vector3 pos) { 262 | 263 | for (int a = 0; a < chunks.Count; a++) 264 | { 265 | Vector3 cpos = chunks[a].transform.position; 266 | 267 | if ( ( pos.x < cpos.x) || (pos.z < cpos.z) || (pos.x >= cpos.x + width) || (pos.z >= cpos.z + width) ) continue; 268 | return chunks[a]; 269 | 270 | } 271 | return null; 272 | 273 | } 274 | 275 | public bool SetBrick(byte brick, Vector3 worldPos){ 276 | worldPos -= transform.position; 277 | return SetBrick (brick, Mathf.FloorToInt(worldPos.x),Mathf.FloorToInt(worldPos.y),Mathf.FloorToInt(worldPos.z)); 278 | } 279 | 280 | public bool SetBrick(byte brick, int x, int y, int z){ 281 | if ((x < 0) || (y < 0) || (z < 0) || (x >= width) || (y >= height || (z >= width))) { 282 | return false; 283 | } 284 | if (map [x, y, z] == brick) return false; 285 | map [x, y, z] = brick; 286 | StartCoroutine (CreateVisualMesh()); 287 | 288 | if (x == 0) { 289 | Chunk chunk = FindChunk(new Vector3(x - 2,y,z) + transform.position); 290 | if (chunk != null){ 291 | StartCoroutine(chunk.CreateVisualMesh()); 292 | } 293 | } 294 | if (x == width - 1) { 295 | Chunk chunk = FindChunk(new Vector3(x + 2,y,z) + transform.position); 296 | if (chunk != null){ 297 | StartCoroutine(chunk.CreateVisualMesh()); 298 | } 299 | } 300 | if (z == 0) { 301 | Chunk chunk = FindChunk(new Vector3(x,y,z - 2) + transform.position); 302 | if (chunk != null){ 303 | StartCoroutine(chunk.CreateVisualMesh()); 304 | } 305 | } 306 | if (z == width - 1) { 307 | Chunk chunk = FindChunk(new Vector3(x,y,z + 2) + transform.position); 308 | if (chunk != null){ 309 | StartCoroutine(chunk.CreateVisualMesh()); 310 | } 311 | } 312 | return true; 313 | } 314 | 315 | } 316 | 317 | 318 | -------------------------------------------------------------------------------- /Assets/Scripts/Chunk.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c989ae7dd4142dc4d8ba67d5b4166a30 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/DayNightCycle.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | public class DayNightCycle : MonoBehaviour { 6 | 7 | float hourOfDay = 9f; 8 | public float timeSpeed = 0.6f; 9 | 10 | // Update is called once per frame 11 | void Update () { 12 | transform.Rotate (Time.deltaTime * Time.timeScale * timeSpeed, 0f, 0f); 13 | } 14 | 15 | public float HourOfDay{ 16 | get { 17 | return (transform.rotation.eulerAngles.x / 360f) * 24f; 18 | } 19 | set { 20 | Quaternion q = transform.rotation; 21 | q.eulerAngles = new Vector3 ((value / 24f) * 360f , q.eulerAngles.y, q.eulerAngles.z); 22 | transform.rotation = q; 23 | } 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /Assets/Scripts/DayNightCycle.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 77fe1371806dd5d459cf9fd6788f23f4 3 | timeCreated: 1497698042 4 | licenseType: Free 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /Assets/Scripts/Noise.cs: -------------------------------------------------------------------------------- 1 | // SimplexNoise for C# 2 | // Author: Heikki Törmälä 3 | 4 | //This is free and unencumbered software released into the public domain. 5 | 6 | //Anyone is free to copy, modify, publish, use, compile, sell, or 7 | //distribute this software, either in source code form or as a compiled 8 | //binary, for any purpose, commercial or non-commercial, and by any 9 | //means. 10 | 11 | //In jurisdictions that recognize copyright laws, the author or authors 12 | //of this software dedicate any and all copyright interest in the 13 | //software to the public domain. We make this dedication for the benefit 14 | //of the public at large and to the detriment of our heirs and 15 | //successors. We intend this dedication to be an overt act of 16 | //relinquishment in perpetuity of all present and future rights to this 17 | //software under copyright law. 18 | 19 | //THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 20 | //EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 21 | //MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 22 | //IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR 23 | //OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 24 | //ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | //OTHER DEALINGS IN THE SOFTWARE. 26 | 27 | //For more information, please refer to 28 | 29 | 30 | namespace SimplexNoise 31 | { 32 | /// 33 | /// Implementation of the Perlin simplex noise, an improved Perlin noise algorithm. 34 | /// Based loosely on SimplexNoise1234 by Stefan Gustavson 35 | /// 36 | /// 37 | public class Noise 38 | { 39 | /// 40 | /// 1D simplex noise 41 | /// 42 | /// 43 | /// 44 | public static float Generate(float x) 45 | { 46 | int i0 = FastFloor(x); 47 | int i1 = i0 + 1; 48 | float x0 = x - i0; 49 | float x1 = x0 - 1.0f; 50 | 51 | float n0, n1; 52 | 53 | float t0 = 1.0f - x0*x0; 54 | t0 *= t0; 55 | n0 = t0 * t0 * grad(perm[i0 & 0xff], x0); 56 | 57 | float t1 = 1.0f - x1*x1; 58 | t1 *= t1; 59 | n1 = t1 * t1 * grad(perm[i1 & 0xff], x1); 60 | // The maximum value of this noise is 8*(3/4)^4 = 2.53125 61 | // A factor of 0.395 scales to fit exactly within [-1,1] 62 | return 0.395f * (n0 + n1); 63 | } 64 | 65 | /// 66 | /// 2D simplex noise 67 | /// 68 | /// 69 | /// 70 | /// 71 | public static float Generate(float x, float y) 72 | { 73 | const float F2 = 0.366025403f; // F2 = 0.5*(sqrt(3.0)-1.0) 74 | const float G2 = 0.211324865f; // G2 = (3.0-Math.sqrt(3.0))/6.0 75 | 76 | float n0, n1, n2; // Noise contributions from the three corners 77 | 78 | // Skew the input space to determine which simplex cell we're in 79 | float s = (x+y)*F2; // Hairy factor for 2D 80 | float xs = x + s; 81 | float ys = y + s; 82 | int i = FastFloor(xs); 83 | int j = FastFloor(ys); 84 | 85 | float t = (float)(i+j)*G2; 86 | float X0 = i-t; // Unskew the cell origin back to (x,y) space 87 | float Y0 = j-t; 88 | float x0 = x-X0; // The x,y distances from the cell origin 89 | float y0 = y-Y0; 90 | 91 | // For the 2D case, the simplex shape is an equilateral triangle. 92 | // Determine which simplex we are in. 93 | int i1, j1; // Offsets for second (middle) corner of simplex in (i,j) coords 94 | if(x0>y0) {i1=1; j1=0;} // lower triangle, XY order: (0,0)->(1,0)->(1,1) 95 | else {i1=0; j1=1;} // upper triangle, YX order: (0,0)->(0,1)->(1,1) 96 | 97 | // A step of (1,0) in (i,j) means a step of (1-c,-c) in (x,y), and 98 | // a step of (0,1) in (i,j) means a step of (-c,1-c) in (x,y), where 99 | // c = (3-sqrt(3))/6 100 | 101 | float x1 = x0 - i1 + G2; // Offsets for middle corner in (x,y) unskewed coords 102 | float y1 = y0 - j1 + G2; 103 | float x2 = x0 - 1.0f + 2.0f * G2; // Offsets for last corner in (x,y) unskewed coords 104 | float y2 = y0 - 1.0f + 2.0f * G2; 105 | 106 | // Wrap the integer indices at 256, to avoid indexing perm[] out of bounds 107 | int ii = i % 256; 108 | int jj = j % 256; 109 | 110 | // Calculate the contribution from the three corners 111 | float t0 = 0.5f - x0*x0-y0*y0; 112 | if(t0 < 0.0f) n0 = 0.0f; 113 | else { 114 | t0 *= t0; 115 | n0 = t0 * t0 * grad(perm[ii+perm[jj]], x0, y0); 116 | } 117 | 118 | float t1 = 0.5f - x1*x1-y1*y1; 119 | if(t1 < 0.0f) n1 = 0.0f; 120 | else { 121 | t1 *= t1; 122 | n1 = t1 * t1 * grad(perm[ii+i1+perm[jj+j1]], x1, y1); 123 | } 124 | 125 | float t2 = 0.5f - x2*x2-y2*y2; 126 | if(t2 < 0.0f) n2 = 0.0f; 127 | else { 128 | t2 *= t2; 129 | n2 = t2 * t2 * grad(perm[ii+1+perm[jj+1]], x2, y2); 130 | } 131 | 132 | // Add contributions from each corner to get the final noise value. 133 | // The result is scaled to return values in the interval [-1,1]. 134 | return 40.0f * (n0 + n1 + n2); // TODO: The scale factor is preliminary! 135 | } 136 | 137 | 138 | public static float Generate(float x, float y, float z) 139 | { 140 | // Simple skewing factors for the 3D case 141 | const float F3 = 0.333333333f; 142 | const float G3 = 0.166666667f; 143 | 144 | float n0, n1, n2, n3; // Noise contributions from the four corners 145 | 146 | // Skew the input space to determine which simplex cell we're in 147 | float s = (x+y+z)*F3; // Very nice and simple skew factor for 3D 148 | float xs = x+s; 149 | float ys = y+s; 150 | float zs = z+s; 151 | int i = FastFloor(xs); 152 | int j = FastFloor(ys); 153 | int k = FastFloor(zs); 154 | 155 | float t = (float)(i+j+k)*G3; 156 | float X0 = i-t; // Unskew the cell origin back to (x,y,z) space 157 | float Y0 = j-t; 158 | float Z0 = k-t; 159 | float x0 = x-X0; // The x,y,z distances from the cell origin 160 | float y0 = y-Y0; 161 | float z0 = z-Z0; 162 | 163 | // For the 3D case, the simplex shape is a slightly irregular tetrahedron. 164 | // Determine which simplex we are in. 165 | int i1, j1, k1; // Offsets for second corner of simplex in (i,j,k) coords 166 | int i2, j2, k2; // Offsets for third corner of simplex in (i,j,k) coords 167 | 168 | /* This code would benefit from a backport from the GLSL version! */ 169 | if(x0>=y0) { 170 | if(y0>=z0) 171 | { i1=1; j1=0; k1=0; i2=1; j2=1; k2=0; } // X Y Z order 172 | else if(x0>=z0) { i1=1; j1=0; k1=0; i2=1; j2=0; k2=1; } // X Z Y order 173 | else { i1=0; j1=0; k1=1; i2=1; j2=0; k2=1; } // Z X Y order 174 | } 175 | else { // x0 0) ? ((int)x) : (((int)x) - 1); 266 | } 267 | 268 | private static float grad( int hash, float x ) 269 | { 270 | int h = hash & 15; 271 | float grad = 1.0f + (h & 7); // Gradient value 1.0, 2.0, ..., 8.0 272 | if ((h & 8) != 0) grad = -grad; // Set a random sign for the gradient 273 | return ( grad * x ); // Multiply the gradient with the distance 274 | } 275 | 276 | private static float grad( int hash, float x, float y ) 277 | { 278 | int h = hash & 7; // Convert low 3 bits of hash code 279 | float u = h<4 ? x : y; // into 8 simple gradient directions, 280 | float v = h<4 ? y : x; // and compute the dot product with (x,y). 281 | return ((h&1) != 0 ? -u : u) + ((h&2) != 0 ? -2.0f*v : 2.0f*v); 282 | } 283 | 284 | private static float grad( int hash, float x, float y , float z ) { 285 | int h = hash & 15; // Convert low 4 bits of hash code into 12 simple 286 | float u = h<8 ? x : y; // gradient directions, and compute dot product. 287 | float v = h<4 ? y : h==12||h==14 ? x : z; // Fix repeats at h = 12 to 15 288 | return ((h&1) != 0 ? -u : u) + ((h&2) != 0 ? -v : v); 289 | } 290 | 291 | private static float grad( int hash, float x, float y, float z, float t ) { 292 | int h = hash & 31; // Convert low 5 bits of hash code into 32 simple 293 | float u = h<24 ? x : y; // gradient directions, and compute dot product. 294 | float v = h<16 ? y : z; 295 | float w = h<8 ? z : t; 296 | return ((h&1) != 0 ? -u : u) + ((h&2) != 0 ? -v : v) + ((h&4) != 0 ? -w : w); 297 | } 298 | } 299 | } 300 | -------------------------------------------------------------------------------- /Assets/Scripts/Noise.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7281089874bee8f4d9e8142b6e90032e 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/PlayerIO.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections; 3 | 4 | public class PlayerIO : MonoBehaviour { 5 | 6 | public static PlayerIO currentPlayerIO; 7 | public float maxInteractDistance = 8; 8 | public byte selectedInventory = 0; 9 | public bool resetCamera = false; 10 | public Vector3 campos; 11 | public Animator playerAnimator; 12 | 13 | // Use this for initialization 14 | void Start () { 15 | currentPlayerIO = this; 16 | } 17 | 18 | // Update is called once per frame 19 | void Update () { 20 | playerAnimator.SetBool ("walking", Input.GetKey (KeyCode.W) || Input.GetKey (KeyCode.A) || Input.GetKey (KeyCode.S) || Input.GetKey (KeyCode.D)); 21 | if (GameObject.FindWithTag ("FPSController").transform.position.y < -20) { 22 | Debug.Log("Test"); 23 | GameObject.FindWithTag("FPSController").transform.position = new Vector3(GameObject.FindWithTag("FPSController").transform.position.x, 60, GameObject.FindWithTag("FPSController").transform.position.z); 24 | } 25 | if (Input.GetMouseButtonDown(0) || Input.GetMouseButtonDown(1) || Input.GetMouseButtonDown(2)){ 26 | Ray ray = GetComponent().ViewportPointToRay(new Vector3(0.5f,0.5f,0.5f)); 27 | RaycastHit hit; 28 | if (Physics.Raycast (ray,out hit, maxInteractDistance)) { 29 | Chunk chunk = hit.transform.GetComponent(); 30 | if (chunk == null){ 31 | return; 32 | } 33 | if (Input.GetMouseButtonDown(0)){ 34 | Vector3 p = hit.point; 35 | p -= hit.normal / 4; 36 | chunk.SetBrick(0, p); 37 | } 38 | if (Input.GetMouseButtonDown (1)) { 39 | Vector3 p = hit.point; 40 | if (selectedInventory != 0){ 41 | p += hit.normal / 4; 42 | chunk.SetBrick(selectedInventory, p); 43 | } 44 | } 45 | if (Input.GetMouseButtonDown(2)) { 46 | Vector3 p = hit.point; 47 | p -= hit.normal / 4; 48 | selectedInventory = chunk.GetByte(p); 49 | } 50 | } 51 | } 52 | if (Input.GetKeyDown (KeyCode.F5)) { 53 | if (!resetCamera) { 54 | transform.localPosition -= Vector3.forward * 2; 55 | GameObject.FindWithTag("MinecraftPlayer").layer = 1; 56 | resetCamera = true; 57 | } else { 58 | transform.position = transform.parent.root.transform.localPosition + new Vector3(0f, 0.7f, 0.06f); 59 | transform.rotation = transform.parent.root.transform.rotation; 60 | GameObject.FindWithTag("MinecraftPlayer").layer = 8; 61 | resetCamera = false; 62 | } 63 | } 64 | if (Input.GetKey (KeyCode.Escape) && Input.GetKey (KeyCode.F1)) { 65 | Application.Quit(); 66 | } 67 | } 68 | } -------------------------------------------------------------------------------- /Assets/Scripts/PlayerIO.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9cffcde21a77c864389d63351fb4e728 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/World.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections; 3 | 4 | public class World : MonoBehaviour { 5 | 6 | public static World currentWorld; 7 | 8 | public int chunkWidth = 20, chunkHeight = 20, seed = 0; 9 | public float viewRange = 30; 10 | 11 | 12 | public Chunk chunkFab; 13 | 14 | // Use this for initialization 15 | void Awake () { 16 | Cursor.visible = false; 17 | currentWorld = this; 18 | if (seed == 0) 19 | seed = Random.Range(0, int.MaxValue); 20 | } 21 | 22 | // Update is called once per frame 23 | void Update () { 24 | 25 | 26 | for (float x = transform.position.x - viewRange; x < transform.position.x + viewRange; x+= chunkWidth) 27 | { 28 | for (float z = transform.position.z - viewRange; z < transform.position.z + viewRange; z+= chunkWidth) 29 | { 30 | 31 | Vector3 pos = new Vector3(x, 0, z); 32 | pos.x = Mathf.Floor(pos.x / (float)chunkWidth) * chunkWidth; 33 | pos.z = Mathf.Floor(pos.z / (float)chunkWidth) * chunkWidth; 34 | 35 | Chunk chunk = Chunk.FindChunk(pos); 36 | if (chunk != null) continue; 37 | 38 | chunk = (Chunk)Instantiate(chunkFab, pos, Quaternion.identity); 39 | 40 | 41 | 42 | } 43 | } 44 | 45 | } 46 | } 47 | 48 | 49 | -------------------------------------------------------------------------------- /Assets/Scripts/World.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b19aff51390c91040b9cf58efcd70390 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8ce8324a93c67cf4db6e30432f3e24ca 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 54216e9ed42974e30967824b7f0b2806 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/3rd Person Controller.prefab: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/3rd Person Controller.prefab -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/3rd Person Controller.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2314ce3a3eecf4816bad3c9eca4de2e1 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/First Person Controller.prefab: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/First Person Controller.prefab -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/First Person Controller.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9d4133d5d30b644bd87802a347eaccbe 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f117771501994564982fa44cbd1077a6 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/MinecraftPlayer-Player__char_png.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Materials/MinecraftPlayer-Player__char_png.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/MinecraftPlayer-Player__char_png.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b5b3956acb79c4c419da73d451024c28 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/MinecraftPlayer-Player__char_png_0.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Materials/MinecraftPlayer-Player__char_png_0.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/MinecraftPlayer-Player__char_png_0.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d08f683727b16a2448be5007d8711e92 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/Player.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Materials/Player.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/Player.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: dfcea0ba0cf7ab8468ea385fce550706 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/Player__char_png_0.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Materials/Player__char_png_0.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/Player__char_png_0.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e401e501282cf0f4498f1e9bb2765ea5 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/char.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Materials/char.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/char.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: baa909ed6ff07724eaf8b9d078fd139a 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/defaultMat.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Materials/defaultMat.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Materials/defaultMat.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9f67e5bce8e55e949a088765ec12d01a 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/MinecraftPlayer.blend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/MinecraftPlayer.blend -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/MinecraftPlayer.blend.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ec7f2c9019cef3f409a2e0c214a49214 3 | ModelImporter: 4 | serializedVersion: 15 5 | fileIDToRecycleName: {} 6 | materials: 7 | importMaterials: 1 8 | materialName: 0 9 | materialSearch: 1 10 | animations: 11 | legacyGenerateAnimations: 4 12 | bakeSimulation: 0 13 | optimizeGameObjects: 0 14 | animationCompression: 1 15 | animationRotationError: .5 16 | animationPositionError: .5 17 | animationScaleError: .5 18 | animationWrapMode: 0 19 | extraExposedTransformPaths: [] 20 | clipAnimations: [] 21 | isReadable: 1 22 | meshes: 23 | lODScreenPercentages: [] 24 | globalScale: 1 25 | meshCompression: 0 26 | addColliders: 0 27 | importBlendShapes: 1 28 | swapUVChannels: 0 29 | generateSecondaryUV: 0 30 | useFileUnits: 1 31 | optimizeMeshForGPU: 1 32 | weldVertices: 1 33 | secondaryUVAngleDistortion: 8 34 | secondaryUVAreaDistortion: 15.000001 35 | secondaryUVHardAngle: 88 36 | secondaryUVPackMargin: 4 37 | tangentSpace: 38 | normalSmoothAngle: 60 39 | splitTangentsAcrossUV: 1 40 | normalImportMode: 0 41 | tangentImportMode: 1 42 | importAnimation: 1 43 | copyAvatar: 0 44 | humanDescription: 45 | human: [] 46 | skeleton: [] 47 | armTwist: .5 48 | foreArmTwist: .5 49 | upperLegTwist: .5 50 | legTwist: .5 51 | armStretch: .0500000007 52 | legStretch: .0500000007 53 | feetSpacing: 0 54 | rootMotionBoneName: 55 | lastHumanDescriptionAvatarSource: {instanceID: 0} 56 | animationType: 2 57 | userData: 58 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/MinecraftPlayer.fbx.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4783aadae216f2140afd1967eda81d71 3 | ModelImporter: 4 | serializedVersion: 15 5 | fileIDToRecycleName: 6 | 100000: body 7 | 100002: Camera 8 | 100004: larm_L 9 | 100006: larm_R 10 | 100008: lleg_L 11 | 100010: lleg_R 12 | 100012: //RootNode 13 | 100014: Player_0 14 | 100016: PlayerArmature 15 | 100018: root_0 16 | 100020: Sun 17 | 100022: top 18 | 100024: uarm_L 19 | 100026: uarm_R 20 | 100028: uleg_L 21 | 100030: uleg_R 22 | 100032: Player 23 | 100034: root 24 | 400000: body 25 | 400002: Camera 26 | 400004: larm_L 27 | 400006: larm_R 28 | 400008: lleg_L 29 | 400010: lleg_R 30 | 400012: //RootNode 31 | 400014: Player_0 32 | 400016: PlayerArmature 33 | 400018: root_0 34 | 400020: Sun 35 | 400022: top 36 | 400024: uarm_L 37 | 400026: uarm_R 38 | 400028: uleg_L 39 | 400030: uleg_R 40 | 400032: Player 41 | 400034: root 42 | 4300000: Player_0 43 | 4300002: Player 44 | 7400000: Default Take 45 | 9500000: //RootNode 46 | 13700000: Player_0 47 | 13700002: Player 48 | materials: 49 | importMaterials: 1 50 | materialName: 2 51 | materialSearch: 1 52 | animations: 53 | legacyGenerateAnimations: 4 54 | bakeSimulation: 0 55 | optimizeGameObjects: 0 56 | animationCompression: 3 57 | animationRotationError: .5 58 | animationPositionError: .5 59 | animationScaleError: .5 60 | animationWrapMode: 0 61 | extraExposedTransformPaths: [] 62 | clipAnimations: [] 63 | isReadable: 1 64 | meshes: 65 | lODScreenPercentages: [] 66 | globalScale: 1 67 | meshCompression: 0 68 | addColliders: 0 69 | importBlendShapes: 1 70 | swapUVChannels: 0 71 | generateSecondaryUV: 0 72 | useFileUnits: 1 73 | optimizeMeshForGPU: 1 74 | weldVertices: 1 75 | secondaryUVAngleDistortion: 8 76 | secondaryUVAreaDistortion: 15.000001 77 | secondaryUVHardAngle: 88 78 | secondaryUVPackMargin: 4 79 | tangentSpace: 80 | normalSmoothAngle: 60 81 | splitTangentsAcrossUV: 1 82 | normalImportMode: 0 83 | tangentImportMode: 1 84 | importAnimation: 1 85 | copyAvatar: 0 86 | humanDescription: 87 | human: 88 | - boneName: root_0 89 | humanName: Hips 90 | limit: 91 | min: {x: 0, y: 0, z: 0} 92 | max: {x: 0, y: 0, z: 0} 93 | value: {x: 0, y: 0, z: 0} 94 | length: 0 95 | modified: 0 96 | - boneName: uleg_L 97 | humanName: LeftUpperLeg 98 | limit: 99 | min: {x: 0, y: 0, z: 0} 100 | max: {x: 0, y: 0, z: 0} 101 | value: {x: 0, y: 0, z: 0} 102 | length: 0 103 | modified: 0 104 | - boneName: uleg_R 105 | humanName: RightUpperLeg 106 | limit: 107 | min: {x: 0, y: 0, z: 0} 108 | max: {x: 0, y: 0, z: 0} 109 | value: {x: 0, y: 0, z: 0} 110 | length: 0 111 | modified: 0 112 | - boneName: lleg_L 113 | humanName: LeftLowerLeg 114 | limit: 115 | min: {x: 0, y: 0, z: 0} 116 | max: {x: 0, y: 0, z: 0} 117 | value: {x: 0, y: 0, z: 0} 118 | length: 0 119 | modified: 0 120 | - boneName: lleg_R 121 | humanName: RightLowerLeg 122 | limit: 123 | min: {x: 0, y: 0, z: 0} 124 | max: {x: 0, y: 0, z: 0} 125 | value: {x: 0, y: 0, z: 0} 126 | length: 0 127 | modified: 0 128 | - boneName: body 129 | humanName: Spine 130 | limit: 131 | min: {x: 0, y: 0, z: 0} 132 | max: {x: 0, y: 0, z: 0} 133 | value: {x: 0, y: 0, z: 0} 134 | length: 0 135 | modified: 0 136 | - boneName: top 137 | humanName: Neck 138 | limit: 139 | min: {x: 0, y: 0, z: 0} 140 | max: {x: 0, y: 0, z: 0} 141 | value: {x: 0, y: 0, z: 0} 142 | length: 0 143 | modified: 0 144 | - boneName: uarm_L 145 | humanName: LeftShoulder 146 | limit: 147 | min: {x: 0, y: 0, z: 0} 148 | max: {x: 0, y: 0, z: 0} 149 | value: {x: 0, y: 0, z: 0} 150 | length: 0 151 | modified: 0 152 | - boneName: uarm_R 153 | humanName: RightShoulder 154 | limit: 155 | min: {x: 0, y: 0, z: 0} 156 | max: {x: 0, y: 0, z: 0} 157 | value: {x: 0, y: 0, z: 0} 158 | length: 0 159 | modified: 0 160 | - boneName: larm_L 161 | humanName: LeftUpperArm 162 | limit: 163 | min: {x: 0, y: 0, z: 0} 164 | max: {x: 0, y: 0, z: 0} 165 | value: {x: 0, y: 0, z: 0} 166 | length: 0 167 | modified: 0 168 | - boneName: larm_R 169 | humanName: RightUpperArm 170 | limit: 171 | min: {x: 0, y: 0, z: 0} 172 | max: {x: 0, y: 0, z: 0} 173 | value: {x: 0, y: 0, z: 0} 174 | length: 0 175 | modified: 0 176 | skeleton: 177 | - name: MinecraftPlayer(Clone) 178 | position: {x: 0, y: 0, z: 0} 179 | rotation: {x: 0, y: 0, z: 0, w: 1} 180 | scale: {x: 1, y: 1, z: 1} 181 | transformModified: 1 182 | - name: Camera 183 | position: {x: 0, y: 1.5, z: 6} 184 | rotation: {x: -.00617037341, y: -.707079828, z: .00617037341, w: .707079887} 185 | scale: {x: .99999994, y: .99999994, z: 1} 186 | transformModified: 1 187 | - name: Player_0 188 | position: {x: 0, y: 0, z: 0} 189 | rotation: {x: -.707106888, y: 0, z: -0, w: .707106769} 190 | scale: {x: .5, y: .5, z: .5} 191 | transformModified: 1 192 | - name: PlayerArmature 193 | position: {x: 0, y: 1.06277966, z: 0} 194 | rotation: {x: -.707106888, y: 0, z: -0, w: .707106769} 195 | scale: {x: .5, y: .5, z: .5} 196 | transformModified: 1 197 | - name: root_0 198 | position: {x: -0, y: 0, z: -.423761725} 199 | rotation: {x: .5, y: .5, z: -.5, w: .5} 200 | scale: {x: 1, y: 1, z: 1} 201 | transformModified: 1 202 | - name: body 203 | position: {x: -.341935515, y: 2.58154138e-08, z: 0} 204 | rotation: {x: 0, y: -0, z: -0, w: 1} 205 | scale: {x: 1, y: 1, z: 1} 206 | transformModified: 1 207 | - name: top 208 | position: {x: -1.95626521, y: 1.47693925e-07, z: -2.99999969e-15} 209 | rotation: {x: 1, y: -7.54979013e-08, z: 4.37113883e-08, w: -7.55001537e-08} 210 | scale: {x: 1, y: 1, z: 1} 211 | transformModified: 1 212 | - name: uarm_L 213 | position: {x: -1.65516734, y: -.905686736, z: 1.31614026e-08} 214 | rotation: {x: 1.06071717e-07, y: 2.52986823e-08, z: .798305094, w: .602253318} 215 | scale: {x: 1, y: 1, z: 1} 216 | transformModified: 1 217 | - name: larm_L 218 | position: {x: -.654940486, y: 4.54074183e-08, z: 1.80000007e-14} 219 | rotation: {x: -1.28392927e-07, y: 3.77522582e-08, z: .0762128532, w: .997091591} 220 | scale: {x: .99999994, y: .99999994, z: 1} 221 | transformModified: 1 222 | - name: uarm_R 223 | position: {x: -1.6551671, y: .905686975, z: 1.31614026e-08} 224 | rotation: {x: 4.17391206e-08, y: 7.50616422e-08, z: .798304975, w: -.602253377} 225 | scale: {x: 1, y: 1, z: 1} 226 | transformModified: 1 227 | - name: larm_R 228 | position: {x: -.654940486, y: 5.50251009e-08, z: 0} 229 | rotation: {x: 1.02639071e-07, y: 2.29707009e-08, z: -.0762128606, w: .997091591} 230 | scale: {x: .99999994, y: .99999994, z: 1} 231 | transformModified: 1 232 | - name: uleg_L 233 | position: {x: -.21524182, y: -.338408351, z: 5.53795898e-09} 234 | rotation: {x: 1.51898514e-15, y: 4.37113883e-08, z: 1, w: -4.37091323e-08} 235 | scale: {x: 1, y: 1, z: 1} 236 | transformModified: 1 237 | - name: lleg_L 238 | position: {x: -.85425961, y: 5.04353004e-08, z: 0} 239 | rotation: {x: 0, y: -0, z: -0, w: 1} 240 | scale: {x: 1, y: 1, z: 1} 241 | transformModified: 1 242 | - name: uleg_R 243 | position: {x: -.21524176, y: .338408411, z: 5.53795898e-09} 244 | rotation: {x: -5.34015903e-15, y: -4.37113883e-08, z: 1, w: 4.37091323e-08} 245 | scale: {x: 1, y: 1, z: 1} 246 | transformModified: 1 247 | - name: lleg_R 248 | position: {x: -.85425961, y: 5.04353004e-08, z: -2.99999969e-15} 249 | rotation: {x: 0, y: -0, z: -0, w: 1} 250 | scale: {x: 1, y: 1, z: 1} 251 | transformModified: 1 252 | - name: Sun 253 | position: {x: -1.51981843, y: 5.3833971, z: 6.11083698} 254 | rotation: {x: .464420855, y: .0796379745, z: .155300483, w: .868247032} 255 | scale: {x: 1, y: 1, z: .999999821} 256 | transformModified: 1 257 | armTwist: .5 258 | foreArmTwist: .5 259 | upperLegTwist: .5 260 | legTwist: .5 261 | armStretch: .0500000007 262 | legStretch: .0500000007 263 | feetSpacing: 0 264 | rootMotionBoneName: 265 | lastHumanDescriptionAvatarSource: {instanceID: 0} 266 | animationType: 3 267 | userData: 268 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/MinecraftPlayer.mtl: -------------------------------------------------------------------------------- 1 | # Blender MTL File: 'MinecraftPlayer.blend' 2 | # Material Count: 1 3 | 4 | newmtl Player 5 | Ns 96.078431 6 | Ka 0.000000 0.000000 0.000000 7 | Kd 0.640000 0.640000 0.640000 8 | Ks 0.000000 0.000000 0.000000 9 | Ni 1.000000 10 | d 1.000000 11 | illum 1 12 | map_Kd char.png 13 | map_d char.png 14 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/MinecraftPlayer.mtl.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c12922db8df3a95418019291d35e7168 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Skin_Default.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/Skin_Default.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Skin_Default.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a05fa379be031cb49a7e7bd56e473540 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7e0b0a994d8934541a387e092630b5db 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f781c091d1c8647c380d5230adfaee54 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/CharacterMotor.js: -------------------------------------------------------------------------------- 1 | #pragma strict 2 | #pragma implicit 3 | #pragma downcast 4 | 5 | // Does this script currently respond to input? 6 | var canControl : boolean = true; 7 | 8 | var useFixedUpdate : boolean = true; 9 | 10 | // For the next variables, @System.NonSerialized tells Unity to not serialize the variable or show it in the inspector view. 11 | // Very handy for organization! 12 | 13 | // The current global direction we want the character to move in. 14 | @System.NonSerialized 15 | var inputMoveDirection : Vector3 = Vector3.zero; 16 | 17 | // Is the jump button held down? We use this interface instead of checking 18 | // for the jump button directly so this script can also be used by AIs. 19 | @System.NonSerialized 20 | var inputJump : boolean = false; 21 | 22 | class CharacterMotorMovement { 23 | // The maximum horizontal speed when moving 24 | var maxForwardSpeed : float = 10.0; 25 | var maxSidewaysSpeed : float = 10.0; 26 | var maxBackwardsSpeed : float = 10.0; 27 | 28 | // Curve for multiplying speed based on slope (negative = downwards) 29 | var slopeSpeedMultiplier : AnimationCurve = AnimationCurve(Keyframe(-90, 1), Keyframe(0, 1), Keyframe(90, 0)); 30 | 31 | // How fast does the character change speeds? Higher is faster. 32 | var maxGroundAcceleration : float = 30.0; 33 | var maxAirAcceleration : float = 20.0; 34 | 35 | // The gravity for the character 36 | var gravity : float = 10.0; 37 | var maxFallSpeed : float = 20.0; 38 | 39 | // For the next variables, @System.NonSerialized tells Unity to not serialize the variable or show it in the inspector view. 40 | // Very handy for organization! 41 | 42 | // The last collision flags returned from controller.Move 43 | @System.NonSerialized 44 | var collisionFlags : CollisionFlags; 45 | 46 | // We will keep track of the character's current velocity, 47 | @System.NonSerialized 48 | var velocity : Vector3; 49 | 50 | // This keeps track of our current velocity while we're not grounded 51 | @System.NonSerialized 52 | var frameVelocity : Vector3 = Vector3.zero; 53 | 54 | @System.NonSerialized 55 | var hitPoint : Vector3 = Vector3.zero; 56 | 57 | @System.NonSerialized 58 | var lastHitPoint : Vector3 = Vector3(Mathf.Infinity, 0, 0); 59 | } 60 | 61 | var movement : CharacterMotorMovement = CharacterMotorMovement(); 62 | 63 | enum MovementTransferOnJump { 64 | None, // The jump is not affected by velocity of floor at all. 65 | InitTransfer, // Jump gets its initial velocity from the floor, then gradualy comes to a stop. 66 | PermaTransfer, // Jump gets its initial velocity from the floor, and keeps that velocity until landing. 67 | PermaLocked // Jump is relative to the movement of the last touched floor and will move together with that floor. 68 | } 69 | 70 | // We will contain all the jumping related variables in one helper class for clarity. 71 | class CharacterMotorJumping { 72 | // Can the character jump? 73 | var enabled : boolean = true; 74 | 75 | // How high do we jump when pressing jump and letting go immediately 76 | var baseHeight : float = 1.0; 77 | 78 | // We add extraHeight units (meters) on top when holding the button down longer while jumping 79 | var extraHeight : float = 4.1; 80 | 81 | // How much does the character jump out perpendicular to the surface on walkable surfaces? 82 | // 0 means a fully vertical jump and 1 means fully perpendicular. 83 | var perpAmount : float = 0.0; 84 | 85 | // How much does the character jump out perpendicular to the surface on too steep surfaces? 86 | // 0 means a fully vertical jump and 1 means fully perpendicular. 87 | var steepPerpAmount : float = 0.5; 88 | 89 | // For the next variables, @System.NonSerialized tells Unity to not serialize the variable or show it in the inspector view. 90 | // Very handy for organization! 91 | 92 | // Are we jumping? (Initiated with jump button and not grounded yet) 93 | // To see if we are just in the air (initiated by jumping OR falling) see the grounded variable. 94 | @System.NonSerialized 95 | var jumping : boolean = false; 96 | 97 | @System.NonSerialized 98 | var holdingJumpButton : boolean = false; 99 | 100 | // the time we jumped at (Used to determine for how long to apply extra jump power after jumping.) 101 | @System.NonSerialized 102 | var lastStartTime : float = 0.0; 103 | 104 | @System.NonSerialized 105 | var lastButtonDownTime : float = -100; 106 | 107 | @System.NonSerialized 108 | var jumpDir : Vector3 = Vector3.up; 109 | } 110 | 111 | var jumping : CharacterMotorJumping = CharacterMotorJumping(); 112 | 113 | class CharacterMotorMovingPlatform { 114 | var enabled : boolean = true; 115 | 116 | var movementTransfer : MovementTransferOnJump = MovementTransferOnJump.PermaTransfer; 117 | 118 | @System.NonSerialized 119 | var hitPlatform : Transform; 120 | 121 | @System.NonSerialized 122 | var activePlatform : Transform; 123 | 124 | @System.NonSerialized 125 | var activeLocalPoint : Vector3; 126 | 127 | @System.NonSerialized 128 | var activeGlobalPoint : Vector3; 129 | 130 | @System.NonSerialized 131 | var activeLocalRotation : Quaternion; 132 | 133 | @System.NonSerialized 134 | var activeGlobalRotation : Quaternion; 135 | 136 | @System.NonSerialized 137 | var lastMatrix : Matrix4x4; 138 | 139 | @System.NonSerialized 140 | var platformVelocity : Vector3; 141 | 142 | @System.NonSerialized 143 | var newPlatform : boolean; 144 | } 145 | 146 | var movingPlatform : CharacterMotorMovingPlatform = CharacterMotorMovingPlatform(); 147 | 148 | class CharacterMotorSliding { 149 | // Does the character slide on too steep surfaces? 150 | var enabled : boolean = true; 151 | 152 | // How fast does the character slide on steep surfaces? 153 | var slidingSpeed : float = 15; 154 | 155 | // How much can the player control the sliding direction? 156 | // If the value is 0.5 the player can slide sideways with half the speed of the downwards sliding speed. 157 | var sidewaysControl : float = 1.0; 158 | 159 | // How much can the player influence the sliding speed? 160 | // If the value is 0.5 the player can speed the sliding up to 150% or slow it down to 50%. 161 | var speedControl : float = 0.4; 162 | } 163 | 164 | var sliding : CharacterMotorSliding = CharacterMotorSliding(); 165 | 166 | @System.NonSerialized 167 | var grounded : boolean = true; 168 | 169 | @System.NonSerialized 170 | var groundNormal : Vector3 = Vector3.zero; 171 | 172 | private var lastGroundNormal : Vector3 = Vector3.zero; 173 | 174 | private var tr : Transform; 175 | 176 | private var controller : CharacterController; 177 | 178 | function Awake () { 179 | controller = GetComponent (CharacterController); 180 | tr = transform; 181 | } 182 | 183 | private function UpdateFunction () { 184 | // We copy the actual velocity into a temporary variable that we can manipulate. 185 | var velocity : Vector3 = movement.velocity; 186 | 187 | // Update velocity based on input 188 | velocity = ApplyInputVelocityChange(velocity); 189 | 190 | // Apply gravity and jumping force 191 | velocity = ApplyGravityAndJumping (velocity); 192 | 193 | // Moving platform support 194 | var moveDistance : Vector3 = Vector3.zero; 195 | if (MoveWithPlatform()) { 196 | var newGlobalPoint : Vector3 = movingPlatform.activePlatform.TransformPoint(movingPlatform.activeLocalPoint); 197 | moveDistance = (newGlobalPoint - movingPlatform.activeGlobalPoint); 198 | if (moveDistance != Vector3.zero) 199 | controller.Move(moveDistance); 200 | 201 | // Support moving platform rotation as well: 202 | var newGlobalRotation : Quaternion = movingPlatform.activePlatform.rotation * movingPlatform.activeLocalRotation; 203 | var rotationDiff : Quaternion = newGlobalRotation * Quaternion.Inverse(movingPlatform.activeGlobalRotation); 204 | 205 | var yRotation = rotationDiff.eulerAngles.y; 206 | if (yRotation != 0) { 207 | // Prevent rotation of the local up vector 208 | tr.Rotate(0, yRotation, 0); 209 | } 210 | } 211 | 212 | // Save lastPosition for velocity calculation. 213 | var lastPosition : Vector3 = tr.position; 214 | 215 | // We always want the movement to be framerate independent. Multiplying by Time.deltaTime does this. 216 | var currentMovementOffset : Vector3 = velocity * Time.deltaTime; 217 | 218 | // Find out how much we need to push towards the ground to avoid loosing grouning 219 | // when walking down a step or over a sharp change in slope. 220 | var pushDownOffset : float = Mathf.Max(controller.stepOffset, Vector3(currentMovementOffset.x, 0, currentMovementOffset.z).magnitude); 221 | if (grounded) 222 | currentMovementOffset -= pushDownOffset * Vector3.up; 223 | 224 | // Reset variables that will be set by collision function 225 | movingPlatform.hitPlatform = null; 226 | groundNormal = Vector3.zero; 227 | 228 | // Move our character! 229 | movement.collisionFlags = controller.Move (currentMovementOffset); 230 | 231 | movement.lastHitPoint = movement.hitPoint; 232 | lastGroundNormal = groundNormal; 233 | 234 | if (movingPlatform.enabled && movingPlatform.activePlatform != movingPlatform.hitPlatform) { 235 | if (movingPlatform.hitPlatform != null) { 236 | movingPlatform.activePlatform = movingPlatform.hitPlatform; 237 | movingPlatform.lastMatrix = movingPlatform.hitPlatform.localToWorldMatrix; 238 | movingPlatform.newPlatform = true; 239 | } 240 | } 241 | 242 | // Calculate the velocity based on the current and previous position. 243 | // This means our velocity will only be the amount the character actually moved as a result of collisions. 244 | var oldHVelocity : Vector3 = new Vector3(velocity.x, 0, velocity.z); 245 | movement.velocity = (tr.position - lastPosition) / Time.deltaTime; 246 | var newHVelocity : Vector3 = new Vector3(movement.velocity.x, 0, movement.velocity.z); 247 | 248 | // The CharacterController can be moved in unwanted directions when colliding with things. 249 | // We want to prevent this from influencing the recorded velocity. 250 | if (oldHVelocity == Vector3.zero) { 251 | movement.velocity = new Vector3(0, movement.velocity.y, 0); 252 | } 253 | else { 254 | var projectedNewVelocity : float = Vector3.Dot(newHVelocity, oldHVelocity) / oldHVelocity.sqrMagnitude; 255 | movement.velocity = oldHVelocity * Mathf.Clamp01(projectedNewVelocity) + movement.velocity.y * Vector3.up; 256 | } 257 | 258 | if (movement.velocity.y < velocity.y - 0.001) { 259 | if (movement.velocity.y < 0) { 260 | // Something is forcing the CharacterController down faster than it should. 261 | // Ignore this 262 | movement.velocity.y = velocity.y; 263 | } 264 | else { 265 | // The upwards movement of the CharacterController has been blocked. 266 | // This is treated like a ceiling collision - stop further jumping here. 267 | jumping.holdingJumpButton = false; 268 | } 269 | } 270 | 271 | // We were grounded but just loosed grounding 272 | if (grounded && !IsGroundedTest()) { 273 | grounded = false; 274 | 275 | // Apply inertia from platform 276 | if (movingPlatform.enabled && 277 | (movingPlatform.movementTransfer == MovementTransferOnJump.InitTransfer || 278 | movingPlatform.movementTransfer == MovementTransferOnJump.PermaTransfer) 279 | ) { 280 | movement.frameVelocity = movingPlatform.platformVelocity; 281 | movement.velocity += movingPlatform.platformVelocity; 282 | } 283 | 284 | SendMessage("OnFall", SendMessageOptions.DontRequireReceiver); 285 | // We pushed the character down to ensure it would stay on the ground if there was any. 286 | // But there wasn't so now we cancel the downwards offset to make the fall smoother. 287 | tr.position += pushDownOffset * Vector3.up; 288 | } 289 | // We were not grounded but just landed on something 290 | else if (!grounded && IsGroundedTest()) { 291 | grounded = true; 292 | jumping.jumping = false; 293 | SubtractNewPlatformVelocity(); 294 | 295 | SendMessage("OnLand", SendMessageOptions.DontRequireReceiver); 296 | } 297 | 298 | // Moving platforms support 299 | if (MoveWithPlatform()) { 300 | // Use the center of the lower half sphere of the capsule as reference point. 301 | // This works best when the character is standing on moving tilting platforms. 302 | movingPlatform.activeGlobalPoint = tr.position + Vector3.up * (controller.center.y - controller.height*0.5 + controller.radius); 303 | movingPlatform.activeLocalPoint = movingPlatform.activePlatform.InverseTransformPoint(movingPlatform.activeGlobalPoint); 304 | 305 | // Support moving platform rotation as well: 306 | movingPlatform.activeGlobalRotation = tr.rotation; 307 | movingPlatform.activeLocalRotation = Quaternion.Inverse(movingPlatform.activePlatform.rotation) * movingPlatform.activeGlobalRotation; 308 | } 309 | } 310 | 311 | function FixedUpdate () { 312 | if (movingPlatform.enabled) { 313 | if (movingPlatform.activePlatform != null) { 314 | if (!movingPlatform.newPlatform) { 315 | var lastVelocity : Vector3 = movingPlatform.platformVelocity; 316 | 317 | movingPlatform.platformVelocity = ( 318 | movingPlatform.activePlatform.localToWorldMatrix.MultiplyPoint3x4(movingPlatform.activeLocalPoint) 319 | - movingPlatform.lastMatrix.MultiplyPoint3x4(movingPlatform.activeLocalPoint) 320 | ) / Time.deltaTime; 321 | } 322 | movingPlatform.lastMatrix = movingPlatform.activePlatform.localToWorldMatrix; 323 | movingPlatform.newPlatform = false; 324 | } 325 | else { 326 | movingPlatform.platformVelocity = Vector3.zero; 327 | } 328 | } 329 | 330 | if (useFixedUpdate) 331 | UpdateFunction(); 332 | } 333 | 334 | function Update () { 335 | if (!useFixedUpdate) 336 | UpdateFunction(); 337 | } 338 | 339 | private function ApplyInputVelocityChange (velocity : Vector3) { 340 | if (!canControl) 341 | inputMoveDirection = Vector3.zero; 342 | 343 | // Find desired velocity 344 | var desiredVelocity : Vector3; 345 | if (grounded && TooSteep()) { 346 | // The direction we're sliding in 347 | desiredVelocity = Vector3(groundNormal.x, 0, groundNormal.z).normalized; 348 | // Find the input movement direction projected onto the sliding direction 349 | var projectedMoveDir = Vector3.Project(inputMoveDirection, desiredVelocity); 350 | // Add the sliding direction, the spped control, and the sideways control vectors 351 | desiredVelocity = desiredVelocity + projectedMoveDir * sliding.speedControl + (inputMoveDirection - projectedMoveDir) * sliding.sidewaysControl; 352 | // Multiply with the sliding speed 353 | desiredVelocity *= sliding.slidingSpeed; 354 | } 355 | else 356 | desiredVelocity = GetDesiredHorizontalVelocity(); 357 | 358 | if (movingPlatform.enabled && movingPlatform.movementTransfer == MovementTransferOnJump.PermaTransfer) { 359 | desiredVelocity += movement.frameVelocity; 360 | desiredVelocity.y = 0; 361 | } 362 | 363 | if (grounded) 364 | desiredVelocity = AdjustGroundVelocityToNormal(desiredVelocity, groundNormal); 365 | else 366 | velocity.y = 0; 367 | 368 | // Enforce max velocity change 369 | var maxVelocityChange : float = GetMaxAcceleration(grounded) * Time.deltaTime; 370 | var velocityChangeVector : Vector3 = (desiredVelocity - velocity); 371 | if (velocityChangeVector.sqrMagnitude > maxVelocityChange * maxVelocityChange) { 372 | velocityChangeVector = velocityChangeVector.normalized * maxVelocityChange; 373 | } 374 | // If we're in the air and don't have control, don't apply any velocity change at all. 375 | // If we're on the ground and don't have control we do apply it - it will correspond to friction. 376 | if (grounded || canControl) 377 | velocity += velocityChangeVector; 378 | 379 | if (grounded) { 380 | // When going uphill, the CharacterController will automatically move up by the needed amount. 381 | // Not moving it upwards manually prevent risk of lifting off from the ground. 382 | // When going downhill, DO move down manually, as gravity is not enough on steep hills. 383 | velocity.y = Mathf.Min(velocity.y, 0); 384 | } 385 | 386 | return velocity; 387 | } 388 | 389 | private function ApplyGravityAndJumping (velocity : Vector3) { 390 | 391 | if (!inputJump || !canControl) { 392 | jumping.holdingJumpButton = false; 393 | jumping.lastButtonDownTime = -100; 394 | } 395 | 396 | if (inputJump && jumping.lastButtonDownTime < 0 && canControl) 397 | jumping.lastButtonDownTime = Time.time; 398 | 399 | if (grounded) 400 | velocity.y = Mathf.Min(0, velocity.y) - movement.gravity * Time.deltaTime; 401 | else { 402 | velocity.y = movement.velocity.y - movement.gravity * Time.deltaTime; 403 | 404 | // When jumping up we don't apply gravity for some time when the user is holding the jump button. 405 | // This gives more control over jump height by pressing the button longer. 406 | if (jumping.jumping && jumping.holdingJumpButton) { 407 | // Calculate the duration that the extra jump force should have effect. 408 | // If we're still less than that duration after the jumping time, apply the force. 409 | if (Time.time < jumping.lastStartTime + jumping.extraHeight / CalculateJumpVerticalSpeed(jumping.baseHeight)) { 410 | // Negate the gravity we just applied, except we push in jumpDir rather than jump upwards. 411 | velocity += jumping.jumpDir * movement.gravity * Time.deltaTime; 412 | } 413 | } 414 | 415 | // Make sure we don't fall any faster than maxFallSpeed. This gives our character a terminal velocity. 416 | velocity.y = Mathf.Max (velocity.y, -movement.maxFallSpeed); 417 | } 418 | 419 | if (grounded) { 420 | // Jump only if the jump button was pressed down in the last 0.2 seconds. 421 | // We use this check instead of checking if it's pressed down right now 422 | // because players will often try to jump in the exact moment when hitting the ground after a jump 423 | // and if they hit the button a fraction of a second too soon and no new jump happens as a consequence, 424 | // it's confusing and it feels like the game is buggy. 425 | if (jumping.enabled && canControl && (Time.time - jumping.lastButtonDownTime < 0.2)) { 426 | grounded = false; 427 | jumping.jumping = true; 428 | jumping.lastStartTime = Time.time; 429 | jumping.lastButtonDownTime = -100; 430 | jumping.holdingJumpButton = true; 431 | 432 | // Calculate the jumping direction 433 | if (TooSteep()) 434 | jumping.jumpDir = Vector3.Slerp(Vector3.up, groundNormal, jumping.steepPerpAmount); 435 | else 436 | jumping.jumpDir = Vector3.Slerp(Vector3.up, groundNormal, jumping.perpAmount); 437 | 438 | // Apply the jumping force to the velocity. Cancel any vertical velocity first. 439 | velocity.y = 0; 440 | velocity += jumping.jumpDir * CalculateJumpVerticalSpeed (jumping.baseHeight); 441 | 442 | // Apply inertia from platform 443 | if (movingPlatform.enabled && 444 | (movingPlatform.movementTransfer == MovementTransferOnJump.InitTransfer || 445 | movingPlatform.movementTransfer == MovementTransferOnJump.PermaTransfer) 446 | ) { 447 | movement.frameVelocity = movingPlatform.platformVelocity; 448 | velocity += movingPlatform.platformVelocity; 449 | } 450 | 451 | SendMessage("OnJump", SendMessageOptions.DontRequireReceiver); 452 | } 453 | else { 454 | jumping.holdingJumpButton = false; 455 | } 456 | } 457 | 458 | return velocity; 459 | } 460 | 461 | function OnControllerColliderHit (hit : ControllerColliderHit) { 462 | if (hit.normal.y > 0 && hit.normal.y > groundNormal.y && hit.moveDirection.y < 0) { 463 | if ((hit.point - movement.lastHitPoint).sqrMagnitude > 0.001 || lastGroundNormal == Vector3.zero) 464 | groundNormal = hit.normal; 465 | else 466 | groundNormal = lastGroundNormal; 467 | 468 | movingPlatform.hitPlatform = hit.collider.transform; 469 | movement.hitPoint = hit.point; 470 | movement.frameVelocity = Vector3.zero; 471 | } 472 | } 473 | 474 | private function SubtractNewPlatformVelocity () { 475 | // When landing, subtract the velocity of the new ground from the character's velocity 476 | // since movement in ground is relative to the movement of the ground. 477 | if (movingPlatform.enabled && 478 | (movingPlatform.movementTransfer == MovementTransferOnJump.InitTransfer || 479 | movingPlatform.movementTransfer == MovementTransferOnJump.PermaTransfer) 480 | ) { 481 | // If we landed on a new platform, we have to wait for two FixedUpdates 482 | // before we know the velocity of the platform under the character 483 | if (movingPlatform.newPlatform) { 484 | var platform : Transform = movingPlatform.activePlatform; 485 | yield WaitForFixedUpdate(); 486 | yield WaitForFixedUpdate(); 487 | if (grounded && platform == movingPlatform.activePlatform) 488 | yield 1; 489 | } 490 | movement.velocity -= movingPlatform.platformVelocity; 491 | } 492 | } 493 | 494 | private function MoveWithPlatform () : boolean { 495 | return ( 496 | movingPlatform.enabled 497 | && (grounded || movingPlatform.movementTransfer == MovementTransferOnJump.PermaLocked) 498 | && movingPlatform.activePlatform != null 499 | ); 500 | } 501 | 502 | private function GetDesiredHorizontalVelocity () { 503 | // Find desired velocity 504 | var desiredLocalDirection : Vector3 = tr.InverseTransformDirection(inputMoveDirection); 505 | var maxSpeed : float = MaxSpeedInDirection(desiredLocalDirection); 506 | if (grounded) { 507 | // Modify max speed on slopes based on slope speed multiplier curve 508 | var movementSlopeAngle = Mathf.Asin(movement.velocity.normalized.y) * Mathf.Rad2Deg; 509 | maxSpeed *= movement.slopeSpeedMultiplier.Evaluate(movementSlopeAngle); 510 | } 511 | return tr.TransformDirection(desiredLocalDirection * maxSpeed); 512 | } 513 | 514 | private function AdjustGroundVelocityToNormal (hVelocity : Vector3, groundNormal : Vector3) : Vector3 { 515 | var sideways : Vector3 = Vector3.Cross(Vector3.up, hVelocity); 516 | return Vector3.Cross(sideways, groundNormal).normalized * hVelocity.magnitude; 517 | } 518 | 519 | private function IsGroundedTest () { 520 | return (groundNormal.y > 0.01); 521 | } 522 | 523 | function GetMaxAcceleration (grounded : boolean) : float { 524 | // Maximum acceleration on ground and in air 525 | if (grounded) 526 | return movement.maxGroundAcceleration; 527 | else 528 | return movement.maxAirAcceleration; 529 | } 530 | 531 | function CalculateJumpVerticalSpeed (targetJumpHeight : float) { 532 | // From the jump height and gravity we deduce the upwards speed 533 | // for the character to reach at the apex. 534 | return Mathf.Sqrt (2 * targetJumpHeight * movement.gravity); 535 | } 536 | 537 | function IsJumping () { 538 | return jumping.jumping; 539 | } 540 | 541 | function IsSliding () { 542 | return (grounded && sliding.enabled && TooSteep()); 543 | } 544 | 545 | function IsTouchingCeiling () { 546 | return (movement.collisionFlags & CollisionFlags.CollidedAbove) != 0; 547 | } 548 | 549 | function IsGrounded () { 550 | return grounded; 551 | } 552 | 553 | function TooSteep () { 554 | return (groundNormal.y <= Mathf.Cos(controller.slopeLimit * Mathf.Deg2Rad)); 555 | } 556 | 557 | function GetDirection () { 558 | return inputMoveDirection; 559 | } 560 | 561 | function SetControllable (controllable : boolean) { 562 | canControl = controllable; 563 | } 564 | 565 | // Project a direction onto elliptical quater segments based on forward, sideways, and backwards speed. 566 | // The function returns the length of the resulting vector. 567 | function MaxSpeedInDirection (desiredMovementDirection : Vector3) : float { 568 | if (desiredMovementDirection == Vector3.zero) 569 | return 0; 570 | else { 571 | var zAxisEllipseMultiplier : float = (desiredMovementDirection.z > 0 ? movement.maxForwardSpeed : movement.maxBackwardsSpeed) / movement.maxSidewaysSpeed; 572 | var temp : Vector3 = new Vector3(desiredMovementDirection.x, 0, desiredMovementDirection.z / zAxisEllipseMultiplier).normalized; 573 | var length : float = new Vector3(temp.x, 0, temp.z * zAxisEllipseMultiplier).magnitude * movement.maxSidewaysSpeed; 574 | return length; 575 | } 576 | } 577 | 578 | function SetVelocity (velocity : Vector3) { 579 | grounded = false; 580 | movement.velocity = velocity; 581 | movement.frameVelocity = Vector3.zero; 582 | SendMessage("OnExternalVelocity"); 583 | } 584 | 585 | // Require a character controller to be attached to the same game object 586 | @script RequireComponent (CharacterController) 587 | @script AddComponentMenu ("Character/Character Motor") 588 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/CharacterMotor.js.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0ab79d7f243824f5d9826bd83522c8df 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/FPSInputController.js: -------------------------------------------------------------------------------- 1 | private var motor : CharacterMotor; 2 | 3 | // Use this for initialization 4 | function Awake () { 5 | motor = GetComponent(CharacterMotor); 6 | } 7 | 8 | // Update is called once per frame 9 | function Update () { 10 | // Get the input vector from kayboard or analog stick 11 | var directionVector = new Vector3(Input.GetAxis("Horizontal"), 0, Input.GetAxis("Vertical")); 12 | 13 | if (directionVector != Vector3.zero) { 14 | // Get the length of the directon vector and then normalize it 15 | // Dividing by the length is cheaper than normalizing when we already have the length anyway 16 | var directionLength = directionVector.magnitude; 17 | directionVector = directionVector / directionLength; 18 | 19 | // Make sure the length is no bigger than 1 20 | directionLength = Mathf.Min(1, directionLength); 21 | 22 | // Make the input vector more sensitive towards the extremes and less sensitive in the middle 23 | // This makes it easier to control slow speeds when using analog sticks 24 | directionLength = directionLength * directionLength; 25 | 26 | // Multiply the normalized direction vector by the modified length 27 | directionVector = directionVector * directionLength; 28 | } 29 | 30 | // Apply the direction to the CharacterMotor 31 | motor.inputMoveDirection = transform.rotation * directionVector; 32 | motor.inputJump = Input.GetButton("Jump"); 33 | } 34 | 35 | // Require a character controller to be attached to the same game object 36 | @script RequireComponent (CharacterMotor) 37 | @script AddComponentMenu ("Character/FPS Input Controller") 38 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/FPSInputController.js.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 60bca8f58a0b8478e946e6e86658cb29 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/MouseLook.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using System.Collections; 3 | 4 | /// MouseLook rotates the transform based on the mouse delta. 5 | /// Minimum and Maximum values can be used to constrain the possible rotation 6 | 7 | /// To make an FPS style character: 8 | /// - Create a capsule. 9 | /// - Add the MouseLook script to the capsule. 10 | /// -> Set the mouse look to use LookX. (You want to only turn character but not tilt it) 11 | /// - Add FPSInputController script to the capsule 12 | /// -> A CharacterMotor and a CharacterController component will be automatically added. 13 | 14 | /// - Create a camera. Make the camera a child of the capsule. Reset it's transform. 15 | /// - Add a MouseLook script to the camera. 16 | /// -> Set the mouse look to use LookY. (You want the camera to tilt up and down like a head. The character already turns.) 17 | [AddComponentMenu("Camera-Control/Mouse Look")] 18 | public class MouseLook : MonoBehaviour { 19 | 20 | public enum RotationAxes { MouseXAndY = 0, MouseX = 1, MouseY = 2 } 21 | public RotationAxes axes = RotationAxes.MouseXAndY; 22 | public float sensitivityX = 15F; 23 | public float sensitivityY = 15F; 24 | 25 | public float minimumX = -360F; 26 | public float maximumX = 360F; 27 | 28 | public float minimumY = -90F; 29 | public float maximumY = 90F; 30 | 31 | float rotationY = 0F; 32 | 33 | void Update () 34 | { 35 | if (axes == RotationAxes.MouseXAndY) 36 | { 37 | float rotationX = transform.localEulerAngles.y + Input.GetAxis("Mouse X") * sensitivityX; 38 | 39 | rotationY += Input.GetAxis("Mouse Y") * sensitivityY; 40 | rotationY = Mathf.Clamp (rotationY, minimumY, maximumY); 41 | 42 | transform.localEulerAngles = new Vector3(-rotationY, rotationX, 0); 43 | } 44 | else if (axes == RotationAxes.MouseX) 45 | { 46 | transform.Rotate(0, Input.GetAxis("Mouse X") * sensitivityX, 0); 47 | } 48 | else 49 | { 50 | rotationY += Input.GetAxis("Mouse Y") * sensitivityY; 51 | rotationY = Mathf.Clamp (rotationY, minimumY, maximumY); 52 | 53 | transform.localEulerAngles = new Vector3(-rotationY, transform.localEulerAngles.y, 0); 54 | } 55 | } 56 | 57 | void Start () 58 | { 59 | // Make the rigid body not change rotation 60 | if (GetComponent()) 61 | GetComponent().freezeRotation = true; 62 | } 63 | } -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/MouseLook.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 68ec2fe99d1108b9d0006a298d76c639 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/PlatformInputController.js: -------------------------------------------------------------------------------- 1 | // This makes the character turn to face the current movement speed per default. 2 | var autoRotate : boolean = true; 3 | var maxRotationSpeed : float = 360; 4 | 5 | private var motor : CharacterMotor; 6 | 7 | // Use this for initialization 8 | function Awake () { 9 | motor = GetComponent(CharacterMotor); 10 | } 11 | 12 | // Update is called once per frame 13 | function Update () { 14 | // Get the input vector from kayboard or analog stick 15 | var directionVector = new Vector3(Input.GetAxis("Horizontal"), Input.GetAxis("Vertical"), 0); 16 | 17 | if (directionVector != Vector3.zero) { 18 | // Get the length of the directon vector and then normalize it 19 | // Dividing by the length is cheaper than normalizing when we already have the length anyway 20 | var directionLength = directionVector.magnitude; 21 | directionVector = directionVector / directionLength; 22 | 23 | // Make sure the length is no bigger than 1 24 | directionLength = Mathf.Min(1, directionLength); 25 | 26 | // Make the input vector more sensitive towards the extremes and less sensitive in the middle 27 | // This makes it easier to control slow speeds when using analog sticks 28 | directionLength = directionLength * directionLength; 29 | 30 | // Multiply the normalized direction vector by the modified length 31 | directionVector = directionVector * directionLength; 32 | } 33 | 34 | // Rotate the input vector into camera space so up is camera's up and right is camera's right 35 | directionVector = Camera.main.transform.rotation * directionVector; 36 | 37 | // Rotate input vector to be perpendicular to character's up vector 38 | var camToCharacterSpace = Quaternion.FromToRotation(-Camera.main.transform.forward, transform.up); 39 | directionVector = (camToCharacterSpace * directionVector); 40 | 41 | // Apply the direction to the CharacterMotor 42 | motor.inputMoveDirection = directionVector; 43 | motor.inputJump = Input.GetButton("Jump"); 44 | 45 | // Set rotation to the move direction 46 | if (autoRotate && directionVector.sqrMagnitude > 0.01) { 47 | var newForward : Vector3 = ConstantSlerp( 48 | transform.forward, 49 | directionVector, 50 | maxRotationSpeed * Time.deltaTime 51 | ); 52 | newForward = ProjectOntoPlane(newForward, transform.up); 53 | transform.rotation = Quaternion.LookRotation(newForward, transform.up); 54 | } 55 | } 56 | 57 | function ProjectOntoPlane (v : Vector3, normal : Vector3) { 58 | return v - Vector3.Project(v, normal); 59 | } 60 | 61 | function ConstantSlerp (from : Vector3, to : Vector3, angle : float) { 62 | var value : float = Mathf.Min(1, angle / Vector3.Angle(from, to)); 63 | return Vector3.Slerp(from, to, value); 64 | } 65 | 66 | // Require a character controller to be attached to the same game object 67 | @script RequireComponent (CharacterMotor) 68 | @script AddComponentMenu ("Character/Platform Input Controller") 69 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/PlatformInputController.js.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: da93ddd6928094e24bb1f3f665f143d3 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/ThirdPersonCamera.js: -------------------------------------------------------------------------------- 1 | 2 | 3 | var cameraTransform : Transform; 4 | private var _target : Transform; 5 | 6 | // The distance in the x-z plane to the target 7 | 8 | var distance = 7.0; 9 | 10 | // the height we want the camera to be above the target 11 | var height = 3.0; 12 | 13 | var angularSmoothLag = 0.3; 14 | var angularMaxSpeed = 15.0; 15 | 16 | var heightSmoothLag = 0.3; 17 | 18 | var snapSmoothLag = 0.2; 19 | var snapMaxSpeed = 720.0; 20 | 21 | var clampHeadPositionScreenSpace = 0.75; 22 | 23 | var lockCameraTimeout = 0.2; 24 | 25 | private var headOffset = Vector3.zero; 26 | private var centerOffset = Vector3.zero; 27 | 28 | private var heightVelocity = 0.0; 29 | private var angleVelocity = 0.0; 30 | private var snap = false; 31 | private var controller : ThirdPersonController; 32 | private var targetHeight = 100000.0; 33 | 34 | function Awake () 35 | { 36 | if(!cameraTransform && Camera.main) 37 | cameraTransform = Camera.main.transform; 38 | if(!cameraTransform) { 39 | Debug.Log("Please assign a camera to the ThirdPersonCamera script."); 40 | enabled = false; 41 | } 42 | 43 | 44 | _target = transform; 45 | if (_target) 46 | { 47 | controller = _target.GetComponent(ThirdPersonController); 48 | } 49 | 50 | if (controller) 51 | { 52 | var characterController : CharacterController = _target.GetComponent.(); 53 | centerOffset = characterController.bounds.center - _target.position; 54 | headOffset = centerOffset; 55 | headOffset.y = characterController.bounds.max.y - _target.position.y; 56 | } 57 | else 58 | Debug.Log("Please assign a target to the camera that has a ThirdPersonController script attached."); 59 | 60 | 61 | Cut(_target, centerOffset); 62 | } 63 | 64 | function DebugDrawStuff () 65 | { 66 | Debug.DrawLine(_target.position, _target.position + headOffset); 67 | 68 | } 69 | 70 | function AngleDistance (a : float, b : float) 71 | { 72 | a = Mathf.Repeat(a, 360); 73 | b = Mathf.Repeat(b, 360); 74 | 75 | return Mathf.Abs(b - a); 76 | } 77 | 78 | function Apply (dummyTarget : Transform, dummyCenter : Vector3) 79 | { 80 | // Early out if we don't have a target 81 | if (!controller) 82 | return; 83 | 84 | var targetCenter = _target.position + centerOffset; 85 | var targetHead = _target.position + headOffset; 86 | 87 | // DebugDrawStuff(); 88 | 89 | // Calculate the current & target rotation angles 90 | var originalTargetAngle = _target.eulerAngles.y; 91 | var currentAngle = cameraTransform.eulerAngles.y; 92 | 93 | // Adjust real target angle when camera is locked 94 | var targetAngle = originalTargetAngle; 95 | 96 | // When pressing Fire2 (alt) the camera will snap to the target direction real quick. 97 | // It will stop snapping when it reaches the target 98 | if (Input.GetButton("Fire2")) 99 | snap = true; 100 | 101 | if (snap) 102 | { 103 | // We are close to the target, so we can stop snapping now! 104 | if (AngleDistance (currentAngle, originalTargetAngle) < 3.0) 105 | snap = false; 106 | 107 | currentAngle = Mathf.SmoothDampAngle(currentAngle, targetAngle, angleVelocity, snapSmoothLag, snapMaxSpeed); 108 | } 109 | // Normal camera motion 110 | else 111 | { 112 | if (controller.GetLockCameraTimer () < lockCameraTimeout) 113 | { 114 | targetAngle = currentAngle; 115 | } 116 | 117 | // Lock the camera when moving backwards! 118 | // * It is really confusing to do 180 degree spins when turning around. 119 | if (AngleDistance (currentAngle, targetAngle) > 160 && controller.IsMovingBackwards ()) 120 | targetAngle += 180; 121 | 122 | currentAngle = Mathf.SmoothDampAngle(currentAngle, targetAngle, angleVelocity, angularSmoothLag, angularMaxSpeed); 123 | } 124 | 125 | 126 | // When jumping don't move camera upwards but only down! 127 | if (controller.IsJumping ()) 128 | { 129 | // We'd be moving the camera upwards, do that only if it's really high 130 | var newTargetHeight = targetCenter.y + height; 131 | if (newTargetHeight < targetHeight || newTargetHeight - targetHeight > 5) 132 | targetHeight = targetCenter.y + height; 133 | } 134 | // When walking always update the target height 135 | else 136 | { 137 | targetHeight = targetCenter.y + height; 138 | } 139 | 140 | // Damp the height 141 | var currentHeight = cameraTransform.position.y; 142 | currentHeight = Mathf.SmoothDamp (currentHeight, targetHeight, heightVelocity, heightSmoothLag); 143 | 144 | // Convert the angle into a rotation, by which we then reposition the camera 145 | var currentRotation = Quaternion.Euler (0, currentAngle, 0); 146 | 147 | // Set the position of the camera on the x-z plane to: 148 | // distance meters behind the target 149 | cameraTransform.position = targetCenter; 150 | cameraTransform.position += currentRotation * Vector3.back * distance; 151 | 152 | // Set the height of the camera 153 | cameraTransform.position.y = currentHeight; 154 | 155 | // Always look at the target 156 | SetUpRotation(targetCenter, targetHead); 157 | } 158 | 159 | function LateUpdate () { 160 | Apply (transform, Vector3.zero); 161 | } 162 | 163 | function Cut (dummyTarget : Transform, dummyCenter : Vector3) 164 | { 165 | var oldHeightSmooth = heightSmoothLag; 166 | var oldSnapMaxSpeed = snapMaxSpeed; 167 | var oldSnapSmooth = snapSmoothLag; 168 | 169 | snapMaxSpeed = 10000; 170 | snapSmoothLag = 0.001; 171 | heightSmoothLag = 0.001; 172 | 173 | snap = true; 174 | Apply (transform, Vector3.zero); 175 | 176 | heightSmoothLag = oldHeightSmooth; 177 | snapMaxSpeed = oldSnapMaxSpeed; 178 | snapSmoothLag = oldSnapSmooth; 179 | } 180 | 181 | function SetUpRotation (centerPos : Vector3, headPos : Vector3) 182 | { 183 | // Now it's getting hairy. The devil is in the details here, the big issue is jumping of course. 184 | // * When jumping up and down we don't want to center the guy in screen space. 185 | // This is important to give a feel for how high you jump and avoiding large camera movements. 186 | // 187 | // * At the same time we dont want him to ever go out of screen and we want all rotations to be totally smooth. 188 | // 189 | // So here is what we will do: 190 | // 191 | // 1. We first find the rotation around the y axis. Thus he is always centered on the y-axis 192 | // 2. When grounded we make him be centered 193 | // 3. When jumping we keep the camera rotation but rotate the camera to get him back into view if his head is above some threshold 194 | // 4. When landing we smoothly interpolate towards centering him on screen 195 | var cameraPos = cameraTransform.position; 196 | var offsetToCenter = centerPos - cameraPos; 197 | 198 | // Generate base rotation only around y-axis 199 | var yRotation = Quaternion.LookRotation(Vector3(offsetToCenter.x, 0, offsetToCenter.z)); 200 | 201 | var relativeOffset = Vector3.forward * distance + Vector3.down * height; 202 | cameraTransform.rotation = yRotation * Quaternion.LookRotation(relativeOffset); 203 | 204 | // Calculate the projected center position and top position in world space 205 | var centerRay = cameraTransform.GetComponent.().ViewportPointToRay(Vector3(.5, 0.5, 1)); 206 | var topRay = cameraTransform.GetComponent.().ViewportPointToRay(Vector3(.5, clampHeadPositionScreenSpace, 1)); 207 | 208 | var centerRayPos = centerRay.GetPoint(distance); 209 | var topRayPos = topRay.GetPoint(distance); 210 | 211 | var centerToTopAngle = Vector3.Angle(centerRay.direction, topRay.direction); 212 | 213 | var heightToAngle = centerToTopAngle / (centerRayPos.y - topRayPos.y); 214 | 215 | var extraLookAngle = heightToAngle * (centerRayPos.y - centerPos.y); 216 | if (extraLookAngle < centerToTopAngle) 217 | { 218 | extraLookAngle = 0; 219 | } 220 | else 221 | { 222 | extraLookAngle = extraLookAngle - centerToTopAngle; 223 | cameraTransform.rotation *= Quaternion.Euler(-extraLookAngle, 0, 0); 224 | } 225 | } 226 | 227 | function GetCenterOffset () 228 | { 229 | return centerOffset; 230 | } 231 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/ThirdPersonCamera.js.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0b167d00b3108411a8a963cba5ddde1b 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/ThirdPersonController.js: -------------------------------------------------------------------------------- 1 | 2 | // Require a character controller to be attached to the same game object 3 | @script RequireComponent(CharacterController) 4 | 5 | public var idleAnimation : AnimationClip; 6 | public var walkAnimation : AnimationClip; 7 | public var runAnimation : AnimationClip; 8 | public var jumpPoseAnimation : AnimationClip; 9 | 10 | public var walkMaxAnimationSpeed : float = 0.75; 11 | public var trotMaxAnimationSpeed : float = 1.0; 12 | public var runMaxAnimationSpeed : float = 1.0; 13 | public var jumpAnimationSpeed : float = 1.15; 14 | public var landAnimationSpeed : float = 1.0; 15 | 16 | private var _animation : Animation; 17 | 18 | enum CharacterState { 19 | Idle = 0, 20 | Walking = 1, 21 | Trotting = 2, 22 | Running = 3, 23 | Jumping = 4, 24 | } 25 | 26 | private var _characterState : CharacterState; 27 | 28 | // The speed when walking 29 | var walkSpeed = 2.0; 30 | // after trotAfterSeconds of walking we trot with trotSpeed 31 | var trotSpeed = 4.0; 32 | // when pressing "Fire3" button (cmd) we start running 33 | var runSpeed = 6.0; 34 | 35 | var inAirControlAcceleration = 3.0; 36 | 37 | // How high do we jump when pressing jump and letting go immediately 38 | var jumpHeight = 0.5; 39 | 40 | // The gravity for the character 41 | var gravity = 20.0; 42 | // The gravity in controlled descent mode 43 | var speedSmoothing = 10.0; 44 | var rotateSpeed = 500.0; 45 | var trotAfterSeconds = 3.0; 46 | 47 | var canJump = true; 48 | 49 | private var jumpRepeatTime = 0.05; 50 | private var jumpTimeout = 0.15; 51 | private var groundedTimeout = 0.25; 52 | 53 | // The camera doesnt start following the target immediately but waits for a split second to avoid too much waving around. 54 | private var lockCameraTimer = 0.0; 55 | 56 | // The current move direction in x-z 57 | private var moveDirection = Vector3.zero; 58 | // The current vertical speed 59 | private var verticalSpeed = 0.0; 60 | // The current x-z move speed 61 | private var moveSpeed = 0.0; 62 | 63 | // The last collision flags returned from controller.Move 64 | private var collisionFlags : CollisionFlags; 65 | 66 | // Are we jumping? (Initiated with jump button and not grounded yet) 67 | private var jumping = false; 68 | private var jumpingReachedApex = false; 69 | 70 | // Are we moving backwards (This locks the camera to not do a 180 degree spin) 71 | private var movingBack = false; 72 | // Is the user pressing any keys? 73 | private var isMoving = false; 74 | // When did the user start walking (Used for going into trot after a while) 75 | private var walkTimeStart = 0.0; 76 | // Last time the jump button was clicked down 77 | private var lastJumpButtonTime = -10.0; 78 | // Last time we performed a jump 79 | private var lastJumpTime = -1.0; 80 | 81 | 82 | // the height we jumped from (Used to determine for how long to apply extra jump power after jumping.) 83 | private var lastJumpStartHeight = 0.0; 84 | 85 | 86 | private var inAirVelocity = Vector3.zero; 87 | 88 | private var lastGroundedTime = 0.0; 89 | 90 | 91 | private var isControllable = true; 92 | 93 | function Awake () 94 | { 95 | moveDirection = transform.TransformDirection(Vector3.forward); 96 | 97 | _animation = GetComponent(Animation); 98 | if(!_animation) 99 | Debug.Log("The character you would like to control doesn't have animations. Moving her might look weird."); 100 | 101 | /* 102 | public var idleAnimation : AnimationClip; 103 | public var walkAnimation : AnimationClip; 104 | public var runAnimation : AnimationClip; 105 | public var jumpPoseAnimation : AnimationClip; 106 | */ 107 | if(!idleAnimation) { 108 | _animation = null; 109 | Debug.Log("No idle animation found. Turning off animations."); 110 | } 111 | if(!walkAnimation) { 112 | _animation = null; 113 | Debug.Log("No walk animation found. Turning off animations."); 114 | } 115 | if(!runAnimation) { 116 | _animation = null; 117 | Debug.Log("No run animation found. Turning off animations."); 118 | } 119 | if(!jumpPoseAnimation && canJump) { 120 | _animation = null; 121 | Debug.Log("No jump animation found and the character has canJump enabled. Turning off animations."); 122 | } 123 | 124 | } 125 | 126 | 127 | function UpdateSmoothedMovementDirection () 128 | { 129 | var cameraTransform = Camera.main.transform; 130 | var grounded = IsGrounded(); 131 | 132 | // Forward vector relative to the camera along the x-z plane 133 | var forward = cameraTransform.TransformDirection(Vector3.forward); 134 | forward.y = 0; 135 | forward = forward.normalized; 136 | 137 | // Right vector relative to the camera 138 | // Always orthogonal to the forward vector 139 | var right = Vector3(forward.z, 0, -forward.x); 140 | 141 | var v = Input.GetAxisRaw("Vertical"); 142 | var h = Input.GetAxisRaw("Horizontal"); 143 | 144 | // Are we moving backwards or looking backwards 145 | if (v < -0.2) 146 | movingBack = true; 147 | else 148 | movingBack = false; 149 | 150 | var wasMoving = isMoving; 151 | isMoving = Mathf.Abs (h) > 0.1 || Mathf.Abs (v) > 0.1; 152 | 153 | // Target direction relative to the camera 154 | var targetDirection = h * right + v * forward; 155 | 156 | // Grounded controls 157 | if (grounded) 158 | { 159 | // Lock camera for short period when transitioning moving & standing still 160 | lockCameraTimer += Time.deltaTime; 161 | if (isMoving != wasMoving) 162 | lockCameraTimer = 0.0; 163 | 164 | // We store speed and direction seperately, 165 | // so that when the character stands still we still have a valid forward direction 166 | // moveDirection is always normalized, and we only update it if there is user input. 167 | if (targetDirection != Vector3.zero) 168 | { 169 | // If we are really slow, just snap to the target direction 170 | if (moveSpeed < walkSpeed * 0.9 && grounded) 171 | { 172 | moveDirection = targetDirection.normalized; 173 | } 174 | // Otherwise smoothly turn towards it 175 | else 176 | { 177 | moveDirection = Vector3.RotateTowards(moveDirection, targetDirection, rotateSpeed * Mathf.Deg2Rad * Time.deltaTime, 1000); 178 | 179 | moveDirection = moveDirection.normalized; 180 | } 181 | } 182 | 183 | // Smooth the speed based on the current target direction 184 | var curSmooth = speedSmoothing * Time.deltaTime; 185 | 186 | // Choose target speed 187 | //* We want to support analog input but make sure you cant walk faster diagonally than just forward or sideways 188 | var targetSpeed = Mathf.Min(targetDirection.magnitude, 1.0); 189 | 190 | _characterState = CharacterState.Idle; 191 | 192 | // Pick speed modifier 193 | if (Input.GetKey (KeyCode.LeftShift) || Input.GetKey (KeyCode.RightShift)) 194 | { 195 | targetSpeed *= runSpeed; 196 | _characterState = CharacterState.Running; 197 | } 198 | else if (Time.time - trotAfterSeconds > walkTimeStart) 199 | { 200 | targetSpeed *= trotSpeed; 201 | _characterState = CharacterState.Trotting; 202 | } 203 | else 204 | { 205 | targetSpeed *= walkSpeed; 206 | _characterState = CharacterState.Walking; 207 | } 208 | 209 | moveSpeed = Mathf.Lerp(moveSpeed, targetSpeed, curSmooth); 210 | 211 | // Reset walk time start when we slow down 212 | if (moveSpeed < walkSpeed * 0.3) 213 | walkTimeStart = Time.time; 214 | } 215 | // In air controls 216 | else 217 | { 218 | // Lock camera while in air 219 | if (jumping) 220 | lockCameraTimer = 0.0; 221 | 222 | if (isMoving) 223 | inAirVelocity += targetDirection.normalized * Time.deltaTime * inAirControlAcceleration; 224 | } 225 | 226 | 227 | 228 | } 229 | 230 | 231 | function ApplyJumping () 232 | { 233 | // Prevent jumping too fast after each other 234 | if (lastJumpTime + jumpRepeatTime > Time.time) 235 | return; 236 | 237 | if (IsGrounded()) { 238 | // Jump 239 | // - Only when pressing the button down 240 | // - With a timeout so you can press the button slightly before landing 241 | if (canJump && Time.time < lastJumpButtonTime + jumpTimeout) { 242 | verticalSpeed = CalculateJumpVerticalSpeed (jumpHeight); 243 | SendMessage("DidJump", SendMessageOptions.DontRequireReceiver); 244 | } 245 | } 246 | } 247 | 248 | 249 | function ApplyGravity () 250 | { 251 | if (isControllable) // don't move player at all if not controllable. 252 | { 253 | // Apply gravity 254 | var jumpButton = Input.GetButton("Jump"); 255 | 256 | 257 | // When we reach the apex of the jump we send out a message 258 | if (jumping && !jumpingReachedApex && verticalSpeed <= 0.0) 259 | { 260 | jumpingReachedApex = true; 261 | SendMessage("DidJumpReachApex", SendMessageOptions.DontRequireReceiver); 262 | } 263 | 264 | if (IsGrounded ()) 265 | verticalSpeed = 0.0; 266 | else 267 | verticalSpeed -= gravity * Time.deltaTime; 268 | } 269 | } 270 | 271 | function CalculateJumpVerticalSpeed (targetJumpHeight : float) 272 | { 273 | // From the jump height and gravity we deduce the upwards speed 274 | // for the character to reach at the apex. 275 | return Mathf.Sqrt(2 * targetJumpHeight * gravity); 276 | } 277 | 278 | function DidJump () 279 | { 280 | jumping = true; 281 | jumpingReachedApex = false; 282 | lastJumpTime = Time.time; 283 | lastJumpStartHeight = transform.position.y; 284 | lastJumpButtonTime = -10; 285 | 286 | _characterState = CharacterState.Jumping; 287 | } 288 | 289 | function Update() { 290 | 291 | if (!isControllable) 292 | { 293 | // kill all inputs if not controllable. 294 | Input.ResetInputAxes(); 295 | } 296 | 297 | if (Input.GetButtonDown ("Jump")) 298 | { 299 | lastJumpButtonTime = Time.time; 300 | } 301 | 302 | UpdateSmoothedMovementDirection(); 303 | 304 | // Apply gravity 305 | // - extra power jump modifies gravity 306 | // - controlledDescent mode modifies gravity 307 | ApplyGravity (); 308 | 309 | // Apply jumping logic 310 | ApplyJumping (); 311 | 312 | // Calculate actual motion 313 | var movement = moveDirection * moveSpeed + Vector3 (0, verticalSpeed, 0) + inAirVelocity; 314 | movement *= Time.deltaTime; 315 | 316 | // Move the controller 317 | var controller : CharacterController = GetComponent(CharacterController); 318 | collisionFlags = controller.Move(movement); 319 | 320 | // ANIMATION sector 321 | if(_animation) { 322 | if(_characterState == CharacterState.Jumping) 323 | { 324 | if(!jumpingReachedApex) { 325 | _animation[jumpPoseAnimation.name].speed = jumpAnimationSpeed; 326 | _animation[jumpPoseAnimation.name].wrapMode = WrapMode.ClampForever; 327 | _animation.CrossFade(jumpPoseAnimation.name); 328 | } else { 329 | _animation[jumpPoseAnimation.name].speed = -landAnimationSpeed; 330 | _animation[jumpPoseAnimation.name].wrapMode = WrapMode.ClampForever; 331 | _animation.CrossFade(jumpPoseAnimation.name); 332 | } 333 | } 334 | else 335 | { 336 | if(controller.velocity.sqrMagnitude < 0.1) { 337 | _animation.CrossFade(idleAnimation.name); 338 | } 339 | else 340 | { 341 | if(_characterState == CharacterState.Running) { 342 | _animation[runAnimation.name].speed = Mathf.Clamp(controller.velocity.magnitude, 0.0, runMaxAnimationSpeed); 343 | _animation.CrossFade(runAnimation.name); 344 | } 345 | else if(_characterState == CharacterState.Trotting) { 346 | _animation[walkAnimation.name].speed = Mathf.Clamp(controller.velocity.magnitude, 0.0, trotMaxAnimationSpeed); 347 | _animation.CrossFade(walkAnimation.name); 348 | } 349 | else if(_characterState == CharacterState.Walking) { 350 | _animation[walkAnimation.name].speed = Mathf.Clamp(controller.velocity.magnitude, 0.0, walkMaxAnimationSpeed); 351 | _animation.CrossFade(walkAnimation.name); 352 | } 353 | 354 | } 355 | } 356 | } 357 | // ANIMATION sector 358 | 359 | // Set rotation to the move direction 360 | if (IsGrounded()) 361 | { 362 | 363 | transform.rotation = Quaternion.LookRotation(moveDirection); 364 | 365 | } 366 | else 367 | { 368 | var xzMove = movement; 369 | xzMove.y = 0; 370 | if (xzMove.sqrMagnitude > 0.001) 371 | { 372 | transform.rotation = Quaternion.LookRotation(xzMove); 373 | } 374 | } 375 | 376 | // We are in jump mode but just became grounded 377 | if (IsGrounded()) 378 | { 379 | lastGroundedTime = Time.time; 380 | inAirVelocity = Vector3.zero; 381 | if (jumping) 382 | { 383 | jumping = false; 384 | SendMessage("DidLand", SendMessageOptions.DontRequireReceiver); 385 | } 386 | } 387 | } 388 | 389 | function OnControllerColliderHit (hit : ControllerColliderHit ) 390 | { 391 | // Debug.DrawRay(hit.point, hit.normal); 392 | if (hit.moveDirection.y > 0.01) 393 | return; 394 | } 395 | 396 | function GetSpeed () { 397 | return moveSpeed; 398 | } 399 | 400 | function IsJumping () { 401 | return jumping; 402 | } 403 | 404 | function IsGrounded () { 405 | return (collisionFlags & CollisionFlags.CollidedBelow) != 0; 406 | } 407 | 408 | function GetDirection () { 409 | return moveDirection; 410 | } 411 | 412 | function IsMovingBackwards () { 413 | return movingBack; 414 | } 415 | 416 | function GetLockCameraTimer () 417 | { 418 | return lockCameraTimer; 419 | } 420 | 421 | function IsMoving () : boolean 422 | { 423 | return Mathf.Abs(Input.GetAxisRaw("Vertical")) + Mathf.Abs(Input.GetAxisRaw("Horizontal")) > 0.5; 424 | } 425 | 426 | function HasJumpReachedApex () 427 | { 428 | return jumpingReachedApex; 429 | } 430 | 431 | function IsGroundedWithTimeout () 432 | { 433 | return lastGroundedTime + groundedTimeout > Time.time; 434 | } 435 | 436 | function Reset () 437 | { 438 | gameObject.tag = "Player"; 439 | } 440 | 441 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/Sources/Scripts/ThirdPersonController.js.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1d5ac211a643e447ca78c2d794a16381 3 | MonoImporter: 4 | serializedVersion: 2 5 | defaultReferences: [] 6 | executionOrder: 0 7 | icon: {instanceID: 0} 8 | userData: 9 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/char.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/char.png -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/char.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4f822a18df8013246a517342c843e83c 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: 0 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 1 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/char1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Character Controllers/char1.png -------------------------------------------------------------------------------- /Assets/Standard Assets/Character Controllers/char1.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d36233802f2e3ca448ecd6f18a36c9d8 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: 0 27 | aniso: 9 28 | mipBias: -1 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 1 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3071ea9614acbfe4c880f35574f3ac51 3 | folderAsset: yes 4 | timeCreated: 1497701051 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c0ba8bcab1d6b9141966d42db59cf22d 3 | folderAsset: yes 4 | timeCreated: 1497701051 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d34e1865e511b8843aa4b6ea552960bf 3 | folderAsset: yes 4 | timeCreated: 1497701051 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares/50mmZoom.flare: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!121 &12100000 4 | Flare: 5 | m_ObjectHideFlags: 0 6 | m_PrefabParentObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_Name: 50mmZoom 9 | m_FlareTexture: {fileID: 2800000, guid: 23a02ac18d11c9ffa0009c58a8ad6659, type: 3} 10 | m_TextureLayout: 1 11 | m_Elements: 12 | - m_ImageIndex: 9 13 | m_Position: 0 14 | m_Size: 50 15 | m_Color: {r: 1, g: 1, b: 1, a: 1} 16 | m_UseLightColor: 1 17 | m_Rotate: 0 18 | m_Zoom: 1 19 | m_Fade: 1 20 | - m_ImageIndex: 0 21 | m_Position: 0 22 | m_Size: 50 23 | m_Color: {r: .0941176489, g: .0941176489, b: .0941176489, a: 1} 24 | m_UseLightColor: 1 25 | m_Rotate: 1 26 | m_Zoom: 1 27 | m_Fade: 1 28 | - m_ImageIndex: 5 29 | m_Position: 0 30 | m_Size: 20 31 | m_Color: {r: .0313725509, g: .0196078438, b: .0196078438, a: 1} 32 | m_UseLightColor: 1 33 | m_Rotate: 0 34 | m_Zoom: 0 35 | m_Fade: 1 36 | - m_ImageIndex: 5 37 | m_Position: -.269999981 38 | m_Size: 36.3899994 39 | m_Color: {r: .0313725509, g: .0235294122, b: .0196078438, a: 1} 40 | m_UseLightColor: 1 41 | m_Rotate: 0 42 | m_Zoom: 0 43 | m_Fade: 1 44 | - m_ImageIndex: 5 45 | m_Position: -.74999994 46 | m_Size: 28.6899986 47 | m_Color: {r: .0196078438, g: .0156862754, b: .0117647061, a: 1} 48 | m_UseLightColor: 1 49 | m_Rotate: 0 50 | m_Zoom: 0 51 | m_Fade: 1 52 | - m_ImageIndex: 3 53 | m_Position: 0 54 | m_Size: 10.2500019 55 | m_Color: {r: .447058827, g: 0, b: .00784313772, a: 1} 56 | m_UseLightColor: 1 57 | m_Rotate: 0 58 | m_Zoom: 0 59 | m_Fade: 1 60 | - m_ImageIndex: 5 61 | m_Position: .435999811 62 | m_Size: 4.01399994 63 | m_Color: {r: .0117647061, g: .0235294122, b: .0392156877, a: 1} 64 | m_UseLightColor: 1 65 | m_Rotate: 0 66 | m_Zoom: 0 67 | m_Fade: 1 68 | - m_ImageIndex: 5 69 | m_Position: .335999876 70 | m_Size: 2.58999991 71 | m_Color: {r: .0352941193, g: .0235294122, b: .0784313753, a: 1} 72 | m_UseLightColor: 1 73 | m_Rotate: 0 74 | m_Zoom: 0 75 | m_Fade: 1 76 | - m_ImageIndex: 5 77 | m_Position: .390999913 78 | m_Size: 7.47000074 79 | m_Color: {r: .0156862754, g: .0235294122, b: .0392156877, a: 1} 80 | m_UseLightColor: 1 81 | m_Rotate: 0 82 | m_Zoom: 0 83 | m_Fade: 1 84 | - m_ImageIndex: 7 85 | m_Position: 1.5 86 | m_Size: 7.47000074 87 | m_Color: {r: .0941176489, g: .0588235296, b: 0, a: 1} 88 | m_UseLightColor: 1 89 | m_Rotate: 0 90 | m_Zoom: 0 91 | m_Fade: 1 92 | - m_ImageIndex: 5 93 | m_Position: 1.45300031 94 | m_Size: 4.44999361 95 | m_Color: {r: .0705882385, g: .0431372561, b: 0, a: 1} 96 | m_UseLightColor: 1 97 | m_Rotate: 0 98 | m_Zoom: 0 99 | m_Fade: 1 100 | - m_ImageIndex: 4 101 | m_Position: 1.28200161 102 | m_Size: 1.5 103 | m_Color: {r: .270588249, g: .819607854, b: .572549045, a: 1} 104 | m_UseLightColor: 1 105 | m_Rotate: 0 106 | m_Zoom: 0 107 | m_Fade: 1 108 | - m_ImageIndex: 6 109 | m_Position: 1.74200153 110 | m_Size: 2.76999307 111 | m_Color: {r: .156862751, g: .0784313753, b: .270588249, a: 1} 112 | m_UseLightColor: 1 113 | m_Rotate: 0 114 | m_Zoom: 0 115 | m_Fade: 1 116 | - m_ImageIndex: 5 117 | m_Position: 1.72300005 118 | m_Size: 2.76999283 119 | m_Color: {r: .0274509806, g: .0941176489, b: .0588235296, a: 1} 120 | m_UseLightColor: 1 121 | m_Rotate: 0 122 | m_Zoom: 0 123 | m_Fade: 1 124 | - m_ImageIndex: 5 125 | m_Position: 1.52300024 126 | m_Size: 2.12999368 127 | m_Color: {r: .0509803928, g: .0313725509, b: 0, a: 1} 128 | m_UseLightColor: 1 129 | m_Rotate: 0 130 | m_Zoom: 0 131 | m_Fade: 1 132 | - m_ImageIndex: 8 133 | m_Position: -.239000008 134 | m_Size: 4.5899992 135 | m_Color: {r: .188235298, g: .149019614, b: .0588235296, a: 1} 136 | m_UseLightColor: 1 137 | m_Rotate: 0 138 | m_Zoom: 0 139 | m_Fade: 1 140 | - m_ImageIndex: 2 141 | m_Position: 2.46099973 142 | m_Size: 25.9699974 143 | m_Color: {r: .164705887, g: .164705887, b: .164705887, a: 1} 144 | m_UseLightColor: 1 145 | m_Rotate: 0 146 | m_Zoom: 0 147 | m_Fade: 1 148 | - m_ImageIndex: 1 149 | m_Position: 2.1309998 150 | m_Size: 17.2099953 151 | m_Color: {r: .164705887, g: .164705887, b: .164705887, a: 1} 152 | m_UseLightColor: 1 153 | m_Rotate: 0 154 | m_Zoom: 0 155 | m_Fade: 1 156 | - m_ImageIndex: 5 157 | m_Position: .819999993 158 | m_Size: 2.65999603 159 | m_Color: {r: .0509803928, g: .0235294122, b: 0, a: 1} 160 | m_UseLightColor: 1 161 | m_Rotate: 0 162 | m_Zoom: 0 163 | m_Fade: 1 164 | m_UseFog: 1 165 | --- !u!1002 &12100001 166 | EditorExtensionImpl: 167 | serializedVersion: 6 168 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares/50mmZoom.flare.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2666d59730ff09044abe2dac8ae03df2 3 | timeCreated: 1497701957 4 | licenseType: Free 5 | NativeFormatImporter: 6 | mainObjectFileID: -1 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares/FlareSmall.flare: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!121 &12100000 4 | Flare: 5 | m_ObjectHideFlags: 0 6 | m_PrefabParentObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_Name: FlareSmall 9 | m_FlareTexture: {fileID: 2800000, guid: 51dc82ef9d11c594d000e7c9e39e7c39, type: 3} 10 | m_TextureLayout: 0 11 | m_Elements: 12 | - m_ImageIndex: 0 13 | m_Position: 0 14 | m_Size: 10 15 | m_Color: {r: 1, g: 1, b: 1, a: 0} 16 | m_UseLightColor: 1 17 | m_Rotate: 0 18 | m_Zoom: 0 19 | m_Fade: 1 20 | - m_ImageIndex: 2 21 | m_Position: 0 22 | m_Size: 40 23 | m_Color: {r: .248752579, g: .248752579, b: .248752579, a: 0} 24 | m_UseLightColor: 1 25 | m_Rotate: 0 26 | m_Zoom: 0 27 | m_Fade: 1 28 | m_UseFog: 1 29 | --- !u!1002 &12100001 30 | EditorExtensionImpl: 31 | serializedVersion: 6 32 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares/FlareSmall.flare.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1d4b083aab4911748b15940ef5adbe2d 3 | timeCreated: 1497701051 4 | licenseType: Free 5 | NativeFormatImporter: 6 | mainObjectFileID: -1 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares/Sun.flare: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Effects/LightFlares/Flares/Sun.flare -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Flares/Sun.flare.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 23c197c6bfd97314b999ecd17f2edd88 3 | timeCreated: 1497701051 4 | licenseType: Free 5 | NativeFormatImporter: 6 | mainObjectFileID: -1 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Materials.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 723c2901c147e9948a0f55eec23ab52b 3 | folderAsset: yes 4 | timeCreated: 1497701957 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Materials/Flare50mm.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 3 6 | m_ObjectHideFlags: 0 7 | m_PrefabParentObject: {fileID: 0} 8 | m_PrefabInternal: {fileID: 0} 9 | m_Name: Flare50mm 10 | m_Shader: {fileID: 101, guid: 0000000000000000f000000000000000, type: 0} 11 | m_ShaderKeywords: [] 12 | m_CustomRenderQueue: -1 13 | m_SavedProperties: 14 | serializedVersion: 2 15 | m_TexEnvs: 16 | data: 17 | first: 18 | name: _MainTex 19 | second: 20 | m_Texture: {fileID: 2800000, guid: 23a02ac18d11c9ffa0009c58a8ad6659, type: 3} 21 | m_Scale: {x: 1, y: 1} 22 | m_Offset: {x: 0, y: 0} 23 | m_Floats: {} 24 | m_Colors: {} 25 | --- !u!1002 &2100001 26 | EditorExtensionImpl: 27 | serializedVersion: 6 28 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Materials/Flare50mm.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a6dbb96b9d112024d000e929e39e7c39 3 | NativeFormatImporter: 4 | userData: 5 | assetBundleName: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Textures.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 410475dc0a655674988ef350ce244384 3 | folderAsset: yes 4 | timeCreated: 1497701957 5 | licenseType: Free 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Textures/Flare50mm.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Effects/LightFlares/Textures/Flare50mm.psd -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Textures/Flare50mm.psd.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 23a02ac18d11c9ffa0009c58a8ad6659 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 2 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .100000001 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | cubemapConvolution: 0 24 | cubemapConvolutionSteps: 8 25 | cubemapConvolutionExponent: 1.5 26 | seamlessCubemap: 0 27 | textureFormat: -1 28 | maxTextureSize: 512 29 | textureSettings: 30 | filterMode: 1 31 | aniso: 1 32 | mipBias: 0 33 | wrapMode: 0 34 | nPOTScale: 1 35 | lightmap: 0 36 | rGBM: 0 37 | compressionQuality: 50 38 | spriteMode: 0 39 | spriteExtrude: 1 40 | spriteMeshType: 1 41 | alignment: 0 42 | spritePivot: {x: .5, y: .5} 43 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 44 | spritePixelsToUnits: 100 45 | alphaIsTransparency: 0 46 | textureType: 0 47 | buildTargetSettings: [] 48 | spriteSheet: 49 | sprites: [] 50 | spritePackingTag: 51 | userData: 52 | assetBundleName: 53 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Textures/FlareStar.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Effects/LightFlares/Textures/FlareStar.psd -------------------------------------------------------------------------------- /Assets/Standard Assets/Effects/LightFlares/Textures/FlareStar.psd.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 51dc82ef9d11c594d000e7c9e39e7c39 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 2 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | linearTexture: 0 10 | correctGamma: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 2 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: .100000001 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 0 23 | cubemapConvolution: 0 24 | cubemapConvolutionSteps: 8 25 | cubemapConvolutionExponent: 1.5 26 | seamlessCubemap: 0 27 | textureFormat: -1 28 | maxTextureSize: 256 29 | textureSettings: 30 | filterMode: 1 31 | aniso: 1 32 | mipBias: 0 33 | wrapMode: 0 34 | nPOTScale: 1 35 | lightmap: 0 36 | rGBM: 0 37 | compressionQuality: 50 38 | spriteMode: 0 39 | spriteExtrude: 1 40 | spriteMeshType: 1 41 | alignment: 0 42 | spritePivot: {x: .5, y: .5} 43 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 44 | spritePixelsToUnits: 100 45 | alphaIsTransparency: 0 46 | textureType: 0 47 | buildTargetSettings: [] 48 | spriteSheet: 49 | sprites: [] 50 | spritePackingTag: 51 | userData: 52 | assetBundleName: 53 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 607426a9820414bfd8081fb22854dbd4 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Sunny1 Skybox.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Sunny1 Skybox.mat -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Sunny1 Skybox.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a2126534b3a11b34e977105bd9e3cc03 3 | NativeFormatImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9ef50104b12ed4ca9bed40f105986cd7 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1bf34b610fe6f466faff3dcd833c06f6 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_back.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_back.tif -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_back.tif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 32ef381921b3f7f479831b042c113762 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 1 27 | aniso: 1 28 | mipBias: 0 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: 0 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_down.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_down.tif -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_down.tif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 352e5f82d7105ad408904c5f552b5fe7 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 1 27 | aniso: 1 28 | mipBias: 0 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: 0 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_front.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_front.tif -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_front.tif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2372dd1814cb4ed47a91f8174877623e 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 1 27 | aniso: 1 28 | mipBias: 0 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: 0 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_left.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_left.tif -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_left.tif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 66ebe4da1ef67e64e8aeccb820e409d6 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 1 27 | aniso: 1 28 | mipBias: 0 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: 0 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_right.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_right.tif -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_right.tif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 195c271a9118d224c8562ae67cf47a66 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 1 27 | aniso: 1 28 | mipBias: 0 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: 0 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_up.tif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_up.tif -------------------------------------------------------------------------------- /Assets/Standard Assets/Skyboxes/Textures/Sunny1/Sunny1_up.tif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8a98ef45bc7df804d95fd945abd2c943 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 1 27 | aniso: 1 28 | mipBias: 0 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: 0 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Textures.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 75a9f42993c7cb446b8bffb829d7adb4 3 | folderAsset: yes 4 | DefaultImporter: 5 | userData: 6 | -------------------------------------------------------------------------------- /Assets/Textures/checkerboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Textures/checkerboard.png -------------------------------------------------------------------------------- /Assets/Textures/checkerboard.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 78c863421fc0e6948b59e59996e6ca7d 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: -1 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Textures/crosshairalpha.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Textures/crosshairalpha.png -------------------------------------------------------------------------------- /Assets/Textures/crosshairalpha.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d379536bbe06cc646bd48c83110ea995 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | serializedVersion: 4 6 | mipmaps: 7 | mipMapMode: 0 8 | enableMipMap: 1 9 | sRGBTexture: 1 10 | linearTexture: 0 11 | fadeOut: 0 12 | borderMipMap: 0 13 | mipMapFadeDistanceStart: 1 14 | mipMapFadeDistanceEnd: 3 15 | bumpmap: 16 | convertToNormalMap: 0 17 | externalNormalMap: 0 18 | heightScale: 0.25 19 | normalMapFilter: 0 20 | isReadable: 0 21 | grayScaleToAlpha: 0 22 | generateCubemap: 6 23 | cubemapConvolution: 0 24 | seamlessCubemap: 0 25 | textureFormat: -1 26 | maxTextureSize: 1024 27 | textureSettings: 28 | filterMode: 0 29 | aniso: 16 30 | mipBias: -1 31 | wrapMode: -1 32 | nPOTScale: 0 33 | lightmap: 0 34 | compressionQuality: 50 35 | spriteMode: 1 36 | spriteExtrude: 1 37 | spriteMeshType: 1 38 | alignment: 0 39 | spritePivot: {x: 0.5, y: 0.5} 40 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 41 | spritePixelsToUnits: 100 42 | alphaUsage: 1 43 | alphaIsTransparency: 1 44 | spriteTessellationDetail: -1 45 | textureType: 8 46 | textureShape: 1 47 | maxTextureSizeSet: 0 48 | compressionQualitySet: 0 49 | textureFormatSet: 0 50 | platformSettings: 51 | - buildTarget: DefaultTexturePlatform 52 | maxTextureSize: 1024 53 | textureFormat: -1 54 | textureCompression: 1 55 | compressionQuality: 50 56 | crunchedCompression: 0 57 | allowsAlphaSplitting: 0 58 | overridden: 0 59 | - buildTarget: Standalone 60 | maxTextureSize: 1024 61 | textureFormat: -1 62 | textureCompression: 1 63 | compressionQuality: 50 64 | crunchedCompression: 0 65 | allowsAlphaSplitting: 0 66 | overridden: 0 67 | - buildTarget: Android 68 | maxTextureSize: 1024 69 | textureFormat: -1 70 | textureCompression: 1 71 | compressionQuality: 50 72 | crunchedCompression: 0 73 | allowsAlphaSplitting: 0 74 | overridden: 0 75 | spriteSheet: 76 | serializedVersion: 2 77 | sprites: [] 78 | outline: [] 79 | spritePackingTag: 80 | userData: 81 | assetBundleName: 82 | assetBundleVariant: 83 | -------------------------------------------------------------------------------- /Assets/Textures/tileTexture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Textures/tileTexture.png -------------------------------------------------------------------------------- /Assets/Textures/tileTexture.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 453ea2e1e226d2c4f83fe551570fbabf 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 0 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | alphaIsTransparency: 0 34 | textureType: -1 35 | buildTargetSettings: [] 36 | userData: 37 | -------------------------------------------------------------------------------- /Assets/Textures/tileTextureBump.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/Textures/tileTextureBump.png -------------------------------------------------------------------------------- /Assets/Textures/tileTextureBump.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 640f8137cba04b94890b520575b3e766 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 1 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 1 16 | externalNormalMap: 1 17 | heightScale: .25 18 | normalMapFilter: 1 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 512 25 | textureSettings: 26 | filterMode: 0 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: 1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 0 40 | textureType: 1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/garden.unity: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/garden.unity -------------------------------------------------------------------------------- /Assets/garden.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 61b884acb642d904382bce55cfeac61a 3 | DefaultImporter: 4 | userData: 5 | -------------------------------------------------------------------------------- /Assets/mineinunity.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/mineinunity.png -------------------------------------------------------------------------------- /Assets/mineinunity.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 736d1d9b5c5a7a24a9b99f66657b204c 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 1 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /Assets/mineinunitylogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Assets/mineinunitylogo.png -------------------------------------------------------------------------------- /Assets/mineinunitylogo.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4f87cd5fddc81ba4d8143e6f882ab622 3 | TextureImporter: 4 | serializedVersion: 2 5 | mipmaps: 6 | mipMapMode: 0 7 | enableMipMap: 1 8 | linearTexture: 0 9 | correctGamma: 0 10 | fadeOut: 0 11 | borderMipMap: 0 12 | mipMapFadeDistanceStart: 1 13 | mipMapFadeDistanceEnd: 3 14 | bumpmap: 15 | convertToNormalMap: 0 16 | externalNormalMap: 0 17 | heightScale: .25 18 | normalMapFilter: 0 19 | isReadable: 0 20 | grayScaleToAlpha: 0 21 | generateCubemap: 0 22 | seamlessCubemap: 0 23 | textureFormat: -1 24 | maxTextureSize: 1024 25 | textureSettings: 26 | filterMode: -1 27 | aniso: -1 28 | mipBias: -1 29 | wrapMode: -1 30 | nPOTScale: 1 31 | lightmap: 0 32 | compressionQuality: 50 33 | spriteMode: 0 34 | spriteExtrude: 1 35 | spriteMeshType: 1 36 | alignment: 0 37 | spritePivot: {x: .5, y: .5} 38 | spritePixelsToUnits: 100 39 | alphaIsTransparency: 1 40 | textureType: -1 41 | buildTargetSettings: [] 42 | spriteSheet: 43 | sprites: [] 44 | spritePackingTag: 45 | userData: 46 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | License 2 | ------- 3 | This program is free software: you can redistribute it and/or modify 4 | it under the terms of the GNU General Public License as published by 5 | the Free Software Foundation, either version 3 of the License, or 6 | (at your option) any later version. 7 | 8 | This program is distributed in the hope that it will be useful, 9 | but WITHOUT ANY WARRANTY; without even the implied warranty of 10 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 | GNU General Public License for more details. 12 | 13 | You should have received a copy of the GNU General Public License 14 | along with this program. If not, see . 15 | 16 | 17 | More Information 18 | ---------------- 19 | The source code and files contained in all files in this repository are property of their original owners. All files that do not have a license otherwise, are placed under the GNU General Public License. By using the files in this repository, you aggree that the contained code is provided with no warranty or guarentess and agree to all licenses in this repository. To redistribute this, you must give credit to all the original authors (listed in the credits of the README.md file). 20 | -------------------------------------------------------------------------------- /Library/AnnotationManager: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/AnnotationManager -------------------------------------------------------------------------------- /Library/AssetImportState: -------------------------------------------------------------------------------- 1 | 5;0;2;0;0 -------------------------------------------------------------------------------- /Library/AssetServerCacheV3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/AssetServerCacheV3 -------------------------------------------------------------------------------- /Library/AssetVersioning.db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/AssetVersioning.db -------------------------------------------------------------------------------- /Library/BuildPlayer.prefs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/BuildPlayer.prefs -------------------------------------------------------------------------------- /Library/BuildSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/BuildSettings.asset -------------------------------------------------------------------------------- /Library/CurrentLayout.dwlt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/CurrentLayout.dwlt -------------------------------------------------------------------------------- /Library/CurrentMaximizeLayout.dwlt: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &1 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 52 6 | m_PrefabParentObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_GameObject: {fileID: 0} 9 | m_Enabled: 1 10 | m_EditorHideFlags: 1 11 | m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0} 12 | m_Name: 13 | m_EditorClassIdentifier: 14 | m_Children: 15 | - {fileID: 3} 16 | - {fileID: 14} 17 | m_Position: 18 | serializedVersion: 2 19 | x: 0 20 | y: 30 21 | width: 1366 22 | height: 635 23 | m_MinSize: {x: 683, y: 492} 24 | m_MaxSize: {x: 14004, y: 14042} 25 | vertical: 0 26 | controlID: 9147 27 | --- !u!114 &2 28 | MonoBehaviour: 29 | m_ObjectHideFlags: 52 30 | m_PrefabParentObject: {fileID: 0} 31 | m_PrefabInternal: {fileID: 0} 32 | m_GameObject: {fileID: 0} 33 | m_Enabled: 1 34 | m_EditorHideFlags: 1 35 | m_Script: {fileID: 12015, guid: 0000000000000000e000000000000000, type: 0} 36 | m_Name: 37 | m_EditorClassIdentifier: 38 | m_AutoRepaintOnSceneChange: 1 39 | m_MinSize: {x: 200, y: 200} 40 | m_MaxSize: {x: 4000, y: 4000} 41 | m_TitleContent: 42 | m_Text: Game 43 | m_Image: {fileID: -2087823869225018852, guid: 0000000000000000d000000000000000, 44 | type: 0} 45 | m_Tooltip: 46 | m_DepthBufferBits: 32 47 | m_Pos: 48 | serializedVersion: 2 49 | x: 319 50 | y: 92 51 | width: 645 52 | height: 343 53 | m_MaximizeOnPlay: 1 54 | m_Gizmos: 0 55 | m_Stats: 0 56 | m_SelectedSizes: 00000000000000000000000000000000000000000000000000000000000000000000000000000000 57 | m_TargetDisplay: 0 58 | m_ZoomArea: 59 | m_HRangeLocked: 0 60 | m_VRangeLocked: 0 61 | m_HBaseRangeMin: -322.5 62 | m_HBaseRangeMax: 322.5 63 | m_VBaseRangeMin: -163 64 | m_VBaseRangeMax: 163 65 | m_HAllowExceedBaseRangeMin: 1 66 | m_HAllowExceedBaseRangeMax: 1 67 | m_VAllowExceedBaseRangeMin: 1 68 | m_VAllowExceedBaseRangeMax: 1 69 | m_ScaleWithWindow: 0 70 | m_HSlider: 0 71 | m_VSlider: 0 72 | m_IgnoreScrollWheelUntilClicked: 0 73 | m_EnableMouseInput: 1 74 | m_EnableSliderZoom: 0 75 | m_UniformScale: 1 76 | m_UpDirection: 1 77 | m_DrawArea: 78 | serializedVersion: 2 79 | x: 0 80 | y: 17 81 | width: 645 82 | height: 326 83 | m_Scale: {x: 1, y: 1} 84 | m_Translation: {x: 322.5, y: 163} 85 | m_MarginLeft: 0 86 | m_MarginRight: 0 87 | m_MarginTop: 0 88 | m_MarginBottom: 0 89 | m_LastShownAreaInsideMargins: 90 | serializedVersion: 2 91 | x: -322.5 92 | y: -163 93 | width: 645 94 | height: 326 95 | m_MinimalGUI: 1 96 | m_defaultScale: 1 97 | m_TargetTexture: {fileID: 0} 98 | m_CurrentColorSpace: 0 99 | m_LastWindowPixelSize: {x: 645, y: 343} 100 | m_ClearInEditMode: 1 101 | m_NoCameraWarning: 1 102 | m_LowResolutionForAspectRatios: 01000000000100000100 103 | --- !u!114 &3 104 | MonoBehaviour: 105 | m_ObjectHideFlags: 52 106 | m_PrefabParentObject: {fileID: 0} 107 | m_PrefabInternal: {fileID: 0} 108 | m_GameObject: {fileID: 0} 109 | m_Enabled: 1 110 | m_EditorHideFlags: 1 111 | m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0} 112 | m_Name: 113 | m_EditorClassIdentifier: 114 | m_Children: 115 | - {fileID: 4} 116 | - {fileID: 10} 117 | m_Position: 118 | serializedVersion: 2 119 | x: 0 120 | y: 0 121 | width: 966 122 | height: 635 123 | m_MinSize: {x: 406, y: 492} 124 | m_MaxSize: {x: 10002, y: 14042} 125 | vertical: 1 126 | controlID: 9148 127 | --- !u!114 &4 128 | MonoBehaviour: 129 | m_ObjectHideFlags: 52 130 | m_PrefabParentObject: {fileID: 0} 131 | m_PrefabInternal: {fileID: 0} 132 | m_GameObject: {fileID: 0} 133 | m_Enabled: 1 134 | m_EditorHideFlags: 1 135 | m_Script: {fileID: 12010, guid: 0000000000000000e000000000000000, type: 0} 136 | m_Name: 137 | m_EditorClassIdentifier: 138 | m_Children: 139 | - {fileID: 5} 140 | - {fileID: 7} 141 | m_Position: 142 | serializedVersion: 2 143 | x: 0 144 | y: 0 145 | width: 966 146 | height: 364 147 | m_MinSize: {x: 406, y: 221} 148 | m_MaxSize: {x: 8006, y: 4021} 149 | vertical: 0 150 | controlID: 9060 151 | --- !u!114 &5 152 | MonoBehaviour: 153 | m_ObjectHideFlags: 52 154 | m_PrefabParentObject: {fileID: 0} 155 | m_PrefabInternal: {fileID: 0} 156 | m_GameObject: {fileID: 0} 157 | m_Enabled: 1 158 | m_EditorHideFlags: 1 159 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0} 160 | m_Name: 161 | m_EditorClassIdentifier: 162 | m_Children: [] 163 | m_Position: 164 | serializedVersion: 2 165 | x: 0 166 | y: 0 167 | width: 317 168 | height: 364 169 | m_MinSize: {x: 202, y: 221} 170 | m_MaxSize: {x: 4002, y: 4021} 171 | m_ActualView: {fileID: 6} 172 | m_Panes: 173 | - {fileID: 6} 174 | m_Selected: 0 175 | m_LastSelected: 0 176 | --- !u!114 &6 177 | MonoBehaviour: 178 | m_ObjectHideFlags: 52 179 | m_PrefabParentObject: {fileID: 0} 180 | m_PrefabInternal: {fileID: 0} 181 | m_GameObject: {fileID: 0} 182 | m_Enabled: 1 183 | m_EditorHideFlags: 1 184 | m_Script: {fileID: 12061, guid: 0000000000000000e000000000000000, type: 0} 185 | m_Name: 186 | m_EditorClassIdentifier: 187 | m_AutoRepaintOnSceneChange: 0 188 | m_MinSize: {x: 200, y: 200} 189 | m_MaxSize: {x: 4000, y: 4000} 190 | m_TitleContent: 191 | m_Text: Hierarchy 192 | m_Image: {fileID: -590624980919486359, guid: 0000000000000000d000000000000000, 193 | type: 0} 194 | m_Tooltip: 195 | m_DepthBufferBits: 0 196 | m_Pos: 197 | serializedVersion: 2 198 | x: 0 199 | y: 92 200 | width: 315 201 | height: 343 202 | m_TreeViewState: 203 | scrollPos: {x: 0, y: 0} 204 | m_SelectedIDs: 86deffff 205 | m_LastClickedID: -8570 206 | m_ExpandedIDs: f4dfffffa2f5ffff02f7ffff00000000d2290000de290000fa2900001e2a00002c2a0000402a0000 207 | m_RenameOverlay: 208 | m_UserAcceptedRename: 0 209 | m_Name: Player 210 | m_OriginalName: Player 211 | m_EditFieldRect: 212 | serializedVersion: 2 213 | x: 0 214 | y: 0 215 | width: 0 216 | height: 0 217 | m_UserData: 10754 218 | m_IsWaitingForDelay: 0 219 | m_IsRenaming: 0 220 | m_OriginalEventType: 0 221 | m_IsRenamingFilename: 0 222 | m_ClientGUIView: {fileID: 5} 223 | m_SearchString: 224 | m_ExpandedScenes: [] 225 | m_CurrenRootInstanceID: 0 226 | m_Locked: 0 227 | m_CurrentSortingName: TransformSorting 228 | --- !u!114 &7 229 | MonoBehaviour: 230 | m_ObjectHideFlags: 52 231 | m_PrefabParentObject: {fileID: 0} 232 | m_PrefabInternal: {fileID: 0} 233 | m_GameObject: {fileID: 0} 234 | m_Enabled: 1 235 | m_EditorHideFlags: 1 236 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0} 237 | m_Name: 238 | m_EditorClassIdentifier: 239 | m_Children: [] 240 | m_Position: 241 | serializedVersion: 2 242 | x: 317 243 | y: 0 244 | width: 649 245 | height: 364 246 | m_MinSize: {x: 204, y: 221} 247 | m_MaxSize: {x: 4004, y: 4021} 248 | m_ActualView: {fileID: 2} 249 | m_Panes: 250 | - {fileID: 8} 251 | - {fileID: 2} 252 | - {fileID: 9} 253 | m_Selected: 1 254 | m_LastSelected: 0 255 | --- !u!114 &8 256 | MonoBehaviour: 257 | m_ObjectHideFlags: 52 258 | m_PrefabParentObject: {fileID: 0} 259 | m_PrefabInternal: {fileID: 0} 260 | m_GameObject: {fileID: 0} 261 | m_Enabled: 1 262 | m_EditorHideFlags: 1 263 | m_Script: {fileID: 12013, guid: 0000000000000000e000000000000000, type: 0} 264 | m_Name: 265 | m_EditorClassIdentifier: 266 | m_AutoRepaintOnSceneChange: 1 267 | m_MinSize: {x: 200, y: 200} 268 | m_MaxSize: {x: 4000, y: 4000} 269 | m_TitleContent: 270 | m_Text: Scene 271 | m_Image: {fileID: 2318424515335265636, guid: 0000000000000000d000000000000000, 272 | type: 0} 273 | m_Tooltip: 274 | m_DepthBufferBits: 32 275 | m_Pos: 276 | serializedVersion: 2 277 | x: 319 278 | y: 92 279 | width: 645 280 | height: 343 281 | m_SceneLighting: 0 282 | lastFramingTime: 4758.844880435786 283 | m_2DMode: 0 284 | m_isRotationLocked: 0 285 | m_AudioPlay: 0 286 | m_Position: 287 | m_Target: {x: 5, y: 60.683533, z: 5.0345836} 288 | speed: 2 289 | m_Value: {x: 5, y: 60.683533, z: 5.0345836} 290 | m_RenderMode: 0 291 | m_ValidateTrueMetals: 0 292 | m_SceneViewState: 293 | showFog: 1 294 | showMaterialUpdate: 0 295 | showSkybox: 1 296 | showFlares: 1 297 | showImageEffects: 1 298 | grid: 299 | xGrid: 300 | m_Target: 0 301 | speed: 2 302 | m_Value: 0 303 | yGrid: 304 | m_Target: 1 305 | speed: 2 306 | m_Value: 1 307 | zGrid: 308 | m_Target: 0 309 | speed: 2 310 | m_Value: 0 311 | m_Rotation: 312 | m_Target: {x: 0, y: -0.7071068, z: -0, w: 0.7071068} 313 | speed: 2 314 | m_Value: {x: 0, y: -0.70710677, z: 0, w: 0.70710677} 315 | m_Size: 316 | m_Target: 3.0038195 317 | speed: 2 318 | m_Value: 3.0038195 319 | m_Ortho: 320 | m_Target: 0 321 | speed: 2 322 | m_Value: 0 323 | m_LastSceneViewRotation: {x: 0, y: 0, z: 0, w: 0} 324 | m_LastSceneViewOrtho: 0 325 | m_ReplacementShader: {fileID: 0} 326 | m_ReplacementString: 327 | m_LastLockedObject: {fileID: 0} 328 | m_ViewIsLockedToObject: 0 329 | --- !u!114 &9 330 | MonoBehaviour: 331 | m_ObjectHideFlags: 52 332 | m_PrefabParentObject: {fileID: 0} 333 | m_PrefabInternal: {fileID: 0} 334 | m_GameObject: {fileID: 0} 335 | m_Enabled: 1 336 | m_EditorHideFlags: 0 337 | m_Script: {fileID: 12914, guid: 0000000000000000e000000000000000, type: 0} 338 | m_Name: 339 | m_EditorClassIdentifier: 340 | m_AutoRepaintOnSceneChange: 1 341 | m_MinSize: {x: 100, y: 100} 342 | m_MaxSize: {x: 4000, y: 4000} 343 | m_TitleContent: 344 | m_Text: Animator 345 | m_Image: {fileID: 663490763026382308, guid: 0000000000000000d000000000000000, 346 | type: 0} 347 | m_Tooltip: 348 | m_DepthBufferBits: 0 349 | m_Pos: 350 | serializedVersion: 2 351 | x: 319 352 | y: 92 353 | width: 645 354 | height: 343 355 | m_ViewPositions: 356 | m_KeySerializationHelper: 357 | - {fileID: 1107731750822401482, guid: 3eb5bbd8de6138640ba9d9822b2debdc, type: 2} 358 | m_ValueSerializationHelper: 359 | - {x: 337.00003, y: 185.8} 360 | m_PreviewAnimator: {fileID: 0} 361 | m_AnimatorController: {fileID: 9100000, guid: 3eb5bbd8de6138640ba9d9822b2debdc, 362 | type: 2} 363 | m_BreadCrumbs: 364 | - m_Target: {fileID: 1107731750822401482, guid: 3eb5bbd8de6138640ba9d9822b2debdc, 365 | type: 2} 366 | m_ScrollPosition: {x: 0, y: 0} 367 | stateMachineGraph: {fileID: 0} 368 | stateMachineGraphGUI: {fileID: 0} 369 | blendTreeGraph: {fileID: 0} 370 | blendTreeGraphGUI: {fileID: 0} 371 | m_AutoLiveLink: 1 372 | m_LiveLinkFollowTransitions: 0 373 | m_MiniTool: 0 374 | m_SerializedLocked: 0 375 | m_CurrentEditor: 1 376 | m_LayerEditor: 377 | m_SelectedLayerIndex: 0 378 | --- !u!114 &10 379 | MonoBehaviour: 380 | m_ObjectHideFlags: 52 381 | m_PrefabParentObject: {fileID: 0} 382 | m_PrefabInternal: {fileID: 0} 383 | m_GameObject: {fileID: 0} 384 | m_Enabled: 1 385 | m_EditorHideFlags: 1 386 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0} 387 | m_Name: 388 | m_EditorClassIdentifier: 389 | m_Children: [] 390 | m_Position: 391 | serializedVersion: 2 392 | x: 0 393 | y: 364 394 | width: 966 395 | height: 271 396 | m_MinSize: {x: 230, y: 250} 397 | m_MaxSize: {x: 10000, y: 10000} 398 | m_ActualView: {fileID: 11} 399 | m_Panes: 400 | - {fileID: 11} 401 | - {fileID: 12} 402 | - {fileID: 13} 403 | m_Selected: 0 404 | m_LastSelected: 1 405 | --- !u!114 &11 406 | MonoBehaviour: 407 | m_ObjectHideFlags: 52 408 | m_PrefabParentObject: {fileID: 0} 409 | m_PrefabInternal: {fileID: 0} 410 | m_GameObject: {fileID: 0} 411 | m_Enabled: 1 412 | m_EditorHideFlags: 1 413 | m_Script: {fileID: 12014, guid: 0000000000000000e000000000000000, type: 0} 414 | m_Name: 415 | m_EditorClassIdentifier: 416 | m_AutoRepaintOnSceneChange: 0 417 | m_MinSize: {x: 230, y: 250} 418 | m_MaxSize: {x: 10000, y: 10000} 419 | m_TitleContent: 420 | m_Text: Project 421 | m_Image: {fileID: -7501376956915960154, guid: 0000000000000000d000000000000000, 422 | type: 0} 423 | m_Tooltip: 424 | m_DepthBufferBits: 0 425 | m_Pos: 426 | serializedVersion: 2 427 | x: 0 428 | y: 456 429 | width: 964 430 | height: 250 431 | m_SearchFilter: 432 | m_NameFilter: 433 | m_ClassNames: [] 434 | m_AssetLabels: [] 435 | m_AssetBundleNames: [] 436 | m_VersionControlStates: [] 437 | m_ReferencingInstanceIDs: 438 | m_ScenePaths: [] 439 | m_ShowAllHits: 0 440 | m_SearchArea: 0 441 | m_Folders: 442 | - Assets 443 | m_ViewMode: 1 444 | m_StartGridSize: 64 445 | m_LastFolders: 446 | - Assets 447 | m_LastFoldersGridSize: -1 448 | m_LastProjectPath: C:\Users\Sushii\Documents\Git\Mine-In-Unity 449 | m_IsLocked: 0 450 | m_FolderTreeState: 451 | scrollPos: {x: 0, y: 95} 452 | m_SelectedIDs: 46290000 453 | m_LastClickedID: 10566 454 | m_ExpandedIDs: 00000000462900007829000080290000822900008429000098290000be290000962b0000982b00009c2d000000ca9a3bffffff7f 455 | m_RenameOverlay: 456 | m_UserAcceptedRename: 0 457 | m_Name: 458 | m_OriginalName: 459 | m_EditFieldRect: 460 | serializedVersion: 2 461 | x: 0 462 | y: 0 463 | width: 0 464 | height: 0 465 | m_UserData: 0 466 | m_IsWaitingForDelay: 0 467 | m_IsRenaming: 0 468 | m_OriginalEventType: 11 469 | m_IsRenamingFilename: 1 470 | m_ClientGUIView: {fileID: 0} 471 | m_SearchString: 472 | m_CreateAssetUtility: 473 | m_EndAction: {fileID: 0} 474 | m_InstanceID: 0 475 | m_Path: 476 | m_Icon: {fileID: 0} 477 | m_ResourceFile: 478 | m_AssetTreeState: 479 | scrollPos: {x: 0, y: 0} 480 | m_SelectedIDs: 481 | m_LastClickedID: 0 482 | m_ExpandedIDs: 00000000462900007829000080290000822900008429000098290000be290000962b0000982b00009c2d000000ca9a3bffffff7f 483 | m_RenameOverlay: 484 | m_UserAcceptedRename: 0 485 | m_Name: 486 | m_OriginalName: 487 | m_EditFieldRect: 488 | serializedVersion: 2 489 | x: 0 490 | y: 0 491 | width: 0 492 | height: 0 493 | m_UserData: 0 494 | m_IsWaitingForDelay: 0 495 | m_IsRenaming: 0 496 | m_OriginalEventType: 11 497 | m_IsRenamingFilename: 1 498 | m_ClientGUIView: {fileID: 0} 499 | m_SearchString: 500 | m_CreateAssetUtility: 501 | m_EndAction: {fileID: 0} 502 | m_InstanceID: 0 503 | m_Path: 504 | m_Icon: {fileID: 0} 505 | m_ResourceFile: 506 | m_ListAreaState: 507 | m_SelectedInstanceIDs: 86deffff 508 | m_LastClickedInstanceID: -8570 509 | m_HadKeyboardFocusLastEvent: 1 510 | m_ExpandedInstanceIDs: 3629000078000000 511 | m_RenameOverlay: 512 | m_UserAcceptedRename: 0 513 | m_Name: 514 | m_OriginalName: 515 | m_EditFieldRect: 516 | serializedVersion: 2 517 | x: 0 518 | y: 0 519 | width: 0 520 | height: 0 521 | m_UserData: 0 522 | m_IsWaitingForDelay: 0 523 | m_IsRenaming: 0 524 | m_OriginalEventType: 11 525 | m_IsRenamingFilename: 1 526 | m_ClientGUIView: {fileID: 0} 527 | m_CreateAssetUtility: 528 | m_EndAction: {fileID: 0} 529 | m_InstanceID: 0 530 | m_Path: 531 | m_Icon: {fileID: 0} 532 | m_ResourceFile: 533 | m_NewAssetIndexInList: -1 534 | m_ScrollPosition: {x: 0, y: 0} 535 | m_GridSize: 64 536 | m_DirectoriesAreaWidth: 115 537 | --- !u!114 &12 538 | MonoBehaviour: 539 | m_ObjectHideFlags: 52 540 | m_PrefabParentObject: {fileID: 0} 541 | m_PrefabInternal: {fileID: 0} 542 | m_GameObject: {fileID: 0} 543 | m_Enabled: 1 544 | m_EditorHideFlags: 1 545 | m_Script: {fileID: 12003, guid: 0000000000000000e000000000000000, type: 0} 546 | m_Name: 547 | m_EditorClassIdentifier: 548 | m_AutoRepaintOnSceneChange: 0 549 | m_MinSize: {x: 100, y: 100} 550 | m_MaxSize: {x: 4000, y: 4000} 551 | m_TitleContent: 552 | m_Text: Console 553 | m_Image: {fileID: 111653112392082826, guid: 0000000000000000d000000000000000, 554 | type: 0} 555 | m_Tooltip: 556 | m_DepthBufferBits: 0 557 | m_Pos: 558 | serializedVersion: 2 559 | x: 0 560 | y: 456 561 | width: 964 562 | height: 250 563 | --- !u!114 &13 564 | MonoBehaviour: 565 | m_ObjectHideFlags: 52 566 | m_PrefabParentObject: {fileID: 0} 567 | m_PrefabInternal: {fileID: 0} 568 | m_GameObject: {fileID: 0} 569 | m_Enabled: 1 570 | m_EditorHideFlags: 1 571 | m_Script: {fileID: 12071, guid: 0000000000000000e000000000000000, type: 0} 572 | m_Name: 573 | m_EditorClassIdentifier: 574 | m_AutoRepaintOnSceneChange: 0 575 | m_MinSize: {x: 100, y: 100} 576 | m_MaxSize: {x: 4000, y: 4000} 577 | m_TitleContent: 578 | m_Text: Animation 579 | m_Image: {fileID: 1561878555887300916, guid: 0000000000000000d000000000000000, 580 | type: 0} 581 | m_Tooltip: 582 | m_DepthBufferBits: 0 583 | m_Pos: 584 | serializedVersion: 2 585 | x: 0 586 | y: 456 587 | width: 964 588 | height: 250 589 | m_AnimEditor: {fileID: 0} 590 | m_Locked: 0 591 | --- !u!114 &14 592 | MonoBehaviour: 593 | m_ObjectHideFlags: 52 594 | m_PrefabParentObject: {fileID: 0} 595 | m_PrefabInternal: {fileID: 0} 596 | m_GameObject: {fileID: 0} 597 | m_Enabled: 1 598 | m_EditorHideFlags: 1 599 | m_Script: {fileID: 12006, guid: 0000000000000000e000000000000000, type: 0} 600 | m_Name: 601 | m_EditorClassIdentifier: 602 | m_Children: [] 603 | m_Position: 604 | serializedVersion: 2 605 | x: 966 606 | y: 0 607 | width: 400 608 | height: 635 609 | m_MinSize: {x: 277, y: 71} 610 | m_MaxSize: {x: 4002, y: 4021} 611 | m_ActualView: {fileID: 15} 612 | m_Panes: 613 | - {fileID: 15} 614 | - {fileID: 16} 615 | m_Selected: 0 616 | m_LastSelected: 1 617 | --- !u!114 &15 618 | MonoBehaviour: 619 | m_ObjectHideFlags: 52 620 | m_PrefabParentObject: {fileID: 0} 621 | m_PrefabInternal: {fileID: 0} 622 | m_GameObject: {fileID: 0} 623 | m_Enabled: 1 624 | m_EditorHideFlags: 1 625 | m_Script: {fileID: 12019, guid: 0000000000000000e000000000000000, type: 0} 626 | m_Name: 627 | m_EditorClassIdentifier: 628 | m_AutoRepaintOnSceneChange: 0 629 | m_MinSize: {x: 275, y: 50} 630 | m_MaxSize: {x: 4000, y: 4000} 631 | m_TitleContent: 632 | m_Text: Inspector 633 | m_Image: {fileID: -6905738622615590433, guid: 0000000000000000d000000000000000, 634 | type: 0} 635 | m_Tooltip: 636 | m_DepthBufferBits: 0 637 | m_Pos: 638 | serializedVersion: 2 639 | x: 968 640 | y: 92 641 | width: 398 642 | height: 614 643 | m_ScrollPosition: {x: 0, y: 0} 644 | m_InspectorMode: 0 645 | m_PreviewResizer: 646 | m_CachedPref: 160 647 | m_ControlHash: -371814159 648 | m_PrefName: Preview_InspectorPreview 649 | m_PreviewWindow: {fileID: 0} 650 | --- !u!114 &16 651 | MonoBehaviour: 652 | m_ObjectHideFlags: 52 653 | m_PrefabParentObject: {fileID: 0} 654 | m_PrefabInternal: {fileID: 0} 655 | m_GameObject: {fileID: 0} 656 | m_Enabled: 1 657 | m_EditorHideFlags: 1 658 | m_Script: {fileID: 12079, guid: 0000000000000000e000000000000000, type: 0} 659 | m_Name: 660 | m_EditorClassIdentifier: 661 | m_AutoRepaintOnSceneChange: 0 662 | m_MinSize: {x: 360, y: 390} 663 | m_MaxSize: {x: 4000, y: 4000} 664 | m_TitleContent: 665 | m_Text: Lighting 666 | m_Image: {fileID: 8394858894532624064, guid: 0000000000000000d000000000000000, 667 | type: 0} 668 | m_Tooltip: 669 | m_DepthBufferBits: 0 670 | m_Pos: 671 | serializedVersion: 2 672 | x: 968 673 | y: 92 674 | width: 398 675 | height: 614 676 | -------------------------------------------------------------------------------- /Library/EditorUserBuildSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/EditorUserBuildSettings.asset -------------------------------------------------------------------------------- /Library/EditorUserSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/EditorUserSettings.asset -------------------------------------------------------------------------------- /Library/FailedAssetImports.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/FailedAssetImports.txt -------------------------------------------------------------------------------- /Library/InspectorExpandedItems.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/InspectorExpandedItems.asset -------------------------------------------------------------------------------- /Library/MonoManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/MonoManager.asset -------------------------------------------------------------------------------- /Library/ProjectSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ProjectSettings.asset -------------------------------------------------------------------------------- /Library/ScriptAssemblies/Assembly-CSharp-firstpass.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptAssemblies/Assembly-CSharp-firstpass.dll -------------------------------------------------------------------------------- /Library/ScriptAssemblies/Assembly-CSharp-firstpass.dll.mdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptAssemblies/Assembly-CSharp-firstpass.dll.mdb -------------------------------------------------------------------------------- /Library/ScriptAssemblies/Assembly-CSharp.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptAssemblies/Assembly-CSharp.dll -------------------------------------------------------------------------------- /Library/ScriptAssemblies/Assembly-CSharp.dll.mdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptAssemblies/Assembly-CSharp.dll.mdb -------------------------------------------------------------------------------- /Library/ScriptAssemblies/Assembly-UnityScript-firstpass.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptAssemblies/Assembly-UnityScript-firstpass.dll -------------------------------------------------------------------------------- /Library/ScriptAssemblies/Assembly-UnityScript-firstpass.dll.mdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptAssemblies/Assembly-UnityScript-firstpass.dll.mdb -------------------------------------------------------------------------------- /Library/ScriptMapper: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/ScriptMapper -------------------------------------------------------------------------------- /Library/assetDatabase3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/assetDatabase3 -------------------------------------------------------------------------------- /Library/expandedItems: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/expandedItems -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000001000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000001000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000002000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000002000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000003000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000003000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000004000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000004000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000004100000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000004100000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000005000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000005000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000005100000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000005100000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000006000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000006000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000006100000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000006100000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000007000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000007000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000008000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000008000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/00000000000000009000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/00000000000000009000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/0000000000000000a000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/0000000000000000a000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/0000000000000000b000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/0000000000000000b000000000000000 -------------------------------------------------------------------------------- /Library/metadata/00/0000000000000000c000000000000000: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/00/0000000000000000c000000000000000 -------------------------------------------------------------------------------- /Library/metadata/08/0823cae39ac1f1147b3653dc7db245a2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/08/0823cae39ac1f1147b3653dc7db245a2 -------------------------------------------------------------------------------- /Library/metadata/0a/0ab79d7f243824f5d9826bd83522c8df: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/0a/0ab79d7f243824f5d9826bd83522c8df -------------------------------------------------------------------------------- /Library/metadata/0b/0b167d00b3108411a8a963cba5ddde1b: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/0b/0b167d00b3108411a8a963cba5ddde1b -------------------------------------------------------------------------------- /Library/metadata/10/1090bcb745ab46f48bf2f29b212db3be: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/10/1090bcb745ab46f48bf2f29b212db3be -------------------------------------------------------------------------------- /Library/metadata/19/195c271a9118d224c8562ae67cf47a66: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/19/195c271a9118d224c8562ae67cf47a66 -------------------------------------------------------------------------------- /Library/metadata/1b/1bf34b610fe6f466faff3dcd833c06f6: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/1b/1bf34b610fe6f466faff3dcd833c06f6 -------------------------------------------------------------------------------- /Library/metadata/1d/1d5ac211a643e447ca78c2d794a16381: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/1d/1d5ac211a643e447ca78c2d794a16381 -------------------------------------------------------------------------------- /Library/metadata/23/2314ce3a3eecf4816bad3c9eca4de2e1: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/23/2314ce3a3eecf4816bad3c9eca4de2e1 -------------------------------------------------------------------------------- /Library/metadata/23/2372dd1814cb4ed47a91f8174877623e: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/23/2372dd1814cb4ed47a91f8174877623e -------------------------------------------------------------------------------- /Library/metadata/32/32ef381921b3f7f479831b042c113762: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/32/32ef381921b3f7f479831b042c113762 -------------------------------------------------------------------------------- /Library/metadata/35/352e5f82d7105ad408904c5f552b5fe7: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/35/352e5f82d7105ad408904c5f552b5fe7 -------------------------------------------------------------------------------- /Library/metadata/45/453ea2e1e226d2c4f83fe551570fbabf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/45/453ea2e1e226d2c4f83fe551570fbabf -------------------------------------------------------------------------------- /Library/metadata/47/4783aadae216f2140afd1967eda81d71: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/47/4783aadae216f2140afd1967eda81d71 -------------------------------------------------------------------------------- /Library/metadata/4f/4f822a18df8013246a517342c843e83c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/4f/4f822a18df8013246a517342c843e83c -------------------------------------------------------------------------------- /Library/metadata/4f/4f87cd5fddc81ba4d8143e6f882ab622: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/4f/4f87cd5fddc81ba4d8143e6f882ab622 -------------------------------------------------------------------------------- /Library/metadata/54/54216e9ed42974e30967824b7f0b2806: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/54/54216e9ed42974e30967824b7f0b2806 -------------------------------------------------------------------------------- /Library/metadata/60/607426a9820414bfd8081fb22854dbd4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/60/607426a9820414bfd8081fb22854dbd4 -------------------------------------------------------------------------------- /Library/metadata/60/60bca8f58a0b8478e946e6e86658cb29: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/60/60bca8f58a0b8478e946e6e86658cb29 -------------------------------------------------------------------------------- /Library/metadata/61/61b884acb642d904382bce55cfeac61a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/61/61b884acb642d904382bce55cfeac61a -------------------------------------------------------------------------------- /Library/metadata/64/640f8137cba04b94890b520575b3e766: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/64/640f8137cba04b94890b520575b3e766 -------------------------------------------------------------------------------- /Library/metadata/66/66ebe4da1ef67e64e8aeccb820e409d6: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/66/66ebe4da1ef67e64e8aeccb820e409d6 -------------------------------------------------------------------------------- /Library/metadata/68/68ec2fe99d1108b9d0006a298d76c639: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/68/68ec2fe99d1108b9d0006a298d76c639 -------------------------------------------------------------------------------- /Library/metadata/72/7281089874bee8f4d9e8142b6e90032e: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/72/7281089874bee8f4d9e8142b6e90032e -------------------------------------------------------------------------------- /Library/metadata/73/736d1d9b5c5a7a24a9b99f66657b204c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/73/736d1d9b5c5a7a24a9b99f66657b204c -------------------------------------------------------------------------------- /Library/metadata/75/75a9f42993c7cb446b8bffb829d7adb4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/75/75a9f42993c7cb446b8bffb829d7adb4 -------------------------------------------------------------------------------- /Library/metadata/78/78c863421fc0e6948b59e59996e6ca7d: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/78/78c863421fc0e6948b59e59996e6ca7d -------------------------------------------------------------------------------- /Library/metadata/7e/7e0b0a994d8934541a387e092630b5db: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/7e/7e0b0a994d8934541a387e092630b5db -------------------------------------------------------------------------------- /Library/metadata/8a/8a98ef45bc7df804d95fd945abd2c943: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/8a/8a98ef45bc7df804d95fd945abd2c943 -------------------------------------------------------------------------------- /Library/metadata/8c/8ce8324a93c67cf4db6e30432f3e24ca: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/8c/8ce8324a93c67cf4db6e30432f3e24ca -------------------------------------------------------------------------------- /Library/metadata/9c/9cffcde21a77c864389d63351fb4e728: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/9c/9cffcde21a77c864389d63351fb4e728 -------------------------------------------------------------------------------- /Library/metadata/9d/9d4133d5d30b644bd87802a347eaccbe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/9d/9d4133d5d30b644bd87802a347eaccbe -------------------------------------------------------------------------------- /Library/metadata/9e/9ef50104b12ed4ca9bed40f105986cd7: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/9e/9ef50104b12ed4ca9bed40f105986cd7 -------------------------------------------------------------------------------- /Library/metadata/9f/9f67e5bce8e55e949a088765ec12d01a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/9f/9f67e5bce8e55e949a088765ec12d01a -------------------------------------------------------------------------------- /Library/metadata/a0/a05fa379be031cb49a7e7bd56e473540: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/a0/a05fa379be031cb49a7e7bd56e473540 -------------------------------------------------------------------------------- /Library/metadata/a2/a2126534b3a11b34e977105bd9e3cc03: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/a2/a2126534b3a11b34e977105bd9e3cc03 -------------------------------------------------------------------------------- /Library/metadata/b1/b19aff51390c91040b9cf58efcd70390: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/b1/b19aff51390c91040b9cf58efcd70390 -------------------------------------------------------------------------------- /Library/metadata/b5/b5b3956acb79c4c419da73d451024c28: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/b5/b5b3956acb79c4c419da73d451024c28 -------------------------------------------------------------------------------- /Library/metadata/ba/baa909ed6ff07724eaf8b9d078fd139a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/ba/baa909ed6ff07724eaf8b9d078fd139a -------------------------------------------------------------------------------- /Library/metadata/c1/c12922db8df3a95418019291d35e7168: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/c1/c12922db8df3a95418019291d35e7168 -------------------------------------------------------------------------------- /Library/metadata/c9/c989ae7dd4142dc4d8ba67d5b4166a30: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/c9/c989ae7dd4142dc4d8ba67d5b4166a30 -------------------------------------------------------------------------------- /Library/metadata/d0/d08f683727b16a2448be5007d8711e92: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/d0/d08f683727b16a2448be5007d8711e92 -------------------------------------------------------------------------------- /Library/metadata/d3/d36233802f2e3ca448ecd6f18a36c9d8: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/d3/d36233802f2e3ca448ecd6f18a36c9d8 -------------------------------------------------------------------------------- /Library/metadata/d3/d379536bbe06cc646bd48c83110ea995: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/d3/d379536bbe06cc646bd48c83110ea995 -------------------------------------------------------------------------------- /Library/metadata/da/da93ddd6928094e24bb1f3f665f143d3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/da/da93ddd6928094e24bb1f3f665f143d3 -------------------------------------------------------------------------------- /Library/metadata/df/dfcea0ba0cf7ab8468ea385fce550706: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/df/dfcea0ba0cf7ab8468ea385fce550706 -------------------------------------------------------------------------------- /Library/metadata/e1/e1fa29a895b766e4087bebbbbe4e7647: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/e1/e1fa29a895b766e4087bebbbbe4e7647 -------------------------------------------------------------------------------- /Library/metadata/e4/e401e501282cf0f4498f1e9bb2765ea5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/e4/e401e501282cf0f4498f1e9bb2765ea5 -------------------------------------------------------------------------------- /Library/metadata/ec/ec7f2c9019cef3f409a2e0c214a49214: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/ec/ec7f2c9019cef3f409a2e0c214a49214 -------------------------------------------------------------------------------- /Library/metadata/f1/f117771501994564982fa44cbd1077a6: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/f1/f117771501994564982fa44cbd1077a6 -------------------------------------------------------------------------------- /Library/metadata/f7/f781c091d1c8647c380d5230adfaee54: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/Library/metadata/f7/f781c091d1c8647c380d5230adfaee54 -------------------------------------------------------------------------------- /ProjectSettings/AudioManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/AudioManager.asset -------------------------------------------------------------------------------- /ProjectSettings/ClusterInputManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/ClusterInputManager.asset -------------------------------------------------------------------------------- /ProjectSettings/DynamicsManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/DynamicsManager.asset -------------------------------------------------------------------------------- /ProjectSettings/EditorBuildSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/EditorBuildSettings.asset -------------------------------------------------------------------------------- /ProjectSettings/EditorSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/EditorSettings.asset -------------------------------------------------------------------------------- /ProjectSettings/GraphicsSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/GraphicsSettings.asset -------------------------------------------------------------------------------- /ProjectSettings/InputManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/InputManager.asset -------------------------------------------------------------------------------- /ProjectSettings/NavMeshAreas.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/NavMeshAreas.asset -------------------------------------------------------------------------------- /ProjectSettings/NavMeshLayers.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/NavMeshLayers.asset -------------------------------------------------------------------------------- /ProjectSettings/NetworkManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/NetworkManager.asset -------------------------------------------------------------------------------- /ProjectSettings/Physics2DSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/Physics2DSettings.asset -------------------------------------------------------------------------------- /ProjectSettings/ProjectSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/ProjectSettings.asset -------------------------------------------------------------------------------- /ProjectSettings/ProjectVersion.txt: -------------------------------------------------------------------------------- 1 | m_EditorVersion: 5.6.0f3 2 | -------------------------------------------------------------------------------- /ProjectSettings/QualitySettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/QualitySettings.asset -------------------------------------------------------------------------------- /ProjectSettings/TagManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/TagManager.asset -------------------------------------------------------------------------------- /ProjectSettings/TimeManager.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/TimeManager.asset -------------------------------------------------------------------------------- /ProjectSettings/UnityConnectSettings.asset: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/devmattrick/Mine-In-Unity/a17c3fe4b1f9ae07d98a7a6e1a7c1ba3debc3d21/ProjectSettings/UnityConnectSettings.asset -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Mine-in-Unity 2 | ============= 3 | ### This repository is no longer maintained. Please see [theWildSushii's fork](https://github.com/theWildSushii/Mine-In-Unity). 4 | 5 | Installation 6 | ------------ 7 | 1. Clone using git 8 | 2. Open up Unity 9 | 3. Choose File > Open Project 10 | 4. Click Other Project 11 | 5. Navigate to your downloaded repository 12 | 6. Modify to your liking! 13 | 14 | Controls 15 | -------- 16 | - W: Move Forward 17 | - A: Move Left 18 | - S: Move Backward 19 | - D: Move Right 20 | - Mouse: Camera Control 21 | - Right Click: Place Block 22 | - Left Click: Break Block 23 | - Middle Click: Select Block 24 | - F5: 3rd Person View (Second Time Resets It) 25 | - ESC + F1: Exit Game 26 | 27 | Version Info 28 | ------------ 29 | Changelog: 30 | First Release (0.1) 31 | 32 | Known Bugs: 33 | - Walking animation is REALLY weird. We'd appreciate anyone's help with fixing that! 34 | - Slight lag on chunk load. 35 | - Block glitching. 36 | - Some world generation bugs, not too noticeable. 37 | 38 | FAQ 39 | --- 40 | 41 | Q: When Will This Come Out??? A: Out now!!!! 42 | 43 | Q: Is this going to be an exact clone? A: Maybe.....Our plans may change as time goes on! 44 | 45 | Q: Can I help? A: Yes! We need coders to help us with bugs or adding new things. 46 | 47 | Q: Where can I get help? A: www.mineinunity.tk 48 | 49 | Q: I don't now what a Unity is...can I still play? A: No. This is a dev release, so only devs can use it. Once we mature, public releases will be added. 50 | 51 | Credits 52 | ------- 53 | 54 | - mattrick16 (mattrick) for writing the engine and releasing the source 55 | - Craig Perko for some good tutorials on making this :) 56 | - imjake9 for the Minecraft player model 57 | - Unity for their awesome engine! 58 | - Heikki Törmälä for his SimplexNoise script used in world geneation 59 | 60 | --------------------------------------------------------------------------------