Identity Target References

From HLKitWiki
Revision as of 20:58, 5 December 2008 by Rob (Talk | contribs) (New page: {{contextmulti|Kit Reference|Target References}} There are a number of target references across different contexts that make use of identity tags. For each of these target references, a t...)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Context: HL KitKit Reference … Target References  … Multiple Sources

There are a number of target references across different contexts that make use of identity tags. For each of these target references, a tag group is specified, but no actual tag. This is because the script itself implicitly identifies the tag id based on the initial context of the script.

The source of the identity tag is dictated by the pick or thing that begins as the initial context, with the unique id of that object being used as the identity tag id. The group in which to locate that identity tag is specified with the target reference. If the resulting identity tag does not exist, a run-time error is reported.

The use of identity target references has an important limitation. The identity source is based on the initial script context, and only things and picks possess identity tags. Consequently, identity target references can only be used from within scripts whose initial context is either a thing or a pick. Use from any other script results in a compilation error.