Add syntax hilighting in egi_client/README.md.
This commit is contained in:
parent
8561e3de23
commit
1781a5acda
1 changed files with 68 additions and 64 deletions
|
|
@ -19,50 +19,52 @@ Start by `cd`'ing to your game directory. From there, open up
|
|||
`server/conf/server_services_plugins.py`. It might look something like this
|
||||
if you don't have any other optional add-ons enabled:
|
||||
|
||||
"""
|
||||
Server plugin services
|
||||
```python
|
||||
"""
|
||||
Server plugin services
|
||||
|
||||
This plugin module can define user-created services for the Server to
|
||||
start.
|
||||
This plugin module can define user-created services for the Server to
|
||||
start.
|
||||
|
||||
This module must handle all imports and setups required to start a
|
||||
twisted service (see examples in evennia.server.server). It must also
|
||||
contain a function start_plugin_services(application). Evennia will
|
||||
call this function with the main Server application (so your services
|
||||
can be added to it). The function should not return anything. Plugin
|
||||
services are started last in the Server startup process.
|
||||
"""
|
||||
This module must handle all imports and setups required to start a
|
||||
twisted service (see examples in evennia.server.server). It must also
|
||||
contain a function start_plugin_services(application). Evennia will
|
||||
call this function with the main Server application (so your services
|
||||
can be added to it). The function should not return anything. Plugin
|
||||
services are started last in the Server startup process.
|
||||
"""
|
||||
|
||||
|
||||
def start_plugin_services(server):
|
||||
def start_plugin_services(server):
|
||||
"""
|
||||
This hook is called by Evennia, last in the Server startup process.
|
||||
|
||||
server - a reference to the main server application.
|
||||
"""
|
||||
pass
|
||||
|
||||
```
|
||||
|
||||
To enable the client, import `EvenniaGameIndexService` and fire it up after the
|
||||
Evennia server has finished starting:
|
||||
|
||||
"""
|
||||
Server plugin services
|
||||
```python
|
||||
"""
|
||||
Server plugin services
|
||||
|
||||
This plugin module can define user-created services for the Server to
|
||||
start.
|
||||
This plugin module can define user-created services for the Server to
|
||||
start.
|
||||
|
||||
This module must handle all imports and setups required to start a
|
||||
twisted service (see examples in evennia.server.server). It must also
|
||||
contain a function start_plugin_services(application). Evennia will
|
||||
call this function with the main Server application (so your services
|
||||
can be added to it). The function should not return anything. Plugin
|
||||
services are started last in the Server startup process.
|
||||
"""
|
||||
This module must handle all imports and setups required to start a
|
||||
twisted service (see examples in evennia.server.server). It must also
|
||||
contain a function start_plugin_services(application). Evennia will
|
||||
call this function with the main Server application (so your services
|
||||
can be added to it). The function should not return anything. Plugin
|
||||
services are started last in the Server startup process.
|
||||
"""
|
||||
|
||||
from evennia.contrib.egi_client import EvenniaGameIndexService
|
||||
from evennia.contrib.egi_client import EvenniaGameIndexService
|
||||
|
||||
def start_plugin_services(server):
|
||||
def start_plugin_services(server):
|
||||
"""
|
||||
This hook is called by Evennia, last in the Server startup process.
|
||||
|
||||
|
|
@ -70,16 +72,17 @@ Evennia server has finished starting:
|
|||
"""
|
||||
egi_service = EvenniaGameIndexService()
|
||||
server.services.addService(egi_service)
|
||||
|
||||
```
|
||||
|
||||
Next, configure your game listing by opening up `server/conf/settings.py` and
|
||||
using the following as a starting point:
|
||||
|
||||
######################################################################
|
||||
# Contrib config
|
||||
######################################################################
|
||||
```python
|
||||
######################################################################
|
||||
# Contrib config
|
||||
######################################################################
|
||||
|
||||
GAME_INDEX_LISTING = {
|
||||
GAME_INDEX_LISTING = {
|
||||
'game_status': 'pre-alpha',
|
||||
# Optional, comment out or remove if N/A
|
||||
'game_website': 'http://my-game.com',
|
||||
|
|
@ -97,7 +100,8 @@ Next, configure your game listing by opening up `server/conf/settings.py` and
|
|||
'telnet_port': 1234,
|
||||
# At minimum, specify this or the telnet_* options. Both is fine, too.
|
||||
'web_client_url': 'http://my-game.com/webclient',
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
The following section in this README.md will go over all possible values.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue