Update gamemodes.py.example
Old file was out-of-date wrt recent changes. Add in missing imports and fix the do not edit warning to be less wonky. Also add in skeleton example gamemode
This commit is contained in:
parent
4e41dfe47a
commit
8bb12f73e6
@ -1,17 +1,26 @@
|
||||
# To add new game modes, rename this file to 'gamemodes.py' then add them in
|
||||
# Basic frame for the game modes in src/gamemodes.py
|
||||
|
||||
# *** DO NOT TOUCH ANY OF THE CODE BETWEEN THE LINES 4 AND 17 ***
|
||||
|
||||
from src.messages import messages
|
||||
from src.gamemodes import (GameMode, game_mode, reset_roles)
|
||||
import src.settings as var
|
||||
from src.utilities import *
|
||||
from src.messages import messages
|
||||
from src import events
|
||||
|
||||
from src.gamemodes import (
|
||||
####################################################################
|
||||
# DO NOT EDIT ANYTHING ABOVE THIS LINE, ADD CUSTOM GAMEMODES BELOW #
|
||||
####################################################################
|
||||
|
||||
GameMode,
|
||||
game_mode,
|
||||
reset_roles,
|
||||
@game_mode("mymode", minp=4, maxp=24, likelihood=5)
|
||||
class MyMode(GameMode):
|
||||
"""Example mode. This doesn't do anything special yet."""
|
||||
def __init__(self, arg=""):
|
||||
super().__init__(arg)
|
||||
# Put gamemode settings here
|
||||
|
||||
)
|
||||
def startup(self):
|
||||
# Register events here
|
||||
pass
|
||||
|
||||
# Add custom game modes from this point
|
||||
def teardown(self):
|
||||
# Unregister events here
|
||||
pass
|
||||
|
Loading…
Reference in New Issue
Block a user