From efc249329f5ca4da85485ebd54981f69ad5c36a1 Mon Sep 17 00:00:00 2001 From: clyf Date: Tue, 23 Apr 2024 07:24:27 -0400 Subject: [PATCH] add MassValueKilled stat --- lua/defaultcomponents.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lua/defaultcomponents.lua b/lua/defaultcomponents.lua index b86ca5b372..ec60d43fe6 100644 --- a/lua/defaultcomponents.lua +++ b/lua/defaultcomponents.lua @@ -607,10 +607,12 @@ VeterancyComponent = ClassSimple { -- optionally, these fields are defined too to inform UI of our veterancy status if blueprint.VetEnabled then - self:UpdateStat('VetLevel', 0) self:UpdateStat('VetExperience', 0) + self:UpdateStat('VetLevel', 0) + self:UpdateStat('MassValueKilled', 0) self.VetExperience = 0 self.VetLevel = 0 + self.MassValueKilled = 0 end end, @@ -658,6 +660,11 @@ VeterancyComponent = ClassSimple { return end + -- Update a mass value killed stat, not used + -- by veterancy but potentially useful to the player + self.MassValueKilled = self.MassValueKilled + experience + self:UpdateStat('MassValueKilled', self.MassValueKilled) + local currExperience = self.VetExperience local currLevel = self.VetLevel