<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/css" href="http://wiki.lostsouls.org/w/skins/common/feed.css"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://wiki.lostsouls.org/w/index.php?action=history&amp;feed=atom&amp;title=Man_identity</id>
		<title>Man identity - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://wiki.lostsouls.org/w/index.php?action=history&amp;feed=atom&amp;title=Man_identity"/>
		<link rel="alternate" type="text/html" href="http://wiki.lostsouls.org/w/index.php?title=Man_identity&amp;action=history"/>
		<updated>2026-05-10T10:45:47Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.8.2</generator>

	<entry>
		<id>http://wiki.lostsouls.org/w/index.php?title=Man_identity&amp;diff=3968&amp;oldid=prev</id>
		<title>Laine at 20:37, 11 June 2007</title>
		<link rel="alternate" type="text/html" href="http://wiki.lostsouls.org/w/index.php?title=Man_identity&amp;diff=3968&amp;oldid=prev"/>
				<updated>2007-06-11T20:37:50Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==Files==&lt;br /&gt;
&lt;br /&gt;
 /def/descriptor/identity.c&lt;br /&gt;
 /lib/descriptors/identity.h&lt;br /&gt;
 /mod/basic/identity.c&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
Identity descriptors are used by objects to define the way their identity&lt;br /&gt;
(names and short descriptions) are determined.&lt;br /&gt;
&lt;br /&gt;
Identity descriptors which are in used by an object should not be directly&lt;br /&gt;
modified; changes may not be properly acknowledged and, because identity&lt;br /&gt;
descriptors are shared, serious errors may result.  Instead, the function&lt;br /&gt;
alter_identity() in the object should be used.&lt;br /&gt;
&lt;br /&gt;
Certain core concepts are critical to understand identity descriptors and&lt;br /&gt;
how they are used.  The main one is that of assembling names out of nouns,&lt;br /&gt;
adjunct nouns, and adjectives.  The basic idea is simple: if an object has&lt;br /&gt;
a noun of &amp;quot;rock&amp;quot; and an adjective of &amp;quot;big&amp;quot;, then it will answer to the&lt;br /&gt;
names &amp;quot;big rock&amp;quot; and &amp;quot;rock&amp;quot;.  If it has nouns of &amp;quot;rock&amp;quot; and &amp;quot;stone&amp;quot; and&lt;br /&gt;
adjectives of &amp;quot;big&amp;quot; and &amp;quot;pretty&amp;quot;, then it is a &amp;quot;big pretty rock&amp;quot;, &amp;quot;big&lt;br /&gt;
pretty stone&amp;quot;, &amp;quot;big rock&amp;quot;, &amp;quot;big stone&amp;quot;, &amp;quot;pretty rock&amp;quot;, &amp;quot;pretty stone&amp;quot;,&lt;br /&gt;
&amp;quot;rock&amp;quot;, and &amp;quot;stone&amp;quot;.  (Incidentally, the longest final combination will&lt;br /&gt;
be the one that winds up being used as the object's main name; in this&lt;br /&gt;
case, &amp;quot;big pretty stone&amp;quot;.)  All the appropriate combinations will be put&lt;br /&gt;
together in determining the object's list of names.  An example of an&lt;br /&gt;
adjunct noun is &amp;quot;suit&amp;quot; in &amp;quot;suit of armour&amp;quot;; these also will be combined&lt;br /&gt;
as appropriate.  If no ordinary nouns are available, but adjunct nouns&lt;br /&gt;
are, the adjunct nouns will be used as ordinary nouns.&lt;br /&gt;
&lt;br /&gt;
Another concept is the handling of identity codes, in particular multiple&lt;br /&gt;
identity codes applying to a given object.  There are many sources of&lt;br /&gt;
identity codes applying to an object: its own explicit setting, its name&lt;br /&gt;
if any, its materials, its weapon and armour type if any.  When object&lt;br /&gt;
configuration is resolved, an object which has no explicit identity code&lt;br /&gt;
setting will have the first code found from any of these sources set as&lt;br /&gt;
its identity code.  If there are any more applicable identity codes found,&lt;br /&gt;
they will be available from query_extra_codes(); also, having multiple&lt;br /&gt;
identity codes forces names to be dynamically generated for each viewer&lt;br /&gt;
rather than being able to have lists stored.  This is much more expensive&lt;br /&gt;
in terms of execution time than cacheable lists, so some care should be&lt;br /&gt;
taken at an administrative level to see that the bulk of objects in the&lt;br /&gt;
game do not require this behavior (though of course it should be used&lt;br /&gt;
where appropriate).&lt;br /&gt;
&lt;br /&gt;
Last, the condition of &amp;quot;the object being known to the viewer&amp;quot; is often&lt;br /&gt;
referenced.  To clarify, this means that the object's primary identity&lt;br /&gt;
code (its Identity_Code setting) is known to the viewer; any additional&lt;br /&gt;
identity codes do not count in this context.&lt;br /&gt;
&lt;br /&gt;
===Public Fields===&lt;br /&gt;
&lt;br /&gt;
Identity_Type: The identity type determines the general way in which the&lt;br /&gt;
object's identity will be constructed.  (Integer.)  The types are:&lt;br /&gt;
&lt;br /&gt;
    Identity_Type_Standard: The usual and default type, under which nouns,&lt;br /&gt;
    adjunct nouns, and adjectives are collected from the object's identity&lt;br /&gt;
    settings, its weapon and armour type (if any), and its material&lt;br /&gt;
    configuration (usually its predominant material by volume).  All the&lt;br /&gt;
    other identity fields described below behave normally with this type.&lt;br /&gt;
    Note that nouns, adjunct nouns, and adjectives from the identity&lt;br /&gt;
    descriptor are added to those from other sources.&lt;br /&gt;
