Welcome to Evennia! This multi-part Beginner Tutorial will help get you off the ground and running.
You may choose topics that seem interesting but, if you follow this tutorial through to the end, you will have created your own small online game to play and share with others!
Things You Need¶
A command line interface
A MUD client (or web browser)
Evennia installed and a game-dir initialized
A Command Line Interface¶
You need to know how to find the terminal/console in your OS. The Evennia server can be controlled from in-game, but you will realistically need to use the command-line interface to get anywhere. Here are some starters:
Note that the documentation typically uses forward-slashes (
/) for file system paths. Windows users should convert these to back-slashes (
A Fresh Game-Dir?¶
You should make sure that you have successfully installed Evennia. If you followed the instructions, you will have already created a game-dir. The documentation will continue to refer to this game-dir as
mygame, so you may want to re-use it or make a new one specific to this tutorial only – it’s up to you.
If you already have a game-dir and want a new one specific to this tutorial, use the
evennia stop command to halt the running server. Then, initialize a new game-dir somewhere else (not inside the previous game-dir!).
A MUD Client¶
You may already have a preferred MUD client. Check out the grid of supported clients. Or, if telnet’s not your thing, you may also simply use Evennia’s web-client in your preferred browser.
Make sure you know how to connect and log in to your locally running Evennia server.
In this documentation we often interchangeably use the terms ‘MUD’, ‘MU’, and ‘MU*’ to represent all the historically different forms of text-based multiplayer game-styles (i.e., MUD, MUX, MUSH, MUCK, MOO, etc.). Evennia can be used to create any of these game-styles… and more!
A Text Editor or IDE¶
You need a text editor application to edit Python source files. Most anything that can edit and output raw text should work (…so not Microsoft Word).
Here’s a blog post summing up a variety of text editor options - these things don’t change much from year to year. Popular choices for Python are PyCharm, VSCode, Atom, Sublime Text, and Notepad++. Evennia is – to a very large degree – coded in VIM, but it is not suitable for beginners.
Use Spaces, Not Tabs< br/> Make sure to configure your text editor so that pressing the ‘Tab’ key inserts 4 spaces rather than a tab-character. Because Python is whitespace-aware, this simple practice will make your life much easier.
You should now be ready to move on to the first part of the Beginner Tutorial! (In the future, use the
previous | next buttons on the top/bottom of the page to progress.)
Click here to see the full index of all parts and lessons of the Beginner-Tutorial.
- Part 1: What We Have
- 1. Using Commands and Building Stuff
- 2. The Tutorial World
- 3. Intro to using Python with Evennia
- 3.1. Evennia Hello world
- 3.2. Making some text ‘graphics’
- 3.3. Importing code from other modules
- 3.4. Sending text to others
- 3.5. Parsing Python errors
- 3.6. Passing arguments to functions
- 3.7. Finding others to send to
- 3.8. Multi-line py
- 3.9. Other ways to test Python code
- 3.10. ipython
- 3.11. Conclusions
- 4. Overview of your new Game Dir
- 5. Introduction to Python classes and objects
- 6. Overview of the Evennia library
- 7. Making objects persistent
- 7.1. Our first persistent object
- 7.2. Typeclasses
- 7.3. Modifying ourselves
- 7.4. Extra Credits
- 7.5. Conclusions
- 8. Adding custom commands
- 9. Parsing Command input
- 10. Creating things
- 11. Searching for things
- 11.1. Main search functions
- 11.2. Searching using Object.search
- 11.3. What can be searched for
- 11.4. Finding objects relative each other
- 11.5. Summary
- 12. Advanced searching - Django Database queries
- 13. Building a chair you can sit on
- Part 2: What We Want
- 1. Where do I begin?
- 2. On Planning a Game
- 3. Planning our tutorial game
- 3.1. Game concept
- 3.2. Administration
- 3.2.1. Should your game rules be enforced by coded systems by human game masters?
- 3.2.2. What is the staff hierarchy in your game? Is vanilla Evennia roles enough or do you need something else?
- 3.2.3. Should players be able to post out-of-characters on channels and via other means like bulletin-boards?
- 3.3. Building
- 3.4. Systems
- 3.4.1. Do you base your game off an existing RPG system or make up your own?
- 3.4.2. What are the game mechanics? How do you decide if an action succeeds or fails?
- 3.4.3. Does the flow of time matter in your game - does night and day change? What about seasons?
- 3.4.4. Do you want changing, global weather or should weather just be set manually in roleplay?
- 3.4.5. Do you want a coded world-economy or just a simple barter system? Or no formal economy at all?
- 3.4.6. Do you have concepts like reputation and influence?
- 3.4.7. Will your characters be known by their name or only by their physical appearance?
- 3.5. Rooms
- 3.6. Objects
- 3.6.1. How numerous are your objects? Do you want large loot-lists or are objects just role playing props?
- 3.6.2. Is each coin a separate object or do you just store a bank account value?
- 3.6.3. Do multiple similar objects form stack and how are those stacks handled in that case?
- 3.6.4. Does an object have weight or volume (so you cannot carry an infinite amount of them)?
- 3.6.5. Can objects be broken? Can they be repaired?
- 3.6.6. Can you fight with a chair or a flower or must you use a special ‘weapon’ kind of thing?
- 3.6.7. Will characters be able to craft new objects?
- 3.6.8. Should mobs/NPCs have some sort of AI?
- 3.6.9. Are NPCs and mobs different entities? How do they differ?
- 3.6.10. _Should there be NPCs giving quests? If so, how do you track Quest status?
- 3.7. Characters
- 3.7.1. Can players have more than one Character active at a time or are they allowed to multi-play?
- 3.7.2. How does the character-generation work?
- 3.7.3. How do you implement different “classes” or “races”?
- 3.7.4. If a Character can hide in a room, what skill will decide if they are detected?
- 3.7.5. What does the skill tree look like? Can a Character gain experience to improve? By killing enemies? Solving quests? By roleplaying?
- 3.7.6. May player-characters attack each other (PvP)?
- 3.7.7. What are the penalties of defeat? Permanent death? Quick respawn? Time in prison?
- 3.8. Conclusions
- Part 3: How We Get There (Example Game)
- 1. Code structure and Utilities
- 2. Rules and dice rolling
- 2.1. Summary of Knave rules
- 2.2. Making a rule module
- 2.3. Rolling dice
- 2.4. Testing
- 2.5. Summary
- 3. Player Characters
- 4. In-game Objects and items
- 5. Handling Equipment
- 5.1. EquipmentHandler that saves
- 5.2. Connecting the EquipmentHandler
- 5.3. Expanding the Equipmenthandler
- 5.6. Moving things around
- 5.7. Get everything
- 5.8. Weapon and armor
- 5.9. Extra credits
- 5.10. Unit Testing
- 5.11. Summary
- 6. Character Generation
- 6.1. How it will work
- 6.2. Random tables
- 6.3. Storing state of the menu
- 6.4. Initializing EvMenu
- 6.5. Main Node: Choosing what to do
- 6.6. Node: Changing your name
- 6.7. Node: Swapping Abilities around
- 6.8. Node: Creating the Character
- 6.9. Tying the nodes together
- 6.10. Conclusions
- 7. In-game Rooms
- 8. Non-Player-Characters
- 9. Combat base framework
- 9.1. CombatHandler
- 9.2. Actions
- 9.3. Action dicts
- 9.4. Action classes
- 9.5. Testing
- 9.6. Conclusions
- 10. Twitch Combat
- 10.1. General principle
- 10.2. Twitch combat handler
- 10.3. Commands
- 10.4. Grouping Commands for use
- 10.5. Unit Testing
- 10.6. A small combat test
- 10.7. Conclusions
- 11. Turnbased Combat
- 11.1. General Principle
- 11.2. Turnbased combat handler
- 11.3. Using EvMenu for the combat menu
- 11.4. Menu for Turnbased combat
- 11.5. Attack Command
- 11.6. Making sure the menu stops
- 11.7. Testing
- 11.8. A small combat test
- 11.9. Conclusions
- 12. NPC and monster AI
- 13. Dynamically generated Dungeon
- 14. Game Quests
- 15. In-game Shops
- 16. In-game Commands
- Part 4: Using What We Created
- Part 5: Showing the World