Platforms to show: All Mac Windows Linux Cross-Platform

GetHash32MBS(s as string) as UInt32

Type Topic Plugin Version macOS Windows Linux iOS Targets
global method Encryption and Hash MBS Util Plugin 3.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Calculates some special Hash value.
Example
MsgBox hex(GetHash32MBS("xskin-b013fafit_01-PELVIS-BODY.skn")) // should show 67A53A4D

The 255 char limit was in the original C function, but should be resolved for this plugin, so string longer than 255 chars will work.
The original C code looks like this:

static UInt32 GetHash32 (StringPtr inString)
{
intlength = inString[0];
UInt32hash = length + 1;
inti;

for (i = 1; i <= length; i++)
{
hash = __rlwinm(hash, 3, 0, 31) ^ tolower(inString[i]);
}

return hash;
}

Originally this was added for Cherie Benoit, which describes it like this:

"GetHash32MBS" duplicates the hashing function of Westlake
Interactive's "Namer" application which creates LFN-style short
filenames for use with the Macintosh version of "The Sims."

The items on this page are in the following plugins: MBS Util Plugin.


The biggest plugin in space...