coghq: fix some factory crashes
This commit is contained in:
parent
80bda9a9ec
commit
77548ed278
3 changed files with 8 additions and 4 deletions
|
@ -10,6 +10,7 @@ from toontown.ai.NewsManagerAI import NewsManagerAI
|
|||
from toontown.ai.WelcomeValleyManagerAI import WelcomeValleyManagerAI
|
||||
from toontown.building.DistributedTrophyMgrAI import DistributedTrophyMgrAI
|
||||
from toontown.catalog.CatalogManagerAI import CatalogManagerAI
|
||||
from toontown.coghq.CogSuitManagerAI import CogSuitManagerAI
|
||||
from toontown.coghq.FactoryManagerAI import FactoryManagerAI
|
||||
from toontown.coghq.PromotionManagerAI import PromotionManagerAI
|
||||
from toontown.distributed.ToontownDistrictAI import ToontownDistrictAI
|
||||
|
@ -65,6 +66,7 @@ class ToontownAIRepository(ToontownInternalRepository):
|
|||
self.cogPageManager = None
|
||||
self.raceMgr = None
|
||||
self.factoryMgr = None
|
||||
self.cogSuitMgr = None
|
||||
self.timeManager = None
|
||||
self.newsManager = None
|
||||
self.welcomeValleyManager = None
|
||||
|
@ -138,6 +140,9 @@ class ToontownAIRepository(ToontownInternalRepository):
|
|||
# Create our factory manager...
|
||||
self.factoryMgr = FactoryManagerAI(self)
|
||||
|
||||
# Create our Cog suit manager...
|
||||
self.cogSuitMgr = CogSuitManagerAI(self)
|
||||
|
||||
def createGlobals(self):
|
||||
"""
|
||||
Creates "global" (distributed) objects.
|
||||
|
|
|
@ -48,7 +48,7 @@ class DistributedGrid(BasicEntities.DistributedNodePathEntity):
|
|||
long = self.numRow
|
||||
short = self.numCol
|
||||
h = 90
|
||||
self.model.setScale(scale * int, scale * short, 1)
|
||||
self.model.setScale(scale * long, scale * short, 1)
|
||||
self.model.setHpr(h, 180, 0)
|
||||
self.model.setPos(self.cellSize * self.numCol / 2.0, self.cellSize * self.numRow / 2.0, 0.025)
|
||||
self.model.setColor(0.588, 0.588, 0.459, 0.4)
|
||||
|
|
|
@ -10,7 +10,6 @@ from toontown.battle import BattleProps
|
|||
from toontown.toonbase import TTLocalizer
|
||||
from pandac.PandaModules import VirtualFileMountHTTP, VirtualFileSystem, Filename, DSearchPath
|
||||
from direct.showbase import AppRunnerGlobal
|
||||
import string
|
||||
import os
|
||||
aSize = 6.06
|
||||
bSize = 5.29
|
||||
|
@ -928,7 +927,7 @@ class Suit(Avatar.Avatar):
|
|||
else:
|
||||
self.setSuitClothes(self.loseActor)
|
||||
else:
|
||||
loseModel = 'phase_5/models/char/cog' + string.upper(self.style.body) + '_robot-lose-mod'
|
||||
loseModel = 'phase_5/models/char/cog' + self.style.body.upper() + '_robot-lose-mod'
|
||||
filePrefix, phase = TutorialModelDict[self.style.body]
|
||||
loseAnim = 'phase_' + str(phase) + filePrefix + 'lose'
|
||||
self.loseActor = Actor.Actor(loseModel, {'lose': loseAnim})
|
||||
|
@ -952,7 +951,7 @@ class Suit(Avatar.Avatar):
|
|||
return
|
||||
|
||||
def makeSkeleton(self):
|
||||
model = 'phase_5/models/char/cog' + string.upper(self.style.body) + '_robot-zero'
|
||||
model = 'phase_5/models/char/cog' + self.style.body.upper() + '_robot-zero'
|
||||
anims = self.generateAnimDict()
|
||||
anim = self.getCurrentAnim()
|
||||
dropShadow = self.dropShadow
|
||||
|
|
Loading…
Reference in a new issue