mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2025-01-09 17:53:50 +00:00
parent
9d042186b7
commit
10da5ad398
2 changed files with 5 additions and 26 deletions
|
@ -110,7 +110,7 @@ class Garden:
|
||||||
box.setPos(x, y, 0)
|
box.setPos(x, y, 0)
|
||||||
box.setH(h)
|
box.setH(h)
|
||||||
box.setOwnerIndex(houseIndex)
|
box.setOwnerIndex(houseIndex)
|
||||||
box.generate()#WithRequired(estateMgr.zoneId)
|
box.generateWithRequired(estateMgr.zoneId)
|
||||||
self.objects.append(box)
|
self.objects.append(box)
|
||||||
|
|
||||||
plots = GardenGlobals.estatePlots[houseIndex]
|
plots = GardenGlobals.estatePlots[houseIndex]
|
||||||
|
@ -127,7 +127,7 @@ class Garden:
|
||||||
tree.setWaterLevel(waterLevel)
|
tree.setWaterLevel(waterLevel)
|
||||||
tree.setGrowthLevel(growthLevel)
|
tree.setGrowthLevel(growthLevel)
|
||||||
tree.calculate(nextGrowth, nextLevelDecrease)
|
tree.calculate(nextGrowth, nextLevelDecrease)
|
||||||
tree.generate()#WithRequired(estateMgr.zoneId)
|
tree.generateWithRequired(estateMgr.zoneId)
|
||||||
self.trees.append(tree)
|
self.trees.append(tree)
|
||||||
|
|
||||||
class GardenManager:
|
class GardenManager:
|
||||||
|
|
|
@ -1,33 +1,12 @@
|
||||||
from direct.directnotify import DirectNotifyGlobal
|
from direct.directnotify import DirectNotifyGlobal
|
||||||
from toontown.estate.DistributedPlantBaseAI import DistributedPlantBaseAI
|
from toontown.estate.DistributedPlantBaseAI import DistributedPlantBaseAI
|
||||||
import GardenGlobals
|
|
||||||
|
|
||||||
class DistributedGagTreeAI(DistributedPlantBaseAI):
|
class DistributedGagTreeAI(DistributedPlantBaseAI):
|
||||||
notify = DirectNotifyGlobal.directNotify.newCategory("DistributedGagTreeAI")
|
notify = DirectNotifyGlobal.directNotify.newCategory("DistributedGagTreeAI")
|
||||||
|
|
||||||
def __init__(self, air):
|
def setWilted(self, todo0):
|
||||||
DistributedPlantBaseAI.__init__(self, air)
|
pass
|
||||||
self.setTypeIndex(GardenGlobals.GAG_TREE_TYPE)
|
|
||||||
self.wilted = 0
|
|
||||||
|
|
||||||
def setWilted(self, wilted):
|
|
||||||
self.wilted = wilted
|
|
||||||
|
|
||||||
def d_setWilted(self, wilted):
|
|
||||||
self.sendUpdate("setWilted", [wilted])
|
|
||||||
|
|
||||||
def b_setWilted(self, wilted):
|
|
||||||
self.setWilted(wilted)
|
|
||||||
self.d_setWilted(wilted)
|
|
||||||
|
|
||||||
def getWilted(self):
|
|
||||||
return self.wilted
|
|
||||||
|
|
||||||
def calculate(self, nextGrowth, nextLevelDecrease):
|
|
||||||
now = time.time()
|
|
||||||
while nextLevelDecrease < now:
|
|
||||||
nextLevelDecrease += 3893475798397 # to do
|
|
||||||
self.b_setWaterLevel(max(-1, self.waterLevel - 1))
|
|
||||||
|
|
||||||
def requestHarvest(self):
|
def requestHarvest(self):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue