Codechange: Replace assert_compile macro with static_assert
This commit is contained in:
@@ -811,7 +811,7 @@ void RunTileLoop()
|
||||
static const uint32 feedbacks[] = {
|
||||
0xD8F, 0x1296, 0x2496, 0x4357, 0x8679, 0x1030E, 0x206CD, 0x403FE, 0x807B8, 0x1004B2, 0x2006A8, 0x4004B2, 0x800B87
|
||||
};
|
||||
assert_compile(lengthof(feedbacks) == 2 * MAX_MAP_SIZE_BITS - 2 * MIN_MAP_SIZE_BITS + 1);
|
||||
static_assert(lengthof(feedbacks) == 2 * MAX_MAP_SIZE_BITS - 2 * MIN_MAP_SIZE_BITS + 1);
|
||||
const uint32 feedback = feedbacks[MapLogX() + MapLogY() - 2 * MIN_MAP_SIZE_BITS];
|
||||
|
||||
/* We update every tile every 256 ticks, so divide the map size by 2^8 = 256 */
|
||||
|
Reference in New Issue
Block a user