<gh_stars>1-10
# File: D (Python 2.4)

from pirates.instance import DistributedInstanceWorld

class DistributedMiniGameWorld(DistributedInstanceWorld.DistributedInstanceWorld):
    
    def __init__(self, cr):
        DistributedInstanceWorld.DistributedInstanceWorld.__init__(self, cr)
        self._turnOnWorldGrid = True

    
    def generate(self):
        DistributedInstanceWorld.DistributedInstanceWorld.generate(self)

    
    def announceGenerate(self):
        DistributedInstanceWorld.DistributedInstanceWorld.announceGenerate(self)

    
    def turnOn(self, av = None):
        DistributedInstanceWorld.DistributedInstanceWorld.turnOn(self, None)
        if self.worldGrid and av and self._turnOnWorldGrid:
            self.worldGrid.turnOn(av)
        
        self._turnOnIslands()

    
    def turnOff(self, cacheIslands = []):
        DistributedInstanceWorld.DistributedInstanceWorld.turnOff(self, cacheIslands)

    
    def addWorldInterest(self, area = None):
        DistributedInstanceWorld.DistributedInstanceWorld.addWorldInterest(self, area)
        if area:
            area.turnOn(localAvatar)
        

    
    def removeWorldInterest(self, area = None):
        if not area and area.gridVisContext:
            area = None
        
        DistributedInstanceWorld.DistributedInstanceWorld.removeWorldInterest(self, area)



# File: D (Python 2.4)

from pirates.instance import DistributedInstanceWorld

class DistributedMiniGameWorld(DistributedInstanceWorld.DistributedInstanceWorld):
    
    def __init__(self, cr):
        DistributedInstanceWorld.DistributedInstanceWorld.__init__(self, cr)
        self._turnOnWorldGrid = True

    
    def generate(self):
        DistributedInstanceWorld.DistributedInstanceWorld.generate(self)

    
    def announceGenerate(self):
        DistributedInstanceWorld.DistributedInstanceWorld.announceGenerate(self)

    
    def turnOn(self, av = None):
        DistributedInstanceWorld.DistributedInstanceWorld.turnOn(self, None)
        if self.worldGrid and av and self._turnOnWorldGrid:
            self.worldGrid.turnOn(av)
        
        self._turnOnIslands()

    
    def turnOff(self, cacheIslands = []):
        DistributedInstanceWorld.DistributedInstanceWorld.turnOff(self, cacheIslands)

    
    def addWorldInterest(self, area = None):
        DistributedInstanceWorld.DistributedInstanceWorld.addWorldInterest(self, area)
        if area:
            area.turnOn(localAvatar)
        

    
    def removeWorldInterest(self, area = None):
        if not area and area.gridVisContext:
            area = None
        
        DistributedInstanceWorld.DistributedInstanceWorld.removeWorldInterest(self, area)
# File: D (Python 2.4)