diff --git a/MrBigsock/Assets/Code/PlayerController.cs b/MrBigsock/Assets/Code/PlayerController.cs index 6a2ca820ac2762d4a22fae2f014e3e3c6b1ab0ae..f27bd483930b9c3e48c2e1b28c775eeb65939953 100644 --- a/MrBigsock/Assets/Code/PlayerController.cs +++ b/MrBigsock/Assets/Code/PlayerController.cs @@ -42,6 +42,7 @@ namespace BigSock { protected IAttack _testAttack; protected IAttack _testAttack2; + protected IAttack _testAttack3; protected IAbility _dodge; public DateTime NextTimeCanAttack { get; private set; } = DateTime.Now; @@ -80,8 +81,9 @@ namespace BigSock { //var tmp = PrefabService.SINGLETON; //var tmp = SpriteService.SINGLETON; - _testAttack = (IAttack) AbilityService.SINGLETON.Get(101); + _testAttack = (IAttack) AbilityService.SINGLETON.Get(104); _testAttack2 = (IAttack) AbilityService.SINGLETON.Get(102); + _testAttack3 = (IAttack) AbilityService.SINGLETON.Get(101); _dodge = AbilityService.SINGLETON.Get(201); } @@ -151,7 +153,10 @@ namespace BigSock { else if(Input.GetKeyUp(key)) { par.ChargeTime = Time.time - chargeStarts[key]; var t = ability.Use(par); - if(!t) Debug.Log($"[PlayerController.CheckAbilityInput({key})] {ability.Name} not fired ({par.ChargeTime}/{ability.MinCharge})"); + if(!t) { + if(par.ChargeTime < ability.MinCharge) + Debug.Log($"[PlayerController.CheckAbilityInput({key})] {ability.Name} not fired ({par.ChargeTime:N3} < {ability.MinCharge:N3})"); + } } break; default: @@ -184,6 +189,7 @@ namespace BigSock { CheckAbilityInput(KeyCode.Z, _testAttack2); // Check ability 3. CheckAbilityInput(KeyCode.X, _dodge); + CheckAbilityInput(KeyCode.C, _testAttack3); //if(Input.GetKeyDown(KeyCode.Z)) Debug.Log($"[PlayerController.Update()] Z was pressed.");