mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2025-01-09 17:53:50 +00:00
Decorations should only be used on their correct holidays pls.
This commit is contained in:
parent
a03c70c0e6
commit
c1e1f5164a
9 changed files with 107 additions and 42 deletions
|
@ -3214,6 +3214,8 @@ dclass DistributedPartyManager : DistributedObject {
|
||||||
updateToPublicPartyCountUdToAllAi(uint32 partyCount, uint64 partyId) airecv;
|
updateToPublicPartyCountUdToAllAi(uint32 partyCount, uint64 partyId) airecv;
|
||||||
requestShardIdZoneIdForHostId(uint32) clsend airecv;
|
requestShardIdZoneIdForHostId(uint32) clsend airecv;
|
||||||
sendShardIdZoneIdToAvatar(uint32, uint32);
|
sendShardIdZoneIdToAvatar(uint32, uint32);
|
||||||
|
partyManagerUdStartingUp() airecv;
|
||||||
|
partyManagerUdLost() airecv;
|
||||||
updateAllPartyInfoToUd(uint32, uint64, uint32, uint32, uint8, uint8, string, uint8 [], uint64);
|
updateAllPartyInfoToUd(uint32, uint64, uint32, uint32, uint8, uint8, string, uint8 [], uint64);
|
||||||
forceCheckStart();
|
forceCheckStart();
|
||||||
requestMw(uint32, string, uint32, uint32);
|
requestMw(uint32, string, uint32, uint32);
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
from pandac.PandaModules import *
|
from pandac.PandaModules import *
|
||||||
|
|
||||||
|
|
||||||
hashVal = 3860069384L
|
hashVal = 4040865593L
|
||||||
|
|
||||||
|
|
||||||
from toontown.coghq import DistributedCashbotBossSafe, DistributedCashbotBossCrane, DistributedBattleFactory, DistributedCashbotBossTreasure, DistributedCogHQDoor, DistributedSellbotHQDoor, DistributedFactoryElevatorExt, DistributedMintElevatorExt, DistributedLawOfficeElevatorExt, DistributedLawOfficeElevatorInt, LobbyManager, DistributedMegaCorp, DistributedFactory, DistributedLawOffice, DistributedLawOfficeFloor, DistributedLift, DistributedDoorEntity, DistributedSwitch, DistributedButton, DistributedTrigger, DistributedCrushableEntity, DistributedCrusherEntity, DistributedStomper, DistributedStomperPair, DistributedLaserField, DistributedGolfGreenGame, DistributedSecurityCamera, DistributedMover, DistributedElevatorMarker, DistributedBarrelBase, DistributedGagBarrel, DistributedBeanBarrel, DistributedHealBarrel, DistributedGrid, ActiveCell, DirectionalCell, CrusherCell, DistributedCrate, DistributedSinkingPlatform, BattleBlocker, DistributedMint, DistributedMintRoom, DistributedMintBattle, DistributedStage, DistributedStageRoom, DistributedStageBattle, DistributedLawbotBossGavel, DistributedLawbotCannon, DistributedLawbotChair, DistributedCogKart, DistributedCountryClub, DistributedCountryClubRoom, DistributedMoleField, DistributedCountryClubBattle, DistributedMaze, DistributedFoodBelt, DistributedBanquetTable, DistributedGolfSpot
|
from toontown.coghq import DistributedCashbotBossSafe, DistributedCashbotBossCrane, DistributedBattleFactory, DistributedCashbotBossTreasure, DistributedCogHQDoor, DistributedSellbotHQDoor, DistributedFactoryElevatorExt, DistributedMintElevatorExt, DistributedLawOfficeElevatorExt, DistributedLawOfficeElevatorInt, LobbyManager, DistributedMegaCorp, DistributedFactory, DistributedLawOffice, DistributedLawOfficeFloor, DistributedLift, DistributedDoorEntity, DistributedSwitch, DistributedButton, DistributedTrigger, DistributedCrushableEntity, DistributedCrusherEntity, DistributedStomper, DistributedStomperPair, DistributedLaserField, DistributedGolfGreenGame, DistributedSecurityCamera, DistributedMover, DistributedElevatorMarker, DistributedBarrelBase, DistributedGagBarrel, DistributedBeanBarrel, DistributedHealBarrel, DistributedGrid, ActiveCell, DirectionalCell, CrusherCell, DistributedCrate, DistributedSinkingPlatform, BattleBlocker, DistributedMint, DistributedMintRoom, DistributedMintBattle, DistributedStage, DistributedStageRoom, DistributedStageBattle, DistributedLawbotBossGavel, DistributedLawbotCannon, DistributedLawbotChair, DistributedCogKart, DistributedCountryClub, DistributedCountryClubRoom, DistributedMoleField, DistributedCountryClubBattle, DistributedMaze, DistributedFoodBelt, DistributedBanquetTable, DistributedGolfSpot
|
||||||
|
|
|
@ -1,13 +1,21 @@
|
||||||
from direct.directnotify import DirectNotifyGlobal
|
from direct.directnotify import DirectNotifyGlobal
|
||||||
from direct.distributed.DistributedObjectAI import DistributedObjectAI
|
from direct.distributed.DistributedObjectAI import DistributedObjectAI
|
||||||
from PartyGlobals import *
|
from PartyGlobals import *
|
||||||
import DistributedPartyCannonAI, DistributedPartyCannonActivityAI, DistributedPartyCatchActivityAI, DistributedPartyCogActivityAI, DistributedPartyDanceActivityAI
|
import PartyUtils
|
||||||
import DistributedPartyDance20ActivityAI, DistributedPartyFireworksActivityAI, DistributedPartyJukeboxActivityAI, DistributedPartyJukebox40ActivityAI
|
import time
|
||||||
import DistributedPartyTrampolineActivityAI, DistributedPartyTugOfWarActivityAI, DistributedPartyValentineDanceActivityAI
|
# ugh all these activities
|
||||||
import DistributedPartyValentineDance20ActivityAI, DistributedPartyValentineJukeboxActivityAI, DistributedPartyValentineJukebox40ActivityAI
|
from toontown.parties.DistributedPartyJukeboxActivityAI import DistributedPartyJukeboxActivityAI
|
||||||
import DistributedPartyValentineTrampolineActivityAI, DistributedPartyVictoryTrampolineActivityAI, DistributedPartyWinterCatchActivityAI
|
from toontown.parties.DistributedPartyDanceActivityAI import DistributedPartyDanceActivityAI
|
||||||
import DistributedPartyWinterCogActivityAI, DistributedPartyWinterTrampolineActivityAI
|
from toontown.parties.DistributedPartyJukebox40ActivityAI import DistributedPartyJukebox40ActivityAI
|
||||||
import PartyUtils, time
|
from toontown.parties.DistributedPartyDance20ActivityAI import DistributedPartyDance20ActivityAI
|
||||||
|
from toontown.parties.DistributedPartyCogActivityAI import DistributedPartyCogActivityAI
|
||||||
|
from toontown.parties.DistributedPartyTrampolineActivityAI import DistributedPartyTrampolineActivityAI
|
||||||
|
from toontown.parties.DistributedPartyVictoryTrampolineActivityAI import DistributedPartyVictoryTrampolineActivityAI
|
||||||
|
from toontown.parties.DistributedPartyCatchActivityAI import DistributedPartyCatchActivityAI
|
||||||
|
from toontown.parties.DistributedPartyTugOfWarActivityAI import DistributedPartyTugOfWarActivityAI
|
||||||
|
from toontown.parties.DistributedPartyCannonActivityAI import DistributedPartyCannonActivityAI
|
||||||
|
from toontown.parties.DistributedPartyCannonAI import DistributedPartyCannonAI
|
||||||
|
from toontown.parties.DistributedPartyFireworksActivityAI import DistributedPartyFireworksActivityAI
|
||||||
|
|
||||||
"""
|
"""
|
||||||
dclass DistributedParty : DistributedObject {
|
dclass DistributedParty : DistributedObject {
|
||||||
|
@ -51,23 +59,16 @@ class DistributedPartyAI(DistributedObjectAI):
|
||||||
DistributedObjectAI.generate(self)
|
DistributedObjectAI.generate(self)
|
||||||
# make stuff
|
# make stuff
|
||||||
actId2Class = {
|
actId2Class = {
|
||||||
ActivityIds.PartyCatch: DistributedPartyCatchActivityAI.DistributedPartyCatchActivityAI,
|
ActivityIds.PartyJukebox: DistributedPartyJukeboxActivityAI,
|
||||||
ActivityIds.PartyCog: DistributedPartyCogActivityAI.DistributedPartyCogActivityAI,
|
ActivityIds.PartyTrampoline: DistributedPartyTrampolineActivityAI,
|
||||||
ActivityIds.PartyDance: DistributedPartyDanceActivityAI.DistributedPartyDanceActivityAI,
|
ActivityIds.PartyVictoryTrampoline: DistributedPartyVictoryTrampolineActivityAI,
|
||||||
ActivityIds.PartyDance20: DistributedPartyDance20ActivityAI.DistributedPartyDance20ActivityAI,
|
ActivityIds.PartyCatch: DistributedPartyCatchActivityAI,
|
||||||
ActivityIds.PartyFireworks: DistributedPartyFireworksActivityAI.DistributedPartyFireworksActivityAI,
|
ActivityIds.PartyDance: DistributedPartyDanceActivityAI,
|
||||||
ActivityIds.PartyJukebox: DistributedPartyJukeboxActivityAI.DistributedPartyJukeboxActivityAI,
|
ActivityIds.PartyTugOfWar: DistributedPartyTugOfWarActivityAI,
|
||||||
ActivityIds.PartyJukebox40: DistributedPartyJukebox40ActivityAI.DistributedPartyJukebox40ActivityAI,
|
ActivityIds.PartyFireworks: DistributedPartyFireworksActivityAI,
|
||||||
ActivityIds.PartyTrampoline: DistributedPartyTrampolineActivityAI.DistributedPartyTrampolineActivityAI,
|
ActivityIds.PartyJukebox40: DistributedPartyJukebox40ActivityAI,
|
||||||
ActivityIds.PartyTugOfWar: DistributedPartyTugOfWarActivityAI.DistributedPartyTugOfWarActivityAI,
|
ActivityIds.PartyDance20: DistributedPartyDance20ActivityAI,
|
||||||
ActivityIds.PartyValentineDance: DistributedPartyValentineDanceActivityAI.DistributedPartyValentineDanceActivityAI,
|
ActivityIds.PartyCog: DistributedPartyCogActivityAI,
|
||||||
ActivityIds.PartyValentineDance20: DistributedPartyValentineDance20ActivityAI.DistributedPartyValentineDance20ActivityAI,
|
|
||||||
ActivityIds.PartyValentineJukebox: DistributedPartyValentineJukeboxActivityAI.DistributedPartyValentineJukeboxActivityAI,
|
|
||||||
ActivityIds.PartyValentineJukebox40: DistributedPartyValentineJukebox40ActivityAI.DistributedPartyValentineJukebox40ActivityAI,
|
|
||||||
ActivityIds.PartyValentineTrampoline: DistributedPartyValentineTrampolineActivityAI.DistributedPartyValentineTrampolineActivityAI,
|
|
||||||
ActivityIds.PartyVictoryTrampoline: DistributedPartyVictoryTrampolineActivityAI.DistributedPartyVictoryTrampolineActivityAI,
|
|
||||||
ActivityIds.PartyWinterCatch: DistributedPartyWinterCatchActivityAI.DistributedPartyWinterCatchActivityAI,
|
|
||||||
ActivityIds.PartyWinterCog: DistributedPartyWinterCogActivityAI.DistributedPartyWinterCogActivityAI
|
|
||||||
}
|
}
|
||||||
for activity in self.info['activities']:
|
for activity in self.info['activities']:
|
||||||
actId = activity[0]
|
actId = activity[0]
|
||||||
|
@ -77,9 +78,9 @@ class DistributedPartyAI(DistributedObjectAI):
|
||||||
self.activities.append(act)
|
self.activities.append(act)
|
||||||
elif actId == ActivityIds.PartyCannon:
|
elif actId == ActivityIds.PartyCannon:
|
||||||
if not self.cannonActivity:
|
if not self.cannonActivity:
|
||||||
self.cannonActivity = DistributedPartyCannonActivityAI.DistributedPartyCannonActivityAI(self.air, self.doId, activity)
|
self.cannonActivity = DistributedPartyCannonActivityAI(self.air, self.doId, activity)
|
||||||
self.cannonActivity.generateWithRequired(self.zoneId)
|
self.cannonActivity.generateWithRequired(self.zoneId)
|
||||||
act = DistributedPartyCannonAI.DistributedPartyCannonAI(self.air)
|
act = DistributedPartyCannonAI(self.air)
|
||||||
act.setActivityDoId(self.cannonActivity.doId)
|
act.setActivityDoId(self.cannonActivity.doId)
|
||||||
x, y, h = activity[1:] # ignore activity ID
|
x, y, h = activity[1:] # ignore activity ID
|
||||||
x = PartyUtils.convertDistanceFromPartyGrid(x, 0)
|
x = PartyUtils.convertDistanceFromPartyGrid(x, 0)
|
||||||
|
|
|
@ -166,7 +166,14 @@ class GlobalPartyManagerUD(DistributedObjectGlobalUD):
|
||||||
self.__updatePartyCount(partyId)
|
self.__updatePartyCount(partyId)
|
||||||
|
|
||||||
def partyManagerAIHello(self, channel):
|
def partyManagerAIHello(self, channel):
|
||||||
|
# Upon AI boot, DistributedPartyManagerAIs are supposed to say hello.
|
||||||
|
# They send along the DPMAI's doId as well, so that I can talk to them later.
|
||||||
|
print 'AI with base channel %s, will send replies to DPM %s' % (simbase.air.getAvatarIdFromSender(), channel)
|
||||||
self.senders2Mgrs[simbase.air.getAvatarIdFromSender()] = channel
|
self.senders2Mgrs[simbase.air.getAvatarIdFromSender()] = channel
|
||||||
|
self.sendToAI('partyManagerUdStartingUp', [])
|
||||||
|
|
||||||
|
# In addition, set up a postRemove where we inform this AI that the UD has died
|
||||||
|
self.air.addPostRemove(self._makeAIMsg('partyManagerUdLost', [], channel))
|
||||||
|
|
||||||
def addParty(self, avId, partyId, start, end, isPrivate, inviteTheme, activities, decorations, inviteeIds):
|
def addParty(self, avId, partyId, start, end, isPrivate, inviteTheme, activities, decorations, inviteeIds):
|
||||||
PARTY_TIME_FORMAT = '%Y-%m-%d %H:%M:%S'
|
PARTY_TIME_FORMAT = '%Y-%m-%d %H:%M:%S'
|
||||||
|
|
|
@ -110,9 +110,24 @@ PartyEditorActivityOrder = [ ActivityIds.PartyClock,
|
||||||
ActivityIds.PartyCog,
|
ActivityIds.PartyCog,
|
||||||
ActivityIds.PartyWinterCog,
|
ActivityIds.PartyWinterCog,
|
||||||
ActivityIds.PartyFireworks]
|
ActivityIds.PartyFireworks]
|
||||||
MutuallyExclusiveActivities = ((ActivityIds.PartyJukebox, ActivityIds.PartyJukebox40, ActivityIds.PartyValentineJukebox, ActivityIds.PartyValentineJukebox40),
|
MutuallyExclusiveActivities = ((ActivityIds.PartyJukebox, ActivityIds.PartyJukebox40),
|
||||||
|
(ActivityIds.PartyValentineJukebox, ActivityIds.PartyValentineJukebox40),
|
||||||
(ActivityIds.PartyDance, ActivityIds.PartyDance20),
|
(ActivityIds.PartyDance, ActivityIds.PartyDance20),
|
||||||
(ActivityIds.PartyValentineDance, ActivityIds.PartyValentineDance20))
|
(ActivityIds.PartyValentineDance, ActivityIds.PartyValentineDance20))
|
||||||
|
VictoryPartyActivityIds = frozenset([ActivityIds.PartyVictoryTrampoline])
|
||||||
|
VictoryPartyReplacementActivityIds = frozenset([ActivityIds.PartyTrampoline])
|
||||||
|
WinterPartyActivityIds = frozenset([ActivityIds.PartyWinterCatch, ActivityIds.PartyWinterTrampoline, ActivityIds.PartyWinterCog])
|
||||||
|
WinterPartyReplacementActivityIds = frozenset([ActivityIds.PartyCatch, ActivityIds.PartyTrampoline, ActivityIds.PartyCog])
|
||||||
|
ValentinePartyActivityIds = frozenset([ActivityIds.PartyValentineDance,
|
||||||
|
ActivityIds.PartyValentineDance20,
|
||||||
|
ActivityIds.PartyValentineJukebox,
|
||||||
|
ActivityIds.PartyValentineJukebox40,
|
||||||
|
ActivityIds.PartyValentineTrampoline])
|
||||||
|
ValentinePartyReplacementActivityIds = frozenset([ActivityIds.PartyDance,
|
||||||
|
ActivityIds.PartyDance20,
|
||||||
|
ActivityIds.PartyJukebox,
|
||||||
|
ActivityIds.PartyJukebox40,
|
||||||
|
ActivityIds.PartyTrampoline])
|
||||||
DecorationIds = PythonUtil.Enum(('BalloonAnvil',
|
DecorationIds = PythonUtil.Enum(('BalloonAnvil',
|
||||||
'BalloonStage',
|
'BalloonStage',
|
||||||
'Bow',
|
'Bow',
|
||||||
|
@ -141,6 +156,21 @@ DecorationIds = PythonUtil.Enum(('BalloonAnvil',
|
||||||
'BalloonAnvilValentine'))
|
'BalloonAnvilValentine'))
|
||||||
DECORATION_VOLUME = 1.0
|
DECORATION_VOLUME = 1.0
|
||||||
DECORATION_CUTOFF = 45
|
DECORATION_CUTOFF = 45
|
||||||
|
VictoryPartyDecorationIds = frozenset([DecorationIds.BannerVictory,
|
||||||
|
DecorationIds.CannonVictory,
|
||||||
|
DecorationIds.CogStatueVictory,
|
||||||
|
DecorationIds.TubeCogVictory])
|
||||||
|
WinterPartyDecorationIds = frozenset([DecorationIds.cogIceCreamWinter,
|
||||||
|
DecorationIds.StageWinter,
|
||||||
|
DecorationIds.CogStatueWinter,
|
||||||
|
DecorationIds.snowman,
|
||||||
|
DecorationIds.snowDoodle])
|
||||||
|
VictoryPartyReplacementDecorationIds = frozenset([DecorationIds.BannerJellyBean])
|
||||||
|
ValentinePartyDecorationIds = frozenset([DecorationIds.BalloonAnvilValentine,
|
||||||
|
DecorationIds.HeartBanner,
|
||||||
|
DecorationIds.HeartTarget,
|
||||||
|
DecorationIds.FlyingHeart])
|
||||||
|
ValentinePartyReplacementDecorationIds = frozenset([DecorationIds.BalloonAnvil, DecorationIds.BannerJellyBean])
|
||||||
GoToPartyStatus = PythonUtil.Enum(('AllowedToGo',
|
GoToPartyStatus = PythonUtil.Enum(('AllowedToGo',
|
||||||
'PartyFull',
|
'PartyFull',
|
||||||
'PrivateParty',
|
'PrivateParty',
|
||||||
|
|
|
@ -3598,36 +3598,40 @@ PartyDecorationNameDict = {0: {'editor': 'Balloon Anvil',
|
||||||
9: {'editor': 'Pinwheel',
|
9: {'editor': 'Pinwheel',
|
||||||
'description': 'Colorful twirling for everyone!'},
|
'description': 'Colorful twirling for everyone!'},
|
||||||
10: {'editor': 'Gag Globe',
|
10: {'editor': 'Gag Globe',
|
||||||
'description': 'Gag and star globe'},
|
'description': 'Gag and star globe designed by Olivea'},
|
||||||
11: {'editor': 'Bean Banner',
|
11: {'editor': 'Bean Banner',
|
||||||
'description': 'A Jellybean banner'},
|
'description': 'A Jellybean banner designed by Cassidy'},
|
||||||
12: {'editor': 'Gag Cake',
|
12: {'editor': 'Gag Cake',
|
||||||
'description': 'A Topsy Turvy gag cake'},
|
'description': 'A Topsy Turvy gag cake designed by Felicia'},
|
||||||
13: {'editor': "Cupid's Heart",
|
13: {'editor': "Cupid's Heart",
|
||||||
'description': 'Ready...Aim...\nValenToons!'},
|
'description': 'Ready...Aim...\nValenToons!'},
|
||||||
14: {'editor': 'Candy Hearts\n Banner',
|
14: {'editor': 'Candy Hearts\n Banner',
|
||||||
'description': "Who doesn't love candy hearts?"},
|
'description': "Who doesn't love candy hearts?"},
|
||||||
15: {'editor': 'Flying Heart',
|
15: {'editor': 'Flying Heart',
|
||||||
'description': 'This heart is getting carried away!'},
|
'description': 'This heart is getting carried away!'},
|
||||||
16: {'editor': 'Victory Banner',
|
16: {'editor': 'Victory Bandstand',
|
||||||
|
'description': 'All our new friends are ready to dance!'},
|
||||||
|
17: {'editor': 'Victory Banner',
|
||||||
'description': 'Not just a normal banner!'},
|
'description': 'Not just a normal banner!'},
|
||||||
17: {'editor': 'Confetti Cannons',
|
18: {'editor': 'Confetti Cannons',
|
||||||
'description': 'BOOM! Confetti! Fun!'},
|
'description': 'BOOM! Confetti! Fun!'},
|
||||||
18: {'editor': 'Cog & Doodle',
|
19: {'editor': 'Cog & Doodle',
|
||||||
'description': "Ouch! That's gotta hurt."},
|
'description': "Ouch! That's gotta hurt."},
|
||||||
19: {'editor': 'Cog Flappy Man',
|
20: {'editor': 'Cog Flappy Man',
|
||||||
'description': 'A Cog full of hot air, what a shock!'},
|
'description': 'A Cog full of hot air, what a shock!'},
|
||||||
20: {'editor': 'CogCicle',
|
21: {'editor': 'Cog Ice Cream',
|
||||||
|
'description': 'A Cog looking his best.'},
|
||||||
|
22: {'editor': 'CogCicle',
|
||||||
'description': 'A Cog looking his holiday best.'},
|
'description': 'A Cog looking his holiday best.'},
|
||||||
21: {'editor': 'Holiday Bandstand',
|
23: {'editor': 'Holiday Bandstand',
|
||||||
'description': 'Everyone loves a Holiday Party!'},
|
'description': 'Everyone loves a Holiday Party!'},
|
||||||
22: {'editor': 'Chilly Cog',
|
24: {'editor': 'Chilly Cog',
|
||||||
'description': "Ouch! That's gotta hurt."},
|
'description': "Ouch! That's gotta hurt."},
|
||||||
23: {'editor': 'Snowman',
|
25: {'editor': 'Snowman',
|
||||||
'description': "So cool, he's hot!"},
|
'description': "So cool, he's hot!"},
|
||||||
24: {'editor': 'SnowDoodle',
|
26: {'editor': 'SnowDoodle',
|
||||||
'description': 'His only trick is being cold!'},
|
'description': 'His only trick is being cold!'},
|
||||||
25: {'editor': 'ValenToons Anvil',
|
27: {'editor': 'ValenToons Anvil',
|
||||||
'description': "We've got your heart on a string!"}}
|
'description': "We've got your heart on a string!"}}
|
||||||
ActivityLabel = 'Cost - Activity Name'
|
ActivityLabel = 'Cost - Activity Name'
|
||||||
PartyDoYouWantToPlan = 'Would you like to plan a new party right now?'
|
PartyDoYouWantToPlan = 'Would you like to plan a new party right now?'
|
||||||
|
|
|
@ -21,10 +21,17 @@ class DistributedPartyManagerAI(DistributedObjectAI):
|
||||||
self.id2Party = {}
|
self.id2Party = {}
|
||||||
self.pubPartyInfo = {}
|
self.pubPartyInfo = {}
|
||||||
self.idPool = range(self.air.ourChannel, self.air.ourChannel + 100000)
|
self.idPool = range(self.air.ourChannel, self.air.ourChannel + 100000)
|
||||||
|
# get 100 ids at the start and top up
|
||||||
|
#taskMgr.doMethodLater(0, self.__getIds, 'DistributedPartyManagerAI___getIds')
|
||||||
|
|
||||||
def receiveId(self, ids):
|
def receiveId(self, ids):
|
||||||
self.idPool += ids
|
self.idPool += ids
|
||||||
|
|
||||||
|
# def __getIds(self, task):
|
||||||
|
# if len(self.idPool) < 50:
|
||||||
|
# self.air.globalPartyMgr.allocIds(100 - len(self.idPool))
|
||||||
|
# taskMgr.doMethodLater(180, self.__getIds, 'DistributedPartyManagerAI___getIds')
|
||||||
|
|
||||||
def _makePartyDict(self, struct):
|
def _makePartyDict(self, struct):
|
||||||
PARTY_TIME_FORMAT = '%Y-%m-%d %H:%M:%S'
|
PARTY_TIME_FORMAT = '%Y-%m-%d %H:%M:%S'
|
||||||
party = {}
|
party = {}
|
||||||
|
@ -41,6 +48,15 @@ class DistributedPartyManagerAI(DistributedObjectAI):
|
||||||
# struct[16] = partystatus
|
# struct[16] = partystatus
|
||||||
return party
|
return party
|
||||||
|
|
||||||
|
# Management stuff
|
||||||
|
def partyManagerUdStartingUp(self):
|
||||||
|
# This is sent in reply to the GPMAI's hello
|
||||||
|
self.notify.info("uberdog has said hello")
|
||||||
|
|
||||||
|
def partyManagerUdLost(self):
|
||||||
|
# well fuck. ud died.
|
||||||
|
self.notify.warning("uberdog lost!")
|
||||||
|
|
||||||
def addPartyRequest(self, hostId, startTime, endTime, isPrivate, inviteTheme, activities, decorations, inviteeIds):
|
def addPartyRequest(self, hostId, startTime, endTime, isPrivate, inviteTheme, activities, decorations, inviteeIds):
|
||||||
if hostId != simbase.air.getAvatarIdFromSender():
|
if hostId != simbase.air.getAvatarIdFromSender():
|
||||||
self.air.writeServerEvent('suspicious',simbase.air.getAvatarIdFromSender(),'Toon tried to create a party as someone else!')
|
self.air.writeServerEvent('suspicious',simbase.air.getAvatarIdFromSender(),'Toon tried to create a party as someone else!')
|
||||||
|
|
|
@ -7,6 +7,8 @@ class DistributedPartyManagerUD(DistributedObjectUD):
|
||||||
def announceGenerate(self):
|
def announceGenerate(self):
|
||||||
DistributedObjectUD.announceGenerate(self)
|
DistributedObjectUD.announceGenerate(self)
|
||||||
|
|
||||||
|
self.sendUpdate('partyManagerUdStartingUp') # Shouldn't have to send to anyone special, as the field is airecv
|
||||||
|
|
||||||
def addParty(self, todo0, todo1, todo2, todo3, todo4, todo5, todo6, todo7, todo8, todo9):
|
def addParty(self, todo0, todo1, todo2, todo3, todo4, todo5, todo6, todo7, todo8, todo9):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
@ -112,6 +114,9 @@ class DistributedPartyManagerUD(DistributedObjectUD):
|
||||||
def sendShardIdZoneIdToAvatar(self, shardId, zoneId):
|
def sendShardIdZoneIdToAvatar(self, shardId, zoneId):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
def partyManagerUdStartingUp(self):
|
||||||
|
pass
|
||||||
|
|
||||||
def updateAllPartyInfoToUd(self, todo0, todo1, todo2, todo3, todo4, todo5, todo6, todo7, todo8):
|
def updateAllPartyInfoToUd(self, todo0, todo1, todo2, todo3, todo4, todo5, todo6, todo7, todo8):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue