Fixed typo, fixed some shit on my end

This commit is contained in:
Pao
2023-01-09 23:25:58 +01:00
parent 4e4d7752f2
commit 49b3c5563a
2 changed files with 12 additions and 6 deletions

View File

@@ -203,12 +203,12 @@ function OperateArm(partName, surgeonFact, useOven)
end
end
FixDeepWound(partName)
FixDeepWound(player, partName, useOven)
player:transmitModData();
end
function FixDeepWound(partName)
function FixDeepWound(player, partName, useOven)
local a_rightArm = {"RightArm", "RightForearm", "RightHand"}
local a_rightForearm = {"RightForearm", "RightHand"}
@@ -240,11 +240,17 @@ function FixDeepWound(partName)
for k,v in pairs(chosen_array) do
local tmpBodyPart = bodyDamage:getBodyPart(TOC_getBodyPart(v));
local tmpBodyPart = player:getBodyDamage():getBodyPart(TOC_getBodyPart(v));
tmpBodyPart:setDeepWounded(false); -- Basically like stictching
tmpBodyPart:setDeepWoundTime(0);
bodyPart:setBleeding(true);
bodyPart:setBleedingTime(10); -- Reset the bleeding
if useOven then
tmpBodyPart:setBleeding(false)
tmpBodyPart:setBleedingTime(0) -- no bleeding since it's been cauterized
else
tmpBodyPart:setBleeding(true);
tmpBodyPart:setBleedingTime(10); -- Reset the bleeding
end
end

View File

@@ -38,7 +38,7 @@ function ISOperateArm:findArgs()
local weight = math.floor(self.kit:getWeight() * 10 + 0.5)
if weight == 1 then
surgeonFact = surgeonFact + 2;
elseif weight == surgeonFact2 then
elseif weight == surgeonFact then
surgeonFact = surgeonFact + 4;
elseif weight == 3 then
surgeonFact = surgeonFact + 6;