<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE funcs
  SYSTEM '../../../clonk.dtd'>
<?xml-stylesheet type="text/xsl" href="../../../clonk.xsl"?>
<funcs>
  <func>
    <title>GetCategory</title>
    <category>Objects</category>
    <subcat>Category</subcat>
    <version>5.1 OC</version>
    <syntax><rtype>int</rtype></syntax>
    <desc>Determines the category of an object. The category is usually specified in the <emlink href="definition/defcore.html">DefCore</emlink> but may in some cases haven been changed during the game by <funclink>SetCategory</funclink>. The category determines general placement and behaviour of the object. The returned category value can be compared with C4D_x constants using the &amp; operator.</desc>
    <examples>
      <example>
        <code><funclink>if</funclink> (obj-&gt;GetCategory() &amp; <funclink>C4D_Structure</funclink>) obj-><funclink>Incinerate</funclink>();</code>
        <text>Incinerates the object if it is a building.</text>
      </example>
    </examples>
    <related><funclink>SetCategory</funclink></related>
  </func>
  <author>Sven2</author><date>2002-04</date>
</funcs>
