mirror of
https://github.com/evennia/evennia.git
synced 2026-03-31 21:17:17 +02:00
Run Migrations. Added player field to script model in order to allow Players to be scripted in the same way Objects can.
This commit is contained in:
parent
75ef743297
commit
8b52591c2f
5 changed files with 137 additions and 7 deletions
|
|
@ -822,9 +822,10 @@ class CmdIRC2Chan(MuxCommand):
|
|||
self.msg(string)
|
||||
return
|
||||
|
||||
botname = "ircbot-%s" % irc_botname
|
||||
|
||||
if('disconnect' in self.switches or 'remove' in self.switches or
|
||||
'delete' in self.switches):
|
||||
botname = "ircbot-%s" % irc_botname
|
||||
matches = PlayerDB.filter(db_isbot=True, db_key=botname)
|
||||
if matches:
|
||||
matches[0].delete()
|
||||
|
|
@ -834,7 +835,7 @@ class CmdIRC2Chan(MuxCommand):
|
|||
return
|
||||
|
||||
# create a new bot
|
||||
bot = create.create_player(bots.IRCBot, key=botname)
|
||||
bot = create.create_player(botname, None, None, typeclass=bots.IRCBot)
|
||||
bot.start(ev_channel=channel, irc_botname=irc_botname, irc_channel=irc_channel,
|
||||
irc_network=irc_network, irc_port=irc_port)
|
||||
self.msg("Connection created. Starting IRC bot.")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue