mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2024-10-31 16:57:54 +00:00
31 lines
976 B
Python
31 lines
976 B
Python
|
from direct.distributed import DistributedObject
|
||
|
from direct.directnotify import DirectNotifyGlobal
|
||
|
from toontown.toonbase import TTLocalizer
|
||
|
|
||
|
class DistributedTrophyMgr(DistributedObject.DistributedObject):
|
||
|
notify = DirectNotifyGlobal.directNotify.newCategory('DistributedTrophyMgr')
|
||
|
neverDisable = 1
|
||
|
|
||
|
def __init__(self, cr):
|
||
|
DistributedObject.DistributedObject.__init__(self, cr)
|
||
|
|
||
|
def generate(self):
|
||
|
if base.cr.trophyManager != None:
|
||
|
base.cr.trophyManager.delete()
|
||
|
base.cr.trophyManager = self
|
||
|
DistributedObject.DistributedObject.generate(self)
|
||
|
return
|
||
|
|
||
|
def disable(self):
|
||
|
base.cr.trophyManager = None
|
||
|
DistributedObject.DistributedObject.disable(self)
|
||
|
return
|
||
|
|
||
|
def delete(self):
|
||
|
base.cr.trophyManager = None
|
||
|
DistributedObject.DistributedObject.delete(self)
|
||
|
return
|
||
|
|
||
|
def d_requestTrophyScore(self):
|
||
|
self.sendUpdate('requestTrophyScore', [])
|