doors now close when the player dies, changes in main to make it work

This commit is contained in:
Novvator 2021-04-21 16:42:11 +01:00
parent ebff7d05eb
commit 71a3b48a78
9 changed files with 554 additions and 218 deletions

View File

@ -1,5 +1,31 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1102 &-6953445788389773886
AnimatorState:
serializedVersion: 6
m_ObjectHideFlags: 1
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: DoorDown
m_Speed: 1
m_CycleOffset: 0
m_Transitions: []
m_StateMachineBehaviours: []
m_Position: {x: 50, y: 50, z: 0}
m_IKOnFeet: 0
m_WriteDefaultValues: 1
m_Mirror: 0
m_SpeedParameterActive: 0
m_MirrorParameterActive: 0
m_CycleOffsetParameterActive: 0
m_TimeParameterActive: 0
m_Motion: {fileID: 7400000, guid: 5be60d4f4b410d34080dbc6a64281f57, type: 2}
m_Tag:
m_SpeedParameter:
m_MirrorParameter:
m_CycleOffsetParameter:
m_TimeParameter:
--- !u!1102 &-5507418607302417577
AnimatorState:
serializedVersion: 6
@ -89,6 +115,9 @@ AnimatorStateMachine:
- serializedVersion: 1
m_State: {fileID: -5507418607302417577}
m_Position: {x: 260, y: 100, z: 0}
- serializedVersion: 1
m_State: {fileID: -6953445788389773886}
m_Position: {x: 295, y: 165, z: 0}
m_ChildStateMachines: []
m_AnyStateTransitions: []
m_EntryTransitions: []

View File

@ -0,0 +1,169 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!74 &7400000
AnimationClip:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: DoorDown
serializedVersion: 6
m_Legacy: 0
m_Compressed: 0
m_UseHighQualityCurve: 1
m_RotationCurves: []
m_CompressedRotationCurves: []
m_EulerCurves: []
m_PositionCurves:
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: {x: 0, y: 4.5, z: 0}
inSlope: {x: 0, y: 0, z: 0}
outSlope: {x: 0, y: 0, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
- serializedVersion: 3
time: 2
value: {x: 0, y: 1.5, z: 0}
inSlope: {x: 0, y: 0, z: 0}
outSlope: {x: 0, y: 0, z: 0}
tangentMode: 0
weightedMode: 0
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
path:
m_ScaleCurves: []
m_FloatCurves: []
m_PPtrCurves: []
m_SampleRate: 60
m_WrapMode: 0
m_Bounds:
m_Center: {x: 0, y: 0, z: 0}
m_Extent: {x: 0, y: 0, z: 0}
m_ClipBindingConstant:
genericBindings:
- serializedVersion: 2
path: 0
attribute: 1
script: {fileID: 0}
typeID: 4
customType: 0
isPPtrCurve: 0
pptrCurveMapping: []
m_AnimationClipSettings:
serializedVersion: 2
m_AdditiveReferencePoseClip: {fileID: 0}
m_AdditiveReferencePoseTime: 0
m_StartTime: 0
m_StopTime: 2
m_OrientationOffsetY: 0
m_Level: 0
m_CycleOffset: 0
m_HasAdditiveReferencePose: 0
m_LoopTime: 0
m_LoopBlend: 0
m_LoopBlendOrientation: 0
m_LoopBlendPositionY: 0
m_LoopBlendPositionXZ: 0
m_KeepOriginalOrientation: 0
m_KeepOriginalPositionY: 1
m_KeepOriginalPositionXZ: 0
m_HeightFromFeet: 0
m_Mirror: 0
m_EditorCurves:
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 2
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
attribute: m_LocalPosition.x
path:
classID: 4
script: {fileID: 0}
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 4.5
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 2
value: 1.5
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
attribute: m_LocalPosition.y
path:
classID: 4
script: {fileID: 0}
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 2
value: 0
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
attribute: m_LocalPosition.z
path:
classID: 4
script: {fileID: 0}
m_EulerEditorCurves: []
m_HasGenericRootTransform: 1
m_HasMotionFloatCurves: 0
m_Events: []

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5be60d4f4b410d34080dbc6a64281f57
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 7400000
userData:
assetBundleName:
assetBundleVariant:

View File

@ -14,7 +14,7 @@ GameObject:
- component: {fileID: 3376821640706513195}
- component: {fileID: 7076099413930353623}
m_Layer: 0
m_Name: Door
m_Name: Graphics
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -125,8 +125,9 @@ GameObject:
m_Component:
- component: {fileID: 889410586990417773}
- component: {fileID: 8044731510911618503}
- component: {fileID: 2033609833314563782}
m_Layer: 0
m_Name: DoorParent
m_Name: Door
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
@ -160,3 +161,32 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
_animator: {fileID: 7076099413930353623}
_opened: 0
--- !u!114 &2033609833314563782
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7857540940252484938}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 0a5de09a27d949d4db67034f55c57e6b, type: 3}
m_Name:
m_EditorClassIdentifier:
_event: {fileID: 11400000, guid: 22fd384aef0d08146831d35c2ab7f983, type: 2}
_response:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 8044731510911618503}
m_TargetAssemblyTypeName: Door, Assembly-CSharp
m_MethodName: Close
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2

