Extended install instructions for gendersub. REsolve #2525.
This commit is contained in:
parent
8a7ebf992b
commit
4af263b362
1 changed files with 30 additions and 1 deletions
|
|
@ -17,10 +17,39 @@ An object can have the following genders:
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
Import and add the `SetGender` command to your default cmdset in
|
Import and add the `SetGender` command to your default cmdset in
|
||||||
`mygame/commands/default_cmdset.py`
|
`mygame/commands/default_cmdset.py`:
|
||||||
|
|
||||||
|
```python
|
||||||
|
# mygame/commands/default_cmdsets.py
|
||||||
|
|
||||||
|
# ...
|
||||||
|
|
||||||
|
from evennia.contrib.game_systems.gendersub import SetGender # <---
|
||||||
|
|
||||||
|
# ...
|
||||||
|
|
||||||
|
class CharacterCmdSet(default_cmds.CharacterCmdSet):
|
||||||
|
# ...
|
||||||
|
def at_cmdset_creation(self):
|
||||||
|
# ...
|
||||||
|
self.add(SetGender()) # <---
|
||||||
|
```
|
||||||
|
|
||||||
Make your `Character` inherit from `GenderCharacter`.
|
Make your `Character` inherit from `GenderCharacter`.
|
||||||
|
|
||||||
|
```python
|
||||||
|
# mygame/typeclasses/characters.py
|
||||||
|
|
||||||
|
# ...
|
||||||
|
|
||||||
|
from evennia.contrib.game_systems.gendersub import GenderCharacter # <---
|
||||||
|
|
||||||
|
class Character(GenderCharacter): # <---
|
||||||
|
# ...
|
||||||
|
```
|
||||||
|
|
||||||
|
Reload the server (`evennia reload` or `reload` from inside the game).
|
||||||
|
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue