Skip to content

Commit

Permalink
Add chicken bit to allow test/exec mismatch for all commands
Browse files Browse the repository at this point in the history
  • Loading branch information
JGRennison committed Sep 22, 2023
1 parent ed75592 commit 338dff0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/command.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1156,7 +1156,7 @@ CommandCost DoCommandPInternal(TileIndex tile, uint32 p1, uint32 p2, uint64 p3,
Backup<CompanyID> cur_company(_current_company, FILE_LINE);
if (exec_as_spectator) cur_company.Change(COMPANY_SPECTATOR);

bool test_and_exec_can_differ = (cmd_flags & CMD_NO_TEST) != 0;
bool test_and_exec_can_differ = ((cmd_flags & CMD_NO_TEST) != 0) || HasChickenBit(DCBF_CMD_NO_TEST_ALL);

GameRandomSeedChecker random_state;

Expand Down
1 change: 1 addition & 0 deletions src/debug_settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ enum ChickenBitFlags {
DCBF_DESYNC_CHECK_POST_COMMAND = 3,
DCBF_DESYNC_CHECK_NO_GENERAL = 4,
DCBF_DESYNC_CHECK_PERIODIC_SIGNALS = 5,
DCBF_CMD_NO_TEST_ALL = 6,
};

inline bool HasChickenBit(ChickenBitFlags flag)
Expand Down

0 comments on commit 338dff0

Please sign in to comment.