<p>This has the drawback of being two operations; you must also import the class and have to pass
the actual database field names, such as <codeclass="docutils literal notranslate"><spanclass="pre">db_key</span></code> instead of <codeclass="docutils literal notranslate"><spanclass="pre">key</span></code> as keyword arguments.</p>
</li>
<li><p>Secondly you can use the Evennia creation helpers:</p>
<p>This is the recommended way if you are trying to create things in Python. The first argument can either be
the class <em>or</em> the python-path to the typeclass, like <codeclass="docutils literal notranslate"><spanclass="pre">"path.to.SomeTypeClass"</span></code>. It can also be <codeclass="docutils literal notranslate"><spanclass="pre">None</span></code> in which
case the Evennia default will be used. While all the creation methods
are available on <codeclass="docutils literal notranslate"><spanclass="pre">evennia</span></code>, they are actually implemented in <aclass="reference internal"href="../../../api/evennia.utils.create.html"><spanclass="doc std std-doc">evennia/utils/create.py</span></a>.</p>
</li>
<li><p>Finally, you can create objects using an in-game command, such as</p>
<p>As a developer you are usually best off using the two other methods, but a command is usually the only way
to let regular players or builders without Python-access help build the game world.</p>
</li>
</ul>
<sectionid="creating-objects">
<h2><spanclass="section-number">10.1. </span>Creating Objects<aclass="headerlink"href="#creating-objects"title="Permalink to this headline">¶</a></h2>
<p>This is one of the most common creation-types. These are entities that inherits from <codeclass="docutils literal notranslate"><spanclass="pre">DefaultObject</span></code> at any distance.
They have an existence in the game world and includes rooms, characters, exits, weapons, flower pots and castles.</p>
> rose = evennia.create_object(key="rose")
</pre></div>
</div>
<p>Since we didn’t specify the <codeclass="docutils literal notranslate"><spanclass="pre">typeclass</span></code> as the first argument, the default given by <codeclass="docutils literal notranslate"><spanclass="pre">settings.BASE_OBJECT_TYPECLASS</span></code>
(<codeclass="docutils literal notranslate"><spanclass="pre">typeclasses.objects.Object</span></code>) will be used.</p>
</section>
<sectionid="creating-accounts">
<h2><spanclass="section-number">10.2. </span>Creating Accounts<aclass="headerlink"href="#creating-accounts"title="Permalink to this headline">¶</a></h2>
<p>An <em>Account</em> is an out-of-character (OOC) entity, with no existence in the game world.
You can find the parent class for Accounts in <codeclass="docutils literal notranslate"><spanclass="pre">typeclasses/accounts.py</span></code>.</p>