PGD Home

P-152: Virtual World Concept Update 170: Milestone 2: Final Work: Part 2

by on Sep.04, 2016, under Astral Realms, P-0, Software and Games, Spiritus Astrum

I have finished cleaning up the code base after MS2. It is now down to slightly less than 3,000 lines of code, which is a lot less than I expected. Most of the work I put into it was in the algorithms and concept itself, rather than the actual code, which is likely why it is so short.

I am also considering a new coordinate system for the terrain, which may fix the floating point issue. The idea would be to keep the current world and local coordinate systems, but also add another, so that I could keep the world space positions as they are, but also adjust the render position to keep it centered on the (local) origin.

I have also learned that the cause of the floating point issue may in fact be with the players movement, not with the terrains movement. I was moving the player in a straight line, since this was the easiest way to test the players movement. However, in reality, moving the player around a spherical planet would cause them to move in a curve, not a line. I did not take this into account. It is quite possible that I need to work on moving the player correctly, not the terrain.

It may actually not take as long as I feared to fix the floating origin issue, but I will still need to take a step back from it and decide on what the best approach should be. I can do this while I am working on other projects, and hopefully get MS 2.5 actually done without having to work full-time on it.

Given the fact that the spherical terrain implementation is, so far, one of the only major parts of P0 that I have worked on, the thought has occurred to me that if I ever wanted to port to a new engine, now would be the time. My spherical terrain implementation is really all that I would need to port with P0 (I have done other work, but it’s not as important, and wouldn’t be as time-consuming to recreate. It would also be much easier to port).

Since I wrote almost all of this myself, with the exception of the bare minimum code that I needed to “hook” into the T3D rendering, collision, and networking subsystems, porting to a new engine and hooking into their subsystems should not be an impossible challenge.

I was evaluating Unreal some time ago, but I haven’t had a chance to fully immerse myself in it. I think I will try out both Unreal and Unity, and possibly CryEngine/LumberYard. Unity, being a C# based engine, may be more difficult to port to from T3D, but so far I am finding Unreal quite difficult to adapt to with it’s “blueprint” visual scripting system.

I am reasonably happy with how MS 2 turned out. I accomplished the main goal of the milestone, which was to add support for realistic planet sizes. In addition, I added the Tier-based scaling system which allows for a complete transition from the surface of the planet to the far reaches of space. It’s very basic at the moment, but it does work. This took up the vast majority of the time. I also added a lot of other, smaller, features, and bug fixes.

I unfortunately uncovered quite a few new issues while doing this, most notably the floating origin issue, but I am also having issues with the noise generation function, (producing terrain with either jagged surfaces, or completely flat) optimisations, and general bugs. I have definitely made huge progress however, and I think I will have a fully working, procedural, spherical terrain system in the relatively near future.

P152_DEBUG 05/09/2016 , 12:48:45 AM Torque 3D MIT - P152

P152_DEBUG
05/09/2016 , 12:48:45 AM
Torque 3D MIT – P152

P152_DEBUG 05/09/2016 , 12:21:55 AM Torque 3D MIT - P152

P152_DEBUG
05/09/2016 , 12:21:55 AM
Torque 3D MIT – P152

wgnuplot 04/09/2016 , 01:43:54 AM Gnuplot (window id : 0) [SCM]actwin,0,84,961,843;

wgnuplot
04/09/2016 , 01:43:54 AM
Gnuplot (window id : 0)
[SCM]actwin,0,84,961,843;

P152_DEBUG 03/09/2016 , 11:57:07 PM Torque 3D MIT - P152

P152_DEBUG
03/09/2016 , 11:57:07 PM
Torque 3D MIT – P152

P152_DEBUG 04/09/2016 , 12:44:47 AM Torque 3D MIT - P152

P152_DEBUG
04/09/2016 , 12:44:47 AM
Torque 3D MIT – P152

Facebooktwitterredditpinterestlinkedinmail

Comments are closed.

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!