diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Utils.meta b/FallUnity/Assets/Utils.meta new file mode 100644 index 0000000..e946d92 --- /dev/null +++ b/FallUnity/Assets/Utils.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 13d161046e2e3ff4da9c91d640bbb749 +folderAsset: yes +timeCreated: 1572110295 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Utils.meta b/FallUnity/Assets/Utils.meta new file mode 100644 index 0000000..e946d92 --- /dev/null +++ b/FallUnity/Assets/Utils.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 13d161046e2e3ff4da9c91d640bbb749 +folderAsset: yes +timeCreated: 1572110295 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Utils/Utils.cs b/FallUnity/Assets/Utils/Utils.cs new file mode 100644 index 0000000..62e61c2 --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using UnityEngine; + + +public static class Utils +{ + public static Rect ScreenSpaceBounds(Transform t, Mesh m, Camera c) + { + float xMin = 0, xMax = 0, yMin = 0, yMax = 0; + for (int i = 0; i < m.vertexCount; i++) + { + Vector3 v = c.WorldToViewportPoint(t.TransformPoint(m.vertices[i])); + + if (i == 0) + { + xMin = xMax = v.x; + yMin = yMax = v.y; + } + else + { + if (v.x < xMin) xMin = v.x; + if (v.x > xMax) xMax = v.x; + if (v.y < yMin) yMin = v.y; + if (v.y > yMax) yMax = v.y; + } + } + + return new Rect(xMin, yMin, xMax - xMin, yMax - yMin); + } +} \ No newline at end of file diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Utils.meta b/FallUnity/Assets/Utils.meta new file mode 100644 index 0000000..e946d92 --- /dev/null +++ b/FallUnity/Assets/Utils.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 13d161046e2e3ff4da9c91d640bbb749 +folderAsset: yes +timeCreated: 1572110295 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Utils/Utils.cs b/FallUnity/Assets/Utils/Utils.cs new file mode 100644 index 0000000..62e61c2 --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using UnityEngine; + + +public static class Utils +{ + public static Rect ScreenSpaceBounds(Transform t, Mesh m, Camera c) + { + float xMin = 0, xMax = 0, yMin = 0, yMax = 0; + for (int i = 0; i < m.vertexCount; i++) + { + Vector3 v = c.WorldToViewportPoint(t.TransformPoint(m.vertices[i])); + + if (i == 0) + { + xMin = xMax = v.x; + yMin = yMax = v.y; + } + else + { + if (v.x < xMin) xMin = v.x; + if (v.x > xMax) xMax = v.x; + if (v.y < yMin) yMin = v.y; + if (v.y > yMax) yMax = v.y; + } + } + + return new Rect(xMin, yMin, xMax - xMin, yMax - yMin); + } +} \ No newline at end of file diff --git a/FallUnity/Assets/Utils/Utils.cs.meta b/FallUnity/Assets/Utils/Utils.cs.meta new file mode 100644 index 0000000..141785c --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 2db3c6f40acf16f488caf9fcc012357c +timeCreated: 1572110295 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Utils.meta b/FallUnity/Assets/Utils.meta new file mode 100644 index 0000000..e946d92 --- /dev/null +++ b/FallUnity/Assets/Utils.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 13d161046e2e3ff4da9c91d640bbb749 +folderAsset: yes +timeCreated: 1572110295 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Utils/Utils.cs b/FallUnity/Assets/Utils/Utils.cs new file mode 100644 index 0000000..62e61c2 --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using UnityEngine; + + +public static class Utils +{ + public static Rect ScreenSpaceBounds(Transform t, Mesh m, Camera c) + { + float xMin = 0, xMax = 0, yMin = 0, yMax = 0; + for (int i = 0; i < m.vertexCount; i++) + { + Vector3 v = c.WorldToViewportPoint(t.TransformPoint(m.vertices[i])); + + if (i == 0) + { + xMin = xMax = v.x; + yMin = yMax = v.y; + } + else + { + if (v.x < xMin) xMin = v.x; + if (v.x > xMax) xMax = v.x; + if (v.y < yMin) yMin = v.y; + if (v.y > yMax) yMax = v.y; + } + } + + return new Rect(xMin, yMin, xMax - xMin, yMax - yMin); + } +} \ No newline at end of file diff --git a/FallUnity/Assets/Utils/Utils.cs.meta b/FallUnity/Assets/Utils/Utils.cs.meta new file mode 100644 index 0000000..141785c --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 2db3c6f40acf16f488caf9fcc012357c +timeCreated: 1572110295 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/level.unity b/FallUnity/Assets/level.unity index debc777..f3c11f3 100755 --- a/FallUnity/Assets/level.unity +++ b/FallUnity/Assets/level.unity @@ -88,7 +88,6 @@ m_PVRFilteringAtrousPositionSigmaDirect: 0.5 m_PVRFilteringAtrousPositionSigmaIndirect: 2 m_PVRFilteringAtrousPositionSigmaAO: 1 - m_ShowResolutionOverlay: 1 m_LightingDataAsset: {fileID: 0} m_UseShadowmask: 1 --- !u!196 &4 @@ -113,135 +112,6 @@ debug: m_Flags: 0 m_NavMeshData: {fileID: 0} ---- !u!1 &257733088 -GameObject: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 257733089} - m_Layer: 0 - m_Name: Physics - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &257733089 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 257733088} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1772932289} - - {fileID: 763199061} - m_Father: {fileID: 0} - m_RootOrder: 2 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &277372078 -GameObject: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 277372079} - - component: {fileID: 277372083} - - component: {fileID: 277372082} - - component: {fileID: 277372081} - - component: {fileID: 277372080} - m_Layer: 9 - m_Name: Cube - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &277372079 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_LocalRotation: {x: 0, y: 0.38268343, z: 0, w: 0.92387956} - m_LocalPosition: {x: 0, y: -7.71, z: 0} - m_LocalScale: {x: 13.184225, y: 13.184217, z: 13.184217} - m_Children: [] - m_Father: {fileID: 1772932289} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 45, z: 0} ---- !u!64 &277372080 -MeshCollider: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_Enabled: 1 - serializedVersion: 3 - m_Convex: 0 - m_CookingOptions: 14 - m_SkinWidth: 0.01 - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} ---- !u!23 &277372081 -MeshRenderer: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Enabled: 1 - m_CastShadows: 1 - m_ReceiveShadows: 1 - m_DynamicOccludee: 1 - m_MotionVectors: 1 - m_LightProbeUsage: 1 - m_ReflectionProbeUsage: 1 - m_Materials: - - {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0} - m_StaticBatchInfo: - firstSubMesh: 0 - subMeshCount: 0 - m_StaticBatchRoot: {fileID: 0} - m_ProbeAnchor: {fileID: 0} - m_LightProbeVolumeOverride: {fileID: 0} - m_ScaleInLightmap: 1 - m_PreserveUVs: 1 - m_IgnoreNormalsForChartDetection: 0 - m_ImportantGI: 0 - m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 3 - m_MinimumChartSize: 4 - m_AutoUVMaxDistance: 0.5 - m_AutoUVMaxAngle: 89 - m_LightmapParameters: {fileID: 0} - m_SortingLayerID: 0 - m_SortingLayer: 0 - m_SortingOrder: 0 ---- !u!65 &277372082 -BoxCollider: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_Enabled: 1 - serializedVersion: 2 - m_Size: {x: 1, y: 1, z: 1} - m_Center: {x: 0, y: 0, z: 0} ---- !u!33 &277372083 -MeshFilter: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &418505720 GameObject: m_ObjectHideFlags: 0 @@ -318,11 +188,179 @@ m_TargetEye: 3 m_HDR: 1 m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 m_ForceIntoRT: 0 m_OcclusionCulling: 1 m_StereoConvergence: 10 m_StereoSeparation: 0.022 +--- !u!1 &478953809 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 478953810} + - component: {fileID: 478953814} + - component: {fileID: 478953813} + - component: {fileID: 478953812} + - component: {fileID: 478953811} + m_Layer: 0 + m_Name: Real + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &478953810 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1519907061} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!114 &478953811 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61cf17aa4290b4b4f8ec29804c6c1b37, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!23 &478953812 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_Materials: + - {fileID: 2100000, guid: 92fd918bd65df2f47960580d7d061efd, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 1 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!64 &478953813 +MeshCollider: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Convex: 0 + m_InflateMesh: 0 + m_SkinWidth: 0.01 + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &478953814 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &559179774 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 559179775} + - component: {fileID: 559179777} + - component: {fileID: 559179776} + m_Layer: 9 + m_Name: Scene + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &559179775 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_LocalRotation: {x: 0.7071068, y: -0.000000029802319, z: 0.000000029802319, w: 0.7071068} + m_LocalPosition: {x: 0.0000000021210707, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1.0000008, z: 1.0000011} + m_Children: [] + m_Father: {fileID: 1519907061} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!23 &559179776 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_Materials: + - {fileID: 2100000, guid: 92fd918bd65df2f47960580d7d061efd, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 1 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &559179777 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &594869233 GameObject: m_ObjectHideFlags: 0 @@ -425,7 +463,7 @@ - {fileID: 418505721} - {fileID: 1464748117} m_Father: {fileID: 0} - m_RootOrder: 1 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &763199060 GameObject: @@ -453,7 +491,7 @@ m_LocalPosition: {x: -8.81, y: 4.62, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 257733089} + m_Father: {fileID: 0} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 37.039, y: 41.088, z: 14.252001} --- !u!108 &763199062 @@ -492,50 +530,111 @@ m_UseColorTemperature: 0 m_ShadowRadius: 0 m_ShadowAngle: 0 ---- !u!1 &1118406554 +--- !u!1 &865854130 GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} serializedVersion: 5 m_Component: - - component: {fileID: 1118406555} - - component: {fileID: 1118406556} + - component: {fileID: 865854131} m_Layer: 0 - m_Name: ground + m_Name: Fence m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!4 &1118406555 +--- !u!4 &865854131 Transform: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1118406554} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: -0.06, y: 0, z: 2.42} + m_GameObject: {fileID: 865854130} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0, w: 0.7071068} + m_LocalPosition: {x: 7.44, y: -11.6, z: 0.42} m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: [] - m_Father: {fileID: 1777425977} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &1118406556 -SpriteRenderer: + m_Children: + - {fileID: 1519907061} + m_Father: {fileID: 890042692} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0} +--- !u!1 &890042691 +GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1118406554} + serializedVersion: 5 + m_Component: + - component: {fileID: 890042692} + m_Layer: 0 + m_Name: World + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &890042692 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 890042691} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -0.42, y: 11.6, z: -0.41} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1206131916} + - {fileID: 1529148493} + - {fileID: 865854131} + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1092719078 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1092719079} + - component: {fileID: 1092719082} + - component: {fileID: 1092719080} + m_Layer: 9 + m_Name: Scene + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1092719079 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} + m_LocalRotation: {x: 0.7071068, y: -0.000000029802319, z: 0.000000029802319, w: 0.7071068} + m_LocalPosition: {x: 0.0000000021210707, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1.0000008, z: 1.0000011} + m_Children: [] + m_Father: {fileID: 1307206125} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!23 &1092719080 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 + m_CastShadows: 1 + m_ReceiveShadows: 1 m_DynamicOccludee: 1 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + - {fileID: 2100000, guid: 3ac737af95c4a0c4d872141109506099, type: 2} m_StaticBatchInfo: firstSubMesh: 0 subMeshCount: 0 @@ -543,11 +642,11 @@ m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 - m_PreserveUVs: 0 + m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 + m_SelectedEditorRenderState: 3 m_MinimumChartSize: 4 m_AutoUVMaxDistance: 0.5 m_AutoUVMaxAngle: 89 @@ -555,16 +654,13 @@ m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 21300000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 15, y: 8} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 1 - m_MaskInteraction: 0 +--- !u!33 &1092719082 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1206131915 GameObject: m_ObjectHideFlags: 0 @@ -573,7 +669,6 @@ serializedVersion: 5 m_Component: - component: {fileID: 1206131916} - - component: {fileID: 1206131917} - component: {fileID: 1206131918} m_Layer: 0 m_Name: Spawner @@ -588,27 +683,13 @@ m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1206131915} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -0.42, y: 11.6, z: -0.41} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 3 + m_Father: {fileID: 890042692} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &1206131917 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1206131915} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 540cb6c0be5490d4687e3eb9c06ab209, type: 3} - m_Name: - m_EditorClassIdentifier: - Radius: 1 - Rate: 5 - Leaf: {fileID: 0} --- !u!114 &1206131918 MonoBehaviour: m_ObjectHideFlags: 0 @@ -696,6 +777,36 @@ m_SpriteTileMode: 0 m_WasSpriteAssigned: 1 m_MaskInteraction: 0 +--- !u!1 &1307206124 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1307206125} + m_Layer: 0 + m_Name: GroundHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1307206125 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1307206124} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 14.050603, y: 14.050598, z: 14.050598} + m_Children: + - {fileID: 1994434113} + - {fileID: 1092719079} + m_Father: {fileID: 1529148493} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1337964309 GameObject: m_ObjectHideFlags: 0 @@ -759,7 +870,6 @@ m_TargetEye: 3 m_HDR: 1 m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 m_ForceIntoRT: 0 m_OcclusionCulling: 1 m_StereoConvergence: 10 @@ -770,13 +880,13 @@ m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1337964309} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: -8.37} + m_LocalRotation: {x: 0.24914837, y: 0.36850542, z: -0.10320063, w: 0.8896508} + m_LocalPosition: {x: -7.46, y: 7.61, z: -7.45} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 1832090302} + m_Father: {fileID: 0} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: 31.29, y: 45, z: 0} --- !u!1 &1464748116 GameObject: m_ObjectHideFlags: 0 @@ -851,6 +961,36 @@ m_SpriteTileMode: 0 m_WasSpriteAssigned: 0 m_MaskInteraction: 0 +--- !u!1 &1519907060 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1519907061} + m_Layer: 0 + m_Name: FenceHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1519907061 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1519907060} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalPosition: {x: -0, y: 1.3, z: 0} + m_LocalScale: {x: 14.050603, y: 14.050598, z: 2.6934834} + m_Children: + - {fileID: 478953810} + - {fileID: 559179775} + m_Father: {fileID: 865854131} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} --- !u!1 &1529148492 GameObject: m_ObjectHideFlags: 0 @@ -873,87 +1013,71 @@ m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1529148492} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: -1.47, z: 10.369859} - m_LocalScale: {x: 1.2665029, y: 1.2665033, z: 1.2665033} + m_LocalPosition: {x: 0.42, y: -11.6, z: 0.41} + m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - - {fileID: 1777425977} - m_Father: {fileID: 1832090302} + - {fileID: 1307206125} + m_Father: {fileID: 890042692} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1772932288 +--- !u!1 &1994434112 GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} serializedVersion: 5 m_Component: - - component: {fileID: 1772932289} + - component: {fileID: 1994434113} + - component: {fileID: 1994434117} + - component: {fileID: 1994434116} + - component: {fileID: 1994434115} + - component: {fileID: 1994434114} m_Layer: 0 - m_Name: PGround + m_Name: Real m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!4 &1772932289 +--- !u!4 &1994434113 Transform: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1772932288} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_GameObject: {fileID: 1994434112} + m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 277372079} - m_Father: {fileID: 257733089} + m_Children: [] + m_Father: {fileID: 1307206125} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1777425976 -GameObject: + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!114 &1994434114 +MonoBehaviour: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 1777425977} - - component: {fileID: 1777425978} - m_Layer: 0 - m_Name: GroundSprite - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1777425977 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1777425976} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: -0, z: 7.66} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1118406555} - m_Father: {fileID: 1529148493} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &1777425978 -SpriteRenderer: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1777425976} + m_GameObject: {fileID: 1994434112} m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61cf17aa4290b4b4f8ec29804c6c1b37, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!23 &1994434115 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1994434112} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 m_DynamicOccludee: 1 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + - {fileID: 2100000, guid: 3ac737af95c4a0c4d872141109506099, type: 2} m_StaticBatchInfo: firstSubMesh: 0 subMeshCount: 0 @@ -961,11 +1085,11 @@ m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 - m_PreserveUVs: 0 + m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 + m_SelectedEditorRenderState: 3 m_MinimumChartSize: 4 m_AutoUVMaxDistance: 0.5 m_AutoUVMaxAngle: 89 @@ -973,43 +1097,24 @@ m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 0} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 1, y: 1} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 0 - m_MaskInteraction: 0 ---- !u!1 &1832090301 -GameObject: +--- !u!64 &1994434116 +MeshCollider: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 1832090302} - m_Layer: 0 - m_Name: WorldPerspective - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1832090302 -Transform: + m_GameObject: {fileID: 1994434112} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Convex: 0 + m_InflateMesh: 0 + m_SkinWidth: 0.01 + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &1994434117 +MeshFilter: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1832090301} - m_LocalRotation: {x: 0.26967824, y: -0, z: -0, w: 0.9629505} - m_LocalPosition: {x: 0, y: 4.66, z: -6.68} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1337964313} - - {fileID: 1529148493} - m_Father: {fileID: 0} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 31.29, y: 0, z: 0} + m_GameObject: {fileID: 1994434112} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Utils.meta b/FallUnity/Assets/Utils.meta new file mode 100644 index 0000000..e946d92 --- /dev/null +++ b/FallUnity/Assets/Utils.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 13d161046e2e3ff4da9c91d640bbb749 +folderAsset: yes +timeCreated: 1572110295 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Utils/Utils.cs b/FallUnity/Assets/Utils/Utils.cs new file mode 100644 index 0000000..62e61c2 --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using UnityEngine; + + +public static class Utils +{ + public static Rect ScreenSpaceBounds(Transform t, Mesh m, Camera c) + { + float xMin = 0, xMax = 0, yMin = 0, yMax = 0; + for (int i = 0; i < m.vertexCount; i++) + { + Vector3 v = c.WorldToViewportPoint(t.TransformPoint(m.vertices[i])); + + if (i == 0) + { + xMin = xMax = v.x; + yMin = yMax = v.y; + } + else + { + if (v.x < xMin) xMin = v.x; + if (v.x > xMax) xMax = v.x; + if (v.y < yMin) yMin = v.y; + if (v.y > yMax) yMax = v.y; + } + } + + return new Rect(xMin, yMin, xMax - xMin, yMax - yMin); + } +} \ No newline at end of file diff --git a/FallUnity/Assets/Utils/Utils.cs.meta b/FallUnity/Assets/Utils/Utils.cs.meta new file mode 100644 index 0000000..141785c --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 2db3c6f40acf16f488caf9fcc012357c +timeCreated: 1572110295 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/level.unity b/FallUnity/Assets/level.unity index debc777..f3c11f3 100755 --- a/FallUnity/Assets/level.unity +++ b/FallUnity/Assets/level.unity @@ -88,7 +88,6 @@ m_PVRFilteringAtrousPositionSigmaDirect: 0.5 m_PVRFilteringAtrousPositionSigmaIndirect: 2 m_PVRFilteringAtrousPositionSigmaAO: 1 - m_ShowResolutionOverlay: 1 m_LightingDataAsset: {fileID: 0} m_UseShadowmask: 1 --- !u!196 &4 @@ -113,135 +112,6 @@ debug: m_Flags: 0 m_NavMeshData: {fileID: 0} ---- !u!1 &257733088 -GameObject: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 257733089} - m_Layer: 0 - m_Name: Physics - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &257733089 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 257733088} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1772932289} - - {fileID: 763199061} - m_Father: {fileID: 0} - m_RootOrder: 2 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &277372078 -GameObject: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 277372079} - - component: {fileID: 277372083} - - component: {fileID: 277372082} - - component: {fileID: 277372081} - - component: {fileID: 277372080} - m_Layer: 9 - m_Name: Cube - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &277372079 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_LocalRotation: {x: 0, y: 0.38268343, z: 0, w: 0.92387956} - m_LocalPosition: {x: 0, y: -7.71, z: 0} - m_LocalScale: {x: 13.184225, y: 13.184217, z: 13.184217} - m_Children: [] - m_Father: {fileID: 1772932289} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 45, z: 0} ---- !u!64 &277372080 -MeshCollider: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_Enabled: 1 - serializedVersion: 3 - m_Convex: 0 - m_CookingOptions: 14 - m_SkinWidth: 0.01 - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} ---- !u!23 &277372081 -MeshRenderer: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Enabled: 1 - m_CastShadows: 1 - m_ReceiveShadows: 1 - m_DynamicOccludee: 1 - m_MotionVectors: 1 - m_LightProbeUsage: 1 - m_ReflectionProbeUsage: 1 - m_Materials: - - {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0} - m_StaticBatchInfo: - firstSubMesh: 0 - subMeshCount: 0 - m_StaticBatchRoot: {fileID: 0} - m_ProbeAnchor: {fileID: 0} - m_LightProbeVolumeOverride: {fileID: 0} - m_ScaleInLightmap: 1 - m_PreserveUVs: 1 - m_IgnoreNormalsForChartDetection: 0 - m_ImportantGI: 0 - m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 3 - m_MinimumChartSize: 4 - m_AutoUVMaxDistance: 0.5 - m_AutoUVMaxAngle: 89 - m_LightmapParameters: {fileID: 0} - m_SortingLayerID: 0 - m_SortingLayer: 0 - m_SortingOrder: 0 ---- !u!65 &277372082 -BoxCollider: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_Enabled: 1 - serializedVersion: 2 - m_Size: {x: 1, y: 1, z: 1} - m_Center: {x: 0, y: 0, z: 0} ---- !u!33 &277372083 -MeshFilter: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &418505720 GameObject: m_ObjectHideFlags: 0 @@ -318,11 +188,179 @@ m_TargetEye: 3 m_HDR: 1 m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 m_ForceIntoRT: 0 m_OcclusionCulling: 1 m_StereoConvergence: 10 m_StereoSeparation: 0.022 +--- !u!1 &478953809 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 478953810} + - component: {fileID: 478953814} + - component: {fileID: 478953813} + - component: {fileID: 478953812} + - component: {fileID: 478953811} + m_Layer: 0 + m_Name: Real + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &478953810 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1519907061} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!114 &478953811 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61cf17aa4290b4b4f8ec29804c6c1b37, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!23 &478953812 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_Materials: + - {fileID: 2100000, guid: 92fd918bd65df2f47960580d7d061efd, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 1 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!64 &478953813 +MeshCollider: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Convex: 0 + m_InflateMesh: 0 + m_SkinWidth: 0.01 + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &478953814 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &559179774 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 559179775} + - component: {fileID: 559179777} + - component: {fileID: 559179776} + m_Layer: 9 + m_Name: Scene + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &559179775 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_LocalRotation: {x: 0.7071068, y: -0.000000029802319, z: 0.000000029802319, w: 0.7071068} + m_LocalPosition: {x: 0.0000000021210707, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1.0000008, z: 1.0000011} + m_Children: [] + m_Father: {fileID: 1519907061} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!23 &559179776 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_Materials: + - {fileID: 2100000, guid: 92fd918bd65df2f47960580d7d061efd, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 1 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &559179777 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &594869233 GameObject: m_ObjectHideFlags: 0 @@ -425,7 +463,7 @@ - {fileID: 418505721} - {fileID: 1464748117} m_Father: {fileID: 0} - m_RootOrder: 1 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &763199060 GameObject: @@ -453,7 +491,7 @@ m_LocalPosition: {x: -8.81, y: 4.62, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 257733089} + m_Father: {fileID: 0} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 37.039, y: 41.088, z: 14.252001} --- !u!108 &763199062 @@ -492,50 +530,111 @@ m_UseColorTemperature: 0 m_ShadowRadius: 0 m_ShadowAngle: 0 ---- !u!1 &1118406554 +--- !u!1 &865854130 GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} serializedVersion: 5 m_Component: - - component: {fileID: 1118406555} - - component: {fileID: 1118406556} + - component: {fileID: 865854131} m_Layer: 0 - m_Name: ground + m_Name: Fence m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!4 &1118406555 +--- !u!4 &865854131 Transform: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1118406554} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: -0.06, y: 0, z: 2.42} + m_GameObject: {fileID: 865854130} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0, w: 0.7071068} + m_LocalPosition: {x: 7.44, y: -11.6, z: 0.42} m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: [] - m_Father: {fileID: 1777425977} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &1118406556 -SpriteRenderer: + m_Children: + - {fileID: 1519907061} + m_Father: {fileID: 890042692} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0} +--- !u!1 &890042691 +GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1118406554} + serializedVersion: 5 + m_Component: + - component: {fileID: 890042692} + m_Layer: 0 + m_Name: World + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &890042692 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 890042691} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -0.42, y: 11.6, z: -0.41} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1206131916} + - {fileID: 1529148493} + - {fileID: 865854131} + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1092719078 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1092719079} + - component: {fileID: 1092719082} + - component: {fileID: 1092719080} + m_Layer: 9 + m_Name: Scene + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1092719079 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} + m_LocalRotation: {x: 0.7071068, y: -0.000000029802319, z: 0.000000029802319, w: 0.7071068} + m_LocalPosition: {x: 0.0000000021210707, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1.0000008, z: 1.0000011} + m_Children: [] + m_Father: {fileID: 1307206125} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!23 &1092719080 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 + m_CastShadows: 1 + m_ReceiveShadows: 1 m_DynamicOccludee: 1 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + - {fileID: 2100000, guid: 3ac737af95c4a0c4d872141109506099, type: 2} m_StaticBatchInfo: firstSubMesh: 0 subMeshCount: 0 @@ -543,11 +642,11 @@ m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 - m_PreserveUVs: 0 + m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 + m_SelectedEditorRenderState: 3 m_MinimumChartSize: 4 m_AutoUVMaxDistance: 0.5 m_AutoUVMaxAngle: 89 @@ -555,16 +654,13 @@ m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 21300000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 15, y: 8} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 1 - m_MaskInteraction: 0 +--- !u!33 &1092719082 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1206131915 GameObject: m_ObjectHideFlags: 0 @@ -573,7 +669,6 @@ serializedVersion: 5 m_Component: - component: {fileID: 1206131916} - - component: {fileID: 1206131917} - component: {fileID: 1206131918} m_Layer: 0 m_Name: Spawner @@ -588,27 +683,13 @@ m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1206131915} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -0.42, y: 11.6, z: -0.41} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 3 + m_Father: {fileID: 890042692} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &1206131917 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1206131915} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 540cb6c0be5490d4687e3eb9c06ab209, type: 3} - m_Name: - m_EditorClassIdentifier: - Radius: 1 - Rate: 5 - Leaf: {fileID: 0} --- !u!114 &1206131918 MonoBehaviour: m_ObjectHideFlags: 0 @@ -696,6 +777,36 @@ m_SpriteTileMode: 0 m_WasSpriteAssigned: 1 m_MaskInteraction: 0 +--- !u!1 &1307206124 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1307206125} + m_Layer: 0 + m_Name: GroundHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1307206125 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1307206124} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 14.050603, y: 14.050598, z: 14.050598} + m_Children: + - {fileID: 1994434113} + - {fileID: 1092719079} + m_Father: {fileID: 1529148493} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1337964309 GameObject: m_ObjectHideFlags: 0 @@ -759,7 +870,6 @@ m_TargetEye: 3 m_HDR: 1 m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 m_ForceIntoRT: 0 m_OcclusionCulling: 1 m_StereoConvergence: 10 @@ -770,13 +880,13 @@ m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1337964309} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: -8.37} + m_LocalRotation: {x: 0.24914837, y: 0.36850542, z: -0.10320063, w: 0.8896508} + m_LocalPosition: {x: -7.46, y: 7.61, z: -7.45} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 1832090302} + m_Father: {fileID: 0} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: 31.29, y: 45, z: 0} --- !u!1 &1464748116 GameObject: m_ObjectHideFlags: 0 @@ -851,6 +961,36 @@ m_SpriteTileMode: 0 m_WasSpriteAssigned: 0 m_MaskInteraction: 0 +--- !u!1 &1519907060 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1519907061} + m_Layer: 0 + m_Name: FenceHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1519907061 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1519907060} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalPosition: {x: -0, y: 1.3, z: 0} + m_LocalScale: {x: 14.050603, y: 14.050598, z: 2.6934834} + m_Children: + - {fileID: 478953810} + - {fileID: 559179775} + m_Father: {fileID: 865854131} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} --- !u!1 &1529148492 GameObject: m_ObjectHideFlags: 0 @@ -873,87 +1013,71 @@ m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1529148492} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: -1.47, z: 10.369859} - m_LocalScale: {x: 1.2665029, y: 1.2665033, z: 1.2665033} + m_LocalPosition: {x: 0.42, y: -11.6, z: 0.41} + m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - - {fileID: 1777425977} - m_Father: {fileID: 1832090302} + - {fileID: 1307206125} + m_Father: {fileID: 890042692} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1772932288 +--- !u!1 &1994434112 GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} serializedVersion: 5 m_Component: - - component: {fileID: 1772932289} + - component: {fileID: 1994434113} + - component: {fileID: 1994434117} + - component: {fileID: 1994434116} + - component: {fileID: 1994434115} + - component: {fileID: 1994434114} m_Layer: 0 - m_Name: PGround + m_Name: Real m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!4 &1772932289 +--- !u!4 &1994434113 Transform: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1772932288} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_GameObject: {fileID: 1994434112} + m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 277372079} - m_Father: {fileID: 257733089} + m_Children: [] + m_Father: {fileID: 1307206125} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1777425976 -GameObject: + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!114 &1994434114 +MonoBehaviour: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 1777425977} - - component: {fileID: 1777425978} - m_Layer: 0 - m_Name: GroundSprite - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1777425977 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1777425976} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: -0, z: 7.66} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1118406555} - m_Father: {fileID: 1529148493} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &1777425978 -SpriteRenderer: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1777425976} + m_GameObject: {fileID: 1994434112} m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61cf17aa4290b4b4f8ec29804c6c1b37, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!23 &1994434115 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1994434112} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 m_DynamicOccludee: 1 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + - {fileID: 2100000, guid: 3ac737af95c4a0c4d872141109506099, type: 2} m_StaticBatchInfo: firstSubMesh: 0 subMeshCount: 0 @@ -961,11 +1085,11 @@ m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 - m_PreserveUVs: 0 + m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 + m_SelectedEditorRenderState: 3 m_MinimumChartSize: 4 m_AutoUVMaxDistance: 0.5 m_AutoUVMaxAngle: 89 @@ -973,43 +1097,24 @@ m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 0} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 1, y: 1} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 0 - m_MaskInteraction: 0 ---- !u!1 &1832090301 -GameObject: +--- !u!64 &1994434116 +MeshCollider: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 1832090302} - m_Layer: 0 - m_Name: WorldPerspective - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1832090302 -Transform: + m_GameObject: {fileID: 1994434112} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Convex: 0 + m_InflateMesh: 0 + m_SkinWidth: 0.01 + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &1994434117 +MeshFilter: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1832090301} - m_LocalRotation: {x: 0.26967824, y: -0, z: -0, w: 0.9629505} - m_LocalPosition: {x: 0, y: 4.66, z: -6.68} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1337964313} - - {fileID: 1529148493} - m_Father: {fileID: 0} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 31.29, y: 0, z: 0} + m_GameObject: {fileID: 1994434112} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} diff --git a/FallUnity/ProjectSettings/DynamicsManager.asset b/FallUnity/ProjectSettings/DynamicsManager.asset index 219523f..4095a05 100755 --- a/FallUnity/ProjectSettings/DynamicsManager.asset +++ b/FallUnity/ProjectSettings/DynamicsManager.asset @@ -3,7 +3,7 @@ --- !u!55 &1 PhysicsManager: m_ObjectHideFlags: 0 - serializedVersion: 7 + serializedVersion: 3 m_Gravity: {x: 0, y: -2.55, z: 0} m_DefaultMaterial: {fileID: 0} m_BounceThreshold: 2 @@ -14,16 +14,7 @@ m_QueriesHitBackfaces: 0 m_QueriesHitTriggers: 1 m_EnableAdaptiveForce: 0 - m_ClothInterCollisionDistance: 0 - m_ClothInterCollisionStiffness: 0 - m_ContactsGeneration: 1 + m_EnablePCM: 1 m_LayerCollisionMatrix: fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffbffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff m_AutoSimulation: 1 m_AutoSyncTransforms: 1 - m_ClothInterCollisionSettingsToggle: 0 - m_ContactPairsMode: 0 - m_BroadphaseType: 0 - m_WorldBounds: - m_Center: {x: 0, y: 0, z: 0} - m_Extent: {x: 250, y: 250, z: 250} - m_WorldSubdivisions: 8 diff --git a/FallUnity/Assets/Ground/Materials.meta b/FallUnity/Assets/Ground/Materials.meta new file mode 100644 index 0000000..59fdfdc --- /dev/null +++ b/FallUnity/Assets/Ground/Materials.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: c675b3121c6e4e043909510b24551075 +folderAsset: yes +timeCreated: 1572113444 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/fence.mat b/FallUnity/Assets/Ground/Materials/fence.mat new file mode 100644 index 0000000..ab8d079 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat @@ -0,0 +1,27 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: fence + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 1b56c9a31f081ca4d8a1aca43c169cd2, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: [] + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/fence.mat.meta b/FallUnity/Assets/Ground/Materials/fence.mat.meta new file mode 100644 index 0000000..d468c94 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/fence.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 92fd918bd65df2f47960580d7d061efd +timeCreated: 1572115461 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/Materials/ground.mat b/FallUnity/Assets/Ground/Materials/ground.mat new file mode 100644 index 0000000..86cbdee --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat @@ -0,0 +1,28 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: ground + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _MainTex: + m_Texture: {fileID: 2800000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _Cutoff: 0.5 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} diff --git a/FallUnity/Assets/Ground/Materials/ground.mat.meta b/FallUnity/Assets/Ground/Materials/ground.mat.meta new file mode 100644 index 0000000..57f4740 --- /dev/null +++ b/FallUnity/Assets/Ground/Materials/ground.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 3ac737af95c4a0c4d872141109506099 +timeCreated: 1572113444 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldMat.mat b/FallUnity/Assets/Ground/WorldMat.mat new file mode 100644 index 0000000..aabfaca --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 6 + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_Name: WorldMat + m_Shader: {fileID: 4800000, guid: 219eb327d7dce1348ab44ae9dc7f06aa, type: 3} + m_ShaderKeywords: + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Floats: + - _BumpScale: 1 + - _Cutoff: 0.5 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _GlossMapScale: 1 + - _Glossiness: 0.5 + - _GlossyReflections: 1 + - _Metallic: 0 + - _Mode: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.02 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _UVSec: 0 + - _ZWrite: 1 + m_Colors: + - _Bounds: {r: 0, g: 0, b: 0, a: 0} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} diff --git a/FallUnity/Assets/Ground/WorldMat.mat.meta b/FallUnity/Assets/Ground/WorldMat.mat.meta new file mode 100644 index 0000000..acc9a35 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldMat.mat.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: cae1eb2a3abe89f4dbffc286a5b7c93f +timeCreated: 1572110550 +licenseType: Free +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs b/FallUnity/Assets/Ground/WorldRenderHelper.cs new file mode 100644 index 0000000..8fa19bb --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs @@ -0,0 +1,21 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class WorldRenderHelper : MonoBehaviour { + private MeshRenderer render; + private MeshFilter filter; + // Use this for initialization + void Start () { + filter = GetComponent(); + render = GetComponent(); + } + + [ExecuteInEditMode] + void Update() + { + Rect bounds = Utils.ScreenSpaceBounds(transform, filter.sharedMesh, GameObject.Find("Main Camera").GetComponentInChildren()); + + render.materials[0].SetVector("_Bounds", new Vector4(bounds.xMin, bounds.yMin, bounds.width, bounds.height)); + } +} diff --git a/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta new file mode 100644 index 0000000..2862a0d --- /dev/null +++ b/FallUnity/Assets/Ground/WorldRenderHelper.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 61cf17aa4290b4b4f8ec29804c6c1b37 +timeCreated: 1572110667 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/WorldShader.shader b/FallUnity/Assets/Ground/WorldShader.shader new file mode 100644 index 0000000..746cfda --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader @@ -0,0 +1,72 @@ +Shader "Unlit/WorldShader" +{ + Properties + { + _MainTex ("Texture", 2D) = "white" {} + _Bounds("Bounds", Vector) = (0,0,0,0) + } + SubShader + { + Tags { "RenderType"="Transparent" "Queue"="Transparent" "IgnoreProjector"="True" } + LOD 100 + + ZWrite Off + Blend SrcAlpha OneMinusSrcAlpha + + Pass + { + CGPROGRAM + #pragma vertex vert + #pragma fragment frag + // make fog work + #pragma multi_compile_fog + + #include "UnityCG.cginc" + #include "AutoLight.cginc" + + struct appdata + { + float4 vertex : POSITION; + float2 uv : TEXCOORD0; + }; + + struct v2f + { + float2 uv : TEXCOORD0; + UNITY_FOG_COORDS(1) + float4 vertex : SV_POSITION; + float2 screenPos : TEXCOORD1; + }; + + sampler2D _MainTex; + float4 _MainTex_ST; + + float4 _Bounds; + + v2f vert (appdata v) + { + v2f o; + o.vertex = UnityObjectToClipPos(v.vertex); + o.uv = TRANSFORM_TEX(v.uv, _MainTex); + UNITY_TRANSFER_FOG(o,o.vertex); + o.screenPos = ComputeScreenPos(o.vertex); + return o; + } + + fixed4 frag (v2f i) : SV_Target + { + // sample the texture + //fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //fixed4 col = half4(half2((i.screenPos.xy - _Bounds.xy) / _Bounds.zw), 0, 1); + fixed4 col = tex2D(_MainTex, (i.screenPos.xy - _Bounds.xy) / _Bounds.zw); + //float xVal = (i.screenPos.x - _Bounds.x) / _Bounds.z; + //float xVal = i.screenPos.x; + //fixed4 col = half4(half3(xVal, xVal, xVal), 1); + // apply fog + //UNITY_APPLY_FOG(i.fogCoord, col); + return col; + } + ENDCG + } + } +} diff --git a/FallUnity/Assets/Ground/WorldShader.shader.meta b/FallUnity/Assets/Ground/WorldShader.shader.meta new file mode 100644 index 0000000..a9b82c6 --- /dev/null +++ b/FallUnity/Assets/Ground/WorldShader.shader.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 219eb327d7dce1348ab44ae9dc7f06aa +timeCreated: 1572110429 +licenseType: Free +ShaderImporter: + externalObjects: {} + defaultTextures: [] + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/fence.png b/FallUnity/Assets/Ground/fence.png new file mode 100644 index 0000000..f94d677 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png Binary files differ diff --git a/FallUnity/Assets/Ground/fence.png.meta b/FallUnity/Assets/Ground/fence.png.meta new file mode 100644 index 0000000..88c9e34 --- /dev/null +++ b/FallUnity/Assets/Ground/fence.png.meta @@ -0,0 +1,76 @@ +fileFormatVersion: 2 +guid: 1b56c9a31f081ca4d8a1aca43c169cd2 +timeCreated: 1572114830 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 1 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: -1 + wrapV: -1 + wrapW: -1 + nPOTScale: 1 + lightmap: 0 + compressionQuality: 50 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 0 + spriteTessellationDetail: -1 + textureType: 0 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Ground/ground.png b/FallUnity/Assets/Ground/ground.png index c448080..9a42eb6 100644 --- a/FallUnity/Assets/Ground/ground.png +++ b/FallUnity/Assets/Ground/ground.png Binary files differ diff --git a/FallUnity/Assets/Ground/ground.png.meta b/FallUnity/Assets/Ground/ground.png.meta index 6abcc6f..14b2831 100644 --- a/FallUnity/Assets/Ground/ground.png.meta +++ b/FallUnity/Assets/Ground/ground.png.meta @@ -8,7 +8,7 @@ serializedVersion: 4 mipmaps: mipMapMode: 0 - enableMipMap: 0 + enableMipMap: 1 sRGBTexture: 1 linearTexture: 0 fadeOut: 0 @@ -34,8 +34,8 @@ filterMode: -1 aniso: -1 mipBias: -1 - wrapU: 1 - wrapV: 1 + wrapU: -1 + wrapV: -1 wrapW: -1 nPOTScale: 0 lightmap: 0 @@ -50,7 +50,7 @@ alphaUsage: 1 alphaIsTransparency: 1 spriteTessellationDetail: -1 - textureType: 8 + textureType: 0 textureShape: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 diff --git a/FallUnity/Assets/Utils.meta b/FallUnity/Assets/Utils.meta new file mode 100644 index 0000000..e946d92 --- /dev/null +++ b/FallUnity/Assets/Utils.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 13d161046e2e3ff4da9c91d640bbb749 +folderAsset: yes +timeCreated: 1572110295 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/Utils/Utils.cs b/FallUnity/Assets/Utils/Utils.cs new file mode 100644 index 0000000..62e61c2 --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using UnityEngine; + + +public static class Utils +{ + public static Rect ScreenSpaceBounds(Transform t, Mesh m, Camera c) + { + float xMin = 0, xMax = 0, yMin = 0, yMax = 0; + for (int i = 0; i < m.vertexCount; i++) + { + Vector3 v = c.WorldToViewportPoint(t.TransformPoint(m.vertices[i])); + + if (i == 0) + { + xMin = xMax = v.x; + yMin = yMax = v.y; + } + else + { + if (v.x < xMin) xMin = v.x; + if (v.x > xMax) xMax = v.x; + if (v.y < yMin) yMin = v.y; + if (v.y > yMax) yMax = v.y; + } + } + + return new Rect(xMin, yMin, xMax - xMin, yMax - yMin); + } +} \ No newline at end of file diff --git a/FallUnity/Assets/Utils/Utils.cs.meta b/FallUnity/Assets/Utils/Utils.cs.meta new file mode 100644 index 0000000..141785c --- /dev/null +++ b/FallUnity/Assets/Utils/Utils.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 2db3c6f40acf16f488caf9fcc012357c +timeCreated: 1572110295 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/FallUnity/Assets/level.unity b/FallUnity/Assets/level.unity index debc777..f3c11f3 100755 --- a/FallUnity/Assets/level.unity +++ b/FallUnity/Assets/level.unity @@ -88,7 +88,6 @@ m_PVRFilteringAtrousPositionSigmaDirect: 0.5 m_PVRFilteringAtrousPositionSigmaIndirect: 2 m_PVRFilteringAtrousPositionSigmaAO: 1 - m_ShowResolutionOverlay: 1 m_LightingDataAsset: {fileID: 0} m_UseShadowmask: 1 --- !u!196 &4 @@ -113,135 +112,6 @@ debug: m_Flags: 0 m_NavMeshData: {fileID: 0} ---- !u!1 &257733088 -GameObject: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 257733089} - m_Layer: 0 - m_Name: Physics - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &257733089 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 257733088} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1772932289} - - {fileID: 763199061} - m_Father: {fileID: 0} - m_RootOrder: 2 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &277372078 -GameObject: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 277372079} - - component: {fileID: 277372083} - - component: {fileID: 277372082} - - component: {fileID: 277372081} - - component: {fileID: 277372080} - m_Layer: 9 - m_Name: Cube - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &277372079 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_LocalRotation: {x: 0, y: 0.38268343, z: 0, w: 0.92387956} - m_LocalPosition: {x: 0, y: -7.71, z: 0} - m_LocalScale: {x: 13.184225, y: 13.184217, z: 13.184217} - m_Children: [] - m_Father: {fileID: 1772932289} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 45, z: 0} ---- !u!64 &277372080 -MeshCollider: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_Enabled: 1 - serializedVersion: 3 - m_Convex: 0 - m_CookingOptions: 14 - m_SkinWidth: 0.01 - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} ---- !u!23 &277372081 -MeshRenderer: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Enabled: 1 - m_CastShadows: 1 - m_ReceiveShadows: 1 - m_DynamicOccludee: 1 - m_MotionVectors: 1 - m_LightProbeUsage: 1 - m_ReflectionProbeUsage: 1 - m_Materials: - - {fileID: 10303, guid: 0000000000000000f000000000000000, type: 0} - m_StaticBatchInfo: - firstSubMesh: 0 - subMeshCount: 0 - m_StaticBatchRoot: {fileID: 0} - m_ProbeAnchor: {fileID: 0} - m_LightProbeVolumeOverride: {fileID: 0} - m_ScaleInLightmap: 1 - m_PreserveUVs: 1 - m_IgnoreNormalsForChartDetection: 0 - m_ImportantGI: 0 - m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 3 - m_MinimumChartSize: 4 - m_AutoUVMaxDistance: 0.5 - m_AutoUVMaxAngle: 89 - m_LightmapParameters: {fileID: 0} - m_SortingLayerID: 0 - m_SortingLayer: 0 - m_SortingOrder: 0 ---- !u!65 &277372082 -BoxCollider: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Material: {fileID: 0} - m_IsTrigger: 0 - m_Enabled: 1 - serializedVersion: 2 - m_Size: {x: 1, y: 1, z: 1} - m_Center: {x: 0, y: 0, z: 0} ---- !u!33 &277372083 -MeshFilter: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 277372078} - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &418505720 GameObject: m_ObjectHideFlags: 0 @@ -318,11 +188,179 @@ m_TargetEye: 3 m_HDR: 1 m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 m_ForceIntoRT: 0 m_OcclusionCulling: 1 m_StereoConvergence: 10 m_StereoSeparation: 0.022 +--- !u!1 &478953809 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 478953810} + - component: {fileID: 478953814} + - component: {fileID: 478953813} + - component: {fileID: 478953812} + - component: {fileID: 478953811} + m_Layer: 0 + m_Name: Real + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &478953810 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1519907061} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!114 &478953811 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61cf17aa4290b4b4f8ec29804c6c1b37, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!23 &478953812 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_Materials: + - {fileID: 2100000, guid: 92fd918bd65df2f47960580d7d061efd, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 1 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!64 &478953813 +MeshCollider: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Convex: 0 + m_InflateMesh: 0 + m_SkinWidth: 0.01 + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &478953814 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 478953809} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &559179774 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 559179775} + - component: {fileID: 559179777} + - component: {fileID: 559179776} + m_Layer: 9 + m_Name: Scene + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &559179775 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_LocalRotation: {x: 0.7071068, y: -0.000000029802319, z: 0.000000029802319, w: 0.7071068} + m_LocalPosition: {x: 0.0000000021210707, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1.0000008, z: 1.0000011} + m_Children: [] + m_Father: {fileID: 1519907061} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!23 &559179776 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_Materials: + - {fileID: 2100000, guid: 92fd918bd65df2f47960580d7d061efd, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_PreserveUVs: 1 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 +--- !u!33 &559179777 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 559179774} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &594869233 GameObject: m_ObjectHideFlags: 0 @@ -425,7 +463,7 @@ - {fileID: 418505721} - {fileID: 1464748117} m_Father: {fileID: 0} - m_RootOrder: 1 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &763199060 GameObject: @@ -453,7 +491,7 @@ m_LocalPosition: {x: -8.81, y: 4.62, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 257733089} + m_Father: {fileID: 0} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 37.039, y: 41.088, z: 14.252001} --- !u!108 &763199062 @@ -492,50 +530,111 @@ m_UseColorTemperature: 0 m_ShadowRadius: 0 m_ShadowAngle: 0 ---- !u!1 &1118406554 +--- !u!1 &865854130 GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} serializedVersion: 5 m_Component: - - component: {fileID: 1118406555} - - component: {fileID: 1118406556} + - component: {fileID: 865854131} m_Layer: 0 - m_Name: ground + m_Name: Fence m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!4 &1118406555 +--- !u!4 &865854131 Transform: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1118406554} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: -0.06, y: 0, z: 2.42} + m_GameObject: {fileID: 865854130} + m_LocalRotation: {x: 0, y: 0.7071068, z: 0, w: 0.7071068} + m_LocalPosition: {x: 7.44, y: -11.6, z: 0.42} m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: [] - m_Father: {fileID: 1777425977} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &1118406556 -SpriteRenderer: + m_Children: + - {fileID: 1519907061} + m_Father: {fileID: 890042692} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0} +--- !u!1 &890042691 +GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1118406554} + serializedVersion: 5 + m_Component: + - component: {fileID: 890042692} + m_Layer: 0 + m_Name: World + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &890042692 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 890042691} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -0.42, y: 11.6, z: -0.41} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1206131916} + - {fileID: 1529148493} + - {fileID: 865854131} + m_Father: {fileID: 0} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1092719078 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1092719079} + - component: {fileID: 1092719082} + - component: {fileID: 1092719080} + m_Layer: 9 + m_Name: Scene + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1092719079 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} + m_LocalRotation: {x: 0.7071068, y: -0.000000029802319, z: 0.000000029802319, w: 0.7071068} + m_LocalPosition: {x: 0.0000000021210707, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1.0000008, z: 1.0000011} + m_Children: [] + m_Father: {fileID: 1307206125} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!23 &1092719080 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 + m_CastShadows: 1 + m_ReceiveShadows: 1 m_DynamicOccludee: 1 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + - {fileID: 2100000, guid: 3ac737af95c4a0c4d872141109506099, type: 2} m_StaticBatchInfo: firstSubMesh: 0 subMeshCount: 0 @@ -543,11 +642,11 @@ m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 - m_PreserveUVs: 0 + m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 + m_SelectedEditorRenderState: 3 m_MinimumChartSize: 4 m_AutoUVMaxDistance: 0.5 m_AutoUVMaxAngle: 89 @@ -555,16 +654,13 @@ m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 21300000, guid: 52d9e4c5ed1ec784c9ffb3750610c8f6, type: 3} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 15, y: 8} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 1 - m_MaskInteraction: 0 +--- !u!33 &1092719082 +MeshFilter: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1092719078} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1206131915 GameObject: m_ObjectHideFlags: 0 @@ -573,7 +669,6 @@ serializedVersion: 5 m_Component: - component: {fileID: 1206131916} - - component: {fileID: 1206131917} - component: {fileID: 1206131918} m_Layer: 0 m_Name: Spawner @@ -588,27 +683,13 @@ m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1206131915} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -0.42, y: 11.6, z: -0.41} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 3 + m_Father: {fileID: 890042692} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &1206131917 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1206131915} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 540cb6c0be5490d4687e3eb9c06ab209, type: 3} - m_Name: - m_EditorClassIdentifier: - Radius: 1 - Rate: 5 - Leaf: {fileID: 0} --- !u!114 &1206131918 MonoBehaviour: m_ObjectHideFlags: 0 @@ -696,6 +777,36 @@ m_SpriteTileMode: 0 m_WasSpriteAssigned: 1 m_MaskInteraction: 0 +--- !u!1 &1307206124 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1307206125} + m_Layer: 0 + m_Name: GroundHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1307206125 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1307206124} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 14.050603, y: 14.050598, z: 14.050598} + m_Children: + - {fileID: 1994434113} + - {fileID: 1092719079} + m_Father: {fileID: 1529148493} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1337964309 GameObject: m_ObjectHideFlags: 0 @@ -759,7 +870,6 @@ m_TargetEye: 3 m_HDR: 1 m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 m_ForceIntoRT: 0 m_OcclusionCulling: 1 m_StereoConvergence: 10 @@ -770,13 +880,13 @@ m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1337964309} - m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: -8.37} + m_LocalRotation: {x: 0.24914837, y: 0.36850542, z: -0.10320063, w: 0.8896508} + m_LocalPosition: {x: -7.46, y: 7.61, z: -7.45} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 1832090302} + m_Father: {fileID: 0} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_LocalEulerAnglesHint: {x: 31.29, y: 45, z: 0} --- !u!1 &1464748116 GameObject: m_ObjectHideFlags: 0 @@ -851,6 +961,36 @@ m_SpriteTileMode: 0 m_WasSpriteAssigned: 0 m_MaskInteraction: 0 +--- !u!1 &1519907060 +GameObject: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + serializedVersion: 5 + m_Component: + - component: {fileID: 1519907061} + m_Layer: 0 + m_Name: FenceHolder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1519907061 +Transform: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1519907060} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalPosition: {x: -0, y: 1.3, z: 0} + m_LocalScale: {x: 14.050603, y: 14.050598, z: 2.6934834} + m_Children: + - {fileID: 478953810} + - {fileID: 559179775} + m_Father: {fileID: 865854131} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} --- !u!1 &1529148492 GameObject: m_ObjectHideFlags: 0 @@ -873,87 +1013,71 @@ m_PrefabInternal: {fileID: 0} m_GameObject: {fileID: 1529148492} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0, y: -1.47, z: 10.369859} - m_LocalScale: {x: 1.2665029, y: 1.2665033, z: 1.2665033} + m_LocalPosition: {x: 0.42, y: -11.6, z: 0.41} + m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - - {fileID: 1777425977} - m_Father: {fileID: 1832090302} + - {fileID: 1307206125} + m_Father: {fileID: 890042692} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1772932288 +--- !u!1 &1994434112 GameObject: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} serializedVersion: 5 m_Component: - - component: {fileID: 1772932289} + - component: {fileID: 1994434113} + - component: {fileID: 1994434117} + - component: {fileID: 1994434116} + - component: {fileID: 1994434115} + - component: {fileID: 1994434114} m_Layer: 0 - m_Name: PGround + m_Name: Real m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!4 &1772932289 +--- !u!4 &1994434113 Transform: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1772932288} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_GameObject: {fileID: 1994434112} + m_LocalRotation: {x: 0.7071068, y: -0, z: -0, w: 0.7071068} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 277372079} - m_Father: {fileID: 257733089} + m_Children: [] + m_Father: {fileID: 1307206125} m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &1777425976 -GameObject: + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!114 &1994434114 +MonoBehaviour: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 1777425977} - - component: {fileID: 1777425978} - m_Layer: 0 - m_Name: GroundSprite - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1777425977 -Transform: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1777425976} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: -0, z: 7.66} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1118406555} - m_Father: {fileID: 1529148493} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!212 &1777425978 -SpriteRenderer: - m_ObjectHideFlags: 0 - m_PrefabParentObject: {fileID: 0} - m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1777425976} + m_GameObject: {fileID: 1994434112} m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 61cf17aa4290b4b4f8ec29804c6c1b37, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!23 &1994434115 +MeshRenderer: + m_ObjectHideFlags: 0 + m_PrefabParentObject: {fileID: 0} + m_PrefabInternal: {fileID: 0} + m_GameObject: {fileID: 1994434112} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 m_DynamicOccludee: 1 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + - {fileID: 2100000, guid: 3ac737af95c4a0c4d872141109506099, type: 2} m_StaticBatchInfo: firstSubMesh: 0 subMeshCount: 0 @@ -961,11 +1085,11 @@ m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 - m_PreserveUVs: 0 + m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 m_StitchLightmapSeams: 0 - m_SelectedEditorRenderState: 0 + m_SelectedEditorRenderState: 3 m_MinimumChartSize: 4 m_AutoUVMaxDistance: 0.5 m_AutoUVMaxAngle: 89 @@ -973,43 +1097,24 @@ m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 0} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 1, y: 1} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 0 - m_MaskInteraction: 0 ---- !u!1 &1832090301 -GameObject: +--- !u!64 &1994434116 +MeshCollider: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - serializedVersion: 5 - m_Component: - - component: {fileID: 1832090302} - m_Layer: 0 - m_Name: WorldPerspective - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1832090302 -Transform: + m_GameObject: {fileID: 1994434112} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Convex: 0 + m_InflateMesh: 0 + m_SkinWidth: 0.01 + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!33 &1994434117 +MeshFilter: m_ObjectHideFlags: 0 m_PrefabParentObject: {fileID: 0} m_PrefabInternal: {fileID: 0} - m_GameObject: {fileID: 1832090301} - m_LocalRotation: {x: 0.26967824, y: -0, z: -0, w: 0.9629505} - m_LocalPosition: {x: 0, y: 4.66, z: -6.68} - m_LocalScale: {x: 1, y: 1, z: 1} - m_Children: - - {fileID: 1337964313} - - {fileID: 1529148493} - m_Father: {fileID: 0} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 31.29, y: 0, z: 0} + m_GameObject: {fileID: 1994434112} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} diff --git a/FallUnity/ProjectSettings/DynamicsManager.asset b/FallUnity/ProjectSettings/DynamicsManager.asset index 219523f..4095a05 100755 --- a/FallUnity/ProjectSettings/DynamicsManager.asset +++ b/FallUnity/ProjectSettings/DynamicsManager.asset @@ -3,7 +3,7 @@ --- !u!55 &1 PhysicsManager: m_ObjectHideFlags: 0 - serializedVersion: 7 + serializedVersion: 3 m_Gravity: {x: 0, y: -2.55, z: 0} m_DefaultMaterial: {fileID: 0} m_BounceThreshold: 2 @@ -14,16 +14,7 @@ m_QueriesHitBackfaces: 0 m_QueriesHitTriggers: 1 m_EnableAdaptiveForce: 0 - m_ClothInterCollisionDistance: 0 - m_ClothInterCollisionStiffness: 0 - m_ContactsGeneration: 1 + m_EnablePCM: 1 m_LayerCollisionMatrix: fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffbffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff m_AutoSimulation: 1 m_AutoSyncTransforms: 1 - m_ClothInterCollisionSettingsToggle: 0 - m_ContactPairsMode: 0 - m_BroadphaseType: 0 - m_WorldBounds: - m_Center: {x: 0, y: 0, z: 0} - m_Extent: {x: 250, y: 250, z: 250} - m_WorldSubdivisions: 8 diff --git a/FallUnity/ProjectSettings/ProjectVersion.txt b/FallUnity/ProjectSettings/ProjectVersion.txt index a6a4bc5..7a6fffb 100755 --- a/FallUnity/ProjectSettings/ProjectVersion.txt +++ b/FallUnity/ProjectSettings/ProjectVersion.txt @@ -1 +1 @@ -m_EditorVersion: 2017.4.28f1 +m_EditorVersion: 2017.2.0f3