mirror of
https://github.com/evennia/evennia.git
synced 2026-03-20 23:06:31 +01:00
554 lines
No EOL
36 KiB
HTML
554 lines
No EOL
36 KiB
HTML
|
||
<!DOCTYPE html>
|
||
|
||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||
<head>
|
||
<meta charset="utf-8" />
|
||
<title>evennia.game_template.server.conf package — Evennia 1.0-dev documentation</title>
|
||
<link rel="stylesheet" href="../_static/alabaster.css" type="text/css" />
|
||
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
|
||
<script id="documentation_options" data-url_root="../" src="../_static/documentation_options.js"></script>
|
||
<script src="../_static/jquery.js"></script>
|
||
<script src="../_static/underscore.js"></script>
|
||
<script src="../_static/doctools.js"></script>
|
||
<script src="../_static/language_data.js"></script>
|
||
<link rel="index" title="Index" href="../genindex.html" />
|
||
<link rel="search" title="Search" href="../search.html" />
|
||
|
||
<link rel="stylesheet" href="../_static/custom.css" type="text/css" />
|
||
|
||
|
||
<meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9" />
|
||
|
||
</head><body>
|
||
|
||
|
||
<div class="document">
|
||
<div class="documentwrapper">
|
||
<div class="bodywrapper">
|
||
|
||
|
||
<div class="body" role="main">
|
||
|
||
<div class="section" id="module-evennia.game_template.server.conf">
|
||
<span id="evennia-game-template-server-conf-package"></span><h1>evennia.game_template.server.conf package<a class="headerlink" href="#module-evennia.game_template.server.conf" title="Permalink to this headline">¶</a></h1>
|
||
<div class="section" id="submodules">
|
||
<h2>Submodules<a class="headerlink" href="#submodules" title="Permalink to this headline">¶</a></h2>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.at_initial_setup">
|
||
<span id="evennia-game-template-server-conf-at-initial-setup-module"></span><h2>evennia.game_template.server.conf.at_initial_setup module<a class="headerlink" href="#module-evennia.game_template.server.conf.at_initial_setup" title="Permalink to this headline">¶</a></h2>
|
||
<p>At_initial_setup module template</p>
|
||
<p>Custom at_initial_setup method. This allows you to hook special
|
||
modifications to the initial server startup process. Note that this
|
||
will only be run once - when the server starts up for the very first
|
||
time! It is called last in the startup process and can thus be used to
|
||
overload things that happened before it.</p>
|
||
<p>The module must contain a global function at_initial_setup(). This
|
||
will be called without arguments. Note that tracebacks in this module
|
||
will be QUIETLY ignored, so make sure to check it well to make sure it
|
||
does what you expect it to.</p>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_initial_setup.at_initial_setup">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_initial_setup.</code><code class="sig-name descname">at_initial_setup</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_initial_setup.html#at_initial_setup"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_initial_setup.at_initial_setup" title="Permalink to this definition">¶</a></dt>
|
||
<dd></dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.at_search">
|
||
<span id="evennia-game-template-server-conf-at-search-module"></span><h2>evennia.game_template.server.conf.at_search module<a class="headerlink" href="#module-evennia.game_template.server.conf.at_search" title="Permalink to this headline">¶</a></h2>
|
||
<p>Search and multimatch handling</p>
|
||
<p>This module allows for overloading two functions used by Evennia’s
|
||
search functionality:</p>
|
||
<blockquote>
|
||
<div><dl class="simple">
|
||
<dt>at_search_result:</dt><dd><p>This is called whenever a result is returned from an object
|
||
search (a common operation in commands). It should (together
|
||
with at_multimatch_input below) define some way to present and
|
||
differentiate between multiple matches (by default these are
|
||
presented as 1-ball, 2-ball etc)</p>
|
||
</dd>
|
||
<dt>at_multimatch_input:</dt><dd><p>This is called with a search term and should be able to
|
||
identify if the user wants to separate a multimatch-result
|
||
(such as that from a previous search). By default, this
|
||
function understands input on the form 1-ball, 2-ball etc as
|
||
indicating that the 1st or 2nd match for “ball” should be
|
||
used.</p>
|
||
</dd>
|
||
</dl>
|
||
</div></blockquote>
|
||
<p>This module is not called by default, to use it, add the following
|
||
line to your settings file:</p>
|
||
<blockquote>
|
||
<div><p>SEARCH_AT_RESULT = “server.conf.at_search.at_search_result”</p>
|
||
</div></blockquote>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_search.at_search_result">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_search.</code><code class="sig-name descname">at_search_result</code><span class="sig-paren">(</span><em class="sig-param">matches</em>, <em class="sig-param">caller</em>, <em class="sig-param">query=''</em>, <em class="sig-param">quiet=False</em>, <em class="sig-param">**kwargs</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_search.html#at_search_result"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_search.at_search_result" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is a generic hook for handling all processing of a search
|
||
result, including error reporting.</p>
|
||
<dl class="field-list simple">
|
||
<dt class="field-odd">Parameters</dt>
|
||
<dd class="field-odd"><ul class="simple">
|
||
<li><p><strong>matches</strong> (<em>list</em>) – This is a list of 0, 1 or more typeclass instances,
|
||
the matched result of the search. If 0, a nomatch error should
|
||
be echoed, and if >1, multimatch errors should be given. Only
|
||
if a single match should the result pass through.</p></li>
|
||
<li><p><strong>caller</strong> (<em>Object</em>) – The object performing the search and/or which should</p></li>
|
||
<li><p><strong>error messages.</strong> (<em>receive</em>) – </p></li>
|
||
</ul>
|
||
</dd>
|
||
</dl>
|
||
<dl class="simple">
|
||
<dt>query (str, optional): The search query used to produce <cite>matches</cite>.</dt><dd><dl class="simple">
|
||
<dt>quiet (bool, optional): If <cite>True</cite>, no messages will be echoed to caller</dt><dd><p>on errors.</p>
|
||
</dd>
|
||
</dl>
|
||
</dd>
|
||
<dt>Kwargs:</dt><dd><p>nofound_string (str): Replacement string to echo on a notfound error.
|
||
multimatch_string (str): Replacement string to echo on a multimatch error.</p>
|
||
</dd>
|
||
</dl>
|
||
<dl class="field-list simple">
|
||
<dt class="field-odd">Returns</dt>
|
||
<dd class="field-odd"><p><dl class="simple">
|
||
<dt>This is always a single result</dt><dd><p>or <cite>None</cite>. If <cite>None</cite>, any error reporting/handling should
|
||
already have happened.</p>
|
||
</dd>
|
||
</dl>
|
||
</p>
|
||
</dd>
|
||
<dt class="field-even">Return type</dt>
|
||
<dd class="field-even"><p>processed_result (Object or None)</p>
|
||
</dd>
|
||
</dl>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.at_server_startstop">
|
||
<span id="evennia-game-template-server-conf-at-server-startstop-module"></span><h2>evennia.game_template.server.conf.at_server_startstop module<a class="headerlink" href="#module-evennia.game_template.server.conf.at_server_startstop" title="Permalink to this headline">¶</a></h2>
|
||
<p>Server startstop hooks</p>
|
||
<p>This module contains functions called by Evennia at various
|
||
points during its startup, reload and shutdown sequence. It
|
||
allows for customizing the server operation as desired.</p>
|
||
<p>This module must contain at least these global functions:</p>
|
||
<p>at_server_start()
|
||
at_server_stop()
|
||
at_server_reload_start()
|
||
at_server_reload_stop()
|
||
at_server_cold_start()
|
||
at_server_cold_stop()</p>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_server_startstop.at_server_cold_start">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_server_startstop.</code><code class="sig-name descname">at_server_cold_start</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_server_startstop.html#at_server_cold_start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_server_startstop.at_server_cold_start" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called only when the server starts “cold”, i.e. after a
|
||
shutdown or a reset.</p>
|
||
</dd></dl>
|
||
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_server_startstop.at_server_cold_stop">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_server_startstop.</code><code class="sig-name descname">at_server_cold_stop</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_server_startstop.html#at_server_cold_stop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_server_startstop.at_server_cold_stop" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called only when the server goes down due to a shutdown or
|
||
reset.</p>
|
||
</dd></dl>
|
||
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_server_startstop.at_server_reload_start">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_server_startstop.</code><code class="sig-name descname">at_server_reload_start</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_server_startstop.html#at_server_reload_start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_server_startstop.at_server_reload_start" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called only when server starts back up after a reload.</p>
|
||
</dd></dl>
|
||
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_server_startstop.at_server_reload_stop">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_server_startstop.</code><code class="sig-name descname">at_server_reload_stop</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_server_startstop.html#at_server_reload_stop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_server_startstop.at_server_reload_stop" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called only time the server stops before a reload.</p>
|
||
</dd></dl>
|
||
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_server_startstop.at_server_start">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_server_startstop.</code><code class="sig-name descname">at_server_start</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_server_startstop.html#at_server_start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_server_startstop.at_server_start" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called every time the server starts up, regardless of
|
||
how it was shut down.</p>
|
||
</dd></dl>
|
||
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.at_server_startstop.at_server_stop">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.at_server_startstop.</code><code class="sig-name descname">at_server_stop</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/at_server_startstop.html#at_server_stop"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.at_server_startstop.at_server_stop" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called just before the server is shut down, regardless
|
||
of it is for a reload, reset or shutdown.</p>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.cmdparser">
|
||
<span id="evennia-game-template-server-conf-cmdparser-module"></span><h2>evennia.game_template.server.conf.cmdparser module<a class="headerlink" href="#module-evennia.game_template.server.conf.cmdparser" title="Permalink to this headline">¶</a></h2>
|
||
<p>Changing the default command parser</p>
|
||
<p>The cmdparser is responsible for parsing the raw text inserted by the
|
||
user, identifying which command/commands match and return one or more
|
||
matching command objects. It is called by Evennia’s cmdhandler and
|
||
must accept input and return results on the same form. The default
|
||
handler is very generic so you usually don’t need to overload this
|
||
unless you have very exotic parsing needs; advanced parsing is best
|
||
done at the Command.parse level.</p>
|
||
<p>The default cmdparser understands the following command combinations
|
||
(where [] marks optional parts.)</p>
|
||
<p>[cmdname[ cmdname2 cmdname3 …] [the rest]</p>
|
||
<p>A command may consist of any number of space-separated words of any
|
||
length, and contain any character. It may also be empty.</p>
|
||
<p>The parser makes use of the cmdset to find command candidates. The
|
||
parser return a list of matches. Each match is a tuple with its first
|
||
three elements being the parsed cmdname (lower case), the remaining
|
||
arguments, and the matched cmdobject from the cmdset.</p>
|
||
<p>This module is not accessed by default. To tell Evennia to use it
|
||
instead of the default command parser, add the following line to
|
||
your settings file:</p>
|
||
<blockquote>
|
||
<div><p>COMMAND_PARSER = “server.conf.cmdparser.cmdparser”</p>
|
||
</div></blockquote>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.cmdparser.cmdparser">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.cmdparser.</code><code class="sig-name descname">cmdparser</code><span class="sig-paren">(</span><em class="sig-param">raw_string</em>, <em class="sig-param">cmdset</em>, <em class="sig-param">caller</em>, <em class="sig-param">match_index=None</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/cmdparser.html#cmdparser"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.cmdparser.cmdparser" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This function is called by the cmdhandler once it has
|
||
gathered and merged all valid cmdsets valid for this particular parsing.</p>
|
||
<p>raw_string - the unparsed text entered by the caller.
|
||
cmdset - the merged, currently valid cmdset
|
||
caller - the caller triggering this parsing
|
||
match_index - an optional integer index to pick a given match in a</p>
|
||
<blockquote>
|
||
<div><p>list of same-named command matches.</p>
|
||
</div></blockquote>
|
||
<dl class="field-list simple">
|
||
<dt class="field-odd">Returns</dt>
|
||
<dd class="field-odd"><p><dl class="simple">
|
||
<dt>[(cmdname, args, cmdobj, cmdlen, mratio), …]</dt><dd><p>where cmdname is the matching command name and args is
|
||
everything not included in the cmdname. Cmdobj is the actual
|
||
command instance taken from the cmdset, cmdlen is the length
|
||
of the command name and the mratio is some quality value to
|
||
(possibly) separate multiple matches.</p>
|
||
</dd>
|
||
</dl>
|
||
</p>
|
||
</dd>
|
||
<dt class="field-even">Return type</dt>
|
||
<dd class="field-even"><p>list of tuples</p>
|
||
</dd>
|
||
</dl>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.connection_screens">
|
||
<span id="evennia-game-template-server-conf-connection-screens-module"></span><h2>evennia.game_template.server.conf.connection_screens module<a class="headerlink" href="#module-evennia.game_template.server.conf.connection_screens" title="Permalink to this headline">¶</a></h2>
|
||
<p>Connection screen</p>
|
||
<p>This is the text to show the user when they first connect to the game (before
|
||
they log in).</p>
|
||
<p>To change the login screen in this module, do one of the following:</p>
|
||
<ul class="simple">
|
||
<li><p>Define a function <cite>connection_screen()</cite>, taking no arguments. This will be
|
||
called first and must return the full string to act as the connection screen.
|
||
This can be used to produce more dynamic screens.</p></li>
|
||
<li><p>Alternatively, define a string variable in the outermost scope of this module
|
||
with the connection string that should be displayed. If more than one such
|
||
variable is given, Evennia will pick one of them at random.</p></li>
|
||
</ul>
|
||
<p>The commands available to the user when the connection screen is shown
|
||
are defined in evennia.default_cmds.UnloggedinCmdSet. The parsing and display
|
||
of the screen is done by the unlogged-in “look” command.</p>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.inlinefuncs">
|
||
<span id="evennia-game-template-server-conf-inlinefuncs-module"></span><h2>evennia.game_template.server.conf.inlinefuncs module<a class="headerlink" href="#module-evennia.game_template.server.conf.inlinefuncs" title="Permalink to this headline">¶</a></h2>
|
||
<p>Inlinefunc</p>
|
||
<p>Inline functions allow for direct conversion of text users mark in a
|
||
special way. Inlinefuncs are deactivated by default. To activate, add</p>
|
||
<blockquote>
|
||
<div><p>INLINEFUNC_ENABLED = True</p>
|
||
</div></blockquote>
|
||
<p>to your settings file. The default inlinefuncs are found in
|
||
evennia.utils.inlinefunc.</p>
|
||
<p>In text, usage is straightforward:</p>
|
||
<p>$funcname([arg1,[arg2,…]])</p>
|
||
<dl class="simple">
|
||
<dt>Example 1 (using the “pad” inlinefunc):</dt><dd><p>say This is $pad(“a center-padded text”, 50,c,-) of width 50.
|
||
->
|
||
John says, “This is ————– a center-padded text————— of width 50.”</p>
|
||
</dd>
|
||
<dt>Example 2 (using nested “pad” and “time” inlinefuncs):</dt><dd><p>say The time is $pad($time(), 30)right now.
|
||
->
|
||
John says, “The time is Oct 25, 11:09 right now.”</p>
|
||
</dd>
|
||
</dl>
|
||
<p>To add more inline functions, add them to this module, using
|
||
the following call signature:</p>
|
||
<blockquote>
|
||
<div><p>def funcname(text, <a href="#id1"><span class="problematic" id="id2">*</span></a>args, <a href="#id3"><span class="problematic" id="id4">**</span></a>kwargs)</p>
|
||
</div></blockquote>
|
||
<p>where <cite>text</cite> is always the part between {funcname(args) and
|
||
{/funcname and the <a href="#id5"><span class="problematic" id="id6">*</span></a>args are taken from the appropriate part of the
|
||
call. If no {/funcname is given, <cite>text</cite> will be the empty string.</p>
|
||
<p>It is important that the inline function properly clean the
|
||
incoming <cite>args</cite>, checking their type and replacing them with sane
|
||
defaults if needed. If impossible to resolve, the unmodified text
|
||
should be returned. The inlinefunc should never cause a traceback.</p>
|
||
<p>While the inline function should accept <a href="#id7"><span class="problematic" id="id8">**</span></a>kwargs, the keyword is
|
||
never accepted as a valid call - this is only intended to be used
|
||
internally by Evennia, notably to send the <cite>session</cite> keyword to
|
||
the function; this is the session of the object viewing the string
|
||
and can be used to customize it to each session.</p>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.inputfuncs">
|
||
<span id="evennia-game-template-server-conf-inputfuncs-module"></span><h2>evennia.game_template.server.conf.inputfuncs module<a class="headerlink" href="#module-evennia.game_template.server.conf.inputfuncs" title="Permalink to this headline">¶</a></h2>
|
||
<p>Input functions</p>
|
||
<p>Input functions are always called from the client (they handle server
|
||
input, hence the name).</p>
|
||
<p>This module is loaded by being included in the
|
||
<cite>settings.INPUT_FUNC_MODULES</cite> tuple.</p>
|
||
<p>All <em>global functions</em> included in this module are considered
|
||
input-handler functions and can be called by the client to handle
|
||
input.</p>
|
||
<p>An input function must have the following call signature:</p>
|
||
<blockquote>
|
||
<div><p>cmdname(session, <a href="#id9"><span class="problematic" id="id10">*</span></a>args, <a href="#id11"><span class="problematic" id="id12">**</span></a>kwargs)</p>
|
||
</div></blockquote>
|
||
<p>Where session will be the active session and <a href="#id13"><span class="problematic" id="id14">*</span></a>args, <a href="#id15"><span class="problematic" id="id16">**</span></a>kwargs are extra
|
||
incoming arguments and keyword properties.</p>
|
||
<p>A special command is the “default” command, which is will be called
|
||
when no other cmdname matches. It also receives the non-found cmdname
|
||
as argument.</p>
|
||
<blockquote>
|
||
<div><p>default(session, cmdname, <a href="#id17"><span class="problematic" id="id18">*</span></a>args, <a href="#id19"><span class="problematic" id="id20">**</span></a>kwargs)</p>
|
||
</div></blockquote>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.lockfuncs">
|
||
<span id="evennia-game-template-server-conf-lockfuncs-module"></span><h2>evennia.game_template.server.conf.lockfuncs module<a class="headerlink" href="#module-evennia.game_template.server.conf.lockfuncs" title="Permalink to this headline">¶</a></h2>
|
||
<p>Lockfuncs</p>
|
||
<p>Lock functions are functions available when defining lock strings,
|
||
which in turn limits access to various game systems.</p>
|
||
<p>All functions defined globally in this module are assumed to be
|
||
available for use in lockstrings to determine access. See the
|
||
Evennia documentation for more info on locks.</p>
|
||
<p>A lock function is always called with two arguments, accessing_obj and
|
||
accessed_obj, followed by any number of arguments. All possible
|
||
arguments should be handled with <a href="#id21"><span class="problematic" id="id22">*</span></a>args, <a href="#id23"><span class="problematic" id="id24">**</span></a>kwargs. The lock function
|
||
should handle all eventual tracebacks by logging the error and
|
||
returning False.</p>
|
||
<p>Lock functions in this module extend (and will overload same-named)
|
||
lock functions from evennia.locks.lockfuncs.</p>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.mssp">
|
||
<span id="evennia-game-template-server-conf-mssp-module"></span><h2>evennia.game_template.server.conf.mssp module<a class="headerlink" href="#module-evennia.game_template.server.conf.mssp" title="Permalink to this headline">¶</a></h2>
|
||
<p>MSSP (Mud Server Status Protocol) meta information</p>
|
||
<p>Modify this file to specify what MUD listing sites will report about your game.
|
||
All fields are static. The number of currently active players and your game’s
|
||
current uptime will be added automatically by Evennia.</p>
|
||
<p>You don’t have to fill in everything (and most fields are not shown/used by all
|
||
crawlers anyway); leave the default if so needed. You need to reload the server
|
||
before the updated information is made available to crawlers (reloading does
|
||
not affect uptime).</p>
|
||
<p>After changing the values in this file, you must register your game with the
|
||
MUD website list you want to track you. The listing crawler will then regularly
|
||
connect to your server to get the latest info. No further configuration is
|
||
needed on the Evennia side.</p>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.portal_services_plugins">
|
||
<span id="evennia-game-template-server-conf-portal-services-plugins-module"></span><h2>evennia.game_template.server.conf.portal_services_plugins module<a class="headerlink" href="#module-evennia.game_template.server.conf.portal_services_plugins" title="Permalink to this headline">¶</a></h2>
|
||
<p>Start plugin services</p>
|
||
<p>This plugin module can define user-created services for the Portal to
|
||
start.</p>
|
||
<p>This module must handle all imports and setups required to start
|
||
twisted services (see examples in evennia.server.portal.portal). It
|
||
must also contain a function start_plugin_services(application).
|
||
Evennia will call this function with the main Portal application (so
|
||
your services can be added to it). The function should not return
|
||
anything. Plugin services are started last in the Portal startup
|
||
process.</p>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.portal_services_plugins.start_plugin_services">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.portal_services_plugins.</code><code class="sig-name descname">start_plugin_services</code><span class="sig-paren">(</span><em class="sig-param">portal</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/portal_services_plugins.html#start_plugin_services"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.portal_services_plugins.start_plugin_services" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This hook is called by Evennia, last in the Portal startup process.</p>
|
||
<p>portal - a reference to the main portal application.</p>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="evennia-game-template-server-conf-secret-settings-module">
|
||
<h2>evennia.game_template.server.conf.secret_settings module<a class="headerlink" href="#evennia-game-template-server-conf-secret-settings-module" title="Permalink to this headline">¶</a></h2>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.server_services_plugins">
|
||
<span id="evennia-game-template-server-conf-server-services-plugins-module"></span><h2>evennia.game_template.server.conf.server_services_plugins module<a class="headerlink" href="#module-evennia.game_template.server.conf.server_services_plugins" title="Permalink to this headline">¶</a></h2>
|
||
<p>Server plugin services</p>
|
||
<p>This plugin module can define user-created services for the Server to
|
||
start.</p>
|
||
<p>This module must handle all imports and setups required to start a
|
||
twisted service (see examples in evennia.server.server). It must also
|
||
contain a function start_plugin_services(application). Evennia will
|
||
call this function with the main Server application (so your services
|
||
can be added to it). The function should not return anything. Plugin
|
||
services are started last in the Server startup process.</p>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.server_services_plugins.start_plugin_services">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.server_services_plugins.</code><code class="sig-name descname">start_plugin_services</code><span class="sig-paren">(</span><em class="sig-param">server</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/server_services_plugins.html#start_plugin_services"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.server_services_plugins.start_plugin_services" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This hook is called by Evennia, last in the Server startup process.</p>
|
||
<p>server - a reference to the main server application.</p>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.serversession">
|
||
<span id="evennia-game-template-server-conf-serversession-module"></span><h2>evennia.game_template.server.conf.serversession module<a class="headerlink" href="#module-evennia.game_template.server.conf.serversession" title="Permalink to this headline">¶</a></h2>
|
||
<p>ServerSession</p>
|
||
<p>The serversession is the Server-side in-memory representation of a
|
||
user connecting to the game. Evennia manages one Session per
|
||
connection to the game. So a user logged into the game with multiple
|
||
clients (if Evennia is configured to allow that) will have multiple
|
||
sessions tied to one Account object. All communication between Evennia
|
||
and the real-world user goes through the Session(s) associated with that user.</p>
|
||
<p>It should be noted that modifying the Session object is not usually
|
||
necessary except for the most custom and exotic designs - and even
|
||
then it might be enough to just add custom session-level commands to
|
||
the SessionCmdSet instead.</p>
|
||
<p>This module is not normally called. To tell Evennia to use the class
|
||
in this module instead of the default one, add the following to your
|
||
settings file:</p>
|
||
<blockquote>
|
||
<div><p>SERVER_SESSION_CLASS = “server.conf.serversession.ServerSession”</p>
|
||
</div></blockquote>
|
||
<dl class="class">
|
||
<dt id="evennia.game_template.server.conf.serversession.ServerSession">
|
||
<em class="property">class </em><code class="sig-prename descclassname">evennia.game_template.server.conf.serversession.</code><code class="sig-name descname">ServerSession</code><a class="reference internal" href="../_modules/evennia/game_template/server/conf/serversession.html#ServerSession"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.serversession.ServerSession" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>Bases: <a class="reference internal" href="evennia.server.html#evennia.server.serversession.ServerSession" title="evennia.server.serversession.ServerSession"><code class="xref py py-class docutils literal notranslate"><span class="pre">evennia.server.serversession.ServerSession</span></code></a></p>
|
||
<p>This class represents a player’s session and is a template for
|
||
individual protocols to communicate with Evennia.</p>
|
||
<p>Each account gets one or more sessions assigned to them whenever they connect
|
||
to the game server. All communication between game and account goes
|
||
through their session(s).</p>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
<div class="section" id="evennia-game-template-server-conf-settings-module">
|
||
<h2>evennia.game_template.server.conf.settings module<a class="headerlink" href="#evennia-game-template-server-conf-settings-module" title="Permalink to this headline">¶</a></h2>
|
||
</div>
|
||
<div class="section" id="module-evennia.game_template.server.conf.web_plugins">
|
||
<span id="evennia-game-template-server-conf-web-plugins-module"></span><h2>evennia.game_template.server.conf.web_plugins module<a class="headerlink" href="#module-evennia.game_template.server.conf.web_plugins" title="Permalink to this headline">¶</a></h2>
|
||
<p>Web plugin hooks.</p>
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.web_plugins.at_webproxy_root_creation">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.web_plugins.</code><code class="sig-name descname">at_webproxy_root_creation</code><span class="sig-paren">(</span><em class="sig-param">web_root</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/web_plugins.html#at_webproxy_root_creation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.web_plugins.at_webproxy_root_creation" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This function can modify the portal proxy service.
|
||
:param web_root: The Evennia</p>
|
||
<blockquote>
|
||
<div><p>Website application. Use .putChild() to add new
|
||
subdomains that are Portal-accessible over TCP;
|
||
primarily for new protocol development, but suitable
|
||
for other shenanigans.</p>
|
||
</div></blockquote>
|
||
<dl class="field-list simple">
|
||
</dl>
|
||
</dd></dl>
|
||
|
||
<dl class="function">
|
||
<dt id="evennia.game_template.server.conf.web_plugins.at_webserver_root_creation">
|
||
<code class="sig-prename descclassname">evennia.game_template.server.conf.web_plugins.</code><code class="sig-name descname">at_webserver_root_creation</code><span class="sig-paren">(</span><em class="sig-param">web_root</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/evennia/game_template/server/conf/web_plugins.html#at_webserver_root_creation"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#evennia.game_template.server.conf.web_plugins.at_webserver_root_creation" title="Permalink to this definition">¶</a></dt>
|
||
<dd><p>This is called as the web server has finished building its default
|
||
path tree. At this point, the media/ and static/ URIs have already
|
||
been added to the web root.</p>
|
||
<dl class="field-list simple">
|
||
<dt class="field-odd">Parameters</dt>
|
||
<dd class="field-odd"><p><strong>web_root</strong> (<em>twisted.web.resource.Resource</em>) – The root
|
||
resource of the URI tree. Use .putChild() to
|
||
add new subdomains to the tree.</p>
|
||
</dd>
|
||
<dt class="field-even">Returns</dt>
|
||
<dd class="field-even"><p><dl class="simple">
|
||
<dt>The potentially</dt><dd><p>modified root structure.</p>
|
||
</dd>
|
||
</dl>
|
||
</p>
|
||
</dd>
|
||
<dt class="field-odd">Return type</dt>
|
||
<dd class="field-odd"><p>web_root (twisted.web.resource.Resource)</p>
|
||
</dd>
|
||
</dl>
|
||
<p class="rubric">Example</p>
|
||
<p>from twisted.web import static
|
||
my_page = static.File(“web/mypage/”)
|
||
my_page.indexNames = [“index.html”]
|
||
web_root.putChild(“mypage”, my_page)</p>
|
||
</dd></dl>
|
||
|
||
</div>
|
||
</div>
|
||
|
||
|
||
</div>
|
||
|
||
</div>
|
||
</div>
|
||
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
|
||
<div class="sphinxsidebarwrapper">
|
||
<div id="searchbox" style="display: none" role="search">
|
||
<h3 id="searchlabel">Quick search</h3>
|
||
<div class="searchformwrapper">
|
||
<form class="search" action="../search.html" method="get">
|
||
<input type="text" name="q" aria-labelledby="searchlabel" />
|
||
<input type="submit" value="Go" />
|
||
</form>
|
||
</div>
|
||
</div>
|
||
<script>$('#searchbox').show(0);</script>
|
||
<p><h3><a href="../index.html">Table of Contents</a></h3>
|
||
<ul>
|
||
<li><a class="reference internal" href="#">evennia.game_template.server.conf package</a><ul>
|
||
<li><a class="reference internal" href="#submodules">Submodules</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.at_initial_setup">evennia.game_template.server.conf.at_initial_setup module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.at_search">evennia.game_template.server.conf.at_search module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.at_server_startstop">evennia.game_template.server.conf.at_server_startstop module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.cmdparser">evennia.game_template.server.conf.cmdparser module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.connection_screens">evennia.game_template.server.conf.connection_screens module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.inlinefuncs">evennia.game_template.server.conf.inlinefuncs module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.inputfuncs">evennia.game_template.server.conf.inputfuncs module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.lockfuncs">evennia.game_template.server.conf.lockfuncs module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.mssp">evennia.game_template.server.conf.mssp module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.portal_services_plugins">evennia.game_template.server.conf.portal_services_plugins module</a></li>
|
||
<li><a class="reference internal" href="#evennia-game-template-server-conf-secret-settings-module">evennia.game_template.server.conf.secret_settings module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.server_services_plugins">evennia.game_template.server.conf.server_services_plugins module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.serversession">evennia.game_template.server.conf.serversession module</a></li>
|
||
<li><a class="reference internal" href="#evennia-game-template-server-conf-settings-module">evennia.game_template.server.conf.settings module</a></li>
|
||
<li><a class="reference internal" href="#module-evennia.game_template.server.conf.web_plugins">evennia.game_template.server.conf.web_plugins module</a></li>
|
||
</ul>
|
||
</li>
|
||
</ul>
|
||
<div class="relations">
|
||
<h3>Related Topics</h3>
|
||
<ul>
|
||
<li><a href="../index.html">Documentation overview</a><ul>
|
||
</ul></li>
|
||
</ul>
|
||
</div>
|
||
<div role="note" aria-label="source link">
|
||
<!--h3>This Page</h3-->
|
||
<ul class="this-page-menu">
|
||
<li><a href="../_sources/api/evennia.game_template.server.conf.rst.txt"
|
||
rel="nofollow">Show Page Source</a></li>
|
||
</ul>
|
||
</div>
|
||
<h3>Versions</h3>
|
||
<ul>
|
||
<li><a href="evennia.game_template.server.conf.html">1.0-dev (develop branch)</a></li>
|
||
<li><a href="../../../versions/0.9.1/api/evennia.game_template.server.conf.html">0.9.1 (master branch)</a></li>
|
||
</ul>
|
||
|
||
</div>
|
||
</div>
|
||
<div class="clearer"></div>
|
||
</div>
|
||
<div class="footer">
|
||
©2020, The Evennia developer community.
|
||
|
||
|
|
||
Powered by <a href="http://sphinx-doc.org/">Sphinx 2.4.4</a>
|
||
& <a href="https://github.com/bitprophet/alabaster">Alabaster 0.7.12</a>
|
||
|
||
|
|
||
<a href="../_sources/api/evennia.game_template.server.conf.rst.txt"
|
||
rel="nofollow">Page source</a>
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</body>
|
||
</html> |