Skip to content
This repository was archived by the owner on Jan 5, 2024. It is now read-only.

Commit dd1cdc1

Browse files
GacyrGacyr
authored andcommitted
Changed TotalWoundCount to WoundCount and RemoveAnyRandomWounds to RemoveWounds
1 parent f63eb0a commit dd1cdc1

File tree

7 files changed

+17
-17
lines changed

7 files changed

+17
-17
lines changed

Base.rte/Activities/MetaFight.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -581,7 +581,7 @@ function MetaFight:StartActivity()
581581
end
582582

583583
-- Further reduce value if actors are badly damaged in terms of wounds
584-
if Act.TotalWoundCount / Act.TotalWoundLimit > 0.5 then
584+
if Act.WoundCount / Act.TotalWoundLimit > 0.5 then
585585
value = value * 0.5
586586
end
587587

Base.rte/Actors/Mecha/Medic/Medic.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function Update(self)
3333
for i = 1, #self.healTargets do
3434
local targetFound = false;
3535
local healTarget = self.healTargets[i];
36-
if healTarget and IsActor(healTarget) and (healTarget.Health < healTarget.MaxHealth or healTarget.TotalWoundCount > 0) and healTarget.Vel.Largest < 10 then
36+
if healTarget and IsActor(healTarget) and (healTarget.Health < healTarget.MaxHealth or healTarget.WoundCount > 0) and healTarget.Vel.Largest < 10 then
3737
local trace = SceneMan:ShortestDistance(self.Pos, healTarget.Pos, false);
3838
if (trace.Magnitude - healTarget.Radius) < healRange then
3939
if SceneMan:CastObstacleRay(self.Pos, trace, Vector(), Vector(), parent.ID, parent.IgnoresWhichTeam, rte.grassID, 5) < 0 then
@@ -50,7 +50,7 @@ function Update(self)
5050
MovableMan:AddParticle(cross);
5151
end
5252
if healTarget.Health >= healTarget.MaxHealth then
53-
healTarget:RemoveAnyRandomWounds(self.healStrength);
53+
healTarget:RemoveWounds(self.healStrength);
5454
end
5555
end
5656
end
@@ -60,7 +60,7 @@ function Update(self)
6060
end
6161
self.healTargets = {};
6262
for act in MovableMan.Actors do
63-
if act.Team == parent.Team and act.ID ~= parent.ID and (act.Health < act.MaxHealth or act.TotalWoundCount > 0) and act.Vel.Largest < 5 then
63+
if act.Team == parent.Team and act.ID ~= parent.ID and (act.Health < act.MaxHealth or act.WoundCount > 0) and act.Vel.Largest < 5 then
6464
local trace = SceneMan:ShortestDistance(self.Pos, act.Pos, false);
6565
if (trace.Magnitude - act.Radius) < (healRange * 0.9) then
6666
if SceneMan:CastObstacleRay(self.Pos, trace, Vector(), Vector(), parent.ID, parent.IgnoresWhichTeam, rte.airID, 3) < 0 then

Base.rte/Devices/Special/Medikit/Medikit.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,13 @@ function Update(self)
1717
break;
1818
end
1919
end
20-
if target and (target.Health < target.MaxHealth or target.TotalWoundCount > 0) then
20+
if target and (target.Health < target.MaxHealth or target.WoundCount > 0) then
2121
local strength = self.baseStrength + math.ceil(3000/(1 + math.abs(target.Mass + target.Material.StructuralIntegrity) * 0.5));
2222
if target.Health < target.MaxHealth then
2323
target.Health = math.min(target.Health + strength, target.MaxHealth);
2424
end
25-
if target.TotalWoundCount > 0 then
26-
target:RemoveAnyRandomWounds(math.ceil(strength * 0.15));
25+
if target.WoundCount > 0 then
26+
target:RemoveWounds(math.ceil(strength * 0.15));
2727
end
2828
target:FlashWhite(50);
2929
AudioMan:PlaySound("Base.rte/Sounds/GUIs/SlicePicked.wav", self.Pos);

Base.rte/Scenes/Objects/Bunkers/BunkerSystems/Docks/DropshipDock.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ function Update(self)
2323
--Heal the craft.
2424
if self.healTimer:IsPastSimMS(self.craft.Mass) then
2525
self.healTimer:Reset();
26-
if self.craft.TotalWoundCount > 0 then
27-
self.craft.Health = math.min(self.craft.Health + self.craft:RemoveAnyRandomWounds(1), self.craft.MaxHealth);
26+
if self.craft.WoundCount > 0 then
27+
self.craft.Health = math.min(self.craft.Health + self.craft:RemoveWounds(1), self.craft.MaxHealth);
2828
elseif self.craft.Health < self.craft.MaxHealth then
2929
self.craft.Health = math.min(self.craft.Health + 1, self.craft.MaxHealth);
3030
end

Base.rte/Scenes/Objects/Bunkers/BunkerSystems/Docks/RocketDock.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ function Update(self)
2323
--Heal the craft
2424
if self.healTimer:IsPastSimMS(self.craft.Mass) then
2525
self.healTimer:Reset();
26-
if self.craft.TotalWoundCount > 0 then
27-
self.craft.Health = math.min(self.craft.Health + self.craft:RemoveAnyRandomWounds(1), self.craft.MaxHealth);
26+
if self.craft.WoundCount > 0 then
27+
self.craft.Health = math.min(self.craft.Health + self.craft:RemoveWounds(1), self.craft.MaxHealth);
2828
elseif self.craft.Health < self.craft.MaxHealth then
2929
self.craft.Health = math.min(self.craft.Health + 1, self.craft.MaxHealth);
3030
end

Techion.rte/Actors/Infantry/SilverMan/Regeneration.lua

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,18 @@ function Create(self)
33
self.regenDelay = 750;
44
self.regenTimer = Timer();
55

6-
self.lastWoundCount = self.TotalWoundCount;
6+
self.lastWoundCount = self.WoundCount;
77
self.lastHealth = self.Health;
88
end
99
function Update(self)
1010
if self.regenTimer:IsPastSimMS(self.regenDelay) then
1111
self.regenTimer:Reset();
1212
if self.Health > 0 then
13-
local damageRatio = (self.TotalWoundCount - self.lastWoundCount)/self.TotalWoundLimit + (self.lastHealth - self.Health)/self.MaxHealth;
13+
local damageRatio = (self.WoundCount - self.lastWoundCount)/self.TotalWoundLimit + (self.lastHealth - self.Health)/self.MaxHealth;
1414
if damageRatio > 0 then
1515
self.regenDelay = self.regenDelay * (1 + damageRatio);
1616
else
17-
local healed = self:RemoveAnyRandomWounds(1);
17+
local healed = self:RemoveWounds(1);
1818
if healed ~= 0 and self.Health < self.MaxHealth then
1919
self:AddHealth(self.healAmount);
2020
if self.Health > self.MaxHealth then
@@ -23,7 +23,7 @@ function Update(self)
2323
end
2424
end
2525
end
26-
self.lastWoundCount = self.TotalWoundCount;
26+
self.lastWoundCount = self.WoundCount;
2727
self.lastHealth = self.Health;
2828
end
2929
end

Techion.rte/Devices/Shared/Scripts/Disintegrator.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ function Create(self)
3535
end
3636
end
3737
--Elaborate effect resistance strength calculations based on various Actor values
38-
local resistance = ((actor.Mass + size + actor.Material.StructuralIntegrity) * 0.3 + (actor.TotalWoundLimit - actor.TotalWoundCount) + actor.Health) * 0.5;
38+
local resistance = ((actor.Mass + size + actor.Material.StructuralIntegrity) * 0.3 + (actor.TotalWoundLimit - actor.WoundCount) + actor.Health) * 0.5;
3939
if resistance - strength < 0 then
4040
--Leave this Actor alone if it already has a disintegrator particle assigned to it
4141
if ToActor(target):NumberValueExists("ToDisintegrate") then
@@ -48,7 +48,7 @@ function Create(self)
4848
self.target = ToACrab(target);
4949
end
5050
self.target.Health = self.target.Health - self.target.MaxHealth;
51-
self.target:RemoveAnyRandomWounds(self.target.TotalWoundCount + 1);
51+
self.target:RemoveWounds(self.target.WoundCount + 1);
5252
self.target.MissionCritical = true; --This ensures that the target Actor doesn't settle during the effect
5353
self.target.HitsMOs = false;
5454
self.target.AngularVel = self.target.AngularVel * 0.5 - self.target.Vel.X + self.target.FlipFactor;

0 commit comments

Comments
 (0)