mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2024-12-26 21:22:27 -06:00
22 lines
750 B
Python
22 lines
750 B
Python
|
from pandac.PandaModules import *
|
||
|
from direct.distributed import DistributedObject
|
||
|
from direct.directnotify import DirectNotifyGlobal
|
||
|
|
||
|
class DeleteManager(DistributedObject.DistributedObject):
|
||
|
notify = DirectNotifyGlobal.directNotify.newCategory('DeleteManager')
|
||
|
neverDisable = 1
|
||
|
|
||
|
def __init__(self, cr):
|
||
|
DistributedObject.DistributedObject.__init__(self, cr)
|
||
|
|
||
|
def generate(self):
|
||
|
DistributedObject.DistributedObject.generate(self)
|
||
|
self.accept('deleteItems', self.d_setInventory)
|
||
|
|
||
|
def disable(self):
|
||
|
self.ignore('deleteItems')
|
||
|
DistributedObject.DistributedObject.disable(self)
|
||
|
|
||
|
def d_setInventory(self, newInventoryString):
|
||
|
self.sendUpdate('setInventory', [newInventoryString])
|