浏览代码
Merge branch 'feature/player-cane-hit-anim-variant' of https://github.com/treivize/open-project-1 into pr-bash
Merge branch 'feature/player-cane-hit-anim-variant' of https://github.com/treivize/open-project-1 into pr-bash
# Conflicts: # UOP1_Project/Assets/Prefabs/Characters/PigChef.prefab # UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/AttackTrigger.asset # UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/AttackTrigger.asset.meta # UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/AttackTrigger_OnEnter.asset # UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/AttackTrigger_OnEnter.asset.meta # UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsAttacking_False_OnEnter.asset # UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsAttacking_True_OnEnter.asset.meta/UI
Ciro Continisio
4 年前
当前提交
7ea6bfdf
共有 38 个文件被更改,包括 3366 次插入 和 207 次删除
-
156UOP1_Project/Assets/Art/Characters/PigChef/Animation/PigChef.controller
-
13UOP1_Project/Assets/Art/Characters/PlantCritter/Animation/PlantCritter.controller
-
14UOP1_Project/Assets/Art/Characters/SlimeCritter/Animation/Attack.anim
-
21UOP1_Project/Assets/Prefabs/Characters/PigChef.prefab
-
105UOP1_Project/Assets/Prefabs/Characters/PlantCritter.prefab
-
13UOP1_Project/Assets/Prefabs/Characters/SlimeCritter_Base.prefab
-
1UOP1_Project/Assets/ScriptableObjects/StateMachine/Critters/PlantCritter/States/Attack.asset
-
1UOP1_Project/Assets/ScriptableObjects/StateMachine/Critters/SlimeRockCritter/States/Attack.asset
-
2UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsTalking_False_OnExit.asset
-
2UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Conditions/Timer_AttackAnimation.asset
-
6UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/PigChef_TransitionTable.asset
-
1UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/States/Attack.asset
-
1UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/States/Idle.asset
-
1UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/States/Walking.asset
-
3UOP1_Project/Assets/Scripts/Characters/Attack.cs
-
2UOP1_Project/Assets/Scripts/Characters/Damageable.cs
-
9UOP1_Project/Assets/Scripts/Characters/Protagonist.cs
-
12UOP1_Project/Assets/Scripts/Characters/StateMachine/Conditions/IsHoldingAttackActionConditionSO.cs
-
12UOP1_Project/Assets/Scripts/Input/InputReader.cs
-
2UOP1_Project/Assets/Scripts/Characters/Attacker.cs.meta
-
1001UOP1_Project/Assets/Art/Characters/PigChef/Animation/CaneHit.anim
-
8UOP1_Project/Assets/Art/Characters/PigChef/Animation/CaneHit.anim.meta
-
1001UOP1_Project/Assets/Art/Characters/PigChef/Animation/CaneHit2.anim
-
8UOP1_Project/Assets/Art/Characters/PigChef/Animation/CaneHit2.anim.meta
-
1001UOP1_Project/Assets/Art/Characters/PlantCritter/Animation/Attack.anim
-
8UOP1_Project/Assets/Art/Characters/PlantCritter/Animation/Attack.anim.meta
-
20UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsAttacking_False_OnEnter.asset
-
8UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsAttacking_False_OnEnter.asset.meta
-
20UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsAttacking_True_OnEnter.asset
-
17UOP1_Project/Assets/Scripts/Characters/Attacker.cs
-
14UOP1_Project/Assets/ScriptableObjects/StateMachine/Critters/Actions/ActivateAttack.asset
-
8UOP1_Project/Assets/ScriptableObjects/StateMachine/Critters/Actions/ActivateAttack.asset.meta
-
14UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/ActivateWeapon.asset
-
8UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/ActivateWeapon.asset.meta
-
20UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/AttackTrigger_OnEnter.asset
-
40UOP1_Project/Assets/Scripts/Characters/StateMachine/Actions/ActivateAttackSO.cs
-
0/UOP1_Project/Assets/ScriptableObjects/StateMachine/Protagonist/Actions/IsAttacking_True_OnEnter.asset.meta
-
0/UOP1_Project/Assets/Scripts/Characters/Attacker.cs.meta
1001
UOP1_Project/Assets/Art/Characters/PigChef/Animation/CaneHit.anim
文件差异内容过多而无法显示
查看文件
文件差异内容过多而无法显示
查看文件
|
|||
fileFormatVersion: 2 |
|||
guid: 2ac155304be9e4c4b981fc59fbf0ae99 |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 0 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
1001
UOP1_Project/Assets/Art/Characters/PigChef/Animation/CaneHit2.anim
文件差异内容过多而无法显示
查看文件
文件差异内容过多而无法显示
查看文件
|
|||
fileFormatVersion: 2 |
|||
guid: 8c82fdb0da179794095b8f1f54e520ec |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 0 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
1001
UOP1_Project/Assets/Art/Characters/PlantCritter/Animation/Attack.anim
文件差异内容过多而无法显示
查看文件
文件差异内容过多而无法显示
查看文件
|
|||
fileFormatVersion: 2 |
|||
guid: d369cba3ba8337d4b8a1c2d6f5d277f1 |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 0 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
%YAML 1.1 |
|||
%TAG !u! tag:unity3d.com,2011: |
|||
--- !u!114 &11400000 |
|||
MonoBehaviour: |
|||
m_ObjectHideFlags: 0 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_GameObject: {fileID: 0} |
|||
m_Enabled: 1 |
|||
m_EditorHideFlags: 0 |
|||
m_Script: {fileID: 11500000, guid: 4c70afd7f911db7449d578cc18700875, type: 3} |
|||
m_Name: IsAttacking_False_OnEnter |
|||
m_EditorClassIdentifier: |
|||
parameterType: 0 |
|||
parameterName: IsAttacking |
|||
boolValue: 0 |
|||
intValue: 0 |
|||
floatValue: 0 |
|||
whenToRun: 0 |
|
|||
fileFormatVersion: 2 |
|||
guid: ba1e9b4d062da724c909db617eb613ae |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 0 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
%YAML 1.1 |
|||
%TAG !u! tag:unity3d.com,2011: |
|||
--- !u!114 &11400000 |
|||
MonoBehaviour: |
|||
m_ObjectHideFlags: 0 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_GameObject: {fileID: 0} |
|||
m_Enabled: 1 |
|||
m_EditorHideFlags: 0 |
|||
m_Script: {fileID: 11500000, guid: 4c70afd7f911db7449d578cc18700875, type: 3} |
|||
m_Name: IsAttacking_True_OnEnter |
|||
m_EditorClassIdentifier: |
|||
parameterType: 0 |
|||
parameterName: IsAttacking |
|||
boolValue: 1 |
|||
intValue: 0 |
|||
floatValue: 0 |
|||
whenToRun: 0 |
|
|||
using UnityEngine; |
|||
|
|||
public class Attacker : MonoBehaviour |
|||
{ |
|||
[SerializeField] |
|||
private Attack _attack; |
|||
|
|||
public void EnableWeapon() |
|||
{ |
|||
_attack.Enable = true; |
|||
} |
|||
|
|||
public void DisableWeapon() |
|||
{ |
|||
_attack.Enable = false; |
|||
} |
|||
} |
|
|||
%YAML 1.1 |
|||
%TAG !u! tag:unity3d.com,2011: |
|||
--- !u!114 &11400000 |
|||
MonoBehaviour: |
|||
m_ObjectHideFlags: 0 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_GameObject: {fileID: 0} |
|||
m_Enabled: 1 |
|||
m_EditorHideFlags: 0 |
|||
m_Script: {fileID: 11500000, guid: 505a5fc22f9d36c4592a17e08c85263d, type: 3} |
|||
m_Name: ActivateAttack |
|||
m_EditorClassIdentifier: |
|
|||
fileFormatVersion: 2 |
|||
guid: 1635753dee8f59a4495211e1f6d07835 |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 0 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
%YAML 1.1 |
|||
%TAG !u! tag:unity3d.com,2011: |
|||
--- !u!114 &11400000 |
|||
MonoBehaviour: |
|||
m_ObjectHideFlags: 0 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_GameObject: {fileID: 0} |
|||
m_Enabled: 1 |
|||
m_EditorHideFlags: 0 |
|||
m_Script: {fileID: 11500000, guid: 505a5fc22f9d36c4592a17e08c85263d, type: 3} |
|||
m_Name: ActivateWeapon |
|||
m_EditorClassIdentifier: |
|
|||
fileFormatVersion: 2 |
|||
guid: 0b38abb4ef196264188f86997cf47770 |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 0 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
%YAML 1.1 |
|||
%TAG !u! tag:unity3d.com,2011: |
|||
--- !u!114 &11400000 |
|||
MonoBehaviour: |
|||
m_ObjectHideFlags: 0 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_GameObject: {fileID: 0} |
|||
m_Enabled: 1 |
|||
m_EditorHideFlags: 0 |
|||
m_Script: {fileID: 11500000, guid: 4c70afd7f911db7449d578cc18700875, type: 3} |
|||
m_Name: AttackTrigger_OnEnter |
|||
m_EditorClassIdentifier: |
|||
parameterType: 3 |
|||
parameterName: CaneHit |
|||
boolValue: 0 |
|||
intValue: 0 |
|||
floatValue: 0 |
|||
whenToRun: 0 |
|
|||
using UnityEngine; |
|||
using UOP1.StateMachine; |
|||
using UOP1.StateMachine.ScriptableObjects; |
|||
|
|||
[CreateAssetMenu(fileName = "ActivateAttack", menuName = "State Machines/Actions/Activate Attack")] |
|||
public class ActivateAttackSO : StateActionSO |
|||
{ |
|||
protected override StateAction CreateAction() => new ActivateAttack(); |
|||
} |
|||
|
|||
public class ActivateAttack : StateAction |
|||
{ |
|||
private Attack _attack; |
|||
|
|||
public override void Awake(StateMachine stateMachine) |
|||
{ |
|||
_attack = stateMachine.gameObject.GetComponentInChildren<Attack>(); |
|||
} |
|||
|
|||
public override void OnUpdate() |
|||
{ |
|||
|
|||
} |
|||
|
|||
public override void OnStateEnter() |
|||
{ |
|||
if (_attack != null) |
|||
{ |
|||
_attack.Enable = true; |
|||
} |
|||
} |
|||
|
|||
public override void OnStateExit() |
|||
{ |
|||
if (_attack != null) |
|||
{ |
|||
_attack.Enable = false; |
|||
} |
|||
} |
|||
} |
撰写
预览
正在加载...
取消
保存
Reference in new issue