diff --git a/Assets/Scripts/AI/AI_BotController.cs b/Assets/Scripts/AI/AI_BotController.cs index 64b44bee..2fe209c8 100644 --- a/Assets/Scripts/AI/AI_BotController.cs +++ b/Assets/Scripts/AI/AI_BotController.cs @@ -454,16 +454,6 @@ public class AI_BotController : MonoBehaviour private void AttackEnemy(PlayerState currentEnemy) { - /*if (currentEnemy && Vector3.Distance(currentEnemy.transform.position, transform.position) < 1.1f * TileManagment.tileOffset) - { - //Debug.Log("startAttack"); - //isAttackedOnce = true; - leftInput = Vector2.zero; - _currentFollowingPath.Clear(); - _actionTriggerSystem.TriggerAction(currentEnemy.currentTile, _playerState.defaultAction); - StartPatrolBehaviour(); - }*/ - leftInput = Vector2.zero; _currentFollowingPath.Clear(); _actionTriggerSystem.TriggerAction(currentEnemy.currentTile, _playerState.defaultAction); @@ -500,14 +490,8 @@ public class AI_BotController : MonoBehaviour } _currentFollowingPath = Pathfinding.FindPath(curentPos, target, TileManagment.levelTiles, TileManagment.tileOffset); //Debug.Log("created path to " + target); - if (_currentFollowingPath != null) - { - return true; - } - else - { - return false; - } + return _currentFollowingPath != null; + } private void MoveAlongPath() diff --git a/Assets/Scripts/Global/TileManagment.cs b/Assets/Scripts/Global/TileManagment.cs index a170fb7e..353b5319 100644 --- a/Assets/Scripts/Global/TileManagment.cs +++ b/Assets/Scripts/Global/TileManagment.cs @@ -195,7 +195,7 @@ public class TileManagment : MonoBehaviour { return resultTile; }*/ - if (position.x < 0 || position.z > 0.5f) + if (position.x < -0.5 || position.z > 0.5f) { //Debug.Log("null pos"); return null; diff --git a/ProjectSettings/ProjectSettings.asset b/ProjectSettings/ProjectSettings.asset index b0844762..513c3a30 100644 --- a/ProjectSettings/ProjectSettings.asset +++ b/ProjectSettings/ProjectSettings.asset @@ -127,7 +127,7 @@ PlayerSettings: 16:10: 1 16:9: 1 Others: 1 - bundleVersion: 0.38 + bundleVersion: 0.40 preloadedAssets: [] metroInputSource: 0 wsaTransparentSwapchain: 0