View File

@ -15,6 +15,7 @@ GameObject:
- component: {fileID: 2008516910213964938}
- component: {fileID: 5530170563008613136}
- component: {fileID: 8033591221754439421}
- component: {fileID: 453378280238780630}
m_Layer: 0
m_Name: Plate
m_TagString: Untagged
@ -127,7 +128,19 @@ MonoBehaviour:
pPlateAnim: {fileID: 8033591221754439421}
_onPress:
m_PersistentCalls:
m_Calls: []
m_Calls:
- m_Target: {fileID: 0}
m_TargetAssemblyTypeName:
m_MethodName:
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName:
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
--- !u!95 &8033591221754439421
Animator:
serializedVersion: 3
@ -147,6 +160,34 @@ Animator:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorControllerStateOnDisable: 0
--- !u!114 &453378280238780630
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 172610034636199716}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 0a5de09a27d949d4db67034f55c57e6b, type: 3}
m_Name:
m_EditorClassIdentifier:
_event: {fileID: 11400000, guid: 22fd384aef0d08146831d35c2ab7f983, type: 2}
_response:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 5530170563008613136}
m_TargetAssemblyTypeName: PressurePlate, Assembly-CSharp
m_MethodName: plateUp
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
--- !u!1 &8036033890208197765
GameObject:
m_ObjectHideFlags: 0

View File

