You've already forked taptap2024_GJ_chidouren
updat core
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using Sirenix.OdinInspector;
|
||||
using System.Collections.Generic;
|
||||
using Sirenix.OdinInspector;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Game.Component
|
||||
@@ -14,6 +15,8 @@ namespace Game.Component
|
||||
|
||||
[LabelText ("当前完成数:")] private int _currentConditionNumber = 0;
|
||||
|
||||
private List<EnemyEntity> _enemyEntities;
|
||||
|
||||
|
||||
public bool IsComplete => _currentConditionNumber >= completeConditionNumber;
|
||||
|
||||
@@ -22,5 +25,21 @@ namespace Game.Component
|
||||
this._currentConditionNumber += number;
|
||||
return _currentConditionNumber >= completeConditionNumber;
|
||||
}
|
||||
|
||||
public void RefreshInit ()
|
||||
{
|
||||
this._currentConditionNumber = 0;
|
||||
foreach (var enemyEntity in this._enemyEntities)
|
||||
{
|
||||
enemyEntity.ResetState ();
|
||||
}
|
||||
}
|
||||
|
||||
public void InitPart ()
|
||||
{
|
||||
this._enemyEntities = new List<EnemyEntity> ();
|
||||
this._enemyEntities = new List<EnemyEntity> (transform.GetComponentsInChildren<EnemyEntity> (true));
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user