|Plouj||python on planes? I think I've heard everything now - http://developers.slashdot.org/developers/07/04/01/176239.shtml|
|joao_afk||Plouj: April the 1st i you did not notice it.|
|synx||I realized something important about python yesterday, and programming in general.|
Every variable is global. Every freaking variable is global.
Even if you have a variable on the stack in C, you can still access the same location on the stack anywhere else in the program, provided you know where it is.
So python variables are all global, because that's how computers work, not because of some special python thing.
|gpolo||well, there is a thing called scope too|
some other day you will learn about this one
|synx||The keyword global itself only keeps new local variables from overlapping the one in context. It should be nocreatelocalvariableonassign, but I guess 'global' has a catchy ring to it.|
Sure, well scope is one strategy to plan restriction of access to variables. So in languages with scope sure the variable might change unpredictably, as other functions use that area of the stack. But it's still global.
|reportingsjr||If anyone here has ever done 3d game programming in java, what would you recommend as the best 3d rendering engine for a game?|
|synx||OpenGL is pretty much the standard when it comes to 3D rendering engines. It's not a cakewalk, but it is pretty powerful.|
|reportingsjr||Does most everyone has opengl?|
|reportingsjr||I would like this to be cross platform|
|gpolo||ah ok, ignore then|
|synx||E v e r y o n e has OpenGl.|
Sorry, I'm brand new to this block. I am a php programmer :)
|reportingsjr||I think I might use Soya3d|
|snarfer||How do I loop the contents of a file into a dictionary>|
This is what I have so far:
|synx||You might want to look into the pygame module. It uses SDL, but works pretty seamlessly with OpenGL in some cases.|
snarfer: Depends on the file format.
|gpolo||for line in file..|
|reportingsjr||synx, well I thought it was mainly 2d, I did look into it though|
|synx||snarfer: You need a file format that has a set of key,value pairs, or else you can't make a dictionary.|
|delsvr||I'm looking to build a tuple interactively. How should I initialize the variable?|
er, not interactively. dynamically.
|synx||reportingsjr: OpenGL is the 3D part. It can render on an SDL surface though, among other things.|
|gpolo||snarfer, you did split already, not what else you want ?|
|reportingsjr||well, what would be easier to make a 3d game with?|
|synx||snarfer: Oh, so your format is one record per line, with key: value comma separated?|