From cde5b9761b432559f71ff62ce6d464ae78098083 Mon Sep 17 00:00:00 2001
From: Ny Bruker <robinhs@stud.ntnu.no>
Date: Tue, 1 Nov 2022 17:59:15 +0100
Subject: [PATCH] Added ability parameters for charging.

---
 .../Assets/Code/Core/Abilities/Base/AbilityParam.cs  | 12 ++++++++++++
 .../Assets/Code/Core/Abilities/Base/IAbilityParam.cs | 12 ++++++++++++
 2 files changed, 24 insertions(+)

diff --git a/MrBigsock/Assets/Code/Core/Abilities/Base/AbilityParam.cs b/MrBigsock/Assets/Code/Core/Abilities/Base/AbilityParam.cs
index 33681d7a..07c6fce9 100644
--- a/MrBigsock/Assets/Code/Core/Abilities/Base/AbilityParam.cs
+++ b/MrBigsock/Assets/Code/Core/Abilities/Base/AbilityParam.cs
@@ -29,6 +29,18 @@ namespace BigSock {
 			The character that activated the ability.
 		*/
 		public Character Actor { get; set; }
+
+		/*
+			How long the ability was charged.
+		*/
+		public float ChargeTime { get; set; }
+
+		/*
+			How much of the allowed charge was done in percent.
+			Ex.: if min is 1s, max is 3s, and the ability was charged for 2s, 
+				then 0.5 since it was charged for half the time between min and max.
+		*/
+		public float ChargeTimePercent { get; set; }
 	}
 
 }
\ No newline at end of file
diff --git a/MrBigsock/Assets/Code/Core/Abilities/Base/IAbilityParam.cs b/MrBigsock/Assets/Code/Core/Abilities/Base/IAbilityParam.cs
index 9741d187..e0b29b97 100644
--- a/MrBigsock/Assets/Code/Core/Abilities/Base/IAbilityParam.cs
+++ b/MrBigsock/Assets/Code/Core/Abilities/Base/IAbilityParam.cs
@@ -30,6 +30,18 @@ namespace BigSock {
 		*/
 		Character Actor { get; set; }
 
+		/*
+			How long the ability was charged.
+		*/
+		float ChargeTime { get; set; }
+
+		/*
+			How much of the allowed charge was done in percent.
+			Ex.: if min is 1s, max is 3s, and the ability was charged for 2s, 
+				then 0.5 since it was charged for half the time between min and max.
+		*/
+		float ChargeTimePercent { get; set; }
+
 	}
 
 }
\ No newline at end of file
-- 
GitLab