private void FindAllEnemy(out Enemy.MonsterData[] enemies) { var guids = AssetDatabase.FindAssets("t:MonsterData"); enemies = new Enemy.MonsterData[guids.Length]; for (int i = 0; i < guids.Length; i++) { var path = AssetDatabase.GUIDToAssetPath(guids[i]); enemies[i] = AssetDatabase.LoadAssetAtPath <Enemy.MonsterData>(path); } }
private void Start() { dirMove = Vector3.right; _currentData = monsterData; TimeTickSystem.onTick += TimeOnTick; }