&lt;br /&gt;
    Identity_Type_Custom: Similar to Identity_Standard, but weapon type,&lt;br /&gt;
    armour type, and materials do not influence configuration.  Basically,&lt;br /&gt;
    this means that the object's names are determined solely from its&lt;br /&gt;
    identity settings.&lt;br /&gt;
&lt;br /&gt;
    Identity_Type_Unit: Indicates that the object is a unit of its main&lt;br /&gt;
    material, meaning it is &amp;quot;a strawberry&amp;quot; or &amp;quot;an emerald&amp;quot; rather than,&lt;br /&gt;
    for example, a &amp;quot;piece of strawberry&amp;quot; or a &amp;quot;piece of emerald&amp;quot;.  Causes&lt;br /&gt;
    nouns, adjunct nouns, and adjectives from materials to be assembled&lt;br /&gt;
    differently, and for weapon and armour type to be ignored.&lt;br /&gt;
&lt;br /&gt;
    Identity_Type_Preconfigured: Means that the object is configured with&lt;br /&gt;
    a preset, static list of names (and possibly also of known names).&lt;br /&gt;
    This type exists mainly for backward compatibility with the way object&lt;br /&gt;
    names were configured prior to Ain Soph 2.0; new code should not use&lt;br /&gt;
    this type, and it may be discontinued at some point.  Almost all of&lt;br /&gt;
    the normal behavior of the fields described below is suppressed when&lt;br /&gt;
    this type is used; the only one which still retains its behavior is&lt;br /&gt;
    Identity_Code.&lt;br /&gt;
