Parcourir la source

删除hitcols

SZAND\msx_2 il y a 1 an
Parent
commit
1e6671177f

+ 41 - 121
ActionTowerDefense/Assets/Resources/Prefab/Boss/Boss_YuMenGuan.prefab

@@ -33,72 +33,6 @@ Transform:
   m_Father: {fileID: 5440846222648032754}
   m_RootOrder: 0
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
---- !u!1 &1322232727721152541
-GameObject:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  serializedVersion: 6
-  m_Component:
-  - component: {fileID: 8927539278125731317}
-  - component: {fileID: 77275286589392561}
-  - component: {fileID: 7729941002223262554}
-  m_Layer: 0
-  m_Name: AttackTrigger
-  m_TagString: Untagged
-  m_Icon: {fileID: 0}
-  m_NavMeshLayer: 0
-  m_StaticEditorFlags: 0
-  m_IsActive: 0
---- !u!4 &8927539278125731317
-Transform:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  m_GameObject: {fileID: 1322232727721152541}
-  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_ConstrainProportionsScale: 0
-  m_Children: []
-  m_Father: {fileID: 901824162977467732}
-  m_RootOrder: 3
-  m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
---- !u!65 &77275286589392561
-BoxCollider:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  m_GameObject: {fileID: 1322232727721152541}
-  m_Material: {fileID: 0}
-  m_IsTrigger: 1
-  m_Enabled: 1
-  serializedVersion: 2
-  m_Size: {x: 2, y: 4, z: 20}
-  m_Center: {x: -2, y: 2, z: 0}
---- !u!114 &7729941002223262554
-MonoBehaviour:
-  m_ObjectHideFlags: 0
-  m_CorrespondingSourceObject: {fileID: 0}
-  m_PrefabInstance: {fileID: 0}
-  m_PrefabAsset: {fileID: 0}
-  m_GameObject: {fileID: 1322232727721152541}
-  m_Enabled: 1
-  m_EditorHideFlags: 0
-  m_Script: {fileID: 11500000, guid: 5eaed0a6b9d6fc6409bef80cf41a0a8e, type: 3}
-  m_Name: 
-  m_EditorClassIdentifier: 
-  owner: {fileID: 0}
-  trigedObjs: []
-  damage: 0
-  force: {x: 0, y: 0, z: 0}
-  changeHurt: 0
-  repelValue: 0
-  offsetY: 1
-  hitRate: 1
 --- !u!1 &2460330936527559963
 GameObject:
   m_ObjectHideFlags: 0
@@ -130,7 +64,7 @@ Transform:
   m_ConstrainProportionsScale: 0
   m_Children: []
   m_Father: {fileID: 901824162977467732}
-  m_RootOrder: 4
+  m_RootOrder: 3
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
 --- !u!65 &5217712517297835056
 BoxCollider:
@@ -294,7 +228,6 @@ Transform:
   - {fileID: 5669356131851076493}
   - {fileID: 5440846222604650428}
   - {fileID: 6207242290232856985}
-  - {fileID: 8927539278125731317}
   - {fileID: 6069085609270885073}
   m_Father: {fileID: 6459001683917408033}
   m_RootOrder: 1
@@ -444,11 +377,6 @@ MonoBehaviour:
   m_Script: {fileID: 11500000, guid: 61f2b89ad5048f1429e0645f7157eba5, type: 3}
   m_Name: 
   m_EditorClassIdentifier: 
-  isTran: 0
-  pc: {fileID: 0}
-  isSpirit: 0
-  HitCols: []
-  cookNum: 0
   mecanim: {fileID: 7573527827155227431}
   meshRenderer: {fileID: 0}
   ani: {fileID: 3333436509305836838}
@@ -456,83 +384,80 @@ MonoBehaviour:
   rb: {fileID: 5440846222648032765}
   bodyTrans: {fileID: 6459001683917408033}
   beSearchTrigger: {fileID: 4259433079752244006}
+  searchTrigger: {fileID: 2932762729738363159}
   beHitTrigger: {fileID: 3377671071202039733}
   bodyCollider: {fileID: 4543619153787591511}
   uiHp: {fileID: 478072938412589135}
   state: 0
+  totalHp: 10000
+  hp: 0
+  isDie: 0
+  isRevive: 0
+  linked: 0
+  canNotAddForce: 0
+  canNotChangeHurt: 0
+  invincibleTime: 0
+  totalDieKeepTime: 2
+  dieKeepTime: 0
+  canHitFly: 0
+  isNonAttack: 0
   attackTime: 0
   totalAttack1Time: 0.5
   totalAttack2Time: 0.5
-  isNonAttack: 0
-  hptp: 0
-  isDie: 0
-  isRevive: 0
-  totalHp: 1000
-  hp: 0
-  attack1Infos: []
-  attack2Infos: []
-  attackTriggers:
-  - {fileID: 7729941002223262554}
   attackType: 0
   bulletPrefab: {fileID: 0}
   shootPos: []
-  dieKeepTime: 0
-  totalDieKeepTime: 2
-  attackTarget: {fileID: 0}
   shootTrack: 0
-  invincibleTime: 0
+  attack1Infos: []
+  attack2Infos: []
+  attackTriggers:
+  - {fileID: 0}
+  targetTypes: 0100000002000000
   targetCharacter: {fileID: 0}
+  attackTarget: {fileID: 0}
   beTargetCharacter: []
