From f5c0d5fe6e21ffe378ee88b4daa1bf312c0c5bb8 Mon Sep 17 00:00:00 2001 From: Evennia docbuilder action Date: Sun, 21 May 2023 19:09:48 +0000 Subject: [PATCH] Updated HTML docs. --- docs/1.0/.buildinfo | 2 +- docs/1.0/Coding/Changelog.html | 12 +- docs/1.0/Components/Tags.html | 47 +++-- docs/1.0/Contribs/Contribs-Overview.html | 2 +- docs/1.0/_modules/evennia.html | 17 +- .../evennia/commands/default/system.html | 24 ++- .../_modules/evennia/typeclasses/models.html | 7 +- .../_modules/evennia/typeclasses/tags.html | 161 ++++++++++++++++-- docs/1.0/_sources/Coding/Changelog.md.txt | 12 +- docs/1.0/_sources/Components/Tags.md.txt | 45 +++-- ....game_systems.containers.containers.md.txt | 10 ++ ...nia.contrib.game_systems.containers.md.txt | 18 ++ ...ntrib.game_systems.containers.tests.md.txt | 10 ++ .../api/evennia.contrib.game_systems.md.txt | 1 + docs/1.0/api/evennia-api.html | 5 + ...evennia.commands.default.batchprocess.html | 4 +- .../evennia.commands.default.building.html | 12 +- .../api/evennia.commands.default.general.html | 8 +- .../api/evennia.commands.default.system.html | 4 +- .../api/evennia.commands.default.tests.html | 2 +- .../evennia.commands.default.unloggedin.html | 12 +- ....base_systems.email_login.email_login.html | 12 +- ...b.base_systems.ingame_python.commands.html | 4 +- ...systems.mux_comms_cmds.mux_comms_cmds.html | 8 +- ...rib.full_systems.evscaperoom.commands.html | 24 +-- ...a.contrib.game_systems.clothing.tests.html | 10 +- ...ib.game_systems.containers.containers.html | 144 ++++++++++++++++ ...ennia.contrib.game_systems.containers.html | 148 ++++++++++++++++ ...contrib.game_systems.containers.tests.html | 144 ++++++++++++++++ ...vennia.contrib.game_systems.cooldowns.html | 10 +- .../1.0/api/evennia.contrib.game_systems.html | 5 + ...trib.game_systems.turnbattle.tb_basic.html | 4 +- ...trib.game_systems.turnbattle.tb_equip.html | 4 +- ...trib.game_systems.turnbattle.tb_items.html | 4 +- ...trib.game_systems.turnbattle.tb_magic.html | 4 +- ...trib.game_systems.turnbattle.tb_range.html | 4 +- docs/1.0/api/evennia.contrib.html | 5 + ...evennia.contrib.rpg.rpsystem.rpsystem.html | 8 +- ...ia.contrib.tutorials.evadventure.npcs.html | 15 +- ...ntrib.tutorials.red_button.red_button.html | 16 +- ...trib.tutorials.tutorial_world.objects.html | 12 +- ...ontrib.tutorials.tutorial_world.rooms.html | 4 +- ...utils.git_integration.git_integration.html | 4 +- docs/1.0/api/evennia.html | 6 + docs/1.0/api/evennia.typeclasses.tags.html | 51 +++++- docs/1.0/api/evennia.utils.eveditor.html | 4 +- docs/1.0/api/evennia.utils.evmenu.html | 4 +- docs/1.0/api/evennia.utils.evmore.html | 4 +- docs/1.0/genindex.html | 6 + docs/1.0/objects.inv | Bin 162567 -> 162683 bytes docs/1.0/searchindex.js | 2 +- 51 files changed, 875 insertions(+), 210 deletions(-) create mode 100644 docs/1.0/_sources/api/evennia.contrib.game_systems.containers.containers.md.txt create mode 100644 docs/1.0/_sources/api/evennia.contrib.game_systems.containers.md.txt create mode 100644 docs/1.0/_sources/api/evennia.contrib.game_systems.containers.tests.md.txt create mode 100644 docs/1.0/api/evennia.contrib.game_systems.containers.containers.html create mode 100644 docs/1.0/api/evennia.contrib.game_systems.containers.html create mode 100644 docs/1.0/api/evennia.contrib.game_systems.containers.tests.html diff --git a/docs/1.0/.buildinfo b/docs/1.0/.buildinfo index f125147e08..6fc3451f70 100644 --- a/docs/1.0/.buildinfo +++ b/docs/1.0/.buildinfo @@ -1,4 +1,4 @@ # Sphinx build info version 1 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. -config: 96cd01a646747ff4753f61aa6f956ce1 +config: 8cf66312f2f25f2121a051ec1d1b1577 tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/docs/1.0/Coding/Changelog.html b/docs/1.0/Coding/Changelog.html index 7a9bcc3987..23652fb0c3 100644 --- a/docs/1.0/Coding/Changelog.html +++ b/docs/1.0/Coding/Changelog.html @@ -173,11 +173,19 @@

Main branch

diff --git a/docs/1.0/Components/Tags.html b/docs/1.0/Components/Tags.html index 25a30def32..512b28eba6 100644 --- a/docs/1.0/Components/Tags.html +++ b/docs/1.0/Components/Tags.html @@ -126,16 +126,24 @@
-
In code, using TagProperty (auto-assign tag to all instances of the class)
+
In code, using TagProperty or TagCategoryProperty
from evennia import DefaultObject
-from evennia import TagProperty
+from evennia import TagProperty, TagCategoryProperty
+
 class Sword(DefaultObject): 
+    # name of property is the tagkey, category as argument
     can_be_wielded = TagProperty(category='combat')
     has_sharp_edge = TagProperty(category='combat')
+
+    # name of property is the category, tag-keys are arguments
+    damage_type = TagCategoryProperty("piercing", "slashing")
+    crafting_element = TagCategory("blade", "hilt", "pommel") 
+        
 

Tags are short text lables one can ‘hang’ on objects in order to organize, group and quickly find out their properties. An Evennia entity can be tagged by any number of tags. They are more efficient than Attributes since on the database-side, Tags are shared between all objects with that particular tag. A tag does not carry a value in itself; it either sits on the entity

+

You manage Tags using the TagHandler (.tags) on typeclassed entities. You can also assign Tags on the class level through the TagProperty (one tag, one category per line) or the TagCategoryProperty (one category, multiple tags per line). Both of these use the TagHandler under the hood, they are just convenient ways to add tags already when you define your class.

Above, the tags inform us that the Sword is both sharp and can be wielded. If that’s all they do, they could just be a normal Python flag. When tags become important is if there are a lot of objects with different combinations of tags. Maybe you have a magical spell that dulls all sharp-edged objects in the castle - whether sword, dagger, spear or kitchen knife! You can then just grab all objects with the has_sharp_edge tag. Another example would be a weather script affecting all rooms tagged as outdoors or finding all characters tagged with belongs_to_fighter_guild.

In Evennia, Tags are technically also used to implement Aliases (alternative names for objects) and Permissions (simple strings for Locks to check for).

@@ -144,35 +152,23 @@ Another example would be a weather script affecting all rooms tagged as

Properties of Tags (and Aliases and Permissions)

Tags are unique. This means that there is only ever one Tag object with a given key and category.

-
-

Not specifying a category (default) gives the tag a category of None, which is also considered a -unique key + category combination.

-
-

When Tags are assigned to game entities, these entities are actually sharing the same Tag. This -means that Tags are not suitable for storing information about a single object - use an +

+

Important

+

Not specifying a category (default) gives the tag a category of None, which is also considered a unique key + category combination. You cannot use TagCategoryProperty to set Tags with None categories, since the property name may not be None. Use the TagHandler (or TagProperty) for this.

+
+

When Tags are assigned to game entities, these entities are actually sharing the same Tag. This means that Tags are not suitable for storing information about a single object - use an Attribute for this instead. Tags are a lot more limited than Attributes but this also makes them very quick to lookup in the database - this is the whole point.

Tags have the following properties, stored in the database:

  • key - the name of the Tag. This is the main property to search for when looking up a Tag.

  • -
  • category - this category allows for retrieving only specific subsets of tags used for -different purposes. You could have one category of tags for “zones”, another for “outdoor -locations”, for example. If not given, the category will be None, which is also considered a -separate, default, category.

  • -
  • data - this is an optional text field with information about the tag. Remember that Tags are -shared between entities, so this field cannot hold any object-specific information. Usually it would -be used to hold info about the group of entities the Tag is tagging - possibly used for contextual -help like a tool tip. It is not used by default.

  • +
  • category - this category allows for retrieving only specific subsets of tags used for different purposes. You could have one category of tags for “zones”, another for “outdoor locations”, for example. If not given, the category will be None, which is also considered a separate, default, category.

  • +
  • data - this is an optional text field with information about the tag. Remember that Tags are shared between entities, so this field cannot hold any object-specific information. Usually it would be used to hold info about the group of entities the Tag is tagging - possibly used for contextual help like a tool tip. It is not used by default.

-

There are also two special properties. These should usually not need to be changed or set, it is -used internally by Evennia to implement various other uses it makes of the Tag object:

+

There are also two special properties. These should usually not need to be changed or set, it is used internally by Evennia to implement various other uses it makes of the Tag object:

    -
  • model - this holds a natural-key description of the model object that this tag deals with, -on the form application.modelclass, for example objects.objectdb. It used by the TagHandler of -each entity type for correctly storing the data behind the scenes.

  • -
  • tagtype - this is a “top-level category” of sorts for the inbuilt children of Tags, namely -Aliases and Permissions. The Taghandlers using this special field are especially intended to -free up the category property for any use you desire.

  • +
  • model - this holds a natural-key description of the model object that this tag deals with, on the form application.modelclass, for example objects.objectdb. It used by the TagHandler of each entity type for correctly storing the data behind the scenes.

  • +
  • tagtype - this is a “top-level category” of sorts for the inbuilt children of Tags, namely Aliases and Permissions. The Taghandlers using this special field are especially intended to free up the category property for any use you desire.