&lt;br /&gt;
Identity_Nouns: A list of nouns to apply to the object.  (String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Known_Nouns: A list of nouns which, if specified, overrides the&lt;br /&gt;
Identity_Nouns setting when the object is known by the viewer.  Only has&lt;br /&gt;
meaning if the object possesses an identity code.  (String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Adjunct_Nouns: A list of adjunct nouns to apply to the object.&lt;br /&gt;
(String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Known_Adjunct_Nouns: A list of adjunct nouns which, if specified,&lt;br /&gt;
overrides the Identity_Adjunct_Nouns setting when the object is known by&lt;br /&gt;
the viewer.  Only has meaning if the object possesses an identity code.&lt;br /&gt;
(String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Adjectives: A list of adjectives to apply to the object.  (String&lt;br /&gt;
array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Known_Adjectives: A list of adjectives which, if specified,&lt;br /&gt;
overrides the Identity_Adjectives setting when the object is known by the&lt;br /&gt;
viewer.  Only has meaning if the object possesses an identity code.&lt;br /&gt;
(String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Special_Names: A list of names which the object should always&lt;br /&gt;
respond to, regardless of circumstances.  Generally this is used for IDs&lt;br /&gt;
of the form PROJECT_TAG and the like.  (String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Code: An identity code for the object, as used by the general&lt;br /&gt;
item-identification mechanics.  (The old-style function set_code() is&lt;br /&gt;
now implemented as an alter_identity() call to set this field.)  Often&lt;br /&gt;
this field does not need to be set because it will be automatically set&lt;br /&gt;
based on other factors, such as the Identity_Name field, below.  (String.)&lt;br /&gt;
&lt;br /&gt;
Identity_Name: A name for the object.  If Identity_Flag_Proper, described&lt;br /&gt;
below, is set, this is considered a proper name, otherwise a generic name.&lt;br /&gt;
For example, the artifact Soulshard has &amp;quot;Soulshard&amp;quot; as a proper name,&lt;br /&gt;
while iltarixai have &amp;quot;iltarix&amp;quot; as a generic name.  Unless another flag,&lt;br /&gt;
Identity_Flag_Suppress_Name_Code, is set, an identity code for the object&lt;br /&gt;
will generated based on this field; for a proper name, the Identity_Name&lt;br /&gt;
field will be used as an identity code unchanged, and for a generic name,&lt;br /&gt;
the result of pluralize() applied to the Identity_Name field will be used&lt;br /&gt;
as an identity code.  Normally, the object's Identity_Name is visible only&lt;br /&gt;
when the object is known to the viewer; the exception to this is when the&lt;br /&gt;
object has no Identity_Code setting at all.  (String.)&lt;br /&gt;
&lt;br /&gt;
Identity_Name_Adjectives: A list of adjectives to be applied to the&lt;br /&gt;
object's name when it is visible.  Not frequently set.  (String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Effect: Used to designate an object as being &amp;quot;of such-and-thus&lt;br /&gt;
effect&amp;quot;, in the popular style.  For example, a magical ring might have&lt;br /&gt;
an Identity_Effect field of &amp;quot;protection&amp;quot;; this will cause names to be&lt;br /&gt;
added to it with &amp;quot;of protection&amp;quot; appended.  This will only be visible&lt;br /&gt;
when the object is known to the viewer.  Note that no identity code will&lt;br /&gt;
be automatically generated based on this field, and an identity code&lt;br /&gt;
should be manually specified.  (String array.)&lt;br /&gt;
&lt;br /&gt;
Identity_Image: Can be used in either of two ways.  1) When specified as a&lt;br /&gt;
string array, the object is regarded as being an image or representation&lt;br /&gt;
of the names listed in the array; for example, if Identity_Nouns were set&lt;br /&gt;
to ({ &amp;quot;painting&amp;quot; }) and Identity_Image to ({ &amp;quot;a landscape&amp;quot; }), the&lt;br /&gt;
object would be &amp;quot;a painting of a landscape&amp;quot;.  2) When specified as a&lt;br /&gt;
string, this string is interpreted as the object name, and this object is&lt;br /&gt;
considered to be an image of that object.  The other object's names are&lt;br /&gt;
requested from it (via special functions) and its identity code, is taken&lt;br /&gt;
into account, and will apply to this object; for instance, if the object&lt;br /&gt;
pointed to is an iltarix, this object will appear as an image &amp;quot;of an&lt;br /&gt;
iltarix&amp;quot;, &amp;quot;of a silvery metal longsword&amp;quot;, or whatever else as appropriate.&lt;br /&gt;
See also Identity_Flag_Effect_Suppress_Image, below.&lt;br /&gt;
&lt;br /&gt;
Identity_Color: May be used to specify a color which should be applied to&lt;br /&gt;
the object's entire name as viewed by users, overriding any colors normally&lt;br /&gt;
supplied by materials or any other source.  This is the bare color name,&lt;br /&gt;
with no terminal control characters, e.g. &amp;quot;black&amp;quot;, &amp;quot;white&amp;quot;.  (String.)&lt;br /&gt;
&lt;br /&gt;
Identity_Known_Color: Functions like Identity_Color, but only takes effect&lt;br /&gt;
when the Identity_Code is known by the viewer.  (String.)&lt;br /&gt;
&lt;br /&gt;
Identity_Flags: A set of bitmask flags, combinable with bitwise or (|),&lt;br /&gt;
which can alter various aspects of the identity descriptor's behavior.&lt;br /&gt;
(Integer.)  The flags are:&lt;br /&gt;
&lt;br /&gt;
    Identity_Flag_Proper: Indicates that when the object is known to the&lt;br /&gt;
    viewer, its name is considered a proper name.&lt;br /&gt;
&lt;br /&gt;
    Identity_Flag_Unknown_Proper: Indicates that the object's name is&lt;br /&gt;
    considered proper when it is not known.  This is mainly for backward&lt;br /&gt;
    compatibility and is rarely useful in new code.&lt;br /&gt;
&lt;br /&gt;
    Identity_Flag_Suppress_Name_Code: Suppresses the normal behavior of&lt;br /&gt;
    deriving an identity code from the Identity_Name field.&lt;br /&gt;
&lt;br /&gt;
    Identity_Flag_Effect_Override_Image: Indicates that if a viewer would&lt;br /&gt;
    normally see the results of applying both the Identity_Effect and&lt;br /&gt;
    Identity_Image fields, to suppress the effect of Identity_Image.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
&lt;br /&gt;
[[man descriptors|descriptors(mechanisms)]], [[man set identity|set_identity(lfun)]], [[man query identity|query_identity(lfun)]], [[man alter identity|alter_identity(lfun)]]&lt;/div&gt;</summary>
		<author><name>Laine</name></author>	</entry>

	</feed>