-  searchTrigger: {fileID: 2932762729738363159}
-  targetTypes: 0100000002000000
-  canHitFly: 0
-  linked: 0
+  HitCols: []
+  isSpirit: 0
+  isTran: 0
+  pc: {fileID: 0}
+  hptp: 0
   joint: {fileID: 0}
   rope: {fileID: 0}
-  hasHpUp: 0
   beLarger: 0
-  canHitFloat: 0
-  floatProbability: 0
-  attackToFloat: 0
-  floatTimes: 0
-  hasFloatTimes: 0
-  criticalChance: 0
-  criticalMultiplier: 0
   cookEffect: {fileID: 0}
-  canMove: 1
+  matState: 1
+  spinee: {fileID: 0}
+  mesh: {fileID: 0}
+  mats: []
+  outlineMats: []
+  outline1Mats: []
   foot: {fileID: 0}
   extraRiseGravity: 0
   extraFallGravity: -10
+  canMove: 1
   moveSpeed: 5
-  beRepelValue: 0
   totalBeRepelValue: 0
+  beRepelValue: 0
   weakTime: 0
   totalWeakTime: 0
-  decelerationRatio: 1
   weakHitRate: 2
+  easyToGetHit: 0.2
+  isDamageReduction: 0
+  reductionDegree: 0
+  reductionEffect: {fileID: 0}
+  decelerationRatio: 1
   comaTime: 5
   pastComaTime: 0
-  isCaughtByCook: 0
-  isBeDropped: 0
+  floatState: 0
   maxTime: 1.5
   minTime: 0.1
   maxHeight: 12
   minHeight: 7
+  floatTime: 20
   maxRotateSpeed: 20
   minRotateSpeed: 5
-  floatTime: 20
   isFloat: 0
-  dropDamage: 0
   normalFallSpeed: 0
-  rapidFallSpeed: 0
-  curFallSpeed: 0
-  floatState: 0
-  matState: 1
-  spinee: {fileID: 0}
-  mesh: {fileID: 0}
-  mats: []
-  outlineMats: []
-  outline1Mats: []
   playerMe: {fileID: 0}
   playerAni: {fileID: 0}
   playerCol: {fileID: 0}
@@ -545,19 +470,14 @@ MonoBehaviour:
   playerMesh: {fileID: 0}
   playerMats: []
   playerOut: []
-  canNotChangeHurt: 0
   soulPrefab: {fileID: 0}
   soulStartSpeed: 1
   isInvisible: 0
   invisibleTime: 0
   velocityAddition: 0
-  transmitTime: 0
   haveTransmit: 0
+  transmitTime: 0
   portalsController: {fileID: 0}
-  easyToGetHit: 0.2
-  isDamageReduction: 0
-  reductionDegree: 0
-  reductionEffect: {fileID: 0}
 --- !u!1 &6139679835290116115
 GameObject:
   m_ObjectHideFlags: 0

+ 0 - 3
ActionTowerDefense/Assets/Scripts/Character.cs

@@ -108,9 +108,6 @@ public class Character : MonoBehaviour
     public Character attackTarget;
     public List<Character> beTargetCharacter = new List<Character>(); //被哪些锁定
 
-    [Header("被攻击的触发器")]
-    public GameObject[] HitCols;
-
     [Header("是否为英灵、是否为变身形态英灵")]
     public bool isSpirit;
     public bool isTran;

+ 0 - 4
ActionTowerDefense/Assets/Scripts/Demonic.cs

@@ -588,10 +588,6 @@ public class Demonic : MoveCharacter
             //    break;
             case CharacterState.Coma:
                 canMove = true;
-                foreach(GameObject i in HitCols)
-                {
-                    i.SetActive(true);
-                }
                 break;
             case CharacterState.Attack:
                 aniCollider.Play("NotAttack", 1, 0);

+ 0 - 8
ActionTowerDefense/Assets/Scripts/Enemy.cs

@@ -649,10 +649,6 @@ public class Enemy : MoveCharacter
                 break;
             case CharacterState.Coma:
                 canMove = true;
-                foreach (GameObject i in HitCols)
-                {
-                    i.SetActive(true);
-                }
                 break;
             case CharacterState.FindPlayer:
                 noOnSearchState = false;
@@ -731,10 +727,6 @@ public class Enemy : MoveCharacter
                 ani.Play("idle", 0, 0);
                 aniCollider.Play("Idle", 0, 0);
                 rb.velocity = Vector3.zero;
-                foreach (GameObject i in HitCols)
-                {
-                    i.SetActive(false);
-                }
                 pastComaTime = 0;
                 break;
             case CharacterState.Attack:

+ 0 - 8
ActionTowerDefense/Assets/Scripts/PlayerController.cs

@@ -1481,10 +1481,6 @@ public class PlayerController : MoveCharacter
             //    break;
             case CharacterState.Coma:
                 canMove = true;
-                foreach (GameObject i in HitCols)
-                {
-                    i.SetActive(true);
-                }
                 break;
             case CharacterState.Attack:
                 aniCollider.Play("NotAttack", 1, 0);
@@ -1560,10 +1556,6 @@ public class PlayerController : MoveCharacter
                 ani.Play("idle", 0, 0);
                 aniCollider.Play("Idle", 0, 0);
                 rb.velocity = Vector3.zero;
-                foreach (GameObject i in HitCols)
-                {
-                    i.SetActive(false);
-                }
                 break;
             case CharacterState.Attack:
                 attackTime = totalAttack1Time;