From c1a45bcb064668d896aa8e292dac4175d197f14d Mon Sep 17 00:00:00 2001 From: Zach Date: Sun, 10 May 2015 06:47:03 -0500 Subject: [PATCH] gardening AIs --- .../estate/DistributedChangingStatuaryAI.py | 2 +- toontown/estate/DistributedFlowerAI.py | 4 +-- toontown/estate/DistributedGagTreeAI.py | 2 +- toontown/estate/DistributedGardenBoxAI.py | 2 +- toontown/estate/DistributedGardenPlotAI.py | 26 ++++++++++++------- toontown/estate/DistributedLawnDecorAI.py | 8 +++--- toontown/estate/DistributedPlantBaseAI.py | 6 ++--- toontown/estate/DistributedStatuaryAI.py | 6 ++--- toontown/estate/DistributedToonStatuaryAI.py | 2 +- 9 files changed, 32 insertions(+), 26 deletions(-) diff --git a/toontown/estate/DistributedChangingStatuaryAI.py b/toontown/estate/DistributedChangingStatuaryAI.py index cb96ede1..abffc37b 100644 --- a/toontown/estate/DistributedChangingStatuaryAI.py +++ b/toontown/estate/DistributedChangingStatuaryAI.py @@ -4,5 +4,5 @@ from toontown.estate.DistributedStatuaryAI import DistributedStatuaryAI class DistributedChangingStatuaryAI(DistributedStatuaryAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedChangingStatuaryAI") - def setGrowthLevel(self, todo0): + def setGrowthLevel(self, growth): pass diff --git a/toontown/estate/DistributedFlowerAI.py b/toontown/estate/DistributedFlowerAI.py index 4a5a7fa0..9e043ce6 100644 --- a/toontown/estate/DistributedFlowerAI.py +++ b/toontown/estate/DistributedFlowerAI.py @@ -4,8 +4,8 @@ from toontown.estate.DistributedPlantBaseAI import DistributedPlantBaseAI class DistributedFlowerAI(DistributedPlantBaseAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedFlowerAI") - def setTypeIndex(self, todo0): + def setTypeIndex(self, index): pass - def setVariety(self, todo0): + def setVariety(self, variety): pass diff --git a/toontown/estate/DistributedGagTreeAI.py b/toontown/estate/DistributedGagTreeAI.py index b24cbffc..dde4f453 100644 --- a/toontown/estate/DistributedGagTreeAI.py +++ b/toontown/estate/DistributedGagTreeAI.py @@ -4,7 +4,7 @@ from toontown.estate.DistributedPlantBaseAI import DistributedPlantBaseAI class DistributedGagTreeAI(DistributedPlantBaseAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedGagTreeAI") - def setWilted(self, todo0): + def setWilted(self, wilted): pass def requestHarvest(self): diff --git a/toontown/estate/DistributedGardenBoxAI.py b/toontown/estate/DistributedGardenBoxAI.py index 9f71ed2d..9f8948bc 100644 --- a/toontown/estate/DistributedGardenBoxAI.py +++ b/toontown/estate/DistributedGardenBoxAI.py @@ -4,5 +4,5 @@ from toontown.estate.DistributedLawnDecorAI import DistributedLawnDecorAI class DistributedGardenBoxAI(DistributedLawnDecorAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedGardenBoxAI") - def setTypeIndex(self, todo0): + def setTypeIndex(self, index): pass diff --git a/toontown/estate/DistributedGardenPlotAI.py b/toontown/estate/DistributedGardenPlotAI.py index e9748cde..2130a1e4 100644 --- a/toontown/estate/DistributedGardenPlotAI.py +++ b/toontown/estate/DistributedGardenPlotAI.py @@ -1,20 +1,26 @@ from direct.directnotify import DirectNotifyGlobal from toontown.estate.DistributedLawnDecorAI import DistributedLawnDecorAI +import DistributedToonStatuaryAI +import DistributedStatuaryAI class DistributedGardenPlotAI(DistributedLawnDecorAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedGardenPlotAI") - def plantFlower(self, todo0, todo1): - pass + def plantFlower(self, species, variety): + flower = DistributedFlowerAI.DistributedFlowerAI() - def plantGagTree(self, todo0, todo1): - pass + def plantGagTree(self, gagTrack, gagLevel): + tree = DistributedGagTreeAI.DistributedGagTreeAI() - def plantStatuary(self, todo0): - pass + def plantStatuary(self, species): + statue = DistributedStatuaryAI.DistributedStatuaryAI() - def plantToonStatuary(self, todo0, todo1): - pass + def plantToonStatuary(self, species, dnaCode): + statue = DistributedToonStatuaryAI.DistributedToonStatuaryAI() - def plantNothing(self, todo0): - pass + def plantNothing(self, burntBeans): + avId = self.air.getAvatarIdFromSender() + av = self.air.doId2do[avId] + money = av.getMoney() + av.setMoney(money - burntBeans) + av.d_setMoney(money - burntBeans) diff --git a/toontown/estate/DistributedLawnDecorAI.py b/toontown/estate/DistributedLawnDecorAI.py index 7ee4669f..e001379b 100644 --- a/toontown/estate/DistributedLawnDecorAI.py +++ b/toontown/estate/DistributedLawnDecorAI.py @@ -4,16 +4,16 @@ from direct.distributed.DistributedNodeAI import DistributedNodeAI class DistributedLawnDecorAI(DistributedNodeAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedLawnDecorAI") - def setPlot(self, todo0): + def setPlot(self, plot): pass - def setHeading(self, todo0): + def setHeading(self, h): pass - def setPosition(self, todo0, todo1, todo2): + def setPosition(self, x, y, z): pass - def setOwnerIndex(self, todo0): + def setOwnerIndex(self, index): pass def plotEntered(self): diff --git a/toontown/estate/DistributedPlantBaseAI.py b/toontown/estate/DistributedPlantBaseAI.py index 956464e1..afa09c37 100644 --- a/toontown/estate/DistributedPlantBaseAI.py +++ b/toontown/estate/DistributedPlantBaseAI.py @@ -4,13 +4,13 @@ from toontown.estate.DistributedLawnDecorAI import DistributedLawnDecorAI class DistributedPlantBaseAI(DistributedLawnDecorAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedPlantBaseAI") - def setTypeIndex(self, todo0): + def setTypeIndex(self, index): pass - def setWaterLevel(self, todo0): + def setWaterLevel(self, water): pass - def setGrowthLevel(self, todo0): + def setGrowthLevel(self, growth): pass def waterPlant(self): diff --git a/toontown/estate/DistributedStatuaryAI.py b/toontown/estate/DistributedStatuaryAI.py index 9b862c64..01d28e2d 100644 --- a/toontown/estate/DistributedStatuaryAI.py +++ b/toontown/estate/DistributedStatuaryAI.py @@ -4,11 +4,11 @@ from toontown.estate.DistributedLawnDecorAI import DistributedLawnDecorAI class DistributedStatuaryAI(DistributedLawnDecorAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedStatuaryAI") - def setTypeIndex(self, todo0): + def setTypeIndex(self, index): pass - def setWaterLevel(self, todo0): + def setWaterLevel(self, water): pass - def setGrowthLevel(self, todo0): + def setGrowthLevel(self, growth): pass diff --git a/toontown/estate/DistributedToonStatuaryAI.py b/toontown/estate/DistributedToonStatuaryAI.py index f98b7758..2b3b1411 100644 --- a/toontown/estate/DistributedToonStatuaryAI.py +++ b/toontown/estate/DistributedToonStatuaryAI.py @@ -4,5 +4,5 @@ from toontown.estate.DistributedStatuaryAI import DistributedStatuaryAI class DistributedToonStatuaryAI(DistributedStatuaryAI): notify = DirectNotifyGlobal.directNotify.newCategory("DistributedToonStatuaryAI") - def setOptional(self, todo0): + def setOptional(self, opt): pass