Python IDLE

Hey guys. i’ve been playing around with python and lerned how to do most my stuff in the IDLE. but when i tried to run through the lessons here. like just opening Panda. The IDLE can’t open it. when i have to edit my code as well. i have to write the whole thing from square one. how can use the IDLE insted of the DOS looking window that came with Panda?

Try using ‘ppython idle’ might be an option… this would call IDLE in the Panda3D environment thus allowing you to use the Panda3D libraries with IDLE…

However, you can also code your code with the normal ‘python idle’ (what is going to be called when double clicking on the ‘idle’ icon) - but to run that code you need to open the dos box then and have to run ‘ppython yourCode.py’ there…

Regards, Bigfoot29

see. I went into the Python IDLE and just copy pasted the stuff in the lessons in the manul on this site. saved it as grass.py tryed to load it after pulling up panda 3d by useing the import direct.directbase.DirectStart but it didn’t open it. came back with an error

There are already bat files which you can use just to see what the code is doing.To read open the file with idle, but it will not run since the libs needed are not in the path.

Hi all,

I’m on day 1 of getting to grips with Panda & Python. I prefer using IDLE too, so I had the same issues.

Create a batch file - call it Panda3D.bat

You just need one line:

ppython c:\panda3d-1.1.0\python\Lib\idlelib\idle.py %1 %2 %3 %4 %5 %6 %7 %8 %9

Everything seems to work fine.

Note:
I left the 1-9 parameters in as they’re set on the original batch file … haven’t bothered to find out what they’re for yet.