oldschool-toontown/toontown/uberdog/DistributedWhitelistMgr.py

32 lines
944 B
Python
Raw Normal View History

2019-11-02 17:27:54 -05:00
import socket
import datetime
import os
from direct.distributed.DistributedObjectGlobal import DistributedObjectGlobal
from direct.distributed.DistributedObject import DistributedObject
from toontown.toonbase import ToontownGlobals
class DistributedWhitelistMgr(DistributedObject):
notify = directNotify.newCategory('WhitelistMgr')
neverDisable = 1
def __init__(self, cr):
DistributedObject.__init__(self, cr)
base.cr.whitelistMgr = self
def delete(self):
DistributedObject.delete(self)
self.cr.whitelistMgr = None
return
def disable(self):
self.notify.debug("i'm disabling WhitelistMgr right now.")
DistributedObject.disable(self)
def generate(self):
self.notify.debug('BASE: generate')
DistributedObject.generate(self)
def updateWhitelist(self):
messenger.send('updateWhitelist')
self.notify.info('Updating white list')