CreateKey() A Checksum Generator
not ratedThis Script creates a checksum of a string. the string will be shortened, and every single letter has consequences for the created checksum (or KEY as i called it first).
e.g.
If you create a savecode, if the code is ready, you can add a key, and check the key again when loading the hero or whatever is saved. if then the key is missmatching, abord the loadtrigger. so, manipulating or hacking the savecode is harder.
the function has 3 parameters. the first is the string of which u want a checksum. the second is for the length of the key. type an integer here, that is SMALLER than the stringlength of the first parameter. the last parameter contains a charmap. its a list of letters, numbers and other symbols, and has to contain every symbol ONCE that the first parameter can contain.
IMPORTANT!! NEEDS THE IndexOfSubstring() FUNCTION!
e.g.
If you create a savecode, if the code is ready, you can add a key, and check the key again when loading the hero or whatever is saved. if then the key is missmatching, abord the loadtrigger. so, manipulating or hacking the savecode is harder.
the function has 3 parameters. the first is the string of which u want a checksum. the second is for the length of the key. type an integer here, that is SMALLER than the stringlength of the first parameter. the last parameter contains a charmap. its a list of letters, numbers and other symbols, and has to contain every symbol ONCE that the first parameter can contain.
IMPORTANT!! NEEDS THE IndexOfSubstring() FUNCTION!