fix byte order in seed debug print

This commit is contained in:
p2r3
2025-08-21 03:06:28 +03:00
parent 8963b83bff
commit afb3680c24

View File

@@ -346,11 +346,11 @@ int main () {
// Hash the seeds to ensure they're random enough // Hash the seeds to ensure they're random enough
world_seed = splitmix64(world_seed); world_seed = splitmix64(world_seed);
printf("World seed: "); printf("World seed: ");
for (int i = 0; i < 4; i ++) printf("%X", (unsigned int)((world_seed >> (8 * i)) & 255)); for (int i = 3; i >= 0; i --) printf("%X", (unsigned int)((world_seed >> (8 * i)) & 255));
rng_seed = splitmix64(rng_seed); rng_seed = splitmix64(rng_seed);
printf("\nRNG seed: "); printf("\nRNG seed: ");
for (int i = 0; i < 4; i ++) printf("%X", (unsigned int)((rng_seed >> (8 * i)) & 255)); for (int i = 3; i >= 0; i --) printf("%X", (unsigned int)((rng_seed >> (8 * i)) & 255));
printf("\n\n"); printf("\n\n");
for (int i = 0; i < sizeof(block_changes) / sizeof(BlockChange); i ++) { for (int i = 0; i < sizeof(block_changes) / sizeof(BlockChange); i ++) {