from direct.showbase.ShowBase import ShowBase
class Window(ShowBase):
def __init__(self):
Showbase.__init__(self)
self.loadModels()
def loadModels(self):
self.ttc = loader.loadModel('phase_4/models/neighborhoods/toontown_central_full.bam')
self.ttc.reparentTo(render)
game = Window()
game.run()
The error I am getting is:
Traceback (most recent call last):
File “Window.py”, line 15, in
game = Window()
File “Window.py”, line 7, in init
Show.base.init(self)
NameError: global name ‘Showbase’ is not defined
In the tutorial I am watching, this guy types the exact same thing (execpt for the loadModel directory, I know) and it works for him?
youtube.com/watch?v=A5HNxQQVzMI
Could it be because im using Geany and he is using PyCharm?