任务:搭建第一关的框架
场景【第一关】
1.加入任务书的交互,交互键打开任务书,键盘【K】退出、手柄【B】退出
2.加入轰炸区、并做好适配。
3.啧,由于轰炸区的高度写了屎山代码,现在只能把对高度的适配这个参数还给轰炸区,再在场景中的轰炸区进行适配。
4.布置电话线断处(共六处)
5.优化电话线断除脚本,使其能够自己找到修电话线的UI
6.给电话线断处加上结束事件,因为有一条电话线修好后需要炸毁前面的石头
7.创建游戏物体【石头】
8.给石头添加控制脚本。
9.创建并编写事件【当修好第一个电话线】,召唤一枚炮弹砸向石头,石头检测到炮弹后销毁自己和炮弹,并在原地生成一个投掷物堆。
10.给炮弹加上标识,不是特殊的炮弹砸不烂石头。
下班,就剩9天了……😔
This commit is contained in:
parent
47dcb6173b
commit
3c682117f3
@ -49,6 +49,14 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
""expectedControlType"": ""Button"",
|
""expectedControlType"": ""Button"",
|
||||||
""processors"": """",
|
""processors"": """",
|
||||||
""interactions"": ""Press(behavior=2)""
|
""interactions"": ""Press(behavior=2)""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
""name"": ""Quit"",
|
||||||
|
""type"": ""Button"",
|
||||||
|
""id"": ""8d490180-d97c-4d4f-836c-a6f7a4392b67"",
|
||||||
|
""expectedControlType"": ""Button"",
|
||||||
|
""processors"": """",
|
||||||
|
""interactions"": ""Press(behavior=2)""
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
""bindings"": [
|
""bindings"": [
|
||||||
@ -183,6 +191,28 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
""action"": ""Coding"",
|
""action"": ""Coding"",
|
||||||
""isComposite"": false,
|
""isComposite"": false,
|
||||||
""isPartOfComposite"": false
|
""isPartOfComposite"": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
""name"": """",
|
||||||
|
""id"": ""9fc9a4fc-1140-4bf4-acb9-5e210bf4f365"",
|
||||||
|
""path"": ""<Keyboard>/k"",
|
||||||
|
""interactions"": """",
|
||||||
|
""processors"": """",
|
||||||
|
""groups"": ""Player"",
|
||||||
|
""action"": ""Quit"",
|
||||||
|
""isComposite"": false,
|
||||||
|
""isPartOfComposite"": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
""name"": """",
|
||||||
|
""id"": ""9bcc3236-8109-4b58-89db-131cb9301bf4"",
|
||||||
|
""path"": ""<Gamepad>/buttonEast"",
|
||||||
|
""interactions"": """",
|
||||||
|
""processors"": """",
|
||||||
|
""groups"": ""Player"",
|
||||||
|
""action"": ""Quit"",
|
||||||
|
""isComposite"": false,
|
||||||
|
""isPartOfComposite"": false
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@ -381,6 +411,7 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
m_PlayerNormal_Run = m_PlayerNormal.FindAction("Run", throwIfNotFound: true);
|
m_PlayerNormal_Run = m_PlayerNormal.FindAction("Run", throwIfNotFound: true);
|
||||||
m_PlayerNormal_Interaction = m_PlayerNormal.FindAction("Interaction", throwIfNotFound: true);
|
m_PlayerNormal_Interaction = m_PlayerNormal.FindAction("Interaction", throwIfNotFound: true);
|
||||||
m_PlayerNormal_Coding = m_PlayerNormal.FindAction("Coding", throwIfNotFound: true);
|
m_PlayerNormal_Coding = m_PlayerNormal.FindAction("Coding", throwIfNotFound: true);
|
||||||
|
m_PlayerNormal_Quit = m_PlayerNormal.FindAction("Quit", throwIfNotFound: true);
|
||||||
// NullMap
|
// NullMap
|
||||||
m_NullMap = asset.FindActionMap("NullMap", throwIfNotFound: true);
|
m_NullMap = asset.FindActionMap("NullMap", throwIfNotFound: true);
|
||||||
m_NullMap_Newaction = m_NullMap.FindAction("New action", throwIfNotFound: true);
|
m_NullMap_Newaction = m_NullMap.FindAction("New action", throwIfNotFound: true);
|
||||||
@ -442,6 +473,7 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
private readonly InputAction m_PlayerNormal_Run;
|
private readonly InputAction m_PlayerNormal_Run;
|
||||||
private readonly InputAction m_PlayerNormal_Interaction;
|
private readonly InputAction m_PlayerNormal_Interaction;
|
||||||
private readonly InputAction m_PlayerNormal_Coding;
|
private readonly InputAction m_PlayerNormal_Coding;
|
||||||
|
private readonly InputAction m_PlayerNormal_Quit;
|
||||||
public struct PlayerNormalActions
|
public struct PlayerNormalActions
|
||||||
{
|
{
|
||||||
private @Player m_Wrapper;
|
private @Player m_Wrapper;
|
||||||
@ -450,6 +482,7 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
public InputAction @Run => m_Wrapper.m_PlayerNormal_Run;
|
public InputAction @Run => m_Wrapper.m_PlayerNormal_Run;
|
||||||
public InputAction @Interaction => m_Wrapper.m_PlayerNormal_Interaction;
|
public InputAction @Interaction => m_Wrapper.m_PlayerNormal_Interaction;
|
||||||
public InputAction @Coding => m_Wrapper.m_PlayerNormal_Coding;
|
public InputAction @Coding => m_Wrapper.m_PlayerNormal_Coding;
|
||||||
|
public InputAction @Quit => m_Wrapper.m_PlayerNormal_Quit;
|
||||||
public InputActionMap Get() { return m_Wrapper.m_PlayerNormal; }
|
public InputActionMap Get() { return m_Wrapper.m_PlayerNormal; }
|
||||||
public void Enable() { Get().Enable(); }
|
public void Enable() { Get().Enable(); }
|
||||||
public void Disable() { Get().Disable(); }
|
public void Disable() { Get().Disable(); }
|
||||||
@ -471,6 +504,9 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
@Coding.started -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnCoding;
|
@Coding.started -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnCoding;
|
||||||
@Coding.performed -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnCoding;
|
@Coding.performed -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnCoding;
|
||||||
@Coding.canceled -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnCoding;
|
@Coding.canceled -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnCoding;
|
||||||
|
@Quit.started -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnQuit;
|
||||||
|
@Quit.performed -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnQuit;
|
||||||
|
@Quit.canceled -= m_Wrapper.m_PlayerNormalActionsCallbackInterface.OnQuit;
|
||||||
}
|
}
|
||||||
m_Wrapper.m_PlayerNormalActionsCallbackInterface = instance;
|
m_Wrapper.m_PlayerNormalActionsCallbackInterface = instance;
|
||||||
if (instance != null)
|
if (instance != null)
|
||||||
@ -487,6 +523,9 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
@Coding.started += instance.OnCoding;
|
@Coding.started += instance.OnCoding;
|
||||||
@Coding.performed += instance.OnCoding;
|
@Coding.performed += instance.OnCoding;
|
||||||
@Coding.canceled += instance.OnCoding;
|
@Coding.canceled += instance.OnCoding;
|
||||||
|
@Quit.started += instance.OnQuit;
|
||||||
|
@Quit.performed += instance.OnQuit;
|
||||||
|
@Quit.canceled += instance.OnQuit;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -588,6 +627,7 @@ public class @Player : IInputActionCollection, IDisposable
|
|||||||
void OnRun(InputAction.CallbackContext context);
|
void OnRun(InputAction.CallbackContext context);
|
||||||
void OnInteraction(InputAction.CallbackContext context);
|
void OnInteraction(InputAction.CallbackContext context);
|
||||||
void OnCoding(InputAction.CallbackContext context);
|
void OnCoding(InputAction.CallbackContext context);
|
||||||
|
void OnQuit(InputAction.CallbackContext context);
|
||||||
}
|
}
|
||||||
public interface INullMapActions
|
public interface INullMapActions
|
||||||
{
|
{
|
||||||
|
@ -36,6 +36,14 @@
|
|||||||
"expectedControlType": "Button",
|
"expectedControlType": "Button",
|
||||||
"processors": "",
|
"processors": "",
|
||||||
"interactions": "Press(behavior=2)"
|
"interactions": "Press(behavior=2)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Quit",
|
||||||
|
"type": "Button",
|
||||||
|
"id": "8d490180-d97c-4d4f-836c-a6f7a4392b67",
|
||||||
|
"expectedControlType": "Button",
|
||||||
|
"processors": "",
|
||||||
|
"interactions": "Press(behavior=2)"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"bindings": [
|
"bindings": [
|
||||||
@ -170,6 +178,28 @@
|
|||||||
"action": "Coding",
|
"action": "Coding",
|
||||||
"isComposite": false,
|
"isComposite": false,
|
||||||
"isPartOfComposite": false
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "9fc9a4fc-1140-4bf4-acb9-5e210bf4f365",
|
||||||
|
"path": "<Keyboard>/k",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Player",
|
||||||
|
"action": "Quit",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "",
|
||||||
|
"id": "9bcc3236-8109-4b58-89db-131cb9301bf4",
|
||||||
|
"path": "<Gamepad>/buttonEast",
|
||||||
|
"interactions": "",
|
||||||
|
"processors": "",
|
||||||
|
"groups": "Player",
|
||||||
|
"action": "Quit",
|
||||||
|
"isComposite": false,
|
||||||
|
"isPartOfComposite": false
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
@ -44,6 +44,6 @@ Material:
|
|||||||
- WaveIntensity_2: 1
|
- WaveIntensity_2: 1
|
||||||
- WaveSpread_Value: 0
|
- WaveSpread_Value: 0
|
||||||
m_Colors:
|
m_Colors:
|
||||||
- Center: {r: -0.61346686, g: 0.31902167, b: 0, a: 0}
|
- Center: {r: 0.6066498, g: 0.21391696, b: 0, a: 0}
|
||||||
- Vector2_d2d098295fc146f08b921b231b2e5199: {r: 1.6, g: 0.9, b: 0, a: 0}
|
- Vector2_d2d098295fc146f08b921b231b2e5199: {r: 1.6, g: 0.9, b: 0, a: 0}
|
||||||
m_BuildTextureStacks: []
|
m_BuildTextureStacks: []
|
||||||
|
229
Assets/Prefabs/电话线&电报系统/修电话线界面.prefab
Normal file
229
Assets/Prefabs/电话线&电报系统/修电话线界面.prefab
Normal file
@ -0,0 +1,229 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!1 &8233114533063075528
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8233114533063075529}
|
||||||
|
- component: {fileID: 8233114533063075543}
|
||||||
|
- component: {fileID: 8233114533063075542}
|
||||||
|
m_Layer: 5
|
||||||
|
m_Name: "\u4FEE\u7535\u8BDD\u7EBF\u754C\u9762"
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 0
|
||||||
|
--- !u!224 &8233114533063075529
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114533063075528}
|
||||||
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
|
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||||
|
m_LocalScale: {x: 0.15, y: 0.15, z: 0.15}
|
||||||
|
m_Children:
|
||||||
|
- {fileID: 8233114533355190934}
|
||||||
|
- {fileID: 8233114534707674507}
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_RootOrder: 0
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
m_AnchorMin: {x: 0.61048114, y: 0.20600002}
|
||||||
|
m_AnchorMax: {x: 0.86200005, y: 0.572}
|
||||||
|
m_AnchoredPosition: {x: -432.00003, y: -3.9000397}
|
||||||
|
m_SizeDelta: {x: 297, y: 142}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!222 &8233114533063075543
|
||||||
|
CanvasRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114533063075528}
|
||||||
|
m_CullTransparentMesh: 1
|
||||||
|
--- !u!114 &8233114533063075542
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114533063075528}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_Material: {fileID: 0}
|
||||||
|
m_Color: {r: 0.21960786, g: 0.21960786, b: 0.21960786, a: 0}
|
||||||
|
m_RaycastTarget: 1
|
||||||
|
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_Maskable: 1
|
||||||
|
m_OnCullStateChanged:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
|
m_Type: 1
|
||||||
|
m_PreserveAspect: 0
|
||||||
|
m_FillCenter: 1
|
||||||
|
m_FillMethod: 4
|
||||||
|
m_FillAmount: 1
|
||||||
|
m_FillClockwise: 1
|
||||||
|
m_FillOrigin: 0
|
||||||
|
m_UseSpriteMesh: 0
|
||||||
|
m_PixelsPerUnitMultiplier: 1
|
||||||
|
--- !u!1 &8233114533355190921
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8233114533355190934}
|
||||||
|
- component: {fileID: 8233114533355190932}
|
||||||
|
- component: {fileID: 8233114533355190935}
|
||||||
|
m_Layer: 5
|
||||||
|
m_Name: "\u8FDB\u5EA6\u6761\u80CC\u666F"
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!224 &8233114533355190934
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114533355190921}
|
||||||
|
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: 8233114533063075529}
|
||||||
|
m_RootOrder: 0
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
m_AnchorMin: {x: 0.2732673, y: 0.23600002}
|
||||||
|
m_AnchorMax: {x: 0.72315717, y: 0.80067426}
|
||||||
|
m_AnchoredPosition: {x: 0.5, y: -3.9999695}
|
||||||
|
m_SizeDelta: {x: -79, y: -26}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!222 &8233114533355190932
|
||||||
|
CanvasRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114533355190921}
|
||||||
|
m_CullTransparentMesh: 1
|
||||||
|
--- !u!114 &8233114533355190935
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114533355190921}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_Material: {fileID: 0}
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_RaycastTarget: 1
|
||||||
|
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_Maskable: 1
|
||||||
|
m_OnCullStateChanged:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_Sprite: {fileID: 10913, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
|
m_Type: 0
|
||||||
|
m_PreserveAspect: 0
|
||||||
|
m_FillCenter: 1
|
||||||
|
m_FillMethod: 4
|
||||||
|
m_FillAmount: 1
|
||||||
|
m_FillClockwise: 1
|
||||||
|
m_FillOrigin: 0
|
||||||
|
m_UseSpriteMesh: 0
|
||||||
|
m_PixelsPerUnitMultiplier: 1
|
||||||
|
--- !u!1 &8233114534707674506
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8233114534707674507}
|
||||||
|
- component: {fileID: 8233114534707674505}
|
||||||
|
- component: {fileID: 8233114534707674504}
|
||||||
|
m_Layer: 5
|
||||||
|
m_Name: "\u8FDB\u5EA6\u6761"
|
||||||
|
m_TagString: "\u8FDB\u5EA6\u6761"
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!224 &8233114534707674507
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114534707674506}
|
||||||
|
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: 8233114533063075529}
|
||||||
|
m_RootOrder: 1
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
m_AnchorMin: {x: 0.2732673, y: 0.23600002}
|
||||||
|
m_AnchorMax: {x: 0.72315717, y: 0.80067426}
|
||||||
|
m_AnchoredPosition: {x: 0.5, y: -3.9999695}
|
||||||
|
m_SizeDelta: {x: -79, y: -26}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!222 &8233114534707674505
|
||||||
|
CanvasRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114534707674506}
|
||||||
|
m_CullTransparentMesh: 1
|
||||||
|
--- !u!114 &8233114534707674504
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8233114534707674506}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_Material: {fileID: 0}
|
||||||
|
m_Color: {r: 1, g: 0, b: 0, a: 1}
|
||||||
|
m_RaycastTarget: 1
|
||||||
|
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_Maskable: 1
|
||||||
|
m_OnCullStateChanged:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_Sprite: {fileID: 10913, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
|
m_Type: 3
|
||||||
|
m_PreserveAspect: 0
|
||||||
|
m_FillCenter: 1
|
||||||
|
m_FillMethod: 4
|
||||||
|
m_FillAmount: 0.31
|
||||||
|
m_FillClockwise: 1
|
||||||
|
m_FillOrigin: 2
|
||||||
|
m_UseSpriteMesh: 0
|
||||||
|
m_PixelsPerUnitMultiplier: 1
|
7
Assets/Prefabs/电话线&电报系统/修电话线界面.prefab.meta
Normal file
7
Assets/Prefabs/电话线&电报系统/修电话线界面.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 82d871be611f9d14fbe8c166075c1a37
|
||||||
|
PrefabImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
@ -277,6 +277,22 @@ MonoBehaviour:
|
|||||||
m_CallState: 2
|
m_CallState: 2
|
||||||
m_ActionId: fddd4068-5ae8-4c1a-8498-4c8c30327f57
|
m_ActionId: fddd4068-5ae8-4c1a-8498-4c8c30327f57
|
||||||
m_ActionName: PlayerInThrowing/AdjustTheAngle[/Keyboard/s,/Keyboard/w]
|
m_ActionName: PlayerInThrowing/AdjustTheAngle[/Keyboard/s,/Keyboard/w]
|
||||||
|
- m_PersistentCalls:
|
||||||
|
m_Calls:
|
||||||
|
- m_Target: {fileID: 1692961902718145226}
|
||||||
|
m_TargetAssemblyTypeName: M_Player, Assembly-CSharp
|
||||||
|
m_MethodName: OnQuit
|
||||||
|
m_Mode: 0
|
||||||
|
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
|
||||||
|
m_ActionId: 8d490180-d97c-4d4f-836c-a6f7a4392b67
|
||||||
|
m_ActionName: PlayerNormal/Quit[/Keyboard/k,/XInputControllerWindows/buttonEast]
|
||||||
m_NeverAutoSwitchControlSchemes: 0
|
m_NeverAutoSwitchControlSchemes: 0
|
||||||
m_DefaultControlScheme: Player
|
m_DefaultControlScheme: Player
|
||||||
m_DefaultActionMap: PlayerNormal
|
m_DefaultActionMap: PlayerNormal
|
||||||
|
@ -14,7 +14,7 @@ GameObject:
|
|||||||
- component: {fileID: 7607195361720575763}
|
- component: {fileID: 7607195361720575763}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: "\u70AE\u5F39"
|
m_Name: "\u70AE\u5F39"
|
||||||
m_TagString: Untagged
|
m_TagString: "\u70AE\u5F39"
|
||||||
m_Icon: {fileID: 0}
|
m_Icon: {fileID: 0}
|
||||||
m_NavMeshLayer: 0
|
m_NavMeshLayer: 0
|
||||||
m_StaticEditorFlags: 0
|
m_StaticEditorFlags: 0
|
||||||
@ -98,6 +98,7 @@ MonoBehaviour:
|
|||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
shadow: {fileID: 3566358762308528686, guid: 73f23d723f100f54db8c58c86da940eb, type: 3}
|
shadow: {fileID: 3566358762308528686, guid: 73f23d723f100f54db8c58c86da940eb, type: 3}
|
||||||
boomObj: {fileID: 7911349319489194765, guid: 299f21a72c405984780245234d765a50, type: 3}
|
boomObj: {fileID: 7911349319489194765, guid: 299f21a72c405984780245234d765a50, type: 3}
|
||||||
|
M_BombingArea: {fileID: 0}
|
||||||
--- !u!61 &7607195361720575763
|
--- !u!61 &7607195361720575763
|
||||||
BoxCollider2D:
|
BoxCollider2D:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -1297,81 +1297,11 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 3945938556576538518, guid: 77c170410751adc43b3804b6a3f59d3b, type: 3}
|
m_CorrespondingSourceObject: {fileID: 3945938556576538518, guid: 77c170410751adc43b3804b6a3f59d3b, type: 3}
|
||||||
m_PrefabInstance: {fileID: 381999398}
|
m_PrefabInstance: {fileID: 381999398}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
--- !u!1 &383396460
|
--- !u!4 &421694489 stripped
|
||||||
GameObject:
|
Transform:
|
||||||
m_ObjectHideFlags: 0
|
m_CorrespondingSourceObject: {fileID: 1692961902559028647, guid: e0481b76b4057fd4fad09cc46028b53a, type: 3}
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
m_PrefabInstance: {fileID: 1692961901516479215}
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
serializedVersion: 6
|
|
||||||
m_Component:
|
|
||||||
- component: {fileID: 383396461}
|
|
||||||
- component: {fileID: 383396463}
|
|
||||||
- component: {fileID: 383396462}
|
|
||||||
m_Layer: 5
|
|
||||||
m_Name: "\u8FDB\u5EA6\u6761"
|
|
||||||
m_TagString: "\u8FDB\u5EA6\u6761"
|
|
||||||
m_Icon: {fileID: 0}
|
|
||||||
m_NavMeshLayer: 0
|
|
||||||
m_StaticEditorFlags: 0
|
|
||||||
m_IsActive: 1
|
|
||||||
--- !u!224 &383396461
|
|
||||||
RectTransform:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 383396460}
|
|
||||||
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: 1893052719}
|
|
||||||
m_RootOrder: 1
|
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
|
||||||
m_AnchorMin: {x: 0.2732673, y: 0.23600002}
|
|
||||||
m_AnchorMax: {x: 0.72315717, y: 0.80067426}
|
|
||||||
m_AnchoredPosition: {x: 0.5, y: -3.9999695}
|
|
||||||
m_SizeDelta: {x: -79, y: -26}
|
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
|
||||||
--- !u!114 &383396462
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 383396460}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
m_Material: {fileID: 0}
|
|
||||||
m_Color: {r: 1, g: 0, b: 0, a: 1}
|
|
||||||
m_RaycastTarget: 1
|
|
||||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
|
||||||
m_Maskable: 1
|
|
||||||
m_OnCullStateChanged:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
m_Sprite: {fileID: 10913, guid: 0000000000000000f000000000000000, type: 0}
|
|
||||||
m_Type: 3
|
|
||||||
m_PreserveAspect: 0
|
|
||||||
m_FillCenter: 1
|
|
||||||
m_FillMethod: 4
|
|
||||||
m_FillAmount: 0.31
|
|
||||||
m_FillClockwise: 1
|
|
||||||
m_FillOrigin: 2
|
|
||||||
m_UseSpriteMesh: 0
|
|
||||||
m_PixelsPerUnitMultiplier: 1
|
|
||||||
--- !u!222 &383396463
|
|
||||||
CanvasRenderer:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 383396460}
|
|
||||||
m_CullTransparentMesh: 1
|
|
||||||
--- !u!1 &461367559
|
--- !u!1 &461367559
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -2567,7 +2497,6 @@ MonoBehaviour:
|
|||||||
shellSpeed: 10
|
shellSpeed: 10
|
||||||
shellFallingTime: 1
|
shellFallingTime: 1
|
||||||
shellShadowRangeOfChange: 0.1
|
shellShadowRangeOfChange: 0.1
|
||||||
shellShadowPositionYOffSet: 1.5
|
|
||||||
rateOfChangeOfThrowingAngle: 1
|
rateOfChangeOfThrowingAngle: 1
|
||||||
strengthOfThrowing: 8
|
strengthOfThrowing: 8
|
||||||
stageName:
|
stageName:
|
||||||
@ -2686,7 +2615,7 @@ GameObject:
|
|||||||
m_Icon: {fileID: 0}
|
m_Icon: {fileID: 0}
|
||||||
m_NavMeshLayer: 0
|
m_NavMeshLayer: 0
|
||||||
m_StaticEditorFlags: 0
|
m_StaticEditorFlags: 0
|
||||||
m_IsActive: 1
|
m_IsActive: 0
|
||||||
--- !u!4 &969830748
|
--- !u!4 &969830748
|
||||||
Transform:
|
Transform:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -3332,6 +3261,10 @@ MonoBehaviour:
|
|||||||
m_CallState: 2
|
m_CallState: 2
|
||||||
m_ActionId: fddd4068-5ae8-4c1a-8498-4c8c30327f57
|
m_ActionId: fddd4068-5ae8-4c1a-8498-4c8c30327f57
|
||||||
m_ActionName: PlayerInThrowing/AdjustTheAngle[/Keyboard/s,/Keyboard/w]
|
m_ActionName: PlayerInThrowing/AdjustTheAngle[/Keyboard/s,/Keyboard/w]
|
||||||
|
- m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_ActionId: 8d490180-d97c-4d4f-836c-a6f7a4392b67
|
||||||
|
m_ActionName: PlayerNormal/Quit[/Keyboard/k]
|
||||||
m_NeverAutoSwitchControlSchemes: 0
|
m_NeverAutoSwitchControlSchemes: 0
|
||||||
m_DefaultControlScheme: Player
|
m_DefaultControlScheme: Player
|
||||||
m_DefaultActionMap: PlayerNormal
|
m_DefaultActionMap: PlayerNormal
|
||||||
@ -4593,81 +4526,6 @@ Transform:
|
|||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_RootOrder: 1
|
m_RootOrder: 1
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &1631382895
|
|
||||||
GameObject:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
serializedVersion: 6
|
|
||||||
m_Component:
|
|
||||||
- component: {fileID: 1631382896}
|
|
||||||
- component: {fileID: 1631382898}
|
|
||||||
- component: {fileID: 1631382897}
|
|
||||||
m_Layer: 5
|
|
||||||
m_Name: "\u8FDB\u5EA6\u6761\u80CC\u666F"
|
|
||||||
m_TagString: Untagged
|
|
||||||
m_Icon: {fileID: 0}
|
|
||||||
m_NavMeshLayer: 0
|
|
||||||
m_StaticEditorFlags: 0
|
|
||||||
m_IsActive: 1
|
|
||||||
--- !u!224 &1631382896
|
|
||||||
RectTransform:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1631382895}
|
|
||||||
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: 1893052719}
|
|
||||||
m_RootOrder: 0
|
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
|
||||||
m_AnchorMin: {x: 0.2732673, y: 0.23600002}
|
|
||||||
m_AnchorMax: {x: 0.72315717, y: 0.80067426}
|
|
||||||
m_AnchoredPosition: {x: 0.5, y: -3.9999695}
|
|
||||||
m_SizeDelta: {x: -79, y: -26}
|
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
|
||||||
--- !u!114 &1631382897
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1631382895}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
m_Material: {fileID: 0}
|
|
||||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
|
||||||
m_RaycastTarget: 1
|
|
||||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
|
||||||
m_Maskable: 1
|
|
||||||
m_OnCullStateChanged:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
m_Sprite: {fileID: 10913, guid: 0000000000000000f000000000000000, type: 0}
|
|
||||||
m_Type: 0
|
|
||||||
m_PreserveAspect: 0
|
|
||||||
m_FillCenter: 1
|
|
||||||
m_FillMethod: 4
|
|
||||||
m_FillAmount: 1
|
|
||||||
m_FillClockwise: 1
|
|
||||||
m_FillOrigin: 0
|
|
||||||
m_UseSpriteMesh: 0
|
|
||||||
m_PixelsPerUnitMultiplier: 1
|
|
||||||
--- !u!222 &1631382898
|
|
||||||
CanvasRenderer:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1631382895}
|
|
||||||
m_CullTransparentMesh: 1
|
|
||||||
--- !u!1 &1727183435
|
--- !u!1 &1727183435
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -5041,83 +4899,16 @@ CanvasRenderer:
|
|||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 1839520244}
|
m_GameObject: {fileID: 1839520244}
|
||||||
m_CullTransparentMesh: 1
|
m_CullTransparentMesh: 1
|
||||||
--- !u!1 &1893052718
|
--- !u!1 &1893052718 stripped
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_CorrespondingSourceObject: {fileID: 8233114533063075528, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
m_PrefabInstance: {fileID: 8233114534945036262}
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
serializedVersion: 6
|
--- !u!224 &1893052719 stripped
|
||||||
m_Component:
|
|
||||||
- component: {fileID: 1893052719}
|
|
||||||
- component: {fileID: 1893052721}
|
|
||||||
- component: {fileID: 1893052720}
|
|
||||||
m_Layer: 5
|
|
||||||
m_Name: "\u4FEE\u7535\u8BDD\u7EBF\u754C\u9762"
|
|
||||||
m_TagString: Untagged
|
|
||||||
m_Icon: {fileID: 0}
|
|
||||||
m_NavMeshLayer: 0
|
|
||||||
m_StaticEditorFlags: 0
|
|
||||||
m_IsActive: 0
|
|
||||||
--- !u!224 &1893052719
|
|
||||||
RectTransform:
|
RectTransform:
|
||||||
m_ObjectHideFlags: 0
|
m_CorrespondingSourceObject: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
m_PrefabInstance: {fileID: 8233114534945036262}
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 1893052718}
|
|
||||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
|
||||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
|
||||||
m_LocalScale: {x: 0.15, y: 0.15, z: 0.15}
|
|
||||||
m_Children:
|
|
||||||
- {fileID: 1631382896}
|
|
||||||
- {fileID: 383396461}
|
|
||||||
m_Father: {fileID: 1272302693}
|
|
||||||
m_RootOrder: 1
|
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
|
||||||
m_AnchorMin: {x: 0.61048114, y: 0.20600002}
|
|
||||||
m_AnchorMax: {x: 0.86200005, y: 0.572}
|
|
||||||
m_AnchoredPosition: {x: -432.00003, y: -3.9000397}
|
|
||||||
m_SizeDelta: {x: 297, y: 142}
|
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
|
||||||
--- !u!114 &1893052720
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1893052718}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
m_Material: {fileID: 0}
|
|
||||||
m_Color: {r: 0.21960786, g: 0.21960786, b: 0.21960786, a: 0}
|
|
||||||
m_RaycastTarget: 1
|
|
||||||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
|
||||||
m_Maskable: 1
|
|
||||||
m_OnCullStateChanged:
|
|
||||||
m_PersistentCalls:
|
|
||||||
m_Calls: []
|
|
||||||
m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0}
|
|
||||||
m_Type: 1
|
|
||||||
m_PreserveAspect: 0
|
|
||||||
m_FillCenter: 1
|
|
||||||
m_FillMethod: 4
|
|
||||||
m_FillAmount: 1
|
|
||||||
m_FillClockwise: 1
|
|
||||||
m_FillOrigin: 0
|
|
||||||
m_UseSpriteMesh: 0
|
|
||||||
m_PixelsPerUnitMultiplier: 1
|
|
||||||
--- !u!222 &1893052721
|
|
||||||
CanvasRenderer:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1893052718}
|
|
||||||
m_CullTransparentMesh: 1
|
|
||||||
--- !u!1 &1894615459
|
--- !u!1 &1894615459
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@ -6219,6 +6010,10 @@ PrefabInstance:
|
|||||||
m_Modification:
|
m_Modification:
|
||||||
m_TransformParent: {fileID: 1601657821}
|
m_TransformParent: {fileID: 1601657821}
|
||||||
m_Modifications:
|
m_Modifications:
|
||||||
|
- target: {fileID: 1692961902718145226, guid: e0481b76b4057fd4fad09cc46028b53a, type: 3}
|
||||||
|
propertyPath: throwOffset
|
||||||
|
value:
|
||||||
|
objectReference: {fileID: 421694489}
|
||||||
- target: {fileID: 3719369086825294709, guid: e0481b76b4057fd4fad09cc46028b53a, type: 3}
|
- target: {fileID: 3719369086825294709, guid: e0481b76b4057fd4fad09cc46028b53a, type: 3}
|
||||||
propertyPath: m_RootOrder
|
propertyPath: m_RootOrder
|
||||||
value: 1
|
value: 1
|
||||||
@ -6274,3 +6069,100 @@ Transform:
|
|||||||
m_CorrespondingSourceObject: {fileID: 3719369086825294709, guid: e0481b76b4057fd4fad09cc46028b53a, type: 3}
|
m_CorrespondingSourceObject: {fileID: 3719369086825294709, guid: e0481b76b4057fd4fad09cc46028b53a, type: 3}
|
||||||
m_PrefabInstance: {fileID: 1692961901516479215}
|
m_PrefabInstance: {fileID: 1692961901516479215}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
--- !u!1001 &8233114534945036262
|
||||||
|
PrefabInstance:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Modification:
|
||||||
|
m_TransformParent: {fileID: 1272302693}
|
||||||
|
m_Modifications:
|
||||||
|
- target: {fileID: 8233114533063075528, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_Name
|
||||||
|
value: "\u4FEE\u7535\u8BDD\u7EBF\u754C\u9762"
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_Pivot.x
|
||||||
|
value: 0.5
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_Pivot.y
|
||||||
|
value: 0.5
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_RootOrder
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_AnchorMax.x
|
||||||
|
value: 0.86200005
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_AnchorMax.y
|
||||||
|
value: 0.572
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_AnchorMin.x
|
||||||
|
value: 0.61048114
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_AnchorMin.y
|
||||||
|
value: 0.20600002
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_SizeDelta.x
|
||||||
|
value: 297
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_SizeDelta.y
|
||||||
|
value: 142
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalPosition.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.w
|
||||||
|
value: 1
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.x
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.y
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalRotation.z
|
||||||
|
value: -0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_AnchoredPosition.x
|
||||||
|
value: -432.00003
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_AnchoredPosition.y
|
||||||
|
value: -3.9000397
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.x
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.y
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
propertyPath: m_LocalEulerAnglesHint.z
|
||||||
|
value: 0
|
||||||
|
objectReference: {fileID: 0}
|
||||||
|
m_RemovedComponents: []
|
||||||
|
m_SourcePrefab: {fileID: 100100000, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -125,6 +125,11 @@ public class M_Player : MonoBehaviour
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void OnQuit(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
if(context.started) catched.Quit();//如果按下退出按钮,则执行捕捉到物体的退出功能
|
||||||
|
}
|
||||||
|
|
||||||
//监听修改投掷角度的函数
|
//监听修改投掷角度的函数
|
||||||
public void OnAdjustTheAngle(InputAction.CallbackContext context)
|
public void OnAdjustTheAngle(InputAction.CallbackContext context)
|
||||||
{throwingAngleDir = context.ReadValue<float>();}//把收到的轴的值交给角度变化的大小和方向
|
{throwingAngleDir = context.ReadValue<float>();}//把收到的轴的值交给角度变化的大小和方向
|
||||||
|
21
Assets/Scripts/事件/CallASpecialShell.cs
Normal file
21
Assets/Scripts/事件/CallASpecialShell.cs
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class CallASpecialShell : Event
|
||||||
|
{
|
||||||
|
//修好第一个电话线后的事件,召唤一个特殊的炮弹摧毁石头
|
||||||
|
[Tooltip("要召唤,得先有,对吧?拖进炮弹的预制体")]
|
||||||
|
public GameObject shell;
|
||||||
|
[Tooltip("召唤的炮弹需要知道自己属于哪个轰炸区,请拖入其轰炸区")]
|
||||||
|
public BombingArea bombingArea;
|
||||||
|
|
||||||
|
public override void OnCall()
|
||||||
|
{
|
||||||
|
//当事件触发,生成一个特殊的炮弹
|
||||||
|
Shell thisShell = Instantiate(shell,new Vector3(15.1599998f,9.23999977f,0f),Quaternion.identity).
|
||||||
|
GetComponent<Shell>();
|
||||||
|
thisShell.M_BombingArea = bombingArea;
|
||||||
|
thisShell.YouAreSpecal();//告诉这枚炮弹,它是特殊的
|
||||||
|
}
|
||||||
|
}
|
11
Assets/Scripts/事件/CallASpecialShell.cs.meta
Normal file
11
Assets/Scripts/事件/CallASpecialShell.cs.meta
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 4a81fb9add054924e9caa0d022bf4a6b
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
@ -1,12 +1,14 @@
|
|||||||
using System.Collections;
|
using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
public class AllLinesInfo : MonoBehaviour
|
public class AllLinesInfo : MonoBehaviour
|
||||||
{
|
{
|
||||||
//总线信息类,用来存储场景中电话线断裂的总体信息,
|
//总线信息类,用来存储场景中电话线断裂的总体信息,
|
||||||
// Start is called before the first frame update
|
// Start is called before the first frame update
|
||||||
public int needCount;
|
[ReadOnly][SerializeField]
|
||||||
|
private int needCount;
|
||||||
public int OKCount = 0;
|
public int OKCount = 0;
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
@ -20,4 +22,23 @@ public class AllLinesInfo : MonoBehaviour
|
|||||||
}
|
}
|
||||||
|
|
||||||
public bool AreYouOK(){return (needCount == OKCount);}//返回完成量是不是等于需求量
|
public bool AreYouOK(){return (needCount == OKCount);}//返回完成量是不是等于需求量
|
||||||
|
|
||||||
|
//制造一个只读的变量,不要动这些
|
||||||
|
public class ReadOnlyAttribute : PropertyAttribute{}
|
||||||
|
[CustomPropertyDrawer(typeof(ReadOnlyAttribute))]
|
||||||
|
public class ReadOnlyDrawer : PropertyDrawer
|
||||||
|
{
|
||||||
|
public override float GetPropertyHeight(SerializedProperty property, GUIContent label)
|
||||||
|
{
|
||||||
|
return EditorGUI.GetPropertyHeight(property, label, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
|
||||||
|
{
|
||||||
|
GUI.enabled = false;
|
||||||
|
EditorGUI.PropertyField(position, property, label, true);
|
||||||
|
GUI.enabled = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//
|
||||||
}
|
}
|
||||||
|
@ -32,8 +32,8 @@ public class IndexRecoder : MonoBehaviour
|
|||||||
public float shellFallingTime;
|
public float shellFallingTime;
|
||||||
[Tooltip("炮弹阴影的震动幅度")]
|
[Tooltip("炮弹阴影的震动幅度")]
|
||||||
public float shellShadowRangeOfChange;
|
public float shellShadowRangeOfChange;
|
||||||
[Tooltip("炮弹阴影的Y值偏移")]
|
// [Tooltip("炮弹阴影的Y值偏移")]
|
||||||
public float shellShadowPositionYOffSet;
|
// public float shellShadowPositionYOffSet;
|
||||||
[Tooltip("玩家投掷角度变化的速度")]
|
[Tooltip("玩家投掷角度变化的速度")]
|
||||||
public float rateOfChangeOfThrowingAngle;
|
public float rateOfChangeOfThrowingAngle;
|
||||||
[Tooltip("抛出投掷物的力度")]
|
[Tooltip("抛出投掷物的力度")]
|
||||||
|
@ -68,7 +68,8 @@ public class Machine : Interactive
|
|||||||
//用来检查电话线的函数,如果电话线全通,返回true,否则返回false
|
//用来检查电话线的函数,如果电话线全通,返回true,否则返回false
|
||||||
private bool LinesCheck()
|
private bool LinesCheck()
|
||||||
{
|
{
|
||||||
if(linesChecker.needCount == linesChecker.OKCount) return true;
|
//if(linesChecker.needCount == linesChecker.OKCount) return true;过时的方法
|
||||||
|
if(linesChecker.AreYouOK()) return true;
|
||||||
else return false;
|
else return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
17
Assets/Scripts/具象物体/MissionBook.cs
Normal file
17
Assets/Scripts/具象物体/MissionBook.cs
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class MissionBook : Interactive
|
||||||
|
{
|
||||||
|
//任务书,继承可交互物体基类
|
||||||
|
[Tooltip("就是Canvas物体,拖进来,用来找到任务书的UI并控制它的开关")]
|
||||||
|
public RectTransform canvas;
|
||||||
|
private GameObject bookUI;//任务书游戏物体
|
||||||
|
void Start()
|
||||||
|
{
|
||||||
|
bookUI = canvas.Find("任务书").gameObject;//找到任务书UI,因为其默认隐藏,所以必须用这种方式找到
|
||||||
|
}
|
||||||
|
public override void OnCall(){bookUI.SetActive(true);}//当被唤醒,直接显示任务书的UI
|
||||||
|
public override void Quit(){bookUI.SetActive(false);}//当触发退出按钮,直接关闭任务书UI
|
||||||
|
}
|
11
Assets/Scripts/具象物体/MissionBook.cs.meta
Normal file
11
Assets/Scripts/具象物体/MissionBook.cs.meta
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: c4bf5fb83616faf46871d36e6dd11e78
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
@ -14,6 +14,8 @@ public class Shell : MonoBehaviour
|
|||||||
private bool isDroping = false;
|
private bool isDroping = false;
|
||||||
private Transform m_shadow;
|
private Transform m_shadow;
|
||||||
public GameObject boomObj;
|
public GameObject boomObj;
|
||||||
|
public BombingArea M_BombingArea;
|
||||||
|
private bool amISpecal = false;//记录自己是不是特殊的的变量。特殊的炮弹才能炸烂石头。
|
||||||
|
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
@ -24,7 +26,7 @@ public class Shell : MonoBehaviour
|
|||||||
m_shadow = Instantiate(shadow,//生成一片阴影
|
m_shadow = Instantiate(shadow,//生成一片阴影
|
||||||
new Vector3(transform.position.x,//在这枚炮弹的X
|
new Vector3(transform.position.x,//在这枚炮弹的X
|
||||||
ground.transform.position.y + //地面的Y
|
ground.transform.position.y + //地面的Y
|
||||||
indexRecoder.shellShadowPositionYOffSet,//加上偏移量
|
M_BombingArea.shellShadowYOffset,//加上偏移量
|
||||||
0),
|
0),
|
||||||
Quaternion.identity)
|
Quaternion.identity)
|
||||||
.transform;
|
.transform;
|
||||||
@ -43,6 +45,9 @@ public class Shell : MonoBehaviour
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool AmISpecal(){return amISpecal;}//外部调用,返回这个炮弹是不是特殊的
|
||||||
|
public void YouAreSpecal(){amISpecal = true;}//外部调用,生成炮弹时,给其标记它是特殊的。
|
||||||
|
|
||||||
private void ShadowShock()
|
private void ShadowShock()
|
||||||
{
|
{
|
||||||
m_shadow.transform.localScale = new Vector3(m_shadow.localScale.x +
|
m_shadow.transform.localScale = new Vector3(m_shadow.localScale.x +
|
||||||
@ -71,6 +76,12 @@ public class Shell : MonoBehaviour
|
|||||||
Destroy(gameObject);
|
Destroy(gameObject);
|
||||||
Instantiate(boomObj, new Vector2(transform.position.x, transform.position.y),Quaternion.identity);
|
Instantiate(boomObj, new Vector2(transform.position.x, transform.position.y),Quaternion.identity);
|
||||||
break;
|
break;
|
||||||
|
case "石头":
|
||||||
|
Destroy(m_shadow.gameObject);
|
||||||
|
Destroy(gameObject);//摧毁炮弹
|
||||||
|
//如果自己是特殊的炮弹,则触发石头的程序段
|
||||||
|
if(amISpecal) other.GetComponent<Stone>().BeHitBySpecalShell();
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
33
Assets/Scripts/具象物体/Stone.cs
Normal file
33
Assets/Scripts/具象物体/Stone.cs
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class Stone : MonoBehaviour
|
||||||
|
{
|
||||||
|
//具象物体,石头
|
||||||
|
[Tooltip("投掷物堆的游戏物体,请拖入预制体。石头被剧情杀炸毁后,将生成这样一个投掷物堆")]
|
||||||
|
public GameObject missile;
|
||||||
|
//炮弹是触发器,在这里写碰撞没用
|
||||||
|
// void OnCollisionEnter2D(Collision2D other)
|
||||||
|
// {
|
||||||
|
// Debug.Log("被"+other.transform.name+"给锤了");
|
||||||
|
// if(other.transform.tag == "炮弹")//如果被炮弹锤了
|
||||||
|
// {
|
||||||
|
// //因为可能是普通的炮弹锤了这个石头,所以给炮弹加个标识吧,是特殊的炮弹才能炸烂这个石头
|
||||||
|
// if(other.transform.GetComponent<Shell>().AmISpecal())
|
||||||
|
// {
|
||||||
|
// Instantiate(missile,transform.position,Quaternion.identity);//原地生成投掷物堆
|
||||||
|
// Destroy(other.gameObject);
|
||||||
|
// Destroy(gameObject);//被特殊炮弹锤了,销毁炮弹和自己
|
||||||
|
// }
|
||||||
|
// Destroy(other.gameObject);//被锤了以后,销毁那个炮弹
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
|
//如果被特殊炮弹击中
|
||||||
|
public void BeHitBySpecalShell()
|
||||||
|
{
|
||||||
|
Instantiate(missile,transform.position,Quaternion.identity);//原地生成投掷物堆
|
||||||
|
Destroy(gameObject);
|
||||||
|
}
|
||||||
|
}
|
11
Assets/Scripts/具象物体/Stone.cs.meta
Normal file
11
Assets/Scripts/具象物体/Stone.cs.meta
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 150efca3e442f4943b2d1e4aa6a772c5
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
@ -2,6 +2,7 @@ using System.Collections;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.UI;
|
using UnityEngine.UI;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
public class TelephoneLine : Interactive
|
public class TelephoneLine : Interactive
|
||||||
{
|
{
|
||||||
@ -10,14 +11,18 @@ public class TelephoneLine : Interactive
|
|||||||
private float allNeedTime;
|
private float allNeedTime;
|
||||||
private float hasReparedTime = 0f;
|
private float hasReparedTime = 0f;
|
||||||
private bool isReparing = false;
|
private bool isReparing = false;
|
||||||
public bool isRepared = false;
|
[SerializeField][ReadOnly]
|
||||||
|
private bool isRepared = false;
|
||||||
IndexRecoder indexRecoder;
|
IndexRecoder indexRecoder;
|
||||||
private float process = 0f;
|
private float process = 0f;
|
||||||
|
[Tooltip("特殊电话线用,拖入这个电话线修好后的事件")]
|
||||||
|
public Event endEvent;
|
||||||
|
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
indexRecoder = FindObjectOfType<IndexRecoder>();
|
indexRecoder = FindObjectOfType<IndexRecoder>();
|
||||||
allNeedTime = indexRecoder.TelephoneNeedTime;
|
allNeedTime = indexRecoder.TelephoneNeedTime;
|
||||||
|
m_interface = GameObject.Find("Canvas").transform.Find("修电话线界面").gameObject;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update is called once per frame
|
// Update is called once per frame
|
||||||
@ -31,10 +36,11 @@ public class TelephoneLine : Interactive
|
|||||||
//检查是否满了
|
//检查是否满了
|
||||||
if(process >= 1f)
|
if(process >= 1f)
|
||||||
{
|
{
|
||||||
isRepared = true;
|
isRepared = true;//标记自己已经被修好
|
||||||
FindObjectOfType<AllLinesInfo>().OKCount++;
|
FindObjectOfType<AllLinesInfo>().OKCount++;//找到总线信息,给好了的电话线+1
|
||||||
Debug.Log("满了,这个修好了");
|
Debug.Log("满了,这个修好了");
|
||||||
OnStopReparing();
|
OnStopReparing();//关下UI
|
||||||
|
if(endEvent != null) endEvent.OnCall();//如果有结束事件,那触发一下结束事件
|
||||||
}
|
}
|
||||||
//还要更新UI上的进度条
|
//还要更新UI上的进度条
|
||||||
for(int i = 0; i < m_interface.transform.childCount; i++)
|
for(int i = 0; i < m_interface.transform.childCount; i++)
|
||||||
@ -45,7 +51,7 @@ public class TelephoneLine : Interactive
|
|||||||
|
|
||||||
public override void OnCall()
|
public override void OnCall()
|
||||||
{
|
{
|
||||||
//象征着按下交互键了,如果这个还没被修改,即刻开始修复电话线
|
//象征着按下交互键了,如果这个还没被修好,即刻开始修复电话线
|
||||||
if(!isRepared)
|
if(!isRepared)
|
||||||
{
|
{
|
||||||
m_interface.SetActive(true);
|
m_interface.SetActive(true);
|
||||||
@ -64,8 +70,30 @@ public class TelephoneLine : Interactive
|
|||||||
OnStopReparing();
|
OnStopReparing();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//当此电话线修好了
|
||||||
private void OnStopReparing()
|
private void OnStopReparing()
|
||||||
{
|
{
|
||||||
m_interface.SetActive(false);
|
m_interface.SetActive(false);//关闭修电话线的UI
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//制造一个只读的变量,不要动这些
|
||||||
|
public class ReadOnlyAttribute : PropertyAttribute{}
|
||||||
|
[CustomPropertyDrawer(typeof(ReadOnlyAttribute))]
|
||||||
|
public class ReadOnlyDrawer : PropertyDrawer
|
||||||
|
{
|
||||||
|
public override float GetPropertyHeight(SerializedProperty property, GUIContent label)
|
||||||
|
{
|
||||||
|
return EditorGUI.GetPropertyHeight(property, label, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void OnGUI(Rect position, SerializedProperty property, GUIContent label)
|
||||||
|
{
|
||||||
|
GUI.enabled = false;
|
||||||
|
EditorGUI.PropertyField(position, property, label, true);
|
||||||
|
GUI.enabled = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
//
|
||||||
|
}
|
||||||
|
@ -8,8 +8,9 @@ public class BombingArea : MonoBehaviour
|
|||||||
// Start is called before the first frame update
|
// Start is called before the first frame update
|
||||||
private bool bombing = false;//是否正在轰炸
|
private bool bombing = false;//是否正在轰炸
|
||||||
public GameObject shell;//炮弹游戏物体
|
public GameObject shell;//炮弹游戏物体
|
||||||
// [Tooltip("炮弹阴影Y轴的偏移量")]
|
|
||||||
// public float shellShadowYOffset;//炮弹阴影Y轴的偏移量,因为复杂原因,必须使用此变量调整阴影的Y位置
|
[Tooltip("炮弹阴影Y轴的偏移量")]
|
||||||
|
public float shellShadowYOffset;//炮弹阴影Y轴的偏移量,因为复杂原因,必须使用此变量调整阴影的Y位置
|
||||||
|
|
||||||
private float minimumTimeInterval;
|
private float minimumTimeInterval;
|
||||||
private float maximumTimeInterval;//生成炮弹的最小和最大时间间隔
|
private float maximumTimeInterval;//生成炮弹的最小和最大时间间隔
|
||||||
@ -46,11 +47,12 @@ public class BombingArea : MonoBehaviour
|
|||||||
{
|
{
|
||||||
if(leftTime <= 0f)
|
if(leftTime <= 0f)
|
||||||
{
|
{
|
||||||
Instantiate(shell,//生成炮弹
|
GameObject ThisShell = Instantiate(shell,//生成炮弹
|
||||||
player.transform.position + //以玩家位置
|
player.transform.position + //以玩家位置
|
||||||
new Vector3(Random.Range(-maxOffSetOfShell,maxOffSetOfShell),//加上水平方向的偏移量
|
new Vector3(Random.Range(-maxOffSetOfShell,maxOffSetOfShell),//加上水平方向的偏移量
|
||||||
shellHeight,0),//竖直方向给高度
|
shellHeight,0),//竖直方向给高度
|
||||||
Quaternion.identity);
|
Quaternion.identity);
|
||||||
|
ThisShell.GetComponent<Shell>().M_BombingArea = this;//给子弹赋以自身,让其好获取Y轴偏移量
|
||||||
leftTime = Random.Range(minimumTimeInterval,maximumTimeInterval);
|
leftTime = Random.Range(minimumTimeInterval,maximumTimeInterval);
|
||||||
}
|
}
|
||||||
else leftTime -= Time.deltaTime;
|
else leftTime -= Time.deltaTime;
|
||||||
|
@ -5,7 +5,6 @@ using UnityEngine.UI;
|
|||||||
|
|
||||||
public class Interactive : MonoBehaviour
|
public class Interactive : MonoBehaviour
|
||||||
{
|
{
|
||||||
// Start is called before the first frame update
|
|
||||||
//这是所有可交互物体的基类
|
//这是所有可交互物体的基类
|
||||||
public GameObject m_interface;//可交互物体一般都和一个UI界面挂钩,这就是那个UI界面
|
public GameObject m_interface;//可交互物体一般都和一个UI界面挂钩,这就是那个UI界面
|
||||||
|
|
||||||
@ -33,7 +32,8 @@ public class Interactive : MonoBehaviour
|
|||||||
//
|
//
|
||||||
|
|
||||||
//以下为针对各具体可交互对象的虚拟函数,在具体物体中重写
|
//以下为针对各具体可交互对象的虚拟函数,在具体物体中重写
|
||||||
public virtual void Coding(string temp){}
|
public virtual void Coding(string temp){}//电报机的打码
|
||||||
public virtual void StopRepareTheTelephoneLine(){}
|
public virtual void StopRepareTheTelephoneLine(){}//电话线的停止修复(松开按键检测
|
||||||
|
public virtual void Quit(){}//任务书的关闭
|
||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
@ -7,6 +7,8 @@ TagManager:
|
|||||||
- "\u8FDB\u5EA6\u6761"
|
- "\u8FDB\u5EA6\u6761"
|
||||||
- "\u5730\u9762"
|
- "\u5730\u9762"
|
||||||
- "\u6295\u63B7\u7269"
|
- "\u6295\u63B7\u7269"
|
||||||
|
- "\u70AE\u5F39"
|
||||||
|
- "\u77F3\u5934"
|
||||||
layers:
|
layers:
|
||||||
- Default
|
- Default
|
||||||
- TransparentFX
|
- TransparentFX
|
||||||
|
@ -24,13 +24,13 @@ EditorUserSettings:
|
|||||||
value: 22424703114646680e0b0227036cdafade90ecf1aafdcdb8e2dc99eb0c69f6dc6a20dea7f234362820
|
value: 22424703114646680e0b0227036cdafade90ecf1aafdcdb8e2dc99eb0c69f6dc6a20dea7f234362820
|
||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-6:
|
RecentlyUsedScenePath-6:
|
||||||
value: 22424703114646680e0b0227036cdae0f290dfc7abfbfdb7f6d69be60968fbcd663fd8601ed2bad4ce4cfa320d2a18
|
value: 22424703114646680e0b0227036cdacaf990d3ea61ade8e6a9f1d07df7ee3d2cfb
|
||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-7:
|
RecentlyUsedScenePath-7:
|
||||||
value: 22424703114646680e0b0227036cdacaf990d3ea61aecec8a8d5c77df7ee3d2cfb
|
value: 22424703114646680e0b0227036cdae0f290dfc7abfbfdb7f6d69be60968fbcd663fd8601ed2bad4ce4cfa320d2a18
|
||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-8:
|
RecentlyUsedScenePath-8:
|
||||||
value: 22424703114646680e0b0227036cdacaf990d3ea61ade8e6a9f1d07df7ee3d2cfb
|
value: 22424703114646680e0b0227036cdacaf990d3ea61aecec8a8d5c77df7ee3d2cfb
|
||||||
flags: 0
|
flags: 0
|
||||||
RecentlyUsedScenePath-9:
|
RecentlyUsedScenePath-9:
|
||||||
value: 22424703114646680e0b0227036cd8dcda93c0caa9cdf57e38271427fb
|
value: 22424703114646680e0b0227036cd8dcda93c0caa9cdf57e38271427fb
|
||||||
|
Loading…
x
Reference in New Issue
Block a user