@ -281,6 +281,17 @@ Transform:
m_CorrespondingSourceObject: {fileID: -8679921383154817045, guid: ef7a51de2c5c5c5438ce6fea733533b2, type: 3}
m_PrefabInstance: {fileID: 3060674079568809208}
m_PrefabAsset: {fileID: 0}
--- !u!114 &64137470 stripped
MonoBehaviour:
m_CorrespondingSourceObject: {fileID: 7737479256821795591, guid: 2d949926f63a2554584336b07085202b, type: 3}
m_PrefabInstance: {fileID: 5633276111010996303}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c79d6b66286a2ac41b41321a95dfcc00, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!4 &68350320 stripped
Transform:
m_CorrespondingSourceObject: {fileID: -8679921383154817045, guid: e20114b5c13a067488940c5cc8e13b60, type: 3}
@ -1308,219 +1319,6 @@ Transform:
m_CorrespondingSourceObject: {fileID: -8679921383154817045, guid: e20114b5c13a067488940c5cc8e13b60, type: 3}
m_PrefabInstance: {fileID: 3060674079097563415}
m_PrefabAsset: {fileID: 0}
--- !u!1001 &359481387
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.028300352
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.0010792735
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: -0.91045475
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0.41263804
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: -0.039340973
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0.2522471
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: -2.719612
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.9719741
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.22945215
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: 0.04979975
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: -0.011756136
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007564, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_Name
value: PlayerObjects
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_RootOrder
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: -25.67
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0.35
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: 83.71
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831598614294, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: _cheatBlink
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831598614294, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: _cheatBoost
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831598614294, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: _cheatFreeze
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.028300386
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.0010792749
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: -0.91045475
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0.41263804
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: -0.039340973
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0.2522471
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: -2.719612
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.018142022
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.0035588439
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: 0.9811299
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: -0.19246408
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.06957282
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.0026532556
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: -0.90860987
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0.41180193
objectReference: {fileID: 0}
- target: {fileID: 9122906920607805875, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_Enabled
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
--- !u!4 &359635900 stripped
Transform:
m_CorrespondingSourceObject: {fileID: -8679921383154817045, guid: e20114b5c13a067488940c5cc8e13b60, type: 3}
@ -1998,6 +1796,151 @@ Transform:
m_CorrespondingSourceObject: {fileID: 3340651998927408397, guid: e182e6daf2f187b45a07e7c89e3f1b55, type: 3}
m_PrefabInstance: {fileID: 489969879}
m_PrefabAsset: {fileID: 0}
--- !u!1001 &491911248
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.034656826
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.0019042965
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: -0.91706365
objectReference: {fileID: 0}
- target: {fileID: 4676633831318799747, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0.39722723
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: -0.03933716
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0.25224686
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: -2.7196195
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.97121775
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.2292728
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: 0.062848374
objectReference: {fileID: 0}
- target: {fileID: 4676633831388223341, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: -0.01483645
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007564, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_Name
value: PlayerObjects
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_RootOrder
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: 92.171265
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 10.023724
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: -245.18256
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633831414007565, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.034656808
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.001904296
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: -0.91706365
objectReference: {fileID: 0}
- target: {fileID: 4676633832789495666, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0.39722723
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.x
value: -0.03933716
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.y
value: 0.25224686
objectReference: {fileID: 0}
- target: {fileID: 4676633832858914731, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalPosition.z
value: -2.7196195
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.w
value: 0.08924791
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.x
value: 0.004903927
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.y
value: -0.91394365
objectReference: {fileID: 0}
- target: {fileID: 4676633832928372887, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
propertyPath: m_LocalRotation.z
value: 0.39587584
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 8a918f60d084fbe468bf3b2c0a14fb52, type: 3}
--- !u!1 &493198196 stripped
GameObject:
m_CorrespondingSourceObject: {fileID: 919132149155446097, guid: e20114b5c13a067488940c5cc8e13b60, type: 3}
@ -2023,6 +1966,17 @@ Transform:
m_CorrespondingSourceObject: {fileID: -8679921383154817045, guid: 584f9522dd055c543863c0c60d13776e, type: 3}
m_PrefabInstance: {fileID: 3060674078835130068}
m_PrefabAsset: {fileID: 0}
--- !u!114 &508143115 stripped
MonoBehaviour:
m_CorrespondingSourceObject: {fileID: 8238856868209591015, guid: 2d949926f63a2554584336b07085202b, type: 3}
m_PrefabInstance: {fileID: 5633276111010996303}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c79d6b66286a2ac41b41321a95dfcc00, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &509124455 stripped
GameObject:
m_CorrespondingSourceObject: {fileID: 919132149155446097, guid: e20114b5c13a067488940c5cc8e13b60, type: 3}
@ -6670,6 +6624,17 @@ Transform:
m_CorrespondingSourceObject: {fileID: -8679921383154817045, guid: e20114b5c13a067488940c5cc8e13b60, type: 3}
m_PrefabInstance: {fileID: 3060674077961207736}
m_PrefabAsset: {fileID: 0}
--- !u!114 &1460540785 stripped
MonoBehaviour:
m_CorrespondingSourceObject: {fileID: 6109618642997272366, guid: 2d949926f63a2554584336b07085202b, type: 3}
m_PrefabInstance: {fileID: 5633276111010996303}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c79d6b66286a2ac41b41321a95dfcc00, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1001 &1461193461
PrefabInstance:
m_ObjectHideFlags: 0
@ -60794,6 +60759,10 @@ PrefabInstance:
m_Modification:
m_TransformParent: {fileID: 1509348081}
m_Modifications:
- target: {fileID: 617695716942238125, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: m_LocalPosition.z
value: -0.26
objectReference: {fileID: 0}
- target: {fileID: 1579399496488282771, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: m_LocalPosition.x
value: 4.5474735e-13
@ -60806,6 +60775,26 @@ PrefabInstance:
propertyPath: m_IsActive
value: 1
objectReference: {fileID: 0}
- target: {fileID: 3979716773325473156, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: m_LocalPosition.z
value: 1.52
objectReference: {fileID: 0}
- target: {fileID: 4442848222983829643, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Mode
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4442848222983829643, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Target
value:
objectReference: {fileID: 64137470}
- target: {fileID: 4442848222983829643, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName
value: Open
objectReference: {fileID: 0}
- target: {fileID: 4442848222983829643, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_TargetAssemblyTypeName
value: Door, Assembly-CSharp
objectReference: {fileID: 0}
- target: {fileID: 4895474368290382271, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: fallAwayTime
value: 2
@ -60878,6 +60867,22 @@ PrefabInstance:
propertyPath: m_LocalPosition.z
value: -0.41999152
objectReference: {fileID: 0}
- target: {fileID: 6548783543199996220, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Mode
value: 1
objectReference: {fileID: 0}
- target: {fileID: 6548783543199996220, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Target
value:
objectReference: {fileID: 1460540785}
- target: {fileID: 6548783543199996220, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName
value: Open
objectReference: {fileID: 0}
- target: {fileID: 6548783543199996220, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_TargetAssemblyTypeName
value: Door, Assembly-CSharp
objectReference: {fileID: 0}
- target: {fileID: 7337296876544949150, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: m_LocalPosition.x
value: -0.2
@ -60886,6 +60891,38 @@ PrefabInstance:
propertyPath: m_LocalPosition.z
value: 1.37
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.size
value: 1
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Mode
value: 1
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Target
value:
objectReference: {fileID: 508143115}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_CallState
value: 2
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName
value: Open
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_TargetAssemblyTypeName
value: Door, Assembly-CSharp
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Arguments.m_StringArgument
value:
objectReference: {fileID: 0}
- target: {fileID: 7710948611258593327, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: _onPress.m_PersistentCalls.m_Calls.Array.data[0].m_Arguments.m_ObjectArgumentAssemblyTypeName
value: UnityEngine.Object, UnityEngine
objectReference: {fileID: 0}
- target: {fileID: 8836440962582373704, guid: 2d949926f63a2554584336b07085202b, type: 3}
propertyPath: m_RootOrder
value: 36

View File

@ -7,7 +7,7 @@ public class Door : MonoBehaviour
{
[SerializeField] private Animator _animator;
private bool _opened;
private bool _opened = false;
public void Open()
{
@ -17,4 +17,15 @@ public class Door : MonoBehaviour
_animator.Play("DoorUp", 0, 0);
_opened = true;
}
public void Close()
{
Debug.Log("Door closed");
if (!_opened) return;
Debug.Log("after if");
//move door
_animator.Play("DoorDown", 0, 0);
_opened = false;
}
}

View File

@ -9,11 +9,14 @@ public class PressurePlate : MonoBehaviour
[SerializeField] private Animator pPlateAnim = null;
[SerializeField] private UnityEvent _onPress;
private bool opened = false;
private bool opened;
private float? triggered = null;
private void OnTriggerEnter(Collider other)
{
Debug.Log(opened);
Debug.Log("entered trigger");
if (other.CompareTag("Player") && !opened)
{
//pressure plate down and start trigger time
@ -42,6 +45,14 @@ public class PressurePlate : MonoBehaviour
if(timepassed > _triggerDelay && !opened)
{
_onPress.Invoke();
opened = true;
}
}
public void plateUp()
{
pPlateAnim.Play("PPup", 0, 0);
triggered = null;
opened = false;
}
}