Description The screenshot shows a frame from my first person 3D terrain engine. One thing I hate about modern 3D RTS engines is that the camera can't be in the thick of battle with your armies, so I am working on this "first person" terrain engine. You can actually move the camera right down to ground level or leave it hovering above the ground.
An approach I have taken is to develop a true 3D zone where meshes are used close to the camera and a non-3D zone where billboards, lots of them, are used for trees etc. Excusing my fairly lame tree meshes at the front of the image, the concept is demonstrated quite clearly with the billboard tree bitmaps in the rear. Permanent fixtures like buildings are left in true 3D.
My engine does not use a ROAM type algorithm for terrain; instead I use a simple but effective tile system. You can liken my terrain mechanism to being in the same style as the 2D adjoining tiles in classic Rollercoaster Tycoon, only of course in 3D. While my engine does not generate high-resolution terrain geometry, efficient and easy to manipulate rolling hills do result. The benefit of tiles too is that all world entities can be mapped using a linked list. Essentially the entire world map is an octree, rendering entities that are only on a visible tile. Having seamless terrain textures hides the fact tiles are used.
Streamlining of code is my next big undertaking. I want to have a long viewing distance for this engine so as to watch huge armies clash.
It sounds like your terrain engine is going to work really really well.
I am a game designer, so i don't really know much about engine development, but I can say that it would be an idea to have support for high level shaders (mostly becuase they can give some great effects and are really quite easy to write (or download off the nVidia site)).
I like the idea of having a LOD for the environmental props. IDV's Speedtree RT does this quite nicely, though it isn't just mesh or billboard, it has about 8 different levels of mesh then billboard. This system works quite nicely (as you can see in the Unreal Engine 3 and Elder Scrolls 4: Oblivion screenshots). Perhaps doing soemthing like this might work.
One thing I hate about modern RTS engine is the lack of physics. AOE 3 promises to address this issue, but apart from that, nothing. It would be awesome to see ODE or Newton Game Dynamics in your engine.
What sort of input, networking, ai etc does your engine have?
Also, is your scene hard-coded or do you have an editor to make life easier?
I am very interested in your engine and hope to see more of it.
I like that screenie very much and i'm very satisfied with the engine itself too. Keep up the good work and keep us informed on the progress!
Hi Methulah – thanks for the comments. While I would very much like to add shader support my pre dx9 graphics card is something of a problem! My most immediate goal is to really polish and tidy a lot of the code up. Unfortunately the prototype depicted is built on top of a lot of legacy procedural code I wrote way before I even studied programming at uni, so in the way that a "true" independent 3D engine goes much of it relies on hard code. It can of course load x files and the tiling algorithm, particularly how it snaps edges together, is a work of art, but nothing like a level map editor is implemented yet. Basically I just feed the tiler some hard coded xyz points at random and the tiler slopes out around these points from the top to the ground. The effect is simple but surprisingly cool, as the tiler can smooth over hills that collide.
Varying LOD is of course a nice thing to implement for a game with maybe a few hundred or so objects in the background but I am really keen on having thousands of objects on screen, something that to this day has not been done in a commercial game. I think using billboards at distance is okay if you keep the true 3D zone fairly wide and you have a cool FPS interface that interacts nicely with high detail meshes.
As for the input I have paid special attention to the mouse. You can imagine that designing a FPS strategy hybrid game plays havoc with the controls. I recall this was done somewhat okay with the command aspect of Operation Flashpoint, so I have tried to capture this. The FPS control aspect works by holding the right mouse button for rotation and holding left moves forward. When you let go of all these buttons a 3D cursor pops up and you can move it to command while the camera stays still. The command 3D mouse function I have not put into my engine yet but I have successfully created and used this in a little demo I made ages ago.
Physics, AI and networking are not on the radar yet. Isaac Newton is not a part of my 3D world… yet. Basically now that I have developed a proof of concept prototype, which is what my engine is at the moment, my next task is rebuilding it from the ground up using a current c++ compiler, in OO, in dx9 and with as many optimisations as I can find. Frame rate is a problem, at my worst I am pushing only about 33000 textured-billboard triangles plus inner zone meshes (est. avg of 20000 triangles a frame) at 16 fps with mip mapping on. Removing overheads like cutting state changes should seriously help out. What can I say, rough code rough frame rate. I am still happy though, as all my concepts for the next engine have been proved.
Really nice work there, it looks like you are doing it the right way, polishing and optimising your code for DirectX 9.0 and a faster frame rate. This is probably the way it should be done, yet I never seem to have the patience to fix up code before implementing new features.
Nice work, and I think that if it is fully finished then it will stand out becuase of the "FPS Zone" making it look better than the current RTS engines out there.
However I recommend that you check out some Elder Scrolls 4: Oblivion screenshots. Bethseda have done a great piece of work implementing SpeedTree RT and they have HUGE forests with grass and trees.
One the thiongs about making the engine for higher end cards that you should think of if you are going to be mkaing thousands of trees is instancing. One of the beauties of SpeedTree RT is that it builds trees from a base and all "randomly generated" trees will use as many resources as if you were rendering just one of each family. I am not a seasoned graphics programmer so I do not know how difficult an algorithm like this would be to code, but if it is possible, it may be worth ckecking out.
Great Work with the engine.
(Pardon posting twice)
I have reviewed what it is you are looking for and I can only say that I think that your concept is truly great and if it works out could have some HUGE potential and be a unique and powerful engine.
The main reason I brought up high level shaders is that it has always been a dream of mine to build a high level shader driven engine. This has been an issue, mainly becuase my C++ is sketchy at best and I am a designer more than anything.
This said, one type of game that has always been in my mind is a MMOFPSRTS. What this would mean is that there is a Massivly Multiplayer persistant online world, where players take the role of peasant or rise up to be kings, lords or whatever and build and gather resources under instruction or by their free will... in first person. This idea is very, very difficult to implement - and would probably have a relitavly small audience - but it was just a thought for a possible use for your engine.
Anyway, if you wish, I can provide various pixel shaders (as .fx files) for use in your engine. ONly if you want it though .
Anyway. Again, great work on the engine, and hope to hear more of it.