Decompile 2 functions in Source/Utility/Cipher/CipherPrimitives.cpp

Batch #16327 by youko: 2 byte-identical, 0 confirmed by peer review.

- fn_18399 StoreLittleEndian32: byte-identical
- fn_18400 LoadLittleEndian32: byte-identical

Merged automatically: every function is byte-identical to the original.
This commit is contained in:
ragnarok-clanker 2026-11-10 16:52:42 +00:00
commit 9508353044

View file

@ -595,16 +595,20 @@ unsigned int* CryptonSetKey(const unsigned int* input, unsigned int keyBits) {
// OFFSET: 0x00B0BDD0
// FUNCTION: fn_18399
void StoreLittleEndian32(unsigned int value, unsigned char* bytes) {
bytes[0] = static_cast<unsigned char>(value);
bytes[1] = static_cast<unsigned char>(value >> 8);
bytes[2] = static_cast<unsigned char>(value >> 16);
bytes[3] = static_cast<unsigned char>(value >> 24);
*bytes++ = static_cast<unsigned char>(value);
*bytes++ = static_cast<unsigned char>(value >> 8);
*bytes++ = static_cast<unsigned char>(value >> 16);
*bytes = static_cast<unsigned char>(value >> 24);
}
// OFFSET: 0x00B0C3D0
// FUNCTION: fn_18400
unsigned int LoadLittleEndian32(const unsigned char* bytes) {
return ((((static_cast<unsigned int>(bytes[3]) << 8) | bytes[2]) << 8 | bytes[1]) << 8) | bytes[0];
unsigned char b0 = *bytes++;
unsigned char b1 = *bytes++;
unsigned char b2 = *bytes++;
unsigned char b3 = *bytes;
return ((((static_cast<unsigned int>(b3) << 8) | b2) << 8 | b1) << 8) | b0;
}
// OFFSET: 0x00B0C440