The *.deb works fine for Ubuntu. I had to build the tarball on Gentoo, apart from fussing with library paths, that goes smoothly too. Or rather, I don't remember being driven into fits of rage by it, which, given my experiences with game engines so far, is positively an endorsement.
On Gentoo, you need to set your environment variable LD_LIBRARY_PATH=/usr/lib/panda3d so that Python knows where to find Panda. Or do the lazy thing and just add it to every invocation of a Panda program.
LD_LIBRARY_PATH=/usr/lib/panda3d python Tut-Asteroids.py LD_LIBRARY_PATH=/usr/lib/panda3d pview
Get the Chicken exporter script and follow the README, it'll tell you about Ubuntu's symlinks making you put each part in the right folder, and you'll have to do it from the command line so you can sudo to cope with messed up file permissions
This was baffling task for me, so simple and yet hard to figure out.
I hate Blender's UI with the fire of 10,000 suns. When using it on a laptop with a tiny screen and a touchpad, the fire of 10 million suns.
Pview won't be able to see the tile because of the way the plane is oriented. If you move the camera up just slightly you may catch a glimpse of it.
And it puts it on upside down! Probably my fault.
Once I got a tile, I poked around in the file itself. Blender is overkill for creating a unit plane with a picture stuck on it.
Sample code is clearer than any explanation I can come up with. And, yup, these 5 lines of code at the top are all it takes.
import direct.directbase.DirectStart from pandac.PandaModules import * from direct.interval.IntervalGlobal import * from direct.task.Task import Task #We get a nice 2D view, without perspective messing everything up lens = OrthographicLens() base.cam.node().setLens(lens) #From the Panda3D manual, the film size should be the unit size of #your view of the world lens.setFilmSize(16,12) #Any Z value greater than zero works for position, you will always #get the same view base.cam.setPos(0,0,1) base.cam.lookAt(0,0,0) tile = loader.loadModel("tile.egg") #blender makes a 2 unit x 2 unit tile tile.setScale(0.5, 0.5, 0.5) #not quite correct code borrowed from a hexagonal tile map example #in the Panda3D forums map = NodePath('map') map.reparentTo(render) for x in xrange(-9,9): for y in xrange(-7,7): tile.setPos(x,y,0) tile.copyTo(map) map.flattenStrong() run()
February 10, 2010