mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-04 06:00:15 +00:00
VarAction2: Optimise unknown reads from 0x11 as constant 0
This commit is contained in:
parent
6285b5823b
commit
439c1208d7
@ -846,6 +846,12 @@ void OptimiseVarAction2Adjust(VarAction2OptimiseState &state, const GrfSpecFeatu
|
||||
if (adjust.variable == 0x1C && !state.seen_procedure_call) {
|
||||
group->dsg_flags |= DSGF_REQUIRES_VAR1C;
|
||||
}
|
||||
if (adjust.variable == 0x11 || (adjust.variable == 0x7B && adjust.parameter == 0x11)) {
|
||||
adjust.variable = 0x1A;
|
||||
adjust.parameter = 0;
|
||||
adjust.shift_num = 0;
|
||||
adjust.and_mask = 0;
|
||||
}
|
||||
|
||||
VarAction2AdjustInferenceFlags non_const_var_inference = VA2AIF_NONE;
|
||||
int iteration = 32;
|
||||
|
Loading…
Reference in New Issue
Block a user