mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2025-01-09 17:53:50 +00:00
Stuff that was bothering me
This commit is contained in:
parent
2b4fc260dc
commit
e4340eb131
9 changed files with 35 additions and 54 deletions
6
dependencies/astron/dclass/stride.dc
vendored
6
dependencies/astron/dclass/stride.dc
vendored
|
@ -150,7 +150,7 @@ dclass DistributedPlayer : DistributedAvatar {
|
||||||
setSC(uint16 msgIndex) broadcast ownsend airecv;
|
setSC(uint16 msgIndex) broadcast ownsend airecv;
|
||||||
setSCCustom(uint16 msgIndex) broadcast ownsend airecv;
|
setSCCustom(uint16 msgIndex) broadcast ownsend airecv;
|
||||||
setFriendsList(uint32[] = []) ownrecv required db airecv;
|
setFriendsList(uint32[] = []) ownrecv required db airecv;
|
||||||
setDISLid(uint32 = 0) broadcast ownrecv ram db airecv required;
|
setDISLid(uint32 = 0) airecv ram db;
|
||||||
setWishName(string = "") db ram;
|
setWishName(string = "") db ram;
|
||||||
setWishNameState(string = "OPEN") db ram;
|
setWishNameState(string = "OPEN") db ram;
|
||||||
setAdminAccess(uint16 = 0) required broadcast ownrecv db;
|
setAdminAccess(uint16 = 0) required broadcast ownrecv db;
|
||||||
|
@ -555,7 +555,7 @@ dclass ToontownDistrict : DistributedDistrict {
|
||||||
};
|
};
|
||||||
|
|
||||||
dclass ToontownDistrictStats : DistributedObject {
|
dclass ToontownDistrictStats : DistributedObject {
|
||||||
settoontownDistrictId(uint32) broadcast required ram;
|
setDistrictId(uint32) broadcast required ram;
|
||||||
setAvatarCount(uint32) broadcast required ram;
|
setAvatarCount(uint32) broadcast required ram;
|
||||||
setInvasionStatus(uint8) broadcast required ram;
|
setInvasionStatus(uint8) broadcast required ram;
|
||||||
};
|
};
|
||||||
|
@ -726,7 +726,6 @@ dclass DistributedToon : DistributedPlayer {
|
||||||
setGolfCourseBest(uint8 [3] = [0*3]) required ownrecv db;
|
setGolfCourseBest(uint8 [3] = [0*3]) required ownrecv db;
|
||||||
setUnlimitedSwing(uint8) broadcast ownrecv ram;
|
setUnlimitedSwing(uint8) broadcast ownrecv ram;
|
||||||
logSuspiciousEvent(char [0-1024]) ownsend airecv;
|
logSuspiciousEvent(char [0-1024]) ownsend airecv;
|
||||||
logMessage(char [0-1024]) ownsend airecv;
|
|
||||||
forceLogoutWithNotify() ownrecv;
|
forceLogoutWithNotify() ownrecv;
|
||||||
setPinkSlips(uint8 = 0) required ownrecv db;
|
setPinkSlips(uint8 = 0) required ownrecv db;
|
||||||
setNametagStyle(uint8 = 0) required broadcast ownrecv db;
|
setNametagStyle(uint8 = 0) required broadcast ownrecv db;
|
||||||
|
@ -743,7 +742,6 @@ dclass DistributedToon : DistributedPlayer {
|
||||||
setPartyStatus(uint64, uint8) ownrecv airecv;
|
setPartyStatus(uint64, uint8) ownrecv airecv;
|
||||||
announcePartyStarted(uint64) ownrecv;
|
announcePartyStarted(uint64) ownrecv;
|
||||||
setNeverStartedPartyRefunded(uint64, int8, uint16) ownrecv;
|
setNeverStartedPartyRefunded(uint64, int8, uint16) ownrecv;
|
||||||
setDISLid(uint32) ram db airecv;
|
|
||||||
setAnimalSound(uint8 index) ram broadcast ownrecv;
|
setAnimalSound(uint8 index) ram broadcast ownrecv;
|
||||||
setBuffs(uint32[] = []) required ownrecv db;
|
setBuffs(uint32[] = []) required ownrecv db;
|
||||||
setRedeemedCodes(string [] = []) required ownrecv db;
|
setRedeemedCodes(string [] = []) required ownrecv db;
|
||||||
|
|
|
@ -122,8 +122,6 @@ def kick(reason='No reason specified'):
|
||||||
Kick the target from the game server.
|
Kick the target from the game server.
|
||||||
"""
|
"""
|
||||||
target = spellbook.getTarget()
|
target = spellbook.getTarget()
|
||||||
if target == spellbook.getInvoker():
|
|
||||||
return "You can't kick yourself!"
|
|
||||||
datagram = PyDatagram()
|
datagram = PyDatagram()
|
||||||
datagram.addServerHeader(
|
datagram.addServerHeader(
|
||||||
target.GetPuppetConnectionChannel(target.doId),
|
target.GetPuppetConnectionChannel(target.doId),
|
||||||
|
|
|
@ -191,7 +191,7 @@ class ToontownAIRepository(ToontownInternalRepository):
|
||||||
self.claimOwnership(self.districtId)
|
self.claimOwnership(self.districtId)
|
||||||
|
|
||||||
self.districtStats = ToontownDistrictStatsAI(self)
|
self.districtStats = ToontownDistrictStatsAI(self)
|
||||||
self.districtStats.settoontownDistrictId(self.districtId)
|
self.districtStats.setDistrictId(self.districtId)
|
||||||
self.districtStats.generateWithRequiredAndId(
|
self.districtStats.generateWithRequiredAndId(
|
||||||
self.allocateChannel(), self.getGameDoId(), 3)
|
self.allocateChannel(), self.getGameDoId(), 3)
|
||||||
self.notify.info('Created ToontownDistrictStats(%d)' % self.districtStats.doId)
|
self.notify.info('Created ToontownDistrictStats(%d)' % self.districtStats.doId)
|
||||||
|
|
|
@ -67,15 +67,15 @@ class ToontownDistrictStats(DistributedObject.DistributedObject):
|
||||||
|
|
||||||
def __init__(self, cr):
|
def __init__(self, cr):
|
||||||
DistributedObject.DistributedObject.__init__(self, cr)
|
DistributedObject.DistributedObject.__init__(self, cr)
|
||||||
self.toontownDistrictId = 0
|
self.districtId = 0
|
||||||
|
|
||||||
def settoontownDistrictId(self, value):
|
def setDistrictId(self, value):
|
||||||
self.toontownDistrictId = value
|
self.districtId = value
|
||||||
|
|
||||||
def setAvatarCount(self, avatarCount):
|
def setAvatarCount(self, avatarCount):
|
||||||
if self.toontownDistrictId in self.cr.activeDistrictMap:
|
if self.districtId in self.cr.activeDistrictMap:
|
||||||
self.cr.activeDistrictMap[self.toontownDistrictId].avatarCount = avatarCount
|
self.cr.activeDistrictMap[self.districtId].avatarCount = avatarCount
|
||||||
|
|
||||||
def setInvasionStatus(self, invasionStatus):
|
def setInvasionStatus(self, invasionStatus):
|
||||||
if self.toontownDistrictId in self.cr.activeDistrictMap:
|
if self.districtId in self.cr.activeDistrictMap:
|
||||||
self.cr.activeDistrictMap[self.toontownDistrictId].invasionStatus = invasionStatus
|
self.cr.activeDistrictMap[self.districtId].invasionStatus = invasionStatus
|
|
@ -20,17 +20,17 @@ class ToontownDistrictStatsAI(DistributedObjectAI):
|
||||||
status = {'population': self.avatarCount}
|
status = {'population': self.avatarCount}
|
||||||
self.air.netMessenger.send('shardStatus', [self.air.ourChannel, status])
|
self.air.netMessenger.send('shardStatus', [self.air.ourChannel, status])
|
||||||
|
|
||||||
def settoontownDistrictId(self, districtId):
|
def setDistrictId(self, districtId):
|
||||||
self.districtId = districtId
|
self.districtId = districtId
|
||||||
|
|
||||||
def d_settoontownDistrictId(self, districtId):
|
def d_setDistrictId(self, districtId):
|
||||||
self.sendUpdate('settoontownDistrictId', [districtId])
|
self.sendUpdate('setDistrictId', [districtId])
|
||||||
|
|
||||||
def b_settoontownDistrictId(self, districtId):
|
def b_setDistrictId(self, districtId):
|
||||||
self.settoontownDistrictId(districtId)
|
self.setDistrictId(districtId)
|
||||||
self.d_settoontownDistrictId(districtId)
|
self.d_setDistrictId(districtId)
|
||||||
|
|
||||||
def gettoontownDistrictId(self):
|
def getDistrictId(self):
|
||||||
return self.districtId
|
return self.districtId
|
||||||
|
|
||||||
def setAvatarCount(self, avatarCount):
|
def setAvatarCount(self, avatarCount):
|
||||||
|
|
|
@ -474,10 +474,8 @@ class DistributedTwoDGame(DistributedMinigame):
|
||||||
self.updateScore(avId, ToonBlitzGlobals.ScoreGainPerTreasure * treasure.value)
|
self.updateScore(avId, ToonBlitzGlobals.ScoreGainPerTreasure * treasure.value)
|
||||||
else:
|
else:
|
||||||
self.notify.error('WHOA!! treasureIndex %s is out of range; numTreasures = %s' % (treasureIndex, numTreasures))
|
self.notify.error('WHOA!! treasureIndex %s is out of range; numTreasures = %s' % (treasureIndex, numTreasures))
|
||||||
base.localAvatar.sendLogMessage('treasureIndex %s is out of range; numTreasures = %s' % (treasureIndex, numTreasures))
|
|
||||||
else:
|
else:
|
||||||
self.notify.error('WHOA!! sectionIndex %s is out of range; numSections = %s' % (sectionIndex, numSections))
|
self.notify.error('WHOA!! sectionIndex %s is out of range; numSections = %s' % (sectionIndex, numSections))
|
||||||
base.localAvatar.sendLogMessage('sectionIndex %s is out of range; numSections = %s' % (sectionIndex, numSections))
|
|
||||||
|
|
||||||
def __enemyShot(self, sectionIndex, enemyIndex):
|
def __enemyShot(self, sectionIndex, enemyIndex):
|
||||||
self.sectionMgr.sections[sectionIndex].enemyMgr.enemies[enemyIndex].doShotTrack()
|
self.sectionMgr.sections[sectionIndex].enemyMgr.enemies[enemyIndex].doShotTrack()
|
||||||
|
|
|
@ -2041,9 +2041,6 @@ class DistributedToon(DistributedPlayer.DistributedPlayer, Toon.Toon, Distribute
|
||||||
for soundSequence in removeList:
|
for soundSequence in removeList:
|
||||||
self.soundSequenceList.remove(soundSequence)
|
self.soundSequenceList.remove(soundSequence)
|
||||||
|
|
||||||
def sendLogMessage(self, message):
|
|
||||||
self.sendUpdate('logMessage', [message])
|
|
||||||
|
|
||||||
def setChatAbsolute(self, chatString, chatFlags, dialogue = None, interrupt = 1, quiet = 0):
|
def setChatAbsolute(self, chatString, chatFlags, dialogue = None, interrupt = 1, quiet = 0):
|
||||||
DistributedAvatar.DistributedAvatar.setChatAbsolute(self, chatString, chatFlags, dialogue, interrupt)
|
DistributedAvatar.DistributedAvatar.setChatAbsolute(self, chatString, chatFlags, dialogue, interrupt)
|
||||||
|
|
||||||
|
|
|
@ -3655,13 +3655,6 @@ class DistributedToonAI(DistributedPlayerAI.DistributedPlayerAI, DistributedSmoo
|
||||||
def getNametagStyle(self):
|
def getNametagStyle(self):
|
||||||
return self.nametagStyle
|
return self.nametagStyle
|
||||||
|
|
||||||
def logMessage(self, message):
|
|
||||||
avId = self.air.getAvatarIdFromSender()
|
|
||||||
try:
|
|
||||||
self.air.writeServerEvent('clientLog', avId, message)
|
|
||||||
except:
|
|
||||||
self.air.writeServerEvent('suspicious', avId, 'client sent us a clientLog that caused an exception')
|
|
||||||
|
|
||||||
def b_setMail(self, mail):
|
def b_setMail(self, mail):
|
||||||
self.d_setMail(mail)
|
self.d_setMail(mail)
|
||||||
self.setMail(mail)
|
self.setMail(mail)
|
||||||
|
|
|
@ -457,9 +457,6 @@ class DistributedToonUD(DistributedObjectUD):
|
||||||
def logSuspiciousEvent(self, todo0):
|
def logSuspiciousEvent(self, todo0):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def logMessage(self, todo0):
|
|
||||||
pass
|
|
||||||
|
|
||||||
def forceLogoutWithNotify(self):
|
def forceLogoutWithNotify(self):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue