Does anyone have the code for this? The download link is broken.
i have fixed the download links in the first post.
Thank you Hypnos!
Do you mind if I modify your code so that it runs in a standard GUI window (QT/Gtk/etc) and release as open source?
thatâs fine for me. iâve tried encapsulating the gui from the code as much as possible, so it shouldnt be possible.
Hey,
When I try to run the code i get this:
Traceback (most recent call last):
File "main.py", line 8, in <module>
console = pandaConsole( INPUT_CONSOLE|INPUT_GUI|OUTPUT_PYTHON|OUTPUT_IRC, locals() )
File "C:\Panda3D-1.6.2\pandac\interactiveConsole\interactiveConsole.py", line 30, in __init__
self.panda3dConsole = panda3dIOClass( self )
File "C:\Panda3D-1.6.2\pandac\interactiveConsole\panda3d.py", line 72, in __init__
fixedWidthFont = loader.loadFont(self.font)
File "C:\Panda3D-1.6.2\direct\showbase\Loader.py", line 432, in loadFont
raise IOError, message
IOError: Could not load font file: data/interactiveConsole/vera.ttf
EDIT: Never mind I figured out how to fix it
Iâm having the same problem, how did you fix it?
P.s. - I had to download 2.1.8, so I just load 2.2 over it? 2.2 only contains the interactiveConsole folder.
The error has to do with a missing font. Itâs looking for âdata/interactiveConsole/vera.ttfâ which doesnât exist.
To solve this problem, go into the âshared.pyâ file and find the âPANDA3D_CONSOLE_FONTâ variable and change the value to â/c/Windows/Fonts/arial.ttfâ
so it should look like this:
PANDA3D_CONSOLE_FONT = "/c/Windows/Fonts/arial.ttf"
Hope this helps.
Tried what you said also, and I also verified that the font was there, but still itâs coming out with an errorâŚ
DirectStart: Starting the game.
Known pipe types:
wdxGraphicsPipe9
(all display modules loaded.)
ERROR: no clipboard module found for platform win32
- using dummy clipboard ( no interaction with os )
max number of characters on a length: 85
:express(warning): Filename is incorrect case: /c/Windows/Fonts/arial.ttf instead of /c/WINDOWS/Fonts/arial.ttf
:express(warning): Filename is incorrect case: /c/Windows/Fonts/arial.ttf instead of /c/WINDOWS/Fonts/arial.ttf
:express(warning): Filename is incorrect case: /c/Windows/Fonts/arial.ttf instead of /c/WINDOWS/Fonts/arial.ttf
:pnmtext(error): Unable to find font file /c/Windows/Fonts/arial.ttf
Traceback (most recent call last):
File "DirectTut_Console.py", line 8, in <module>
console = pandaConsole( INPUT_CONSOLE|INPUT_GUI|OUTPUT_PYTHON|OUTPUT_IRC, locals() )
File "C:\Panda3D-1.6.2\python\lib\src\interactiveConsole.py", line 30, in __init__
self.panda3dConsole = panda3dIOClass( self )
File "C:\Panda3D-1.6.2\python\lib\src\panda3d.py", line 71, in __init__
fixedWidthFont = loader.loadFont(self.font)
File "C:\Panda3D-1.6.2\direct\showbase\Loader.py", line 432, in loadFont
raise IOError, message
IOError: Could not load font file: /c/Windows/Fonts/arial.ttf
**** End of process output ****
Any idea why?
Treeform detailed that the font needed to be corrected
c/WINDOWS/Fonts/arial.ttf
So that was the last part of the fix. Thanks guys!
Iâd like to try this console, but the instructions on importing it seem not to match whatâs in the v2.2 download. I have tried various things, but keep getting import errors. Can anyone enlighten me?
\d
Sweet thanks!
\d
I had to make two changes in order for the test-application to work:
p = pandaConsole(INPUT_GUI, OUTPUT_PYTHON)
should be
p = pandaConsole(INPUT_GUI | OUTPUT_PYTHON)
in main.py, and
def __init__( self, interfaces=INPUT_GUI|INPUT_CONSOLE|OUTPUT_PYTHON|OUTPUT_IRC, localsEnv=globals ):
should be
def __init__( self, interfaces=INPUT_GUI|INPUT_CONSOLE|OUTPUT_PYTHON|OUTPUT_IRC, localsEnv=globals() ):
in interactiveConsole.py - (parenthesis after globals were missing)
/Daniel