evennia/contrib
Griatch 58e20e2cf1 Added contrib "evlang", an experimental highly restricted Python code environment. It's intended to be used by untrusted users to add custom code e.g. to their crafted objects and similar. Please heed the warnings in the README file - this is experimental still and more people need to play with it and try to break it.
The system uses a hybrid blacklisting/whitelisting and AST-traversal approach to both remove dangerous builtins as well as disallow potentially exploitable python structures alltogether. Examples are while structures and attribute allocation. All advanced functionality is accessed through a set of "safe" methods on a holder object. You can extend this with your own safe methods in order to add more functionality befitting your game.

The system comes with a host of examples, a few scriptable objects and complete commands for adding code to objects. At this point it's not guaranteed that all systems are safe against meddling however - notably Attributes have no locks defined on them by default (although this system does properly check Attribute lock types should they exixt).

Please test and try to break - and report problems to the Issue tracker/forum as usual.
2012-06-10 22:16:46 +02:00
..
battle_for_evennia Added implementation plan for testing game. 2012-04-01 13:15:49 +02:00
evlang Added contrib "evlang", an experimental highly restricted Python code environment. It's intended to be used by untrusted users to add custom code e.g. to their crafted objects and similar. Please heed the warnings in the README file - this is experimental still and more people need to play with it and try to break it. 2012-06-10 22:16:46 +02:00
tutorial_world Fixed a lingering bug with @set that made it not work when assigning normal strings without quotes. Changed so that proper Python constructs (lists, dicts etc) now requires you to entering proper Python syntax (since this is parsed). 2012-04-15 23:09:56 +02:00
__init__.py Added a new 'contrib' folder for optional code snippets not suitable for the server core. Added contrib/menusystem for implementing a multi-choice menu system. Added contrib/lineeditor - a powerful line editor with commands mimicking VI. Also added an example NPC class using the menu system to allow for a conversation. As part of creating these contributions, lots of bugs were found and fixed. A new and more powerful cmdparser was intruduced as a result - this one is much easier to understand than the old one, while being more efficient and versatile. All testsuites were updated. Also: Resolves issue 165. 2011-05-12 21:51:11 +00:00
chargen.py Fixed headers on contribs, they were still referring to the old base*.py -style files under gamesrc. 2012-04-01 22:23:47 +02:00
lineeditor.py Moved contribs to use the new API. Added the system command keys to a property syscmdkeys, for easy access from ev.py. 2012-03-25 18:11:14 +02:00
menu_login.py Fixed headers on contribs, they were still referring to the old base*.py -style files under gamesrc. 2012-04-01 22:23:47 +02:00
menusystem.py Fixed headers on contribs, they were still referring to the old base*.py -style files under gamesrc. 2012-04-01 22:23:47 +02:00
misc_commands.py Fixed headers on contribs, they were still referring to the old base*.py -style files under gamesrc. 2012-04-01 22:23:47 +02:00
README Updated contrib README. 2011-11-14 11:51:32 +01:00
talking_npc.py Trunk: Merged griatch-branch. This implements a new reload mechanism - splitting Evennia into two processes: Server and Portal with different tasks. Also cleans and fixes several bugs in script systems as well as introduces i18n (courtesy of raydeejay). 2011-09-03 10:22:19 +00:00

'Contrib' folder
----------------

This folder contains 'contributions': extra snippets of code that are
potentially very useful for the game coder but which are considered
too game-specific to be a part of the main Evennia game server.  These
modules are not used unless you explicitly import them. See each file
for more detailed instructions on how to install. 

If you want to edit, tweak or expand on this code you should copy the
things you want from here into game/gamesrc and change them there.

* Evennia MenuSystem (Griatch 2011) - A base set of classes and
      cmdsets for creating in-game multiple-choice menus in
      Evennia. The menu tree can be of any depth.  Menu options can be
      numbered or given custom keys, and each option can execute
      code. Also contains a yes/no question generator function. This
      is intended to be used by commands and presents a y/n question
      to the user for accepting an action. Includes a simple new
      command 'menu' for testing and debugging.

* Evennia Lineeditor (Griatch 2011) - A powerful line-by-line editor
      for editing text in-game. Mimics the command names of the famous
      VI text editor. Supports undo/redo, search/replace,
      regex-searches, buffer formatting, indenting etc. It comes with
      its own help system. (Makes minute use of the MenuSystem module
      to show a y/n question if quitting without having
      saved). Includes a basic command '@edit' for activating the
      editor.

* Talking_NPC (Griatch 2011) - An example of a simple NPC object with
      which you can strike up a menu-driven converstaion. Uses the
      MenuSystem to allow conversation options. The npc object defines
      a command 'talk' for starting the (brief) conversation.

* Evennia Menu Login (Griatch 2011) - A menu-driven login screen that 
      replaces the default command-based one. Uses the MenuSystem 
      contrib. Does not require players to give their email and
      doesn't auto-create a Character object at first login like the 
      default system does.

* CharGen (Griatch 2011) - A simple Character creator and selector for
      Evennia's ooc mode. Works well with the menu login contrib and 
      is intended as a starting point for building a more full-featured 
      character creation system.