Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ Template for new versions:
- `hide-tutorials`: new ``reset`` command that will re-enable popups in the current game

## Removed
- `gui/control-panel`: removed ``craft-age-wear`` tweak for Windows users; the tweak doesn't currently load on Windows

# 51.02-r1

Expand Down
14 changes: 12 additions & 2 deletions internal/control-panel/registry.lua
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@ COMMANDS_BY_IDX = {
-- bugfix tools
{command='adamantine-cloth-wear', help_command='tweak', group='bugfix', mode='tweak', default=true,
desc='Prevents adamantine clothing from wearing out while being worn.'},
{command='craft-age-wear', help_command='tweak', group='bugfix', mode='tweak', default=true,
desc='Allows items crafted from organic materials to wear out over time.'},
-- re-inserted below for non-Windows users (where the tweak doesn't work)
-- {command='craft-age-wear', help_command='tweak', group='bugfix', mode='tweak', default=true,
-- desc='Allows items crafted from organic materials to wear out over time.'},
{command='fix/blood-del', group='bugfix', mode='run', default=true},
{command='fix/dead-units', group='bugfix', mode='repeat', default=true,
desc='Fix units still being assigned to burrows after death.',
Expand Down Expand Up @@ -139,6 +140,15 @@ COMMANDS_BY_IDX = {
{command='work-now', group='gameplay', mode='enable'},
}

-- temporary workaround for Windows users until the tweak works
if dfhack.getOSType() ~= 'windows' then
local idx = utils.linear_index(COMMANDS_BY_IDX, 'adamantine-cloth-wear', 'command') or 1
table.insert(COMMANDS_BY_IDX, idx + 1, {
command='craft-age-wear', help_command='tweak', group='bugfix', mode='tweak', default=true,
desc='Allows items crafted from organic materials to wear out over time.',
})
end

COMMANDS_BY_NAME = {}
for _,data in ipairs(COMMANDS_BY_IDX) do
COMMANDS_BY_NAME[data.command] = data
Expand Down