diff --git a/libotp/settings/Settings.py b/libotp/settings/Settings.py index dd5a29f..eac320c 100644 --- a/libotp/settings/Settings.py +++ b/libotp/settings/Settings.py @@ -11,6 +11,10 @@ class Settings: def writeSettings(): pass # lol not yet + @staticmethod + def setWindowedMode(_): + pass + @staticmethod def getWindowedMode(): return 1 @@ -47,10 +51,18 @@ class Settings: def getSfxVolume(): return 1 + @staticmethod + def setResolutionDimensions(_, __): + pass + @staticmethod def getResolution(): return 1 + @staticmethod + def setEmbeddedMode(_): + pass + @staticmethod def getEmbeddedMode(): return 0 diff --git a/otp/avatar/DistributedAvatar.py b/otp/avatar/DistributedAvatar.py index 8c23cfc..e15eafb 100644 --- a/otp/avatar/DistributedAvatar.py +++ b/otp/avatar/DistributedAvatar.py @@ -229,10 +229,10 @@ class DistributedAvatar(DistributedActor, Avatar): self.hpTextSeq.start() def hideHpText(self): + if self.hpTextSeq: + self.hpTextSeq.finish() + self.hpTextSeq = None if self.hpText: - if self.hpTextSeq: - self.hpTextSeq.finish() - self.hpTextSeq = None self.hpText.removeNode() self.hpText = None return diff --git a/toontown/battle/DistributedBattleBldg.py b/toontown/battle/DistributedBattleBldg.py index f08d31e..d0f518e 100644 --- a/toontown/battle/DistributedBattleBldg.py +++ b/toontown/battle/DistributedBattleBldg.py @@ -1,4 +1,5 @@ from pandac.PandaModules import * +from libotp import * from direct.interval.IntervalGlobal import * from BattleBase import * from direct.actor import Actor diff --git a/toontown/battle/DistributedBattleBldgAI.py b/toontown/battle/DistributedBattleBldgAI.py index 73a6416..8714592 100644 --- a/toontown/battle/DistributedBattleBldgAI.py +++ b/toontown/battle/DistributedBattleBldgAI.py @@ -11,7 +11,7 @@ from direct.directnotify import DirectNotifyGlobal import random from direct.fsm import State from direct.fsm import ClassicFSM, State -from direct.showbase import PythonUtil +from otp.otpbase import PythonUtil class DistributedBattleBldgAI(DistributedBattleBaseAI.DistributedBattleBaseAI): notify = DirectNotifyGlobal.directNotify.newCategory('DistributedBattleBldgAI') diff --git a/toontown/battle/MovieLure.py b/toontown/battle/MovieLure.py index 951c942..1eeab41 100644 --- a/toontown/battle/MovieLure.py +++ b/toontown/battle/MovieLure.py @@ -412,7 +412,7 @@ def getSplicedLerpAnimsTrack(object, animName, origDuration, newDuration, startT numIvals = origDuration * fps timeInterval = newDuration / numIvals animInterval = origDuration / numIvals - for i in range(0, numIvals): + for i in range(0, int(numIvals)): track.append(Wait(timeInterval)) track.append(ActorInterval(object, animName, startTime=startTime + addition, duration=animInterval)) addition += animInterval diff --git a/toontown/battle/MovieSuitAttacks.py b/toontown/battle/MovieSuitAttacks.py index 5a06057..53be49a 100644 --- a/toontown/battle/MovieSuitAttacks.py +++ b/toontown/battle/MovieSuitAttacks.py @@ -760,7 +760,7 @@ def getSplicedLerpAnims(animName, origDuration, newDuration, startTime = 0, fps animInterval = origDuration / numAnims if reverse == 1: animInterval = -animInterval - for i in range(0, numAnims): + for i in range(0, int(numAnims)): anims.append([animName, timeInterval, startTime + addition, diff --git a/toontown/battle/MovieUtil.py b/toontown/battle/MovieUtil.py index bba0744..1068e72 100644 --- a/toontown/battle/MovieUtil.py +++ b/toontown/battle/MovieUtil.py @@ -588,7 +588,7 @@ def createSuitStunInterval(suit, before, after): stars.adjustAllPriorities(100) head = suit.getHeadParts()[0] head.calcTightBounds(p1, p2) - return Sequence(Wait(before), Func(stars.reparentTo, head), Func(stars.setZ, max(0.0, p2[2] - 1.0)), Func(stars.loop, 'stun'), Wait(after), Func(stars.removeNode)) + return Sequence(Wait(before), Func(stars.reparentTo, head), Func(stars.setZ, max(0.0, p2[2] - 1.0)), Func(stars.loop, 'stun'), Wait(after), Func(stars.cleanup), Func(stars.removeNode)) def calcAvgSuitPos(throw): diff --git a/toontown/cogdominium/DistributedCogdoInterior.py b/toontown/cogdominium/DistributedCogdoInterior.py index 9551aca..e905f80 100644 --- a/toontown/cogdominium/DistributedCogdoInterior.py +++ b/toontown/cogdominium/DistributedCogdoInterior.py @@ -4,6 +4,7 @@ from direct.distributed.ClockDelta import * from toontown.building.ElevatorConstants import * from toontown.toon import NPCToons from pandac.PandaModules import NodePath +from libotp import * from toontown.building import ElevatorUtils from toontown.toonbase import ToontownGlobals from toontown.toonbase import ToontownBattleGlobals diff --git a/toontown/quest/QuestManagerAI.py b/toontown/quest/QuestManagerAI.py index 03e6436..4800e43 100644 --- a/toontown/quest/QuestManagerAI.py +++ b/toontown/quest/QuestManagerAI.py @@ -18,3 +18,9 @@ class QuestManagerAI: def hasTailorClothingTicket(self, toon, npc): return 0 # TODO + + def toonKilledBuilding(self, toon, track, difficulty, numFloors, zoneId, activeToons): + pass # TODO + + def toonKilledCogdo(self, toon, difficulty, numFloors, zoneId, activeToons): + pass # TODO