Jagged Alliance 3

Jagged Alliance 3

Basic Crafting Economy
Answering a question
DefineConst{
id = "CombineFailAmmoLose",
scale = "%",
value = 20,
}
DefineConst{
id = "CombineFailConditionLose",
scale = "%",
value = 20,
}
DefineConst{
id = "CombineToolConditionLose",
scale = "%",
value = 2,
}


Invntory.lua if i'm looking at the functions:

Combine2ItemsInternal(recipe_id, outcome, outcome_hp, skill_type, unit_operator, item1_context, item1_pos, item2_context, item2_pos, item2)
-- bunch of code before; e.g. for loss of health when failing to combine or something
if IsKindOf(new_item, "ToolItem") then
local change_condition = -MulDivRound(new_item.Condition, const.CombineToolConditionLose,100)
unit_operator:ItemModifyCondition(new_item, change_condition)
end

Not sure if that's 100% the combination stuff you asked for before leaving, but i'd think so.
< >
Menampilkan 1-2 dari 2 komentar
whahappen  [pengembang] (Di-ban) 3 Nov 2023 @ 2:25am 
Thank you a lot. Just seeing this now.
whahappen  [pengembang] (Di-ban) 7 Nov 2023 @ 4:44pm 
Implemented a fixed based on Timmeh's condition modifications and your input now. Should be finally fixing the issue.

All tools have individual condition loss now.

Big thanks to Timmeh & LotR[Henchman]
Terakhir diedit oleh whahappen; 8 Nov 2023 @ 12:19am
< >
Menampilkan 1-2 dari 2 komentar
Per halaman: 1530 50