Renamed cmdset_ooc -> cmdset_player and settings.CMDSET_OOC -> settings.CMDSET_PLAYER. Also split most of the player-specific commands to a new module player.

This commit is contained in:
Griatch 2013-04-11 01:02:05 +02:00
parent 5874505902
commit 1aff5f1fd1
14 changed files with 53 additions and 593 deletions

View file

@ -12,7 +12,7 @@ from src.comms.models import Channel, Msg, PlayerChannelConnection, ExternalChan
from src.comms import irc, imc2, rss
from src.comms.channelhandler import CHANNELHANDLER
from src.utils import create, utils
from src.commands.default.muxcommand import MuxCommand, MuxCommandOOC
from src.commands.default.muxcommand import MuxCommand, MuxPlayerCommand
# limit symbol import for API
__all__ = ("CommCommand", "CmdAddCom", "CmdDelCom", "CmdAllCom",
@ -624,7 +624,7 @@ class CmdCdesc(MuxCommand):
channel.save()
caller.msg("Description of channel '%s' set to '%s'." % (channel.key, self.rhs))
class CmdPage(MuxCommandOOC):
class CmdPage(MuxPlayerCommand):
"""
page - send private message
@ -649,7 +649,7 @@ class CmdPage(MuxCommandOOC):
def func(self):
"Implement function using the Msg methods"
# this is a MuxCommandOOC, which means caller will be a Player.
# this is a MuxPlayerCommand, which means caller will be a Player.
caller = self.caller
# get the messages we've sent (not to channels)