Working on entrance and building out first level
This commit is contained in:
6
.vscode/settings.json
vendored
6
.vscode/settings.json
vendored
@@ -60,11 +60,11 @@
|
|||||||
"*.asset": "yaml",
|
"*.asset": "yaml",
|
||||||
"*.meta": "yaml",
|
"*.meta": "yaml",
|
||||||
"*.prefab": "yaml",
|
"*.prefab": "yaml",
|
||||||
"*.unity": "yaml",
|
"*.unity": "yaml"
|
||||||
},
|
},
|
||||||
"explorer.fileNesting.enabled": true,
|
"explorer.fileNesting.enabled": true,
|
||||||
"explorer.fileNesting.patterns": {
|
"explorer.fileNesting.patterns": {
|
||||||
"*.sln": "*.csproj",
|
"*.sln": "*.csproj"
|
||||||
},
|
},
|
||||||
"dotnet.defaultSolution": "GameDevFPSTut.sln"
|
"dotnet.defaultSolution": "GameDevTVTutFPS.sln"
|
||||||
}
|
}
|
||||||
6
.vsconfig
Normal file
6
.vsconfig
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"version": "1.0",
|
||||||
|
"components": [
|
||||||
|
"Microsoft.VisualStudio.Workload.ManagedGame"
|
||||||
|
]
|
||||||
|
}
|
||||||
BIN
Assets/Audio/Decomtamination.wav
Normal file
BIN
Assets/Audio/Decomtamination.wav
Normal file
Binary file not shown.
23
Assets/Audio/Decomtamination.wav.meta
Normal file
23
Assets/Audio/Decomtamination.wav.meta
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 1d907cd769340e349afdcb33463eb1df
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 8
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Audio/Door.wav
Normal file
BIN
Assets/Audio/Door.wav
Normal file
Binary file not shown.
23
Assets/Audio/Door.wav.meta
Normal file
23
Assets/Audio/Door.wav.meta
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 452955d6d8984de419bf4f5048a924f7
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 8
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Audio/SciFiBeep HI055904.wav
Normal file
BIN
Assets/Audio/SciFiBeep HI055904.wav
Normal file
Binary file not shown.
23
Assets/Audio/SciFiBeep HI055904.wav.meta
Normal file
23
Assets/Audio/SciFiBeep HI055904.wav.meta
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: a3410d8c515970049a31ca834ee6de9c
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 8
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
BIN
Assets/Audio/SciFiDoor 9009_14_2.wav
Normal file
BIN
Assets/Audio/SciFiDoor 9009_14_2.wav
Normal file
Binary file not shown.
23
Assets/Audio/SciFiDoor 9009_14_2.wav.meta
Normal file
23
Assets/Audio/SciFiDoor 9009_14_2.wav.meta
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: aa85d73b6b1f9834881befd1c0803185
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 8
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
158
Assets/Prefabs/Decomtamination.prefab
Normal file
158
Assets/Prefabs/Decomtamination.prefab
Normal file
@@ -0,0 +1,158 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!1 &360830014190531102
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8522442310783664197}
|
||||||
|
- component: {fileID: 3704630250725710116}
|
||||||
|
- component: {fileID: 2184502132450182586}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Decomtamination
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &8522442310783664197
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 360830014190531102}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 15, y: 0, z: 17.31}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children:
|
||||||
|
- {fileID: 5258469180560843371}
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!65 &3704630250725710116
|
||||||
|
BoxCollider:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 360830014190531102}
|
||||||
|
m_Material: {fileID: 0}
|
||||||
|
m_IncludeLayers:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 0
|
||||||
|
m_ExcludeLayers:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 0
|
||||||
|
m_LayerOverridePriority: 0
|
||||||
|
m_IsTrigger: 1
|
||||||
|
m_ProvidesContacts: 0
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 3
|
||||||
|
m_Size: {x: 1.3874273, y: 3.4492884, z: 2.1730556}
|
||||||
|
m_Center: {x: 0.039767742, y: 1.2246442, z: 0.03311062}
|
||||||
|
--- !u!114 &2184502132450182586
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 360830014190531102}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: e19ca9f3a0e0c14489732f1886062ae3, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier: '::'
|
||||||
|
--- !u!1 &8627634658797475560
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 5258469180560843371}
|
||||||
|
- component: {fileID: 6528869020186403301}
|
||||||
|
- component: {fileID: 5445470542415194616}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SM_Prop_Decontamination_Shower_01
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &5258469180560843371
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8627634658797475560}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: -0, y: -0.70710677, z: -0, w: 0.7071068}
|
||||||
|
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 8522442310783664197}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: -90, z: 0}
|
||||||
|
--- !u!33 &6528869020186403301
|
||||||
|
MeshFilter:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8627634658797475560}
|
||||||
|
m_Mesh: {fileID: 4300000, guid: 329d60c9a0a31ac47ba5ffdc0b611849, type: 3}
|
||||||
|
--- !u!23 &5445470542415194616
|
||||||
|
MeshRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8627634658797475560}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_CastShadows: 1
|
||||||
|
m_ReceiveShadows: 1
|
||||||
|
m_DynamicOccludee: 1
|
||||||
|
m_StaticShadowCaster: 0
|
||||||
|
m_MotionVectors: 1
|
||||||
|
m_LightProbeUsage: 1
|
||||||
|
m_ReflectionProbeUsage: 1
|
||||||
|
m_RayTracingMode: 2
|
||||||
|
m_RayTraceProcedural: 0
|
||||||
|
m_RayTracingAccelStructBuildFlagsOverride: 0
|
||||||
|
m_RayTracingAccelStructBuildFlags: 1
|
||||||
|
m_SmallMeshCulling: 1
|
||||||
|
m_ForceMeshLod: -1
|
||||||
|
m_MeshLodSelectionBias: 0
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_RendererPriority: 0
|
||||||
|
m_Materials:
|
||||||
|
- {fileID: 2100000, guid: 4cee7a5983b187943adc589b9cb1f084, type: 2}
|
||||||
|
m_StaticBatchInfo:
|
||||||
|
firstSubMesh: 0
|
||||||
|
subMeshCount: 0
|
||||||
|
m_StaticBatchRoot: {fileID: 0}
|
||||||
|
m_ProbeAnchor: {fileID: 0}
|
||||||
|
m_LightProbeVolumeOverride: {fileID: 0}
|
||||||
|
m_ScaleInLightmap: 1
|
||||||
|
m_ReceiveGI: 1
|
||||||
|
m_PreserveUVs: 0
|
||||||
|
m_IgnoreNormalsForChartDetection: 0
|
||||||
|
m_ImportantGI: 0
|
||||||
|
m_StitchLightmapSeams: 1
|
||||||
|
m_SelectedEditorRenderState: 3
|
||||||
|
m_MinimumChartSize: 4
|
||||||
|
m_AutoUVMaxDistance: 0.5
|
||||||
|
m_AutoUVMaxAngle: 89
|
||||||
|
m_LightmapParameters: {fileID: 0}
|
||||||
|
m_GlobalIlluminationMeshLod: 0
|
||||||
|
m_SortingLayerID: 0
|
||||||
|
m_SortingLayer: 0
|
||||||
|
m_SortingOrder: 0
|
||||||
|
m_AdditionalVertexStreams: {fileID: 0}
|
||||||
7
Assets/Prefabs/Decomtamination.prefab.meta
Normal file
7
Assets/Prefabs/Decomtamination.prefab.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: da11efee78a8ee74981f7a9a1271add0
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
242
Assets/Prefabs/SM_Prop_Detail_Lights_01.prefab
Normal file
242
Assets/Prefabs/SM_Prop_Detail_Lights_01.prefab
Normal file
@@ -0,0 +1,242 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!1 &7032062725729706661
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 7633076689399055286}
|
||||||
|
- component: {fileID: 8073837119443643387}
|
||||||
|
- component: {fileID: 6822260463572930158}
|
||||||
|
- component: {fileID: 8694269266160341448}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SM_Prop_Detail_Lights_01
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &7633076689399055286
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7032062725729706661}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: -0.70710677, y: -0, z: -0, w: 0.7071068}
|
||||||
|
m_LocalPosition: {x: 2.67, y: 3.684, z: 24.015902}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children:
|
||||||
|
- {fileID: 1324537361551797027}
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0}
|
||||||
|
--- !u!33 &8073837119443643387
|
||||||
|
MeshFilter:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7032062725729706661}
|
||||||
|
m_Mesh: {fileID: 4300000, guid: f3b47e725abe95644aa7a98d298e245a, type: 3}
|
||||||
|
--- !u!23 &6822260463572930158
|
||||||
|
MeshRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7032062725729706661}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_CastShadows: 1
|
||||||
|
m_ReceiveShadows: 1
|
||||||
|
m_DynamicOccludee: 1
|
||||||
|
m_StaticShadowCaster: 0
|
||||||
|
m_MotionVectors: 1
|
||||||
|
m_LightProbeUsage: 1
|
||||||
|
m_ReflectionProbeUsage: 1
|
||||||
|
m_RayTracingMode: 2
|
||||||
|
m_RayTraceProcedural: 0
|
||||||
|
m_RayTracingAccelStructBuildFlagsOverride: 0
|
||||||
|
m_RayTracingAccelStructBuildFlags: 1
|
||||||
|
m_SmallMeshCulling: 1
|
||||||
|
m_ForceMeshLod: -1
|
||||||
|
m_MeshLodSelectionBias: 0
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_RendererPriority: 0
|
||||||
|
m_Materials:
|
||||||
|
- {fileID: 2100000, guid: 4cee7a5983b187943adc589b9cb1f084, type: 2}
|
||||||
|
m_StaticBatchInfo:
|
||||||
|
firstSubMesh: 0
|
||||||
|
subMeshCount: 0
|
||||||
|
m_StaticBatchRoot: {fileID: 0}
|
||||||
|
m_ProbeAnchor: {fileID: 0}
|
||||||
|
m_LightProbeVolumeOverride: {fileID: 0}
|
||||||
|
m_ScaleInLightmap: 1
|
||||||
|
m_ReceiveGI: 1
|
||||||
|
m_PreserveUVs: 0
|
||||||
|
m_IgnoreNormalsForChartDetection: 0
|
||||||
|
m_ImportantGI: 0
|
||||||
|
m_StitchLightmapSeams: 1
|
||||||
|
m_SelectedEditorRenderState: 3
|
||||||
|
m_MinimumChartSize: 4
|
||||||
|
m_AutoUVMaxDistance: 0.5
|
||||||
|
m_AutoUVMaxAngle: 89
|
||||||
|
m_LightmapParameters: {fileID: 0}
|
||||||
|
m_GlobalIlluminationMeshLod: 0
|
||||||
|
m_SortingLayerID: 0
|
||||||
|
m_SortingLayer: 0
|
||||||
|
m_SortingOrder: 0
|
||||||
|
m_AdditionalVertexStreams: {fileID: 0}
|
||||||
|
--- !u!64 &8694269266160341448
|
||||||
|
MeshCollider:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7032062725729706661}
|
||||||
|
m_Material: {fileID: 0}
|
||||||
|
m_IncludeLayers:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 0
|
||||||
|
m_ExcludeLayers:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 0
|
||||||
|
m_LayerOverridePriority: 0
|
||||||
|
m_IsTrigger: 0
|
||||||
|
m_ProvidesContacts: 0
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 5
|
||||||
|
m_Convex: 1
|
||||||
|
m_CookingOptions: 30
|
||||||
|
m_Mesh: {fileID: 43864876238455340, guid: b59d5d020b164fe4aba3241dbf2f85bd, type: 2}
|
||||||
|
--- !u!1 &7298016047210063765
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 1324537361551797027}
|
||||||
|
- component: {fileID: 3786643848024176463}
|
||||||
|
- component: {fileID: 8288247802611217926}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Spot Light
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &1324537361551797027
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7298016047210063765}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: -0.7071062, y: -0, z: -0, w: 0.7071074}
|
||||||
|
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 7633076689399055286}
|
||||||
|
m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0}
|
||||||
|
--- !u!108 &3786643848024176463
|
||||||
|
Light:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7298016047210063765}
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 11
|
||||||
|
m_Type: 0
|
||||||
|
m_Color: {r: 0.15619439, g: 0.8490566, b: 0.7980176, a: 1}
|
||||||
|
m_Intensity: 1
|
||||||
|
m_Range: 5
|
||||||
|
m_SpotAngle: 115.05137
|
||||||
|
m_InnerSpotAngle: 21.80208
|
||||||
|
m_CookieSize: 10
|
||||||
|
m_Shadows:
|
||||||
|
m_Type: 0
|
||||||
|
m_Resolution: -1
|
||||||
|
m_CustomResolution: -1
|
||||||
|
m_Strength: 1
|
||||||
|
m_Bias: 0.05
|
||||||
|
m_NormalBias: 0.4
|
||||||
|
m_NearPlane: 0.2
|
||||||
|
m_CullingMatrixOverride:
|
||||||
|
e00: 1
|
||||||
|
e01: 0
|
||||||
|
e02: 0
|
||||||
|
e03: 0
|
||||||
|
e10: 0
|
||||||
|
e11: 1
|
||||||
|
e12: 0
|
||||||
|
e13: 0
|
||||||
|
e20: 0
|
||||||
|
e21: 0
|
||||||
|
e22: 1
|
||||||
|
e23: 0
|
||||||
|
e30: 0
|
||||||
|
e31: 0
|
||||||
|
e32: 0
|
||||||
|
e33: 1
|
||||||
|
m_UseCullingMatrixOverride: 0
|
||||||
|
m_Cookie: {fileID: 0}
|
||||||
|
m_DrawHalo: 0
|
||||||
|
m_Flare: {fileID: 0}
|
||||||
|
m_RenderMode: 0
|
||||||
|
m_CullingMask:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 4294967295
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_Lightmapping: 4
|
||||||
|
m_LightShadowCasterMode: 0
|
||||||
|
m_AreaSize: {x: 1, y: 1}
|
||||||
|
m_BounceIntensity: 1
|
||||||
|
m_ColorTemperature: 6570
|
||||||
|
m_UseColorTemperature: 0
|
||||||
|
m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_UseBoundingSphereOverride: 0
|
||||||
|
m_UseViewFrustumForShadowCasterCull: 1
|
||||||
|
m_ForceVisible: 0
|
||||||
|
m_ShadowRadius: 0
|
||||||
|
m_ShadowAngle: 0
|
||||||
|
m_LightUnit: 1
|
||||||
|
m_LuxAtDistance: 1
|
||||||
|
m_EnableSpotReflector: 1
|
||||||
|
--- !u!114 &8288247802611217926
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 7298016047210063765}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 474bcb49853aa07438625e644c072ee6, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier: Unity.RenderPipelines.Universal.Runtime::UnityEngine.Rendering.Universal.UniversalAdditionalLightData
|
||||||
|
m_UsePipelineSettings: 1
|
||||||
|
m_AdditionalLightsShadowResolutionTier: 2
|
||||||
|
m_CustomShadowLayers: 0
|
||||||
|
m_LightCookieSize: {x: 1, y: 1}
|
||||||
|
m_LightCookieOffset: {x: 0, y: 0}
|
||||||
|
m_SoftShadowQuality: 0
|
||||||
|
m_RenderingLayersMask:
|
||||||
|
serializedVersion: 0
|
||||||
|
m_Bits: 1
|
||||||
|
m_ShadowRenderingLayersMask:
|
||||||
|
serializedVersion: 0
|
||||||
|
m_Bits: 1
|
||||||
|
m_Version: 4
|
||||||
|
m_LightLayerMask: 1
|
||||||
|
m_ShadowLayerMask: 1
|
||||||
|
m_RenderingLayers: 1
|
||||||
|
m_ShadowRenderingLayers: 1
|
||||||
7
Assets/Prefabs/SM_Prop_Detail_Lights_01.prefab.meta
Normal file
7
Assets/Prefabs/SM_Prop_Detail_Lights_01.prefab.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 2168932a847c18541bb3ce0e1a8180bd
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
126
Assets/Prefabs/Trigger.prefab
Normal file
126
Assets/Prefabs/Trigger.prefab
Normal file
@@ -0,0 +1,126 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!1 &8630574106199248916
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8178282882139130390}
|
||||||
|
- component: {fileID: 3907290757713635997}
|
||||||
|
- component: {fileID: 432648033353398004}
|
||||||
|
- component: {fileID: 7595779130050972589}
|
||||||
|
- component: {fileID: 7607949240724942102}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Trigger
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &8178282882139130390
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8630574106199248916}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
|
m_LocalPosition: {x: 12.486, y: 0.03, z: 16.88}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!33 &3907290757713635997
|
||||||
|
MeshFilter:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8630574106199248916}
|
||||||
|
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
|
||||||
|
--- !u!23 &432648033353398004
|
||||||
|
MeshRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8630574106199248916}
|
||||||
|
m_Enabled: 0
|
||||||
|
m_CastShadows: 1
|
||||||
|
m_ReceiveShadows: 1
|
||||||
|
m_DynamicOccludee: 1
|
||||||
|
m_StaticShadowCaster: 0
|
||||||
|
m_MotionVectors: 1
|
||||||
|
m_LightProbeUsage: 1
|
||||||
|
m_ReflectionProbeUsage: 1
|
||||||
|
m_RayTracingMode: 2
|
||||||
|
m_RayTraceProcedural: 0
|
||||||
|
m_RayTracingAccelStructBuildFlagsOverride: 0
|
||||||
|
m_RayTracingAccelStructBuildFlags: 1
|
||||||
|
m_SmallMeshCulling: 1
|
||||||
|
m_ForceMeshLod: -1
|
||||||
|
m_MeshLodSelectionBias: 0
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_RendererPriority: 0
|
||||||
|
m_Materials:
|
||||||
|
- {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, type: 2}
|
||||||
|
m_StaticBatchInfo:
|
||||||
|
firstSubMesh: 0
|
||||||
|
subMeshCount: 0
|
||||||
|
m_StaticBatchRoot: {fileID: 0}
|
||||||
|
m_ProbeAnchor: {fileID: 0}
|
||||||
|
m_LightProbeVolumeOverride: {fileID: 0}
|
||||||
|
m_ScaleInLightmap: 1
|
||||||
|
m_ReceiveGI: 1
|
||||||
|
m_PreserveUVs: 0
|
||||||
|
m_IgnoreNormalsForChartDetection: 0
|
||||||
|
m_ImportantGI: 0
|
||||||
|
m_StitchLightmapSeams: 1
|
||||||
|
m_SelectedEditorRenderState: 3
|
||||||
|
m_MinimumChartSize: 4
|
||||||
|
m_AutoUVMaxDistance: 0.5
|
||||||
|
m_AutoUVMaxAngle: 89
|
||||||
|
m_LightmapParameters: {fileID: 0}
|
||||||
|
m_GlobalIlluminationMeshLod: 0
|
||||||
|
m_SortingLayerID: 0
|
||||||
|
m_SortingLayer: 0
|
||||||
|
m_SortingOrder: 0
|
||||||
|
m_AdditionalVertexStreams: {fileID: 0}
|
||||||
|
--- !u!65 &7595779130050972589
|
||||||
|
BoxCollider:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8630574106199248916}
|
||||||
|
m_Material: {fileID: 0}
|
||||||
|
m_IncludeLayers:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 0
|
||||||
|
m_ExcludeLayers:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 0
|
||||||
|
m_LayerOverridePriority: 0
|
||||||
|
m_IsTrigger: 0
|
||||||
|
m_ProvidesContacts: 0
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 3
|
||||||
|
m_Size: {x: 1.931839, y: 0.54449725, z: 3.100438}
|
||||||
|
m_Center: {x: -0.4659195, y: -0.22775137, z: 0.124867916}
|
||||||
|
--- !u!114 &7607949240724942102
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8630574106199248916}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 5060b3e8fb6da8f41a3da4eaa47ba624, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier: Assembly-CSharp::BaseTrigger
|
||||||
7
Assets/Prefabs/Trigger.prefab.meta
Normal file
7
Assets/Prefabs/Trigger.prefab.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: d88fc97cde3497440a1158e18c3940da
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,143 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: f164ca12fad0bf74e91e0dbdaccce487
|
|
||||||
TextureImporter:
|
|
||||||
internalIDToNameTable: []
|
|
||||||
externalObjects: {}
|
|
||||||
serializedVersion: 13
|
|
||||||
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
|
|
||||||
flipGreenChannel: 0
|
|
||||||
isReadable: 0
|
|
||||||
streamingMipmaps: 0
|
|
||||||
streamingMipmapsPriority: 0
|
|
||||||
vTOnly: 0
|
|
||||||
ignoreMipmapLimit: 0
|
|
||||||
grayScaleToAlpha: 0
|
|
||||||
generateCubemap: 6
|
|
||||||
cubemapConvolution: 1
|
|
||||||
seamlessCubemap: 1
|
|
||||||
textureFormat: 1
|
|
||||||
maxTextureSize: 2048
|
|
||||||
textureSettings:
|
|
||||||
serializedVersion: 2
|
|
||||||
filterMode: 2
|
|
||||||
aniso: 0
|
|
||||||
mipBias: 0
|
|
||||||
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}
|
|
||||||
spritePixelsToUnits: 100
|
|
||||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
|
||||||
spriteGenerateFallbackPhysicsShape: 1
|
|
||||||
alphaUsage: 1
|
|
||||||
alphaIsTransparency: 0
|
|
||||||
spriteTessellationDetail: -1
|
|
||||||
textureType: 0
|
|
||||||
textureShape: 2
|
|
||||||
singleChannelComponent: 0
|
|
||||||
flipbookRows: 1
|
|
||||||
flipbookColumns: 1
|
|
||||||
maxTextureSizeSet: 0
|
|
||||||
compressionQualitySet: 0
|
|
||||||
textureFormatSet: 0
|
|
||||||
ignorePngGamma: 0
|
|
||||||
applyGammaDecoding: 0
|
|
||||||
swizzle: 50462976
|
|
||||||
cookieLightType: 0
|
|
||||||
platformSettings:
|
|
||||||
- serializedVersion: 4
|
|
||||||
buildTarget: DefaultTexturePlatform
|
|
||||||
maxTextureSize: 2048
|
|
||||||
resizeAlgorithm: 0
|
|
||||||
textureFormat: -1
|
|
||||||
textureCompression: 1
|
|
||||||
compressionQuality: 100
|
|
||||||
crunchedCompression: 0
|
|
||||||
allowsAlphaSplitting: 0
|
|
||||||
overridden: 0
|
|
||||||
ignorePlatformSupport: 0
|
|
||||||
androidETC2FallbackOverride: 0
|
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
|
||||||
- serializedVersion: 4
|
|
||||||
buildTarget: Standalone
|
|
||||||
maxTextureSize: 2048
|
|
||||||
resizeAlgorithm: 0
|
|
||||||
textureFormat: -1
|
|
||||||
textureCompression: 1
|
|
||||||
compressionQuality: 50
|
|
||||||
crunchedCompression: 0
|
|
||||||
allowsAlphaSplitting: 0
|
|
||||||
overridden: 0
|
|
||||||
ignorePlatformSupport: 0
|
|
||||||
androidETC2FallbackOverride: 0
|
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
|
||||||
- serializedVersion: 4
|
|
||||||
buildTarget: WebGL
|
|
||||||
maxTextureSize: 2048
|
|
||||||
resizeAlgorithm: 0
|
|
||||||
textureFormat: -1
|
|
||||||
textureCompression: 1
|
|
||||||
compressionQuality: 50
|
|
||||||
crunchedCompression: 0
|
|
||||||
allowsAlphaSplitting: 0
|
|
||||||
overridden: 0
|
|
||||||
ignorePlatformSupport: 0
|
|
||||||
androidETC2FallbackOverride: 0
|
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
|
||||||
- serializedVersion: 4
|
|
||||||
buildTarget: WindowsStoreApps
|
|
||||||
maxTextureSize: 2048
|
|
||||||
resizeAlgorithm: 0
|
|
||||||
textureFormat: -1
|
|
||||||
textureCompression: 1
|
|
||||||
compressionQuality: 50
|
|
||||||
crunchedCompression: 0
|
|
||||||
allowsAlphaSplitting: 0
|
|
||||||
overridden: 0
|
|
||||||
ignorePlatformSupport: 0
|
|
||||||
androidETC2FallbackOverride: 0
|
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
|
||||||
spriteSheet:
|
|
||||||
serializedVersion: 2
|
|
||||||
sprites: []
|
|
||||||
outline: []
|
|
||||||
customData:
|
|
||||||
physicsShape: []
|
|
||||||
bones: []
|
|
||||||
spriteID:
|
|
||||||
internalID: 0
|
|
||||||
vertices: []
|
|
||||||
indices:
|
|
||||||
edges: []
|
|
||||||
weights: []
|
|
||||||
secondaryTextures: []
|
|
||||||
spriteCustomMetadata:
|
|
||||||
entries: []
|
|
||||||
nameFileIdTable: {}
|
|
||||||
mipmapLimitGroupName:
|
|
||||||
pSDRemoveMatte: 0
|
|
||||||
userData:
|
|
||||||
assetBundleName:
|
|
||||||
assetBundleVariant:
|
|
||||||
31
Assets/Scripts/Decomtamination.cs
Normal file
31
Assets/Scripts/Decomtamination.cs
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using StarterAssets;
|
||||||
|
using System.Collections;
|
||||||
|
using UnityEngine.UIElements;
|
||||||
|
|
||||||
|
public class Decomtamination : MonoBehaviour
|
||||||
|
{
|
||||||
|
[SerializeField] GameObject decomtaminationChamberDoor;
|
||||||
|
StarterAssetsInputs inputs;
|
||||||
|
Log log;
|
||||||
|
void Awake()
|
||||||
|
{
|
||||||
|
inputs = FindFirstObjectByType<StarterAssetsInputs>();
|
||||||
|
log = FindFirstObjectByType<Log>();
|
||||||
|
}
|
||||||
|
void OnTriggerEnter(Collider other)
|
||||||
|
{
|
||||||
|
if (other.CompareTag("Player"))
|
||||||
|
{
|
||||||
|
Decomtaminating();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
void Decomtaminating()
|
||||||
|
{
|
||||||
|
Debug.Log("Decomtaminating");
|
||||||
|
StartCoroutine(inputs.ToggleInput(5f));
|
||||||
|
log.WriteOutLog("You have entered the decomtamination chamber. Please wait while we process your decontamination...", 0.05f);
|
||||||
|
decomtaminationChamberDoor.GetComponent<Door>().UnlockDoor();
|
||||||
|
GetComponent<BoxCollider>().enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
2
Assets/Scripts/Decomtamination.cs.meta
Normal file
2
Assets/Scripts/Decomtamination.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e19ca9f3a0e0c14489732f1886062ae3
|
||||||
@@ -4,27 +4,14 @@ using UnityEngine.Rendering;
|
|||||||
|
|
||||||
public class Door : MonoBehaviour, IInteractable
|
public class Door : MonoBehaviour, IInteractable
|
||||||
{
|
{
|
||||||
[SerializeField] bool autoDoor;
|
|
||||||
[SerializeField] bool locked;
|
|
||||||
[SerializeField] bool isOpen;
|
|
||||||
[SerializeField] GameObject door;
|
[SerializeField] GameObject door;
|
||||||
[SerializeField] float openHeight = 3f;
|
[SerializeField] float openHeight = 3f;
|
||||||
[SerializeField] float openTime = 2f;
|
[SerializeField] float openTime = 2f;
|
||||||
void Awake()
|
[SerializeField] AudioClip audioClip;
|
||||||
{
|
[SerializeField] bool autoDoor;
|
||||||
|
[SerializeField] bool locked;
|
||||||
}
|
[SerializeField] bool isOpen;
|
||||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
[SerializeField] bool singleUse;
|
||||||
void Start()
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update is called once per frame
|
|
||||||
void Update()
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
void OnTriggerEnter(Collider other)
|
void OnTriggerEnter(Collider other)
|
||||||
{
|
{
|
||||||
if(other.CompareTag("Player") && autoDoor && !locked && !isOpen)
|
if(other.CompareTag("Player") && autoDoor && !locked && !isOpen)
|
||||||
@@ -45,14 +32,24 @@ public class Door : MonoBehaviour, IInteractable
|
|||||||
isOpen = false;
|
isOpen = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
void OpenDoor(float height)
|
public void OpenDoor(float height)
|
||||||
{
|
{
|
||||||
door.transform.Translate(0f,-height,0f);
|
door.transform.Translate(0f,-height,0f);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CloseDoor(float height)
|
public void CloseDoor(float height)
|
||||||
{
|
{
|
||||||
door.transform.Translate(0f,height,0f);
|
door.transform.Translate(0f,height,0f);
|
||||||
|
if(singleUse)
|
||||||
|
locked = true;
|
||||||
|
}
|
||||||
|
public void LockDoor()
|
||||||
|
{
|
||||||
|
locked = true;
|
||||||
|
}
|
||||||
|
public void UnlockDoor()
|
||||||
|
{
|
||||||
|
locked = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Interact(GameObject interactor)
|
public void Interact(GameObject interactor)
|
||||||
@@ -89,7 +86,10 @@ public string GetInteractionPrompt()
|
|||||||
{
|
{
|
||||||
if (locked)
|
if (locked)
|
||||||
return "Door is locked";
|
return "Door is locked";
|
||||||
|
if(autoDoor)
|
||||||
|
return "";
|
||||||
return isOpen ? "Press [E] to close door" : "Press [E] to open door";
|
return isOpen ? "Press [E] to close door" : "Press [E] to open door";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void OnHighlight()
|
public void OnHighlight()
|
||||||
|
|||||||
34
Assets/Scripts/Log.cs
Normal file
34
Assets/Scripts/Log.cs
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using System.Collections;
|
||||||
|
using TMPro;
|
||||||
|
|
||||||
|
public class Log : MonoBehaviour
|
||||||
|
{
|
||||||
|
TextMeshProUGUI tmpText;
|
||||||
|
void Awake()
|
||||||
|
{
|
||||||
|
tmpText = GetComponent<TextMeshProUGUI>();
|
||||||
|
}
|
||||||
|
void Start()
|
||||||
|
{
|
||||||
|
tmpText.text = "";
|
||||||
|
tmpText.enabled = false;
|
||||||
|
}
|
||||||
|
public void WriteOutLog(string text, float letterDelay = 0.05f)
|
||||||
|
{
|
||||||
|
StartCoroutine(WriteLog(text, letterDelay));
|
||||||
|
}
|
||||||
|
|
||||||
|
IEnumerator WriteLog(string text, float letterDelay)
|
||||||
|
{
|
||||||
|
tmpText.text = "";
|
||||||
|
tmpText.enabled = true;
|
||||||
|
|
||||||
|
foreach (char letter in text)
|
||||||
|
{
|
||||||
|
tmpText.text += letter;
|
||||||
|
yield return new WaitForSeconds(letterDelay);
|
||||||
|
}
|
||||||
|
tmpText.enabled = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
2
Assets/Scripts/Log.cs.meta
Normal file
2
Assets/Scripts/Log.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 0aff546340c1fed46aca390d6645058b
|
||||||
8
Assets/Scripts/Triggers.meta
Normal file
8
Assets/Scripts/Triggers.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: fbdb5b73c909d1e45a27aac0a316583d
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
9
Assets/Scripts/Triggers/EntranceTrigger.cs
Normal file
9
Assets/Scripts/Triggers/EntranceTrigger.cs
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class WelcomeTrigger : BaseTrigger
|
||||||
|
{
|
||||||
|
protected override void OnPlayerEnter()
|
||||||
|
{
|
||||||
|
log.WriteOutLog("Welcome to my spaceship engineer, we are currently undergoing some maintance so please allow my robots some leeway", 0.05f);
|
||||||
|
}
|
||||||
|
}
|
||||||
2
Assets/Scripts/Triggers/EntranceTrigger.cs.meta
Normal file
2
Assets/Scripts/Triggers/EntranceTrigger.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 298f124a3fdf91f41b692cf145cb29cd
|
||||||
24
Assets/Scripts/Triggers/Trigger.cs
Normal file
24
Assets/Scripts/Triggers/Trigger.cs
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class BaseTrigger : MonoBehaviour
|
||||||
|
{
|
||||||
|
protected Log log;
|
||||||
|
|
||||||
|
protected virtual void Awake()
|
||||||
|
{
|
||||||
|
log = FindFirstObjectByType<Log>();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected virtual void OnTriggerEnter(Collider other)
|
||||||
|
{
|
||||||
|
if (other.CompareTag("Player"))
|
||||||
|
{
|
||||||
|
OnPlayerEnter();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Override this in subclasses
|
||||||
|
protected virtual void OnPlayerEnter()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
2
Assets/Scripts/Triggers/Trigger.cs.meta
Normal file
2
Assets/Scripts/Triggers/Trigger.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5060b3e8fb6da8f41a3da4eaa47ba624
|
||||||
@@ -106,7 +106,7 @@ Transform:
|
|||||||
m_GameObject: {fileID: 4135013735270702863}
|
m_GameObject: {fileID: 4135013735270702863}
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
m_LocalPosition: {x: 0, y: 1.375, z: 0}
|
m_LocalPosition: {x: 0, y: 1.5, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
@@ -294,6 +294,7 @@ GameObject:
|
|||||||
- component: {fileID: 8616685848737228371}
|
- component: {fileID: 8616685848737228371}
|
||||||
- component: {fileID: 1978471637655604388}
|
- component: {fileID: 1978471637655604388}
|
||||||
- component: {fileID: 5420857361349278248}
|
- component: {fileID: 5420857361349278248}
|
||||||
|
- component: {fileID: 115016143636925697}
|
||||||
- component: {fileID: 8616685848737228376}
|
- component: {fileID: 8616685848737228376}
|
||||||
m_Layer: 3
|
m_Layer: 3
|
||||||
m_Name: PlayerCapsule
|
m_Name: PlayerCapsule
|
||||||
@@ -407,9 +408,24 @@ MonoBehaviour:
|
|||||||
jump: 0
|
jump: 0
|
||||||
sprint: 0
|
sprint: 0
|
||||||
shoot: 0
|
shoot: 0
|
||||||
|
interact: 0
|
||||||
analogMovement: 0
|
analogMovement: 0
|
||||||
cursorLocked: 1
|
cursorLocked: 1
|
||||||
cursorInputForLook: 1
|
cursorInputForLook: 1
|
||||||
|
--- !u!114 &115016143636925697
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8616685848737228372}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 105f4b8125b2dd54a98fcaf3b8eee146, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier: Assembly-CSharp::Interaction
|
||||||
|
interactionPrompt: {fileID: 0}
|
||||||
|
interactRange: 2
|
||||||
--- !u!114 &8616685848737228376
|
--- !u!114 &8616685848737228376
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
using System.Collections;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
#if ENABLE_INPUT_SYSTEM
|
#if ENABLE_INPUT_SYSTEM
|
||||||
using UnityEngine.InputSystem;
|
using UnityEngine.InputSystem;
|
||||||
@@ -22,15 +23,18 @@ namespace StarterAssets
|
|||||||
public bool cursorLocked = true;
|
public bool cursorLocked = true;
|
||||||
public bool cursorInputForLook = true;
|
public bool cursorInputForLook = true;
|
||||||
|
|
||||||
|
public bool inputEnabled = true;
|
||||||
|
|
||||||
#if ENABLE_INPUT_SYSTEM
|
#if ENABLE_INPUT_SYSTEM
|
||||||
public void OnMove(InputValue value)
|
public void OnMove(InputValue value)
|
||||||
{
|
{
|
||||||
|
if(inputEnabled)
|
||||||
MoveInput(value.Get<Vector2>());
|
MoveInput(value.Get<Vector2>());
|
||||||
}
|
}
|
||||||
|
|
||||||
public void OnLook(InputValue value)
|
public void OnLook(InputValue value)
|
||||||
{
|
{
|
||||||
if(cursorInputForLook)
|
if(cursorInputForLook && inputEnabled)
|
||||||
{
|
{
|
||||||
LookInput(value.Get<Vector2>());
|
LookInput(value.Get<Vector2>());
|
||||||
}
|
}
|
||||||
@@ -38,19 +42,23 @@ namespace StarterAssets
|
|||||||
|
|
||||||
public void OnJump(InputValue value)
|
public void OnJump(InputValue value)
|
||||||
{
|
{
|
||||||
|
if(inputEnabled)
|
||||||
JumpInput(value.isPressed);
|
JumpInput(value.isPressed);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void OnSprint(InputValue value)
|
public void OnSprint(InputValue value)
|
||||||
{
|
{
|
||||||
|
if(inputEnabled)
|
||||||
SprintInput(value.isPressed);
|
SprintInput(value.isPressed);
|
||||||
}
|
}
|
||||||
public void OnShoot(InputValue value)
|
public void OnShoot(InputValue value)
|
||||||
{
|
{
|
||||||
|
if(inputEnabled)
|
||||||
ShootInput(value.isPressed);
|
ShootInput(value.isPressed);
|
||||||
}
|
}
|
||||||
public void OnInteract(InputValue value)
|
public void OnInteract(InputValue value)
|
||||||
{
|
{
|
||||||
|
if(inputEnabled)
|
||||||
InteractInput(value.isPressed);
|
InteractInput(value.isPressed);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -93,6 +101,23 @@ namespace StarterAssets
|
|||||||
{
|
{
|
||||||
Cursor.lockState = newState ? CursorLockMode.Locked : CursorLockMode.None;
|
Cursor.lockState = newState ? CursorLockMode.Locked : CursorLockMode.None;
|
||||||
}
|
}
|
||||||
|
public void EnableInput()
|
||||||
|
{
|
||||||
|
inputEnabled = true;
|
||||||
|
}
|
||||||
|
public void DisableInput()
|
||||||
|
{
|
||||||
|
inputEnabled = false;
|
||||||
|
}
|
||||||
|
public IEnumerator ToggleInput(float delay)
|
||||||
|
{
|
||||||
|
inputEnabled = false; // Disable immediately
|
||||||
|
move = Vector2.zero;
|
||||||
|
look = Vector2.zero;
|
||||||
|
GetComponents<CharacterController>()[0].Move(Vector3.zero); // Prevents character from sliding
|
||||||
|
yield return new WaitForSeconds(delay);
|
||||||
|
inputEnabled = true; // Re-enable after delay
|
||||||
|
yield return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user