mirror of
https://github.com/evennia/evennia.git
synced 2026-03-31 13:07:16 +02:00
Updated HTML docs
This commit is contained in:
parent
40b2ba0cee
commit
cad698493d
87 changed files with 1496 additions and 635 deletions
|
|
@ -110,7 +110,11 @@
|
|||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.talking_npc.html">evennia.contrib.talking_npc</a></li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.test_traits.html">evennia.contrib.test_traits</a></li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html">evennia.contrib.traits</a><ul>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a><ul>
|
||||
<li class="toctree-l5"><a class="reference internal" href="evennia.contrib.traits.html#traits-with-traithandler">Traits with TraitHandler</a></li>
|
||||
<li class="toctree-l5"><a class="reference internal" href="evennia.contrib.traits.html#traitproperties">TraitProperties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#using-traits">Using traits</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#trait-types">Trait types</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#static-trait">Static trait</a><ul>
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ method. Otherwise all text will be returned to all connected sessions.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.account.CmdOOCLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'ls']</em><a class="headerlink" href="#evennia.commands.default.account.CmdOOCLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ls', 'l']</em><a class="headerlink" href="#evennia.commands.default.account.CmdOOCLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -102,7 +102,7 @@ method. Otherwise all text will be returned to all connected sessions.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.account.CmdOOCLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l ls', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n look while out-of-character\n\n Usage:\n look\n\n Look in the ooc state.\n '}</em><a class="headerlink" href="#evennia.commands.default.account.CmdOOCLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ls l', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n look while out-of-character\n\n Usage:\n look\n\n Look in the ooc state.\n '}</em><a class="headerlink" href="#evennia.commands.default.account.CmdOOCLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -1276,7 +1276,7 @@ server settings.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.building.CmdTypeclass.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['type', 'update', 'swap', 'parent', 'typeclasses']</em><a class="headerlink" href="#evennia.commands.default.building.CmdTypeclass.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['swap', 'typeclasses', 'parent', 'update', 'type']</em><a class="headerlink" href="#evennia.commands.default.building.CmdTypeclass.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -1307,7 +1307,7 @@ server settings.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.building.CmdTypeclass.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'type update swap parent typeclasses', 'category': 'building', 'key': 'typeclass', 'tags': '', 'text': "\n set or change an object's typeclass\n\n Usage:\n typeclass[/switch] <object> [= typeclass.path]\n typeclass/prototype <object> = prototype_key\n\n typeclasses or typeclass/list/show [typeclass.path]\n swap - this is a shorthand for using /force/reset flags.\n update - this is a shorthand for using the /force/reload flag.\n\n Switch:\n show, examine - display the current typeclass of object (default) or, if\n given a typeclass path, show the docstring of that typeclass.\n update - *only* re-run at_object_creation on this object\n meaning locks or other properties set later may remain.\n reset - clean out *all* the attributes and properties on the\n object - basically making this a new clean object.\n force - change to the typeclass also if the object\n already has a typeclass of the same name.\n list - show available typeclasses. Only typeclasses in modules actually\n imported or used from somewhere in the code will show up here\n (those typeclasses are still available if you know the path)\n prototype - clean and overwrite the object with the specified\n prototype key - effectively making a whole new object.\n\n Example:\n type button = examples.red_button.RedButton\n type/prototype button=a red button\n\n If the typeclass_path is not given, the current object's typeclass is\n assumed.\n\n View or set an object's typeclass. If setting, the creation hooks of the\n new typeclass will be run on the object. If you have clashing properties on\n the old class, use /reset. By default you are protected from changing to a\n typeclass of the same name as the one you already have - use /force to\n override this protection.\n\n The given typeclass must be identified by its location using python\n dot-notation pointing to the correct module and class. If no typeclass is\n given (or a wrong typeclass is given). Errors in the path or new typeclass\n will lead to the old typeclass being kept. The location of the typeclass\n module is searched from the default typeclass directory, as defined in the\n server settings.\n\n "}</em><a class="headerlink" href="#evennia.commands.default.building.CmdTypeclass.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'swap typeclasses parent update type', 'category': 'building', 'key': 'typeclass', 'tags': '', 'text': "\n set or change an object's typeclass\n\n Usage:\n typeclass[/switch] <object> [= typeclass.path]\n typeclass/prototype <object> = prototype_key\n\n typeclasses or typeclass/list/show [typeclass.path]\n swap - this is a shorthand for using /force/reset flags.\n update - this is a shorthand for using the /force/reload flag.\n\n Switch:\n show, examine - display the current typeclass of object (default) or, if\n given a typeclass path, show the docstring of that typeclass.\n update - *only* re-run at_object_creation on this object\n meaning locks or other properties set later may remain.\n reset - clean out *all* the attributes and properties on the\n object - basically making this a new clean object.\n force - change to the typeclass also if the object\n already has a typeclass of the same name.\n list - show available typeclasses. Only typeclasses in modules actually\n imported or used from somewhere in the code will show up here\n (those typeclasses are still available if you know the path)\n prototype - clean and overwrite the object with the specified\n prototype key - effectively making a whole new object.\n\n Example:\n type button = examples.red_button.RedButton\n type/prototype button=a red button\n\n If the typeclass_path is not given, the current object's typeclass is\n assumed.\n\n View or set an object's typeclass. If setting, the creation hooks of the\n new typeclass will be run on the object. If you have clashing properties on\n the old class, use /reset. By default you are protected from changing to a\n typeclass of the same name as the one you already have - use /force to\n override this protection.\n\n The given typeclass must be identified by its location using python\n dot-notation pointing to the correct module and class. If no typeclass is\n given (or a wrong typeclass is given). Errors in the path or new typeclass\n will lead to the old typeclass being kept. The location of the typeclass\n module is searched from the default typeclass directory, as defined in the\n server settings.\n\n "}</em><a class="headerlink" href="#evennia.commands.default.building.CmdTypeclass.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -1460,7 +1460,7 @@ If object is not specified, the current location is examined.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.building.CmdExamine.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ex', 'exam']</em><a class="headerlink" href="#evennia.commands.default.building.CmdExamine.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['exam', 'ex']</em><a class="headerlink" href="#evennia.commands.default.building.CmdExamine.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -1557,7 +1557,7 @@ non-persistent data stored on object</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.building.CmdExamine.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ex exam', 'category': 'building', 'key': 'examine', 'tags': '', 'text': '\n get detailed information about an object\n\n Usage:\n examine [<object>[/attrname]]\n examine [*<account>[/attrname]]\n\n Switch:\n account - examine an Account (same as adding *)\n object - examine an Object (useful when OOC)\n\n The examine command shows detailed game info about an\n object and optionally a specific attribute on it.\n If object is not specified, the current location is examined.\n\n Append a * before the search string to examine an account.\n\n '}</em><a class="headerlink" href="#evennia.commands.default.building.CmdExamine.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'exam ex', 'category': 'building', 'key': 'examine', 'tags': '', 'text': '\n get detailed information about an object\n\n Usage:\n examine [<object>[/attrname]]\n examine [*<account>[/attrname]]\n\n Switch:\n account - examine an Account (same as adding *)\n object - examine an Object (useful when OOC)\n\n The examine command shows detailed game info about an\n object and optionally a specific attribute on it.\n If object is not specified, the current location is examined.\n\n Append a * before the search string to examine an account.\n\n '}</em><a class="headerlink" href="#evennia.commands.default.building.CmdExamine.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -1818,7 +1818,7 @@ given, <nr> defaults to 10.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.building.CmdObjects.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['listobjects', 'listobjs', 'stats', 'db']</em><a class="headerlink" href="#evennia.commands.default.building.CmdObjects.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['listobjects', 'stats', 'listobjs', 'db']</em><a class="headerlink" href="#evennia.commands.default.building.CmdObjects.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -1844,7 +1844,7 @@ given, <nr> defaults to 10.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.building.CmdObjects.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'listobjects listobjs stats db', 'category': 'system', 'key': 'objects', 'tags': '', 'text': '\n statistics on objects in the database\n\n Usage:\n objects [<nr>]\n\n Gives statictics on objects in database as well as\n a list of <nr> latest objects in database. If not\n given, <nr> defaults to 10.\n '}</em><a class="headerlink" href="#evennia.commands.default.building.CmdObjects.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'listobjects stats listobjs db', 'category': 'system', 'key': 'objects', 'tags': '', 'text': '\n statistics on objects in the database\n\n Usage:\n objects [<nr>]\n\n Gives statictics on objects in database as well as\n a list of <nr> latest objects in database. If not\n given, <nr> defaults to 10.\n '}</em><a class="headerlink" href="#evennia.commands.default.building.CmdObjects.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ look <a href="#id1"><span class="problematic" id="id2">*</span></a><account&g
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.general.CmdLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'ls']</em><a class="headerlink" href="#evennia.commands.default.general.CmdLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ls', 'l']</em><a class="headerlink" href="#evennia.commands.default.general.CmdLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -144,7 +144,7 @@ look <a href="#id1"><span class="problematic" id="id2">*</span></a><account&g
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.general.CmdLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l ls', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n look at location or object\n\n Usage:\n look\n look <obj>\n look *<account>\n\n Observes your location or objects in your vicinity.\n '}</em><a class="headerlink" href="#evennia.commands.default.general.CmdLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ls l', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n look at location or object\n\n Usage:\n look\n look <obj>\n look *<account>\n\n Observes your location or objects in your vicinity.\n '}</em><a class="headerlink" href="#evennia.commands.default.general.CmdLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -558,7 +558,7 @@ See <a href="#id11"><span class="problematic" id="id12">|</span></a>luhttps://ww
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.system.CmdTasks.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['task', 'delays']</em><a class="headerlink" href="#evennia.commands.default.system.CmdTasks.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['delays', 'task']</em><a class="headerlink" href="#evennia.commands.default.system.CmdTasks.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -604,7 +604,7 @@ to all the variables defined therein.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.system.CmdTasks.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'task delays', 'category': 'system', 'key': 'tasks', 'tags': '', 'text': "\n Display or terminate active tasks (delays).\n\n Usage:\n tasks[/switch] [task_id or function_name]\n\n Switches:\n pause - Pause the callback of a task.\n unpause - Process all callbacks made since pause() was called.\n do_task - Execute the task (call its callback).\n call - Call the callback of this task.\n remove - Remove a task without executing it.\n cancel - Stop a task from automatically executing.\n\n Notes:\n A task is a single use method of delaying the call of a function. Calls are created\n in code, using `evennia.utils.delay`.\n See |luhttps://www.evennia.com/docs/latest/Command-Duration.html|ltthe docs|le for help.\n\n By default, tasks that are canceled and never called are cleaned up after one minute.\n\n Examples:\n - `tasks/cancel move_callback` - Cancels all movement delays from the slow_exit contrib.\n In this example slow exits creates it's tasks with\n `utils.delay(move_delay, move_callback)`\n - `tasks/cancel 2` - Cancel task id 2.\n\n "}</em><a class="headerlink" href="#evennia.commands.default.system.CmdTasks.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'delays task', 'category': 'system', 'key': 'tasks', 'tags': '', 'text': "\n Display or terminate active tasks (delays).\n\n Usage:\n tasks[/switch] [task_id or function_name]\n\n Switches:\n pause - Pause the callback of a task.\n unpause - Process all callbacks made since pause() was called.\n do_task - Execute the task (call its callback).\n call - Call the callback of this task.\n remove - Remove a task without executing it.\n cancel - Stop a task from automatically executing.\n\n Notes:\n A task is a single use method of delaying the call of a function. Calls are created\n in code, using `evennia.utils.delay`.\n See |luhttps://www.evennia.com/docs/latest/Command-Duration.html|ltthe docs|le for help.\n\n By default, tasks that are canceled and never called are cleaned up after one minute.\n\n Examples:\n - `tasks/cancel move_callback` - Cancels all movement delays from the slow_exit contrib.\n In this example slow exits creates it's tasks with\n `utils.delay(move_delay, move_callback)`\n - `tasks/cancel 2` - Cancel task id 2.\n\n "}</em><a class="headerlink" href="#evennia.commands.default.system.CmdTasks.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ create “account name” “pass word”</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.unloggedin.CmdUnconnectedCreate.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['cre', 'cr']</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedCreate.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['cr', 'cre']</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedCreate.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -150,7 +150,7 @@ create “account name” “pass word”</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.unloggedin.CmdUnconnectedCreate.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'cre cr', 'category': 'general', 'key': 'create', 'tags': '', 'text': '\n create a new account account\n\n Usage (at login screen):\n create <accountname> <password>\n create "account name" "pass word"\n\n This creates a new account account.\n\n If you have spaces in your name, enclose it in double quotes.\n '}</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedCreate.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'cr cre', 'category': 'general', 'key': 'create', 'tags': '', 'text': '\n create a new account account\n\n Usage (at login screen):\n create <accountname> <password>\n create "account name" "pass word"\n\n This creates a new account account.\n\n If you have spaces in your name, enclose it in double quotes.\n '}</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedCreate.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -224,7 +224,7 @@ All it does is display the connect screen.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.unloggedin.CmdUnconnectedLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['look', 'l']</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'look']</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -250,7 +250,7 @@ All it does is display the connect screen.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.commands.default.unloggedin.CmdUnconnectedLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'look l', 'category': 'general', 'key': '__unloggedin_look_command', 'tags': '', 'text': '\n look when in unlogged-in state\n\n Usage:\n look\n\n This is an unconnected version of the look command for simplicity.\n\n This is called by the server and kicks everything in gear.\n All it does is display the connect screen.\n '}</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l look', 'category': 'general', 'key': '__unloggedin_look_command', 'tags': '', 'text': '\n look when in unlogged-in state\n\n Usage:\n look\n\n This is an unconnected version of the look command for simplicity.\n\n This is called by the server and kicks everything in gear.\n All it does is display the connect screen.\n '}</em><a class="headerlink" href="#evennia.commands.default.unloggedin.CmdUnconnectedLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ at them with this command.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.chargen.CmdOOCLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'ls']</em><a class="headerlink" href="#evennia.contrib.chargen.CmdOOCLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ls', 'l']</em><a class="headerlink" href="#evennia.contrib.chargen.CmdOOCLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -110,7 +110,7 @@ that is checked by the @ic command directly.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.chargen.CmdOOCLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l ls', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n ooc look\n\n Usage:\n look\n look <character>\n\n This is an OOC version of the look command. Since an Account doesn\'t\n have an in-game existence, there is no concept of location or\n "self".\n\n If any characters are available for you to control, you may look\n at them with this command.\n '}</em><a class="headerlink" href="#evennia.contrib.chargen.CmdOOCLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ls l', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n ooc look\n\n Usage:\n look\n look <character>\n\n This is an OOC version of the look command. Since an Account doesn\'t\n have an in-game existence, there is no concept of location or\n "self".\n\n If any characters are available for you to control, you may look\n at them with this command.\n '}</em><a class="headerlink" href="#evennia.contrib.chargen.CmdOOCLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -127,7 +127,7 @@ there is no object yet before the account has logged in)</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.email_login.CmdUnconnectedCreate.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['cre', 'cr']</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedCreate.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['cr', 'cre']</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedCreate.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -163,7 +163,7 @@ name enclosed in quotes:</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.email_login.CmdUnconnectedCreate.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'cre cr', 'category': 'general', 'key': 'create', 'tags': '', 'text': '\n Create a new account.\n\n Usage (at login screen):\n create "accountname" <email> <password>\n\n This creates a new account account.\n\n '}</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedCreate.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'cr cre', 'category': 'general', 'key': 'create', 'tags': '', 'text': '\n Create a new account.\n\n Usage (at login screen):\n create "accountname" <email> <password>\n\n This creates a new account account.\n\n '}</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedCreate.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -227,7 +227,7 @@ All it does is display the connect screen.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.email_login.CmdUnconnectedLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['look', 'l']</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'look']</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -253,7 +253,7 @@ All it does is display the connect screen.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.email_login.CmdUnconnectedLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'look l', 'category': 'general', 'key': '__unloggedin_look_command', 'tags': '', 'text': '\n This is an unconnected version of the `look` command for simplicity.\n\n This is called by the server and kicks everything in gear.\n All it does is display the connect screen.\n '}</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l look', 'category': 'general', 'key': '__unloggedin_look_command', 'tags': '', 'text': '\n This is an unconnected version of the `look` command for simplicity.\n\n This is called by the server and kicks everything in gear.\n All it does is display the connect screen.\n '}</em><a class="headerlink" href="#evennia.contrib.email_login.CmdUnconnectedLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -148,7 +148,7 @@ the operation will be general or on the room.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdGiveUp.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['abort', 'q', 'chicken out', 'quit']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGiveUp.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['chicken out', 'q', 'quit', 'abort']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGiveUp.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py method">
|
||||
|
|
@ -172,7 +172,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdGiveUp.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'abort q chicken out quit', 'category': 'evscaperoom', 'key': 'give up', 'tags': '', 'text': '\n Give up\n\n Usage:\n give up\n\n Abandons your attempts at escaping and of ever winning the pie-eating contest.\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGiveUp.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'chicken out q quit abort', 'category': 'evscaperoom', 'key': 'give up', 'tags': '', 'text': '\n Give up\n\n Usage:\n give up\n\n Abandons your attempts at escaping and of ever winning the pie-eating contest.\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGiveUp.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -193,7 +193,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'ls']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ls', 'l']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -227,7 +227,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l ls', 'category': 'evscaperoom', 'key': 'look', 'tags': '', 'text': '\n Look at the room, an object or the currently focused object\n\n Usage:\n look [obj]\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ls l', 'category': 'evscaperoom', 'key': 'look', 'tags': '', 'text': '\n Look at the room, an object or the currently focused object\n\n Usage:\n look [obj]\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -308,7 +308,7 @@ shout</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdSpeak.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['shout', ';', 'whisper']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdSpeak.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['shout', 'whisper', ';']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdSpeak.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -337,7 +337,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdSpeak.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'shout ; whisper', 'category': 'general', 'key': 'say', 'tags': '', 'text': '\n Perform an communication action.\n\n Usage:\n say <text>\n whisper\n shout\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdSpeak.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'shout whisper ;', 'category': 'general', 'key': 'say', 'tags': '', 'text': '\n Perform an communication action.\n\n Usage:\n say <text>\n whisper\n shout\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdSpeak.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -427,7 +427,7 @@ looks and what actions is available.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdFocus.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['examine', 'e', 'unfocus', 'ex']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdFocus.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ex', 'examine', 'e', 'unfocus']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdFocus.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -456,7 +456,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdFocus.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'examine e unfocus ex', 'category': 'evscaperoom', 'key': 'focus', 'tags': '', 'text': '\n Focus your attention on a target.\n\n Usage:\n focus <obj>\n\n Once focusing on an object, use look to get more information about how it\n looks and what actions is available.\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdFocus.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ex examine e unfocus', 'category': 'evscaperoom', 'key': 'focus', 'tags': '', 'text': '\n Focus your attention on a target.\n\n Usage:\n focus <obj>\n\n Once focusing on an object, use look to get more information about how it\n looks and what actions is available.\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdFocus.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -518,7 +518,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdGet.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['inventory', 'inv', 'give', 'i']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGet.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['give', 'inv', 'inventory', 'i']</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGet.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py method">
|
||||
|
|
@ -542,7 +542,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.evscaperoom.commands.CmdGet.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'inventory inv give i', 'category': 'evscaperoom', 'key': 'get', 'tags': '', 'text': '\n Use focus / examine instead.\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGet.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'give inv inventory i', 'category': 'evscaperoom', 'key': 'get', 'tags': '', 'text': '\n Use focus / examine instead.\n\n '}</em><a class="headerlink" href="#evennia.contrib.evscaperoom.commands.CmdGet.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -277,7 +277,7 @@ look <a href="#id1"><span class="problematic" id="id2">*</span></a><account&g
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.extended_room.CmdExtendedRoomLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'ls']</em><a class="headerlink" href="#evennia.contrib.extended_room.CmdExtendedRoomLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ls', 'l']</em><a class="headerlink" href="#evennia.contrib.extended_room.CmdExtendedRoomLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -297,7 +297,7 @@ look <a href="#id1"><span class="problematic" id="id2">*</span></a><account&g
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.extended_room.CmdExtendedRoomLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l ls', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n look\n\n Usage:\n look\n look <obj>\n look <room detail>\n look *<account>\n\n Observes your location, details at your location or objects in your vicinity.\n '}</em><a class="headerlink" href="#evennia.contrib.extended_room.CmdExtendedRoomLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ls l', 'category': 'general', 'key': 'look', 'tags': '', 'text': '\n look\n\n Usage:\n look\n look <obj>\n look <room detail>\n look *<account>\n\n Observes your location, details at your location or objects in your vicinity.\n '}</em><a class="headerlink" href="#evennia.contrib.extended_room.CmdExtendedRoomLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -70,7 +70,11 @@ useful but are deemed too game-specific to go into the core library.</p>
|
|||
<li class="toctree-l1"><a class="reference internal" href="evennia.contrib.talking_npc.html">evennia.contrib.talking_npc</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="evennia.contrib.test_traits.html">evennia.contrib.test_traits</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="evennia.contrib.traits.html">evennia.contrib.traits</a><ul>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.traits.html#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.traits.html#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a><ul>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#traits-with-traithandler">Traits with TraitHandler</a></li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#traitproperties">TraitProperties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.traits.html#using-traits">Using traits</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.traits.html#trait-types">Trait types</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.traits.html#static-trait">Static trait</a><ul>
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.ingame_python.commands.CmdCallback.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['@calls', '@callbacks', '@callback']</em><a class="headerlink" href="#evennia.contrib.ingame_python.commands.CmdCallback.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['@callback', '@calls', '@callbacks']</em><a class="headerlink" href="#evennia.contrib.ingame_python.commands.CmdCallback.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -134,7 +134,7 @@ on user permission.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.ingame_python.commands.CmdCallback.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': '@calls @callbacks @callback', 'category': 'building', 'key': '@call', 'tags': '', 'text': '\n Command to edit callbacks.\n '}</em><a class="headerlink" href="#evennia.contrib.ingame_python.commands.CmdCallback.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': '@callback @calls @callbacks', 'category': 'building', 'key': '@call', 'tags': '', 'text': '\n Command to edit callbacks.\n '}</em><a class="headerlink" href="#evennia.contrib.ingame_python.commands.CmdCallback.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -317,7 +317,7 @@ same input sentence.</p>
|
|||
<dd class="field-odd"><ul class="simple">
|
||||
<li><p><strong>text</strong> (<em>str</em>) – Text to obfuscate.</p></li>
|
||||
<li><p><strong>level</strong> (<em>real</em><em>, </em><em>optional</em>) – A value from 0.0-1.0 determining
|
||||
the level of obfuscation where 0 means no jobfuscation
|
||||
the level of obfuscation where 0 means no obfuscation
|
||||
(string returned unchanged) and 1.0 means the entire
|
||||
string is obfuscated.</p></li>
|
||||
<li><p><strong>language</strong> (<em>str</em><em>, </em><em>optional</em>) – The identifier of a language
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ represent you in the emote. You can use /sdesc, /nick, /key or
|
|||
/alias to reference objects in the room. You can use any
|
||||
number of sdesc sub-parts to differentiate a local sdesc, or
|
||||
use /1-sdesc etc to differentiate them. The emote also
|
||||
identifies nested says.</p>
|
||||
identifies nested says and separates case.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</li>
|
||||
|
|
@ -113,13 +113,17 @@ The tavern is full of nice people</p>
|
|||
an example of a static <em>pose</em>: The “standing by the bar” has been set
|
||||
by the player of the tall man, so that people looking at him can tell
|
||||
at a glance what is going on.</p>
|
||||
<p>> emote /me looks at /tall and says “Hello!”</p>
|
||||
<p>> emote /me looks at /Tall and says “Hello!”</p>
|
||||
<dl class="simple">
|
||||
<dt>I see:</dt><dd><p>Griatch looks at Tall man and says “Hello”.</p>
|
||||
</dd>
|
||||
<dt>Tall man (assuming his name is Tom) sees:</dt><dd><p>The godlike figure looks at Tom and says “Hello”.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
<p>Note that by default, the case of the tag matters, so <strong>/tall</strong> will
|
||||
lead to ‘tall man’ while <strong>/Tall</strong> will become ‘Tall man’ and /TALL
|
||||
becomes /TALL MAN. If you don’t want this behavior, you can pass
|
||||
case_sensitive=False to the <strong>send_emote</strong> function.</p>
|
||||
<p>Verbose Installation Instructions:</p>
|
||||
<blockquote>
|
||||
<div><ol class="arabic">
|
||||
|
|
@ -154,9 +158,9 @@ Import the <strong>ContribRPCharacter</strong> class:</p>
|
|||
</dd>
|
||||
</dl>
|
||||
</li>
|
||||
<li><p>Reload the server (@reload or from console: “evennia reload”)</p></li>
|
||||
<li><p>Reload the server (<strong>reload</strong> or from console: “evennia reload”)</p></li>
|
||||
<li><dl class="simple">
|
||||
<dt>Force typeclass updates as required. Example for your character:</dt><dd><p>@type/reset/force me = typeclasses.characters.Character</p>
|
||||
<dt>Force typeclass updates as required. Example for your character:</dt><dd><p><strong>type/reset/force me = typeclasses.characters.Character</strong></p>
|
||||
</dd>
|
||||
</dl>
|
||||
</li>
|
||||
|
|
@ -285,7 +289,7 @@ information is actually conveyed.</p>
|
|||
|
||||
<dl class="py function">
|
||||
<dt id="evennia.contrib.rpsystem.parse_sdescs_and_recogs">
|
||||
<code class="sig-prename descclassname">evennia.contrib.rpsystem.</code><code class="sig-name descname">parse_sdescs_and_recogs</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">sender</span></em>, <em class="sig-param"><span class="n">candidates</span></em>, <em class="sig-param"><span class="n">string</span></em>, <em class="sig-param"><span class="n">search_mode</span><span class="o">=</span><span class="default_value">False</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/rpsystem.html#parse_sdescs_and_recogs"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.rpsystem.parse_sdescs_and_recogs" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-prename descclassname">evennia.contrib.rpsystem.</code><code class="sig-name descname">parse_sdescs_and_recogs</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">sender</span></em>, <em class="sig-param"><span class="n">candidates</span></em>, <em class="sig-param"><span class="n">string</span></em>, <em class="sig-param"><span class="n">search_mode</span><span class="o">=</span><span class="default_value">False</span></em>, <em class="sig-param"><span class="n">case_sensitive</span><span class="o">=</span><span class="default_value">True</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/rpsystem.html#parse_sdescs_and_recogs"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.rpsystem.parse_sdescs_and_recogs" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Read a raw emote and parse it into an intermediary
|
||||
format for distributing to all observers.</p>
|
||||
<dl class="field-list simple">
|
||||
|
|
@ -303,6 +307,13 @@ search_mode (bool, optional): If <strong>True</strong>, the “emote” is a que
|
|||
<blockquote>
|
||||
<div><p>we want to analyze. If so, the return value is changed.</p>
|
||||
</div></blockquote>
|
||||
<dl class="simple">
|
||||
<dt>case_sensitive (bool, optional); If set, the case of /refs matter, so that</dt><dd><p>/tall will come out as ‘tall man’ while /Tall will become ‘Tall man’.
|
||||
This allows for more grammatically correct emotes at the cost of being
|
||||
a little more to learn for players. If disabled, the original sdesc case
|
||||
is always kept and are inserted as-is.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Returns</dt>
|
||||
<dd class="field-odd"><p><p><em>(emote, mapping) (tuple)</em> –</p>
|
||||
|
|
@ -352,6 +363,18 @@ self-referencing in the emote, this will auto-add
|
|||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="simple">
|
||||
<dt>Kwargs:</dt><dd><dl class="simple">
|
||||
<dt>case_sensitive (bool): Defaults to True, but can be unset</dt><dd><p>here. When enabled, /tall will lead to a lowercase
|
||||
‘tall man’ while /Tall will lead to ‘Tall man’ and
|
||||
/TALL will lead to ‘TALL MAN’. If disabled, the sdesc’s
|
||||
case will always be used, regardless of the /ref case used.</p>
|
||||
</dd>
|
||||
<dt>any: Other kwargs will be passed on into the receiver’s process_sdesc and</dt><dd><p>process_recog methods, and can thus be used to customize those.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py class">
|
||||
|
|
@ -802,7 +825,7 @@ Using the command without arguments will list all current recogs.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.rpsystem.CmdRecog.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['forget', 'recognize']</em><a class="headerlink" href="#evennia.contrib.rpsystem.CmdRecog.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['recognize', 'forget']</em><a class="headerlink" href="#evennia.contrib.rpsystem.CmdRecog.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py method">
|
||||
|
|
@ -829,7 +852,7 @@ Using the command without arguments will list all current recogs.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.rpsystem.CmdRecog.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'forget recognize', 'category': 'general', 'key': 'recog', 'tags': '', 'text': '\n Recognize another person in the same room.\n\n Usage:\n recog\n recog sdesc as alias\n forget alias\n\n Example:\n recog tall man as Griatch\n forget griatch\n\n This will assign a personal alias for a person, or forget said alias.\n Using the command without arguments will list all current recogs.\n\n '}</em><a class="headerlink" href="#evennia.contrib.rpsystem.CmdRecog.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'recognize forget', 'category': 'general', 'key': 'recog', 'tags': '', 'text': '\n Recognize another person in the same room.\n\n Usage:\n recog\n recog sdesc as alias\n forget alias\n\n Example:\n recog tall man as Griatch\n forget griatch\n\n This will assign a personal alias for a person, or forget said alias.\n Using the command without arguments will list all current recogs.\n\n '}</em><a class="headerlink" href="#evennia.contrib.rpsystem.CmdRecog.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -1165,8 +1188,23 @@ you are viewing yourself (and sdesc is your key).
|
|||
This is not used by default.</p></li>
|
||||
</ul>
|
||||
</dd>
|
||||
<dt class="field-even">Returns</dt>
|
||||
<dd class="field-even"><p><p><em>sdesc (str)</em> –</p>
|
||||
</dl>
|
||||
<dl class="simple">
|
||||
<dt>Kwargs:</dt><dd><dl class="simple">
|
||||
<dt>ref (str): The reference marker found in string to replace.</dt><dd><p>This is on the form #{num}{case}, like ‘#12^’, where
|
||||
the number is a processing location in the string and the
|
||||
case symbol indicates the case of the original tag input
|
||||
- <strong>t</strong> - input was Titled, like /Tall
|
||||
- <strong>^</strong> - input was all uppercase, like /TALL
|
||||
- <strong>v</strong> - input was all lowercase, like /tall
|
||||
- <strong>~</strong> - input case should be kept, or was mixed-case</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Returns</dt>
|
||||
<dd class="field-odd"><p><p><em>sdesc (str)</em> –</p>
|
||||
<dl class="simple">
|
||||
<dt>The processed sdesc ready</dt><dd><p>for display.</p>
|
||||
</dd>
|
||||
|
|
@ -1189,8 +1227,14 @@ translated from the original sdesc at this point.</p></li>
|
|||
This is not used by default.</p></li>
|
||||
</ul>
|
||||
</dd>
|
||||
<dt class="field-even">Returns</dt>
|
||||
<dd class="field-even"><p><em>recog (str)</em> – The modified recog string.</p>
|
||||
</dl>
|
||||
<dl class="simple">
|
||||
<dt>Kwargs:</dt><dd><p>ref (str): See process_sdesc.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Returns</dt>
|
||||
<dd class="field-odd"><p><em>recog (str)</em> – The modified recog string.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -438,6 +438,102 @@
|
|||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py class">
|
||||
<dt id="evennia.contrib.test_traits.DummyCharacter">
|
||||
<em class="property">class </em><code class="sig-prename descclassname">evennia.contrib.test_traits.</code><code class="sig-name descname">DummyCharacter</code><a class="reference internal" href="../_modules/evennia/contrib/test_traits.html#DummyCharacter"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.test_traits.DummyCharacter" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">evennia.contrib.test_traits._MockObj</span></code></p>
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.test_traits.DummyCharacter.strength">
|
||||
<code class="sig-name descname">strength</code><a class="headerlink" href="#evennia.contrib.test_traits.DummyCharacter.strength" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Allows for applying traits as individual properties directly on the parent class
|
||||
instead for properties on the <strong>.traits</strong> handler. So with this you could access data e.g. as
|
||||
<strong>character.hp.value</strong> instead of <strong>character.traits.hp.value</strong>. This still uses the traitshandler
|
||||
under the hood.</p>
|
||||
<p>Example:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="kn">from</span> <span class="nn">evennia.utils</span> <span class="kn">import</span> <span class="n">lazy_property</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.contrib.traits</span> <span class="kn">import</span> <span class="n">TraitProperty</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Character</span><span class="p">(</span><span class="n">DefaultCharacter</span><span class="p">):</span>
|
||||
|
||||
<span class="n">strength</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="n">hunting</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="n">health</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"health"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Type</dt>
|
||||
<dd class="field-odd"><p>Optional extra</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.test_traits.DummyCharacter.hunting">
|
||||
<code class="sig-name descname">hunting</code><a class="headerlink" href="#evennia.contrib.test_traits.DummyCharacter.hunting" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Allows for applying traits as individual properties directly on the parent class
|
||||
instead for properties on the <strong>.traits</strong> handler. So with this you could access data e.g. as
|
||||
<strong>character.hp.value</strong> instead of <strong>character.traits.hp.value</strong>. This still uses the traitshandler
|
||||
under the hood.</p>
|
||||
<p>Example:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="kn">from</span> <span class="nn">evennia.utils</span> <span class="kn">import</span> <span class="n">lazy_property</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.contrib.traits</span> <span class="kn">import</span> <span class="n">TraitProperty</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Character</span><span class="p">(</span><span class="n">DefaultCharacter</span><span class="p">):</span>
|
||||
|
||||
<span class="n">strength</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="n">hunting</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="n">health</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"health"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Type</dt>
|
||||
<dd class="field-odd"><p>Optional extra</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.test_traits.DummyCharacter.health">
|
||||
<code class="sig-name descname">health</code><a class="headerlink" href="#evennia.contrib.test_traits.DummyCharacter.health" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Allows for applying traits as individual properties directly on the parent class
|
||||
instead for properties on the <strong>.traits</strong> handler. So with this you could access data e.g. as
|
||||
<strong>character.hp.value</strong> instead of <strong>character.traits.hp.value</strong>. This still uses the traitshandler
|
||||
under the hood.</p>
|
||||
<p>Example:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="kn">from</span> <span class="nn">evennia.utils</span> <span class="kn">import</span> <span class="n">lazy_property</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.contrib.traits</span> <span class="kn">import</span> <span class="n">TraitProperty</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Character</span><span class="p">(</span><span class="n">DefaultCharacter</span><span class="p">):</span>
|
||||
|
||||
<span class="n">strength</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="n">hunting</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="n">health</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"health"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Type</dt>
|
||||
<dd class="field-odd"><p>Optional extra</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py class">
|
||||
<dt id="evennia.contrib.test_traits.TestTraitFields">
|
||||
<em class="property">class </em><code class="sig-prename descclassname">evennia.contrib.test_traits.</code><code class="sig-name descname">TestTraitFields</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">methodName</span><span class="o">=</span><span class="default_value">'runTest'</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/test_traits.html#TestTraitFields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.test_traits.TestTraitFields" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">django.test.testcases.TestCase</span></code></p>
|
||||
<p>Test the TraitField class.</p>
|
||||
<dl class="py method">
|
||||
<dt id="evennia.contrib.test_traits.TestTraitFields.test_traitfields">
|
||||
<code class="sig-name descname">test_traitfields</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/test_traits.html#TestTraitFields.test_traitfields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.test_traits.TestTraitFields.test_traitfields" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
</section>
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -50,64 +50,118 @@ be used to represent everything from attributes (str, agi etc) to skills
|
|||
a server reload/reboot).</p>
|
||||
<section id="adding-traits-to-a-typeclass">
|
||||
<h2>Adding Traits to a typeclass<a class="headerlink" href="#adding-traits-to-a-typeclass" title="Permalink to this headline">¶</a></h2>
|
||||
<p>To access and manipulate traits on an entity, its Typeclass needs to have a
|
||||
<strong>TraitHandler</strong> assigned it. Usually, the handler is made available as <strong>.traits</strong>
|
||||
(in the same way as <strong>.tags</strong> or <strong>.attributes</strong>). It’s recommended to do this
|
||||
using Evennia’s <strong>lazy_property</strong> (which basically just means it’s not
|
||||
initialized until it’s actually accessed).</p>
|
||||
<p>Here’s an example for adding the TraitHandler to the base Object class:</p>
|
||||
<p>There are two ways to set up Traits on a typeclass. The first sets up the <strong>TraitHandler</strong>
|
||||
as a property <strong>.traits</strong> on your class and you then access traits as e.g. <strong>.traits.strength</strong>.
|
||||
The other alternative uses a <strong>TraitProperty</strong>, which makes the trait available directly
|
||||
as e.g. <strong>.strength</strong>. This solution also uses the <strong>TraitHandler</strong>, but you don’t need to
|
||||
define it explicitly. You can combine both styles if you like.</p>
|
||||
<section id="traits-with-traithandler">
|
||||
<h3>Traits with TraitHandler<a class="headerlink" href="#traits-with-traithandler" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Here’s an example for adding the TraitHandler to the Character class:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="c1"># mygame/typeclasses/objects.py</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">evennia</span> <span class="kn">import</span> <span class="n">DefaultObject</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia</span> <span class="kn">import</span> <span class="n">DefaultCharacter</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.utils</span> <span class="kn">import</span> <span class="n">lazy_property</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.contrib.traits</span> <span class="kn">import</span> <span class="n">TraitHandler</span>
|
||||
|
||||
<span class="c1"># ...</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Object</span><span class="p">(</span><span class="n">DefaultObject</span><span class="p">):</span>
|
||||
<span class="k">class</span> <span class="nc">Character</span><span class="p">(</span><span class="n">DefaultCharacter</span><span class="p">):</span>
|
||||
<span class="o">...</span>
|
||||
<span class="nd">@lazy_property</span>
|
||||
<span class="k">def</span> <span class="nf">traits</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="c1"># this adds the handler as .traits</span>
|
||||
<span class="k">return</span> <span class="n">TraitHandler</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
</section>
|
||||
<section id="using-traits">
|
||||
<h2>Using traits<a class="headerlink" href="#using-traits" title="Permalink to this headline">¶</a></h2>
|
||||
<p>A trait is added to the traithandler, after which one can access it
|
||||
as a property on the handler (similarly to how you can do .db.attrname for Attributes
|
||||
in Evennia).</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="c1"># this is an example using the "static" trait, described below</span>
|
||||
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">4</span><span class="p">)</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">4</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span> <span class="o">+=</span> <span class="mi">5</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">9</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hp"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">100</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span> <span class="o">-=</span> <span class="mi">200</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">0</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">reset</span><span class="p">()</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">100</span>
|
||||
<span class="c1"># you can also access property with getitem</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="p">[</span><span class="s2">"value"</span><span class="p">]</span>
|
||||
<span class="mi">100</span>
|
||||
<span class="c1"># you can store arbitrary data persistently as well</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">effect</span> <span class="o">=</span> <span class="s2">"poisoned!"</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">effect</span>
|
||||
<span class="s2">"poisoned!"</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">at_object_creation</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="c1"># (or wherever you want)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hp"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>When adding the trait, you supply the name of the property (<strong>hunting</strong>) along
|
||||
with a more human-friendly name (“Hunting Skill”). The latter will show if you
|
||||
print the trait etc. The <strong>trait_type</strong> is important, this specifies which type
|
||||
of trait this is.</p>
|
||||
of trait this is (see below).</p>
|
||||
</section>
|
||||
<section id="traitproperties">
|
||||
<h3>TraitProperties<a class="headerlink" href="#traitproperties" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Using <strong>TraitProperties</strong> makes the trait available directly on the class, much like Django model
|
||||
fields. The drawback is that you must make sure that the name of your Traits don’t collide with any
|
||||
other properties/methods on your class.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="c1"># mygame/typeclasses/objects.py</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">evennia</span> <span class="kn">import</span> <span class="n">DefaultObject</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.utils</span> <span class="kn">import</span> <span class="n">lazy_property</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.contrib.traits</span> <span class="kn">import</span> <span class="n">TraitProperty</span>
|
||||
|
||||
<span class="c1"># ...</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Object</span><span class="p">(</span><span class="n">DefaultObject</span><span class="p">):</span>
|
||||
<span class="o">...</span>
|
||||
<span class="n">strength</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="n">health</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="n">hunting</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>> Note that the property-name will become the name of the trait and you don’t supply <strong>trait_key</strong>
|
||||
> separately.</p>
|
||||
<p>> The <strong>.traits</strong> TraitHandler will still be created (it’s used under the
|
||||
> hood. But it will only be created when the TraitProperty has been accessed at least once,
|
||||
> so be careful if mixing the two styles. If you want to make sure <strong>.traits</strong> is always available,
|
||||
> add the <strong>TraitHandler</strong> manually like shown earlier - the <strong>TraitProperty</strong> will by default use
|
||||
> the same handler (<strong>.traits</strong>).</p>
|
||||
</section>
|
||||
</section>
|
||||
<section id="using-traits">
|
||||
<h2>Using traits<a class="headerlink" href="#using-traits" title="Permalink to this headline">¶</a></h2>
|
||||
<p>A trait is added to the traithandler (if you use <strong>TraitProperty</strong> the handler is just created under
|
||||
the hood) after which one can access it as a property on the handler (similarly to how you can do
|
||||
.db.attrname for Attributes in Evennia).</p>
|
||||
<p>All traits have a _read-<a href="#id7"><span class="problematic" id="id8">only_</span></a> field <strong>.value</strong>. This is only used to read out results, you never
|
||||
manipulate it directly (if you try, it will just remain unchanged). The <strong>.value</strong> is calculated based
|
||||
on combining fields, like <strong>.base</strong> and <strong>.mod</strong> - which fields are available and how they relate to
|
||||
each other depends on the trait type.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">strength</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">12</span> <span class="c1"># base + mod</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">strength</span><span class="o">.</span><span class="n">base</span> <span class="o">+=</span> <span class="mi">5</span>
|
||||
<span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">strength</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">17</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">102</span> <span class="c1"># base + mod</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">base</span> <span class="o">-=</span> <span class="mi">200</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">0</span> <span class="c1"># min of 0</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">reset</span><span class="p">()</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">100</span>
|
||||
|
||||
<span class="c1"># you can also access properties like a dict</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="p">[</span><span class="s2">"value"</span><span class="p">]</span>
|
||||
<span class="mi">100</span>
|
||||
|
||||
<span class="c1"># you can store arbitrary data persistently for easy reference</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">effect</span> <span class="o">=</span> <span class="s2">"poisoned!"</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">effect</span>
|
||||
<span class="s2">"poisoned!"</span>
|
||||
|
||||
<span class="c1"># with TraitProperties:</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">12</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">strength</span><span class="o">.</span><span class="n">value</span> <span class="o">+=</span> <span class="mi">5</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">strength</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">17</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
</section>
|
||||
<section id="trait-types">
|
||||
<h2>Trait types<a class="headerlink" href="#trait-types" title="Permalink to this headline">¶</a></h2>
|
||||
|
|
@ -115,13 +169,15 @@ of trait this is.</p>
|
|||
‘current’ value of the trait. Exactly what this means depends on the type of trait.</p>
|
||||
<p>Traits can also be combined to do arithmetic with their .value, if both have a
|
||||
compatible type.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">trait1</span> <span class="o">+</span> <span class="n">trait2</span>
|
||||
<span class="go">54</span>
|
||||
<span class="gp">>>> </span><span class="n">trait1</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">3</span>
|
||||
<span class="gp">>>> </span><span class="n">trait1</span> <span class="o">+</span> <span class="mi">2</span>
|
||||
<span class="gp">>>> </span><span class="n">trait1</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">5</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">trait1</span> <span class="o">+</span> <span class="n">trait2</span>
|
||||
<span class="mi">54</span>
|
||||
|
||||
<span class="o">></span> <span class="n">trait1</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">3</span>
|
||||
|
||||
<span class="o">></span> <span class="n">trait1</span> <span class="o">+</span> <span class="mi">2</span>
|
||||
<span class="o">></span> <span class="n">trait1</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">5</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>Two numerical traits can also be compared (bigger-than etc), which is useful in
|
||||
|
|
@ -137,25 +193,27 @@ all sorts of rule-resolution.</p>
|
|||
<p>The static trait has a <strong>base</strong> value and an optional <strong>mod</strong>-ifier. A typical use
|
||||
of a static trait would be a Strength stat or Skill value. That is, something
|
||||
that varies slowly or not at all, and which may be modified in-place.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">12 # base + mod</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">base</span> <span class="o">+=</span> <span class="mi">2</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">mod</span> <span class="o">+=</span> <span class="mi">1</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">15</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">mod</span> <span class="o">=</span> <span class="mi">0</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">12</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
|
||||
<span class="mi">12</span> <span class="c1"># base + mod</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">base</span> <span class="o">+=</span> <span class="mi">2</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">mod</span> <span class="o">+=</span> <span class="mi">1</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">15</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">mod</span> <span class="o">=</span> <span class="mi">0</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">12</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<section id="counter">
|
||||
<h3>Counter<a class="headerlink" href="#counter" title="Permalink to this headline">¶</a></h3>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="nb">min</span><span class="o">/</span><span class="n">unset</span> <span class="n">base</span> <span class="n">base</span><span class="o">+</span><span class="n">mod</span> <span class="nb">max</span><span class="o">/</span><span class="n">unset</span>
|
||||
<span class="o">|--------------|--------|---------</span><span class="n">X</span><span class="o">--------</span><span class="n">X</span><span class="o">------------|</span>
|
||||
<span class="n">current</span> <span class="n">value</span>
|
||||
<span class="o">=</span> <span class="n">current</span>
|
||||
<span class="o">+</span> <span class="n">mod</span>
|
||||
<span class="n">current</span> <span class="n">value</span>
|
||||
<span class="o">=</span> <span class="n">current</span>
|
||||
<span class="o">+</span> <span class="n">mod</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>A counter describes a value that can move from a base. The <strong>.current</strong> property
|
||||
|
|
@ -163,18 +221,23 @@ is the thing usually modified. It starts at the <strong>.base</strong>. One can
|
|||
modifier, which will both be added to the base and to current (forming
|
||||
<strong>.value</strong>). The min/max of the range are optional, a boundary set to None will
|
||||
remove it. A suggested use for a Counter Trait would be to track skill values.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="go"> base=10, mod=1, min=0, max=100)</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">11 # current starts at base + mod</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span> <span class="o">+=</span> <span class="mi">10</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">21</span>
|
||||
<span class="go"># reset back to base+mod by deleting current</span>
|
||||
<span class="gp">>>> </span><span class="k">del</span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">11</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">max</span> <span class="o">=</span> <span class="kc">None</span> <span class="c1"># removing upper bound</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">11</span> <span class="c1"># current starts at base + mod</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span> <span class="o">+=</span> <span class="mi">10</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">21</span>
|
||||
|
||||
<span class="c1"># reset back to base+mod by deleting current</span>
|
||||
<span class="o">></span> <span class="k">del</span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">11</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">max</span> <span class="o">=</span> <span class="kc">None</span> <span class="c1"># removing upper bound</span>
|
||||
|
||||
<span class="c1"># for TraitProperties, pass the args/kwargs of traits.add() to the</span>
|
||||
<span class="c1"># TraitProperty constructor instead.</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>Counters have some extra properties:</p>
|
||||
|
|
@ -188,19 +251,20 @@ interval. Here is an example for skill values between 0 and 10:</p>
|
|||
</div>
|
||||
<p>The keys must be supplied from smallest to largest. Any values below the lowest and above the
|
||||
highest description will be considered to be included in the closest description slot.
|
||||
By calling <strong>.desc()</strong> on the Counter, will you get the text matching the current <strong>value</strong>
|
||||
value.</p>
|
||||
By calling <strong>.desc()</strong> on the Counter, you will get the text matching the current <strong>value</strong>.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="c1"># (could also have passed descs= to traits.add())</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">descs</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">descs</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="mi">0</span><span class="p">:</span> <span class="s2">"unskilled"</span><span class="p">,</span> <span class="mi">10</span><span class="p">:</span> <span class="s2">"neophyte"</span><span class="p">,</span> <span class="mi">50</span><span class="p">:</span> <span class="s2">"trained"</span><span class="p">,</span> <span class="mi">70</span><span class="p">:</span> <span class="s2">"expert"</span><span class="p">,</span> <span class="mi">90</span><span class="p">:</span> <span class="s2">"master"</span><span class="p">}</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">11</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">desc</span><span class="p">()</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">desc</span><span class="p">()</span>
|
||||
<span class="s2">"neophyte"</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span> <span class="o">+=</span> <span class="mi">60</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span> <span class="o">+=</span> <span class="mi">60</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">71</span>
|
||||
<span class="o">>>></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">desc</span><span class="p">()</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">desc</span><span class="p">()</span>
|
||||
<span class="s2">"expert"</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
|
|
@ -216,39 +280,46 @@ if those are set.</p>
|
|||
<p>It is also possible to set a <strong>.ratetarget</strong>, for the auto-change to stop at
|
||||
(rather than at the min/max boundaries). This allows the value to return to
|
||||
a previous value.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">71</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">ratetarget</span> <span class="o">=</span> <span class="mi">71</span>
|
||||
<span class="go"># debuff hunting for some reason</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span> <span class="o">-=</span> <span class="mi">30</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">41</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">rate</span> <span class="o">=</span> <span class="mi">1</span> <span class="c1"># 1/s increase</span>
|
||||
<span class="go"># Waiting 5s</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">46</span>
|
||||
<span class="go"># Waiting 8s</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">54</span>
|
||||
<span class="go"># Waiting 100s</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">71 # we have stopped at the ratetarget</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">rate</span> <span class="o">=</span> <span class="mi">0</span> <span class="c1"># disable auto-change</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">71</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">ratetarget</span> <span class="o">=</span> <span class="mi">71</span>
|
||||
<span class="c1"># debuff hunting for some reason</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">current</span> <span class="o">-=</span> <span class="mi">30</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">41</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">rate</span> <span class="o">=</span> <span class="mi">1</span> <span class="c1"># 1/s increase</span>
|
||||
<span class="c1"># Waiting 5s</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">46</span>
|
||||
|
||||
<span class="c1"># Waiting 8s</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">54</span>
|
||||
|
||||
<span class="c1"># Waiting 100s</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">71</span> <span class="c1"># we have stopped at the ratetarget</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">rate</span> <span class="o">=</span> <span class="mi">0</span> <span class="c1"># disable auto-change</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>Note that if <strong>.rate</strong> is a non-integer, the resulting <strong>.value</strong> (at least until it
|
||||
reaches a boundary or rate-target) will also come out a float (so you can get a
|
||||
very exact value at the current time). If you expect an integer, you must run
|
||||
<strong>int()</strong> (or something like <strong>round()</strong>) on the result yourself.</p>
|
||||
<p>Note that when retrieving the <strong>current</strong>, the result will always be of the same
|
||||
type as the <strong>.base</strong> even <strong>rate</strong> is a non-integer value. So if <strong>base</strong> is an <strong>int</strong>
|
||||
(default)**, the <strong>current</strong> value will also be rounded the closest full integer.
|
||||
If you want to see the exact <strong>current</strong> value, set <strong>base</strong> to a float - you
|
||||
will then need to use <strong>round()</strong> yourself on the result if you want integers.</p>
|
||||
</section>
|
||||
<section id="percent">
|
||||
<h4>.percent()<a class="headerlink" href="#percent" title="Permalink to this headline">¶</a></h4>
|
||||
<p>If both min and max are defined, the <strong>.percent()</strong> method of the trait will
|
||||
return the value as a percentage.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">percent</span><span class="p">()</span>
|
||||
<span class="go">"71.0%"</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">percent</span><span class="p">(</span><span class="n">formatting</span><span class="o">=</span><span class="kc">None</span><span class="p">)</span>
|
||||
<span class="go">71.0</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">percent</span><span class="p">()</span>
|
||||
<span class="s2">"71.0%"</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hunting</span><span class="o">.</span><span class="n">percent</span><span class="p">(</span><span class="n">formatting</span><span class="o">=</span><span class="kc">None</span><span class="p">)</span>
|
||||
<span class="mf">71.0</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -268,15 +339,17 @@ read-only and is set by <strong>.base</strong> + <strong>.mod</strong>. So contr
|
|||
value. The minimum bound defaults to 0 if not set explicitly.</p>
|
||||
<p>This trait is useful for showing commonly depletable resources like health,
|
||||
stamina and the like.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hp"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span> <span class="c1"># (or .current)</span>
|
||||
<span class="go">100</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">mod</span> <span class="o">=</span> <span class="mi">10</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">110</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">current</span> <span class="o">-=</span> <span class="mi">30</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">80</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"hp"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span> <span class="c1"># (or .current)</span>
|
||||
<span class="mi">100</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">mod</span> <span class="o">=</span> <span class="mi">10</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">110</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">current</span> <span class="o">-=</span> <span class="mi">30</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">hp</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">80</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<p>The Gauge trait is subclass of the Counter, so you have access to the same
|
||||
|
|
@ -291,16 +364,18 @@ from poison slowly draining your health, to resting gradually increasing it.</p>
|
|||
<p>A single value of any type.</p>
|
||||
<p>This is the ‘base’ Trait, meant to inherit from if you want to invent
|
||||
trait-types from scratch (most of the time you’ll probably inherit from some of
|
||||
the more advanced trait-type classes though). A <strong>Trait**s **.value</strong> can be
|
||||
anything (that can be stored in an Attribute) and if it’s a integer/float you
|
||||
can do arithmetic with it, but otherwise it acts just like a glorified
|
||||
Attribute.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"mytrait"</span><span class="p">,</span> <span class="s2">"My Trait"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"trait"</span><span class="p">,</span> <span class="n">value</span><span class="o">=</span><span class="mi">30</span><span class="p">)</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">30</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span> <span class="o">=</span> <span class="s2">"stringvalue"</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="go">"stringvalue"</span>
|
||||
the more advanced trait-type classes though).</p>
|
||||
<p>Unlike other Trait-types, the single <strong>.value</strong> property of the base <strong>Trait</strong> can
|
||||
be editied. The value can hold any data that can be stored in an Attribute. If
|
||||
it’s an integer/float you can do arithmetic with it, but otherwise this acts just
|
||||
like a glorified Attribute.</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"mytrait"</span><span class="p">,</span> <span class="s2">"My Trait"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"trait"</span><span class="p">,</span> <span class="n">value</span><span class="o">=</span><span class="mi">30</span><span class="p">)</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="mi">30</span>
|
||||
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span> <span class="o">=</span> <span class="s2">"stringvalue"</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mytrait</span><span class="o">.</span><span class="n">value</span>
|
||||
<span class="s2">"stringvalue"</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -337,9 +412,14 @@ default (0). Above we also added some helper methods.</p>
|
|||
</pre></div>
|
||||
</div>
|
||||
<p>Reload the server and you should now be able to use your trait:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"mood"</span><span class="p">,</span> <span class="s2">"A dark mood"</span><span class="p">,</span> <span class="n">rage</span><span class="o">=</span><span class="mi">30</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s1">'rage'</span><span class="p">)</span>
|
||||
<span class="gp">>>> </span><span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mood</span><span class="o">.</span><span class="n">rage</span>
|
||||
<span class="go">30</span>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="s2">"mood"</span><span class="p">,</span> <span class="s2">"A dark mood"</span><span class="p">,</span> <span class="n">rage</span><span class="o">=</span><span class="mi">30</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s1">'rage'</span><span class="p">)</span>
|
||||
<span class="o">></span> <span class="n">obj</span><span class="o">.</span><span class="n">traits</span><span class="o">.</span><span class="n">mood</span><span class="o">.</span><span class="n">rage</span>
|
||||
<span class="mi">30</span>
|
||||
|
||||
<span class="c1"># as TraitProperty</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Character</span><span class="p">(</span><span class="n">DefaultCharacter</span><span class="p">):</span>
|
||||
<span class="n">rage</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"A dark mood"</span><span class="p">,</span> <span class="n">rage</span><span class="o">=</span><span class="mi">30</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s1">'rage'</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<hr class="docutils" />
|
||||
|
|
@ -374,7 +454,17 @@ by Trait classes when defining their required keys.</p>
|
|||
<dt id="evennia.contrib.traits.TraitHandler">
|
||||
<em class="property">class </em><code class="sig-prename descclassname">evennia.contrib.traits.</code><code class="sig-name descname">TraitHandler</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">obj</span></em>, <em class="sig-param"><span class="n">db_attribute_key</span><span class="o">=</span><span class="default_value">'traits'</span></em>, <em class="sig-param"><span class="n">db_attribute_category</span><span class="o">=</span><span class="default_value">'traits'</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/traits.html#TraitHandler"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.traits.TraitHandler" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
|
||||
<p>Factory class that instantiates Trait objects.</p>
|
||||
<p>Factory class that instantiates Trait objects. Must be assigned as a property
|
||||
on the class, usually with <strong>lazy_property</strong>.</p>
|
||||
<p>Example:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="k">class</span> <span class="nc">Object</span><span class="p">(</span><span class="n">DefaultObject</span><span class="p">):</span>
|
||||
<span class="o">...</span>
|
||||
<span class="nd">@lazy_property</span>
|
||||
<span class="k">def</span> <span class="nf">traits</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="c1"># this adds the handler as .traits</span>
|
||||
<span class="k">return</span> <span class="n">TraitHandler</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<dl class="py method">
|
||||
<dt id="evennia.contrib.traits.TraitHandler.__init__">
|
||||
<code class="sig-name descname">__init__</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">obj</span></em>, <em class="sig-param"><span class="n">db_attribute_key</span><span class="o">=</span><span class="default_value">'traits'</span></em>, <em class="sig-param"><span class="n">db_attribute_category</span><span class="o">=</span><span class="default_value">'traits'</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/traits.html#TraitHandler.__init__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.traits.TraitHandler.__init__" title="Permalink to this definition">¶</a></dt>
|
||||
|
|
@ -383,7 +473,8 @@ by Trait classes when defining their required keys.</p>
|
|||
<dt class="field-odd">Parameters</dt>
|
||||
<dd class="field-odd"><ul class="simple">
|
||||
<li><p><strong>obj</strong> (<em>Object</em>) – Parent Object typeclass for this TraitHandler</p></li>
|
||||
<li><p><strong>db_attribute_key</strong> (<em>str</em>) – Name of the DB attribute for trait data storage</p></li>
|
||||
<li><p><strong>db_attribute_key</strong> (<em>str</em>) – Name of the DB attribute for trait data storage.</p></li>
|
||||
<li><p><strong>db_attribute_category</strong> (<em>str</em>) – Name of DB attribute’s category to trait data storage.</p></li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
|
|
@ -426,7 +517,7 @@ available on this handler (example ‘hp’).</p></li>
|
|||
<li><p><strong>name</strong> (<em>str</em><em>, </em><em>optional</em>) – Name of the Trait, like “Health”. If
|
||||
not given, will use <strong>trait_key</strong> starting with a capital letter.</p></li>
|
||||
<li><p><strong>trait_type</strong> (<em>str</em><em>, </em><em>optional</em>) – One of ‘static’, ‘counter’ or ‘gauge’.</p></li>
|
||||
<li><p><strong>force_add</strong> (<em>bool</em>) – If set, create a new Trait even if a Trait with
|
||||
<li><p><strong>force</strong> (<em>bool</em>) – If set, create a new Trait even if a Trait with
|
||||
the same <strong>trait_key</strong> already exists.</p></li>
|
||||
<li><p><strong>trait_properties</strong> (<em>dict</em>) – These will all be use to initialize
|
||||
the new trait. See the <strong>properties</strong> class variable on each
|
||||
|
|
@ -460,6 +551,54 @@ already exists (and <strong>force</strong> is unset).</p>
|
|||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py class">
|
||||
<dt id="evennia.contrib.traits.TraitProperty">
|
||||
<em class="property">class </em><code class="sig-prename descclassname">evennia.contrib.traits.</code><code class="sig-name descname">TraitProperty</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">name</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">trait_type</span><span class="o">=</span><span class="default_value">'static'</span></em>, <em class="sig-param"><span class="n">force</span><span class="o">=</span><span class="default_value">True</span></em>, <em class="sig-param"><span class="o">**</span><span class="n">trait_properties</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/traits.html#TraitProperty"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.traits.TraitProperty" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
|
||||
<p>Optional extra: Allows for applying traits as individual properties directly on the parent class
|
||||
instead for properties on the <strong>.traits</strong> handler. So with this you could access data e.g. as
|
||||
<strong>character.hp.value</strong> instead of <strong>character.traits.hp.value</strong>. This still uses the traitshandler
|
||||
under the hood.</p>
|
||||
<p>Example:</p>
|
||||
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="kn">from</span> <span class="nn">evennia.utils</span> <span class="kn">import</span> <span class="n">lazy_property</span>
|
||||
<span class="kn">from</span> <span class="nn">evennia.contrib.traits</span> <span class="kn">import</span> <span class="n">TraitProperty</span>
|
||||
|
||||
<span class="k">class</span> <span class="nc">Character</span><span class="p">(</span><span class="n">DefaultCharacter</span><span class="p">):</span>
|
||||
|
||||
<span class="n">strength</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"str"</span><span class="p">,</span> <span class="s2">"Strength"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"static"</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="n">hunting</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="s2">"hunting"</span><span class="p">,</span> <span class="s2">"Hunting Skill"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"counter"</span><span class="p">,</span>
|
||||
<span class="n">base</span><span class="o">=</span><span class="mi">10</span><span class="p">,</span> <span class="n">mod</span><span class="o">=</span><span class="mi">1</span><span class="p">,</span> <span class="nb">max</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
<span class="n">health</span> <span class="o">=</span> <span class="n">TraitProperty</span><span class="p">(</span><span class="s2">"health"</span><span class="p">,</span> <span class="s2">"Health"</span><span class="p">,</span> <span class="n">trait_type</span><span class="o">=</span><span class="s2">"gauge"</span><span class="p">,</span> <span class="nb">min</span><span class="o">=</span><span class="mi">0</span><span class="p">,</span> <span class="n">base</span><span class="o">=</span><span class="mi">100</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
</div>
|
||||
<dl class="py method">
|
||||
<dt id="evennia.contrib.traits.TraitProperty.__init__">
|
||||
<code class="sig-name descname">__init__</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">name</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">trait_type</span><span class="o">=</span><span class="default_value">'static'</span></em>, <em class="sig-param"><span class="n">force</span><span class="o">=</span><span class="default_value">True</span></em>, <em class="sig-param"><span class="o">**</span><span class="n">trait_properties</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/traits.html#TraitProperty.__init__"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.traits.TraitProperty.__init__" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Initialize a TraitField. Mimics TraitHandler.add input except no <strong>trait_key</strong>.</p>
|
||||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Parameters</dt>
|
||||
<dd class="field-odd"><ul class="simple">
|
||||
<li><p><strong>name</strong> (<em>str</em><em>, </em><em>optional</em>) – Name of the Trait, like “Health”. If
|
||||
not given, will use <strong>trait_key</strong> starting with a capital letter.</p></li>
|
||||
<li><p><strong>trait_type</strong> (<em>str</em><em>, </em><em>optional</em>) – One of ‘static’, ‘counter’ or ‘gauge’.</p></li>
|
||||
<li><p><strong>force</strong> (<em>bool</em>) – If set, create a new Trait even if a Trait with
|
||||
the same <strong>trait_key</strong> already exists.</p></li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="simple">
|
||||
<dt>Kwargs:</dt><dd><dl class="simple">
|
||||
<dt>traithandler_name (str): If given, this is used as the name of the TraitHandler created</dt><dd><p>behind the scenes. If not set, this will be a property <strong>traits</strong> on the class.</p>
|
||||
</dd>
|
||||
<dt>any: All other trait_properties are the same as for adding a new trait of the given type</dt><dd><p>using the normal TraitHandler.</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="py class">
|
||||
<dt id="evennia.contrib.traits.Trait">
|
||||
<em class="property">class </em><code class="sig-prename descclassname">evennia.contrib.traits.</code><code class="sig-name descname">Trait</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">trait_data</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/traits.html#Trait"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.traits.Trait" title="Permalink to this definition">¶</a></dt>
|
||||
|
|
@ -557,7 +696,7 @@ initialization of this trait.</p>
|
|||
<em class="property">class </em><code class="sig-prename descclassname">evennia.contrib.traits.</code><code class="sig-name descname">StaticTrait</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">trait_data</span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/contrib/traits.html#StaticTrait"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.contrib.traits.StaticTrait" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <a class="reference internal" href="#evennia.contrib.traits.Trait" title="evennia.contrib.traits.Trait"><code class="xref py py-class docutils literal notranslate"><span class="pre">evennia.contrib.traits.Trait</span></code></a></p>
|
||||
<p>Static Trait. This is a single value with a modifier,
|
||||
with no concept of a ‘current’ value.</p>
|
||||
with no concept of a ‘current’ value or min/max etc.</p>
|
||||
<p>value = base + mod</p>
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.traits.StaticTrait.trait_type">
|
||||
|
|
@ -569,6 +708,11 @@ with no concept of a ‘current’ value.</p>
|
|||
<code class="sig-name descname">default_keys</code><em class="property"> = {'base': 0, 'mod': 0}</em><a class="headerlink" href="#evennia.contrib.traits.StaticTrait.default_keys" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py method">
|
||||
<dt id="evennia.contrib.traits.StaticTrait.base">
|
||||
<em class="property">property </em><code class="sig-name descname">base</code><a class="headerlink" href="#evennia.contrib.traits.StaticTrait.base" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py method">
|
||||
<dt id="evennia.contrib.traits.StaticTrait.mod">
|
||||
<em class="property">property </em><code class="sig-name descname">mod</code><a class="headerlink" href="#evennia.contrib.traits.StaticTrait.mod" title="Permalink to this definition">¶</a></dt>
|
||||
|
|
@ -868,7 +1012,11 @@ returned.</p>
|
|||
<p><h3><a href="../index.html">Table of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference internal" href="#">evennia.contrib.traits</a><ul>
|
||||
<li><a class="reference internal" href="#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a></li>
|
||||
<li><a class="reference internal" href="#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a><ul>
|
||||
<li><a class="reference internal" href="#traits-with-traithandler">Traits with TraitHandler</a></li>
|
||||
<li><a class="reference internal" href="#traitproperties">TraitProperties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a class="reference internal" href="#using-traits">Using traits</a></li>
|
||||
<li><a class="reference internal" href="#trait-types">Trait types</a></li>
|
||||
<li><a class="reference internal" href="#static-trait">Static trait</a><ul>
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ such as when closing the lid and un-blinding a character.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdPushLidClosed.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['press', 'press button', 'push']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidClosed.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['press', 'push', 'press button']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidClosed.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -109,7 +109,7 @@ check if the lid is open or closed.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdPushLidClosed.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'press press button push', 'category': 'general', 'key': 'push button', 'tags': '', 'text': '\n Push the red button (lid closed)\n\n Usage:\n push button\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidClosed.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'press push press button', 'category': 'general', 'key': 'push button', 'tags': '', 'text': '\n Push the red button (lid closed)\n\n Usage:\n push button\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidClosed.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -179,7 +179,7 @@ check if the lid is open or closed.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdSmashGlass.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['break lid', 'smash', 'smash lid']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdSmashGlass.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['smash lid', 'break lid', 'smash']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdSmashGlass.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -206,7 +206,7 @@ break.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdSmashGlass.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'break lid smash smash lid', 'category': 'general', 'key': 'smash glass', 'tags': '', 'text': '\n Smash the protective glass.\n\n Usage:\n smash glass\n\n Try to smash the glass of the button.\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdSmashGlass.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'smash lid break lid smash', 'category': 'general', 'key': 'smash glass', 'tags': '', 'text': '\n Smash the protective glass.\n\n Usage:\n smash glass\n\n Try to smash the glass of the button.\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdSmashGlass.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -306,7 +306,7 @@ be mutually exclusive.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdPushLidOpen.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['press', 'press button', 'push']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidOpen.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['press', 'push', 'press button']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidOpen.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -335,7 +335,7 @@ set in self.parse())</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdPushLidOpen.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'press press button push', 'category': 'general', 'key': 'push button', 'tags': '', 'text': '\n Push the red button\n\n Usage:\n push button\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidOpen.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'press push press button', 'category': 'general', 'key': 'push button', 'tags': '', 'text': '\n Push the red button\n\n Usage:\n push button\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdPushLidOpen.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -433,7 +433,7 @@ be mutually exclusive.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdBlindLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['examine', 'feel', 'l', 'ex', 'listen', 'get']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdBlindLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['listen', 'feel', 'l', 'get', 'examine', 'ex']</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdBlindLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -459,7 +459,7 @@ be mutually exclusive.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_examples.red_button.CmdBlindLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'examine feel l ex listen get', 'category': 'general', 'key': 'look', 'tags': '', 'text': "\n Looking around in darkness\n\n Usage:\n look <obj>\n\n ... not that there's much to see in the dark.\n\n "}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdBlindLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'listen feel l get examine ex', 'category': 'general', 'key': 'look', 'tags': '', 'text': "\n Looking around in darkness\n\n Usage:\n look <obj>\n\n ... not that there's much to see in the dark.\n\n "}</em><a class="headerlink" href="#evennia.contrib.tutorial_examples.red_button.CmdBlindLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -493,7 +493,7 @@ shift green root up/down</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.objects.CmdShiftRoot.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['move', 'push', 'shiftroot', 'pull']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdShiftRoot.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['move', 'shiftroot', 'push', 'pull']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdShiftRoot.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -529,7 +529,7 @@ yellow/green - horizontal roots</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.objects.CmdShiftRoot.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'move push shiftroot pull', 'category': 'tutorialworld', 'key': 'shift', 'tags': '', 'text': '\n Shifts roots around.\n\n Usage:\n shift blue root left/right\n shift red root left/right\n shift yellow root up/down\n shift green root up/down\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdShiftRoot.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'move shiftroot push pull', 'category': 'tutorialworld', 'key': 'shift', 'tags': '', 'text': '\n Shifts roots around.\n\n Usage:\n shift blue root left/right\n shift red root left/right\n shift yellow root up/down\n shift green root up/down\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdShiftRoot.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -546,7 +546,7 @@ yellow/green - horizontal roots</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.objects.CmdPressButton.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['push button', 'press button', 'button']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdPressButton.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['button', 'push button', 'press button']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdPressButton.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -572,7 +572,7 @@ yellow/green - horizontal roots</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.objects.CmdPressButton.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'push button press button button', 'category': 'tutorialworld', 'key': 'press', 'tags': '', 'text': '\n Presses a button.\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdPressButton.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'button push button press button', 'category': 'tutorialworld', 'key': 'press', 'tags': '', 'text': '\n Presses a button.\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdPressButton.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -716,7 +716,7 @@ parry - forgoes your attack but will make you harder to hit on next</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.objects.CmdAttack.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['pierce', 'kill', 'slash', 'chop', 'stab', 'bash', 'hit', 'parry', 'fight', 'defend', 'thrust']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdAttack.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['pierce', 'slash', 'hit', 'parry', 'fight', 'defend', 'stab', 'kill', 'thrust', 'chop', 'bash']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdAttack.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -742,7 +742,7 @@ parry - forgoes your attack but will make you harder to hit on next</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.objects.CmdAttack.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'pierce kill slash chop stab bash hit parry fight defend thrust', 'category': 'tutorialworld', 'key': 'attack', 'tags': '', 'text': '\n Attack the enemy. Commands:\n\n stab <enemy>\n slash <enemy>\n parry\n\n stab - (thrust) makes a lot of damage but is harder to hit with.\n slash - is easier to land, but does not make as much damage.\n parry - forgoes your attack but will make you harder to hit on next\n enemy attack.\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdAttack.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'pierce slash hit parry fight defend stab kill thrust chop bash', 'category': 'tutorialworld', 'key': 'attack', 'tags': '', 'text': '\n Attack the enemy. Commands:\n\n stab <enemy>\n slash <enemy>\n parry\n\n stab - (thrust) makes a lot of damage but is harder to hit with.\n slash - is easier to land, but does not make as much damage.\n parry - forgoes your attack but will make you harder to hit on next\n enemy attack.\n\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.objects.CmdAttack.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -185,7 +185,7 @@ code except for adding in the details.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.rooms.CmdTutorialLook.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['l', 'ls']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdTutorialLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['ls', 'l']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdTutorialLook.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -200,7 +200,7 @@ code except for adding in the details.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.rooms.CmdTutorialLook.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'l ls', 'category': 'tutorialworld', 'key': 'look', 'tags': '', 'text': '\n looks at the room and on details\n\n Usage:\n look <obj>\n look <room detail>\n look *<account>\n\n Observes your location, details at your location or objects\n in your vicinity.\n\n Tutorial: This is a child of the default Look command, that also\n allows us to look at "details" in the room. These details are\n things to examine and offers some extra description without\n actually having to be actual database objects. It uses the\n return_detail() hook on TutorialRooms for this.\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdTutorialLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'ls l', 'category': 'tutorialworld', 'key': 'look', 'tags': '', 'text': '\n looks at the room and on details\n\n Usage:\n look <obj>\n look <room detail>\n look *<account>\n\n Observes your location, details at your location or objects\n in your vicinity.\n\n Tutorial: This is a child of the default Look command, that also\n allows us to look at "details" in the room. These details are\n things to examine and offers some extra description without\n actually having to be actual database objects. It uses the\n return_detail() hook on TutorialRooms for this.\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdTutorialLook.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
@ -866,7 +866,7 @@ to find something.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.rooms.CmdLookDark.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['feel', 'l', 'feel around', 'fiddle', 'search']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdLookDark.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['feel', 'l', 'fiddle', 'feel around', 'search']</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdLookDark.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -894,7 +894,7 @@ random chance of eventually finding a light source.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.contrib.tutorial_world.rooms.CmdLookDark.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'feel l feel around fiddle search', 'category': 'tutorialworld', 'key': 'look', 'tags': '', 'text': '\n Look around in darkness\n\n Usage:\n look\n\n Look around in the darkness, trying\n to find something.\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdLookDark.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'feel l fiddle feel around search', 'category': 'tutorialworld', 'key': 'look', 'tags': '', 'text': '\n Look around in darkness\n\n Usage:\n look\n\n Look around in the darkness, trying\n to find something.\n '}</em><a class="headerlink" href="#evennia.contrib.tutorial_world.rooms.CmdLookDark.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -206,7 +206,11 @@ with ‘q’, remove the break line and restart server when finished.</p></li>
|
|||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.talking_npc.html">evennia.contrib.talking_npc</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.test_traits.html">evennia.contrib.test_traits</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="evennia.contrib.traits.html">evennia.contrib.traits</a><ul>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a></li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#adding-traits-to-a-typeclass">Adding Traits to a typeclass</a><ul>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#traits-with-traithandler">Traits with TraitHandler</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="evennia.contrib.traits.html#traitproperties">TraitProperties</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#using-traits">Using traits</a></li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#trait-types">Trait types</a></li>
|
||||
<li class="toctree-l3"><a class="reference internal" href="evennia.contrib.traits.html#static-trait">Static trait</a><ul>
|
||||
|
|
|
|||
|
|
@ -57,17 +57,17 @@ to the Portal, through which the Server is also controlled. This pprogram</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.evennia_launcher.MsgStatus.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgStatus.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgStatus.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.evennia_launcher.MsgStatus.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgStatus.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgStatus.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.evennia_launcher.MsgStatus.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgStatus.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgStatus.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -99,17 +99,17 @@ to the Portal, through which the Server is also controlled. This pprogram</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.evennia_launcher.MsgLauncher2Portal.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'operation', <twisted.protocols.amp.String object>), (b'arguments', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgLauncher2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'operation', <twisted.protocols.amp.String object>), (b'arguments', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgLauncher2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.evennia_launcher.MsgLauncher2Portal.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgLauncher2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgLauncher2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.evennia_launcher.MsgLauncher2Portal.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = []</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgLauncher2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = []</em><a class="headerlink" href="#evennia.server.evennia_launcher.MsgLauncher2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
|
|||
|
|
@ -101,17 +101,17 @@ we break up too-long data snippets into multiple batches here.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgLauncher2Portal.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'operation', <twisted.protocols.amp.String object>), (b'arguments', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgLauncher2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'operation', <twisted.protocols.amp.String object>), (b'arguments', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgLauncher2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgLauncher2Portal.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgLauncher2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgLauncher2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgLauncher2Portal.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.MsgLauncher2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.MsgLauncher2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -143,17 +143,17 @@ we break up too-long data snippets into multiple batches here.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgPortal2Server.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgPortal2Server.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgPortal2Server.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgPortal2Server.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgPortal2Server.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgPortal2Server.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgPortal2Server.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.MsgPortal2Server.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.MsgPortal2Server.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -185,17 +185,17 @@ we break up too-long data snippets into multiple batches here.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgServer2Portal.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgServer2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgServer2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgServer2Portal.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgServer2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgServer2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgServer2Portal.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.MsgServer2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.MsgServer2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -229,17 +229,17 @@ server, such as when a new session connects or resyncs</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.AdminPortal2Server.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.AdminPortal2Server.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.AdminPortal2Server.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.AdminPortal2Server.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.AdminPortal2Server.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.AdminPortal2Server.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.AdminPortal2Server.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.AdminPortal2Server.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.AdminPortal2Server.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -273,17 +273,17 @@ portal.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.AdminServer2Portal.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.AdminServer2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'packed_data', <evennia.server.portal.amp.Compressed object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.AdminServer2Portal.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.AdminServer2Portal.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.AdminServer2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.AdminServer2Portal.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.AdminServer2Portal.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.AdminServer2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = []</em><a class="headerlink" href="#evennia.server.portal.amp.AdminServer2Portal.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -315,17 +315,17 @@ portal.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgStatus.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgStatus.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgStatus.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgStatus.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgStatus.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.MsgStatus.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.MsgStatus.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgStatus.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'status', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.MsgStatus.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -359,17 +359,17 @@ the other. This does not use the batch-send functionality.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.FunctionCall.arguments">
|
||||
<code class="sig-name descname">arguments</code><em class="property"> = [(b'module', <twisted.protocols.amp.String object>), (b'function', <twisted.protocols.amp.String object>), (b'args', <twisted.protocols.amp.String object>), (b'kwargs', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.FunctionCall.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">arguments</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'module', <twisted.protocols.amp.String object>), (b'function', <twisted.protocols.amp.String object>), (b'args', <twisted.protocols.amp.String object>), (b'kwargs', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.FunctionCall.arguments" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.FunctionCall.errors">
|
||||
<code class="sig-name descname">errors</code><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.FunctionCall.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">errors</code><em class="property">: Dict<span class="p">[</span>Type<span class="p">[</span>Exception<span class="p">]</span><span class="p">, </span>bytes<span class="p">]</span></em><em class="property"> = {<class 'Exception'>: b'EXCEPTION'}</em><a class="headerlink" href="#evennia.server.portal.amp.FunctionCall.errors" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.amp.FunctionCall.response">
|
||||
<code class="sig-name descname">response</code><em class="property"> = [(b'result', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.FunctionCall.response" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">response</code><em class="property">: List<span class="p">[</span>Tuple<span class="p">[</span>bytes<span class="p">, </span>twisted.protocols.amp.Argument<span class="p">]</span><span class="p">]</span></em><em class="property"> = [(b'result', <twisted.protocols.amp.String object>)]</em><a class="headerlink" href="#evennia.server.portal.amp.FunctionCall.response" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ as sends text to it when prompted</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.server.portal.irc.IRCBot.factory">
|
||||
<code class="sig-name descname">factory</code><em class="property"> = None</em><a class="headerlink" href="#evennia.server.portal.irc.IRCBot.factory" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">factory</code><em class="property">: Optional<span class="p">[</span>twisted.internet.protocol.Factory<span class="p">]</span></em><em class="property"> = None</em><a class="headerlink" href="#evennia.server.portal.irc.IRCBot.factory" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
|
|||
|
|
@ -275,7 +275,7 @@ indentation.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.eveditor.CmdEditorGroup.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = [':!', ':h', ':q', ':dd', ':dw', ':f', ':w', ':wq', ':>', ':q!', ':y', ':p', ':s', ':fd', ':', ':::', ':x', ':uu', ':UU', ':i', ':echo', ':r', ':j', ':A', ':<', ':=', ':u', ':S', '::', ':fi', ':DD', ':I']</em><a class="headerlink" href="#evennia.utils.eveditor.CmdEditorGroup.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = [':i', ':S', ':fi', ':y', ':dd', ':dw', ':A', ':q!', ':p', ':I', ':', ':j', ':wq', ':!', ':x', ':<', ':::', ':q', ':h', ':u', ':UU', ':r', ':DD', ':f', '::', ':echo', ':w', ':>', ':fd', ':uu', ':=', ':s']</em><a class="headerlink" href="#evennia.utils.eveditor.CmdEditorGroup.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -303,7 +303,7 @@ efficient presentation.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.eveditor.CmdEditorGroup.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': ':! :h :q :dd :dw :f :w :wq :> :q! :y :p :s :fd : ::: :x :uu :UU :i :echo :r :j :A :< := :u :S :: :fi :DD :I', 'category': 'general', 'key': ':editor_command_group', 'tags': '', 'text': '\n Commands for the editor\n '}</em><a class="headerlink" href="#evennia.utils.eveditor.CmdEditorGroup.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': ':i :S :fi :y :dd :dw :A :q! :p :I : :j :wq :! :x :< ::: :q :h :u :UU :r :DD :f :: :echo :w :> :fd :uu := :s', 'category': 'general', 'key': ':editor_command_group', 'tags': '', 'text': '\n Commands for the editor\n '}</em><a class="headerlink" href="#evennia.utils.eveditor.CmdEditorGroup.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -941,7 +941,7 @@ single question.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.evmenu.CmdYesNoQuestion.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['no', 'abort', '__nomatch_command', 'n', 'yes', 'y', 'a']</em><a class="headerlink" href="#evennia.utils.evmenu.CmdYesNoQuestion.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['n', 'y', 'a', '__nomatch_command', 'no', 'yes', 'abort']</em><a class="headerlink" href="#evennia.utils.evmenu.CmdYesNoQuestion.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -967,7 +967,7 @@ single question.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.evmenu.CmdYesNoQuestion.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'no abort __nomatch_command n yes y a', 'category': 'general', 'key': '__noinput_command', 'tags': '', 'text': '\n Handle a prompt for yes or no. Press [return] for the default choice.\n\n '}</em><a class="headerlink" href="#evennia.utils.evmenu.CmdYesNoQuestion.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'n y a __nomatch_command no yes abort', 'category': 'general', 'key': '__noinput_command', 'tags': '', 'text': '\n Handle a prompt for yes or no. Press [return] for the default choice.\n\n '}</em><a class="headerlink" href="#evennia.utils.evmenu.CmdYesNoQuestion.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ the <strong>caller.msg()</strong> construct every time the page is updated.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.evmore.CmdMore.aliases">
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['abort', 'next', 'n', 'e', 'top', 'end', 'back', 'quit', 't', 'a', 'q', 'b']</em><a class="headerlink" href="#evennia.utils.evmore.CmdMore.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">aliases</code><em class="property"> = ['n', 'a', 'quit', 'b', 'e', 'next', 't', 'top', 'q', 'back', 'abort', 'end']</em><a class="headerlink" href="#evennia.utils.evmore.CmdMore.aliases" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
@ -102,7 +102,7 @@ the <strong>caller.msg()</strong> construct every time the page is updated.</p>
|
|||
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.evmore.CmdMore.search_index_entry">
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'abort next n e top end back quit t a q b', 'category': 'general', 'key': '__noinput_command', 'tags': '', 'text': '\n Manipulate the text paging\n '}</em><a class="headerlink" href="#evennia.utils.evmore.CmdMore.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">search_index_entry</code><em class="property"> = {'aliases': 'n a quit b e next t top q back abort end', 'category': 'general', 'key': '__noinput_command', 'tags': '', 'text': '\n Manipulate the text paging\n '}</em><a class="headerlink" href="#evennia.utils.evmore.CmdMore.search_index_entry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
|
|
|||
|
|
@ -494,7 +494,7 @@ This keyword has no meaning if <strong>width</strong> is set.</p></li>
|
|||
</dl>
|
||||
<p class="rubric">Notes</p>
|
||||
<p>Beyond those table-specific keywords, the non-overlapping keywords
|
||||
of <strong>EcCell.__init__</strong> are also available. These will be passed down
|
||||
of <strong>EvCell.__init__</strong> are also available. These will be passed down
|
||||
to every cell in the table.</p>
|
||||
</dd></dl>
|
||||
|
||||
|
|
@ -527,7 +527,7 @@ to the end.</p>
|
|||
<dl class="field-list simple">
|
||||
<dt class="field-odd">Parameters</dt>
|
||||
<dd class="field-odd"><ul class="simple">
|
||||
<li><p><strong>args</strong> (<strong>EvColum</strong> or multiple strings) – Either a single EvColumn instance or
|
||||
<li><p><strong>args</strong> (<strong>EvColumn</strong> or multiple strings) – Either a single EvColumn instance or
|
||||
a number of data string arguments to be used to create a new column.</p></li>
|
||||
<li><p><strong>header</strong> (<em>str</em><em>, </em><em>optional</em>) – The header text for the column</p></li>
|
||||
<li><p><strong>xpos</strong> (<em>int</em><em>, </em><em>optional</em>) – Index position in table <em>before</em> which
|
||||
|
|
|
|||
|
|
@ -125,7 +125,7 @@ server.log.2020_01_29__2</p>
|
|||
<p>Reformat logging</p>
|
||||
<dl class="py attribute">
|
||||
<dt id="evennia.utils.logger.PortalLogObserver.timeFormat">
|
||||
<code class="sig-name descname">timeFormat</code><em class="property"> = None</em><a class="headerlink" href="#evennia.utils.logger.PortalLogObserver.timeFormat" title="Permalink to this definition">¶</a></dt>
|
||||
<code class="sig-name descname">timeFormat</code><em class="property">: Optional<span class="p">[</span>str<span class="p">]</span></em><em class="property"> = None</em><a class="headerlink" href="#evennia.utils.logger.PortalLogObserver.timeFormat" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="py attribute">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue