Fixed traits icons
This commit is contained in:
@@ -1,3 +1,7 @@
|
|||||||
|
0.9.12
|
||||||
|
- Fixed traits icons
|
||||||
|
- Some cleaning to the code
|
||||||
|
|
||||||
0.9.11
|
0.9.11
|
||||||
- Hotfix to cicatrization visuals
|
- Hotfix to cicatrization visuals
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,26 @@
|
|||||||
|
-- Init
|
||||||
|
function TocCutLimbForTrait(player, limbs_data, part_name)
|
||||||
|
local amputation_clothing_item = player:getInventory():AddItem("TOC.Amputation_" .. part_name)
|
||||||
|
TocSetCorrectTextureForAmputation(amputation_clothing_item, player, true)
|
||||||
|
|
||||||
|
player:setWornItem(amputation_clothing_item:getBodyLocation(), amputation_clothing_item)
|
||||||
|
limbs_data[part_name].is_cut = true
|
||||||
|
limbs_data[part_name].is_operated = true
|
||||||
|
limbs_data[part_name].is_amputation_shown = true
|
||||||
|
limbs_data[part_name].is_cicatrized = true
|
||||||
|
|
||||||
|
for _, v in pairs(limbs_data[part_name].depends_on) do
|
||||||
|
limbs_data[v].is_cut = true
|
||||||
|
limbs_data[v].is_operated = true
|
||||||
|
limbs_data[v].is_amputation_shown = false
|
||||||
|
limbs_data[v].is_cicatrized = true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
-- CutLimb
|
-- CutLimb
|
||||||
function TocCheckIfStillInfected(limbs_data)
|
function TocCheckIfStillInfected(limbs_data)
|
||||||
if limbs_data == nil then
|
if limbs_data == nil then
|
||||||
@@ -177,7 +200,7 @@ function TocFindItemInProstBodyLocation(part_name, patient)
|
|||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
-- Debug cheat
|
-- Debug cheat and update every minute for cicatrization
|
||||||
function TocFindAmputationOrProsthesisName(part_name, player, choice)
|
function TocFindAmputationOrProsthesisName(part_name, player, choice)
|
||||||
local worn_items = player:getWornItems()
|
local worn_items = player:getWornItems()
|
||||||
for i = 1, worn_items:size() - 1 do
|
for i = 1, worn_items:size() - 1 do
|
||||||
|
|||||||
@@ -130,51 +130,12 @@ function TocSetInitData(mod_data, player)
|
|||||||
|
|
||||||
-- Setup traits
|
-- Setup traits
|
||||||
if player:HasTrait("Amputee_Hand") then
|
if player:HasTrait("Amputee_Hand") then
|
||||||
|
TocCutLimbForTrait(player, mod_data.TOC.Limbs, "Left_Hand")
|
||||||
local amputation_clothing_item = player:getInventory():AddItem("TOC.Amputation_Left_Hand")
|
|
||||||
TocSetCorrectTextureForAmputation(amputation_clothing_item, player, true)
|
|
||||||
|
|
||||||
player:setWornItem(amputation_clothing_item:getBodyLocation(), amputation_clothing_item)
|
|
||||||
mod_data.TOC.Limbs.Left_Hand.is_cut = true
|
|
||||||
mod_data.TOC.Limbs.Left_Hand.is_operated = true
|
|
||||||
mod_data.TOC.Limbs.Left_Hand.is_amputation_shown = true
|
|
||||||
mod_data.TOC.Limbs.Left_Hand.is_cicatrized = true
|
|
||||||
elseif player:HasTrait("Amputee_LowerArm") then
|
elseif player:HasTrait("Amputee_LowerArm") then
|
||||||
local amputation_clothing_item = player:getInventory():AddItem("TOC.Amputation_Left_LowerArm")
|
TocCutLimbForTrait(player, mod_data.TOC.Limbs, "Left_LowerArm")
|
||||||
TocSetCorrectTextureForAmputation(amputation_clothing_item, player, true)
|
|
||||||
|
|
||||||
player:setWornItem(amputation_clothing_item:getBodyLocation(), amputation_clothing_item)
|
|
||||||
mod_data.TOC.Limbs.Left_LowerArm.is_cut = true
|
|
||||||
mod_data.TOC.Limbs.Left_LowerArm.is_operated = true
|
|
||||||
mod_data.TOC.Limbs.Left_LowerArm.is_amputation_shown = true
|
|
||||||
mod_data.TOC.Limbs.Left_LowerArm.is_cicatrized = true
|
|
||||||
|
|
||||||
for _, v in pairs(mod_data.TOC.Limbs.Left_LowerArm.depends_on) do
|
|
||||||
mod_data.TOC.Limbs[v].is_cut = true
|
|
||||||
mod_data.TOC.Limbs[v].is_operated = true
|
|
||||||
mod_data.TOC.Limbs[v].is_amputation_shown = false
|
|
||||||
mod_data.TOC.Limbs[v].is_cicatrized = true
|
|
||||||
end
|
|
||||||
elseif player:HasTrait("Amputee_UpperArm") then
|
elseif player:HasTrait("Amputee_UpperArm") then
|
||||||
local amputation_clothing_item = player:getInventory():AddItem("TOC.Amputation_Left_UpperArm")
|
TocCutLimbForTrait(player, mod_data.TOC.Limbs, "Left_UpperArm")
|
||||||
TocSetCorrectTextureForAmputation(amputation_clothing_item, player, true)
|
|
||||||
|
|
||||||
player:setWornItem(amputation_clothing_item:getBodyLocation(), amputation_clothing_item)
|
|
||||||
mod_data.TOC.Limbs.Left_UpperArm.is_cut = true
|
|
||||||
mod_data.TOC.Limbs.Left_UpperArm.is_operated = true
|
|
||||||
mod_data.TOC.Limbs.Left_UpperArm.is_amputation_shown = true
|
|
||||||
mod_data.TOC.Limbs.Left_UpperArm.is_cicatrized = true
|
|
||||||
|
|
||||||
for _, v in pairs(mod_data.TOC.Limbs.Left_UpperArm.depends_on) do
|
|
||||||
mod_data.TOC.Limbs[v].is_cut = true
|
|
||||||
mod_data.TOC.Limbs[v].is_operated = true
|
|
||||||
mod_data.TOC.Limbs[v].is_amputation_shown = false
|
|
||||||
mod_data.TOC.Limbs[v].is_cicatrized = true
|
|
||||||
end
|
end
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -6,14 +6,14 @@ UI_EN = {
|
|||||||
UI_ContextMenu_CutArm = "Cut arm",
|
UI_ContextMenu_CutArm = "Cut arm",
|
||||||
|
|
||||||
UI_prof_surgeon = "Surgeon",
|
UI_prof_surgeon = "Surgeon",
|
||||||
UI_profdesc_surgeon = "You are a surgeon! Start with all recipe of the mod the only cure.<br>You are also better to cut and operate.",
|
UI_profdesc_surgeon = "You are a surgeon! Start with all recipe of the mod the only cure.<br>Easier to amputate and operate amputees.",
|
||||||
|
|
||||||
UI_trait_Amputee_Hand = "Amputee hand",
|
UI_trait_Amputee_Hand = "Left Hand Amputated",
|
||||||
UI_trait_Amputee_Hand_desc = "Begin the game without a hand but also a metal hook.",
|
UI_trait_Amputee_Hand_desc = "You lost your left hand way before the apocalypse began.",
|
||||||
UI_trait_Amputee_LowerArm = "Amputee forearm",
|
UI_trait_Amputee_LowerArm = "Left Forearm Amputated",
|
||||||
UI_trait_Amputee_LowerArm_desc = "Begin the game without a forearm but also a metal hook.",
|
UI_trait_Amputee_LowerArm_desc = "You lost your left forearm way before the apocalypse began.",
|
||||||
UI_trait_Amputee_UpperArm = "Amputee arm",
|
UI_trait_Amputee_UpperArm = "Entire left Arm Amputated",
|
||||||
UI_trait_Amputee_UpperArm_desc = "Begin the game without an arm, good luck.",
|
UI_trait_Amputee_UpperArm_desc = "You lost your entire left arm before the apocalypse, good luck.",
|
||||||
UI_trait_Insensitive = "Insensitive to pain",
|
UI_trait_Insensitive = "Insensitive to pain",
|
||||||
UI_trait_Insensitivedesc = "Reduces maximum pain.",
|
UI_trait_Insensitivedesc = "Reduces maximum pain.",
|
||||||
|
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
2
mod.info
2
mod.info
@@ -5,5 +5,5 @@ description=Bitten? Not a problem!
|
|||||||
id=Amputation2
|
id=Amputation2
|
||||||
icon=icon.png
|
icon=icon.png
|
||||||
url=https://github.com/ZioPao/The-Only-Cure-But-Better
|
url=https://github.com/ZioPao/The-Only-Cure-But-Better
|
||||||
modversion=0.9.11
|
modversion=0.9.12
|
||||||
pzversion=41.65
|
pzversion=41.65
|
||||||
|
|||||||
Reference in New Issue
Block a user