Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- key GenKey() {
- string chars = "0123456789abcdef";
- string out;
- integer x;
- integer y;
- for (x = 1; x < 6; x++) {
- if (x == 1) for (y = 0; y < 8; y++) {
- integer index = (integer)llFrand(llStringLength(chars));
- out += llGetSubString(chars, index, index);
- }
- if (x == 2 || x == 3 || x == 4) for (y = 0; y < 4; y++) {
- integer index = (integer)llFrand(llStringLength(chars));
- out += llGetSubString(chars, index, index);
- }
- if (x == 5) for (y = 0; y < 12; y++) {
- integer index = (integer)llFrand(llStringLength(chars));
- out += llGetSubString(chars, index, index);
- } if (x != 5) out += "-";
- } return out;
- }
Add Comment
Please, Sign In to add comment