mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2024-12-23 11:42:39 -06:00
Why was that even there!! + 5 more unique pets every day
This commit is contained in:
parent
067fb04dbd
commit
2649fc5256
3 changed files with 4 additions and 6 deletions
|
@ -35,8 +35,6 @@ class PetshopBuildingAI:
|
|||
self.interior.generateWithRequired(self.interiorZone)
|
||||
|
||||
self.npcs = NPCToons.createNpcsInZone(self.air, self.interiorZone)
|
||||
|
||||
seeds = self.air.petMgr.getAvailablePets(1, len(self.npcs))
|
||||
|
||||
door = DistributedDoorAI.DistributedDoorAI(
|
||||
self.air, blockNumber, DoorTypes.EXT_STANDARD)
|
||||
|
|
|
@ -7,7 +7,7 @@ def getDayId():
|
|||
return int(time.time() / DAY)
|
||||
|
||||
class PetManagerAI:
|
||||
NUM_DAILY_PETS = 5
|
||||
NUM_DAILY_PETS = 10
|
||||
|
||||
def __init__(self, air):
|
||||
self.air = air
|
||||
|
@ -28,11 +28,11 @@ class PetManagerAI:
|
|||
self.seeds['day'] = getDayId()
|
||||
simbase.backups.save('pet-seeds', (self.air.districtId,), self.seeds)
|
||||
|
||||
def getAvailablePets(self, seed, safezoneId):
|
||||
def getAvailablePets(self, safezoneId):
|
||||
if self.seeds.get('day', -1) != getDayId():
|
||||
self.generateSeeds()
|
||||
|
||||
return list(set(self.seeds.get(safezoneId, [seed])))
|
||||
return self.seeds[safezoneId] if safezoneId in self.seeds else self.seeds[str(safezoneId)]
|
||||
|
||||
def createNewPetFromSeed(self, avId, seed, nameIndex, gender, safeZoneId):
|
||||
av = self.air.doId2do[avId]
|
||||
|
|
|
@ -27,7 +27,7 @@ class DistributedNPCPetclerkAI(DistributedNPCToonBaseAI):
|
|||
if self.isBusy():
|
||||
self.freeAvatar(avId)
|
||||
return
|
||||
self.petSeeds = self.air.petMgr.getAvailablePets(3, ZoneUtil.getCanonicalHoodId(self.zoneId))
|
||||
self.petSeeds = self.air.petMgr.getAvailablePets(ZoneUtil.getCanonicalHoodId(self.zoneId))
|
||||
numGenders = len(PetDNA.PetGenders)
|
||||
self.petSeeds *= numGenders
|
||||
self.petSeeds.sort()
|
||||
|
|
Loading…
Reference in a new issue