O'Reilly logo

3D Game Programming for Teens, Second Edition by Eric Grebler, Maneesh Sethi

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Importing Models into Blitz3D

Creating your 3D models is only the first step. They won’t do you any good if you can’t bring them into your programs. That’s what we’ll take care of now by using the LoadMesh function. Once the object is imported, you can apply a texture to it like any other.

Create the following blank program, save it with any name, and make sure that the files missile.3ds and missile.jpg are in the same folder where you saved the program. Or, you can load the final version from the CD. It is titled demo10-01.bb.

We need to actually load our 3D model using the LoadMesh command. We’ll also apply a texture to it, resize it, and position it at the same time by loading the following code, or running the file from the CD.

;demo10-01.bb ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required