@@ -261,8 +257,7 @@ used in the same way as Tags above:

all_aliases = boy.aliases.all() -

and so on. Similarly to how @tag works in-game, there is also the @perm command for assigning -permissions and @alias command for aliases.

+

and so on. Similarly to how tag works in-game, there is also the perm command for assigning permissions and @alias command for aliases.

diff --git a/docs/1.0/Contribs/Contribs-Overview.html b/docs/1.0/Contribs/Contribs-Overview.html index 08eda7318c..da9e6bf36e 100644 --- a/docs/1.0/Contribs/Contribs-Overview.html +++ b/docs/1.0/Contribs/Contribs-Overview.html @@ -485,7 +485,7 @@ look of these clothes are appended to the character’s description when worn.

Installation

-

Read the documentation - Browse the Code

+

Read the documentation - Browse the Code

cooldowns

Contribution by owllex, 2021

diff --git a/docs/1.0/_modules/evennia.html b/docs/1.0/_modules/evennia.html index 8e382fb2e3..cb59d5e5bb 100644 --- a/docs/1.0/_modules/evennia.html +++ b/docs/1.0/_modules/evennia.html @@ -128,6 +128,7 @@ # Properties AttributeProperty = None TagProperty = None +TagCategoryProperty = None # commands Command = None @@ -234,7 +235,7 @@ global GLOBAL_SCRIPTS, OPTION_CLASSES global EvMenu, EvTable, EvForm, EvMore, EvEditor global ANSIString - global AttributeProperty, TagProperty + global AttributeProperty, TagProperty, TagCategoryProperty # Parent typeclasses # utilities @@ -249,12 +250,7 @@ from .comms.models import ChannelDB, Msg from .locks import lockfuncs from .objects.models import ObjectDB - from .objects.objects import ( - DefaultCharacter, - DefaultExit, - DefaultObject, - DefaultRoom, - ) + from .objects.objects import DefaultCharacter, DefaultExit, DefaultObject, DefaultRoom from .prototypes.spawner import spawn from .scripts.models import ScriptDB from .scripts.monitorhandler import MONITOR_HANDLER @@ -263,7 +259,7 @@ from .scripts.tickerhandler import TICKER_HANDLER from .server import signals from .typeclasses.attributes import AttributeProperty - from .typeclasses.tags import TagProperty + from .typeclasses.tags import TagCategoryProperty, TagProperty from .utils import ansi, gametime, logger from .utils.ansi import ANSIString @@ -295,22 +291,23 @@ search_script, search_tag, ) - from .utils.utils import class_from_module + if portal_mode: # Set up the PortalSessionHandler from evennia.server.portal import portalsessionhandler + portal_sess_handler_class = class_from_module(settings.PORTAL_SESSION_HANDLER_CLASS) portalsessionhandler.PORTAL_SESSIONS = portal_sess_handler_class() else: # Create the ServerSesssionHandler from evennia.server import sessionhandler + sess_handler_class = class_from_module(settings.SERVER_SESSION_HANDLER_CLASS) sessionhandler.SESSIONS = sess_handler_class() sessionhandler.SESSION_HANDLER = sessionhandler.SESSIONS SESSION_HANDLER = sessionhandler.SESSIONS - # API containers class _EvContainer(object): diff --git a/docs/1.0/_modules/evennia/commands/default/system.html b/docs/1.0/_modules/evennia/commands/default/system.html index b0db485b83..922c704410 100644 --- a/docs/1.0/_modules/evennia/commands/default/system.html +++ b/docs/1.0/_modules/evennia/commands/default/system.html @@ -91,10 +91,9 @@ import traceback import django +import evennia import twisted from django.conf import settings - -import evennia from evennia.accounts.models import AccountDB from evennia.scripts.taskhandler import TaskHandlerTask from evennia.utils import gametime, logger, search, utils @@ -264,7 +263,11 @@ if show_input: for session in sessions: - data = {"text": (f">>> {pycode}", {"type": "py_input"}), "options": {"raw": True, "highlight": True}} + data = { + # TODO: 'highlight' is not used yet + "text": (f">>> {pycode}", {"type": "py_input"}), + "options": {"raw": True, "highlight": True}, + } try: caller.msg(session=session, **data) except TypeError: @@ -321,10 +324,16 @@ for session in sessions: try: - caller.msg((ret, {"type": "py_output"}), session=session, options={"raw": True, "client_raw": client_raw, - "highlight": True}) + caller.msg( + (ret, {"type": "py_output"}), + session=session, + options={"raw": True, "client_raw": client_raw, "highlight": True}, + ) except TypeError: - caller.msg((ret, {"type": "py_output"}), options={"raw": True, "client_raw": client_raw, "highlight": True}) + caller.msg( + (ret, {"type": "py_output"}), + options={"raw": True, "client_raw": client_raw, "highlight": True}, + ) def evennia_local_vars(caller): @@ -1108,7 +1117,6 @@ # handle caller's request to manipulate a task(s) if self.switches and self.lhs: - # find if the argument is a task id or function name action_request = self.switches[0] try: @@ -1118,7 +1126,6 @@ # if the argument is a task id, proccess the action on a single task if arg_is_id: - err_arg_msg = "Switch and task ID are required when manipulating a task." task_comp_msg = "Task completed while processing request." @@ -1183,7 +1190,6 @@ # the argument is not a task id, process the action on all task deferring the function # specified as an argument else: - name_match_found = False arg_func_name = self.lhslist[0].lower() diff --git a/docs/1.0/_modules/evennia/typeclasses/models.html b/docs/1.0/_modules/evennia/typeclasses/models.html index 23439211ed..bfc03f018a 100644 --- a/docs/1.0/_modules/evennia/typeclasses/models.html +++ b/docs/1.0/_modules/evennia/typeclasses/models.html @@ -112,7 +112,6 @@ from django.urls import reverse from django.utils.encoding import smart_str from django.utils.text import slugify - from evennia.locks.lockhandler import LockHandler from evennia.server.signals import SIGNAL_TYPED_OBJECT_POST_RENAME from evennia.typeclasses import managers @@ -128,6 +127,7 @@ AliasHandler, PermissionHandler, Tag, + TagCategoryProperty, TagHandler, TagProperty, ) @@ -421,7 +421,7 @@ by fetching them once. """ for propkey, prop in self.__class__.__dict__.items(): - if isinstance(prop, (AttributeProperty, TagProperty)): + if isinstance(prop, (AttributeProperty, TagProperty, TagCategoryProperty)): try: getattr(self, propkey) except Exception: @@ -704,7 +704,8 @@ raise RuntimeError( "Cannot use swap_typeclass on time-dependent " "Script '%s'.\nStop and start a new Script of the " - "right type instead." % self.key + "right type instead." + % self.key ) self.typeclass_path = new_typeclass.path diff --git a/docs/1.0/_modules/evennia/typeclasses/tags.html b/docs/1.0/_modules/evennia/typeclasses/tags.html index 084d877ab0..62d020d187 100644 --- a/docs/1.0/_modules/evennia/typeclasses/tags.html +++ b/docs/1.0/_modules/evennia/typeclasses/tags.html @@ -91,7 +91,6 @@ from django.conf import settings from django.db import models - from evennia.locks.lockfuncs import perm as perm_lockfunc from evennia.utils.utils import make_iter, to_str @@ -177,28 +176,31 @@
[docs]class TagProperty: """ - Tag property descriptor. Allows for setting tags on an object as Django-like 'fields' - on the class level. Since Tags are almost always used for querying, Tags are always - created/assigned along with the object. Make sure the property/tagname does not collide - with an existing method/property on the class. If it does, you must use tags.add() - instead. - - Note that while you _can_ check e.g. `obj.tagname,this will give an AttributeError - if the Tag is not set. Most often you want to use `obj.tags.get("tagname")` to check - if a tag is set on an object. - - Example: - :: - - class Character(DefaultCharacter): - mytag = TagProperty() # category=None - mytag2 = TagProperty(category="tagcategory") - + Tag Property. """ taghandler_name = "tags"
[docs] def __init__(self, category=None, data=None): + """ + Tag property descriptor. Allows for setting tags on an object as Django-like 'fields' + on the class level. Since Tags are almost always used for querying, Tags are always + created/assigned along with the object. Make sure the property/tagname does not collide + with an existing method/property on the class. If it does, you must use tags.add() + instead. + + Note that while you _can_ check e.g. `obj.tagname,this will give an AttributeError + if the Tag is not set. Most often you want to use `obj.tags.get("tagname")` to check + if a tag is set on an object. + + Example: + :: + + class Character(DefaultCharacter): + mytag = TagProperty() # category=None + mytag2 = TagProperty(category="tagcategory") + """ + self._category = category self._data = data self._key = ""
@@ -245,6 +247,129 @@ getattr(instance, self.taghandler_name).remove(key=self._key, category=self._category)
+
[docs]class TagCategoryProperty: + """ + Tag Category Property. + + """ + + taghandler_name = "tags" + +
[docs] def __init__(self, *args): + """ + Assign a property for a Tag Category, with any number of Tag keys. + This is often more useful than the `TagProperty` since it's common to want to check which + tags of a particular category the object is a member of. + + Args: + *args (str or callable): Tag keys to assign to this property, using the category given + by the name of the property. If a callable, it will be called without arguments + to return the tag key. It is not possible to set tag `data` this way (use the + Taghandler directly for that). Tag keys are not case sensitive. + + Raises: + ValueError: If the input is not a valid tag key or tuple. + + Notes: + It is not possible to set Tags with a `None` category using a `TagCategoryProperty` - + use `obj.tags.add()` instead. + + Example: + :: + + class RogueCharacter(DefaultCharacter): + guild = TagProperty("thieves_guild", "merchant_guild") + + """ + self._category = "" + self._tags = self._parse_tag_input(*args)
+ + def _parse_tag_input(self, *args): + """ + Parse input to the property. + + Args: + *args (str or callable): Tags, either as strings or `callable`, which should return + the tag key when called without arguments. Keys are not case sensitive. + + Returns: + list: A list of tag keys. + + """ + tags = [] + for tagkey in args: + if callable(tagkey): + tagkey = tagkey() + tags.append((str(tagkey).lower())) + return tags + + def __set_name__(self, cls, name): + """ + Called when descriptor is first assigned to the class (not the instance!). + It is called with the name of the field. + + """ + self._category = name + + def __get__(self, instance, owner): + """ + Called when accessing the tag as a property on the instance. Returns a list + of tags under the given category. + """ + taghandler = getattr(instance, self.taghandler_name) + + tags = [] + add_new = [] + for tagkey in self._tags: + try: + tag = taghandler.get( + key=tagkey, category=self._category, return_list=False, raise_exception=True + ) + except AttributeError: + add_new.append(tagkey) + else: + tags.append(tag) + if add_new: + for new_tag in add_new: + # we must remove this from the internal store or system will think it already + # existed when determining the sets in __set__ + self._tags.remove(new_tag) + self.__set__(instance, *add_new) + + return tags + + def __set__(self, instance, *args): + """ + Assign a new set of tags to the category. This replaces the previous set of tags. + + """ + taghandler = getattr(instance, self.taghandler_name) + + old_tags = set(self._tags) + new_tags = set(self._parse_tag_input(*args)) + + # new_tags could be a sub/superset of old tags + removed_tags = old_tags - new_tags + added_tags = new_tags - old_tags + + # remove tags + for tag in removed_tags: + taghandler.remove(key=tag, category=self._category) + + # add new tags (won't re-add if obj already had it) + taghandler.batch_add(*[(tag, self._category) for tag in added_tags]) + + def __delete__(self, instance): + """ + Called when running `del` on the property. Will remove all tags of this + category from the object. Note that the tags will be readded on next fetch + unless the TagCategoryProperty is also removed in code! + + """ + for tagkey in self.tags: + getattr(instance, self.taghandler_name).remove(key=self.tagkey, category=self._category)
+ +
[docs]class TagHandler(object): """ Generic tag-handler. Accessed via TypedObject.tags. diff --git a/docs/1.0/_sources/Coding/Changelog.md.txt b/docs/1.0/_sources/Coding/Changelog.md.txt index 962c25b7f8..3ba3f4a613 100644 --- a/docs/1.0/_sources/Coding/Changelog.md.txt +++ b/docs/1.0/_sources/Coding/Changelog.md.txt @@ -2,11 +2,19 @@ ## Main branch -- Feature: Attribute-support for saving/loading `deques` with `maxlen=` set. -- Contrib: Container typeclass with new commands for storing and retrieving +- New Contrib: `Container` typeclass with new commands for storing and retrieving things inside them (InspectorCaracal) +- Feature: Add `TagCategoryProperty` for setting categories with multiple tags + as properties directly on objects. Complements `TagProperty`. +- Feature: Attribute-support for saving/loading `deques` with `maxlen=` set. +- Feature: Refactor to provide `evennia.SESSION_HANDLER` for easier overloading + and less risks of circular import problems (Volund) +- Fix: Allow webclient's goldenlayout UI (default) to understand `msg` + `cls` kwarg for customizing the CSS class for every resulting `div` (friarzen) - Fix: The `AttributeHandler.all()` now actually accepts `category=` as keyword arg, like our docs already claimed it should (Volund) +- Fix: `TickerHandler` store key updating was refactored, fixing an issue with + updating intervals (InspectorCaracal) - Docs: New Beginner-Tutorial lessons for NPCs, Base-Combat Twitch-Combat and Turnbased-combat (note that the Beginner tutorial is still WIP). diff --git a/docs/1.0/_sources/Components/Tags.md.txt b/docs/1.0/_sources/Components/Tags.md.txt index f11e9d44b2..9aeecee161 100644 --- a/docs/1.0/_sources/Components/Tags.md.txt +++ b/docs/1.0/_sources/Components/Tags.md.txt @@ -12,18 +12,26 @@ obj.tags.get("mytag", category="foo") ``` ```{code-block} python -:caption: In code, using TagProperty (auto-assign tag to all instances of the class) +:caption: In code, using TagProperty or TagCategoryProperty from evennia import DefaultObject -from evennia import TagProperty +from evennia import TagProperty, TagCategoryProperty + class Sword(DefaultObject): + # name of property is the tagkey, category as argument can_be_wielded = TagProperty(category='combat') has_sharp_edge = TagProperty(category='combat') + # name of property is the category, tag-keys are arguments + damage_type = TagCategoryProperty("piercing", "slashing") + crafting_element = TagCategory("blade", "hilt", "pommel") + ``` _Tags_ are short text lables one can 'hang' on objects in order to organize, group and quickly find out their properties. An Evennia entity can be tagged by any number of tags. They are more efficient than [Attributes](./Attributes.md) since on the database-side, Tags are _shared_ between all objects with that particular tag. A tag does not carry a value in itself; it either sits on the entity +You manage Tags using the `TagHandler` (`.tags`) on typeclassed entities. You can also assign Tags on the class level through the `TagProperty` (one tag, one category per line) or the `TagCategoryProperty` (one category, multiple tags per line). Both of these use the `TagHandler` under the hood, they are just convenient ways to add tags already when you define your class. + Above, the tags inform us that the `Sword` is both sharp and can be wielded. If that's all they do, they could just be a normal Python flag. When tags become important is if there are a lot of objects with different combinations of tags. Maybe you have a magical spell that dulls _all_ sharp-edged objects in the castle - whether sword, dagger, spear or kitchen knife! You can then just grab all objects with the `has_sharp_edge` tag. Another example would be a weather script affecting all rooms tagged as `outdoors` or finding all characters tagged with `belongs_to_fighter_guild`. @@ -35,34 +43,24 @@ In Evennia, Tags are technically also used to implement `Aliases` (alternative n Tags are *unique*. This means that there is only ever one Tag object with a given key and category. -> Not specifying a category (default) gives the tag a category of `None`, which is also considered a -unique key + category combination. +```{important} +Not specifying a category (default) gives the tag a category of `None`, which is also considered a unique key + category combination. You cannot use `TagCategoryProperty` to set Tags with `None` categories, since the property name may not be `None`. Use the `TagHandler` (or `TagProperty`) for this. -When Tags are assigned to game entities, these entities are actually sharing the same Tag. This -means that Tags are not suitable for storing information about a single object - use an +``` +When Tags are assigned to game entities, these entities are actually sharing the same Tag. This means that Tags are not suitable for storing information about a single object - use an [Attribute](./Attributes.md) for this instead. Tags are a lot more limited than Attributes but this also makes them very quick to lookup in the database - this is the whole point. Tags have the following properties, stored in the database: - **key** - the name of the Tag. This is the main property to search for when looking up a Tag. -- **category** - this category allows for retrieving only specific subsets of tags used for -different purposes. You could have one category of tags for "zones", another for "outdoor -locations", for example. If not given, the category will be `None`, which is also considered a -separate, default, category. -- **data** - this is an optional text field with information about the tag. Remember that Tags are -shared between entities, so this field cannot hold any object-specific information. Usually it would -be used to hold info about the group of entities the Tag is tagging - possibly used for contextual -help like a tool tip. It is not used by default. +- **category** - this category allows for retrieving only specific subsets of tags used for different purposes. You could have one category of tags for "zones", another for "outdoor locations", for example. If not given, the category will be `None`, which is also considered a separate, default, category. +- **data** - this is an optional text field with information about the tag. Remember that Tags are shared between entities, so this field cannot hold any object-specific information. Usually it would be used to hold info about the group of entities the Tag is tagging - possibly used for contextual help like a tool tip. It is not used by default. -There are also two special properties. These should usually not need to be changed or set, it is -used internally by Evennia to implement various other uses it makes of the `Tag` object: -- **model** - this holds a *natural-key* description of the model object that this tag deals with, -on the form *application.modelclass*, for example `objects.objectdb`. It used by the TagHandler of -each entity type for correctly storing the data behind the scenes. -- **tagtype** - this is a "top-level category" of sorts for the inbuilt children of Tags, namely -*Aliases* and *Permissions*. The Taghandlers using this special field are especially intended to -free up the *category* property for any use you desire. +There are also two special properties. These should usually not need to be changed or set, it is used internally by Evennia to implement various other uses it makes of the `Tag` object: + +- **model** - this holds a *natural-key* description of the model object that this tag deals with, on the form *application.modelclass*, for example `objects.objectdb`. It used by the TagHandler of each entity type for correctly storing the data behind the scenes. +- **tagtype** - this is a "top-level category" of sorts for the inbuilt children of Tags, namely *Aliases* and *Permissions*. The Taghandlers using this special field are especially intended to free up the *category* property for any use you desire. ### Adding/Removing Tags @@ -157,6 +155,5 @@ used in the same way as Tags above: all_aliases = boy.aliases.all() ``` -and so on. Similarly to how `@tag` works in-game, there is also the `@perm` command for assigning -permissions and `@alias` command for aliases. +and so on. Similarly to how `tag` works in-game, there is also the `perm` command for assigning permissions and `@alias` command for aliases. diff --git a/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.containers.md.txt b/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.containers.md.txt new file mode 100644 index 0000000000..b4cdcfd0a2 --- /dev/null +++ b/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.containers.md.txt @@ -0,0 +1,10 @@ +```{eval-rst} +evennia.contrib.game\_systems.containers.containers +========================================================== + +.. automodule:: evennia.contrib.game_systems.containers.containers + :members: + :undoc-members: + :show-inheritance: + +``` \ No newline at end of file diff --git a/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.md.txt b/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.md.txt new file mode 100644 index 0000000000..69d3c7a5c5 --- /dev/null +++ b/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.md.txt @@ -0,0 +1,18 @@ +```{eval-rst} +evennia.contrib.game\_systems.containers +================================================ + +.. automodule:: evennia.contrib.game_systems.containers + :members: + :undoc-members: + :show-inheritance: + + + +.. toctree:: + :maxdepth: 6 + + evennia.contrib.game_systems.containers.containers + evennia.contrib.game_systems.containers.tests + +``` \ No newline at end of file diff --git a/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.tests.md.txt b/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.tests.md.txt new file mode 100644 index 0000000000..318a3d9669 --- /dev/null +++ b/docs/1.0/_sources/api/evennia.contrib.game_systems.containers.tests.md.txt @@ -0,0 +1,10 @@ +```{eval-rst} +evennia.contrib.game\_systems.containers.tests +===================================================== + +.. automodule:: evennia.contrib.game_systems.containers.tests + :members: + :undoc-members: + :show-inheritance: + +``` \ No newline at end of file diff --git a/docs/1.0/_sources/api/evennia.contrib.game_systems.md.txt b/docs/1.0/_sources/api/evennia.contrib.game_systems.md.txt index b321dd8abc..72bbb06be7 100644 --- a/docs/1.0/_sources/api/evennia.contrib.game_systems.md.txt +++ b/docs/1.0/_sources/api/evennia.contrib.game_systems.md.txt @@ -13,6 +13,7 @@ evennia.contrib.game\_systems evennia.contrib.game_systems.barter evennia.contrib.game_systems.clothing + evennia.contrib.game_systems.containers evennia.contrib.game_systems.cooldowns evennia.contrib.game_systems.crafting evennia.contrib.game_systems.gendersub diff --git a/docs/1.0/api/evennia-api.html b/docs/1.0/api/evennia-api.html index 45184d719d..9484696fbe 100644 --- a/docs/1.0/api/evennia-api.html +++ b/docs/1.0/api/evennia-api.html @@ -237,6 +237,11 @@
  • evennia.contrib.game_systems.clothing.tests
  • +
  • evennia.contrib.game_systems.containers +
  • evennia.contrib.game_systems.cooldowns
    • evennia.contrib.game_systems.cooldowns.cooldowns
    • evennia.contrib.game_systems.cooldowns.tests
    • diff --git a/docs/1.0/api/evennia.commands.default.batchprocess.html b/docs/1.0/api/evennia.commands.default.batchprocess.html index a6a85545d6..03c4dcdd9c 100644 --- a/docs/1.0/api/evennia.commands.default.batchprocess.html +++ b/docs/1.0/api/evennia.commands.default.batchprocess.html @@ -138,7 +138,7 @@ skipping, reloading etc.

      -aliases = ['batchcmd', 'batchcommand']
      +aliases = ['batchcommand', 'batchcmd']
      @@ -169,7 +169,7 @@ skipping, reloading etc.

      -search_index_entry = {'aliases': 'batchcmd batchcommand', 'category': 'building', 'key': 'batchcommands', 'no_prefix': ' batchcmd batchcommand', 'tags': '', 'text': '\n build from batch-command file\n\n Usage:\n batchcommands[/interactive] <python.path.to.file>\n\n Switch:\n interactive - this mode will offer more control when\n executing the batch file, like stepping,\n skipping, reloading etc.\n\n Runs batches of commands from a batch-cmd text file (*.ev).\n\n '}
      +search_index_entry = {'aliases': 'batchcommand batchcmd', 'category': 'building', 'key': 'batchcommands', 'no_prefix': ' batchcommand batchcmd', 'tags': '', 'text': '\n build from batch-command file\n\n Usage:\n batchcommands[/interactive] <python.path.to.file>\n\n Switch:\n interactive - this mode will offer more control when\n executing the batch file, like stepping,\n skipping, reloading etc.\n\n Runs batches of commands from a batch-cmd text file (*.ev).\n\n '}
      diff --git a/docs/1.0/api/evennia.commands.default.building.html b/docs/1.0/api/evennia.commands.default.building.html index 546d48018b..92629c06c1 100644 --- a/docs/1.0/api/evennia.commands.default.building.html +++ b/docs/1.0/api/evennia.commands.default.building.html @@ -1345,7 +1345,7 @@ server settings.

      -aliases = ['@update', '@swap', '@type', '@parent', '@typeclasses']
      +aliases = ['@typeclasses', '@swap', '@update', '@type', '@parent']
      @@ -1376,7 +1376,7 @@ server settings.

      -search_index_entry = {'aliases': '@update @swap @type @parent @typeclasses', 'category': 'building', 'key': '@typeclass', 'no_prefix': 'typeclass update swap type parent typeclasses', '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. This will also\n reset cmdsets!\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 "}
      +search_index_entry = {'aliases': '@typeclasses @swap @update @type @parent', 'category': 'building', 'key': '@typeclass', 'no_prefix': 'typeclass typeclasses swap update type parent', '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. This will also\n reset cmdsets!\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 "}
      @@ -1531,7 +1531,7 @@ If object is not specified, the current location is examined.

      -aliases = ['@exam', '@ex']
      +aliases = ['@ex', '@exam']
      @@ -1799,7 +1799,7 @@ the cases, see the module doc.

      -search_index_entry = {'aliases': '@exam @ex', 'category': 'building', 'key': '@examine', 'no_prefix': 'examine exam ex', '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 script - examine a Script\n channel - examine a Channel\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 '}
      +search_index_entry = {'aliases': '@ex @exam', 'category': 'building', 'key': '@examine', 'no_prefix': 'examine ex exam', '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 script - examine a Script\n channel - examine a Channel\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 '}
      @@ -1833,7 +1833,7 @@ one is given.

      -aliases = ['@locate', '@search']
      +aliases = ['@search', '@locate']
      @@ -1864,7 +1864,7 @@ one is given.

      -search_index_entry = {'aliases': '@locate @search', 'category': 'building', 'key': '@find', 'no_prefix': 'find locate search', 'tags': '', 'text': '\n search the database for objects\n\n Usage:\n find[/switches] <name or dbref or *account> [= dbrefmin[-dbrefmax]]\n locate - this is a shorthand for using the /loc switch.\n\n Switches:\n room - only look for rooms (location=None)\n exit - only look for exits (destination!=None)\n char - only look for characters (BASE_CHARACTER_TYPECLASS)\n exact - only exact matches are returned.\n loc - display object location if exists and match has one result\n startswith - search for names starting with the string, rather than containing\n\n Searches the database for an object of a particular name or exact #dbref.\n Use *accountname to search for an account. The switches allows for\n limiting object matches to certain game entities. Dbrefmin and dbrefmax\n limits matches to within the given dbrefs range, or above/below if only\n one is given.\n '}
      +search_index_entry = {'aliases': '@search @locate', 'category': 'building', 'key': '@find', 'no_prefix': 'find search locate', 'tags': '', 'text': '\n search the database for objects\n\n Usage:\n find[/switches] <name or dbref or *account> [= dbrefmin[-dbrefmax]]\n locate - this is a shorthand for using the /loc switch.\n\n Switches:\n room - only look for rooms (location=None)\n exit - only look for exits (destination!=None)\n char - only look for characters (BASE_CHARACTER_TYPECLASS)\n exact - only exact matches are returned.\n loc - display object location if exists and match has one result\n startswith - search for names starting with the string, rather than containing\n\n Searches the database for an object of a particular name or exact #dbref.\n Use *accountname to search for an account. The switches allows for\n limiting object matches to certain game entities. Dbrefmin and dbrefmax\n limits matches to within the given dbrefs range, or above/below if only\n one is given.\n '}
      diff --git a/docs/1.0/api/evennia.commands.default.general.html b/docs/1.0/api/evennia.commands.default.general.html index 686ef5e54f..07b70e52cf 100644 --- a/docs/1.0/api/evennia.commands.default.general.html +++ b/docs/1.0/api/evennia.commands.default.general.html @@ -598,7 +598,7 @@ placing it in their inventory.

      -aliases = ['"', "'"]
      +aliases = ["'", '"']
      @@ -629,7 +629,7 @@ placing it in their inventory.

      -search_index_entry = {'aliases': '" \'', 'category': 'general', 'key': 'say', 'no_prefix': ' " \'', 'tags': '', 'text': '\n speak as your character\n\n Usage:\n say <message>\n\n Talk to those in your current location.\n '}
      +search_index_entry = {'aliases': '\' "', 'category': 'general', 'key': 'say', 'no_prefix': ' \' "', 'tags': '', 'text': '\n speak as your character\n\n Usage:\n say <message>\n\n Talk to those in your current location.\n '}
      @@ -709,7 +709,7 @@ automatically begin with your name.

      -aliases = [':', 'emote']
      +aliases = ['emote', ':']
      @@ -750,7 +750,7 @@ space.

      -search_index_entry = {'aliases': ': emote', 'category': 'general', 'key': 'pose', 'no_prefix': ' : emote', 'tags': '', 'text': "\n strike a pose\n\n Usage:\n pose <pose text>\n pose's <pose text>\n\n Example:\n pose is standing by the wall, smiling.\n -> others will see:\n Tom is standing by the wall, smiling.\n\n Describe an action being taken. The pose text will\n automatically begin with your name.\n "}
      +search_index_entry = {'aliases': 'emote :', 'category': 'general', 'key': 'pose', 'no_prefix': ' emote :', 'tags': '', 'text': "\n strike a pose\n\n Usage:\n pose <pose text>\n pose's <pose text>\n\n Example:\n pose is standing by the wall, smiling.\n -> others will see:\n Tom is standing by the wall, smiling.\n\n Describe an action being taken. The pose text will\n automatically begin with your name.\n "}
      diff --git a/docs/1.0/api/evennia.commands.default.system.html b/docs/1.0/api/evennia.commands.default.system.html index 8395562b27..715c2834fd 100644 --- a/docs/1.0/api/evennia.commands.default.system.html +++ b/docs/1.0/api/evennia.commands.default.system.html @@ -683,7 +683,7 @@ See |luhttps://ww
      -aliases = ['@delays', '@task']
      +aliases = ['@task', '@delays']
      @@ -729,7 +729,7 @@ to all the variables defined therein.

      -search_index_entry = {'aliases': '@delays @task', 'category': 'system', 'key': '@tasks', 'no_prefix': 'tasks delays task', '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 "}
      +search_index_entry = {'aliases': '@task @delays', 'category': 'system', 'key': '@tasks', 'no_prefix': 'tasks task delays', '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 "}
      diff --git a/docs/1.0/api/evennia.commands.default.tests.html b/docs/1.0/api/evennia.commands.default.tests.html index 41b906be3c..e681090a75 100644 --- a/docs/1.0/api/evennia.commands.default.tests.html +++ b/docs/1.0/api/evennia.commands.default.tests.html @@ -955,7 +955,7 @@ main test suite started with

      Test the batch processor.

      -red_button = <module 'evennia.contrib.tutorials.red_button.red_button' from '/tmp/tmp5fz2dpk5/97a87ed416c72ad8cd92f5ad9ccac087dae0275b/evennia/contrib/tutorials/red_button/red_button.py'>
      +red_button = <module 'evennia.contrib.tutorials.red_button.red_button' from '/tmp/tmpqtscfy9l/fb4751f3b82e79fbb4e5b7b6718f910759fa8d02/evennia/contrib/tutorials/red_button/red_button.py'>
      diff --git a/docs/1.0/api/evennia.commands.default.unloggedin.html b/docs/1.0/api/evennia.commands.default.unloggedin.html index 7320c59eb4..ab84e122a3 100644 --- a/docs/1.0/api/evennia.commands.default.unloggedin.html +++ b/docs/1.0/api/evennia.commands.default.unloggedin.html @@ -122,7 +122,7 @@ connect “account name” “pass word”

      -aliases = ['conn', 'co', 'con']
      +aliases = ['co', 'conn', 'con']
      @@ -157,7 +157,7 @@ there is no object yet before the account has logged in)

      -search_index_entry = {'aliases': 'conn co con', 'category': 'general', 'key': 'connect', 'no_prefix': ' conn co con', 'tags': '', 'text': '\n connect to the game\n\n Usage (at login screen):\n connect accountname password\n connect "account name" "pass word"\n\n Use the create command to first create an account before logging in.\n\n If you have spaces in your name, enclose it in double quotes.\n '}
      +search_index_entry = {'aliases': 'co conn con', 'category': 'general', 'key': 'connect', 'no_prefix': ' co conn con', 'tags': '', 'text': '\n connect to the game\n\n Usage (at login screen):\n connect accountname password\n connect "account name" "pass word"\n\n Use the create command to first create an account before logging in.\n\n If you have spaces in your name, enclose it in double quotes.\n '}
      @@ -242,7 +242,7 @@ version is a bit more complicated.

      -aliases = ['q', 'qu']
      +aliases = ['qu', 'q']
      @@ -268,7 +268,7 @@ version is a bit more complicated.

      -search_index_entry = {'aliases': 'q qu', 'category': 'general', 'key': 'quit', 'no_prefix': ' q qu', 'tags': '', 'text': '\n quit when in unlogged-in state\n\n Usage:\n quit\n\n We maintain a different version of the quit command\n here for unconnected accounts for the sake of simplicity. The logged in\n version is a bit more complicated.\n '}
      +search_index_entry = {'aliases': 'qu q', 'category': 'general', 'key': 'quit', 'no_prefix': ' qu q', 'tags': '', 'text': '\n quit when in unlogged-in state\n\n Usage:\n quit\n\n We maintain a different version of the quit command\n here for unconnected accounts for the sake of simplicity. The logged in\n version is a bit more complicated.\n '}
      @@ -292,7 +292,7 @@ All it does is display the connect screen.

      -aliases = ['l', 'look']
      +aliases = ['look', 'l']
      @@ -318,7 +318,7 @@ All it does is display the connect screen.

      -search_index_entry = {'aliases': 'l look', 'category': 'general', 'key': '__unloggedin_look_command', 'no_prefix': ' l look', '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 '}
      +search_index_entry = {'aliases': 'look l', 'category': 'general', 'key': '__unloggedin_look_command', 'no_prefix': ' look l', '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 '}
      diff --git a/docs/1.0/api/evennia.contrib.base_systems.email_login.email_login.html b/docs/1.0/api/evennia.contrib.base_systems.email_login.email_login.html index 3879bd27ab..6e0146fb8b 100644 --- a/docs/1.0/api/evennia.contrib.base_systems.email_login.email_login.html +++ b/docs/1.0/api/evennia.contrib.base_systems.email_login.email_login.html @@ -139,7 +139,7 @@ the module given by settings.CONNECTION_SCREEN_MODULE.

      -aliases = ['conn', 'co', 'con']
      +aliases = ['co', 'conn', 'con']
      @@ -169,7 +169,7 @@ there is no object yet before the account has logged in)

      -search_index_entry = {'aliases': 'conn co con', 'category': 'general', 'key': 'connect', 'no_prefix': ' conn co con', 'tags': '', 'text': '\n Connect to the game.\n\n Usage (at login screen):\n connect <email> <password>\n\n Use the create command to first create an account before logging in.\n '}
      +search_index_entry = {'aliases': 'co conn con', 'category': 'general', 'key': 'connect', 'no_prefix': ' co conn con', 'tags': '', 'text': '\n Connect to the game.\n\n Usage (at login screen):\n connect <email> <password>\n\n Use the create command to first create an account before logging in.\n '}
      @@ -246,7 +246,7 @@ version is a bit more complicated.

      -aliases = ['q', 'qu']
      +aliases = ['qu', 'q']
      @@ -272,7 +272,7 @@ version is a bit more complicated.

      -search_index_entry = {'aliases': 'q qu', 'category': 'general', 'key': 'quit', 'no_prefix': ' q qu', 'tags': '', 'text': '\n We maintain a different version of the `quit` command\n here for unconnected accounts for the sake of simplicity. The logged in\n version is a bit more complicated.\n '}
      +search_index_entry = {'aliases': 'qu q', 'category': 'general', 'key': 'quit', 'no_prefix': ' qu q', 'tags': '', 'text': '\n We maintain a different version of the `quit` command\n here for unconnected accounts for the sake of simplicity. The logged in\n version is a bit more complicated.\n '}
      @@ -291,7 +291,7 @@ All it does is display the connect screen.

      -aliases = ['l', 'look']
      +aliases = ['look', 'l']
      @@ -317,7 +317,7 @@ All it does is display the connect screen.

      -search_index_entry = {'aliases': 'l look', 'category': 'general', 'key': '__unloggedin_look_command', 'no_prefix': ' l look', '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 '}
      +search_index_entry = {'aliases': 'look l', 'category': 'general', 'key': '__unloggedin_look_command', 'no_prefix': ' look l', '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 '}
      diff --git a/docs/1.0/api/evennia.contrib.base_systems.ingame_python.commands.html b/docs/1.0/api/evennia.contrib.base_systems.ingame_python.commands.html index efe4445016..a7fdab240e 100644 --- a/docs/1.0/api/evennia.contrib.base_systems.ingame_python.commands.html +++ b/docs/1.0/api/evennia.contrib.base_systems.ingame_python.commands.html @@ -116,7 +116,7 @@
      -aliases = ['@calls', '@callback', '@callbacks']
      +aliases = ['@callback', '@callbacks', '@calls']
      @@ -197,7 +197,7 @@ on user permission.

      -search_index_entry = {'aliases': '@calls @callback @callbacks', 'category': 'building', 'key': '@call', 'no_prefix': 'call calls callback callbacks', 'tags': '', 'text': '\n Command to edit callbacks.\n '}
      +search_index_entry = {'aliases': '@callback @callbacks @calls', 'category': 'building', 'key': '@call', 'no_prefix': 'call callback callbacks calls', 'tags': '', 'text': '\n Command to edit callbacks.\n '}
      diff --git a/docs/1.0/api/evennia.contrib.base_systems.mux_comms_cmds.mux_comms_cmds.html b/docs/1.0/api/evennia.contrib.base_systems.mux_comms_cmds.mux_comms_cmds.html index a368dfc800..dedf398f8e 100644 --- a/docs/1.0/api/evennia.contrib.base_systems.mux_comms_cmds.mux_comms_cmds.html +++ b/docs/1.0/api/evennia.contrib.base_systems.mux_comms_cmds.mux_comms_cmds.html @@ -160,7 +160,7 @@ aliases to an already joined channel.

      -aliases = ['chanalias', 'aliaschan']
      +aliases = ['aliaschan', 'chanalias']
      @@ -191,7 +191,7 @@ aliases to an already joined channel.

      -search_index_entry = {'aliases': 'chanalias aliaschan', 'category': 'comms', 'key': 'addcom', 'no_prefix': ' chanalias aliaschan', 'tags': '', 'text': '\n Add a channel alias and/or subscribe to a channel\n\n Usage:\n addcom [alias=] <channel>\n\n Joins a given channel. If alias is given, this will allow you to\n refer to the channel by this alias rather than the full channel\n name. Subsequent calls of this command can be used to add multiple\n aliases to an already joined channel.\n '}
      +search_index_entry = {'aliases': 'aliaschan chanalias', 'category': 'comms', 'key': 'addcom', 'no_prefix': ' aliaschan chanalias', 'tags': '', 'text': '\n Add a channel alias and/or subscribe to a channel\n\n Usage:\n addcom [alias=] <channel>\n\n Joins a given channel. If alias is given, this will allow you to\n refer to the channel by this alias rather than the full channel\n name. Subsequent calls of this command can be used to add multiple\n aliases to an already joined channel.\n '}
      @@ -217,7 +217,7 @@ for that channel.

      -aliases = ['delaliaschan', 'delchanalias']
      +aliases = ['delchanalias', 'delaliaschan']
      @@ -248,7 +248,7 @@ for that channel.

      -search_index_entry = {'aliases': 'delaliaschan delchanalias', 'category': 'comms', 'key': 'delcom', 'no_prefix': ' delaliaschan delchanalias', 'tags': '', 'text': "\n remove a channel alias and/or unsubscribe from channel\n\n Usage:\n delcom <alias or channel>\n delcom/all <channel>\n\n If the full channel name is given, unsubscribe from the\n channel. If an alias is given, remove the alias but don't\n unsubscribe. If the 'all' switch is used, remove all aliases\n for that channel.\n "}
      +search_index_entry = {'aliases': 'delchanalias delaliaschan', 'category': 'comms', 'key': 'delcom', 'no_prefix': ' delchanalias delaliaschan', 'tags': '', 'text': "\n remove a channel alias and/or unsubscribe from channel\n\n Usage:\n delcom <alias or channel>\n delcom/all <channel>\n\n If the full channel name is given, unsubscribe from the\n channel. If an alias is given, remove the alias but don't\n unsubscribe. If the 'all' switch is used, remove all aliases\n for that channel.\n "}
      diff --git a/docs/1.0/api/evennia.contrib.full_systems.evscaperoom.commands.html b/docs/1.0/api/evennia.contrib.full_systems.evscaperoom.commands.html index c409458119..9b51697ac6 100644 --- a/docs/1.0/api/evennia.contrib.full_systems.evscaperoom.commands.html +++ b/docs/1.0/api/evennia.contrib.full_systems.evscaperoom.commands.html @@ -211,7 +211,7 @@ the operation will be general or on the room.

      -aliases = ['chicken out', 'q', 'quit', 'abort']
      +aliases = ['chicken out', 'quit', 'abort', 'q']
      @@ -235,7 +235,7 @@ set in self.parse())

      -search_index_entry = {'aliases': 'chicken out q quit abort', 'category': 'evscaperoom', 'key': 'give up', 'no_prefix': ' chicken out q quit abort', '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 '}
      +search_index_entry = {'aliases': 'chicken out quit abort q', 'category': 'evscaperoom', 'key': 'give up', 'no_prefix': ' chicken out quit abort q', '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 '}
      @@ -371,7 +371,7 @@ shout

      -aliases = [';', 'whisper', 'shout']
      +aliases = ['shout', ';', 'whisper']
      @@ -400,7 +400,7 @@ set in self.parse())

      -search_index_entry = {'aliases': '; whisper shout', 'category': 'general', 'key': 'say', 'no_prefix': ' ; whisper shout', 'tags': '', 'text': '\n Perform an communication action.\n\n Usage:\n say <text>\n whisper\n shout\n\n '}
      +search_index_entry = {'aliases': 'shout ; whisper', 'category': 'general', 'key': 'say', 'no_prefix': ' shout ; whisper', 'tags': '', 'text': '\n Perform an communication action.\n\n Usage:\n say <text>\n whisper\n shout\n\n '}
      @@ -428,7 +428,7 @@ emote /me points to /box and /lever.

      -aliases = [':', 'pose']
      +aliases = ['pose', ':']
      @@ -467,7 +467,7 @@ set in self.parse())

      -search_index_entry = {'aliases': ': pose', 'category': 'general', 'key': 'emote', 'no_prefix': ' : pose', 'tags': '', 'text': '\n Perform a free-form emote. Use /me to\n include yourself in the emote and /name\n to include other objects or characters.\n Use "..." to enact speech.\n\n Usage:\n emote <emote>\n :<emote\n\n Example:\n emote /me smiles at /peter\n emote /me points to /box and /lever.\n\n '}
      +search_index_entry = {'aliases': 'pose :', 'category': 'general', 'key': 'emote', 'no_prefix': ' pose :', 'tags': '', 'text': '\n Perform a free-form emote. Use /me to\n include yourself in the emote and /name\n to include other objects or characters.\n Use "..." to enact speech.\n\n Usage:\n emote <emote>\n :<emote\n\n Example:\n emote /me smiles at /peter\n emote /me points to /box and /lever.\n\n '}
      @@ -490,7 +490,7 @@ looks and what actions is available.

      -aliases = ['unfocus', 'examine', 'e', 'ex']
      +aliases = ['examine', 'ex', 'unfocus', 'e']
      @@ -519,7 +519,7 @@ set in self.parse())

      -search_index_entry = {'aliases': 'unfocus examine e ex', 'category': 'evscaperoom', 'key': 'focus', 'no_prefix': ' unfocus examine e ex', '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 '}
      +search_index_entry = {'aliases': 'examine ex unfocus e', 'category': 'evscaperoom', 'key': 'focus', 'no_prefix': ' examine ex unfocus e', '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 '}
      @@ -581,7 +581,7 @@ set in self.parse())

      -aliases = ['give', 'i', 'inventory', 'inv']
      +aliases = ['i', 'give', 'inv', 'inventory']
      @@ -605,7 +605,7 @@ set in self.parse())

      -search_index_entry = {'aliases': 'give i inventory inv', 'category': 'evscaperoom', 'key': 'get', 'no_prefix': ' give i inventory inv', 'tags': '', 'text': '\n Use focus / examine instead.\n\n '}
      +search_index_entry = {'aliases': 'i give inv inventory', 'category': 'evscaperoom', 'key': 'get', 'no_prefix': ' i give inv inventory', 'tags': '', 'text': '\n Use focus / examine instead.\n\n '}
      @@ -626,7 +626,7 @@ set in self.parse())

      -aliases = ['@dig', '@open']
      +aliases = ['@open', '@dig']
      @@ -649,7 +649,7 @@ to all the variables defined therein.

      -search_index_entry = {'aliases': '@dig @open', 'category': 'general', 'key': 'open', 'no_prefix': ' dig open', 'tags': '', 'text': '\n Interact with an object in focus.\n\n Usage:\n <action> [arg]\n\n '}
      +search_index_entry = {'aliases': '@open @dig', 'category': 'general', 'key': 'open', 'no_prefix': ' open dig', 'tags': '', 'text': '\n Interact with an object in focus.\n\n Usage:\n <action> [arg]\n\n '}
      diff --git a/docs/1.0/api/evennia.contrib.game_systems.clothing.tests.html b/docs/1.0/api/evennia.contrib.game_systems.clothing.tests.html index fef062df3d..30d90e150a 100644 --- a/docs/1.0/api/evennia.contrib.game_systems.clothing.tests.html +++ b/docs/1.0/api/evennia.contrib.game_systems.clothing.tests.html @@ -17,7 +17,7 @@ - +
  • +
  • evennia.contrib.game_systems.containers +
  • evennia.contrib.game_systems.cooldowns
    • evennia.contrib.game_systems.cooldowns.cooldowns
    • evennia.contrib.game_systems.cooldowns.tests
    • diff --git a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_basic.html b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_basic.html index adae913770..efca33993e 100644 --- a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_basic.html +++ b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_basic.html @@ -672,7 +672,7 @@ if there are still any actions you can take.

      -aliases = ['hold', 'wait']
      +aliases = ['wait', 'hold']
      @@ -698,7 +698,7 @@ if there are still any actions you can take.

      -search_index_entry = {'aliases': 'hold wait', 'category': 'combat', 'key': 'pass', 'no_prefix': ' hold wait', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      +search_index_entry = {'aliases': 'wait hold', 'category': 'combat', 'key': 'pass', 'no_prefix': ' wait hold', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      diff --git a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_equip.html b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_equip.html index c375bddf93..37ac87b8d3 100644 --- a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_equip.html +++ b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_equip.html @@ -567,7 +567,7 @@ if there are still any actions you can take.

      -aliases = ['hold', 'wait']
      +aliases = ['wait', 'hold']
      @@ -587,7 +587,7 @@ if there are still any actions you can take.

      -search_index_entry = {'aliases': 'hold wait', 'category': 'combat', 'key': 'pass', 'no_prefix': ' hold wait', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      +search_index_entry = {'aliases': 'wait hold', 'category': 'combat', 'key': 'pass', 'no_prefix': ' wait hold', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      diff --git a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_items.html b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_items.html index fd9a60204f..357befc2ef 100644 --- a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_items.html +++ b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_items.html @@ -690,7 +690,7 @@ if there are still any actions you can take.

      -aliases = ['hold', 'wait']
      +aliases = ['wait', 'hold']
      @@ -710,7 +710,7 @@ if there are still any actions you can take.

      -search_index_entry = {'aliases': 'hold wait', 'category': 'combat', 'key': 'pass', 'no_prefix': ' hold wait', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      +search_index_entry = {'aliases': 'wait hold', 'category': 'combat', 'key': 'pass', 'no_prefix': ' wait hold', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      diff --git a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_magic.html b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_magic.html index 55eb38bfae..3a720e7003 100644 --- a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_magic.html +++ b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_magic.html @@ -469,7 +469,7 @@ if there are still any actions you can take.

      -aliases = ['hold', 'wait']
      +aliases = ['wait', 'hold']
      @@ -489,7 +489,7 @@ if there are still any actions you can take.

      -search_index_entry = {'aliases': 'hold wait', 'category': 'combat', 'key': 'pass', 'no_prefix': ' hold wait', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      +search_index_entry = {'aliases': 'wait hold', 'category': 'combat', 'key': 'pass', 'no_prefix': ' wait hold', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      diff --git a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_range.html b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_range.html index cbbf27f645..09197d0a8a 100644 --- a/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_range.html +++ b/docs/1.0/api/evennia.contrib.game_systems.turnbattle.tb_range.html @@ -929,7 +929,7 @@ if there are still any actions you can take.

      -aliases = ['hold', 'wait']
      +aliases = ['wait', 'hold']
      @@ -949,7 +949,7 @@ if there are still any actions you can take.

      -search_index_entry = {'aliases': 'hold wait', 'category': 'combat', 'key': 'pass', 'no_prefix': ' hold wait', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      +search_index_entry = {'aliases': 'wait hold', 'category': 'combat', 'key': 'pass', 'no_prefix': ' wait hold', 'tags': '', 'text': '\n Passes on your turn.\n\n Usage:\n pass\n\n When in a fight, you can use this command to end your turn early, even\n if there are still any actions you can take.\n '}
      diff --git a/docs/1.0/api/evennia.contrib.html b/docs/1.0/api/evennia.contrib.html index dff433ca5f..af29ceff27 100644 --- a/docs/1.0/api/evennia.contrib.html +++ b/docs/1.0/api/evennia.contrib.html @@ -199,6 +199,11 @@ useful but are deemed too game-specific to go into the core library.

    • evennia.contrib.game_systems.clothing.tests
  • +
  • evennia.contrib.game_systems.containers +
  • evennia.contrib.game_systems.cooldowns
    • evennia.contrib.game_systems.cooldowns.cooldowns
    • evennia.contrib.game_systems.cooldowns.tests
    • diff --git a/docs/1.0/api/evennia.contrib.rpg.rpsystem.rpsystem.html b/docs/1.0/api/evennia.contrib.rpg.rpsystem.rpsystem.html index 5cd0974e77..1fc5811ef0 100644 --- a/docs/1.0/api/evennia.contrib.rpg.rpsystem.rpsystem.html +++ b/docs/1.0/api/evennia.contrib.rpg.rpsystem.rpsystem.html @@ -701,7 +701,7 @@ a different language.

      -aliases = ['"', "'"]
      +aliases = ["'", '"']
      @@ -732,7 +732,7 @@ a different language.

      -search_index_entry = {'aliases': '" \'', 'category': 'general', 'key': 'say', 'no_prefix': ' " \'', 'tags': '', 'text': '\n speak as your character\n\n Usage:\n say <message>\n\n Talk to those in your current location.\n '}
      +search_index_entry = {'aliases': '\' "', 'category': 'general', 'key': 'say', 'no_prefix': ' \' "', 'tags': '', 'text': '\n speak as your character\n\n Usage:\n say <message>\n\n Talk to those in your current location.\n '}
      @@ -873,7 +873,7 @@ Using the command without arguments will list all current recogs.

      -aliases = ['forget', 'recognize']
      +aliases = ['recognize', 'forget']
      @@ -900,7 +900,7 @@ Using the command without arguments will list all current recogs.

      -search_index_entry = {'aliases': 'forget recognize', 'category': 'general', 'key': 'recog', 'no_prefix': ' forget recognize', '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 '}
      +search_index_entry = {'aliases': 'recognize forget', 'category': 'general', 'key': 'recog', 'no_prefix': ' recognize forget', '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 '}
      diff --git a/docs/1.0/api/evennia.contrib.tutorials.evadventure.npcs.html b/docs/1.0/api/evennia.contrib.tutorials.evadventure.npcs.html index ffc6c85137..dad78a8bd6 100644 --- a/docs/1.0/api/evennia.contrib.tutorials.evadventure.npcs.html +++ b/docs/1.0/api/evennia.contrib.tutorials.evadventure.npcs.html @@ -184,20 +184,7 @@ non-combat purposes (or for loot to get when killing an enemy).

      group
      -

      Tag property descriptor. Allows for setting tags on an object as Django-like ‘fields’ -on the class level. Since Tags are almost always used for querying, Tags are always -created/assigned along with the object. Make sure the property/tagname does not collide -with an existing method/property on the class. If it does, you must use tags.add() -instead.

      -

      Note that while you _can_ check e.g. obj.tagname,this will give an AttributeError -if the Tag is not set. Most often you want to use **obj.tags.get(“tagname”) to check -if a tag is set on an object.

      -

      Example:

      -
      class Character(DefaultCharacter):
      -    mytag = TagProperty()  # category=None
      -    mytag2 = TagProperty(category="tagcategory")
      -
      -
      +

      Tag Property.

      diff --git a/docs/1.0/api/evennia.contrib.tutorials.red_button.red_button.html b/docs/1.0/api/evennia.contrib.tutorials.red_button.red_button.html index ef9665660b..cea5ceb998 100644 --- a/docs/1.0/api/evennia.contrib.tutorials.red_button.red_button.html +++ b/docs/1.0/api/evennia.contrib.tutorials.red_button.red_button.html @@ -153,7 +153,7 @@ such as when closing the lid and un-blinding a character.

      -aliases = ['push', 'press', 'press button']
      +aliases = ['push', 'press button', 'press']
      @@ -182,7 +182,7 @@ check if the lid is open or closed.

      -search_index_entry = {'aliases': 'push press press button', 'category': 'general', 'key': 'push button', 'no_prefix': ' push press press button', 'tags': '', 'text': '\n Push the red button (lid closed)\n\n Usage:\n push button\n\n '}
      +search_index_entry = {'aliases': 'push press button press', 'category': 'general', 'key': 'push button', 'no_prefix': ' push press button press', 'tags': '', 'text': '\n Push the red button (lid closed)\n\n Usage:\n push button\n\n '}
      @@ -252,7 +252,7 @@ check if the lid is open or closed.

      -aliases = ['break lid', 'smash', 'smash lid']
      +aliases = ['smash lid', 'break lid', 'smash']
      @@ -279,7 +279,7 @@ break.

      -search_index_entry = {'aliases': 'break lid smash smash lid', 'category': 'general', 'key': 'smash glass', 'no_prefix': ' break lid smash smash lid', '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 '}
      +search_index_entry = {'aliases': 'smash lid break lid smash', 'category': 'general', 'key': 'smash glass', 'no_prefix': ' smash lid break lid smash', '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 '}
      @@ -379,7 +379,7 @@ be mutually exclusive.

      -aliases = ['push', 'press', 'press button']
      +aliases = ['push', 'press button', 'press']
      @@ -408,7 +408,7 @@ set in self.parse())

      -search_index_entry = {'aliases': 'push press press button', 'category': 'general', 'key': 'push button', 'no_prefix': ' push press press button', 'tags': '', 'text': '\n Push the red button\n\n Usage:\n push button\n\n '}
      +search_index_entry = {'aliases': 'push press button press', 'category': 'general', 'key': 'push button', 'no_prefix': ' push press button press', 'tags': '', 'text': '\n Push the red button\n\n Usage:\n push button\n\n '}
      @@ -506,7 +506,7 @@ be mutually exclusive.

      -aliases = ['get', 'l', 'ex', 'feel', 'listen', 'examine']
      +aliases = ['listen', 'feel', 'ex', 'examine', 'l', 'get']
      @@ -532,7 +532,7 @@ be mutually exclusive.

      -search_index_entry = {'aliases': 'get l ex feel listen examine', 'category': 'general', 'key': 'look', 'no_prefix': ' get l ex feel listen examine', '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 "}
      +search_index_entry = {'aliases': 'listen feel ex examine l get', 'category': 'general', 'key': 'look', 'no_prefix': ' listen feel ex examine l get', '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 "}
      diff --git a/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.objects.html b/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.objects.html index f499a67aaa..7db1774530 100644 --- a/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.objects.html +++ b/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.objects.html @@ -556,7 +556,7 @@ shift green root up/down

      -aliases = ['push', 'pull', 'shiftroot', 'move']
      +aliases = ['shiftroot', 'push', 'move', 'pull']
      @@ -592,7 +592,7 @@ yellow/green - horizontal roots

      -search_index_entry = {'aliases': 'push pull shiftroot move', 'category': 'tutorialworld', 'key': 'shift', 'no_prefix': ' push pull shiftroot move', '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 '}
      +search_index_entry = {'aliases': 'shiftroot push move pull', 'category': 'tutorialworld', 'key': 'shift', 'no_prefix': ' shiftroot push move pull', '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 '}
      @@ -609,7 +609,7 @@ yellow/green - horizontal roots

      -aliases = ['press button', 'push button', 'button']
      +aliases = ['button', 'press button', 'push button']
      @@ -635,7 +635,7 @@ yellow/green - horizontal roots

      -search_index_entry = {'aliases': 'press button push button button', 'category': 'tutorialworld', 'key': 'press', 'no_prefix': ' press button push button button', 'tags': '', 'text': '\n Presses a button.\n '}
      +search_index_entry = {'aliases': 'button press button push button', 'category': 'tutorialworld', 'key': 'press', 'no_prefix': ' button press button push button', 'tags': '', 'text': '\n Presses a button.\n '}
      @@ -779,7 +779,7 @@ parry - forgoes your attack but will make you harder to hit on next

      -aliases = ['chop', 'slash', 'fight', 'pierce', 'kill', 'bash', 'defend', 'hit', 'thrust', 'parry', 'stab']
      +aliases = ['defend', 'kill', 'bash', 'hit', 'thrust', 'slash', 'parry', 'pierce', 'chop', 'fight', 'stab']
      @@ -805,7 +805,7 @@ parry - forgoes your attack but will make you harder to hit on next

      -search_index_entry = {'aliases': 'chop slash fight pierce kill bash defend hit thrust parry stab', 'category': 'tutorialworld', 'key': 'attack', 'no_prefix': ' chop slash fight pierce kill bash defend hit thrust parry stab', '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 '}
      +search_index_entry = {'aliases': 'defend kill bash hit thrust slash parry pierce chop fight stab', 'category': 'tutorialworld', 'key': 'attack', 'no_prefix': ' defend kill bash hit thrust slash parry pierce chop fight stab', '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 '}
      diff --git a/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.rooms.html b/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.rooms.html index 14257c6cc1..3975977f27 100644 --- a/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.rooms.html +++ b/docs/1.0/api/evennia.contrib.tutorials.tutorial_world.rooms.html @@ -968,7 +968,7 @@ to find something.

      -aliases = ['l', 'feel around', 'search', 'feel', 'fiddle']
      +aliases = ['search', 'fiddle', 'feel around', 'feel', 'l']
      @@ -996,7 +996,7 @@ random chance of eventually finding a light source.

      -search_index_entry = {'aliases': 'l feel around search feel fiddle', 'category': 'tutorialworld', 'key': 'look', 'no_prefix': ' l feel around search feel fiddle', '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 '}
      +search_index_entry = {'aliases': 'search fiddle feel around feel l', 'category': 'tutorialworld', 'key': 'look', 'no_prefix': ' search fiddle feel around feel l', '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 '}
      diff --git a/docs/1.0/api/evennia.contrib.utils.git_integration.git_integration.html b/docs/1.0/api/evennia.contrib.utils.git_integration.git_integration.html index 65f73c64d9..171f9b6955 100644 --- a/docs/1.0/api/evennia.contrib.utils.git_integration.git_integration.html +++ b/docs/1.0/api/evennia.contrib.utils.git_integration.git_integration.html @@ -208,7 +208,7 @@ git evennia pull - Pull the latest evennia code.

      -directory = '/tmp/tmp5fz2dpk5/97a87ed416c72ad8cd92f5ad9ccac087dae0275b/evennia'
      +directory = '/tmp/tmpqtscfy9l/fb4751f3b82e79fbb4e5b7b6718f910759fa8d02/evennia'
      @@ -269,7 +269,7 @@ git pull - Pull the latest code from your current branch.

      -directory = '/tmp/tmp5fz2dpk5/97a87ed416c72ad8cd92f5ad9ccac087dae0275b/evennia/game_template'
      +directory = '/tmp/tmpqtscfy9l/fb4751f3b82e79fbb4e5b7b6718f910759fa8d02/evennia/game_template'
      diff --git a/docs/1.0/api/evennia.html b/docs/1.0/api/evennia.html index 22601c3c04..4f348dc5cf 100644 --- a/docs/1.0/api/evennia.html +++ b/docs/1.0/api/evennia.html @@ -132,6 +132,7 @@
    • evennia.ScriptDB

    • evennia.TASK_HANDLER

    • evennia.TICKER_HANDLER

    • +
    • evennia.TagCategoryProperty

    • evennia.TagProperty

    • evennia.ansi

    • evennia.contrib

    • @@ -336,6 +337,11 @@ with ‘q’, remove the break line and restart server when finished.

    • evennia.contrib.game_systems.clothing.tests
  • +
  • evennia.contrib.game_systems.containers +
  • evennia.contrib.game_systems.cooldowns
    • evennia.contrib.game_systems.cooldowns.cooldowns
    • evennia.contrib.game_systems.cooldowns.tests
    • diff --git a/docs/1.0/api/evennia.typeclasses.tags.html b/docs/1.0/api/evennia.typeclasses.tags.html index 1d96bb5508..5a501f86b1 100644 --- a/docs/1.0/api/evennia.typeclasses.tags.html +++ b/docs/1.0/api/evennia.typeclasses.tags.html @@ -290,7 +290,16 @@ class built by **create_forward_many_to_many_manager()** define
      class evennia.typeclasses.tags.TagProperty(category=None, data=None)[source]

      Bases: object

      -

      Tag property descriptor. Allows for setting tags on an object as Django-like ‘fields’ +

      Tag Property.

      +
      +
      +taghandler_name = 'tags'
      +
      + +
      +
      +__init__(category=None, data=None)[source]
      +

      Tag property descriptor. Allows for setting tags on an object as Django-like ‘fields’ on the class level. Since Tags are almost always used for querying, Tags are always created/assigned along with the object. Make sure the property/tagname does not collide with an existing method/property on the class. If it does, you must use tags.add() @@ -304,15 +313,45 @@ if a tag is set on an object.

      mytag2 = TagProperty(category="tagcategory")
  • + + + + +
    +
    +class evennia.typeclasses.tags.TagCategoryProperty(*args)[source]
    +

    Bases: object

    +

    Tag Category Property.

    -
    -taghandler_name = 'tags'
    +
    +taghandler_name = 'tags'
    -
    -__init__(category=None, data=None)[source]
    -

    Initialize self. See help(type(self)) for accurate signature.

    +
    +__init__(*args)[source]
    +

    Assign a property for a Tag Category, with any number of Tag keys. +This is often more useful than the TagProperty since it’s common to want to check which +tags of a particular category the object is a member of.

    +
    +
    Parameters
    +

    *args (str or callable) – Tag keys to assign to this property, using the category given +by the name of the property. If a callable, it will be called without arguments +to return the tag key. It is not possible to set tag data this way (use the +Taghandler directly for that). Tag keys are not case sensitive.

    +
    +
    Raises
    +

    ValueError – If the input is not a valid tag key or tuple.

    +
    +
    +

    Notes

    +

    It is not possible to set Tags with a None category using a TagCategoryProperty - +use obj.tags.add() instead.

    +

    Example:

    +
    class RogueCharacter(DefaultCharacter):
    +    guild = TagProperty("thieves_guild", "merchant_guild")
    +
    +
    diff --git a/docs/1.0/api/evennia.utils.eveditor.html b/docs/1.0/api/evennia.utils.eveditor.html index ac1e472413..5ee4dbda08 100644 --- a/docs/1.0/api/evennia.utils.eveditor.html +++ b/docs/1.0/api/evennia.utils.eveditor.html @@ -336,7 +336,7 @@ indentation.

    -aliases = [':wq', ':I', ':i', ':dd', ':u', ':A', ':S', ':!', ':echo', ':q', ':uu', ':q!', ':w', ':::', ':h', ':fd', ':y', ':>', ':fi', ':UU', ':=', ':s', ':dw', ':<', ':x', ':', ':f', ':DD', '::', ':r', ':j', ':p']
    +aliases = [':s', ':x', ':u', ':i', ':f', ':fd', ':h', ':q!', ':>', ':wq', ':dd', ':DD', ':uu', ':A', ':p', ':::', ':dw', ':S', ':fi', ':q', ':j', ':I', ':=', '::', ':y', ':', ':echo', ':w', ':!', ':UU', ':r', ':<']
    @@ -364,7 +364,7 @@ efficient presentation.

    -search_index_entry = {'aliases': ':wq :I :i :dd :u :A :S :! :echo :q :uu :q! :w ::: :h :fd :y :> :fi :UU := :s :dw :< :x : :f :DD :: :r :j :p', 'category': 'general', 'key': ':editor_command_group', 'no_prefix': ' :wq :I :i :dd :u :A :S :! :echo :q :uu :q! :w ::: :h :fd :y :> :fi :UU := :s :dw :< :x : :f :DD :: :r :j :p', 'tags': '', 'text': '\n Commands for the editor\n '}
    +search_index_entry = {'aliases': ':s :x :u :i :f :fd :h :q! :> :wq :dd :DD :uu :A :p ::: :dw :S :fi :q :j :I := :: :y : :echo :w :! :UU :r :<', 'category': 'general', 'key': ':editor_command_group', 'no_prefix': ' :s :x :u :i :f :fd :h :q! :> :wq :dd :DD :uu :A :p ::: :dw :S :fi :q :j :I := :: :y : :echo :w :! :UU :r :<', 'tags': '', 'text': '\n Commands for the editor\n '}
    diff --git a/docs/1.0/api/evennia.utils.evmenu.html b/docs/1.0/api/evennia.utils.evmenu.html index 70bd8f8ddf..975bf1eaa3 100644 --- a/docs/1.0/api/evennia.utils.evmenu.html +++ b/docs/1.0/api/evennia.utils.evmenu.html @@ -931,7 +931,7 @@ single question.

    -aliases = ['yes', '__nomatch_command', 'no', 'abort', 'n', 'y', 'a']
    +aliases = ['__nomatch_command', 'yes', 'no', 'n', 'y', 'a', 'abort']
    @@ -957,7 +957,7 @@ single question.

    -search_index_entry = {'aliases': 'yes __nomatch_command no abort n y a', 'category': 'general', 'key': '__noinput_command', 'no_prefix': ' yes __nomatch_command no abort n y a', 'tags': '', 'text': '\n Handle a prompt for yes or no. Press [return] for the default choice.\n\n '}
    +search_index_entry = {'aliases': '__nomatch_command yes no n y a abort', 'category': 'general', 'key': '__noinput_command', 'no_prefix': ' __nomatch_command yes no n y a abort', 'tags': '', 'text': '\n Handle a prompt for yes or no. Press [return] for the default choice.\n\n '}
    diff --git a/docs/1.0/api/evennia.utils.evmore.html b/docs/1.0/api/evennia.utils.evmore.html index 666ff8ad69..85faf077cf 100644 --- a/docs/1.0/api/evennia.utils.evmore.html +++ b/docs/1.0/api/evennia.utils.evmore.html @@ -137,7 +137,7 @@ the caller.msg() construct every time the page is updated.

    -aliases = ['previous', 'abort', 'next', 'end', 'quit', 'n', 'e', 'top', 't', 'p', 'q', 'a']
    +aliases = ['next', 'previous', 'e', 'p', 'n', 'abort', 'a', 'top', 't', 'quit', 'q', 'end']
    @@ -163,7 +163,7 @@ the caller.msg() construct every time the page is updated.

    -search_index_entry = {'aliases': 'previous abort next end quit n e top t p q a', 'category': 'general', 'key': '__noinput_command', 'no_prefix': ' previous abort next end quit n e top t p q a', 'tags': '', 'text': '\n Manipulate the text paging. Catch no-input with aliases.\n '}
    +search_index_entry = {'aliases': 'next previous e p n abort a top t quit q end', 'category': 'general', 'key': '__noinput_command', 'no_prefix': ' next previous e p n abort a top t quit q end', 'tags': '', 'text': '\n Manipulate the text paging. Catch no-input with aliases.\n '}
    diff --git a/docs/1.0/genindex.html b/docs/1.0/genindex.html index 59a681f2ae..7550ae483a 100644 --- a/docs/1.0/genindex.html +++ b/docs/1.0/genindex.html @@ -353,6 +353,8 @@
  • (evennia.typeclasses.attributes.NickHandler method)
  • (evennia.typeclasses.models.TypedObject method) +
  • +
  • (evennia.typeclasses.tags.TagCategoryProperty method)
  • (evennia.typeclasses.tags.TagHandler method)
  • @@ -20219,6 +20221,8 @@
  • TagAdmin (class in evennia.web.admin.tags)
  • tagcategory() (evennia.contrib.full_systems.evscaperoom.objects.EvscaperoomObject property) +
  • +
  • TagCategoryProperty (class in evennia.typeclasses.tags)
  • taget_map_xyz (evennia.contrib.grid.xyzgrid.xymap_legend.TransitionMapNode attribute)
  • @@ -20236,6 +20240,8 @@