任务:修改不合理之处

1.修改石头下落的速度
(1.老兵处投掷物堆
(2.石头被炸后处
(3.碉堡处
2.修改老兵牺牲事件的导弹生成位置
3.增大了导弹爆炸动画的大小
4.修改第一关关底震晕玩家的炸弹的位置
5.修正了地面枪光的方向
This commit is contained in:
Roman 2021-09-06 23:24:37 +08:00
parent 964c70d0d8
commit 97834b7e7e
12 changed files with 277 additions and 66 deletions

View File

@ -44,6 +44,6 @@ Material:
- WaveIntensity_2: 1
- WaveSpread_Value: 0
m_Colors:
- Center: {r: 0.43595243, g: 0.25134057, b: 0, a: 0}
- Center: {r: 0.46282938, g: 0.25857604, b: 0, a: 0}
- Vector2_d2d098295fc146f08b921b231b2e5199: {r: 1.6, g: 0.9, b: 0, a: 0}
m_BuildTextureStacks: []

View File

@ -100,7 +100,7 @@ Rigidbody2D:
m_Mass: 1
m_LinearDrag: 0
m_AngularDrag: 0.05
m_GravityScale: 1
m_GravityScale: 2
m_Material: {fileID: 0}
m_Interpolate: 0
m_SleepingMode: 1
@ -134,3 +134,4 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 621395b8c0d84a847a7f7f6e059e43a0, type: 3}
m_Name:
m_EditorClassIdentifier:
amINoisy: 0

View File

@ -157,7 +157,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.13324745, y: 0.172}
m_AnchorMax: {x: 0.565, y: 0.41035822}
m_AnchoredPosition: {x: 0.80000305, y: -1.8999863}
m_AnchoredPosition: {x: 0.80000305, y: -1.9000549}
m_SizeDelta: {x: -8, y: -12}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &14316730
@ -961,7 +961,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
propertyPath: m_AnchoredPosition.y
value: -3.9000244
value: -3.9000397
objectReference: {fileID: 0}
- target: {fileID: 8233114533063075529, guid: 82d871be611f9d14fbe8c166075c1a37, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
@ -1024,7 +1024,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.13324745, y: 0.41035822}
m_AnchorMax: {x: 0.5877423, y: 0.60871625}
m_AnchoredPosition: {x: -1.1607819, y: 2.89999}
m_AnchoredPosition: {x: -1.1607971, y: 2.89999}
m_SizeDelta: {x: -12, y: -4}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &93894042
@ -1109,23 +1109,24 @@ Transform:
- {fileID: 481019693}
- {fileID: 987095759}
- {fileID: 878083525}
- {fileID: 1353699409}
- {fileID: 1329737170}
- {fileID: 361026086}
- {fileID: 1353699409}
- {fileID: 1197697321}
- {fileID: 361026086}
- {fileID: 1753032686}
- {fileID: 722416801}
- {fileID: 6516117756223022122}
- {fileID: 1837969016}
- {fileID: 1639467005}
- {fileID: 607372480}
- {fileID: 1639467005}
- {fileID: 1897824766}
- {fileID: 1538932754}
- {fileID: 928812679}
- {fileID: 1897824766}
- {fileID: 407306090}
- {fileID: 1545336352}
- {fileID: 422883215}
- {fileID: 1028058163}
- {fileID: 496996551}
m_Father: {fileID: 0}
m_RootOrder: 4
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
@ -2196,7 +2197,7 @@ Transform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 367679635}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -35.5, y: -6.3, z: 0}
m_LocalPosition: {x: 126.87, y: -2.46, z: 0}
m_LocalScale: {x: 0.39999998, y: 0.39999998, z: 0.39999998}
m_Children:
- {fileID: 1737112887496214201}
@ -12289,6 +12290,85 @@ Animator:
m_HasTransformHierarchy: 1
m_AllowConstantClipSamplingOptimization: 1
m_KeepAnimatorControllerStateOnDisable: 0
--- !u!1 &496996550
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 496996551}
- component: {fileID: 496996552}
- component: {fileID: 496996553}
m_Layer: 0
m_Name: "\u9707\u6655\u70B8\u5F39\u7206\u70B8\u70B9"
m_TagString: "\u7206\u70B8\u70B9"
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &496996551
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 496996550}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 117.59, y: -3.54, z: 0}
m_LocalScale: {x: 4.9625, y: 0.375, z: 1}
m_Children: []
m_Father: {fileID: 105534304}
m_RootOrder: 30
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!61 &496996552
BoxCollider2D:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 496996550}
m_Enabled: 1
m_Density: 1
m_Material: {fileID: 0}
m_IsTrigger: 0
m_UsedByEffector: 0
m_UsedByComposite: 0
m_Offset: {x: 0, y: 0}
m_SpriteTilingProperty:
border: {x: 0, y: 0, z: 0, w: 0}
pivot: {x: 0, y: 0}
oldSize: {x: 0, y: 0}
newSize: {x: 0, y: 0}
adaptiveTilingThreshold: 0
drawMode: 0
adaptiveTiling: 0
m_AutoTiling: 0
serializedVersion: 2
m_Size: {x: 1, y: 1}
m_EdgeRadius: 0
--- !u!50 &496996553
Rigidbody2D:
serializedVersion: 4
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 496996550}
m_BodyType: 0
m_Simulated: 1
m_UseFullKinematicContacts: 0
m_UseAutoMass: 0
m_Mass: 1
m_LinearDrag: 0
m_AngularDrag: 0.05
m_GravityScale: 1
m_Material: {fileID: 0}
m_Interpolate: 0
m_SleepingMode: 1
m_CollisionDetection: 0
m_Constraints: 7
--- !u!1 &502055429
GameObject:
m_ObjectHideFlags: 0
@ -12731,7 +12811,7 @@ Transform:
- {fileID: 365692594}
- {fileID: 985202750}
m_Father: {fileID: 105534304}
m_RootOrder: 22
m_RootOrder: 21
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &635089478
GameObject:
@ -12828,7 +12908,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!4 &635525186
Transform:
m_ObjectHideFlags: 0
@ -14936,7 +15016,7 @@ PrefabInstance:
m_Modifications:
- target: {fileID: 3118168874406839344, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
propertyPath: m_RootOrder
value: 24
value: 25
objectReference: {fileID: 0}
- target: {fileID: 3118168874406839344, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
propertyPath: m_LocalScale.x
@ -14996,7 +15076,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 3118168874406839346, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
propertyPath: srengthOfThrowing
value: 9
value: 13
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
@ -16437,7 +16517,7 @@ Transform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1142437218}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -32.56149, y: -5.299382, z: -10}
m_LocalPosition: {x: 87.39001, y: 1.3300002, z: -10}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 1608038909}
@ -16773,7 +16853,7 @@ Transform:
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 105534304}
m_RootOrder: 16
m_RootOrder: 15
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1198602020
GameObject:
@ -17682,7 +17762,7 @@ Transform:
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 105534304}
m_RootOrder: 14
m_RootOrder: 13
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1334663206 stripped
GameObject:
@ -17775,7 +17855,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 8082445130133277908, guid: fab0acc13c79e5248a20877602bd9007, type: 3}
propertyPath: m_RootOrder
value: 13
value: 14
objectReference: {fileID: 0}
- target: {fileID: 8082445130133277908, guid: fab0acc13c79e5248a20877602bd9007, type: 3}
propertyPath: m_LocalPosition.x
@ -18019,7 +18099,7 @@ PrefabInstance:
m_Modifications:
- target: {fileID: 3118168874406839344, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
propertyPath: m_RootOrder
value: 15
value: 16
objectReference: {fileID: 0}
- target: {fileID: 3118168874406839344, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
propertyPath: m_LocalScale.x
@ -18079,7 +18159,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 3118168874406839346, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
propertyPath: srengthOfThrowing
value: 13
value: 20
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: a33f3ee35358b11469af30e9a746a630, type: 3}
@ -18454,7 +18534,7 @@ Transform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1477400527}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -35.94, y: -5.91, z: -10}
m_LocalPosition: {x: 87.39001, y: 1.3300002, z: -10}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 32565896}
@ -18770,7 +18850,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 8083259778992148205, guid: 8c0eff332c2998f4a8fbaf4e2b1171db, type: 3}
propertyPath: m_RootOrder
value: 23
value: 24
objectReference: {fileID: 0}
- target: {fileID: 8083259778992148205, guid: 8c0eff332c2998f4a8fbaf4e2b1171db, type: 3}
propertyPath: m_LocalScale.x
@ -23917,7 +23997,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6148935034079004064, guid: b034a6d27e737a9438c2164815880846, type: 3}
propertyPath: m_RootOrder
value: 21
value: 22
objectReference: {fileID: 0}
- target: {fileID: 6148935034079004064, guid: b034a6d27e737a9438c2164815880846, type: 3}
propertyPath: m_LocalPosition.x
@ -24458,7 +24538,7 @@ Transform:
m_GameObject: {fileID: 1822015333}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.978, y: -0.08700002, z: 0}
m_LocalScale: {x: 0.058046598, y: 0.058046598, z: 0.058046598}
m_LocalScale: {x: -0.0580466, y: 0.058046598, z: 0.058046598}
m_Children: []
m_Father: {fileID: 1353699409}
m_RootOrder: 4
@ -29526,7 +29606,7 @@ Transform:
m_LocalScale: {x: 0.63447374, y: 0.6344737, z: 0.6344737}
m_Children: []
m_Father: {fileID: 105534304}
m_RootOrder: 25
m_RootOrder: 23
m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0}
--- !u!1 &1906947533
GameObject:
@ -29606,7 +29686,7 @@ Transform:
m_GameObject: {fileID: 1921015477}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -0.684, y: -0.097, z: 0}
m_LocalScale: {x: 0.058046598, y: 0.058046598, z: 0.058046598}
m_LocalScale: {x: -0.0580466, y: 0.058046598, z: 0.058046598}
m_Children: []
m_Father: {fileID: 1353699409}
m_RootOrder: 3
@ -29839,7 +29919,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.523, y: 0.059222218}
m_AnchorMax: {x: 0.9732738, y: 0.46247932}
m_AnchoredPosition: {x: 1.0999756, y: -0.39996338}
m_AnchoredPosition: {x: 1.0999756, y: -0.39990234}
m_SizeDelta: {x: -5.90609, y: -2.1826124}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1922630721
@ -31252,7 +31332,7 @@ MonoBehaviour:
- {fileID: 2047411004448683759}
- {fileID: 5695032862028633419}
m_Bounds:
m_Center: {x: 0.0022023916, y: -0.0058820248, z: 0}
m_Center: {x: 0.0021795034, y: -0.005879879, z: 0}
m_Extent: {x: 1.54779, y: 2.3711, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -31346,7 +31426,7 @@ Transform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4658248456436591408}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -10.4, y: -8.8, z: 0}
m_LocalPosition: {x: -108, y: -0.3, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 674795379}
@ -31405,7 +31485,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 4936508675712544306}
m_Bounds:
m_Center: {x: 0.0034700036, y: -0.0018951595, z: 0}
m_Center: {x: 0.0034700036, y: -0.0018942058, z: 0}
m_Extent: {x: 0.68153024, y: 0.4230354, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -31490,7 +31570,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 5437654542896820717}
m_Bounds:
m_Center: {x: 6.369995, y: -0.0021167994, z: 0}
m_Center: {x: 6.369995, y: -0.0021144152, z: 0}
m_Extent: {x: 0.855, y: 1.1198149, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -31573,7 +31653,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 2934879650646324577}
m_Bounds:
m_Center: {x: 0.0008273721, y: -0.0022351146, z: 0}
m_Center: {x: 0.00083500147, y: -0.0022346377, z: 0}
m_Extent: {x: 0.6941651, y: 0.8818251, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -31758,7 +31838,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 7089406931308197820}
m_Bounds:
m_Center: {x: -0.008464992, y: 0.000014662743, z: 0}
m_Center: {x: -0.00849551, y: 0.00001513958, z: 0}
m_Extent: {x: 0.55653495, y: 0.69665515, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -31829,7 +31909,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 2360827735431813924}
m_Bounds:
m_Center: {x: -0.0004426241, y: 0.00431484, z: 0}
m_Center: {x: -0.0004502535, y: 0.0043153167, z: 0}
m_Extent: {x: 0.689565, y: 0.9506854, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -32456,7 +32536,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 4718247844144699107}
m_Bounds:
m_Center: {x: 0.0019849539, y: -0.0000019073486, z: 0}
m_Center: {x: 0.0019849539, y: 0, z: 0}
m_Extent: {x: 0.57801485, y: 0.9349998, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -32494,7 +32574,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 5215891186772959842}
m_Bounds:
m_Center: {x: -0.00000011920929, y: 0.0016960502, z: 0}
m_Center: {x: -0.000015377998, y: 0.0016953349, z: 0}
m_Extent: {x: 1.1549999, y: 0.77910495, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -33247,7 +33327,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 4586288761792830837}
m_Bounds:
m_Center: {x: 0.0021800995, y: 0.0000019073486, z: 0}
m_Center: {x: 0.002149582, y: 0, z: 0}
m_Extent: {x: 0.60282004, y: 0.69500005, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -33451,7 +33531,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 6675447233366868755}
m_Bounds:
m_Center: {x: -0.000027358532, y: 0.0006029606, z: 0}
m_Center: {x: -0.000034987926, y: 0.00060522556, z: 0}
m_Extent: {x: 0.705515, y: 1.2171149, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -33542,7 +33622,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 7263140363742385229}
m_Bounds:
m_Center: {x: -0.004254937, y: 0.0007251501, z: 0}
m_Center: {x: -0.0042854548, y: 0.00072443485, z: 0}
m_Extent: {x: 0.8907454, y: 1.2819755, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -33798,7 +33878,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 3397380986102525386}
m_Bounds:
m_Center: {x: 0.0013372898, y: 0.0000019073486, z: 0}
m_Center: {x: 0.0013144016, y: 0.00000023841858, z: 0}
m_Extent: {x: 0.7836551, y: 1.035, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -33869,7 +33949,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 5215891186772959842}
m_Bounds:
m_Center: {x: 0.003039956, y: -0.0026350021, z: 0}
m_Center: {x: 0.0030246973, y: -0.0026342869, z: 0}
m_Extent: {x: 0.9919598, y: 1.2031548, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1
@ -33905,7 +33985,7 @@ MonoBehaviour:
m_BoneTransforms:
- {fileID: 8339351226288312874}
m_Bounds:
m_Center: {x: 0.0017126799, y: -0.00012481213, z: 0}
m_Center: {x: 0.0016897917, y: -0.00012528896, z: 0}
m_Extent: {x: 1.0732954, y: 1.2652456, z: 0}
m_UseBatching: 1
m_AlwaysUpdate: 1

View File

@ -345,7 +345,7 @@ public class M_Player : MonoBehaviour
line.enabled = true;
int segmentCount = 18;//定义点数
line.positionCount = segmentCount;//传入点数
float gravity=9.8f;//定义重力常量
float gravity=9.8f*2;//定义重力常量
Vector2 fireOffset = new Vector2(throwOffset.position.x - transform.position.x,
throwOffset.position.y - transform.position.y);
Vector2[] segments = new Vector2[segmentCount];//定义二维向量数组用来存15个点的位置

View File

@ -15,7 +15,7 @@ public class AfterCoding : Event
public GameObject BlackUI;
void Start()
{
//OnCall();
OnCall();
}
public override void OnCall()
{
@ -24,10 +24,11 @@ public class AfterCoding : Event
//1.关闭电报机界面
FindObjectOfType<Machine>().m_interface.SetActive(false);
//2.在玩家旁边生成一颗导弹
Shell thisShell = Instantiate(shell,new Vector3(119.539998f,5.96999979f,-4.01295185f),Quaternion.identity).
Shell thisShell = Instantiate(shell,new Vector3(116.539998f,5.96999979f,-4.01295185f),Quaternion.identity).
GetComponent<Shell>();
thisShell.M_BombingArea = bombingArea;
thisShell.YouAreSpecal();
thisShell.target = FindObjectOfType<M_Player>().GetComponent<Animator>();
//3.导弹爆炸后触发玩家死亡动画,这一段写在导弹类里面
}
//4.玩家被炸死开始执行后触发此段,镜头开始缓慢聚焦到主角

View File

@ -45,7 +45,7 @@ public class VeteranSacrifice : Event
{
//1.关闭玩家操作地图
FindObjectOfType<PlayerInput>().SwitchCurrentActionMap("NullMap");
//*让老兵转个身放置牺牲后穿模
//*让老兵转个身防止牺牲后穿模
FindObjectOfType<Veteran>().transform.localScale = new Vector3(
//x
FindObjectOfType<Veteran>().transform.localScale.x*-1,
@ -57,12 +57,14 @@ public class VeteranSacrifice : Event
//2.移动相机至老兵位置
target = new Vector3(-19.8600006f,-0.600000024f,-10f)*3;
//3.召唤一颗导弹在老兵头顶
Shell thisShell = Instantiate(shell,new Vector3(43.9799995f,10.01999998f,0),Quaternion.identity).
Shell thisShell = Instantiate(shell,new Vector3(46.9799995f,10.01999998f,0),Quaternion.identity).
GetComponent<Shell>();
thisShell.M_BombingArea = bombingArea;
thisShell.YouAreSpecal();
//4.打开老兵的碰撞体,等待播放完毕老兵死亡动画
FindObjectOfType<Veteran>().GetComponent<BoxCollider2D>().isTrigger = false;
// //4.打开老兵的碰撞体,等待播放完毕老兵死亡动画
// FindObjectOfType<Veteran>().GetComponent<BoxCollider2D>().isTrigger = false;
//*修改给炸弹的爆炸瞬间在此给这个炸弹赋予Animator的值然后在事件中触发对象的死亡动画
thisShell.target = FindObjectOfType<Veteran>().GetComponentInChildren<Animator>();
//5.若干秒后,使镜头返回主角,顺便让主角转个身
yield return new WaitForSeconds(5f);
FindObjectOfType<M_Player>().TurnAround();

View File

@ -70,12 +70,10 @@ public class Blockhouse : MonoBehaviour
{
if(!isShooting)
{
blockHouseAudio.Stop();//取消播放
warningUI.sprite = done;
}
else
{
blockHouseAudio.Play();//开始播放
warningUI.sprite = ready;
}
}
@ -100,6 +98,7 @@ public class Blockhouse : MonoBehaviour
{
if(isShooting)//如果在开火
{
blockHouseAudio.Stop();
isShooting = false;//别让它开了
//关闭所有动画组件的开火动画
foreach(Animator fire in fireAnimations)
@ -109,6 +108,7 @@ public class Blockhouse : MonoBehaviour
}
else//如果没在开火
{
blockHouseAudio.Play();
isShooting = true;//标记让它开火
//打开所有动画组件的开火动画

View File

@ -22,6 +22,7 @@ public class Shell : MonoBehaviour
public float MaxShadowSize;
[Tooltip("请填入阴影的最小值")]
public float MinShadowSize;
public Animator target;//如果是特殊炮弹则有targe这个变量当这个炮弹爆炸触发目标的死亡动画
void Start()
{
@ -100,7 +101,7 @@ public class Shell : MonoBehaviour
void OnTriggerEnter2D(Collider2D other)
{
//Debug.Log(other.name);
//当玩家被炮弹击中
//当炮弹爆炸根据目标物体的tag分化
switch (other.tag)
{
case "Player":
@ -129,14 +130,23 @@ public class Shell : MonoBehaviour
isDroping = false;
other.transform.Find("老兵").GetComponent<Animator>().SetBool("IsBoomDead",true);//执行老兵被炸死动画
break;
case "电报机":
// case "电报机":
// animator.SetBool("IsBoom",true);
// isDroping = false;//播放爆炸动画
// FindObjectOfType<M_Player>().GetComponent<Animator>().
// SetBool("IsBoomDead",true);//播放玩家被炸死动画
// FindObjectOfType<AfterCoding>().OnDeadAnimation();
// break;
case "爆炸点":
animator.SetBool("IsBoom",true);
isDroping = false;//播放爆炸动画
FindObjectOfType<M_Player>().GetComponent<Animator>().
SetBool("IsBoomDead",true);//播放玩家被炸死动画
FindObjectOfType<AfterCoding>().OnDeadAnimation();
break;
}
if(amISpecal)
{
if(target!=null)target.SetBool("IsBoomDead",true);
}
}

View File

@ -28,7 +28,7 @@ public class Stone : MonoBehaviour
MissileHeap heap = Instantiate(missile,
down(transform.position),
Quaternion.identity).GetComponent<MissileHeap>();//原地生成投掷物堆,并获取其投掷物堆控制组件
heap.srengthOfThrowing = 10;
heap.srengthOfThrowing = 15;//修改生成投掷物堆的力度
Destroy(gameObject);
}
}

View File

@ -15,7 +15,32 @@ AnimationClip:
m_CompressedRotationCurves: []
m_EulerCurves: []
m_PositionCurves: []
m_ScaleCurves: []
m_ScaleCurves:
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: {x: 2, y: 2, z: 2}
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: 0.81666666
value: {x: 2, y: 2, z: 2}
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_FloatCurves: []
m_PPtrCurves:
- curve:
@ -61,6 +86,13 @@ AnimationClip:
typeID: 212
customType: 23
isPPtrCurve: 1
- serializedVersion: 2
path: 0
attribute: 3
script: {fileID: 0}
typeID: 4
customType: 0
isPPtrCurve: 0
pptrCurveMapping:
- {fileID: 21300000, guid: 0192dfd6e3d693c4885fde6d578a7e4e, type: 3}
- {fileID: 21300000, guid: dd3f5c2814e614744a3c553ed12c4324, type: 3}
@ -94,7 +126,91 @@ AnimationClip:
m_KeepOriginalPositionXZ: 0
m_HeightFromFeet: 0
m_Mirror: 0
m_EditorCurves: []
m_EditorCurves:
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 2
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 0.81666666
value: 2
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_LocalScale.x
path:
classID: 4
script: {fileID: 0}
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 2
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 0.81666666
value: 2
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_LocalScale.y
path:
classID: 4
script: {fileID: 0}
- curve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 2
inSlope: 0
outSlope: 0
tangentMode: 136
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 0.81666666
value: 2
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_LocalScale.z
path:
classID: 4
script: {fileID: 0}
m_EulerEditorCurves: []
m_HasGenericRootTransform: 0
m_HasMotionFloatCurves: 0

View File

@ -12,6 +12,7 @@ TagManager:
- "\u7535\u8BDD\u7EBF"
- "\u8001\u5175"
- "\u7535\u62A5\u673A"
- "\u7206\u70B8\u70B9"
layers:
- Default
- TransparentFX

View File

@ -18,23 +18,23 @@ EditorUserSettings:
value: 22424703114646680e0b0227036cdae0f290dfc7abfbfdb7f6d69be60968fbcd663fd8601ed2bad4ce4cfa320d2a18
flags: 0
RecentlyUsedScenePath-4:
value: 22424703114646680e0b0227036cdacaf990d3ea61aecec8a8d5c77df7ee3d2cfb
value: 22424703114646680e0b0227036cdae0f290dfc7abfbfdb7f6d69be60968fbcd663fd8601ed2bad4ce4cfa320d2a18
flags: 0
RecentlyUsedScenePath-5:
value: 22424703114646680e0b0227036cdae0f290dfc7abfbfdb7f6d69be60968fbcd663fd8601ed2bad4ce4cfa320d2a18
flags: 0
RecentlyUsedScenePath-6:
value: 22424703114646680e0b0227036cd8dcda93c0caa9cdf57e38271427fb
flags: 0
RecentlyUsedScenePath-7:
value: 22424703114646680e0b0227036cdae0f290dfc7abfbfdb7f6d69be60968fbcd663fd8601ed2bad4ce4cfa320d2a18
flags: 0
RecentlyUsedScenePath-8:
value: 22424703114646680e0b0227036cdacaf990d3ea61ade8e6a9f1d07df7ee3d2cfb
flags: 0
RecentlyUsedScenePath-9:
RecentlyUsedScenePath-7:
value: 22424703114646680e0b0227036cdacaf990d3ea61aecec8a8d5c77df7ee3d2cfb
flags: 0
RecentlyUsedScenePath-8:
value: 22424703114646680e0b0227036cd8dcda93c2c6a9cdf57e38271427fb
flags: 0
RecentlyUsedScenePath-9:
value: 22424703114646680e0b0227036cd8dcda93c0caa9cdf57e38271427fb
flags: 0
UnityEditor.ShaderGraph.Blackboard:
value: 18135939215a0a5004000b0e15254b524c030a3f2964643d120d1230e9e93a3fd6e826abbd2e2d293c4ead313b08042de6030a0afa240c0d020be94c4ba95e435d8715fa32c70d15d11612dacc11fee5d3c5d1fe9ab1b1968e93e2ffcbc3e7e2f0b3ffe0e8b0be9af8ffaeffff8e85dd8390e3949c8899daa7
flags: 0