mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-16 08:52:40 +01:00
Codechange: Add AssignBit function to assign the value of a single bit (#12934)
* Codechange: Add AssignBit function to assign the value of a single bit * Codechange: Replace various uses of SB with AssignBit * Codechange: Replace various uses of SB with a constant with SetBit
This commit is contained in:
committed by
GitHub
parent
27efa57b7b
commit
e477706bf5
@@ -987,7 +987,7 @@ CommandCost CmdSetVehicleVisibility(DoCommandFlag flags, EngineID engine_id, boo
|
||||
if (!IsEngineBuildable(e->index, e->type, _current_company)) return CMD_ERROR;
|
||||
|
||||
if ((flags & DC_EXEC) != 0) {
|
||||
SB(e->company_hidden, _current_company, 1, hide ? 1 : 0);
|
||||
AssignBit(e->company_hidden, _current_company, hide);
|
||||
AddRemoveEngineFromAutoreplaceAndBuildWindows(e->type);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user