From Second Life Wiki
Revision as of 06:41, 19 March 2015 by Innula Zenovka (talk | contribs) (fixed broken lsl formatting)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

A function that, when passed a key will return an unique hash in the form of an integer based on the the llDialog article on the Second Life wiki. This can be used, for example, to pass an avatar name to a rezzed primitive using llRezObject.

integer Key2Number(key objKey) {
  return ((integer)("0x"+llGetSubString((string)objKey,-8,-1)) & 0x3FFFFFFF) ^ 0x3FFFFFFF;