Wednesday, 31 October 2012

Week 8 – Creating an accurate and scaled solar system using the Ogre3D engine



            It is good to be back in school again after a short absence, due to funeral preparations. For this week, I had spent most of my programming time working on the first medium question, which is to create a solar system with planets and moons. We also had to add information about each planet and moon whenever the player clicks the planet or moon. This appeared to be very difficult at first, but once I began to work on it, it was pretty easy to do, as it was just a lot of copy and pasting and getting the information for each planet and moon from the web. Programming-wise, it wasn’t too difficult, as the majority of the code was derived from the sample projects, and pretty much required a combination of them. 
The solar system layout

The sun
I had to add code that allows the user to click on any planet or moon, and it would display the name of that planet or moon and 8 pieces of information about that planet or moon. This was done using some of the code from one of the sample projects as a basis and foundation, and I had to add the all the tool tip information for each planet and moon, using information from the web. The clicking function was also taken from another sample project, which was modified to create a bounding box around the planet or moon when clicked on. Once a planet or moon is clicked on, the information about that particular planet or moon will appear in the top left corner, which I had programmed in. The parenting sample project contained all the code that I needed to create all the planets and moons, and to make them orbit around the sun or the planet, as well as to spin while in orbit. I searched online for accurate information about the orbital and spin speed of each planet and moon, in order to make this program as accurate as possible. 
Earth


Stay tuned for more updates on my game engines progression!

Jupiter's moon Europa


No comments:

Post a Comment